Class ApxParser


public class ApxParser extends AbstractDungParser
Parses abstract argumentation frameworks in the logic programming format which is given by the following BNF (start symbol is S):

S ::== "" | "arg" "(" ARGUMENT ")" "\n" S | "att" "(" ARGUMENT "," ARGUMENT ")" "\n" S
where "ARGUMENT" represents any string (without blanks) as a terminal symbol.
Author:
Matthias Thimm
  • Constructor Details

    • ApxParser

      public ApxParser()
  • Method Details

    • parse

      public DungTheory parse(Reader reader) throws IOException
      Description copied from class: AbstractDungParser
      Parses the given file into an abstract argumentation framework
      Specified by:
      parse in class AbstractDungParser
      Parameters:
      reader - some reader
      Returns:
      an abstract argumentation framework
      Throws:
      IOException - for all errors concerning file reading.
    • parseIgnoreComments

      public DungTheory parseIgnoreComments(Reader reader, boolean printCommands) throws IOException
      Parses an argumentation framework from a reader source with options to ignore comments and optionally print commands. This method is useful when you want to preprocess the data or when debug outputs are needed.
      Parameters:
      reader - The reader to parse the argumentation framework from.
      printCommands - A boolean flag that when set to true, prints each row of the input to standard output.
      Returns:
      A DungTheory representing the parsed argumentation framework.
      Throws:
      IOException - If an I/O error occurs during reading or parsing the input.