net.sf.sasl.aop.monitoring.execution.time
Class MessageBean

java.lang.Object
  extended by net.sf.sasl.aop.monitoring.execution.time.MessageBean

public class MessageBean
extends Object

Bean class that represents a simple message that can have a subject and a message text.

Since:
0.0.1 (sasl-common-aspect-library)
Author:
Philipp Förmer

Constructor Summary
MessageBean()
           
 
Method Summary
 String getMessage()
          Returns the message text of the message.
 String getSubject()
          Returns the subject of the message.
 void setMessage(String message)
          Sets the message text of the message.
 void setMessageFromResource(String location)
          Sets the message text of the message from a resource.
 void setSubject(String subject)
          Sets the subject of the message.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MessageBean

public MessageBean()
Method Detail

getSubject

public String getSubject()
Returns the subject of the message.

Returns:
non null.
Since:
0.0.1 (sasl-common-aspect-library)

setSubject

public void setSubject(String subject)
Sets the subject of the message.

Parameters:
subject - null or non null.
Since:
0.0.1 (sasl-common-aspect-library)

getMessage

public String getMessage()
Returns the message text of the message.

Returns:
non null.
Since:
0.0.1 (sasl-common-aspect-library)

setMessage

public void setMessage(String message)
Sets the message text of the message.

Parameters:
message - null or non null.
Since:
0.0.1 (sasl-common-aspect-library)

setMessageFromResource

public void setMessageFromResource(String location)
                            throws IllegalArgumentException,
                                   IOException
Sets the message text of the message from a resource. The resource must be UTF-8 encoded. The location can start with "classpath:" or "file:".

Parameters:
location - non null.
Throws:
IllegalArgumentException - if location is null.
IOException - if any io exception occurs during trying to read the resource.
Since:
0.0.1 (sasl-common-aspect-library)
See Also:
net.sf.sasl.aop.common.io.ResourceReader#readStringResource(String)


Copyright © 2010. All Rights Reserved.