You've already forked pico-launcher
mirror of
https://github.com/LNH-team/pico-launcher.git
synced 2026-01-09 16:28:48 -08:00
33 lines
1.5 KiB
C++
33 lines
1.5 KiB
C++
#pragma once
|
|
|
|
class StringUtil
|
|
{
|
|
public:
|
|
/// @brief Copies the null terminated string in src to the
|
|
/// dst buffer of size dstSize. If dstSize > 0 the dst
|
|
/// buffer is guarenteed to be null terminated, even
|
|
/// if src is truncated to fit in dst.
|
|
/// @param dst The destination buffer.
|
|
/// @param src The source string (null terminated).
|
|
/// @param dstLength The length of the destination buffer in characters.
|
|
static u32 Copy(char* dst, const char* src, u32 dstLength);
|
|
|
|
/// @brief Copies the null terminated string in src to the
|
|
/// dst buffer of size dstSize. If dstSize > 0 the dst
|
|
/// buffer is guarenteed to be null terminated, even
|
|
/// if src is truncated to fit in dst.
|
|
/// @param dst The destination buffer.
|
|
/// @param src The source string (null terminated).
|
|
/// @param dstLength The length of the destination buffer in char16_t characters.
|
|
static u32 Copy(char16_t* dst, const char16_t* src, u32 dstLength);
|
|
|
|
/// @brief Copies the null terminated string in src to the
|
|
/// dst buffer of size dstSize. If dstSize > 0 the dst
|
|
/// buffer is guarenteed to be null terminated, even
|
|
/// if src is truncated to fit in dst.
|
|
/// @param dst The destination buffer.
|
|
/// @param src The source string (null terminated).
|
|
/// @param dstLength The length of the destination buffer in char16_t characters.
|
|
static u32 Copy(char16_t* dst, const char* src, u32 dstLength);
|
|
};
|