Package reactor.test

Class ValueFormatters

java.lang.Object
reactor.test.ValueFormatters

public final class ValueFormatters extends Object
An utility class to create ValueFormatters.ToStringConverter Function that convert objects to String. They can be applied to any Object but will restrict the types they actually convert by filtering and defaulting to String.valueOf(Object).

Also defines ValueFormatters.Extractor BiFunction that extract multiple elements from containers and applies a Function (most probably a ValueFormatters.ToStringConverter) to its elements, reforming a complete String representation. Again, this matches on at least a given Class and potentially an additional Predicate.

An additional static utility method convertVarArgs(ToStringConverter, Collection, Object...) can be used to apply such functions and to varargs.

Author:
Simon Baslé