This class should not be constructed directly. Parent class to SetWrapper
s.
set6::Set
-> SetWrapper
wrappedSets
Returns the list of Set
s that are wrapped in the given wrapper.
new()
Create a new SetWrapper
object. It is not recommended to construct this class directly.
SetWrapper$new( setlist, lower = NULL, upper = NULL, type = NULL, class = NULL, cardinality )
setlist
List of Sets to wrap.
lower
Set. Lower bound of wrapper.
upper
Set. Upper bound of wrapper.
type
character. Closure type of wrapper.
class
character. Ignored.
cardinality
character or integer. Cardinality of wrapper.
A new SetWrapper
object.
equals()
Tests if x
is equal to self
.
SetWrapper$equals(x, all = FALSE)
x
any. Object or vector of objects to test.
all
logical. If FALSE
tests each x
separately. Otherwise returns TRUE
only if all x
pass test.
all
logical. If FALSE
tests each x
separately. Otherwise returns TRUE
only if all x
pass test.
If all == TRUE
then returns TRUE
if all x
are equal to self
, otherwise FALSE
.
If all == FALSE
returns a vector of logicals corresponding to the length of x
, representing
if each is equal to self
.
isSubset()
Tests if x
is a (proper) subset of self
.
SetWrapper$isSubset(x, proper = FALSE, all = FALSE)
x
any. Object or vector of objects to test.
proper
logical. If TRUE
tests for proper subsets.
all
logical. If FALSE
tests each x
separately. Otherwise returns TRUE
only if all x
pass test.
all
logical. If FALSE
tests each x
separately. Otherwise returns TRUE
only if all x
pass test.
If all == TRUE
then returns TRUE
if all x
are (proper) subsets of self
, otherwise FALSE
.
If all == FALSE
returns a vector of logicals corresponding to the length of x
, representing
if each is a (proper) subset of self
.
clone()
The objects of this class are cloneable with this method.
SetWrapper$clone(deep = FALSE)
deep
Whether to make a deep clone.