ash v0.2.0 Ash.Resource behaviour View Source
A resource is a static definition of an entity in your system.
Resource DSL documentation: Ash.Resource.DSL
The following options apply to use Ash.Resource, [...]
:name
- Required. The name of the resource, e.gposts
orauthors
. This will typically be the pluralized form of the type:type
- Required. The type of the resource, e.gpost
orauthor
. This is used throughout the system.
For more information on the resource DSL, see Ash.Resource.DSL
Note:
Do not call the functions on a resource, as in MyResource.type()
as this is a private
API and can change at any time. Instead, use the Ash
module, for example: Ash.type(MyResource)
Link to this section Summary
Callbacks
A list of actions available for the resource
A list of attributes on the resource
A list of authorizers to be used when accessing the resource
The data_layer in use by the resource, or nil if there is not one
A description of the resource, to be showed in generated documentation
A list of extensions implemented by the resource
The name of the resource, e.g 'posts'
A list of attribute names that make up the primary key, e.g [:class, :group]
A list of relationships to other resources
The type of the resource, e.g 'post'
Link to this section Callbacks
A list of actions available for the resource
A list of attributes on the resource
A list of authorizers to be used when accessing the resource
The data_layer in use by the resource, or nil if there is not one
A description of the resource, to be showed in generated documentation
A list of extensions implemented by the resource
The name of the resource, e.g 'posts'
A list of attribute names that make up the primary key, e.g [:class, :group]
A list of relationships to other resources
The type of the resource, e.g 'post'