public abstract class ParameterTransformer extends Object
Constructor and Description |
---|
ParameterTransformer() |
Modifier and Type | Method and Description |
---|---|
protected abstract String[] |
getArrayValues(Parameter parameter,
String rawValue) |
protected abstract String[] |
getObjectKeysAndValues(Parameter parameter,
String rawValue) |
Object |
transform(Parameter parameter,
String rawValue)
Transforms the raw value from its
String representation into JSON. |
Object |
transformArray(Parameter parameter,
String rawValue)
Like
transform(Parameter, String) , but only for values considered to be an array. |
Object |
transformObject(Parameter parameter,
String rawValue)
Like
transform(Parameter, String) , but only for values considered to be an object. |
Object |
transformPrimitive(Parameter parameter,
String rawValue)
Like
transform(Parameter, String) , but only for values considered to be primitive. |
public Object transform(Parameter parameter, String rawValue)
String
representation into JSON. This method does not only decode a
String
, it also takes the different styles
into account}.parameter
- The parameter modelrawValue
- The parameter valueObject
holding the transformed value.public Object transformPrimitive(Parameter parameter, String rawValue)
transform(Parameter, String)
, but only for values considered to be primitive.parameter
- The parameter modelrawValue
- The parameter valueObject
holding the transformed value.public Object transformArray(Parameter parameter, String rawValue)
transform(Parameter, String)
, but only for values considered to be an array.parameter
- The parameter modelrawValue
- The parameter valueObject
holding the transformed value.protected abstract String[] getObjectKeysAndValues(Parameter parameter, String rawValue)
public Object transformObject(Parameter parameter, String rawValue)
transform(Parameter, String)
, but only for values considered to be an object.parameter
- The parameter modelrawValue
- The parameter valueObject
holding the transformed value.Copyright © 2023 Eclipse. All rights reserved.