Package com.ibm.icu.impl

Examples of com.ibm.icu.impl.UnicodeSetStringSpan


        }
      }

      // Optimize contains() and span() and similar functions.
      if (!strings.isEmpty()) {
        stringSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), UnicodeSetStringSpan.ALL);
        if (!stringSpan.needsStringSpanUTF16()) {
          // All strings are irrelevant for span() etc. because
          // all of each string's code points are contained in this set.
          // Do not check needsStringSpanUTF8() because UTF-8 has at most as
          // many relevant strings as UTF-16.
View Full Code Here


    if (stringSpan != null) {
      return start + stringSpan.span(s, start, len, spanCondition);
    } else if (!strings.isEmpty()) {
      int which = spanCondition == SpanCondition.NOT_CONTAINED ? UnicodeSetStringSpan.FWD_UTF16_NOT_CONTAINED
          : UnicodeSetStringSpan.FWD_UTF16_CONTAINED;
      UnicodeSetStringSpan strSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), which);
      if (strSpan.needsStringSpanUTF16()) {
        return start + strSpan.span(s, start, len, spanCondition);
      }
    }

    // Pin to 0/1 values.
    boolean spanContained = (spanCondition != SpanCondition.NOT_CONTAINED);
View Full Code Here

    if (stringSpan != null) {
      return stringSpan.spanBack(s, fromIndex, spanCondition);
    } else if (!strings.isEmpty()) {
      int which = (spanCondition == SpanCondition.NOT_CONTAINED) ? UnicodeSetStringSpan.BACK_UTF16_NOT_CONTAINED
          : UnicodeSetStringSpan.BACK_UTF16_CONTAINED;
      UnicodeSetStringSpan strSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), which);
      if (strSpan.needsStringSpanUTF16()) {
        return strSpan.spanBack(s, fromIndex, spanCondition);
      }
    }

    // Pin to 0/1 values.
    boolean spanContained = (spanCondition != SpanCondition.NOT_CONTAINED);
View Full Code Here

                }
            }

            // Optimize contains() and span() and similar functions.
            if (!strings.isEmpty()) {
                stringSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), UnicodeSetStringSpan.ALL);
                if (!stringSpan.needsStringSpanUTF16()) {
                    // All strings are irrelevant for span() etc. because
                    // all of each string's code points are contained in this set.
                    // Do not check needsStringSpanUTF8() because UTF-8 has at most as
                    // many relevant strings as UTF-16.
View Full Code Here

        if (stringSpan != null) {
            return start + stringSpan.span(s, start, len, spanCondition);
        } else if (!strings.isEmpty()) {
            int which = spanCondition == SpanCondition.NOT_CONTAINED ? UnicodeSetStringSpan.FWD_UTF16_NOT_CONTAINED
                    : UnicodeSetStringSpan.FWD_UTF16_CONTAINED;
            UnicodeSetStringSpan strSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), which);
            if (strSpan.needsStringSpanUTF16()) {
                return start + strSpan.span(s, start, len, spanCondition);
            }
        }

        // Pin to 0/1 values.
        boolean spanContained = (spanCondition != SpanCondition.NOT_CONTAINED);
View Full Code Here

            return stringSpan.spanBack(s, fromIndex, spanCondition);
        } else if (!strings.isEmpty()) {
            int which = (spanCondition == SpanCondition.NOT_CONTAINED)
                    ? UnicodeSetStringSpan.BACK_UTF16_NOT_CONTAINED
                    : UnicodeSetStringSpan.BACK_UTF16_CONTAINED;
            UnicodeSetStringSpan strSpan = new UnicodeSetStringSpan(this, new ArrayList<String>(strings), which);
            if (strSpan.needsStringSpanUTF16()) {
                return strSpan.spanBack(s, fromIndex, spanCondition);
            }
        }

        // Pin to 0/1 values.
        boolean spanContained = (spanCondition != SpanCondition.NOT_CONTAINED);
View Full Code Here

TOP

Related Classes of com.ibm.icu.impl.UnicodeSetStringSpan

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.