Internal Development Interface

Package classcore.__

Common constants, imports, and utilities.

classcore.__.dictproxy_empty: collections.abc.Mapping[str, str] = mappingproxy({})

Module classcore.__.imports

Common imports used throughout the package.

Module classcore.__.nomina

Common names and type aliases.

type classcore.__.nomina.ComparisonResult = bool | builtins.NotImplementedType
type classcore.__.nomina.NominativeArguments = collections.abc.Mapping[str, Any]
type classcore.__.nomina.PositionalArguments = collections.abc.Sequence[Any]
class classcore.__.nomina.AttrnameCalculator(package_name='classcore')

Bases: object

Calculates framework attribute names from level and core.

Reference implementation of the attribute namer convention: call instances to produce names, and consult is_internal_name to detect names this framework generated. The package prefix is construction-time configuration (default: this package): downstream packages construct with their own prefix rather than overriding either method, and it is read-only thereafter: assignment raises, so a registered prefix cannot drift. Detection consults the reserved framework grammar (shape conformance, not proof of generation); generation emits the class-level mangling stems whose bare forms the detector does not accept. Downstream callers writing conformance or drift tests can detect a generated name without the private mangled-core vocabulary: try the bare form first, then the form with 64 ‘a’ characters appended, which covers the two class-level mangling stems the bare form never matches.

is_internal_name(name)
Parameters:
  • self

  • name (str)

Return type:

bool

property package_name

Package prefix this calculator generates and detects.

Parameters:

self

Return type:

str

classcore.__.nomina.calculate_contribution_name()

Returns metaclass attribute name holding internal-name detectors.

Return type:

str