fst-0.10.0.0: Finite state transducers

Safe HaskellSafe-Inferred

FST.AutomatonTypes

Contents

Description

Types for Automaton

Synopsis

Types

type StateTy = IntSource

A state

type FirstState = IntSource

First state

type LastState = IntSource

Last state

type InitialStates = [StateTy]Source

Initial states

type FinalStates = [StateTy]Source

Final states

type Transitions a = [(a, StateTy)]Source

Transitions

type TransitionTable a = [(StateTy, Transitions a)]Source

Table of transitions

type Sigma a = [a]Source

The alphabet of an automaton

Type class

class AutomatonFunctions f whereSource

Class of AutomatonFunctions

Methods

states :: f a -> [StateTy]Source

Get the states of an automaton

isFinal :: f a -> StateTy -> BoolSource

Is the given state a final state?

finals :: f a -> FinalStatesSource

Get the final states of an automaton

initials :: f a -> InitialStatesSource

Get the initial states of an automaton

transitionList :: f a -> StateTy -> Transitions aSource

Get the transitions w.r.t. a state

transitionTable :: f a -> TransitionTable aSource

Get the transitionTable

transitions :: Eq a => f a -> (StateTy, a) -> [StateTy]Source

Get the transitions w.r.t. a state and a symbol

firstState :: Eq a => f a -> StateTySource

Get the first state of a automaton

lastState :: Eq a => f a -> StateTySource

Get the last state of a automaton

alphabet :: f a -> Sigma aSource

Get the alphabet of an automaton

Instances

AutomatonFunctions Automaton

Instance of AutomatonFunctions

AutomatonFunctions LBFA