|
libnick 2025.10.0
A cross-platform base for native Nickvision applications.
|
Concepts | |
| concept | StringImplicitlyConstructible |
Functions | |
| std::vector< std::byte > | decode (const std::string &base64) noexcept |
| Converts a base64 encoded string into a list of bytes. | |
| std::string | encode (const std::vector< std::byte > &bytes) noexcept |
| Converts a list of bytes into a base64 encoded string. | |
| bool | isValidUrl (const std::string &s) noexcept |
| Gets whether or not the provided string is a valid url. | |
| std::string | join (const std::vector< std::string > &values, const std::string &separator, bool separateLast=false) noexcept |
| Concatenates the elements of a string list using the specified separator between each element. | |
| std::string | lower (std::string s) noexcept |
| Gets a fully lowercase string from the provided string. | |
| std::string | newUuid () noexcept |
| Generates a new uuid value. | |
| std::string | newGuid () noexcept |
| Generates a new guid value. | |
| std::string | normalizeForFilename (const std::string &s, bool windowsOnly=false) noexcept |
| Normalizes a string for use in a filename. | |
| std::string | quote (const std::string &s) noexcept |
| Quotes a string for use in a command line. | |
| std::string | replace (std::string s, const std::string &toReplace, const std::string &replace) noexcept |
| Replaces a substring within a string with a new string. | |
| std::string | replace (std::string s, char toReplace, char replace) noexcept |
| Replaces a character within a string with a new character. | |
| std::vector< std::string > | splitArgs (std::string s) noexcept |
| Splits a string based on argument delimiters. | |
| std::string | str (const std::wstring &s) noexcept |
| Converts the wstring to a string. | |
| unsigned int | stoui (const std::string &s, size_t *idx=nullptr, int base=10) noexcept |
| Converts a string to an unsigned int. | |
| std::string | trim (const std::string &s) noexcept |
| Trims whitespace form the beginning and end of a string. | |
| std::string | trim (const std::string &s, char delimiter) noexcept |
| Trims the delimiter character form the beginning and end of a string. | |
| std::string | upper (std::string s) noexcept |
| Gets a fully uppercase string from the provided string. | |
| std::wstring | wstr (const std::string &s) noexcept |
| Converts the string to a wstring. | |
| template<StringImplicitlyConstructible T = std::string> | |
| std::vector< T > | split (const std::string &s, const std::string &delimiter, bool includeEmpty=true) noexcept |
| Splits a string based on a delimiter. | |
| template<StringImplicitlyConstructible T = std::string> | |
| std::vector< T > | split (const std::string &s, char delimiter, bool includeEmpty=true) noexcept |
| Splits a string based on a delimiter. | |
|
noexcept |
Converts a base64 encoded string into a list of bytes.
| base64 | The base64 encoded string |
|
noexcept |
Converts a list of bytes into a base64 encoded string.
| bytes | The list of bytes |
|
noexcept |
Gets whether or not the provided string is a valid url.
| s | The string to check |
|
noexcept |
Concatenates the elements of a string list using the specified separator between each element.
| values | The list of strings to join |
| separator | The string to use as a separator between each element |
| separateLast | Whether or not to include the separator for the last joined element |
|
noexcept |
Gets a fully lowercase string from the provided string.
| s | The string to get lowercase |
|
noexcept |
Generates a new guid value.
This function simple calls newUuid() and returns the result.
|
noexcept |
Generates a new uuid value.
|
noexcept |
Normalizes a string for use in a filename.
| s | The string to normalize |
| windowsOnly | Whether or not to normalize strictly for Windows |
|
noexcept |
Quotes a string for use in a command line.
| s | The string to quote |
|
noexcept |
Replaces a character within a string with a new character.
| s | The string to work on |
| toReplace | The character to be replaced |
| replace | The new character to replace with |
|
noexcept |
Replaces a substring within a string with a new string.
| s | The string to work on |
| toReplace | The substring to be replaced |
| replace | The new string to replace with |
|
noexcept |
Splits a string based on a delimiter.
| T | The type of the resulting splits (must be a type that can be implicitly converted to string) |
| s | The string to split |
| delimiter | The delimiter to split the string on |
| includeEmpty | Whether or not to include empty tokens |
|
noexcept |
Splits a string based on a delimiter.
| T | The type of the resulting splits (must be a type that can be implicitly converted to string) |
| s | The string to split |
| delimiter | The delimiter to split the string on |
| includeEmpty | Whether or not to include empty tokens |
|
noexcept |
Splits a string based on argument delimiters.
| s | The string to split |
|
noexcept |
Converts a string to an unsigned int.
| s | The string to convert |
| idx | The address of a size_t to store the number of characters processed |
| base | The number base |
|
noexcept |
Converts the wstring to a string.
| s | The wstring to convert |
|
noexcept |
Trims whitespace form the beginning and end of a string.
| s | The string to trim (unmodified) |
|
noexcept |
Trims the delimiter character form the beginning and end of a string.
| s | The string to trim (unmodified) |
| delimiter | The character to trim |
|
noexcept |
Gets a fully uppercase string from the provided string.
| s | The string to get uppercase |
|
noexcept |
Converts the string to a wstring.
| s | The string to convert |