19 String(
const char *s);
23 String(
const String &other);
27 String(String &&other);
36 const char *
raw(
this const String &self);
44 const char *
begin(
this const String &self);
48 const char *
end(
this const String &self);
56 String
reverse(
this String &self);
61 String
ltrim(
this String &self,
char ch =
' ');
66 String
rtrim(
this String &self,
char ch =
' ');
71 String
trim(
this String &self,
char ch =
' ');
86 bool operator ==(
this const String &self,
const String &other);
91 bool operator !=(
this const String &self,
const String &other);
96 bool operator <(
this const String &self,
const String &other);
101 bool operator >(
this const String &self,
const String &other);
106 bool operator <=(
this const String &self,
const String &other);
111 bool operator >=(
this const String &self,
const String &other);
116 String
operator +(
this const String &self,
const String &other);
121 String &
operator =(
this String &self,
const String &other);
126 String &
operator =(
this String &self, String &&other);
131 String &
operator +=(
this String &self,
const String &other);
String rtrim(this String &self, char ch=' ')
Removes all occurences of ch at the right of the string.
Definition String.cpp:100
bool operator!=(this const String &self, const String &other)
Checks if both strings are different.
Definition String.cpp:140
const char * begin(this const String &self)
Gets the base of the string vector.
Definition String.cpp:52
bool operator<(this const String &self, const String &other)
Checks if this string is smaller than another.
Definition String.cpp:145
bool operator<=(this const String &self, const String &other)
Checks if this string is smaller than another or if both have the same size.
Definition String.cpp:155
bool operator>=(this const String &self, const String &other)
Checks if this string is bigger than another or if both have the same size.
Definition String.cpp:160
char & operator[](this String &self, Typing::USize index)
Gets a character from its index.
Definition String.cpp:125
String reverse(this String &self)
Reverse the string.
Definition String.cpp:69
bool operator==(this const String &self, const String &other)
Checks if both strings are the same.
Definition String.cpp:135
String ltrim(this String &self, char ch=' ')
Removes all occurences of ch at the left of the string.
Definition String.cpp:89
Typing::USize length(this const String &self)
Gets the length of the string.
Definition String.cpp:47
void appendChar(this String &self, char ch)
Appends a character to the string.
Definition String.cpp:62
String & operator=(this String &self, const String &other)
Copy assignment operator.
Definition String.cpp:177
String operator+(this const String &self, const String &other)
Creates a new string by concatenating this string and another.
Definition String.cpp:165
String & operator+=(this String &self, const String &other)
Concatenate two strings.
Definition String.cpp:196
String substract(this String &self, Typing::USize chars)
Returns a substring from this string.
Definition String.cpp:30
const char * raw(this const String &self)
Gets a raw buffer which contains the string characters.
Definition String.cpp:42
const char * end(this const String &self)
Gets the end of the string vector.
Definition String.cpp:57
bool operator>(this const String &self, const String &other)
Checks if this string is bigger than another.
Definition String.cpp:150
String trim(this String &self, char ch=' ')
Removes all occurences of ch at the left and the right of the string.
Definition String.cpp:117
A linear dynamic generic container. TODO: if possible, support objects with no default constructor.
Definition Vector.hpp:13
Contains dynamic strings related features.
Definition String.hpp:8
size_t USize
Biggest unsigned type.
Definition Typing.hpp:38