krrood.patterns.identifier_and_name

krrood.patterns.identifier_and_name#

Attributes#

NameT

The kind of name an object is called by.

Classes#

HasID

Gives an object an identifier, which tells it apart from every other object, so that

HasName

Gives an object a name that people call it by, which need not tell it apart from

Module Contents#

class krrood.patterns.identifier_and_name.HasID#

Bases: krrood.patterns.mixin.Mixin, krrood.patterns.interface.Interface

Gives an object an identifier, which tells it apart from every other object, so that others can refer to it by the identifier instead of holding a copy of it.

id: uuid.UUID#

The identifier that tells this object apart from every other object.

krrood.patterns.identifier_and_name.NameT#

The kind of name an object is called by.

class krrood.patterns.identifier_and_name.HasName#

Bases: Generic[NameT], krrood.patterns.subclass_safe_generic.SubClassSafeGeneric, krrood.patterns.mixin.Mixin, krrood.patterns.interface.Interface

Gives an object a name that people call it by, which need not tell it apart from other objects.

name: NameT#

What the object is called.