Logo Search packages:      
Sourcecode: icu version File versions

void RuleBasedCollator::construct ( const UnicodeString rules,
UColAttributeValue  collationStrength,
UColAttributeValue  decompositionMode,
UErrorCode status 
) [private]

common constructor implementation

rulesthe collation rules to build the collation table from.
collationStrengthdefault strength for comparison
decompositionModethe normalisation mode
statusreporting a success or an error.

Definition at line 157 of file tblcoll.cpp.

References FALSE, UnicodeString::getBuffer(), UnicodeString::length(), NULL, TRUE, U_MEMORY_ALLOCATION_ERROR, U_SUCCESS, and ucollator.

Referenced by RuleBasedCollator().

    ucollator = ucol_openRules(rules.getBuffer(), rules.length(),
        decompositionMode, collationStrength,
        NULL, &status);

    dataIsOwned = TRUE; // since we own a collator now, we need to get rid of it
    isWriteThroughAlias = FALSE;

    if(ucollator == NULL) {
        if(U_SUCCESS(status)) {
            status = U_MEMORY_ALLOCATION_ERROR;
        return; // Failure


Here is the call graph for this function:

Here is the caller graph for this function:

Generated by  Doxygen 1.6.0   Back to index