RAMEN Core
    Preparing search index...

    Class Modeller

    Creates and refines generic models while retaining dependencies, validation and suggestions.

    Hierarchy

    Index
    • Returns an advisor or explains why the current model cannot provide suggestions.

      Returns ModelAdvisor

      When the current project is invalid and cannot provide modelling suggestions.

    • Returns a detached declared data type, or undefined when absent. Built-in types have no declaration.

      Parameters

      Returns DataType | undefined

    • Returns a detached snapshot of the current project model.

      Returns Model

    • Returns detached snapshots of the current model and every transitive dependency.

      Returns readonly Model[]

    • Returns the node that refines every selected node, or undefined for separate branches.

      Parameters

      Returns Node | undefined

    • Returns a detached local or imported node, or undefined when absent. Ambiguous local IDs require a qualified reference.

      Parameters

      Returns Node | undefined

    • Returns detached project information, independently of the selected model level.

      Returns ProjectMetadata | undefined

    • Returns a detached local or imported relation, or undefined when absent.

      Parameters

      Returns Relation | undefined

    • Lists existing relationships with exact endpoints, including permitted predecessor definitions. Returns an empty list for no matches and all matches for parallel relationships; never edits the model. Requires valid node references and a valid model snapshot.

      Parameters

      Returns readonly RelationSelection[]

    • Opens another model in this editable workspace, including an imported predecessor.

      Parameters

      • modelId: string

      Returns Modeller

      When the requested model is not in this workspace.

    • Shows the chosen next level and every later level that imports it.

      Parameters

      • modelId: string

      Returns ModelRemovalPreview

    • Shows every declaration that would be removed with this node.

      Parameters

      • nodeId: string

      Returns NodeRemovalPreview

    • Shows relation refinements affected by removal.

      Parameters

      • relationId: string

      Returns RelationRemovalPreview

    • Removes an attribute by stable identifier and validates the resulting project.

      Parameters

      • nodeId: string
      • attributeId: string

      Returns ModelChange<Attribute>

    • Removes one rule by ID from a local element while preserving its other rules.

      Parameters

      Returns ModelChange<Constraint>

      When the owner is unavailable, ambiguous or imported, or does not declare this constraint ID.

    • Removes a local data type; unresolved references remain visible in validation diagnostics.

      Parameters

      • dataTypeId: string

      Returns ModelChange<DataType>

    • Removes one literal; an empty data type becomes unrestricted again.

      Parameters

      • dataTypeId: string
      • literalId: string

      Returns ModelChange<Literal>

    • Removes a next level; cascade also removes every level that depends on it.

      Parameters

      • modelId: string
      • options: { cascade?: boolean } = {}

      Returns ModelRemovalPreview

      When the level is not an immediate successor, or later levels depend on it and cascade is disabled.

    • Removes an unused node, or atomically removes its dependent definitions with cascade.

      Parameters

      • nodeId: string
      • options: { cascade?: boolean } = {}

      Returns ModelChange<Node>

      When the node is not local, dependants exist without cascade, or malformed domain-specific declarations prevent safe removal.

    • Removes an unused relation, or its dependants with explicit cascade.

      Parameters

      • relationId: string
      • options: { cascade?: boolean } = {}

      Returns ModelChange<Relation>

      When the relation is not local, dependants exist without cascade, or malformed domain-specific declarations prevent safe removal.

    • Captures the entire editable model workspace, including sibling levels, as an independent state.

      Returns Modeller

    • Lists local and imported node types that this level can refine.

      Returns readonly NodeSuggestion[]

    • Updates a level that directly imports this model.

      Parameters

      Returns Model

    • Checks one local or inherited attribute input. Custom evaluators must work without a data graph. Invalid projects and values return diagnostics.

      Parameters

      Returns ValidationResult

      When the node is unavailable or ambiguous, or the named attribute is not visible on it.

    • Checks one value against a built-in or declared data type, including literals and value rules. Invalid projects and values return diagnostics.

      Parameters

      Returns ValidationResult

      When the selected data type is unavailable or its reference is ambiguous.

    • Creates a root modelling language. A name is enough; identity fields remain configurable.

      Parameters

      Returns Modeller

    • Creates a level from an existing model and the dependencies it needs.

      Parameters

      Returns Modeller

    • Loads a shared graph and restores its project context without a consumer-side model selection.

      Parameters

      • input: unknown

      Returns Modeller

      When the file format is unsupported, the document or project is invalid, or the selected root cannot be restored.

    • Opens an existing generic model for editing, with its dependency models.

      Parameters

      Returns Modeller