public interface IPrologTermOutput
Modifier and Type | Method and Description |
---|---|
IPrologTermOutput |
closeList()
Finish a list that was started with
openList() . |
IPrologTermOutput |
closeTerm()
Finish a term that was started with
openTerm(String) . |
IPrologTermOutput |
emptyList()
Print an empty list.
|
IPrologTermOutput |
flush()
flush the underlying output stream
|
IPrologTermOutput |
fullstop()
print a Prolog full stop.
|
IPrologTermOutput |
openList()
Start a new list.
|
IPrologTermOutput |
openTerm(java.lang.String functor)
Start a new term.
|
IPrologTermOutput |
openTerm(java.lang.String functor,
boolean ignoreIndention)
Start a new term.
|
IPrologTermOutput |
printAtom(java.lang.String content)
Print an atom.
|
IPrologTermOutput |
printAtomOrNumber(java.lang.String content)
Print an atom or number.
|
IPrologTermOutput |
printNumber(java.math.BigInteger number)
Print a number.
|
IPrologTermOutput |
printNumber(long number)
Print a number.
|
IPrologTermOutput |
printString(java.lang.String content)
Print a string.
|
IPrologTermOutput |
printTerm(PrologTerm term)
Print a complete Term.
|
IPrologTermOutput |
printVariable(java.lang.String var)
Print a Prolog variable.
|
IPrologTermOutput openTerm(java.lang.String functor)
closeTerm()
.
Same as openTerm(String, boolean)
with false
as
second argument.functor
- the functor, never null
.IPrologTermOutput openTerm(java.lang.String functor, boolean ignoreIndention)
closeTerm()
. You should close all opened terms.
Use this method instead of openTerm(String)
if you want to
control whether the arguments of the term should be indented or not. This
is useful to write terms more compact when you know that they are always
short.functor
- the functor, never null
ignoreIndention
- if this is set to true, the arguments of this term are not
subject to indent.IPrologTermOutput closeTerm()
openTerm(String)
. This
method basically prints the closing parenthesis.IPrologTermOutput printAtom(java.lang.String content)
content
- the name of the atom, never null
IPrologTermOutput printAtomOrNumber(java.lang.String content)
content
- the name of the atom, never null
IPrologTermOutput printString(java.lang.String content)
content
- the string content, never null
IPrologTermOutput printNumber(long number)
number
- the number to printIPrologTermOutput printNumber(java.math.BigInteger number)
number
- the number to printthis
IPrologTermOutput openList()
closeList()
are put into the list. All opened lists
should be closed. Basically this method prints the opening bracket.IPrologTermOutput closeList()
openList()
. Basically this
method prints the closing bracket.IPrologTermOutput emptyList()
IPrologTermOutput printVariable(java.lang.String var)
var
- the name of the variable, never null
java.lang.IllegalArgumentException
- if the variable is not a syntactically valid Prolog variable.IPrologTermOutput printTerm(PrologTerm term)
term
- the term, never null
this
IPrologTermOutput flush()
IPrologTermOutput fullstop()