MetamodelEntity

open class MetamodelEntity(val name: String? = null, val description: String? = null, val asil: ASIL? = null, val issues: List<IssueReference> = emptyList(), val sources: List<URLReference> = emptyList())

Base type for Highway entities participating in model identity, registration, and ownership. Other Highway types, such as DataType and DocumentMetadata, do not extend this class.

Keep this class small and stable: new common metadata fields can be added here in the future (e.g. responsible, owner, lifecycle state).

name / description / asil are nullable authoring attributes. Type contracts and model rules determine which are required or inapplicable for each entity type, and report missing required values as HIGH. They must not be used as identifiers and may be duplicated across entities. The canonical unique identifier is id, computed from the declaring context and the Kotlin val name captured into referenceName by model wiring. The read-only fullLabel, idLabel, and shortIdLabel extensions provide presentation text without adding stored attributes or changing identity.

Registry / scope

Every constructed entity is registered in the current ModelScope — see allInstancesSnapshot; the wireup pass and structural-consistency rules iterate it. Without an explicit scope, construction targets the process-global default scope (ModelScope.global). WireModel.reset clears the current scope — call it once per stigCheckModel invocation so that companion-static state from a previous Gradle-daemon run does not leak into the new one.

Live source-materializers (the IDEA plugin) wrap their work in ModelScope.with(scope) { … } so that per-file materialization runs in an isolated registry and does not interfere with other open files or with the global default.

Inheritors

Constructors

Link copied to clipboard
constructor(name: String? = null, description: String? = null, asil: ASIL? = null, issues: List<IssueReference> = emptyList(), sources: List<URLReference> = emptyList())

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
open val asil: ASIL?
Link copied to clipboard

Identity of the authored Kotlin declaration, independent of its receiving model instance. Inherited declarations retain this provenance while id distinguishes each owning instance.

Link copied to clipboard

Fully-qualified name of the declaring context. Prefers declaringClassNameOverride (set explicitly by source materializers or canonical-ID binding) over declaringClass's captured name; falls back to null if neither is available.

Link copied to clipboard
open val description: String?
Link copied to clipboard
val id: String

Fully-qualified unique identifier of this model instance. A member follows its actual owning instance, so two instances of the same user class have distinct member IDs. declarationId retains the common source declaration for navigation and naming rules.

Link copied to clipboard
Link copied to clipboard
open val name: String?
Link copied to clipboard

Kotlin val name that holds this entity, scoped to its declaring context. Populated reflectively by WireModel.wireAll in the compiled path, or set directly via bindToSource in the source-materialized path. null until either runs.

Link copied to clipboard

Functions

Link copied to clipboard

Binds an authored field or constructor-owned value without replacing its source declaration provenance.

Link copied to clipboard

Registers a child entity declared inside a source-materialized parent.

Link copied to clipboard

Records source-declared uses without changing the target's declaration or owner.

Link copied to clipboard

Binds an entity to an already computed canonical MetamodelEntity.id.

Link copied to clipboard
fun MetamodelEntity.bindToSource(referenceName: String, declaringClassName: String)

Sets the canonical identifiers for an entity that was materialized from source (as opposed to being instantiated from compiled bytecode). Intended for use by PSI / source materializers such as the IDEA plugin.

Link copied to clipboard

Interface-point analyses in declaration order, including analyses nested beneath ports or service groups.

Link copied to clipboard

Structural children, including explicit metamodel containment. Relation targets retain their own declaration.

Link copied to clipboard
Generated with STIG