protocol
setp
ï
Set protocol.
logtalk_load(sets(loader))
static
Public predicatesï
as_set/2
ï
Returns a set with all unique elements from the given list.
static
as_set(List,Set)
as_set(@list,-set)
- one
as_list/2
ï
Returns a list with all elements of the given set.
static
as_list(Set,List)
as_list(@set,-list)
- one
delete/3
ï
Deletes an element from a set returning the set of remaining elements.
static
delete(Set,Element,Remaining)
delete(+set,@term,?set)
- one
disjoint/2
ï
True if the two sets have no element in common.
static
disjoint(Set1,Set2)
disjoint(+set,+set)
- zero_or_one
equal/2
ï
True if the two sets are equal.
static
equal(Set1,Set2)
equal(+set,+set)
- zero_or_one
empty/1
ï
True if the set is empty.
static
empty(Set)
empty(+set)
- zero_or_one
insert/3
ï
Inserts an element in a set, returning the resulting set.
static
insert(In,Element,Out)
insert(+set,+term,?set)
- one
insert_all/3
ï
Inserts a list of elements in a set, returning the resulting set.
static
insert_all(List,In,Out)
insert_all(+list,+set,?set)
- one
intersect/2
ï
True if the two sets have at least one element in common.
static
intersect(Set1,Set2)
intersect(+set,+set)
- zero_or_one
intersection/3
ï
Returns the intersection of Set1
and Set2
.
static
intersection(Set1,Set2,Intersection)
intersection(+set,+set,?set)
- zero_or_one
intersection/4
ï
True if Intersection
is the intersection of Set1
and Set2
and Difference
is the difference between Set2
and Set1
.
static
intersection(Set1,Set2,Intersection,Difference)
intersection(+set,+set,?set,?set)
- zero_or_one
size/2
ï
Number of set elements.
static
size(Set,Size)
size(+set,?integer)
- zero_or_one
member/2
ï
Element
is a member of set Set
.
static
member(Element,Set)
member(+term,+set)
- zero_or_one
member(-term,+set)
- zero_or_more
memberchk/2
ï
Checks if a term is a member of a set.
static
memberchk(Element,Set)
memberchk(+term,+set)
- zero_or_one
powerset/2
ï
Returns the power set of a set, represented as a list of sets.
static
powerset(Set,Powerset)
powerset(+set,-list)
- one
product/3
ï
Returns the cartesian product of two sets.
static
product(Set1,Set2,Product)
product(+set,+set,-set)
- one
select/3
ï
Selects an element from a set, returning the set of remaining elements.
static
select(Element,Set,Remaining)
select(?term,+set,?set)
- zero_or_more
selectchk/3
ï
Checks that an element can be selected from a set, returning the set of remaining elements.
static
selectchk(Element,Set,Remaining)
selectchk(?term,+set,?set)
- zero_or_one
subset/2
ï
True if Subset
is a subset of Set
.
static
subset(Subset,Set)
subset(+set,+set)
- zero_or_one
subtract/3
ï
True when Difference
contains all and only the elements of Set1
which are not also in Set2
.
static
subtract(Set1,Set2,Difference)
subtract(+set,+set,?set)
- zero_or_one
symdiff/3
ï
True if Difference
is the symmetric difference of Set1
and Set2
, containing all elements that are not in the sets intersection.
static
symdiff(Set1,Set2,Difference)
symdiff(+set,+set,?set)
- zero_or_one
union/3
ï
True if Union
is the union of Set1
and Set2
.
static
union(Set1,Set2,Union)
union(+set,+set,?set)
- zero_or_one
union/4
ï
True if Union
is the union of Set1
and Set2
and Difference
is the difference between Set2
and Set1
.
static
union(Set1,Set2,Union,Difference)
union(+set,+set,?set,?set)
- zero_or_one
Protected predicatesï
(none)
Private predicatesï
(none)
Operatorsï
(none)