Class RegexSupport

java.lang.Object
org.codehaus.groovy.runtime.RegexSupport

public class RegexSupport extends Object
Used to store the last regex match.
  • Constructor Details

    • RegexSupport

      public RegexSupport()
  • Method Details

    • getLastMatcher

      public static Matcher getLastMatcher()
      Returns the matcher saved for the current thread.
      Returns:
      that matcher, or null when this thread has not saved one
    • setLastMatcher

      public static void setLastMatcher(Matcher matcher)
      Saves matcher as the last match on the current thread. Another thread keeps its own matcher. Passing null makes getLastMatcher() return null.
      Parameters:
      matcher - matcher to store, or null to clear this thread's match