Package jhoafparser.extensions
Class HOAConsumerPrintFixed
- java.lang.Object
-
- jhoafparser.extensions.HOAConsumerPrintFixed
-
- All Implemented Interfaces:
jhoafparser.consumer.HOAConsumer
public class HOAConsumerPrintFixed extends Object implements jhoafparser.consumer.HOAConsumer
ThisHOAConsumer
renders the method calls to produce a valid HOA automaton output.
-
-
Constructor Summary
Constructors Constructor Description HOAConsumerPrintFixed(Writer out)
Constructor
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addAlias(String name, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr)
void
addEdgeImplicit(int stateId, List<Integer> conjSuccessors, List<Integer> accSignature)
void
addEdgeWithLabel(int stateId, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr, List<Integer> conjSuccessors, List<Integer> accSignature)
void
addMiscHeader(String name, List<Object> content)
void
addProperties(List<String> properties)
void
addStartStates(List<Integer> stateConjunction)
void
addState(int id, String info, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr, List<Integer> accSignature)
void
notifyAbort()
void
notifyBodyStart()
void
notifyEnd()
void
notifyEndOfState(int stateId)
void
notifyHeaderStart(String version)
void
notifyWarning(String warning)
boolean
parserResolvesAliases()
void
provideAcceptanceName(String name, List<Object> extraInfo)
protected static String
quoteString(String s)
Returns the argument, quoted according to HOA quoting rules.void
setAcceptanceCondition(int numberOfSets, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomAcceptance> accExpr)
void
setAPs(List<String> aps)
void
setName(String name)
void
setNumberOfStates(int numberOfStates)
void
setTool(String name, String version)
-
-
-
Constructor Detail
-
HOAConsumerPrintFixed
public HOAConsumerPrintFixed(Writer out)
Constructor- Parameters:
out
- theOutputStream
-
-
Method Detail
-
parserResolvesAliases
public boolean parserResolvesAliases()
- Specified by:
parserResolvesAliases
in interfacejhoafparser.consumer.HOAConsumer
-
notifyHeaderStart
public void notifyHeaderStart(String version) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
notifyHeaderStart
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
setNumberOfStates
public void setNumberOfStates(int numberOfStates) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
setNumberOfStates
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addStartStates
public void addStartStates(List<Integer> stateConjunction) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addStartStates
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addAlias
public void addAlias(String name, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addAlias
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
setAPs
public void setAPs(List<String> aps) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
setAPs
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
setAcceptanceCondition
public void setAcceptanceCondition(int numberOfSets, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomAcceptance> accExpr) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
setAcceptanceCondition
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
provideAcceptanceName
public void provideAcceptanceName(String name, List<Object> extraInfo) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
provideAcceptanceName
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
setName
public void setName(String name) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
setName
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
setTool
public void setTool(String name, String version) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
setTool
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addProperties
public void addProperties(List<String> properties) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addProperties
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addMiscHeader
public void addMiscHeader(String name, List<Object> content) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addMiscHeader
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
notifyBodyStart
public void notifyBodyStart() throws jhoafparser.consumer.HOAConsumerException
- Specified by:
notifyBodyStart
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addState
public void addState(int id, String info, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr, @Nullable List<Integer> accSignature) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addState
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addEdgeImplicit
public void addEdgeImplicit(int stateId, List<Integer> conjSuccessors, @Nullable List<Integer> accSignature) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addEdgeImplicit
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
addEdgeWithLabel
public void addEdgeWithLabel(int stateId, jhoafparser.ast.BooleanExpression<jhoafparser.ast.AtomLabel> labelExpr, List<Integer> conjSuccessors, @Nullable List<Integer> accSignature) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
addEdgeWithLabel
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
notifyEndOfState
public void notifyEndOfState(int stateId)
- Specified by:
notifyEndOfState
in interfacejhoafparser.consumer.HOAConsumer
-
notifyEnd
public void notifyEnd() throws jhoafparser.consumer.HOAConsumerException
- Specified by:
notifyEnd
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
notifyAbort
public void notifyAbort()
- Specified by:
notifyAbort
in interfacejhoafparser.consumer.HOAConsumer
-
quoteString
protected static String quoteString(String s)
Returns the argument, quoted according to HOA quoting rules.
-
notifyWarning
public void notifyWarning(String warning) throws jhoafparser.consumer.HOAConsumerException
- Specified by:
notifyWarning
in interfacejhoafparser.consumer.HOAConsumer
- Throws:
jhoafparser.consumer.HOAConsumerException
-
-