diff options
-rw-r--r-- | lib/Bread/Board/Declare.pm | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/Bread/Board/Declare.pm b/lib/Bread/Board/Declare.pm index a0a3789..26d911d 100644 --- a/lib/Bread/Board/Declare.pm +++ b/lib/Bread/Board/Declare.pm @@ -84,6 +84,12 @@ Constructor parameters for services (C<dependencies>, C<lifecycle>, etc) can also be passed into the attribute definition; these will be forwarded to the service constructor. +If C<< infer => 1 >> is passed in the attribute definition, the class in the +type constraint will be introspected to find its required dependencies, and +those dependencies will be automatically fulfilled as much as possible by +corresponding services in the container. See +L<Bread::Board::Manual::Concepts::Typemap> for more information. + In addition to creating the services, this module also modifies the attribute reader generation, so that if the attribute has no value, a value will be resolved from the associated service. It also modifies the C<get> method on |