Class FileDungTheoryGenerator

    • Constructor Summary

      Constructors 
      Constructor Description
      FileDungTheoryGenerator​(java.io.File[] files, Parser<DungTheory,​?> parser, boolean loop)
      Creates a new theory generator for the given files, which can be parsed by the given parser.
    • Method Summary

      Modifier and Type Method Description
      java.io.File getPreviousFile()
      Returns the file of the theory previously returned by "next()"
      boolean hasNext()  
      DungTheory next()  
      DungTheory next​(Argument arg)
      Generates a new Dung theory where the given argument is enforced to be in the grounded extension
      void setSeed​(long seed)
      Set the seed for the generation.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface java.util.Iterator

        forEachRemaining, remove
    • Constructor Detail

      • FileDungTheoryGenerator

        public FileDungTheoryGenerator​(java.io.File[] files,
                                       Parser<DungTheory,​?> parser,
                                       boolean loop)
        Creates a new theory generator for the given files, which can be parsed by the given parser.
        Parameters:
        files - an array of files.
        parser - a parser for the files.
        loop - whether to loop the files indefinitely.
    • Method Detail

      • getPreviousFile

        public java.io.File getPreviousFile()
        Returns the file of the theory previously returned by "next()"
        Returns:
        the file of the theory previously returned by "next()" (or NULL if there was none)
      • next

        public DungTheory next​(Argument arg)
        Description copied from interface: DungTheoryGenerator
        Generates a new Dung theory where the given argument is enforced to be in the grounded extension
        Specified by:
        next in interface DungTheoryGenerator
        Parameters:
        arg - an argument that is enforced to be in the grounded extension of the generated theory.
        Returns:
        a Dung theory,
      • setSeed

        public void setSeed​(long seed)
        Description copied from interface: DungTheoryGenerator
        Set the seed for the generation. Every two runs of generations with the same seed are ensured to be identical.
        Specified by:
        setSeed in interface DungTheoryGenerator
        Parameters:
        seed - some seed.