Strings - Character mapping, conversion to upper/lowercase
This commit is contained in:
parent
fbff6e8352
commit
d823721fb2
3 changed files with 78 additions and 0 deletions
include/ebcl
|
@ -65,6 +65,8 @@ double UTF8ToDouble( char const* input , uint32_t size ,
|
|||
|
||||
struct T_Character
|
||||
{
|
||||
using F_Map = std::function< T_Character( T_Character ) >;
|
||||
|
||||
const uint32_t codepoint;
|
||||
|
||||
T_Character( ) noexcept;
|
||||
|
@ -240,6 +242,16 @@ class T_String
|
|||
|
||||
// ---------------------------------------------------------------------
|
||||
|
||||
// Generate a string using a function that transforms characters
|
||||
T_String mapped( T_Character::F_Map f ) const noexcept;
|
||||
|
||||
// Convert the string to uppercase
|
||||
T_String toUpper( ) const noexcept;
|
||||
// Convert the string to lowercase
|
||||
T_String toLower( ) const noexcept;
|
||||
|
||||
// ---------------------------------------------------------------------
|
||||
|
||||
bool equals( T_String const& other ) const;
|
||||
bool equals( char const* string ) const;
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue