org.vfny.geoserver.control.internal
Class DefaultStatusReport

java.lang.Object
  extended by org.vfny.geoserver.control.internal.DefaultStatusReport
All Implemented Interfaces:
java.io.Serializable, IStatusReport

public class DefaultStatusReport
extends java.lang.Object
implements IStatusReport

Basic read-only bean implementation of IStatusReport. Supplies getters for each field, which can be passed in through the constructor.

Author:
Richard Gould
See Also:
Serialized Form

Field Summary
 
Fields inherited from interface org.vfny.geoserver.control.IStatusReport
ERROR, OKAY, WARNING
 
Constructor Summary
DefaultStatusReport(java.lang.String name, int status, java.lang.Exception message)
          status can be one of IStatusReport's three constants: OKAY, WARNING, or ERROR.
 
Method Summary
 java.lang.Exception getMessage()
          Message is an Exception containing a message or a stack trace relevant to the current status.
 java.lang.String getModuleName()
          The module name is a human readable String used to identify this module.
 int getStatus()
          status should be one of IStatusReport's three constants: OKAY, WARNING, or ERROR.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DefaultStatusReport

public DefaultStatusReport(java.lang.String name,
                           int status,
                           java.lang.Exception message)
status can be one of IStatusReport's three constants: OKAY, WARNING, or ERROR.

Method Detail

getMessage

public java.lang.Exception getMessage()
Description copied from interface: IStatusReport
Message is an Exception containing a message or a stack trace relevant to the current status. Message could be null, for instance if status was OKAY.

Specified by:
getMessage in interface IStatusReport
Returns:
a message from the module relevant to the status

getStatus

public int getStatus()
status should be one of IStatusReport's three constants: OKAY, WARNING, or ERROR.

Specified by:
getStatus in interface IStatusReport
Returns:
the status indicator of the module that this report is based upon

getModuleName

public java.lang.String getModuleName()
Description copied from interface: IStatusReport
The module name is a human readable String used to identify this module.

Specified by:
getModuleName in interface IStatusReport
Returns:
the name of the module that this report is based upon.