Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  * Copyright 2004-2008 the original author oimport;
 ou may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * See the License for the specific language governing permissions and
 * limitations under the License.
package org.springframework.binding.message;
An object of communication that provides text information from a source. For example, a validation message may inform a web application user a business rule was violated. A messages comes from a source, has text providing the basis for communication, and has severity indicating the priority or intensity of the message for its receiver.

Keith Donald
public class Message implements Serializable {
	private Object source;
	private String text;
	private Severity severity;

Creates a new message.

source the source of the message
text the message text
severity the message severity
	public Message(Object sourceString textSeverity severity) {
		this. = source;
		this. = text;
		this. = severity;

Returns the source of this message. The source is the object that sent the message.

the source
	public Object getSource() {
		return ;

Returns the message text. The text is the message's communication payload.

the message text
	public String getText() {
		return ;

Returns the severity of this message. The severity indicates the intensity or priority of the communication.

the message severity
	public Severity getSeverity() {
		return ;
	public String toString() {
		return new ToStringCreator(this).append("severity").append("text").toString();
New to GrepCode? Check out our FAQ X