Flecs v3.1
A fast entity component system (ECS) for C & C++
Loading...
Searching...
No Matches
flecs::string Struct Reference
Inheritance diagram for flecs::string:
flecs::string_view

Public Member Functions

 string (char *str)
 
 string (string &&str)
 
 operator const char * () const
 
stringoperator= (string &&str)
 
stringoperator= (const string &str)=delete
 
 string (const string &str)=delete
 
bool operator== (const flecs::string &str) const
 
bool operator!= (const flecs::string &str) const
 
bool operator== (const char *str) const
 
bool operator!= (const char *str) const
 
const char * c_str () const
 
std::size_t length ()
 
std::size_t size ()
 
void clear ()
 

Static Public Member Functions

template<size_t N>
static constexpr size_t length (char const (&)[N])
 

Protected Member Functions

 string (const char *str)
 

Protected Attributes

char * m_str = nullptr
 
const char * m_const_str
 
ecs_size_t m_length
 

Detailed Description

Definition at line 13 of file string.hpp.

Constructor & Destructor Documentation

◆ string() [1/4]

flecs::string::string ( )
inlineexplicit

Definition at line 14 of file string.hpp.

◆ string() [2/4]

flecs::string::string ( char *  str)
inlineexplicit

Definition at line 19 of file string.hpp.

◆ ~string()

flecs::string::~string ( )
inline

Definition at line 24 of file string.hpp.

◆ string() [3/4]

flecs::string::string ( string &&  str)
inline

Definition at line 34 of file string.hpp.

◆ string() [4/4]

flecs::string::string ( const char *  str)
inlineprotected

Definition at line 124 of file string.hpp.

Member Function Documentation

◆ c_str()

const char * flecs::string::c_str ( ) const
inline

Definition at line 95 of file string.hpp.

◆ clear()

void flecs::string::clear ( )
inline

Definition at line 112 of file string.hpp.

◆ length() [1/2]

std::size_t flecs::string::length ( )
inline

Definition at line 99 of file string.hpp.

◆ length() [2/2]

template<size_t N>
static constexpr size_t flecs::string::length ( char   const(&)[N])
inlinestaticconstexpr

Definition at line 104 of file string.hpp.

◆ operator const char *()

flecs::string::operator const char * ( ) const
inline

Definition at line 42 of file string.hpp.

◆ operator!=() [1/2]

bool flecs::string::operator!= ( const char *  str) const
inline

Definition at line 91 of file string.hpp.

◆ operator!=() [2/2]

bool flecs::string::operator!= ( const flecs::string str) const
inline

Definition at line 75 of file string.hpp.

◆ operator=()

string & flecs::string::operator= ( string &&  str)
inline

Definition at line 46 of file string.hpp.

◆ operator==() [1/2]

bool flecs::string::operator== ( const char *  str) const
inline

Definition at line 79 of file string.hpp.

◆ operator==() [2/2]

bool flecs::string::operator== ( const flecs::string str) const
inline

Definition at line 59 of file string.hpp.

◆ size()

std::size_t flecs::string::size ( )
inline

Definition at line 108 of file string.hpp.

Member Data Documentation

◆ m_const_str

const char* flecs::string::m_const_str
protected

Definition at line 130 of file string.hpp.

◆ m_length

ecs_size_t flecs::string::m_length
protected

Definition at line 131 of file string.hpp.

◆ m_str

char* flecs::string::m_str = nullptr
protected

Definition at line 129 of file string.hpp.


The documentation for this struct was generated from the following file: