RISC JKU

at.jku.risc.stout.nau.util

Class Printable

  • Direct Known Subclasses:
    AntiUnifySystem, Equation, EquationSystem, FreshnessCtx, NominalPair, NominalTerm


    public abstract class Printable
    extends Object
    Superclass for all printable classes. Printable classes have to implement a method to write a string representation of themselves into an arbitrary Writer. The method toString() will use this representation too. This method is much more flexible than the plain toString() approach and it uses much less system resources by directly writing to the receiver.
    Author:
    Alexander Baumgartner
    • Constructor Detail

      • Printable

        public Printable()
    • Method Detail

      • printString

        public abstract void printString(Writer toPrint)
                                  throws IOException
        Writes a string representation of this object into an arbitrary Writer.
        Throws:
        IOException
      • toString

        public String toString()
        Use printString(Writer) if possible! It uses much less system resources by directly writing to the receiver.
        Overrides:
        toString in class Object