|
| Components |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||
com.sas.util.transforms.StringToStringListInterfaceTransform
public class StringToStringListInterfaceTransform
A transform for converting a String to a String ListInterface
StringListInterfaceToStringTransform,
Serialized Form| Field Summary | |
|---|---|
static StringToStringListInterfaceTransform |
defaultInstance
A default instance which can perform the transformation. |
java.lang.Class |
stringCollectionClass
Class to instantiate when making a StringCollection Defaults to com.sas.collection.StringCollection, but subclasses may prefer another class that implements StringListInterface. |
| Constructor Summary | |
|---|---|
StringToStringListInterfaceTransform()
Default constructor which uses a ',' delimiter. |
|
StringToStringListInterfaceTransform(char delimiter)
Construct a transform which uses a specific delimiter. |
|
| Method Summary | |
|---|---|
protected static char |
defaultDelimiterChar()
|
java.lang.Class |
getInputClass()
|
java.lang.Class |
getOutputClass()
|
protected StringListInterface |
newStringList()
Factory method to create a StringListInterface instance when transforming an object. |
java.lang.Object |
transform(java.lang.Object object)
Transform a String to a StringListInterface |
static StringListInterface |
transform(StringListInterface stringList,
java.lang.String text,
char delimiter)
Transform a text string into a string list. |
| Field Detail |
|---|
public static final StringToStringListInterfaceTransform defaultInstance
public java.lang.Class stringCollectionClass
| Constructor Detail |
|---|
public StringToStringListInterfaceTransform()
public StringToStringListInterfaceTransform(char delimiter)
delimiter - the item delimiter.| Method Detail |
|---|
protected static char defaultDelimiterChar()
public java.lang.Object transform(java.lang.Object object)
throws com.sas.util.transforms.TransformException
transform in interface com.sas.util.transforms.TransformInterfaceobject - null or a String; it contains a comma separated list of items.
Individual items need not be quoted, but quotes are required to preserve
leading and/or trailing space, or of the item contains special characters,
such as escaped characters, a comma, or a '"' double quote.
com.sas.util.transforms.TransformException - if
the transform(dictionary, Object) method throws an exception
java.lang.ClassCastException - if object
is not a Stringprotected StringListInterface newStringList()
public static StringListInterface transform(StringListInterface stringList,
java.lang.String text,
char delimiter)
throws com.sas.util.transforms.TransformException
stringList - items parsed from the text are appended to this string listtext - a comma separated list of items.delimiter - the delimiter which separates the items.
com.sas.util.transforms.TransformException - if
the transform(StringListInterface, Object) method throws an exceptionpublic java.lang.Class getInputClass()
getInputClass in interface com.sas.util.transforms.TransformInputOutputInterfacepublic java.lang.Class getOutputClass()
getOutputClass in interface com.sas.util.transforms.TransformInputOutputInterface
|
| Components |
|
| |||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||||||