libzypp
13.10.6
|
Access to the sat-pools string space. More...
#include <IdString.h>
Public Types | |
typedef sat::detail::IdType | IdType |
Public Member Functions | |
IdString () | |
Default ctor, empty string. More... | |
IdString (IdType id_r) | |
Ctor from id. More... | |
IdString (const char *str_r) | |
Ctor from string. More... | |
IdString (const std::string &str_r) | |
Ctor from string. More... | |
operator bool () const | |
Evaluate in a boolean context ( != . More... | |
bool | empty () const |
Whether the string is empty. More... | |
unsigned | size () const |
The strings size. More... | |
const char * | c_str () const |
Conversion to const char * More... | |
std::string | asString () const |
Conversion to std::string More... | |
bool | compareEQ (const IdString &rhs) const |
Fast compare equal. More... | |
int | compare (const IdString &rhs) const |
Compare IdString returning -1,0,1 . More... | |
int | compare (const char *rhs) const |
int | compare (const std::string &rhs) const |
IdType | id () const |
Expert backdoor. More... | |
Static Public Attributes | |
static const IdString | Null |
No or Null string ( Id 0 ). More... | |
static const IdString | Empty |
Empty string. More... | |
Private Attributes | |
IdType | _id |
Related Functions | |
(Note that these are not member functions.) | |
std::ostream & | operator<< (std::ostream &str, const IdString &obj) |
std::ostream & | dumpOn (std::ostream &str, const IdString &obj) |
bool | operator== (const IdString &lhs, const IdString &rhs) |
bool | operator!= (const IdString &lhs, const IdString &rhs) |
bool | operator< (const IdString &lhs, const IdString &rhs) |
bool | operator<= (const IdString &lhs, const IdString &rhs) |
bool | operator> (const IdString &lhs, const IdString &rhs) |
bool | operator>= (const IdString &lhs, const IdString &rhs) |
Additional Inherited Members | |
![]() | |
static PoolImpl & | myPool () |
Access to the sat-pools string space.
Construction from string will place a copy of the string in the string space, if it is not already present.
While comparison differs between IdString::Null and IdString::Empty ( NULL
and ""
), both are represented by an empty string ""
.
Definition at line 39 of file IdString.h.
Definition at line 42 of file IdString.h.
|
inline |
Default ctor, empty string.
Definition at line 46 of file IdString.h.
|
inlineexplicit |
Ctor from id.
Definition at line 49 of file IdString.h.
|
explicit |
Ctor from string.
Definition at line 31 of file IdString.cc.
|
explicit |
Ctor from string.
Definition at line 35 of file IdString.cc.
|
inlineexplicit |
Evaluate in a boolean context ( !=
. Null
)
Definition at line 66 of file IdString.h.
|
inline |
Whether the string is empty.
This is true for Null and Empty.
Definition at line 72 of file IdString.h.
unsigned zypp::IdString::size | ( | ) | const |
The strings size.
Definition at line 39 of file IdString.cc.
const char * zypp::IdString::c_str | ( | ) | const |
Conversion to const char *
Definition at line 42 of file IdString.cc.
|
inline |
Conversion to std::string
Definition at line 83 of file IdString.h.
|
inline |
Fast compare equal.
Definition at line 88 of file IdString.h.
int zypp::IdString::compare | ( | const IdString & | rhs | ) | const |
Compare IdString returning -1,0,1
.
Definition at line 45 of file IdString.cc.
int zypp::IdString::compare | ( | const char * | rhs | ) | const |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 57 of file IdString.cc.
|
inline |
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.
Definition at line 98 of file IdString.h.
|
inline |
Expert backdoor.
Definition at line 103 of file IdString.h.
|
related |
Stream output
Definition at line 72 of file IdString.cc.
|
related |
Stream output
Definition at line 77 of file IdString.cc.
Equal
Definition at line 118 of file IdString.h.
NotEqual
Definition at line 134 of file IdString.h.
Less
Definition at line 150 of file IdString.h.
LessEqual
Definition at line 166 of file IdString.h.
Greater
Definition at line 182 of file IdString.h.
GreaterEqual
Definition at line 198 of file IdString.h.
|
static |
No or Null string ( Id 0
).
Definition at line 59 of file IdString.h.
|
static |
Empty string.
Definition at line 62 of file IdString.h.
|
private |
Definition at line 107 of file IdString.h.