The purpose of this module is to provide a single official
predicate for serializing Prolog terms that the Attempto
tools produce (DRSs, token lists, OWL FSS, etc.).
Serialized terms can be stored in files, sent over HTTP, etc.,
so that they can be later read back into the exact same term.
Essentially we provide a customized version of Prolog built-ins
like write_canonical/[1,2] and writeq/[1,2].
- author
- - Kaarel Kaljurand
- version
- - 2009-03-20
TODO
:
- test how \= (ACE non-equality) is serialized, maybe check
character_escapes(bool, changeable)
- find a way to print terms which contain variables so that the output
has nice variable names (A vs _G123) but without the detour of numbervars,
maybe check: print, portray
- should we serialize singletons as '_'
- we make an extra effort to locally undefine some operators, there must be a cleaner way
- serialize_term(+Stream:stream, +Term:term) is det
- serialize_term(+Term:term) is det
-
- Arguments:
-
Stream | - is the output stream |
Term | - is a term to be serialized |
- serialize_term_into_atom(+Term:term, -SerializedTerm:atom) is det
-
- Arguments:
-
Term | - is a term to be serialized |
SerializedTerm | - is the term serialized as an atom |
Undocumented predicates
The following predicates are exported, but not or incorrectly documented.
- serialize_term(Arg1)