|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface PrivateBinder
Returns a binder whose configuration information is hidden from its environment by default. See
PrivateModule
for details.
Method Summary | |
---|---|
AnnotatedElementBuilder |
expose(Class<?> type)
Makes a binding for type available to the enclosing environment. |
void |
expose(Key<?> key)
Makes the binding for key available to the enclosing environment |
AnnotatedElementBuilder |
expose(TypeLiteral<?> type)
Makes a binding for type available to the enclosing environment. |
PrivateBinder |
skipSources(Class... classesToSkip)
Returns a binder that skips classesToSkip when identify the
calling code. |
PrivateBinder |
withSource(Object source)
Returns a binder that uses source as the reference location for
configuration errors. |
Methods inherited from interface com.google.inject.Binder |
---|
addError, addError, addError, bind, bind, bind, bindConstant, bindInterceptor, bindListener, bindScope, convertToTypes, currentStage, getMembersInjector, getMembersInjector, getProvider, getProvider, install, newPrivateBinder, requestInjection, requestInjection, requestStaticInjection |
Method Detail |
---|
void expose(Key<?> key)
key
available to the enclosing environment
AnnotatedElementBuilder expose(Class<?> type)
type
available to the enclosing environment. Use annotatedWith()
to expose type
with a
binding annotation.
AnnotatedElementBuilder expose(TypeLiteral<?> type)
type
available to the enclosing environment. Use annotatedWith()
to expose type
with a
binding annotation.
PrivateBinder withSource(Object source)
Binder
source
as the reference location for
configuration errors. This is typically a StackTraceElement
for .java
source but it could any binding source, such as the
path to a .properties
file.
withSource
in interface Binder
source
- any object representing the source location and has a
concise toString()
value
PrivateBinder skipSources(Class... classesToSkip)
Binder
classesToSkip
when identify the
calling code. The caller's StackTraceElement
is used to locate
the source of configuration errors.
skipSources
in interface Binder
classesToSkip
- library classes that create bindings on behalf of
their clients.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |