com.ricebridge.data.sc
Class IntegerArrayStringConverter

java.lang.Object
  extended bycom.ricebridge.data.sc.StringConverterSupport
      extended bycom.ricebridge.data.sc.TypeStringConverter
          extended bycom.ricebridge.data.sc.TypeArrayStringConverter
              extended bycom.ricebridge.data.sc.IntegerArrayStringConverter
All Implemented Interfaces:
StringConverter

public class IntegerArrayStringConverter
extends TypeArrayStringConverter

Handle int array textual representations.


Field Summary
protected  IntegerStringConverter iIntegerStringConverter
          Use instance of single value converter for actual conversion work.
 
Fields inherited from class com.ricebridge.data.sc.TypeArrayStringConverter
iEscChar, iSepChar, iUseNative
 
Fields inherited from class com.ricebridge.data.sc.TypeStringConverter
iDefault
 
Constructor Summary
IntegerArrayStringConverter()
          Create array converter with standard default object.
IntegerArrayStringConverter(int pDefault)
          Create array converter with specified default native value.
IntegerArrayStringConverter(Integer pDefault)
          Create array converter with specified default wrapper object.
 
Method Summary
protected  Object makeArray(List pValues)
          Create an array object from the list of values.
protected  ArrayList makeList(Object pValues)
          Convert an object into a List, if possible.
protected  Object makeTypeObjectImpl(String pValue, boolean pUseDefault)
          Type specific subclasses handle parsing.
 
Methods inherited from class com.ricebridge.data.sc.TypeArrayStringConverter
makeDefaultObjectImpl, makeDefaultStringImpl, makeObjectImpl, makeStringImpl, setDelimiters, setUseNative
 
Methods inherited from class com.ricebridge.data.sc.TypeStringConverter
makeTypeStringImpl, setDefault
 
Methods inherited from class com.ricebridge.data.sc.StringConverterSupport
makeDefaultObject, makeDefaultString, makeObject, makeString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

iIntegerStringConverter

protected IntegerStringConverter iIntegerStringConverter
Use instance of single value converter for actual conversion work.

Constructor Detail

IntegerArrayStringConverter

public IntegerArrayStringConverter()
Create array converter with standard default object.


IntegerArrayStringConverter

public IntegerArrayStringConverter(int pDefault)
Create array converter with specified default native value.

Parameters:
pDefault - default native value

IntegerArrayStringConverter

public IntegerArrayStringConverter(Integer pDefault)
Create array converter with specified default wrapper object.

Parameters:
pDefault - default wrapper value
Method Detail

makeTypeObjectImpl

protected Object makeTypeObjectImpl(String pValue,
                                    boolean pUseDefault)
                             throws Exception
Description copied from class: TypeStringConverter
Type specific subclasses handle parsing.

Specified by:
makeTypeObjectImpl in class TypeStringConverter
Throws:
Exception

makeArray

protected Object makeArray(List pValues)
Description copied from class: TypeArrayStringConverter
Create an array object from the list of values.

If TypeArrayStringConverter.iUseNative is true, then create a native array, else a wrapper object array.

Specified by:
makeArray in class TypeArrayStringConverter
Parameters:
pValues - list of values

makeList

protected ArrayList makeList(Object pValues)
Description copied from class: TypeArrayStringConverter
Convert an object into a List, if possible.

If TypeArrayStringConverter.iUseNative is true, then assume pValues is a native array, else a wrapper object array.

Specified by:
makeList in class TypeArrayStringConverter
Parameters:
pValues - object that should be a list


Copyright © 2004-2005 Ricebridge