- read_term(+Stream,?Term,+Options)
Inputs a term Term from the stream Stream using options
Options. After reaching the end of file, it unifies Term with
end_of_file. The Options is a list of options that can
include:
- variables(V_list) After reading a term, V_list
will be unified with the list of variables that occur in the term.
- variable_names(VN_list) After reading a term, VN_list
will be unified with a list of elements in the form of N = V where
V is a variable occurring in the term and N is the name of V.
- variable_names(VS_list) After reading a term, VS_list
will be unified with a list of elements in the form of N = V where
V is a singleton variable in the term and N is the name of V.
- read_term(?Term,+Options)
The same as the previous one except that the current input stream is used.
- read(+Stream,?Term)
Equivalent to: read_term(Stream,Term),[]).
- read(?Term)
Equivalent to: read_term(Term,[]).
- write_term(+Stream,+Term,+Options)
Outputs a term Term into a stream Stream using the option
list Options. The list of options Options can
include5.5:
- quoted(Bool) - When Bool is true each atom and
functor is quoted such that the term can be read by read/1.
- ignore_ops(Bool) - When Bool is true each
compound term is output in functional notation, i.e., in the form of
f(A1,
,An) where f is the functor and Ai's are
arguments.
- write_term(+Term,+Options)
The same as the previous one except that the current output stream is used.
- write(+Stream,+Term)
Equivalent to: write_term(Stream,Term,[]).
- write(+Term)
Equivalent to:
current_output(Stream),write(Stream,Term).
- write_canonical(+Stream,+Term)
Equivalent to:
write_term(Stream,Term,[quoted(true),ignore_ops(true)]).
- write_canonical(+Term)
Equivalent to:
current_output(Stream),write_canonical(Stream,Term).
- writeq(Stream,Term)
Equivalent to:
write_term(Stream,Term,[quoted(true)]).
- writeq(Term)
Equivalent to:
current_output(Stream),writeq(Stream,Term).
- op(+Priority,+Specifier,+Name)
Makes atom Name an operator of type Specifier and priority
Priority5.6.
Specifier specifies the class ( prefix, infix or postfix) and
the associativity, which can be:
- fx - prefix, non-associative.
- fy - prefix, right-associative.
- xfx - infix, non-associative.
- xfy - infix, right-associative.
- yfx - infix, left-associative.
- xf - postfix, non-associative.
- yf - postfix, left-associative.
The priority of an operator is an integer greater than 0 and less than 1201.
The lower the priority, the stronger the operator binds its operands.
- current_op(?Priority,?Specifier,?Operator)
It is true if Operator is an operator with properties defined by a
specifier Specifier and precedence Priority.