M - El tipo de los valores que maneja el modelo.V - El tipo de los valores que maneja la vista.public interface Transformer<M,V>
| Modifier and Type | Method and Description |
|---|---|
Class<M> |
getModelType()
Returns the class of the values in the model side.
|
Class<V> |
getViewType()
Returns the class of the values in the view side.
|
V |
modelToView(M valueFromModel)
Convert and/or validate a value coming from the model to the type and/or format needed in the view.
|
M |
viewToModel(V valueFromView)
Convert and/or validate a value coming from the view to the type and/or format needed in the model.
|
M viewToModel(V valueFromView)
valueFromView - A value coming from de vieworg.uqbar.commons.model.UserException - Si hay un error que se debe mostrar al usuario.RuntimeException - Si hay cualquier otro tipo de error, interno al programa.V modelToView(M valueFromModel)
valueFromModel - A value coming from the modelorg.uqbar.commons.model.UserException - Si hay un error que se debe mostrar al usuario.RuntimeException - Si hay cualquier otro tipo de error, interno al programa.Copyright © 2015 Uqbar Project. All rights reserved.