atom.enum module

class atom.enum.Enum(*items)[source]

Bases: atom.catom.Member

A member where the value can be one in a sequence of items.

added(*items)[source]

Create a clone of the Enum with added items.

Parameters

*items – Additional items to include in the Enum.

Returns

result – A new enum object which contains all of the original items plus the new items.

Return type

Enum

property items

A readonly property which returns the items in the enum.

removed(*items)[source]

Create a clone of the Enum with some items removed.

Parameters

*items – The items to remove remove from the new enum.

Returns

result – A new enum object which contains all of the original items but with the given items removed.

Return type

Enum