intarsys runtime library

de.intarsys.tools.format
Class NullableFormat

java.lang.Object
  extended by java.text.Format
      extended by de.intarsys.tools.format.NullableFormat
All Implemented Interfaces:
Serializable, Cloneable

public class NullableFormat
extends Format

This format allows a daisy chain style null filtering.

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class java.text.Format
Format.Field
 
Constructor Summary
NullableFormat(Format format, String nullValue)
           
 
Method Summary
 StringBuffer format(Object obj, StringBuffer toAppendTo, FieldPosition pos)
           
 Format getFormat()
           
 String getNullValue()
           
 Object parseObject(String source, ParsePosition pos)
           
 
Methods inherited from class java.text.Format
clone, format, formatToCharacterIterator, parseObject
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NullableFormat

public NullableFormat(Format format,
                      String nullValue)
Method Detail

format

public StringBuffer format(Object obj,
                           StringBuffer toAppendTo,
                           FieldPosition pos)
Specified by:
format in class Format

getFormat

public Format getFormat()

getNullValue

public String getNullValue()

parseObject

public Object parseObject(String source,
                          ParsePosition pos)
Specified by:
parseObject in class Format

intarsys runtime library

Copyright © 2012 intarsys consulting GmbH. All Rights Reserved.