View Source Smokestack.Builder behaviour (smokestack v0.9.1)
A generic behaviour for "building things".
Summary
Callbacks
Given a Factory entity and some options build something.
Provide a schema for validating options.
Functions
Find the appropriate factory, validate options and run the builder.
Generate documentation for the available options.
Types
Callbacks
@callback build(Smokestack.Dsl.Factory.t(), Keyword.t()) :: {:ok, result()} | {:error, error()}
Given a Factory entity and some options build something.
@callback option_schema(nil | Smokestack.Dsl.Factory.t()) :: {:ok, Spark.Options.schema(), String.t()} | {:error, any()}
Provide a schema for validating options.
Functions
@spec build(Smokestack.t(), Ash.Resource.t(), t(), Keyword.t()) :: {:ok, result()} | {:error, error()}
Find the appropriate factory, validate options and run the builder.
@spec docs(t(), nil | Smokestack.Dsl.Factory.t()) :: String.t()
Generate documentation for the available options.