de.akquinet.jbosscc.needle.annotation
Annotation Type InjectIntoMany


@Target(value=FIELD)
@Retention(value=RUNTIME)
public @interface InjectIntoMany

Is used to inject an instance into multiple ObjectUnderTest instances.

  Example 1:

  @InjectIntoMany
  private User user = new User();

  Example 2:

  @InjectIntoMany(value = {
        InjectInto(targetComponentId = "obejctUnderTest1"),
        InjectInto(targetComponentId = "obejctUnderTest2", fieldName = "user")
  })
  private User user = new User();
 


Optional Element Summary
 InjectInto[] value
          (Optional) the injection targets Default are all ObjectUnderTest annotated fields
 

value

public abstract InjectInto[] value
(Optional) the injection targets

Default are all ObjectUnderTest annotated fields

Default:
{}


Copyright © 2013 akquinet AG. All Rights Reserved.