SparkseePython
6.0.2
|
Object identifier set class. More...
Public Member Functions | |
def | copy (self, objs) |
Performs the copy operation. More... | |
def | count (self) |
Gets the number of elements into the collection. More... | |
def | equals (self, objs) |
Checks if the given Objects contains the same information. More... | |
def | any (self) |
Gets an element from the collection. More... | |
def | contains (self, objs) |
Check if this objects contains the other one. More... | |
def | combine_intersection (self, objs1, objs2) |
Creates a new Objects instance which is the intersection of the two given. More... | |
def | __iter__ (self) |
Gets a new ObjectsIterator. More... | |
def | iterator (self) |
Gets an ObjectsIterator. More... | |
def | union (self, objs) |
Performs the union operation. More... | |
def | combine_union (self, objs1, objs2) |
Creates a new Objects instance which is the union of the two given. More... | |
def | intersection (self, objs) |
Performs the intersection operation. More... | |
def | clear (self) |
Clears the collection removing all its elements. | |
def | iterator_from_index (self, index) |
Gets an ObjectsIterator skipping index elements. More... | |
def | exists (self, e) |
Gets if the given element exists into the collection. More... | |
def | copy (self) |
Creates a new Objects instance as a copy of the given one. More... | |
def | difference (self, objs) |
Performs the difference operation. More... | |
def | combine_difference (self, objs1, objs2) |
Creates a new Objects instance which is the difference of the two given. More... | |
def | sample (self, exclude, samples) |
Creates a new Objects instance which is a sample of the calling one. More... | |
def | close (self) |
Closes the Objects instance. More... | |
def | add (self, e) |
Adds an element into the collection. More... | |
def | remove (self, e) |
Removes an element from the collection. More... | |
def | iterator_from_element (self, e) |
Gets an ObjectsIterator starting from the given element. More... | |
def | is_closed (self) |
Gets if Objects instance has been closed or not. More... | |
Static Public Attributes | |
int | INVALID_OID = 0 |
Invalid OID constant. | |
Object identifier set class.
It stores a collection of Sparksee object identifiers as a set. As a set, there is no order and no duplicated elements.
This class should be used just to store large collections. Otherwise, it is strongly recommended to use common classes from the language API.
This class is not thread-safe.
ObjectsIterator must be used to traverse all the elements into the set.
When the Objects instance is closed, it closes all existing and non-closed ObjectsIterator instances too.
def sparksee.Objects.__iter__ | ( | self | ) |
Gets a new ObjectsIterator.
def sparksee.Objects.add | ( | self, | |
e | |||
) |
Adds an element into the collection.
e | [in] Element to be added. |
def sparksee.Objects.any | ( | self | ) |
Gets an element from the collection.
RuntimeError | null |
RuntimeError | whether the collection is empty. |
def sparksee.Objects.close | ( | self | ) |
Closes the Objects instance.
It must be called to ensure the integrity of all data.
def sparksee.Objects.combine_difference | ( | self, | |
objs1, | |||
objs2 | |||
) |
def sparksee.Objects.combine_intersection | ( | self, | |
objs1, | |||
objs2 | |||
) |
def sparksee.Objects.combine_union | ( | self, | |
objs1, | |||
objs2 | |||
) |
def sparksee.Objects.contains | ( | self, | |
objs | |||
) |
Check if this objects contains the other one.
objs | Objects collection. |
def sparksee.Objects.copy | ( | self, | |
objs | |||
) |
Performs the copy operation.
This updates the Objects calling instance and copies the given Objects instance.
objs | [in] Objects instance. |
Referenced by sparksee.Objects.copy().
def sparksee.Objects.copy | ( | self | ) |
Creates a new Objects instance as a copy of the given one.
References sparksee.Objects.copy().
def sparksee.Objects.count | ( | self | ) |
Gets the number of elements into the collection.
def sparksee.Objects.difference | ( | self, | |
objs | |||
) |
def sparksee.Objects.equals | ( | self, | |
objs | |||
) |
def sparksee.Objects.exists | ( | self, | |
e | |||
) |
Gets if the given element exists into the collection.
e | [in] Element. |
def sparksee.Objects.intersection | ( | self, | |
objs | |||
) |
def sparksee.Objects.is_closed | ( | self | ) |
def sparksee.Objects.iterator | ( | self | ) |
Gets an ObjectsIterator.
def sparksee.Objects.iterator_from_element | ( | self, | |
e | |||
) |
Gets an ObjectsIterator starting from the given element.
Objects collection has no order, so this method is implementation-dependent. e[in] The first element to traverse in the resulting
e | [in] The first element to traverse in the resulting ObjectsIterator instance. |
def sparksee.Objects.iterator_from_index | ( | self, | |
index | |||
) |
Gets an ObjectsIterator skipping index elements.
Objects collection has no order, so this method is implementation-dependent.
index | [in] The number of elements to skip from the beginning. It must be in the range [0..Size). |
def sparksee.Objects.remove | ( | self, | |
e | |||
) |
Removes an element from the collection.
e | [in] Element to be removed. |
def sparksee.Objects.sample | ( | self, | |
exclude, | |||
samples | |||
) |
Creates a new Objects instance which is a sample of the calling one.
exclude | [in] If not NULL, elements into this collection will be excluded from the resulting one. |
samples | [in] Number of elements into the resulting collection. |