public class BindingLoader extends Object
Binding
object based on QName
. It can handle storage of classes that support the ComponentAdapter
interface or other classes but will attempt to instantiate and return a Binding
object.
It uses a Context (otherwise known as PicoContainer) to instantiate the relevant object and understand the dependencies that should also be loaded. The Context is required to be passed in by the caller
Constructor and Description |
---|
BindingLoader(Map<QName,Object> bindings) |
Modifier and Type | Method and Description |
---|---|
protected ComponentAdapter |
getBinding(QName type)
Returns the component adapter for a binding with the specified name.
|
Binding |
loadBinding(QName qName,
Class bindingClass,
PicoContainer context)
Loads a binding with a specific class into a context.
|
Binding |
loadBinding(QName qName,
PicoContainer context)
Loads a binding with a specific QName into a context.
|
public Binding loadBinding(QName qName, PicoContainer context)
qName
- The qualified name of the type of the binding object.context
- The context which is to contain the binding.public Binding loadBinding(QName qName, Class bindingClass, PicoContainer context)
bindingClass
- The class of the binding.context
- The context which is to contain the binding.protected ComponentAdapter getBinding(QName type)
type
- The qualified name of the type of the binding.Copyright © 1996–2022 Geotools. All rights reserved.