module documentation

Utility functions for managing bitarrays.

Function GetFreeSlot Helper method to get first available slot in a bitarray
Constant _AVAILABLE_SLOT Undocumented
def GetFreeSlot(slots, slot=None, reserve=False):

Helper method to get first available slot in a bitarray

Parameters
slots:bitarraythe bitarray to operate on
slot:integerif given we check whether the slot is free
reserve:booleanwhether to reserve the first available slot or not
Returns
the idx of the (first) available slot
Raises
errors.OpPrereqErrorIf all slots in a bitarray are occupied or the given slot is not free.
_AVAILABLE_SLOT =

Undocumented

Value
bitarray('0')