[−][src]Trait shaku::component::Component
Components provide a service by implementing an interface. They may use other components as dependencies.
This trait is normally derived, but if the derive
feature is turned off
then it will need to be implemented manually.
Associated Types
Loading content...Required methods
fn dependencies() -> Vec<Dependency>
The other components which this component depends on.
fn build(
build_context: &mut ContainerBuildContext,
params: &mut ParameterMap
) -> Result<()>
build_context: &mut ContainerBuildContext,
params: &mut ParameterMap
) -> Result<()>
Use the build context and parameters to create the component. The
created component must be inserted into the build context via
ContainerBuildContext::insert
.