IBM WebSphere Multichannel Bank Transformation Toolkit Javadoc

com.ibm.btt.base
Class BigDecimalFormat

java.lang.Object
  extended by com.ibm.btt.base.FormatElement
      extended by com.ibm.btt.base.FieldFormat
          extended by com.ibm.btt.base.BigDecimalFormat
All Implemented Interfaces:
Cacheable, java.io.Externalizable, java.io.Serializable

public class BigDecimalFormat
extends FieldFormat

The BigDecmialFormat class formats a BigDecmial object into a string.

See Also:
java.math.BigDecimal;, Serialized Form

Field Summary
 
Fields inherited from class com.ibm.btt.base.FormatElement
dataElementName, externalizer, name
 
Constructor Summary
BigDecimalFormat()
          This constructor creates a BigDecmialFormat object.
BigDecimalFormat(java.lang.String aName)
          This constructor creates a BigDecmialFormat object.
 
Method Summary
 java.lang.String format(java.math.BigDecimal aValue)
          Returns the string representation of the BigDecimal.
 java.lang.String formatField(DataField aDataField)
          Accesses the value of the DataField and checks that it is a valid BigDecmial.
 java.lang.Object initializeFrom(Tag aTag)
          Initializes a BigDecmialFormat with the aTag attributes.
 java.lang.String toString()
          Converts the BigDecimalFormat to a String.
 DataField unformatField(java.lang.String aString, DataField aDataField)
          Updates the DataField value by interpreting the input string.
 
Methods inherited from class com.ibm.btt.base.FieldFormat
format, format, toStrings, unformat, unformat, unformat
 
Methods inherited from class com.ibm.btt.base.FormatElement
checkIndexes, exceptionInfo, externalizer, extract, getDataElementName, getExternalizer, getName, getTagName, isCacheable, isConstant, isItConstant, isNull, readExternal, readExternal, readObject, reinitialize, removeExternal, rootDecorated, setDataElementName, setExternalizer, setName, setSize, toTags, unformat, writeExternal, writeExternal
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

BigDecimalFormat

public BigDecimalFormat()
This constructor creates a BigDecmialFormat object.


BigDecimalFormat

public BigDecimalFormat(java.lang.String aName)
                 throws java.io.IOException
This constructor creates a BigDecmialFormat object.

Parameters:
aName - String - A formater name
Throws:
java.io.IOException
Method Detail

format

public java.lang.String format(java.math.BigDecimal aValue)
Returns the string representation of the BigDecimal.

Parameters:
aValue - BigDecimal - A BigDecimal
Returns:
String - A String respresentation of the BigDecimal

formatField

public java.lang.String formatField(DataField aDataField)
                             throws DSEInvalidArgumentException,
                                    DSEInvalidClassException
Accesses the value of the DataField and checks that it is a valid BigDecmial.

Specified by:
formatField in class FieldFormat
Parameters:
aDataField - DataField - A DataField
Returns:
String - A string respresentation of the BigDecmial
Throws:
DSEInvalidArgumentException
DSEInvalidClassException

initializeFrom

public java.lang.Object initializeFrom(Tag aTag)
                                throws java.io.IOException
Initializes a BigDecmialFormat with the aTag attributes.

Specified by:
initializeFrom in class FormatElement
Parameters:
aTag - - Configuration parameter
Returns:
Object - A FormatExternalizer
Throws:
java.io.IOException - - Throws when a problem occurs in accessing SGML files
See Also:
com.ibm.dse.base.Tag

toString

public java.lang.String toString()
Converts the BigDecimalFormat to a String.

Overrides:
toString in class FormatElement
Returns:
String - A String respresentation of this object

unformatField

public DataField unformatField(java.lang.String aString,
                               DataField aDataField)
                        throws DSEInvalidArgumentException
Updates the DataField value by interpreting the input string.

Specified by:
unformatField in class FieldFormat
Parameters:
aString - String - A String respresentation of a BigDecimal
aDataField - DataField - A given DataField
Returns:
DataField - A DataField contains a new BigDecimal
Throws:
DSEInvalidArgumentException

IBM WebSphere Multichannel Bank Transformation Toolkit Javadoc

(c) Copyright IBM Corporation 1998, 2011