A simple set class.
Sets are not in Python until 2.3, and rdata are not immutable so we
cannot use sets.Set anyway. This class implements subset of the 2.3 Set
interface using a list as the container.
|
|
|
|
|
|
|
remove(self,
item)
Remove an item from the set. |
source code
|
|
|
discard(self,
item)
Remove an item from the set if present. |
source code
|
|
|
|
|
__copy__(self)
Make a (shallow) copy of the set. |
source code
|
|
|
copy(self)
Make a (shallow) copy of the set. |
source code
|
|
|
union_update(self,
other)
Update the set, adding any elements from other which are not already
in the set. |
source code
|
|
|
|
|
|
the same type as self
|
union(self,
other)
Return a new set which is the union of self and other. |
source code
|
|
the same type as self
|
|
the same type as self
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
update(self,
other)
Update the set, adding any elements from other which are not already
in the set. |
source code
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
bool
|
issubset(self,
other)
Is self a subset of other? |
source code
|
|
bool
|
issuperset(self,
other)
Is self a superset of other? |
source code
|
|
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__setattr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|