public final class GraphAnalysisLoader extends Loader
Binding.Resolver
suitable for tool use at build time. The bindings created by
this Binding.Resolver
have the correct dependency graph, but do not implement
Binding.get()
or Binding.injectMembers(T)
methods. They are only suitable
for graph analysis and error detection.Constructor and Description |
---|
GraphAnalysisLoader(ProcessingEnvironment processingEnv) |
Modifier and Type | Method and Description |
---|---|
Binding<?> |
getAtInjectBinding(String key,
String className,
ClassLoader classLoader,
boolean mustHaveInjections)
Returns a binding that uses
@Inject annotations, or null if no valid binding can
be found or created. |
<T> ModuleAdapter<T> |
getModuleAdapter(Class<T> moduleClass)
Returns a module adapter for
moduleClass or throws a TypeNotPresentException if
none can be found. |
StaticInjection |
getStaticInjection(Class<?> injectedClass)
Returns the static injection for
injectedClass . |
instantiate, loadClass
public GraphAnalysisLoader(ProcessingEnvironment processingEnv)
public Binding<?> getAtInjectBinding(String key, String className, ClassLoader classLoader, boolean mustHaveInjections)
Loader
@Inject
annotations, or null if no valid binding can
be found or created.getAtInjectBinding
in class Loader
public <T> ModuleAdapter<T> getModuleAdapter(Class<T> moduleClass)
Loader
moduleClass
or throws a TypeNotPresentException
if
none can be found.getModuleAdapter
in class Loader
public StaticInjection getStaticInjection(Class<?> injectedClass)
Loader
injectedClass
.getStaticInjection
in class Loader
Copyright © 2019 Square, Inc.. All rights reserved.