Logo Search packages:      
Sourcecode: icu version File versions  Download package

UnicodeSet::UnicodeSet ( const UnicodeString pattern,
ParsePosition pos,
uint32_t  options,
const SymbolTable symbols,
UErrorCode status 
)

Constructs a set from the given pattern. See the class description for the syntax of the pattern language.

Parameters:
pattern a string specifying what characters are in the set
pos on input, the position in pattern at which to start parsing. On output, the position after the last character parsed.
options bitmask for options to apply to the pattern. Valid options are USET_IGNORE_SPACE and USET_CASE_INSENSITIVE.
symbols a symbol table mapping variable names to values and stand-in characters to UnicodeSets; may be NULL
status input-output error code ICU 2.8

Definition at line 370 of file uniset_props.cpp.

References allocateStrings(), applyPattern(), NULL, U_MEMORY_ALLOCATION_ERROR, and U_SUCCESS.

                                           :
    len(0), capacity(START_EXTRA), list(0), bmpSet(0), buffer(0),
    bufferCapacity(0), patLen(0), pat(NULL), strings(NULL), stringSpan(NULL),
    fFlags(0)
{
    if(U_SUCCESS(status)){
        list = (UChar32*) uprv_malloc(sizeof(UChar32) * capacity);
        /* test for NULL */
        if(list == NULL) {
            status = U_MEMORY_ALLOCATION_ERROR;   
        }else{
            allocateStrings(status);
            applyPattern(pattern, pos, options, symbols, status);
        }
    }
    _dbgct(this);
}


Generated by  Doxygen 1.6.0   Back to index