UnindexedEdgeAnnotatedNFA

Methods for builders of a deterministic finite automaton.

Type Params
D

Type of DFA constructed by this NFA.

G

Collection type constructor for states in constructed DFAs.

S

Type representing states.

T

Type representing transition labels.

Z

Type of style options for Graphviz export

trait UnindexedNFA[S, T, G, D, NZ, DZ]
trait UnindexedFA[S, T, NZ]
trait Pretty
trait Graphable[S, T, NZ]
class Object
trait Matchable
class Any

Value members

Inherited methods

def accepts(string: Seq[T]): Boolean

Returns true if this automaton accepts the given string.

Returns true if this automaton accepts the given string.

Inherited from
UnindexedFA
def annotated(src: S, label: T, dest: S): Boolean

Check whether there is an annotation on the transition from src to dest labelled label.

Check whether there is an annotation on the transition from src to dest labelled label.

Inherited from
UnindexedEdgeAnnotatedFA
def annotation(src: S, label: T, dest: S): Option[NA]

Return the annotation (if any) on the transition from src to dest labelled label.

Return the annotation (if any) on the transition from src to dest labelled label.

Inherited from
UnindexedEdgeAnnotatedFA
def eAnnotated(src: S, dest: S): Boolean

Check whether there is an annotation on the unlabeled transition from src to dest. For automata without e-transitions, this method will always return false.

Check whether there is an annotation on the unlabeled transition from src to dest. For automata without e-transitions, this method will always return false.

Inherited from
UnindexedEdgeAnnotatedFA
def eAnnotation(src: S, dest: S): Option[NA]

Return the annotation (if any) on the e-transition from src to dest. For automata without e-transitions, this method will always return None.

Return the annotation (if any) on the e-transition from src to dest. For automata without e-transitions, this method will always return None.

Inherited from
UnindexedEdgeAnnotatedFA

Return the pairs comprising all unlabelled transitions.

Return the pairs comprising all unlabelled transitions.

Inherited from
UnindexedFA
def eTransitions(s: S): Set[S]

Return the set of states at the end of an epsilon transition from s.

Return the set of states at the end of an epsilon transition from s.

Inherited from
UnindexedNFA

Returns the Set of final states in this automaton.

Returns the Set of final states in this automaton.

Inherited from
UnindexedFA
def foreachETransition(action: (S, S) => Unit { def apply(s1: S, s2: S): Unit; }): Unit

Perform some action for each epsilon transition in the automaton.

Perform some action for each epsilon transition in the automaton.

Inherited from
UnindexedNFA
def foreachEdgeAnnotation(action: (S, S, NA) => Any): Unit

Perform an action for every annotated unlabelled edge in this automaton.

Perform an action for every annotated unlabelled edge in this automaton.

Inherited from
UnindexedEdgeAnnotatedFA
def foreachEdgeAnnotation(action: (S, T, S, NA) => Any): Unit

Perform an action for every annotated labelled edge in this automaton.

Perform an action for every annotated labelled edge in this automaton.

Inherited from
UnindexedEdgeAnnotatedFA
def foreachFinalState(action: S => Unit { def apply(s: S): Unit; }): Unit

Perform some action for each final state in the automaton.

Perform some action for each final state in the automaton.

Inherited from
UnindexedFA
def foreachInitialState(action: S => Unit { def apply(s: S): Unit; }): Unit

Perform some action for each initial state in the automaton.

Perform some action for each initial state in the automaton.

Inherited from
UnindexedFA
def foreachState(action: S => Unit { def apply(s: S): Unit; }): Unit

Perform some action for each state in the automaton.

Perform some action for each state in the automaton.

Inherited from
UnindexedFA
def foreachTransition(action: (S, T, S) => Unit { def apply(s1: S, t: T, s2: S): Unit; }): Unit

Perform some action for each transition in the automaton.

Perform some action for each transition in the automaton.

Inherited from
UnindexedFA
def graphviz(sourceFile: String, outputFile: String)(using options: NZ[S, T, NA]): Unit

Use Graphviz to render this object as specified.

Use Graphviz to render this object as specified.

Inherited from
Graphable
def graphviz(fileRoot: String)(using options: NZ[S, T, NA]): Unit

Use Graphviz to render this object (in the default format) to the given file.

Use Graphviz to render this object (in the default format) to the given file.

Inherited from
Graphable

Returns the Set of initial states in this automaton.

Returns the Set of initial states in this automaton.

Inherited from
UnindexedFA

Returns whether the given state s is final in this automaton.

Returns whether the given state s is final in this automaton.

Inherited from
UnindexedFA

Returns whether the given state s is initial in this automaton.

Returns whether the given state s is initial in this automaton.

Inherited from
UnindexedFA
def isState(s: S): Boolean

Returns true if s is used as a state

Returns true if s is used as a state

Inherited from
UnindexedFA

Set of automaton transition labels

Set of automaton transition labels

Inherited from
UnindexedFA
def map[S2, T2](stateMap: S => S2, transitionMap: T => T2): UnindexedFA[S2, T2, NZ]

Derive a new isomorphic automaton from this one by applying transforms to the states and transitions. This method does not check that either map is injective: if they are not, then the result may be unpredictable.

Derive a new isomorphic automaton from this one by applying transforms to the states and transitions. This method does not check that either map is injective: if they are not, then the result may be unpredictable.

Inherited from
UnindexedFA
def mapStates[S2](stateMap: S => S2): UnindexedFA[S2, T, NZ]

Derive a new isomorphic automaton from this one by applying transforms to the states. This method does not check that the stateMap is injective: if it is not, then the result may have separate states which cannot be distinguished.

Derive a new isomorphic automaton from this one by applying transforms to the states. This method does not check that the stateMap is injective: if it is not, then the result may have separate states which cannot be distinguished.

Inherited from
UnindexedFA
def mapTransitions[T2](transitionMap: T => T2): UnindexedFA[S, T2, NZ]

Derive a new isomorphic automaton from this one by applying transforms to the transitions. This method does not check that the transitionMap is injective: if it is not, then the result may have separate transitions which cannot be distinguished.

Derive a new isomorphic automaton from this one by applying transforms to the transitions. This method does not check that the transitionMap is injective: if it is not, then the result may have separate transitions which cannot be distinguished.

Inherited from
UnindexedFA
def pretty: Doc
Inherited from
Pretty
def size: Int

Number of states in the automaton

Number of states in the automaton

Inherited from
UnindexedFA

The states themselves

The states themselves

Inherited from
UnindexedFA
def toDFA: D[G[S], T, DA]

Return the specified DFA.

Return the specified DFA.

Inherited from
UnindexedNFA
def toDOT(using graphvizOptions: NZ[S, T, NA]): String

Return the inner lines of a digraph block (or other Graphviz style) to render this object.

Return the inner lines of a digraph block (or other Graphviz style) to render this object.

Inherited from
Graphable

Return the triples comprising all labelled transitions.

Return the triples comprising all labelled transitions.

Inherited from
UnindexedFA
def transitions(s: S, t: T): Set[S]

Returns the (possibly empty, and in deterministic implementations at most singleton) set of states into which the automaton could transition starting from s via a transition labelled t.

Returns the (possibly empty, and in deterministic implementations at most singleton) set of states into which the automaton could transition starting from s via a transition labelled t.

Inherited from
UnindexedFA