The following features are supported:
The following features are supported:
Warning: This is a facade provided for use by user code, not for implementation by user code. User implementations of this interface are highly likely to be incompatible with future releases of the product at both binary and source levels.
@volantis-api-include-in PublicAPI @volantis-api-include-in ProfessionalServicesAPI @volantis-api-include-in InternalAPIWarning: This is a facade provided for use by user code, not for implementation in user code. User implementations of this interface are highly likely to be incompatible with future releases of the product at both binary and source levels.
@volantis-api-include-in PublicAPI @volantis-api-include-in ProfessionalServicesAPI @volantis-api-include-in InternalAPI @mock.generateThe mutability allows to reuse the object inside the user code, also across invocations. Reusing a StringValue object helps to increase the performance, as string objects are rather heavy-weight objects and incur a lot of garbage collection overhead, if created and destroyed in masses. @see eu.stratosphere.types.Key @see eu.stratosphere.types.NormalizableKey @see java.lang.String @see java.lang.CharSequence
The mutability allows to reuse the object inside the user code, also across invocations. Reusing a StringValue object helps to increase the performance, as string objects are rather heavy-weight objects and incur a lot of garbage collection overhead, if created and destroyed in masses. @see org.apache.flink.types.Key @see org.apache.flink.types.NormalizableKey @see java.lang.String @see java.lang.CharSequence
StringValue
provides an implementation of the Value
interface representing a string value.
Objects can be constructed directly from Strings or by using the valueOf() static factory methods. The repeat() static factory methods provide a way of generating a String value that repeats a given char or String a number of times.
Conversions to a wide variety of types can be found in the to*() methods. A generic conversion can be achieved with to(Class).
The beforeFirst(), afterFirst(), beforeLast() and afterLast() methods are handy for parsing things like paths and filenames. @author Jonathan Locke
A {@link PrimitiveValue} corresponding to the Java type {@link String}.
@author Daniel Meyer @since 7.2ComponentProvider
. F.i. to show a Contributor cell object as "Busywoman, Herta" implement a custom StringValue and use it in a text rendering provider.
StringValue stringValue = new StringValue() { public String getString(Object value) { if (!(value instanceof Contributor)) return TO_STRING.getString(value); Contributor contributor = (Contributor) value; return contributor.lastName + ", " + contributor.firstName; } }; ComponentProvider provider = new LabelProvider(stringValue); table.setDefaultRenderer(Contributor.class, new DefaultTableRenderer(provider));
PENDING: use a full-fledged Format instead? Would impose a higher burden onto implementors but could be re-used in editors. @author Jeanette Winzenburg @see ComponentProvider @see LabelProvider @see DefaultTableRenderer @see DefaultListRenderer @see DefaultTreeRenderer
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|