View Source Smokestack.Builder behaviour (smokestack v0.4.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
Given a builder and a factory, validate it's options and call 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.OptionsHelpers.schema()} | {:error, any()}
Provide a schema for validating options.
Functions
@spec build(t(), Smokestack.Dsl.Factory.t(), Keyword.t()) :: {:ok, result()} | {:error, error()}
Given a builder and a factory, validate it's options and call the builder.
@spec docs(t(), nil | Smokestack.Dsl.Factory.t()) :: String.t()
Generate documentation for the available options.