Class AttributeFinder

java.lang.Object
icyllis.modernui.resources.AttributeFinder

public abstract class AttributeFinder extends Object
Provides linear search for sorted needle array (attributes we're looking for) in the sorted haystack array (the attributes we're searching through).
  • Field Details

    • haystackNamespace

      protected String haystackNamespace
    • haystackAttribute

      protected String haystackAttribute
  • Constructor Details

    • AttributeFinder

      public AttributeFinder()
  • Method Details

    • onGetAttribute

      protected abstract void onGetAttribute(int index)
      Override to update haystackNamespace and haystackAttribute.
    • reset

      public void reset(int start, int end)
      Called before the search starts.
    • clear

      public void clear()
      Called after the search ends.
    • find

      public int find(@NonNull String namespace, @NonNull String attribute)