public class ObjectToFieldValueMapper extends Object
StatisticsMapperWrapper
result set into an appropriate form, e.g. a label for a pie chart. Determines what the type is and invokes
the appropriate method on a transformer for conversionConstructor and Description |
---|
ObjectToFieldValueMapper() |
Modifier and Type | Method and Description |
---|---|
static <T> T |
transform(String fieldType,
Object input,
String url,
FieldValueToDisplayTransformer<T> transformer)
Transforms the object in stats result set into an appropriate type specified by the given
transformer.
|
public static <T> T transform(String fieldType, Object input, String url, FieldValueToDisplayTransformer<T> transformer)
T
- the conversion result type, e.g. a string or a StatsMarkupfieldType
- the fieldType the statsMapperWrapper was created forinput
- the object to converturl
- an optional url to associate with the objecttransformer
- the transformer to do the actual conversion. The return type is determined by this objectCopyright © 2002-2015 Atlassian. All Rights Reserved.