public class ModelAdapterFactory
extends AdapterFactoryImpl
createXXX method for each class of the model.
ModelPackage| Modifier and Type | Field and Description |
|---|---|
protected static ModelPackage |
modelPackage
The cached model package.
|
protected ModelSwitch<Adapter> |
modelSwitch
The switch that delegates to the
createXXX methods. |
| Constructor and Description |
|---|
ModelAdapterFactory()
Creates an instance of the adapter factory.
|
| Modifier and Type | Method and Description |
|---|---|
Adapter |
createAdapter(Notifier target)
Creates an adapter for the
target. |
Adapter |
createEMongoCursorAdapter()
Creates a new adapter for an object of class '
EMongo Cursor'. |
Adapter |
createEMongoQueryAdapter()
Creates a new adapter for an object of class '
EMongo Query'. |
Adapter |
createEObjectAdapter()
Creates a new adapter for the default case.
|
Adapter |
createIterableAdapter()
Creates a new adapter for an object of class '
Iterable'. |
boolean |
isFactoryForType(java.lang.Object object)
Returns whether this factory is applicable for the type of the object.
|
protected static ModelPackage modelPackage
protected ModelSwitch<Adapter> modelSwitch
createXXX methods.
public ModelAdapterFactory()
public boolean isFactoryForType(java.lang.Object object)
true if the object is either the model's package or is an instance object of the model.
public Adapter createAdapter(Notifier target)
target.
target - the object to adapt.target.public Adapter createIterableAdapter()
Iterable'.
This default implementation returns null so that we can easily ignore cases;
it's useful to ignore a case when inheritance will catch all the cases anyway.
java.lang.Iterablepublic Adapter createEMongoCursorAdapter()
EMongo Cursor'.
This default implementation returns null so that we can easily ignore cases;
it's useful to ignore a case when inheritance will catch all the cases anyway.
EMongoCursorpublic Adapter createEMongoQueryAdapter()
EMongo Query'.
This default implementation returns null so that we can easily ignore cases;
it's useful to ignore a case when inheritance will catch all the cases anyway.
EMongoQuerypublic Adapter createEObjectAdapter()
Bryan Hunt, Data In Motion Consulting