public class AdapterMaps
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static MapBinder<AdapterKey<?>,java.lang.Object> |
getAdapterMapBinder(Binder binder,
java.lang.Class<? extends IAdaptable> adaptableType)
Returns a
MapBinder , which can be used to define adapter bindings
for an IAdaptable s of the given type. |
static MapBinder<AdapterKey<?>,java.lang.Object> |
getAdapterMapBinder(Binder binder,
java.lang.Class<? extends IAdaptable> adaptableType,
AdapterKey<?>... adaptableContext)
Returns a
MapBinder , which can be used to define adapter bindings
for an IAdaptable s of the given type, restricting it further to
those IAdaptable s that are themselves
adapted to another
IAdaptable with the specified role. |
public static MapBinder<AdapterKey<?>,java.lang.Object> getAdapterMapBinder(Binder binder, java.lang.Class<? extends IAdaptable> adaptableType)
MapBinder
, which can be used to define adapter bindings
for an IAdaptable
s of the given type.public static MapBinder<AdapterKey<?>,java.lang.Object> getAdapterMapBinder(Binder binder, java.lang.Class<? extends IAdaptable> adaptableType, AdapterKey<?>... adaptableContext)
MapBinder
, which can be used to define adapter bindings
for an IAdaptable
s of the given type, restricting it further to
those IAdaptable
s that are themselves
adapted
to another
IAdaptable
with the specified role.binder
- The Binder
used to create a new MapBinder
.adaptableType
- The type to be used as type of the AdapterMap
.adaptableContext
- A specification of the context the adaptable, into which
adapters are to be injected, has to provide. If specified the
injection will be restricted to IAdaptable
s with a
compatible context only. The context of an adaptable is
compatible when respective context elements are visited in the
given order when walking the adaptable-adapter chain,
beginning with the adaptable in which to inject. The actual
chain may contain additional elements, that do not correspond
to context element, in between (which are ignored), but it has
to contain the specified context elements in the given order.MapBinder
used to define adapter map bindings for
the given type (and all sub-types).Copyright (c) 2014 itemis AG and others. All rights reserved.