org.jfree.report.filter
Class ResourceMessageFormatFilter

java.lang.Object
  |
  +--org.jfree.report.filter.ResourceMessageFormatFilter

public class ResourceMessageFormatFilter
extends java.lang.Object
implements ReportConnectable, java.io.Serializable, DataSource

Creation-Date: 24.01.2006, 15:58:32

Author:
Thomas Morgner
See Also:
Serialized Form

Constructor Summary
ResourceMessageFormatFilter()
           
 
Method Summary
 java.lang.Object clone()
          Clones this DataSource.
 java.lang.String getFormatKey()
          Returns the format string used in the message format.
 java.lang.String getNullString()
           
 java.lang.String getResourceIdentifier()
          Returns the name of the used resource bundle.
 java.lang.Object getValue()
          Returns the current value for the data source.
 void registerReportDefinition(ReportDefinition reportDefinition)
          Connects the connectable to the given report definition.
 void setFormatKey(java.lang.String format)
          Defines the format string for the MessageFormat object used in this implementation.
 void setNullString(java.lang.String nullString)
           
 void setResourceIdentifier(java.lang.String resourceIdentifier)
          Defines the name of the used resource bundle.
 void unregisterReportDefinition(ReportDefinition reportDefinition)
          Disconnects the connectable from the given report definition.
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResourceMessageFormatFilter

public ResourceMessageFormatFilter()
Method Detail

getValue

public java.lang.Object getValue()
Returns the current value for the data source.
Specified by:
getValue in interface DataSource
Returns:
the value.

getResourceIdentifier

public java.lang.String getResourceIdentifier()
Returns the name of the used resource bundle.
Returns:
the name of the resourcebundle
See Also:
ResourceBundleFactory.getResourceBundle(String)

setResourceIdentifier

public void setResourceIdentifier(java.lang.String resourceIdentifier)
Defines the name of the used resource bundle. If undefined, all calls to ResourceFileFilter.getValue() will result in null values.
Parameters:
resourceIdentifier - the resource bundle name

setFormatKey

public void setFormatKey(java.lang.String format)
Defines the format string for the MessageFormat object used in this implementation.
Parameters:
format - resourcebundle key for the message format.

getFormatKey

public java.lang.String getFormatKey()
Returns the format string used in the message format.
Returns:
the format string.

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Clones this DataSource.
Specified by:
clone in interface DataSource
Overrides:
clone in class java.lang.Object
Returns:
the clone.
Throws:
java.lang.CloneNotSupportedException - this should never happen.

registerReportDefinition

public void registerReportDefinition(ReportDefinition reportDefinition)
Connects the connectable to the given report definition.
Specified by:
registerReportDefinition in interface ReportConnectable
Parameters:
reportDefinition - the reportDefinition for this report connectable.
Throws:
java.lang.IllegalStateException - if this instance is already connected to a report definition.

unregisterReportDefinition

public void unregisterReportDefinition(ReportDefinition reportDefinition)
Disconnects the connectable from the given report definition.
Specified by:
unregisterReportDefinition in interface ReportConnectable
Parameters:
reportDefinition - the reportDefinition for this report connectable.
Throws:
java.lang.IllegalStateException - if this instance is already connected to a report definition.

getNullString

public java.lang.String getNullString()

setNullString

public void setNullString(java.lang.String nullString)