Class AspicParser<T extends Invertable>

  • Type Parameters:
    T - is the type of the language that the ASPIC theory's rules range over

    public class AspicParser<T extends Invertable>
    extends Parser<AspicArgumentationTheory<T>,​Formula>
    Parses a Aspic Argumentation System out of an input text. Every line contains one of the following:
    <order> ::= <identifier> ( '<' <identifier> )+
    <ordinary premise> ::= '=>' '-'? <identifier>
    <axiom> ::= '->' '-'? <identifier>
    <defeasible rule> ::= ( <identifier> ':' )? <identifier> ( ',' <identifier> )* '=>' (-)? <identifier>
    <static rule> ::= <identifier> ( ',' <identifier> )* '->' (-)? <identifier>
    Author:
    Nils Geilen
    • Constructor Detail

      • AspicParser

        public AspicParser​(Parser<? extends BeliefBase,​? extends Formula> formulaparser,
                           RuleFormulaGenerator<T> rfg)
        Constructs a new instance
        Parameters:
        formulaparser - parses the bodies and the heads of the ASPIC argumentation systems rules
        rfg - a generator, that transforms InferenceRule<T> into T
    • Method Detail

      • setSymbolStrict

        public void setSymbolStrict​(java.lang.String symbolStrict)
        Sets a new symbol used for parsing strict function arrows
        Parameters:
        symbolStrict - is the new symbol
      • setSymbolDefeasible

        public void setSymbolDefeasible​(java.lang.String symbolDefeasible)
        Sets a new symbol used for parsing defeasible function arrows
        Parameters:
        symbolDefeasible - is the new symbol
      • setSymbolComma

        public void setSymbolComma​(java.lang.String symbolComma)
        Sets a new symbol used for parsing parameter separators
        Parameters:
        symbolComma - is the new symbol
      • parseSimpleOrder

        public SimpleAspicOrder<T> parseSimpleOrder​(java.lang.String line)
        Extracts and Constructs a SimpleAspicOrder out of a string
        Parameters:
        line - the source string
        Returns:
        the parsed order