com.rubecula.spreadsheet
Class ErrorPresentation

java.lang.Object
  |
  +--com.rubecula.util.Presentation
        |
        +--com.rubecula.spreadsheet.ErrorPresentation
All Implemented Interfaces:
Auditable, Identifiable

public class ErrorPresentation
extends Presentation

Description: ErrorPresentation is a class used to allow an error message to be presented to the user, instead of a numeric presentation.

Version:
$Revision: 1.4 $
Author:
Robin Hillyard

Field Summary
 
Fields inherited from class com.rubecula.util.Presentation
_Appearance, $empty, $Stars
 
Constructor Summary
ErrorPresentation(java.lang.String s)
           
 
Method Summary
 java.lang.String audit(java.lang.String label)
          Method to return a detailed string from an object for debugging purposes.
 AttrMap getAttributes()
          Return the attributes with which this presentation was created, or at least the best guess.
 java.lang.String getIdentifier()
          Method to get the specific identifier for an object.
 java.lang.String getPresentableClass()
          Method to get the name of the corresponding Presentable class for this Presentation.
 Presentable parse()
          Convert Presentation x into a Presentable object.
 Presentation setValue(java.lang.String s)
           
 java.lang.String toString()
          Render this Presentation as a String with no width limitation.
 java.lang.String toString(int width)
          Render this Presentation as a String within the width specified.
 
Methods inherited from class com.rubecula.util.Presentation
audit, audit, updateAppearance
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ErrorPresentation

public ErrorPresentation(java.lang.String s)
Method Detail

parse

public Presentable parse()
Convert Presentation x into a Presentable object.

Overrides:
parse in class Presentation
Returns:
null.

getPresentableClass

public java.lang.String getPresentableClass()
Method to get the name of the corresponding Presentable class for this Presentation.

Specified by:
getPresentableClass in class Presentation
Returns:
null.

getAttributes

public AttrMap getAttributes()
                      throws PresentationException
Return the attributes with which this presentation was created, or at least the best guess.

Specified by:
getAttributes in class Presentation
Returns:
a map of attributes used to render this Presentation. Currently returns an empty map.
Throws:
PresentationException

toString

public java.lang.String toString(int width)
Description copied from class: Presentation
Render this Presentation as a String within the width specified.

Specified by:
toString in class Presentation
Parameters:
width - the max. number of characters within which to output the presentation.
Returns:
a representation (rendering) of this Presentation.

toString

public java.lang.String toString()
Description copied from class: Presentation
Render this Presentation as a String with no width limitation.

Overrides:
toString in class Presentation
Returns:
a representation (rendering) of this Presentation.

audit

public java.lang.String audit(java.lang.String label)
Description copied from interface: Auditable
Method to return a detailed string from an object for debugging purposes.

Parameters:
label - the label to associate with the data. If label is non-null, a more detailed audit will be returned (this normally occurs only at the top level).
Returns:
the detailed string.

getIdentifier

public java.lang.String getIdentifier()
Description copied from interface: Identifiable
Method to get the specific identifier for an object.

Returns:
the identifier.

setValue

public Presentation setValue(java.lang.String s)