org.progeeks.meta.format
Class AbstractPropertyFormat

java.lang.Object
  extended by org.progeeks.meta.format.AbstractPropertyFormat
All Implemented Interfaces:
PropertyFormat
Direct Known Subclasses:
BeanFieldPropertyFormat, ClassPropertyFormat, DatePropertyFormat, DefaultListPropertyFormat, DefaultPropertyFormat, FieldSubstitutionFormat, MetaFieldPropertyFormat, MonthFormat, MultiTypeFormat, PercentFormat, UrlQueryFormat

public abstract class AbstractPropertyFormat
extends java.lang.Object
implements PropertyFormat

Base implementation that can be extended to more easily provide property formatting support.

Version:
$Revision: 1.1 $
Author:
Paul Speed

Constructor Summary
AbstractPropertyFormat()
           
 
Method Summary
abstract  java.lang.String format(java.lang.Object obj)
          Returns the formatted String for the specified Object.
 java.lang.StringBuffer format(java.lang.Object obj, java.lang.StringBuffer appendTo)
          Appends the formatted string to the specified StringBuffer and returns the supplied StringBuffer.
 java.lang.Object parseObject(java.lang.String source)
          Parses the text and converts it into an Object of the appropriate type.
abstract  java.lang.Object parseObject(java.lang.String source, int index)
          Parses the text starting at the specified index and converts it into an Object of the appropriate type.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractPropertyFormat

public AbstractPropertyFormat()
Method Detail

format

public abstract java.lang.String format(java.lang.Object obj)
Returns the formatted String for the specified Object.

Specified by:
format in interface PropertyFormat

format

public java.lang.StringBuffer format(java.lang.Object obj,
                                     java.lang.StringBuffer appendTo)
Appends the formatted string to the specified StringBuffer and returns the supplied StringBuffer.

Specified by:
format in interface PropertyFormat

parseObject

public java.lang.Object parseObject(java.lang.String source)
Parses the text and converts it into an Object of the appropriate type. If this method is not supported then an UnsupportedOperationException will be thrown.

Specified by:
parseObject in interface PropertyFormat

parseObject

public abstract java.lang.Object parseObject(java.lang.String source,
                                             int index)
Parses the text starting at the specified index and converts it into an Object of the appropriate type. If this method is not supported then an UnsupportedOperationException will be thrown.

Specified by:
parseObject in interface PropertyFormat


Copyright © 2002-2003 Paul Speed. All Rights Reserved.