Interface RegexMatchHandler


public interface RegexMatchHandler
Interface defining a call-back action for processing captured groups within a regular expression
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Method to be called with each fragment of text in a matching substring
    void
    onGroupEnd(int groupNumber)
    Method to be called when the end of a captured group is encountered
    void
    onGroupStart(int groupNumber)
    Method to be called when the start of a captured group is encountered
    void
    onLookaheadGroup(int groupNumber, int position, UnicodeString value)
    Method to be called when a lookahead captured group is encountered
  • Method Details

    • characters

      void characters(UnicodeString s) throws XPathException
      Method to be called with each fragment of text in a matching substring
      Parameters:
      s - a matching substring, or part thereof that falls within a specific group
      Throws:
      XPathException
    • onGroupStart

      void onGroupStart(int groupNumber) throws XPathException
      Method to be called when the start of a captured group is encountered
      Parameters:
      groupNumber - the group number of the captured group
      Throws:
      XPathException
    • onGroupEnd

      void onGroupEnd(int groupNumber) throws XPathException
      Method to be called when the end of a captured group is encountered
      Parameters:
      groupNumber - the group number of the captured group
      Throws:
      XPathException
    • onLookaheadGroup

      void onLookaheadGroup(int groupNumber, int position, UnicodeString value) throws XPathException
      Method to be called when a lookahead captured group is encountered
      Parameters:
      groupNumber - the group number of the captured group
      position - the position within the input string of the captured group
      value - the captured substring
      Throws:
      XPathException