#include <string.h>
static_container::string< MaxStrLen, Ch, ChTraits >のコラボレーション図
Public 型 | |
typedef Ch | char_type |
typedef ChTraits | traits_type |
typedef pointer | iterator |
typedef const_pointer | const_iterator |
Public メソッド | |
BOOST_STATIC_CONSTANT (size_type, npos=-1) | |
最大サイズ | |
BOOST_STATIC_CONSTANT (size_type, const_max=MaxStrLen) | |
size_type | size () const |
サイズ取得 | |
size_type | length () const |
サイズ取得 | |
iterator | begin () |
const_iterator | begin () const |
iterator | end () |
const_iterator | end () const |
char_type & | operator[] (size_type i) |
const char_type & | operator[] (size_type i) const |
bool | empty () const |
reference | at (size_type i) |
char_type | at (size_type i) const |
reference | front () |
char_type | front () const |
reference | back () |
char_type | back () const |
void | push_back (char_type ch) |
一文字追加 | |
void | append (char_type ch) |
一文字追加 | |
void | append (const char *str) |
文字列を末尾に追加 | |
template<size_type OtherMaxStrLen> void | append (const string< OtherMaxStrLen, Ch, ChTraits > &other) |
文字列を末尾に追加 | |
void | pop_back () |
一文字削除 | |
string () | |
デフォルトコンストラクタ | |
template<size_type OtherMaxStrLen> | string (const string< OtherMaxStrLen, Ch, ChTraits > &other) |
コピーコンストラクタ | |
string (const char_type *s) | |
~string () | |
string & | operator= (const string &other) |
代入演算子 | |
string & | operator= (const char_type *s) |
const_pointer | c_str () const |
直アクセス | |
string | operator+= (const char *other) |
append() と同じです | |
template<size_type OtherMaxStrLen> string | operator+= (const string< OtherMaxStrLen, Ch, ChTraits > &other) |
append() と同じです | |
void | clear () |
空文字列化 | |
Static Public メソッド | |
size_type | max_size () |
最大サイズ取得 | |
size_type | capaciry () |
容量取得 | |
Private 変数 | |
Ch | buffer_ [MaxStrLen+1] |
フレンド | |
template<size_type OtherMaxStrLen> bool | operator== (const string &a, const string< OtherMaxStrLen, Ch, ChTraits > &b) |
等しい? | |
bool | operator== (const string &a, const char *b) |
等しい? | |
bool | operator== (const char *a, const string &b) |
等しい? | |
template<size_type OtherMaxStrLen> bool | operator!= (const string &a, const string< OtherMaxStrLen, Ch, ChTraits > &b) |
異なる? | |
bool | operator!= (const string &a, const char *b) |
異なる? | |
bool | operator!= (const char *a, const string &b) |
異なる? | |
template<size_type OtherMaxStrLen> bool | operator< (const string &a, const string< OtherMaxStrLen, Ch, ChTraits > &b) |
辞書順比較 | |
bool | operator< (const string &a, const char *b) |
辞書順比較 | |
bool | operator< (const char *a, const string &b) |
辞書順比較 |
内部的には、Ch[ MaxStrLen + 1 ] のみを利用する。
|
|
|
|
|
|
|
|
デフォルトコンストラクタ
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::clear().
00104 { 00105 clear(); 00106 } |
|
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::char_type, と static_container::string< MaxStrLen, Ch, ChTraits >::max_size().
|
|
00125 { 00126 } |
|
文字列を末尾に追加
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::append(), と static_container::string< MaxStrLen, Ch, ChTraits >::c_str().
00091 { 00092 append( other.c_str() ); 00093 } |
|
|
|
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::operator[](), と static_container::size_type.
00061 { return operator [] ( i ); } |
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::char_type, と static_container::string< MaxStrLen, Ch, ChTraits >::end().
00067 { return *( end() - 1 ); } |
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::end().
00066 { return *( end() - 1 ); } |
|
00046 { return buffer_; } |
|
|
|
|
最大サイズ
|
|
|
容量取得
参照先 static_container::size_type.
00037 { return const_max; }
|
|
空文字列化
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::char_type. 参照元 static_container::string< MaxStrLen, Ch, ChTraits >::string().
|
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::size(). 参照元 static_container::string< MaxStrLen, Ch, ChTraits >::pop_back().
00058 { 00059 return 0 == size(); 00060 } |
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::begin(), と static_container::string< MaxStrLen, Ch, ChTraits >::size().
|
|
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::begin(), と static_container::string< MaxStrLen, Ch, ChTraits >::char_type.
00065 { return *begin(); } |
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::begin().
00064 { return *begin(); } |
|
サイズ取得
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::size(), と static_container::size_type.
00043 { return size(); } |
|
|
append() と同じです
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::append().
00151 { 00152 append( other ); 00153 return *this; 00154 } |
|
append() と同じです
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::append().
00144 { 00145 append( other ); 00146 return *this; 00147 } |
|
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::char_type, と static_container::string< MaxStrLen, Ch, ChTraits >::max_size().
|
|
代入演算子
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::c_str().
00129 { 00130 return operator = ( other.c_str() ); 00131 } |
|
|
|
一文字削除
参照先 static_container::string< MaxStrLen, Ch, ChTraits >::char_type, static_container::string< MaxStrLen, Ch, ChTraits >::empty(), と static_container::string< MaxStrLen, Ch, ChTraits >::end().
|
|
|
|
異なる?
00191 { 00192 return !operator == ( a, b ); 00193 } |
|
異なる?
00186 { 00187 return !operator == ( a, b ); 00188 } |
|
異なる?
00181 { 00182 return !operator == ( a, b ); 00183 } |
|
辞書順比較
00210 { 00211 return operator < ( b, a ); 00212 } |
|
辞書順比較
00202 {
00203 return std::lexicographical_compare(
00204 a.begin(), a.end(),
00205 b, b + traits_type::length( b ),
00206 traits_type::eq_int_type );
00207 }
|
|
辞書順比較
00197 { 00198 return operator < ( a, b.c_str() ); 00199 } |
|
等しい?
00175 { 00176 return operator == ( b, a ); 00177 } |
|
等しい?
|
|
等しい?
00163 { 00164 return operator == ( a, b.c_str() ); 00165 } |
|
|