@Deprecated public abstract class AbstractValidatingMarshallingPayloadEndpoint extends AbstractMarshallingPayloadEndpoint
AbstractMarshallingPayloadEndpoint which validates the request payload with Validator(s). The desired validators can be set using properties, and must support the request object.| Modifier and Type | Field and Description |
|---|---|
static String |
DEFAULT_REQUEST_NAME
Deprecated.
Default request object name used for validating request objects.
|
logger| Constructor and Description |
|---|
AbstractValidatingMarshallingPayloadEndpoint()
Deprecated.
|
| Modifier and Type | Method and Description |
|---|---|
String |
getRequestName()
Deprecated.
Return the name of the request object for validation error codes.
|
Validator |
getValidator()
Deprecated.
Return the primary Validator for this controller.
|
Validator[] |
getValidators()
Deprecated.
Return the Validators for this controller.
|
protected boolean |
onUnmarshalRequest(MessageContext messageContext,
Object requestObject)
Deprecated.
Callback for post-processing in terms of unmarshalling.
|
protected abstract boolean |
onValidationErrors(MessageContext messageContext,
Object requestObject,
Errors errors)
Deprecated.
Callback for post-processing validation errors.
|
void |
setRequestName(String requestName)
Deprecated.
Set the name of the request object user for validation errors.
|
void |
setValidator(Validator validator)
Deprecated.
Set the primary
Validator for this endpoint. |
void |
setValidators(Validator[] validators)
Deprecated.
Set the Validators for this controller.
|
afterMarshallerSet, afterPropertiesSet, getMarshaller, getUnmarshaller, invoke, invokeInternal, onMarshalResponse, setMarshaller, setUnmarshallerpublic static final String DEFAULT_REQUEST_NAME
public AbstractValidatingMarshallingPayloadEndpoint()
public String getRequestName()
public void setRequestName(String requestName)
public Validator getValidator()
public void setValidator(Validator validator)
Validator for this endpoint. The Validator is must support the unmarshalled
class. If there are one or more existing validators set already when this method is called, only the specified
validator will be kept. Use setValidators(Validator[]) to set multiple validators.public Validator[] getValidators()
public void setValidators(Validator[] validators)
protected boolean onUnmarshalRequest(MessageContext messageContext, Object requestObject) throws Exception
AbstractMarshallingPayloadEndpointDefault implementation returns true.
onUnmarshalRequest in class AbstractMarshallingPayloadEndpointmessageContext - the message contextrequestObject - the object unmarshalled from the requesttrue to continue and call AbstractMarshallingPayloadEndpoint.invokeInternal(Object); false otherwiseExceptionprotected abstract boolean onValidationErrors(MessageContext messageContext, Object requestObject, Errors errors)
messageContext - the message contextrequestObject - the object unmarshalled from the requesterrors - validation errors holdertrue to continue and call AbstractMarshallingPayloadEndpoint.invokeInternal(Object); false otherwise