provrml_io (library)

Author(s): Göran Smedbäck.

This file implements I/O predicates of different types.

Implemented by Göran Smedbäck


Usage and interface

Documentation on exports

PREDICATE

Usage:out(ListOfOutput)

The predicate used is out/3 (DCG) where we will 'save' the output in the second argument. The tird argument is the rest, nil.

  • Call and exit should be compatible with:
    (basic_props:list/2)ListOfOutput is a list of atms.
  • The following properties should hold at call time:
    (term_typing:nonvar/1)ListOfOutput is currently a term which is not a free variable.

PREDICATE
No further documentation available for this predicate.

PREDICATE

Usage:convert_atoms_to_string(Atoms,String)

The predicate transforms a list of atoms to a string.

  • Call and exit should be compatible with:
    (basic_props:list/2)Atoms is a list of atms.
    (basic_props:list/2)String is a list of nums.
  • The following properties should hold at call time:
    (term_typing:nonvar/1)Atoms is currently a term which is not a free variable.
    (term_typing:var/1)String is a free variable.

PREDICATE

Usage:read_terms_file(Filename,Term)

Given a filename to a file with terms, the predicate reads the terms and are returned in the second argument. Filename is an atom and Term is the read prolog terms.

  • Call and exit should be compatible with:
    (basic_props:atm/1)Filename is an atom.
    (basic_props:atm/1)Term is an atom.
  • The following properties should hold at call time:
    (term_typing:nonvar/1)Filename is currently a term which is not a free variable.
    (term_typing:var/1)Term is a free variable.

PREDICATE

Usage:write_terms_file(FileName,List)

Given a filename and a list of terms the predicate will write them down to the file.

  • Call and exit should be compatible with:
    (basic_props:atm/1)FileName is an atom.
    (basic_props:list/2)List is a list of atms.
  • The following properties should hold at call time:
    (term_typing:nonvar/1)FileName is currently a term which is not a free variable.
    (term_typing:nonvar/1)List is currently a term which is not a free variable.

PREDICATE

Usage:read_vrml_file(FileName,Data)

Given a filename, the predicate returns the substance.

  • Call and exit should be compatible with:
    (basic_props:atm/1)FileName is an atom.
    (basic_props:string/1)Data is a string (a list of character codes).
  • The following properties should hold at call time:
    (term_typing:nonvar/1)FileName is currently a term which is not a free variable.
    (term_typing:var/1)Data is a free variable.

PREDICATE

Usage:write_vrml_file(FileName,Data)

Given a filename and data in form of a string, the predicate will write the data to the named file.

  • Call and exit should be compatible with:
    (basic_props:atm/1)FileName is an atom.
    (basic_props:string/1)Data is a string (a list of character codes).
  • The following properties should hold at call time:
    (term_typing:nonvar/1)FileName is currently a term which is not a free variable.
    (term_typing:nonvar/1)Data is currently a term which is not a free variable.