Class ScopeInfo


  • public final class ScopeInfo
    extends java.lang.Object
    information about a scope
    • Field Detail

      • _scope

        public final Scope _scope
        Scope object to which this object is attached.
    • Method Detail

      • iterateNSURIConstants

        public java.util.Iterator iterateNSURIConstants()
      • getInitialState

        public State getInitialState()
      • setInitialState

        public void setInitialState​(State s)
      • isNullable

        public boolean isNullable()
      • setNullable

        public void setNullable​(boolean v)
      • getStateCount

        public int getStateCount()
      • getClassName

        public java.lang.String getClassName()
      • getConstructorParams

        public Alias[] getConstructorParams()
      • minimizeStates

        public void minimizeStates()
        Makes the automaton smaller. In actuality, this method only removes unreachable states.
      • appendHeaderSection

        public void appendHeaderSection​(java.lang.String c)
      • getHeaderSection

        public java.lang.String getHeaderSection()
      • isUserDefinedField

        public boolean isUserDefinedField​(java.lang.String name)
      • iterateActions

        public java.util.Iterator iterateActions()
      • createAction

        public ScopeInfo.Action createAction​(java.lang.String code)
        Creates a new Action object inside this _scope.
      • createAction

        public ScopeInfo.Action createAction​(java.lang.StringBuffer code)
      • iterateAliases

        public final java.util.Iterator iterateAliases()
        Iterate all the aliases.
      • simplifyAutomaton

        public void simplifyAutomaton()
      • addNSURI

        public void addNSURI​(java.lang.String nsuri)
      • getNSStringConstant

        public java.lang.String getNSStringConstant​(java.lang.String uri)
      • iterateStatesHaving

        public java.util.Iterator iterateStatesHaving​(int alphabetTypes)
        Iterates states that have transitions with one of specified alphabets.
      • iterateAcceptableStates

        public java.util.Iterator iterateAcceptableStates()
      • iterateAllStates

        public java.util.Iterator iterateAllStates()
      • addState

        public void addState​(State state)
      • addAlias

        public Alias addAlias​(CDType type,
                              java.lang.String name)
      • isRoot

        public boolean isRoot()
        Returns true if this is the start pattern.
      • dump

        public void dump​(java.io.PrintStream strm)
      • dumpAutomaton

        public void dumpAutomaton​(java.io.File target)
                           throws java.io.IOException,
                                  java.lang.InterruptedException
        Writes the automaton by using GraphViz.
        Throws:
        java.io.IOException
        java.lang.InterruptedException
      • head

        public void head​(java.util.Set result)
        Computes the HEAD set of this _scope (that doesn't include EVERYTHING_ELSE token.) See Head for the definition.
      • head

        public java.util.Set head()
        Computes the HEAD set of this _scope (that doesn't include EVERYTHING_ELSE token) and returns them in a new set.
      • calcAFOLLOW

        public void calcAFOLLOW()
        Computes the AFOLLOW set of this _scope