org.xins.common.types.standard
Class Set

java.lang.Object
  extended byorg.xins.common.types.Type
      extended byorg.xins.common.types.List
          extended byorg.xins.common.types.standard.Set

public final class Set
extends List

Standard type _set.

Since:
XINS 1.5.0.
Version:
$Revision: 1.13 $ $Date: 2008/07/04 10:22:44 $
Author:
Anthony Goubard

Nested Class Summary
static class Set.Value
          Inner class that represents a set of String.
 
Field Summary
static Set SINGLETON
          The only instance of this class.
 
Method Summary
 ItemList createList()
          Creates a new ItemList.
static Set.Value fromStringForOptional(String string)
          Constructs a Set.Value from the specified string.
static Set.Value fromStringForRequired(String string)
          Constructs a Set.Value from the specified string which is guaranteed to be non-null.
 String getDescription()
          Retrieves the description of this type.
static String toString(Set.Value value)
          Converts the specified Set.Value to a string.
 
Methods inherited from class org.xins.common.types.List
fromStringImpl, isValidValueImpl, toString, toString
 
Methods inherited from class org.xins.common.types.Type
checkValue, fromString, getName, getValueClass, isValidValue, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

SINGLETON

public static final Set SINGLETON
The only instance of this class. This field is never null.

Method Detail

createList

public ItemList createList()
Description copied from class: List
Creates a new ItemList.

Specified by:
createList in class List
Returns:
the new list created, never null.

fromStringForRequired

public static Set.Value fromStringForRequired(String string)
                                       throws IllegalArgumentException,
                                              TypeValueException
Constructs a Set.Value from the specified string which is guaranteed to be non-null.

Parameters:
string - the string to convert, cannot be null.
Returns:
the Set.Value object, never null.
Throws:
IllegalArgumentException - if string == null.
TypeValueException - if the specified string does not represent a valid value for this type.

fromStringForOptional

public static Set.Value fromStringForOptional(String string)
                                       throws TypeValueException
Constructs a Set.Value from the specified string.

Parameters:
string - the string to convert, can be null.
Returns:
the Set.Value, or null if string == null.
Throws:
TypeValueException - if the specified string does not represent a valid value for this type.

toString

public static String toString(Set.Value value)
Converts the specified Set.Value to a string.

Parameters:
value - the value to convert, can be null.
Returns:
the textual representation of the value, or null if and only if value == null.

getDescription

public String getDescription()
Description copied from class: Type
Retrieves the description of this type.

Overrides:
getDescription in class Type
Returns:
the description of this type, never null.


See http://www.xins.org/.