Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.lsmp.djep.xjep
Class BaseFormat

    java.lang.Object
      java.text.Format
          java.text.NumberFormat
              org.lsmp.djep.xjep.BaseFormat

All Implemented Interfaces:
  java.io.Serializable, java.lang.Cloneable

    public class BaseFormat

extends java.text.NumberFormat

A Number format object which prints results in a specified base. TODO Do something with the FieldPosition arguments.

Author:
  Rich Morris Created on 02-May-2005
See Also:
  Serialized Form

Nested Class Summary

Nested classes/interfaces inherited from class java.text.NumberFormat
`java.text.NumberFormat.Field`

Field Summary

Fields inherited from class java.text.NumberFormat
`FRACTION_FIELD, INTEGER_FIELD`

Constructor Summary
`BaseFormat(int base)` Create a new base format object
`BaseFormat(int base, java.lang.String prefix)` Create a new base format object

Method Summary
`java.lang.StringBuffer` | `format(double val, java.lang.StringBuffer sb, java.text.FieldPosition fp)` Format a double value in specific base.
`java.lang.StringBuffer` | `format(long val, java.lang.StringBuffer sb, java.text.FieldPosition fp)` Format a double value in specific base.
`java.lang.Number` | `parse(java.lang.String arg0, java.text.ParsePosition arg1)` Not implemented

Methods inherited from class java.text.NumberFormat
`clone, equals, format, format, format, getAvailableLocales, getCurrency, getCurrencyInstance, getCurrencyInstance, getInstance, getInstance, getIntegerInstance, getIntegerInstance, getMaximumFractionDigits, getMaximumIntegerDigits, getMinimumFractionDigits, getMinimumIntegerDigits, getNumberInstance, getNumberInstance, getPercentInstance, getPercentInstance, hashCode, isGroupingUsed, isParseIntegerOnly, parse, parseObject, setCurrency, setGroupingUsed, setMaximumFractionDigits, setMaximumIntegerDigits, setMinimumFractionDigits, setMinimumIntegerDigits, setParseIntegerOnly`

Methods inherited from class java.text.Format
`format, formatToCharacterIterator, parseObject`

Methods inherited from class java.lang.Object
`finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### BaseFormat

    public BaseFormat(int base)

  Create a new base format object

  Parameters:
    `base` - the base of number to use
  Throws:
    `java.lang.IllegalArgumentException` - if base is < 2 or > 36

### BaseFormat

    public BaseFormat(int base,
                      java.lang.String prefix)

  Create a new base format object

  Parameters:
    `base` - the base of number to use
    `prefix` - prefix to appear before number
  Throws:
    `java.lang.IllegalArgumentException` - if base is < 2 or > 36

Method Detail

### format

    public java.lang.StringBuffer format(double val,
                                         java.lang.StringBuffer sb,
                                         java.text.FieldPosition fp)

  Format a double value in specific base.

  Specified by:
    `format` in class `java.text.NumberFormat`
  Parameters:
    `val` - the number to format
    `sb` - the buffer to append to
    `fp` - not used
  Returns:
    the string buffer

### format

    public java.lang.StringBuffer format(long val,
                                         java.lang.StringBuffer sb,
                                         java.text.FieldPosition fp)

  Format a double value in specific base.

  Specified by:
    `format` in class `java.text.NumberFormat`
  Parameters:
    `val` - the number to format
    `sb` - the buffer to append to
    `fp` - not used
  Returns:
    the string buffer

### parse

    public java.lang.Number parse(java.lang.String arg0,
                                  java.text.ParsePosition arg1)

  Not implemented

  Specified by:
    `parse` in class `java.text.NumberFormat`

Overview | Package | Class | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

http://www.singularsys.com/jep Copyright © 2007 Singular Systems