@PetiteInject. In our example, so far, container did not resolved the dependency since no annotation is used. To make previous example work, the
Fooclass needs to mark the injection point:
bar(ignored as equals to #1)
@PetiteInjectannotation is method injection point. References will be injected through any number of method arguments:
@PetiteInjectannotation, separated by a comma.
Fooclass may be modified as:
NONE- no wiring, used in (rare) cases to prevent any possible
DEFAULT- wiring mode is set by Petite container configuration.
STRICT- strict wiring affects only property injection points. When
@PetiteInjection) and throws an exception if required reference
OPTIONAL- relaxed version of previous mode also inject into
AUTOWIRE- tries to inject value in all bean fields. Missing