| nl.knowlogy.validation.Messages
All known Subclasses: nl.knowlogy.validation.MessagesImpl,
Messages | public interface Messages extends Serializable(Code) | |
A Messages is a message container,in which messages are
stored during validating and is used to provide feedback about the
validation.
See Also: Message author: Robert |
Method Summary | |
void | addMessage(Message message) Stores an message in the messages. | void | addMessage(MessageType messageType, Object object, String messageCode)
Stores and creates an Message in the messages, based
on the give params. | void | addMessage(MessageType messageType, Object object, String messageCode, String defaultMessage) Add a message. | void | addMessage(MessageType messageType, Object object, String messageCode, Object[] messageArgs, String defaultMessage) Add a message. | void | addMessages(Messages messages) Adds messages. | void | addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode) Add a message for a specific property of the object. | void | addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode, String defaultMessage) Add a message for a specific property of the object. | void | addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode, Object[] messageArgs, String defaultMessage) Add a message for a specific property of the object. | void | clear() Clears all messages in the container. | void | convertMessageCodes(ResourceBundle resourceBundle) | Message | getMessage(Object object, String propertyName) Returns the first message associated with the given object and propertyName, if such
a message is present else null.
Parameters: object - object that is associated with the message. Parameters: propertyName - that is associated with the message. | Message | getMessage(Object object, boolean objectLevelOnly) | String | getMessage() Returns an overal messageMessage. | List | getMessages(Object object, String propertyName) Returns a list of Message instances associated with the given object and propertyName, if such
a message is present.
Parameters: object - object that is associated with the message. Parameters: propertyName - that is associated with the message. | List | getMessages(Object object, boolean objectLevelOnly) | List | getMessages() | int | getNumberOfErrorMessages() | int | getNumberOfMessages() Returns the number of message's. | int | getNumberOfMessages(MessageType messageType) Returns the number of messages with a specific messagetype. |
addMessage | void addMessage(Message message)(Code) | | Stores an message in the messages.
Parameters: message - message to add |
addMessage | void addMessage(MessageType messageType, Object object, String messageCode)(Code) | |
Stores and creates an Message in the messages, based
on the give params.
These messages are not bound to a specific property of the object.
Parameters: messageType - type of the message Parameters: object - the rejected object Parameters: messageCode - message code, interpretable as message key |
addMessage | void addMessage(MessageType messageType, Object object, String messageCode, String defaultMessage)(Code) | | Add a message.
Parameters: messageType - type of the message Parameters: messageCode - message code, interpretable as message key Parameters: defaultMessage - fallback default message |
addMessage | void addMessage(MessageType messageType, Object object, String messageCode, Object[] messageArgs, String defaultMessage)(Code) | | Add a message.
Parameters: messageType - type of the message Parameters: messageCode - message code, interpretable as message key Parameters: messageArgs - message arguments, for argument binding via MessageFormat(can be null) Parameters: defaultMessage - fallback default message |
addMessages | void addMessages(Messages messages)(Code) | | Adds messages.
Parameters: messages - |
addPropertyMessage | void addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode)(Code) | | Add a message for a specific property of the object.
Parameters: messageType - type of the message Parameters: propertyName - the property name Parameters: messageCode - message code, interpretable as message key |
addPropertyMessage | void addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode, String defaultMessage)(Code) | | Add a message for a specific property of the object.
Parameters: messageType - type of the message Parameters: propertyName - the field name Parameters: messageCode - message code, interpretable as message key Parameters: defaultMessage - fallback default message |
addPropertyMessage | void addPropertyMessage(MessageType messageType, Object object, String propertyName, String messageCode, Object[] messageArgs, String defaultMessage)(Code) | | Add a message for a specific property of the object.
Parameters: messageType - type of the message Parameters: propertyName - the property name Parameters: messageCode - message code, interpretable as message key Parameters: messageArgs - message arguments, for argument binding via MessageFormat(can be null) Parameters: defaultMessage - fallback default message |
clear | void clear()(Code) | | Clears all messages in the container.
|
getMessage | Message getMessage(Object object, String propertyName)(Code) | | Returns the first message associated with the given object and propertyName, if such
a message is present else null.
Parameters: object - object that is associated with the message. Parameters: propertyName - that is associated with the message. Returns the first message associated with the given object and propertyName, if sucha message is present else null. |
getMessage | String getMessage()(Code) | | Returns an overal messageMessage.
|
getMessages | List getMessages(Object object, String propertyName)(Code) | | Returns a list of Message instances associated with the given object and propertyName, if such
a message is present.
Parameters: object - object that is associated with the message. Parameters: propertyName - that is associated with the message. a list of Message instances associated with the given object and propertyName, if sucha message is present. |
getNumberOfErrorMessages | int getNumberOfErrorMessages()(Code) | | |
getNumberOfMessages | int getNumberOfMessages()(Code) | | Returns the number of message's.
|
getNumberOfMessages | int getNumberOfMessages(MessageType messageType)(Code) | | Returns the number of messages with a specific messagetype.
Parameters: messageType - |
|
|