AshScenario.Dsl.Prototype (ash_scenario v0.6.0)

View Source

Defines a prototype entity that dynamically accepts attributes and relationships based on the containing Ash resource's schema.

This replaces the previous resources/resource naming to avoid collisions with other Spark/Ash DSLs. The semantics are unchanged.

Summary

Types

t()

@type t() :: %AshScenario.Dsl.Prototype{
  __identifier__: atom(),
  __spark_metadata__: term(),
  action: atom() | nil,
  actor: atom() | {module(), atom()} | nil,
  attr: list() | nil,
  attributes: keyword() | map(),
  attrs: list() | nil,
  create: AshScenario.Dsl.Create.t() | nil,
  function:
    ({map(), keyword()} -> {:ok, any()} | {:error, any()}) | mfa() | nil,
  ref: atom(),
  values: list() | nil,
  virtuals: MapSet.t() | list() | nil
}