HappyDoc Generated Documentation Class: FSA

fsa.py / FSA 

Methods   
  nextStates 
nextStates (
        self,
        state,
        input,
        )
  makeStateTable 
makeStateTable ( self,  default=None )

Initialization

  tuple 
tuple ( self )
  collectStates 
collectStates (
        self,
        transitions,
        initialState,
        finalStates,
        )
  complement 
complement ( self )

FSA operations

  labels 
labels ( self )

Returns a list of transition labels.

  determinized 
determinized ( self )

Returns a deterministic FSA that accepts the same language.

  minimized 
minimized ( self )

Returns a minimal FSA that accepts the same language.

  initializeTransitionTables 
initializeTransitionTables ( self )
  coerce 
coerce ( self,  klass )
  hasArcMetadata 
hasArcMetadata ( self )

Arc Metadata Accessors

  __str__ 
__str__ ( self )
  stateLabelString 
stateLabelString ( self,  state )

A template method for specifying a state's label, for use in dot diagrams. If this returns None, the default (the string representation of the state) is used.

  labelMatches 
labelMatches (
        self,
        label,
        input,
        )

Accepting

  computeEpsilonClosure 
computeEpsilonClosure ( self,  state )
  sorted 
sorted ( self,  initial=0 )

Reductions

  copy 
copy ( self,  *args )
  addArcMetadataFor 
addArcMetadataFor (
        self,
        transition,
        data,
        )
  __init__ 
__init__ (
        self,
        states,
        alphabet,
        transitions,
        initialState,
        finalStates,
        arcMetadata=[],
        )
  getArcMetadata 
getArcMetadata ( self )
  setArcMetadataFor 
setArcMetadataFor (
        self,
        transition,
        data,
        )
  withoutEpsilons 
withoutEpsilons ( self )
  addArcMetadata 
addArcMetadata ( self,  list )
  epsilonClosure 
epsilonClosure ( self,  state )

Accessors

  additionalTransitionInfoString 
additionalTransitionInfoString ( self,  transition )
  create 
create ( self,  *args )

Copying

  isEmpty 
isEmpty ( self )

Predicates

  accepts 
accepts ( self,  sequence )
  getArcMetadataFor 
getArcMetadataFor (
        self,
        transition,
        default=None,
        )
  nextState 
nextState (
        self,
        state,
        input,
        )
  trimmed 
trimmed ( self )

Returns an equivalent FSA that doesn't include unreachable states, or states that only lead to dead states.

  isFSA 
isFSA ( self )
  creationArgs 
creationArgs ( self )
  __repr__ 
__repr__ ( self )

Presentation Methods

  setArcMetadata 
setArcMetadata ( self,  list )
  nextAvailableState 
nextAvailableState ( self )
  computeEpsilonClosures 
computeEpsilonClosures ( self )
  view 
view ( self )
  nextStateSet 
nextStateSet (
        self,
        states,
        input,
        )
  toDotString 
toDotString ( self )

Returns a string that can be printed by the DOT tool at http://www.research.att.com/sw/tools/graphviz/ .

  transitionsFrom 
transitionsFrom ( self,  state )

This document was automatically generated Thu Jul 29 13:55:23 2004 by HappyDoc version 3.0.a1