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

UBool UnicodeSet::containsNone ( const UnicodeSet c  )  const

Returns true if this set contains none of the characters and strings of the given set.

Parameters:
c set to be checked for containment
Returns:
true if the test condition is met ICU 2.4
Returns true if this set contains none of the characters and strings of the given set.
Parameters:
c set to be checked for containment
Returns:
true if the test condition is met

Definition at line 551 of file uniset.cpp.

References UVector::containsNone(), containsNone(), FALSE, getRangeCount(), getRangeEnd(), getRangeStart(), strings, and TRUE.

                                                        {
    // The specified set is a subset if all of its pairs are contained in
    // this set.  It's possible to code this more efficiently in terms of
    // direct manipulation of the inversion lists if the need arises.
    int32_t n = c.getRangeCount();
    for (int32_t i=0; i<n; ++i) {
        if (!containsNone(c.getRangeStart(i), c.getRangeEnd(i))) {
            return FALSE;
        }
    }
    if (!strings->containsNone(*c.strings)) return FALSE;
    return TRUE;
}


Generated by  Doxygen 1.6.0   Back to index