java.lang.Object
org.jhotdraw8.xml.converter.SetXmlConverter<T>
- Type Parameters:
T- the element type
- All Implemented Interfaces:
Converter<ImmutableSequencedSet<T>>
Parses a set with items separated by configurable delimiters.
References:
- HTML 5, Common Microsyntaxes, Space-separated tokens
- w3.org
-
Constructor Summary
ConstructorsConstructorDescriptionSetXmlConverter(Converter<T> elementConverter) Creates a new instance with a space character " " as the delimiter.SetXmlConverter(Converter<T> elementConverter, @Nullable String delimiter) SetXmlConverter(Converter<T> elementConverter, @Nullable String delimiter, @Nullable String prefix, @Nullable String suffix, @Nullable Comparator<T> comparatorForSorting) -
Method Summary
Modifier and TypeMethodDescription@Nullable ImmutableSequencedSet<T> fromString(CharBuffer in, @Nullable IdResolver idResolver) @Nullable ImmutableSequencedSet<T> boolean<TT extends ImmutableSequencedSet<T>>
voidtoString(Appendable out, @Nullable IdSupplier idSupplier, @Nullable TT value) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.jhotdraw8.base.converter.Converter
fromString, fromString, fromString, fromStringNonNull, fromStringNonNull, fromStringNonNull, fromStringNonNull, getHelpText, toString, toString, toString
-
Constructor Details
-
SetXmlConverter
Creates a new instance with a space character " " as the delimiter.- Parameters:
elementConverter-
-
SetXmlConverter
-
SetXmlConverter
-
-
Method Details
-
fromString
public @Nullable ImmutableSequencedSet<T> fromString(CharBuffer in, @Nullable IdResolver idResolver) throws ParseException - Specified by:
fromStringin interfaceConverter<T>- Throws:
ParseException
-
needsIdResolver
public boolean needsIdResolver()- Specified by:
needsIdResolverin interfaceConverter<T>
-
toString
public <TT extends ImmutableSequencedSet<T>> void toString(Appendable out, @Nullable IdSupplier idSupplier, @Nullable TT value) throws IOException - Specified by:
toStringin interfaceConverter<T>- Throws:
IOException
-
getDefaultValue
- Specified by:
getDefaultValuein interfaceConverter<T>
-