edu.uoc.pfc.j2ee.jalonsod.mtp.helper
Class ModelMapperImpl

java.lang.Object
  extended by edu.uoc.pfc.j2ee.jalonsod.mtp.helper.ModelMapperImpl
All Implemented Interfaces:
ModelMapper

public class ModelMapperImpl
extends java.lang.Object
implements ModelMapper

File: ModelMapperImpl.java Created: 2012-04-28 ModelMapper implementation from the framework. The map algorithm is based on the MODEL parameter of the request.

Author:
José Alonso de Motta

Field Summary
private static java.util.logging.Logger logger
           
static java.lang.String MODEL_PARAMETER
           
 
Constructor Summary
ModelMapperImpl()
           
 
Method Summary
 void setRequestModel(RequestDataPrivate requestData)
          Sets into the requestData the model metadata object [setModel()] and creates the instance of the application model class [setModelInstance()].
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

private static final java.util.logging.Logger logger

MODEL_PARAMETER

public static final java.lang.String MODEL_PARAMETER
See Also:
Constant Field Values
Constructor Detail

ModelMapperImpl

public ModelMapperImpl()
Method Detail

setRequestModel

public void setRequestModel(RequestDataPrivate requestData)
                     throws MTPException
Description copied from interface: ModelMapper
Sets into the requestData the model metadata object [setModel()] and creates the instance of the application model class [setModelInstance()]. After the execution of this method, the model and the modelInstance attributes of the requestData object have been set.

Specified by:
setRequestModel in interface ModelMapper
Parameters:
requestData - the MTP requestData of the current request.
Throws:
MTPException - throws when there is a problem setting the model or creating the model instance.