Configuration option to disable HTML escaping when using Gson (#298)

* Configuration option to disable HTML escaping when using Gson

The default implementation of Gson will escape certain characters by default. This
includes the `=` character, which is used in base64 encoding and cause problems when
deserializing the value to a base64 encoded string in a service.

Adding an option for disabling this feature makes it easier to generate client code
with sane defaults.

* Update Petstore sample
This commit is contained in:
Stian Liknes
2018-06-14 13:27:52 +02:00
committed by William Cheng
parent f8e61ac914
commit 680a2bc3ec
5 changed files with 23 additions and 5 deletions

View File

@@ -64,7 +64,8 @@ public class JSON {
}
})
;
return fireBuilder.createGsonBuilder();
GsonBuilder builder = fireBuilder.createGsonBuilder();
return builder;
}
private static String getDiscriminatorValue(JsonElement readElement, String discriminatorField) {