AshGrant.Domain.Info (AshGrant v0.17.0)

Copy Markdown View Source

Introspection helpers for AshGrant domain-level DSL configuration.

Used internally by AshGrant.Transformers.MergeDomainConfig to read domain-level settings and merge them into resources.

Summary

Functions

Returns true if the domain has the AshGrant.Domain extension configured.

Gets a specific scope by name from the domain.

Gets the permission resolver configured on the domain.

Gets all scope definitions from the domain.

Functions

configured?(domain)

@spec configured?(Ash.Domain.t()) :: boolean()

Returns true if the domain has the AshGrant.Domain extension configured.

get_scope(domain, name)

@spec get_scope(Ash.Domain.t(), atom()) :: AshGrant.Dsl.Scope.t() | nil

Gets a specific scope by name from the domain.

resolver(domain)

@spec resolver(Ash.Domain.t()) :: module() | function() | nil

Gets the permission resolver configured on the domain.

scopes(domain)

@spec scopes(Ash.Domain.t()) :: [AshGrant.Dsl.Scope.t()]

Gets all scope definitions from the domain.