Auxiliary class to specify white space character(s) in currect locale.
More...
#include <JWhiteSpacesFacet.hh>
|
typedef std::ctype< char > | ctype |
|
|
ctype::mask | mask_set [ctype::table_size] |
|
Auxiliary class to specify white space character(s) in currect locale.
Definition at line 35 of file JWhiteSpacesFacet.hh.
JLANG::JWhiteSpacesFacet::JWhiteSpacesFacet |
( |
const std::locale & |
loc, |
|
|
const char |
ws |
|
) |
| |
|
inline |
Constructor.
- Parameters
-
loc | current locale |
ws | white space character |
Definition at line 46 of file JWhiteSpacesFacet.hh.
ctype::mask mask_set[ctype::table_size]
void configure(const std::locale &loc, const std::string &ws)
Configure.
Auxiliary class to ensure that the mask set is defined prior to the ctype<>() constructor call...
JLANG::JWhiteSpacesFacet::JWhiteSpacesFacet |
( |
const std::locale & |
loc, |
|
|
const std::string & |
ws |
|
) |
| |
|
inline |
Constructor.
- Parameters
-
loc | current locale |
ws | white space character(s) |
Definition at line 61 of file JWhiteSpacesFacet.hh.
ctype::mask mask_set[ctype::table_size]
void configure(const std::locale &loc, const std::string &ws)
Configure.
Auxiliary class to ensure that the mask set is defined prior to the ctype<>() constructor call...
void JLANG::JWhiteSpacesFacet::configure |
( |
const std::locale & |
loc, |
|
|
const std::string & |
ws |
|
) |
| |
|
inlineprivate |
Configure.
- Parameters
-
loc | current locale |
ws | white space character(s) |
Definition at line 76 of file JWhiteSpacesFacet.hh.
81 char buffer[table_size];
83 for (
unsigned int i = 0;
i != table_size; ++
i) {
87 use_facet<JMask::ctype>(
loc).
is(buffer, buffer + table_size,
mask_set);
89 for (
unsigned int i = 0;
i != table_size; ++
i) {
95 for (string::const_iterator
i = ws.begin();
i != ws.end(); ++
i) {
96 mask_set[(int) *
i] |= JMask::ctype::space;
ctype::mask mask_set[ctype::table_size]
ctype::mask JLANG::JMask::mask_set[ctype::table_size] |
|
protectedinherited |
The documentation for this class was generated from the following file: