java.lang.Object
net.automatalib.serialization.ba.BAWriter<I>
- All Implemented Interfaces:
InputModelSerializer<I,,FiniteStateAcceptor<?, I>> ModelSerializer<InputModelData<I,FiniteStateAcceptor<?, I>>>
public final class BAWriter<I>
extends Object
implements InputModelSerializer<I,FiniteStateAcceptor<?,I>>
A writer that exports automata to the BA format. For further information about the BA format, see
https://languageinclusion.org/doku.php?id=tools#the_ba_format.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <S,I> void writeAutomaton(FiniteStateAcceptor<S, I> automaton, Alphabet<I> alphabet, OutputStream os) voidwriteModel(OutputStream os, FiniteStateAcceptor<?, I> model, Alphabet<I> alphabet) Writes the model to the given output stream.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.automatalib.serialization.InputModelSerializer
writeModel, writeModelMethods inherited from interface net.automatalib.serialization.ModelSerializer
writeModel
-
Constructor Details
-
BAWriter
public BAWriter()
-
-
Method Details
-
writeModel
public void writeModel(OutputStream os, FiniteStateAcceptor<?, I> model, Alphabet<I> alphabet) throws IOExceptionDescription copied from interface:InputModelSerializerWrites the model to the given output stream. If the format is a textual one, the output is typically encoded inUTF-8.Note: the output stream will not be closed.
- Specified by:
writeModelin interfaceInputModelSerializer<I,FiniteStateAcceptor<?, I>> - Parameters:
os- the output stream to write tomodel- the model to writealphabet- the inputs of the model to which serialization should be limited- Throws:
IOException- when writing to the output stream fails.
-
writeAutomaton
public static <S,I> void writeAutomaton(FiniteStateAcceptor<S, I> automaton, Alphabet<I> alphabet, OutputStream os) throws IOException- Throws:
IOException
-