Class HTMLNamedEntitiesParser.RootState

java.lang.Object
org.htmlunit.cyberneko.HTMLNamedEntitiesParser.State
org.htmlunit.cyberneko.HTMLNamedEntitiesParser.RootState
Enclosing class:
HTMLNamedEntitiesParser

protected static class HTMLNamedEntitiesParser.RootState extends HTMLNamedEntitiesParser.State
This is our initial state and has a special optimization applied. We don't iterate, we jump by character code to the position.
  • Field Details

    • offset_

      private int offset_
  • Constructor Details

    • RootState

      protected RootState()
  • Method Details

    • lookup

      public HTMLNamedEntitiesParser.State lookup(int character)
      Description copied from class: HTMLNamedEntitiesParser.State
      Lookup the state by iterating over the chars at this state, should not be that many and due to the small size of the array, should be cache only
      Overrides:
      lookup in class HTMLNamedEntitiesParser.State
      Parameters:
      character - the char to look up
      Returns:
      the next state or the same in case the character was not found
    • optimize

      protected void optimize()