T - type to extract from@FunctionalInterface public interface ToString<T> extends Expression<T>, Function<T,String>, HasMap<T,UnaryOperator<String>,ToString<T>>, HasCase<T,ToString<T>>, HasHash<T>, HasCompare<T>, HasCompose<T>
String value. This
expression can be implemented using a lambda, or it can be a result of
another operation. It has additional methods for operating on it.Function| Modifier and Type | Method and Description |
|---|---|
String |
apply(T object) |
default int |
compare(T first,
T second) |
default <V> ToStringNullable<V> |
compose(Function<? super V,? extends T> before)
Returns a composed expression that first applies the
before
function to its input, and then applies this function to the result. |
default ExpressionType |
expressionType()
Returns the expression type of this expression.
|
default long |
hash(T object)
Hash the specified object into a 64-bit hash.
|
default ToString<T> |
map(UnaryOperator<String> mapper)
Returns an expression for the value of this expression mapped using the
specified mapping function.
|
static <T> ToString<T> |
of(Function<T,String> lambda)
Returns a typed
ToString<T> using the provided lambda. |
default ToString<T> |
toLowerCase()
Returns an expression that is equivalent to this expression, except that
results are always in lower-case letters.
|
default ToString<T> |
toUpperCase()
Returns an expression that is equivalent to this expression, except that
results are always in upper-case letters.
|
comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLongstatic <T> ToString<T> of(Function<T,String> lambda)
ToString<T> using the provided lambda.T - type to extract fromlambda - to convertToString<T> using the provided lambdaNullPointerException - if the provided lambda is
nulldefault ExpressionType expressionType()
ExpressionexpressionType in interface Expression<T>default ToString<T> map(UnaryOperator<String> mapper)
HasMapdefault ToString<T> toUpperCase()
HasCasetoUpperCase in interface HasCase<T,ToString<T>>default ToString<T> toLowerCase()
HasCasetoLowerCase in interface HasCase<T,ToString<T>>default long hash(T object)
HasHashdefault int compare(T first, T second)
compare in interface Comparator<T>compare in interface HasCompare<T>default <V> ToStringNullable<V> compose(Function<? super V,? extends T> before)
HasComposebefore
function to its input, and then applies this function to the result.
If evaluation of either function throws an exception, it is relayed to
the caller of the composed function.compose in interface Function<T,String>compose in interface HasCompose<T>V - the type of input to the before function, and to the
composed expressionbefore - the function to apply before this function is appliedbefore
function and then applies this functionCopyright © 2019 Speedment, Inc.. All rights reserved.