|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.elasticsearch.common.inject.spi.Dependency<T>
public final class Dependency<T>
A variable that can be resolved by an injector.
Use get(org.elasticsearch.common.inject.Key
to build a freestanding dependency, or InjectionPoint
to build one
that's attached to a constructor, method or field.
Method Summary | ||
---|---|---|
boolean |
equals(java.lang.Object o)
|
|
static java.util.Set<Dependency<?>> |
forInjectionPoints(java.util.Set<InjectionPoint> injectionPoints)
Returns the dependencies from the given injection points. |
|
static
|
get(Key<T> key)
Returns a new dependency that is not attached to an injection point. |
|
InjectionPoint |
getInjectionPoint()
Returns the injection point to which this dependency belongs, or null if this dependency isn't attached to a particular injection point. |
|
Key<T> |
getKey()
Returns the key to the binding that satisfies this dependency. |
|
int |
getParameterIndex()
Returns the index of this dependency in the injection point's parameter list, or -1 if
this dependency does not belong to a parameter list. |
|
int |
hashCode()
|
|
boolean |
isNullable()
Returns true if null is a legal value for this dependency. |
|
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Method Detail |
---|
public static <T> Dependency<T> get(Key<T> key)
public static java.util.Set<Dependency<?>> forInjectionPoints(java.util.Set<InjectionPoint> injectionPoints)
public Key<T> getKey()
public boolean isNullable()
public InjectionPoint getInjectionPoint()
public int getParameterIndex()
-1
if
this dependency does not belong to a parameter list. Only method and constuctor dependencies
are elements in a parameter list.
public int hashCode()
hashCode
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public java.lang.String toString()
toString
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |