Class SearchIterator.Search

  • Enclosing class:
    SearchIterator

    final class SearchIterator.Search
    extends java.lang.Object
    Java port of ICU4C struct USearch (usrchimp.h) Note: ICU4J already exposed some protected members such as targetText, breakIterator and matchedLength as a part of stable APIs. In ICU4C, they are exposed through USearch struct, although USearch struct itself is internal API. This class was created for making ICU4J code parallel to ICU4C implementation. ICU4J implementation access member fields like C struct (e.g. search_.isOverlap_) mostly, except fields already exposed as protected member (e.g. search_.text()).
    • Field Detail

      • isOverlap_

        boolean isOverlap_
        Flag to indicate if overlapping search is to be done. E.g. looking for "aa" in "aaa" will yield matches at offset 0 and 1.
      • isCanonicalMatch_

        boolean isCanonicalMatch_
      • matchedIndex_

        int matchedIndex_
      • isForwardSearching_

        boolean isForwardSearching_
        Flag indicates if we are doing a forwards search
      • reset_

        boolean reset_
        Flag indicates if we are at the start of a string search. This indicates that we are in forward search and at the start of m_text.
    • Constructor Detail

      • Search

        Search()
    • Method Detail

      • text

        java.text.CharacterIterator text()
      • setTarget

        void setTarget​(java.text.CharacterIterator text)
      • matchedLength

        int matchedLength()
      • setMatchedLength

        void setMatchedLength​(int matchedLength)
      • beginIndex

        int beginIndex()
      • endIndex

        int endIndex()