protocol
termp
ï
Term utility predicates protocol.
logtalk_load(types(loader))
static
public
comparingpPublic predicatesï
depth/2
ï
True if the depth of Term
is Depth
. The depth of atomic terms is zero; the depth of a compound term is one plus the maximum depth of its sub-terms.
static
depth(Term,Depth)
depth(@term,?integer)
- zero_or_one
ground/1
ï
True if the argument is ground. Deprecated. Use the ground/1
standard predicate instead.
static
ground(Term)
ground(@term)
- zero_or_one
new/1
ï
Creates a new term instance (if meaningful).
static
new(Term)
new(-nonvar)
- zero_or_one
occurs/2
ï
True if the variable occurs in the term.
static
occurs(Variable,Term)
occurs(@var,@term)
- zero_or_one
subsumes/2
ï
The first term subsumes the second term. Deprecated. Use the subsumes_term/2
standard predicate instead.
static
subsumes(General,Specific)
subsumes(@term,@term)
- zero_or_one
subterm/2
ï
The first term is a subterm of the second term.
static
subterm(Subterm,Term)
subterm(?term,+term)
- zero_or_more
valid/1
ï
Term is valid.
static
valid(Term)
valid(@nonvar)
- zero_or_one
check/1
ï
Checks if a term is valid. Throws an exception if the term is not valid.
static
check(Term)
check(@nonvar)
- one
variant/2
ï
Each term is a variant of the other (i.e. they are structurally equivalent).
static
variant(Term1,Term2)
variant(@term,@term)
- zero_or_one
variables/2
ï
Returns a list of all term variables (ordered as found when doing a depth-first, left-to-right traversal of Term
). Deprecated. Use the standard term_variables/2
predicate instead.
static
variables(Term,List)
variables(@term,-list)
- one
singletons/2
ï
Returns a list of all term singleton variables (ordered as found when doing a depth-first, left-to-right traversal of Term
).
static
singletons(Term,Singletons)
singletons(@term,-list)
- one
numbervars/3
ï
Grounds a term by replacing all variables with '$VAR'(N)
terms with N
starting at From
. The Next
argument is unified with the next value for N
after binding all variables.
static
numbervars(Term,From,Next)
numbervars(?term,+integer,?integer)
- zero_or_one
numbervars/1
ï
Grounds a term by replacing all variables with '$VAR'(N)
terms with N
starting at 0
.
static
numbervars(Term)
numbervars(?term)
- zero_or_one
varnumbers/3
ï
Replaces all '$VAR'(N)
sub-terms in a term with fresh variables for all values of N
grater or equal to From
. Variables in Term
are shared with Copy
.
static
varnumbers(Term,From,Copy)
varnumbers(@term,+integer,?term)
- zero_or_one
varnumbers/2
ï
Replaces all '$VAR'(N)
sub-terms in a term with fresh variables for all values of N
grater or equal to 0
. Variables in Term
are shared with Copy
.
static
varnumbers(Term,Copy)
varnumbers(@term,?term)
- zero_or_one
Protected predicatesï
(no local declarations; see entity ancestors if any)
Private predicatesï
(no local declarations; see entity ancestors if any)
Operatorsï
(none)
See also