Class DOTParsers
- java.lang.Object
-
- net.automatalib.serialization.dot.DOTParsers
-
public final class DOTParsers extends Object
An aggregation of factory methods for obtaining DOT parsers for several types of automata / graphs.
-
-
Field Summary
Fields Modifier and Type Field Description static Function<Map<String,String>,@Nullable String>DEFAULT_EDGE_PARSERstatic Function<Map<String,String>,Boolean>DEFAULT_FSA_NODE_PARSERNode property parser that returnstrueif a node's "shape" attribute is specified and equals "doublecircle".static Function<Map<String,String>,Pair<@Nullable String,@Nullable String>>DEFAULT_MEALY_EDGE_PARSEREdge input parser that expects an edge's "label" attribute to be of the form<input>/<property>.static Function<Map<String,String>,@Nullable String>DEFAULT_MOORE_NODE_PARSERNode property parser that expects a node's "label" attribute to be of the form<id>/<property>.static Function<Map<String,String>,MutableModalEdgeProperty>DEFAULT_MTS_EDGE_PARSEREdge input parser that parses an edge'smodalityattribute and constructs a correspondingMutableModalEdgeProperty.static Function<Map<String,String>,@Nullable String>DEFAULT_NODE_PARSER
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static DOTInputModelDeserializer<Integer,@Nullable String,CompactDFA<@Nullable String>>dfa()Default parser forDFAs serialized by AutomataLib.static <I> DOTInputModelDeserializer<Integer,I,CompactDFA<I>>dfa(Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)Parser forDFAs with custom node and edge attributes.static <S,I,A extends MutableFSA<S,I>>
DOTInputModelDeserializer<S,I,A>fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)Parser forFiniteStateAcceptors with a custom automaton instance and custom node and edge attributes.static <S,I,A extends MutableFSA<S,I>>
DOTInputModelDeserializer<S,I,A>fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser, Collection<String> initialNodeIds)Parser forFiniteStateAcceptors with a custom automaton instance, custom node and edge attributes and custom labels for the initial nodes.static <S,I,A extends MutableFSA<S,I>>
DOTInputModelDeserializer<S,I,A>fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser, Collection<String> initialNodeIds, boolean fakeInitialNodeIds)Parser forFiniteStateAcceptors with a custom automaton instance, custom node and edge attributes, custom labels for initial nodes and a flag whether the initial nodes are artificial.static ModelDeserializer<CompactGraph<@Nullable String,@Nullable String>>graph()Default parser for (directed)Graphs serialized by AutomataLib.static <NP,EP>
ModelDeserializer<CompactGraph<NP,EP>>graph(Function<Map<String,String>,NP> nodeParser, Function<Map<String,String>,EP> edgeParser)Parser for (directed)Graphs with custom node and edge attributes.static <NP,EP,G extends MutableGraph<?,?,NP,EP>>
ModelDeserializer<G>graph(Supplier<G> creator, Function<Map<String,String>,NP> nodeParser, Function<Map<String,String>,EP> edgeParser)Parser for (directed)Graphs with a custom graph instance and custom node and edge attributes.static DOTInputModelDeserializer<Integer,@Nullable String,CompactMealy<@Nullable String,@Nullable String>>mealy()Default parser forMealyMachines serialized by AutomataLib.static <I,O>
DOTInputModelDeserializer<Integer,I,CompactMealy<I,O>>mealy(Function<Map<String,String>,Pair<I,O>> edgeParser)Parser forMealyMachines with custom edge attributes.static <S,I,O,A extends MutableMealyMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser)Parser forMealyMachines with a custom automaton instance and custom edge attributes.static <S,I,O,A extends MutableMealyMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser, String initialNodeId)Parser forMealyMachines with a custom automaton instance, custom edge attributes and a custom label for the initial node.static <S,I,O,A extends MutableMealyMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser, String initialNodeId, boolean fakeInitialNodeId)Parser forMealyMachines with a custom automaton instance, custom edge attributes and a custom label for the initial node and a flag whether the initial nodes are artificial.static DOTInputModelDeserializer<Integer,@Nullable String,CompactMoore<@Nullable String,@Nullable String>>moore()Default parser forMooreMachines serialized by AutomataLib.static <I,O>
DOTInputModelDeserializer<Integer,I,CompactMoore<I,O>>moore(Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser)Parser forMooreMachines with custom node and edge attributes.static <S,I,O,A extends MutableMooreMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser)Parser forMooreMachines with a custom automaton instance and custom node and edge attributes.static <S,I,O,A extends MutableMooreMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser, String initialNodeId)Parser forMooreMachines with a custom automaton instance, custom node and edge attributes and a custom label for the initial node.static <S,I,O,A extends MutableMooreMachine<S,I,?,O>>
DOTInputModelDeserializer<S,I,A>moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser, String initialNodeId, boolean fakeInitialNodeId)Parser forMooreMachines with a custom automaton instance, custom node and edge attributes, a custom label for the initial node and a flag whether the initial node is artificial.static DOTInputModelDeserializer<Integer,@Nullable String,CompactMTS<@Nullable String>>mts()Default parser forModalTransitionSystems serialized by AutomataLib.static <S,I,TP extends MutableModalEdgeProperty,M extends MutableModalTransitionSystem<S,I,?,TP>>
DOTInputModelDeserializer<S,I,M>mts(AutomatonCreator<M,I> creator, Function<Map<String,String>,I> inputParser, Function<Map<String,String>,TP> propertyParser)Parser forModalTransitionSystems with a custom MTS instance, custom input type and edge attributes parsers.static <S,I,TP extends MutableModalEdgeProperty,M extends MutableModalTransitionSystem<S,I,?,TP>>
DOTInputModelDeserializer<S,I,M>mts(AutomatonCreator<M,I> creator, Function<Map<String,String>,I> inputParser, Function<Map<String,String>,TP> propertyParser, Collection<String> initialNodeIds)Parser forModalTransitionSystems with a custom MTS instance, custom input type and edge attributes parsers and custom initial state labels.static DOTInputModelDeserializer<Integer,@Nullable String,CompactNFA<@Nullable String>>nfa()Default parser forNFAs serialized by AutomataLib.static <I> DOTInputModelDeserializer<Integer,I,CompactNFA<I>>nfa(Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)Parser forNFAs with custom node and edge attributes.
-
-
-
Field Detail
-
DEFAULT_NODE_PARSER
public static final Function<Map<String,String>,@Nullable String> DEFAULT_NODE_PARSER
-
DEFAULT_FSA_NODE_PARSER
public static final Function<Map<String,String>,Boolean> DEFAULT_FSA_NODE_PARSER
Node property parser that returnstrueif a node's "shape" attribute is specified and equals "doublecircle". Returnsfalseotherwise.
-
DEFAULT_MOORE_NODE_PARSER
public static final Function<Map<String,String>,@Nullable String> DEFAULT_MOORE_NODE_PARSER
Node property parser that expects a node's "label" attribute to be of the form<id>/<property>. Returns the string representation of<property>as-is. Returnsnullif the attribute does not exist or does not match the expected format.
-
DEFAULT_EDGE_PARSER
public static final Function<Map<String,String>,@Nullable String> DEFAULT_EDGE_PARSER
-
DEFAULT_MEALY_EDGE_PARSER
public static final Function<Map<String,String>,Pair<@Nullable String,@Nullable String>> DEFAULT_MEALY_EDGE_PARSER
-
DEFAULT_MTS_EDGE_PARSER
public static final Function<Map<String,String>,MutableModalEdgeProperty> DEFAULT_MTS_EDGE_PARSER
Edge input parser that parses an edge'smodalityattribute and constructs a correspondingMutableModalEdgeProperty. Throws anIllegalArgumentExceptionif the attribute is missing or doesn't match its expectedformat.
-
-
Method Detail
-
dfa
public static DOTInputModelDeserializer<Integer,@Nullable String,CompactDFA<@Nullable String>> dfa()
Default parser forDFAs serialized by AutomataLib.Invokes
dfa(Function, Function)withDEFAULT_FSA_NODE_PARSERasnodeParserandDEFAULT_EDGE_PARSERasedgeParser.- Returns:
- a
DOTInputModelDeserializerforCompactDFAs.
-
dfa
public static <I> DOTInputModelDeserializer<Integer,I,CompactDFA<I>> dfa(Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)
Parser forDFAs with custom node and edge attributes.Invokes
fsa(AutomatonCreator, Function, Function)withCompactDFA.Creatorascreator.- Type Parameters:
I- the input symbol type- Parameters:
nodeParser- a node parser that decides for a property map of a node whether it is accepting or notedgeParser- an edge parser that extracts from a property map of an edge the input symbol- Returns:
- a
DOTInputModelDeserializerforCompactDFAs.
-
nfa
public static DOTInputModelDeserializer<Integer,@Nullable String,CompactNFA<@Nullable String>> nfa()
Default parser forNFAs serialized by AutomataLib.Invokes
nfa(Function, Function)withDEFAULT_FSA_NODE_PARSERasnodeParserandDEFAULT_EDGE_PARSERasedgeParser.- Returns:
- a
DOTInputModelDeserializerforCompactNFAs.
-
nfa
public static <I> DOTInputModelDeserializer<Integer,I,CompactNFA<I>> nfa(Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)
Parser forNFAs with custom node and edge attributes.Invokes
fsa(AutomatonCreator, Function, Function)withCompactNFA.Creatorascreator.- Type Parameters:
I- the input symbol type- Parameters:
nodeParser- a node parser that decides for a property map of a node whether it is accepting or notedgeParser- an edge parser that extracts from a property map of an edge the input symbol- Returns:
- a
DOTInputModelDeserializerforCompactNFAs.
-
fsa
public static <S,I,A extends MutableFSA<S,I>> DOTInputModelDeserializer<S,I,A> fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser)
Parser forFiniteStateAcceptors with a custom automaton instance and custom node and edge attributes.Invokes
fsa(AutomatonCreator, Function, Function, Collection)with AutomataLib's default initial state label "__start0" asinitialNodeLabels.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that decides for a property map of a node whether it is accepting or notedgeParser- an edge parser that extracts from a property map of an edge the input symbol- Returns:
- a
DOTInputModelDeserializerforAs.
-
fsa
public static <S,I,A extends MutableFSA<S,I>> DOTInputModelDeserializer<S,I,A> fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser, Collection<String> initialNodeIds)
Parser forFiniteStateAcceptors with a custom automaton instance, custom node and edge attributes and custom labels for the initial nodes.Invokes
fsa(AutomatonCreator, Function, Function, Collection, boolean)withtrueasfakeInitialNodeLabels.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that decides for a property map of a node whether it is accepting or notedgeParser- an edge parser that extracts from a property map of an edge the input symbolinitialNodeIds- the ids of the initial nodes- Returns:
- a
DOTInputModelDeserializerforAs.
-
fsa
public static <S,I,A extends MutableFSA<S,I>> DOTInputModelDeserializer<S,I,A> fsa(AutomatonCreator<A,I> creator, Function<Map<String,String>,Boolean> nodeParser, Function<Map<String,String>,I> edgeParser, Collection<String> initialNodeIds, boolean fakeInitialNodeIds)
Parser forFiniteStateAcceptors with a custom automaton instance, custom node and edge attributes, custom labels for initial nodes and a flag whether the initial nodes are artificial.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that decides for a property map of a node whether it is accepting or notedgeParser- an edge parser that extracts from a property map of an edge the input symbolinitialNodeIds- the ids of the initial nodesfakeInitialNodeIds- a flag indicating whether theinitialNodeIdsare artificial or not. Iftrue, the nodes matching theinitialNodeIdswill not be added to the automaton. Instead, their direct successors will be initial states instead. This may be useful for instances where there are artificial nodes used to display in incoming arrow for the actual initial states. Iffalse, the nodes matching theinitialNodeIdswill be used as initial nodes.- Returns:
- a
DOTInputModelDeserializerforAs.
-
mealy
public static DOTInputModelDeserializer<Integer,@Nullable String,CompactMealy<@Nullable String,@Nullable String>> mealy()
Default parser forMealyMachines serialized by AutomataLib.Invokes
mealy(Function)withDEFAULT_MEALY_EDGE_PARSERasedgeParser.- Returns:
- a
DOTInputModelDeserializerforCompactMealys.
-
mealy
public static <I,O> DOTInputModelDeserializer<Integer,I,CompactMealy<I,O>> mealy(Function<Map<String,String>,Pair<I,O>> edgeParser)
Parser forMealyMachines with custom edge attributes.Invokes
mealy(AutomatonCreator, Function)withCompactMealy.Creatorascreator.- Type Parameters:
I- the input symbol typeO- the output symbol type- Parameters:
edgeParser- an edge parser that extracts from a property map of an edge the input symbol and transition property- Returns:
- a
DOTInputModelDeserializerforCompactMealys.
-
mealy
public static <S,I,O,A extends MutableMealyMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser)
Parser forMealyMachines with a custom automaton instance and custom edge attributes.Invokes
mealy(AutomatonCreator, Function, String)with AutomataLib's default initial state label "__start0" asinitialNodeLabel.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonedgeParser- an edge parser that extracts from a property map of an edge the input symbol and transition property- Returns:
- a
DOTInputModelDeserializerforAs.
-
mealy
public static <S,I,O,A extends MutableMealyMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser, String initialNodeId)
Parser forMealyMachines with a custom automaton instance, custom edge attributes and a custom label for the initial node.Invokes
fsa(AutomatonCreator, Function, Function, Collection, boolean)withtrueasfakeInitialNodeLabels.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonedgeParser- an edge parser that extracts from a property map of an edge the input symbol and transition propertyinitialNodeId- the id of the initial node- Returns:
- a
DOTInputModelDeserializerforAs.
-
mealy
public static <S,I,O,A extends MutableMealyMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> mealy(AutomatonCreator<A,I> creator, Function<Map<String,String>,Pair<I,O>> edgeParser, String initialNodeId, boolean fakeInitialNodeId)
Parser forMealyMachines with a custom automaton instance, custom edge attributes and a custom label for the initial node and a flag whether the initial nodes are artificial.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonedgeParser- an edge parser that extracts from a property map of an edge the input symbol and transition propertyinitialNodeId- the id of the initial nodefakeInitialNodeId- a flag indicating whether theinitialNodeIdare artificial or not. Iftrue, the nodes matching theinitialNodeIdwill not be added to the automaton. Instead, their direct successors will be initial states instead. This may be useful for instances where there are artificial nodes used to display in incoming arrow for the actual initial states. Iffalse, the nodes matching theinitialNodeIdwill be used as initial nodes.- Returns:
- a
DOTInputModelDeserializerforAs.
-
moore
public static DOTInputModelDeserializer<Integer,@Nullable String,CompactMoore<@Nullable String,@Nullable String>> moore()
Default parser forMooreMachines serialized by AutomataLib.Invokes
moore(Function, Function)withDEFAULT_MOORE_NODE_PARSERasnodeParserandDEFAULT_EDGE_PARSERasedgeParser.- Returns:
- a
DOTInputModelDeserializerforCompactMoores.
-
moore
public static <I,O> DOTInputModelDeserializer<Integer,I,CompactMoore<I,O>> moore(Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser)
Parser forMooreMachines with custom node and edge attributes.Invokes
moore(AutomatonCreator, Function, Function)withCompactMoore.Creatorascreator.- Type Parameters:
I- the input symbol typeO- the output symbol type- Parameters:
nodeParser- a node parser that extracts from a property map of a node the state propertyedgeParser- an edge parser that extracts from a property map of an edge the input symbol- Returns:
- a
DOTInputModelDeserializerforCompactMoores.
-
moore
public static <S,I,O,A extends MutableMooreMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser)
Parser forMooreMachines with a custom automaton instance and custom node and edge attributes.Invokes
moore(AutomatonCreator, Function, Function, String)with AutomataLib's default initial state label "__start0" asinitialNodeLabel.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that extracts from a property map of a node the state propertyedgeParser- an edge parser that extracts from a property map of an edge the input symbol- Returns:
- a
DOTInputModelDeserializerforAs.
-
moore
public static <S,I,O,A extends MutableMooreMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser, String initialNodeId)
Parser forMooreMachines with a custom automaton instance, custom node and edge attributes and a custom label for the initial node.Invokes
moore(AutomatonCreator, Function, Function, String, boolean)withtrueasfakeInitialNodeLabel.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that extracts from a property map of a node the state propertyedgeParser- an edge parser that extracts from a property map of an edge the input symbolinitialNodeId- the id of the initial node- Returns:
- a
DOTInputModelDeserializerforAs.
-
moore
public static <S,I,O,A extends MutableMooreMachine<S,I,?,O>> DOTInputModelDeserializer<S,I,A> moore(AutomatonCreator<A,I> creator, Function<Map<String,String>,O> nodeParser, Function<Map<String,String>,I> edgeParser, String initialNodeId, boolean fakeInitialNodeId)
Parser forMooreMachines with a custom automaton instance, custom node and edge attributes, a custom label for the initial node and a flag whether the initial node is artificial.- Type Parameters:
S- the state type of the returned automatonI- the input symbol typeO- the output symbol typeA- the type of the returned automaton- Parameters:
creator- a creator that is used to instantiate the returned automatonnodeParser- a node parser that extracts from a property map of a node the state propertyedgeParser- an edge parser that extracts from a property map of an edge the input symbolinitialNodeId- the id of the initial nodefakeInitialNodeId- a flag indicating whether theinitialNodeIdare artificial or not. Iftrue, the nodes matching theinitialNodeIdwill not be added to the automaton. Instead, their direct successors will be initial states instead. This may be useful for instances where there are artificial nodes used to display in incoming arrow for the actual initial states. Iffalse, the nodes matching theinitialNodeIdwill be used as initial nodes.- Returns:
- a
DOTInputModelDeserializerforAs.
-
graph
public static ModelDeserializer<CompactGraph<@Nullable String,@Nullable String>> graph()
Default parser for (directed)Graphs serialized by AutomataLib.Invokes
graph(Function, Function)withDEFAULT_NODE_PARSERasnodeParserandDEFAULT_EDGE_PARSERasedgeParser.- Returns:
- a DOT
ModelDeserializerforCompactGraphs.
-
graph
public static <NP,EP> ModelDeserializer<CompactGraph<NP,EP>> graph(Function<Map<String,String>,NP> nodeParser, Function<Map<String,String>,EP> edgeParser)
Parser for (directed)Graphs with custom node and edge attributes.Invokes
graph(Supplier, Function, Function)withCompactGraph()ascreator.- Type Parameters:
NP- the node property typeEP- the edge property type- Parameters:
nodeParser- a node parser that extracts from a property map of a node the node propertyedgeParser- an edge parser that extracts from a property map of an edge the edge property- Returns:
- a DOT
ModelDeserializerforCompactGraphs.
-
graph
public static <NP,EP,G extends MutableGraph<?,?,NP,EP>> ModelDeserializer<G> graph(Supplier<G> creator, Function<Map<String,String>,NP> nodeParser, Function<Map<String,String>,EP> edgeParser)
Parser for (directed)Graphs with a custom graph instance and custom node and edge attributes.- Type Parameters:
NP- the node property typeEP- the edge property typeG- the graph type- Parameters:
creator- a creator that is used to instantiate the returned graphnodeParser- a node parser that extracts from a property map of a node the node propertyedgeParser- an edge parser that extracts from a property map of an edge the edge property- Returns:
- a DOT
ModelDeserializerforGs.
-
mts
public static DOTInputModelDeserializer<Integer,@Nullable String,CompactMTS<@Nullable String>> mts()
Default parser forModalTransitionSystems serialized by AutomataLib.Invokes
mts(AutomatonCreator, Function, Function)withCompactMTS(Alphabet)ascreator,DEFAULT_EDGE_PARSERasinputParserandDEFAULT_EDGE_PARSERaspropertyParser.- Returns:
- a
DOTInputModelDeserializerforCompactMTSs.
-
mts
public static <S,I,TP extends MutableModalEdgeProperty,M extends MutableModalTransitionSystem<S,I,?,TP>> DOTInputModelDeserializer<S,I,M> mts(AutomatonCreator<M,I> creator, Function<Map<String,String>,I> inputParser, Function<Map<String,String>,TP> propertyParser)
Parser forModalTransitionSystems with a custom MTS instance, custom input type and edge attributes parsers.Invokes
mts(AutomatonCreator, Function, Function, Collection)with AutomataLib's default initial state label "__start0" asinitialNodeLabel.- Type Parameters:
S- the state type of the returned MTSI- the input symbol typeTP- the modal transition propertyM- the type of the returned MTS- Parameters:
creator- a creator that is used to instantiate the returned graphinputParser- an edge parser that extracts from a property map of an edge the input symbolpropertyParser- an edge parser that extracts from a property map of an edge the modal transition property- Returns:
- a DOT
ModelDeserializerforMs.
-
mts
public static <S,I,TP extends MutableModalEdgeProperty,M extends MutableModalTransitionSystem<S,I,?,TP>> DOTInputModelDeserializer<S,I,M> mts(AutomatonCreator<M,I> creator, Function<Map<String,String>,I> inputParser, Function<Map<String,String>,TP> propertyParser, Collection<String> initialNodeIds)
Parser forModalTransitionSystems with a custom MTS instance, custom input type and edge attributes parsers and custom initial state labels.- Type Parameters:
S- the state type of the returned MTSI- the input symbol typeTP- the modal transition propertyM- the type of the returned MTS- Parameters:
creator- a creator that is used to instantiate the returned graphinputParser- an edge parser that extracts from a property map of an edge the input symbolpropertyParser- an edge parser that extracts from a property map of an edge the modal transition propertyinitialNodeIds- the ids of the initial nodes- Returns:
- a DOT
ModelDeserializerforMs.
-
-