tools submodule

Useful functions used by multiple structures.

cz_urnnbn_api.api_structures.tools.both_set_and_different(first, second)

If any of both arguments are unset (=``None``), return False. Otherwise return result of unequality comparsion.

Returns:True if both arguments are set and different.
Return type:bool
cz_urnnbn_api.api_structures.tools.to_list(tag)

Put tag to list if it ain’t list/tuple already.

Parameters:tag (obj) – Anything.
Returns:Tag.
Return type:list