Package org.jboss.msc.inject
Class SetMethodInjector<T>
- java.lang.Object
-
- org.jboss.msc.inject.SetMethodInjector<T>
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.reflect.Methodmethodprivate static java.lang.Object[]NULL_PARAMprivate Value<?>target
-
Constructor Summary
Constructors Constructor Description SetMethodInjector(Value<?> target, java.lang.reflect.Method method)Construct a new instance.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> Injector<T>create(Value<?> target, java.lang.reflect.Method method)Construct a new instance.voidinject(T value)Inject the given value.voiduninject()Uninject the given value (in other words, cancel or undo a previous injection).
-
-
-
Field Detail
-
NULL_PARAM
private static final java.lang.Object[] NULL_PARAM
-
target
private final Value<?> target
-
method
private final java.lang.reflect.Method method
-
-
Constructor Detail
-
SetMethodInjector
public SetMethodInjector(Value<?> target, java.lang.reflect.Method method)
Construct a new instance.- Parameters:
target- the object upon which the method is to be calledmethod- the method to invoke
-
-
Method Detail
-
create
public static <T> Injector<T> create(Value<?> target, java.lang.reflect.Method method)
Construct a new instance.- Parameters:
target- the object upon which the method is to be calledmethod- the method to invoke- Returns:
- the new instance
-
inject
public void inject(T value)
Inject the given value.
-
-