Onyx logo

Previous topic

onyx.util.singleton – Support for singleton objects

Next topic

Evaluation Modules

This Page

onyx.util.versionset – Support for keeping track of a set of versions

class onyx.util.versionset.VersionSet(iterable)

Bases: tuple

>>> vs0 = VersionSet((1, 2, 3, (7, 11)))
>>> [v in vs0 for v in (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)]
[True, True, True, False, False, False, True, True, True, True, True, False, False]
count

T.count(value) -> integer – return number of occurrences of value

index

T.index(value, [start, [stop]]) -> integer – return first index of value. Raises ValueError if the value is not present.