mirror of
https://github.com/ZDoom/gzdoom-gles.git
synced 2024-11-29 07:22:07 +00:00
Extended FString class with functions to get first and last characters
This commit is contained in:
parent
3e43572a87
commit
d526ddf7ae
1 changed files with 3 additions and 0 deletions
|
@ -187,6 +187,9 @@ public:
|
|||
FString &operator << (char tail) { return *this += tail; }
|
||||
FString &operator << (const FName &name) { return *this += name.GetChars(); }
|
||||
|
||||
const char &Front() const { assert(IsNotEmpty()); return Chars[0]; }
|
||||
const char &Back() const { assert(IsNotEmpty()); return Chars[Len() - 1]; }
|
||||
|
||||
FString Left (size_t numChars) const;
|
||||
FString Right (size_t numChars) const;
|
||||
FString Mid (size_t pos, size_t numChars = ~(size_t)0) const;
|
||||
|
|
Loading…
Reference in a new issue