Class JacksonRequestConfigurator
java.lang.Object
com.targomo.client.api.request.config.JacksonRequestConfigurator
Parse TravelOptions into JSON strings that can be used when calling client methods.
Targets are generated using StringBuilders for faster generation.
Polygon, sources array and other properties are created as JSONObjects, then appended as Strings.
-
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetConfig(TravelOptions travelOptions) Replaces getCfg methods of Request classes.
-
Method Details
-
getConfig
Replaces getCfg methods of Request classes. Output should be encoded as URL if request method will be GET- Parameters:
travelOptions- Travel options to be parsed into JSON- Returns:
- JSON output
- Throws:
TargomoClientException- Thrown when JSON cannot be generated
-