[Java] fix default value for JsonNullable (#14703)

* fix java webclient default value

* update default value in java okhttp client

* fix java native client default value in JsonNullable

* improve java okhttp-gson default value template

* update java rest-related templates

* update feign samples

* update jersey3 templates

* update jersey2 templates

* update default value in jaxrs templates

* fix spring default value

* update jaxrs pojo, fix tests

* update samples

* suport set
This commit is contained in:
William Cheng
2023-02-16 10:37:36 +08:00
committed by GitHub
parent 8b0b4b5d04
commit 71c2abf81c
230 changed files with 645 additions and 839 deletions

View File

@@ -308,7 +308,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -354,7 +354,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -434,7 +434,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -480,7 +480,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -305,7 +305,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -351,7 +351,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -431,7 +431,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -477,7 +477,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -49,28 +49,28 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AdditionalPropertiesClass {
public static final String JSON_PROPERTY_MAP_STRING = "map_string";
private Map<String, String> mapString = null;
private Map<String, String> mapString = new HashMap<>();
public static final String JSON_PROPERTY_MAP_NUMBER = "map_number";
private Map<String, BigDecimal> mapNumber = null;
private Map<String, BigDecimal> mapNumber = new HashMap<>();
public static final String JSON_PROPERTY_MAP_INTEGER = "map_integer";
private Map<String, Integer> mapInteger = null;
private Map<String, Integer> mapInteger = new HashMap<>();
public static final String JSON_PROPERTY_MAP_BOOLEAN = "map_boolean";
private Map<String, Boolean> mapBoolean = null;
private Map<String, Boolean> mapBoolean = new HashMap<>();
public static final String JSON_PROPERTY_MAP_ARRAY_INTEGER = "map_array_integer";
private Map<String, List<Integer>> mapArrayInteger = null;
private Map<String, List<Integer>> mapArrayInteger = new HashMap<>();
public static final String JSON_PROPERTY_MAP_ARRAY_ANYTYPE = "map_array_anytype";
private Map<String, List<Object>> mapArrayAnytype = null;
private Map<String, List<Object>> mapArrayAnytype = new HashMap<>();
public static final String JSON_PROPERTY_MAP_MAP_STRING = "map_map_string";
private Map<String, Map<String, String>> mapMapString = null;
private Map<String, Map<String, String>> mapMapString = new HashMap<>();
public static final String JSON_PROPERTY_MAP_MAP_ANYTYPE = "map_map_anytype";
private Map<String, Map<String, Object>> mapMapAnytype = null;
private Map<String, Map<String, Object>> mapMapAnytype = new HashMap<>();
public static final String JSON_PROPERTY_ANYTYPE1 = "anytype_1";
private Object anytype1;

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_NUMBER = "ArrayNumber";
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -40,13 +40,13 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayTest {
public static final String JSON_PROPERTY_ARRAY_OF_STRING = "array_of_string";
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -111,7 +111,7 @@ public class EnumArrays {
}
public static final String JSON_PROPERTY_ARRAY_ENUM = "array_enum";
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -42,7 +42,7 @@ public class FileSchemaTestClass {
private ModelFile _file;
public static final String JSON_PROPERTY_FILES = "files";
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -40,7 +40,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class MapTest {
public static final String JSON_PROPERTY_MAP_MAP_OF_STRING = "map_map_of_string";
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -78,13 +78,13 @@ public class MapTest {
}
public static final String JSON_PROPERTY_MAP_OF_ENUM_STRING = "map_of_enum_string";
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String JSON_PROPERTY_DIRECT_MAP = "direct_map";
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String JSON_PROPERTY_INDIRECT_MAP = "indirect_map";
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -48,7 +48,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
private LocalDateTime dateTime;
public static final String JSON_PROPERTY_MAP = "map";
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -59,7 +59,7 @@ public class Pet {
private Set<String> photoUrls = new LinkedHashSet<>();
public static final String JSON_PROPERTY_TAGS = "tags";
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -78,7 +78,7 @@ public class XmlItem {
private Boolean attributeBoolean;
public static final String JSON_PROPERTY_WRAPPED_ARRAY = "wrapped_array";
private List<Integer> wrappedArray = null;
private List<Integer> wrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAME_STRING = "name_string";
private String nameString;
@@ -93,10 +93,10 @@ public class XmlItem {
private Boolean nameBoolean;
public static final String JSON_PROPERTY_NAME_ARRAY = "name_array";
private List<Integer> nameArray = null;
private List<Integer> nameArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAME_WRAPPED_ARRAY = "name_wrapped_array";
private List<Integer> nameWrappedArray = null;
private List<Integer> nameWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_STRING = "prefix_string";
private String prefixString;
@@ -111,10 +111,10 @@ public class XmlItem {
private Boolean prefixBoolean;
public static final String JSON_PROPERTY_PREFIX_ARRAY = "prefix_array";
private List<Integer> prefixArray = null;
private List<Integer> prefixArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_WRAPPED_ARRAY = "prefix_wrapped_array";
private List<Integer> prefixWrappedArray = null;
private List<Integer> prefixWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAMESPACE_STRING = "namespace_string";
private String namespaceString;
@@ -129,10 +129,10 @@ public class XmlItem {
private Boolean namespaceBoolean;
public static final String JSON_PROPERTY_NAMESPACE_ARRAY = "namespace_array";
private List<Integer> namespaceArray = null;
private List<Integer> namespaceArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAMESPACE_WRAPPED_ARRAY = "namespace_wrapped_array";
private List<Integer> namespaceWrappedArray = null;
private List<Integer> namespaceWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_NS_STRING = "prefix_ns_string";
private String prefixNsString;
@@ -147,10 +147,10 @@ public class XmlItem {
private Boolean prefixNsBoolean;
public static final String JSON_PROPERTY_PREFIX_NS_ARRAY = "prefix_ns_array";
private List<Integer> prefixNsArray = null;
private List<Integer> prefixNsArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_NS_WRAPPED_ARRAY = "prefix_ns_wrapped_array";
private List<Integer> prefixNsWrappedArray = null;
private List<Integer> prefixNsWrappedArray = new ArrayList<>();
public XmlItem() {
}

View File

@@ -49,28 +49,28 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AdditionalPropertiesClass {
public static final String JSON_PROPERTY_MAP_STRING = "map_string";
private Map<String, String> mapString = null;
private Map<String, String> mapString = new HashMap<>();
public static final String JSON_PROPERTY_MAP_NUMBER = "map_number";
private Map<String, BigDecimal> mapNumber = null;
private Map<String, BigDecimal> mapNumber = new HashMap<>();
public static final String JSON_PROPERTY_MAP_INTEGER = "map_integer";
private Map<String, Integer> mapInteger = null;
private Map<String, Integer> mapInteger = new HashMap<>();
public static final String JSON_PROPERTY_MAP_BOOLEAN = "map_boolean";
private Map<String, Boolean> mapBoolean = null;
private Map<String, Boolean> mapBoolean = new HashMap<>();
public static final String JSON_PROPERTY_MAP_ARRAY_INTEGER = "map_array_integer";
private Map<String, List<Integer>> mapArrayInteger = null;
private Map<String, List<Integer>> mapArrayInteger = new HashMap<>();
public static final String JSON_PROPERTY_MAP_ARRAY_ANYTYPE = "map_array_anytype";
private Map<String, List<Object>> mapArrayAnytype = null;
private Map<String, List<Object>> mapArrayAnytype = new HashMap<>();
public static final String JSON_PROPERTY_MAP_MAP_STRING = "map_map_string";
private Map<String, Map<String, String>> mapMapString = null;
private Map<String, Map<String, String>> mapMapString = new HashMap<>();
public static final String JSON_PROPERTY_MAP_MAP_ANYTYPE = "map_map_anytype";
private Map<String, Map<String, Object>> mapMapAnytype = null;
private Map<String, Map<String, Object>> mapMapAnytype = new HashMap<>();
public static final String JSON_PROPERTY_ANYTYPE1 = "anytype_1";
private Object anytype1;

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_NUMBER = "ArrayNumber";
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -40,13 +40,13 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayTest {
public static final String JSON_PROPERTY_ARRAY_OF_STRING = "array_of_string";
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -111,7 +111,7 @@ public class EnumArrays {
}
public static final String JSON_PROPERTY_ARRAY_ENUM = "array_enum";
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -42,7 +42,7 @@ public class FileSchemaTestClass {
private ModelFile _file;
public static final String JSON_PROPERTY_FILES = "files";
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -40,7 +40,7 @@ import org.openapitools.client.JSON;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class MapTest {
public static final String JSON_PROPERTY_MAP_MAP_OF_STRING = "map_map_of_string";
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -78,13 +78,13 @@ public class MapTest {
}
public static final String JSON_PROPERTY_MAP_OF_ENUM_STRING = "map_of_enum_string";
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String JSON_PROPERTY_DIRECT_MAP = "direct_map";
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String JSON_PROPERTY_INDIRECT_MAP = "indirect_map";
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -48,7 +48,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
private OffsetDateTime dateTime;
public static final String JSON_PROPERTY_MAP = "map";
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -59,7 +59,7 @@ public class Pet {
private Set<String> photoUrls = new LinkedHashSet<>();
public static final String JSON_PROPERTY_TAGS = "tags";
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -78,7 +78,7 @@ public class XmlItem {
private Boolean attributeBoolean;
public static final String JSON_PROPERTY_WRAPPED_ARRAY = "wrapped_array";
private List<Integer> wrappedArray = null;
private List<Integer> wrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAME_STRING = "name_string";
private String nameString;
@@ -93,10 +93,10 @@ public class XmlItem {
private Boolean nameBoolean;
public static final String JSON_PROPERTY_NAME_ARRAY = "name_array";
private List<Integer> nameArray = null;
private List<Integer> nameArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAME_WRAPPED_ARRAY = "name_wrapped_array";
private List<Integer> nameWrappedArray = null;
private List<Integer> nameWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_STRING = "prefix_string";
private String prefixString;
@@ -111,10 +111,10 @@ public class XmlItem {
private Boolean prefixBoolean;
public static final String JSON_PROPERTY_PREFIX_ARRAY = "prefix_array";
private List<Integer> prefixArray = null;
private List<Integer> prefixArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_WRAPPED_ARRAY = "prefix_wrapped_array";
private List<Integer> prefixWrappedArray = null;
private List<Integer> prefixWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAMESPACE_STRING = "namespace_string";
private String namespaceString;
@@ -129,10 +129,10 @@ public class XmlItem {
private Boolean namespaceBoolean;
public static final String JSON_PROPERTY_NAMESPACE_ARRAY = "namespace_array";
private List<Integer> namespaceArray = null;
private List<Integer> namespaceArray = new ArrayList<>();
public static final String JSON_PROPERTY_NAMESPACE_WRAPPED_ARRAY = "namespace_wrapped_array";
private List<Integer> namespaceWrappedArray = null;
private List<Integer> namespaceWrappedArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_NS_STRING = "prefix_ns_string";
private String prefixNsString;
@@ -147,10 +147,10 @@ public class XmlItem {
private Boolean prefixNsBoolean;
public static final String JSON_PROPERTY_PREFIX_NS_ARRAY = "prefix_ns_array";
private List<Integer> prefixNsArray = null;
private List<Integer> prefixNsArray = new ArrayList<>();
public static final String JSON_PROPERTY_PREFIX_NS_WRAPPED_ARRAY = "prefix_ns_wrapped_array";
private List<Integer> prefixNsWrappedArray = null;
private List<Integer> prefixNsWrappedArray = new ArrayList<>();
public XmlItem() {
}

View File

@@ -48,10 +48,10 @@ import org.openapitools.client.JSON;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AdditionalPropertiesClass {
public static final String JSON_PROPERTY_MAP_PROPERTY = "map_property";
private Map<String, String> mapProperty = null;
private Map<String, String> mapProperty = new HashMap<>();
public static final String JSON_PROPERTY_MAP_OF_MAP_PROPERTY = "map_of_map_property";
private Map<String, Map<String, String>> mapOfMapProperty = null;
private Map<String, Map<String, String>> mapOfMapProperty = new HashMap<>();
public static final String JSON_PROPERTY_ANYTYPE1 = "anytype_1";
private JsonNullable<Object> anytype1 = JsonNullable.<Object>of(null);
@@ -63,13 +63,13 @@ public class AdditionalPropertiesClass {
private Object mapWithUndeclaredPropertiesAnytype2;
public static final String JSON_PROPERTY_MAP_WITH_UNDECLARED_PROPERTIES_ANYTYPE3 = "map_with_undeclared_properties_anytype_3";
private Map<String, Object> mapWithUndeclaredPropertiesAnytype3 = null;
private Map<String, Object> mapWithUndeclaredPropertiesAnytype3 = new HashMap<>();
public static final String JSON_PROPERTY_EMPTY_MAP = "empty_map";
private Object emptyMap;
public static final String JSON_PROPERTY_MAP_WITH_UNDECLARED_PROPERTIES_STRING = "map_with_undeclared_properties_string";
private Map<String, String> mapWithUndeclaredPropertiesString = null;
private Map<String, String> mapWithUndeclaredPropertiesString = new HashMap<>();
public AdditionalPropertiesClass() {
}

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -38,7 +38,7 @@ import org.openapitools.client.JSON;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_NUMBER = "ArrayNumber";
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -40,13 +40,13 @@ import org.openapitools.client.JSON;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayTest {
public static final String JSON_PROPERTY_ARRAY_OF_STRING = "array_of_string";
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -61,7 +61,7 @@ public class Drawing {
private JsonNullable<NullableShape> nullableShape = JsonNullable.<NullableShape>undefined();
public static final String JSON_PROPERTY_SHAPES = "shapes";
private List<Shape> shapes = null;
private List<Shape> shapes = new ArrayList<>();
public Drawing() {
}

View File

@@ -111,7 +111,7 @@ public class EnumArrays {
}
public static final String JSON_PROPERTY_ARRAY_ENUM = "array_enum";
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -42,7 +42,7 @@ public class FileSchemaTestClass {
private ModelFile _file;
public static final String JSON_PROPERTY_FILES = "files";
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -40,7 +40,7 @@ import org.openapitools.client.JSON;
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class MapTest {
public static final String JSON_PROPERTY_MAP_MAP_OF_STRING = "map_map_of_string";
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -78,13 +78,13 @@ public class MapTest {
}
public static final String JSON_PROPERTY_MAP_OF_ENUM_STRING = "map_of_enum_string";
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String JSON_PROPERTY_DIRECT_MAP = "direct_map";
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String JSON_PROPERTY_INDIRECT_MAP = "indirect_map";
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -48,7 +48,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
private OffsetDateTime dateTime;
public static final String JSON_PROPERTY_MAP = "map";
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -85,7 +85,7 @@ public class NullableClass {
private JsonNullable<List<Object>> arrayAndItemsNullableProp = JsonNullable.<List<Object>>undefined();
public static final String JSON_PROPERTY_ARRAY_ITEMS_NULLABLE = "array_items_nullable";
private List<Object> arrayItemsNullable = null;
private List<Object> arrayItemsNullable = new ArrayList<>();
public static final String JSON_PROPERTY_OBJECT_NULLABLE_PROP = "object_nullable_prop";
private JsonNullable<Map<String, Object>> objectNullableProp = JsonNullable.<Map<String, Object>>undefined();
@@ -94,7 +94,7 @@ public class NullableClass {
private JsonNullable<Map<String, Object>> objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>undefined();
public static final String JSON_PROPERTY_OBJECT_ITEMS_NULLABLE = "object_items_nullable";
private Map<String, Object> objectItemsNullable = null;
private Map<String, Object> objectItemsNullable = new HashMap<>();
public NullableClass() {
}
@@ -304,7 +304,7 @@ public class NullableClass {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -349,7 +349,7 @@ public class NullableClass {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -427,7 +427,7 @@ public class NullableClass {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -472,7 +472,7 @@ public class NullableClass {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -51,7 +51,7 @@ public class ObjectWithDeprecatedFields {
private DeprecatedObject deprecatedRef;
public static final String JSON_PROPERTY_BARS = "bars";
private List<String> bars = null;
private List<String> bars = new ArrayList<>();
public ObjectWithDeprecatedFields() {
}

View File

@@ -56,7 +56,7 @@ public class Pet {
private List<String> photoUrls = new ArrayList<>();
public static final String JSON_PROPERTY_TAGS = "tags";
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -306,7 +306,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -351,7 +351,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -429,7 +429,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -474,7 +474,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -306,7 +306,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -351,7 +351,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -429,7 +429,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -474,7 +474,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -70,7 +70,7 @@ public class Pet {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -54,35 +54,35 @@ import org.openapitools.client.JSON;
public class AdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP_STRING = "map_string";
@SerializedName(SERIALIZED_NAME_MAP_STRING)
private Map<String, String> mapString = null;
private Map<String, String> mapString = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_NUMBER = "map_number";
@SerializedName(SERIALIZED_NAME_MAP_NUMBER)
private Map<String, BigDecimal> mapNumber = null;
private Map<String, BigDecimal> mapNumber = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_INTEGER = "map_integer";
@SerializedName(SERIALIZED_NAME_MAP_INTEGER)
private Map<String, Integer> mapInteger = null;
private Map<String, Integer> mapInteger = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_BOOLEAN = "map_boolean";
@SerializedName(SERIALIZED_NAME_MAP_BOOLEAN)
private Map<String, Boolean> mapBoolean = null;
private Map<String, Boolean> mapBoolean = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_ARRAY_INTEGER = "map_array_integer";
@SerializedName(SERIALIZED_NAME_MAP_ARRAY_INTEGER)
private Map<String, List<Integer>> mapArrayInteger = null;
private Map<String, List<Integer>> mapArrayInteger = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_ARRAY_ANYTYPE = "map_array_anytype";
@SerializedName(SERIALIZED_NAME_MAP_ARRAY_ANYTYPE)
private Map<String, List<Object>> mapArrayAnytype = null;
private Map<String, List<Object>> mapArrayAnytype = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_MAP_STRING = "map_map_string";
@SerializedName(SERIALIZED_NAME_MAP_MAP_STRING)
private Map<String, Map<String, String>> mapMapString = null;
private Map<String, Map<String, String>> mapMapString = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_MAP_ANYTYPE = "map_map_anytype";
@SerializedName(SERIALIZED_NAME_MAP_MAP_ANYTYPE)
private Map<String, Map<String, Object>> mapMapAnytype = null;
private Map<String, Map<String, Object>> mapMapAnytype = new HashMap<>();
public static final String SERIALIZED_NAME_ANYTYPE1 = "anytype_1";
@SerializedName(SERIALIZED_NAME_ANYTYPE1)

View File

@@ -53,7 +53,7 @@ import org.openapitools.client.JSON;
public class ArrayOfArrayOfNumberOnly {
public static final String SERIALIZED_NAME_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_NUMBER)
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -53,7 +53,7 @@ import org.openapitools.client.JSON;
public class ArrayOfNumberOnly {
public static final String SERIALIZED_NAME_ARRAY_NUMBER = "ArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_NUMBER)
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -53,15 +53,15 @@ import org.openapitools.client.JSON;
public class ArrayTest {
public static final String SERIALIZED_NAME_ARRAY_OF_STRING = "array_of_string";
@SerializedName(SERIALIZED_NAME_ARRAY_OF_STRING)
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER)
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL)
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -150,7 +150,7 @@ public class EnumArrays {
public static final String SERIALIZED_NAME_ARRAY_ENUM = "array_enum";
@SerializedName(SERIALIZED_NAME_ARRAY_ENUM)
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -57,7 +57,7 @@ public class FileSchemaTestClass {
public static final String SERIALIZED_NAME_FILES = "files";
@SerializedName(SERIALIZED_NAME_FILES)
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -52,7 +52,7 @@ import org.openapitools.client.JSON;
public class MapTest {
public static final String SERIALIZED_NAME_MAP_MAP_OF_STRING = "map_map_of_string";
@SerializedName(SERIALIZED_NAME_MAP_MAP_OF_STRING)
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -103,15 +103,15 @@ public class MapTest {
public static final String SERIALIZED_NAME_MAP_OF_ENUM_STRING = "map_of_enum_string";
@SerializedName(SERIALIZED_NAME_MAP_OF_ENUM_STRING)
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String SERIALIZED_NAME_DIRECT_MAP = "direct_map";
@SerializedName(SERIALIZED_NAME_DIRECT_MAP)
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String SERIALIZED_NAME_INDIRECT_MAP = "indirect_map";
@SerializedName(SERIALIZED_NAME_INDIRECT_MAP)
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -63,7 +63,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP = "map";
@SerializedName(SERIALIZED_NAME_MAP)
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -72,7 +72,7 @@ public class Pet {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -69,7 +69,7 @@ public class XmlItem {
public static final String SERIALIZED_NAME_WRAPPED_ARRAY = "wrapped_array";
@SerializedName(SERIALIZED_NAME_WRAPPED_ARRAY)
private List<Integer> wrappedArray = null;
private List<Integer> wrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAME_STRING = "name_string";
@SerializedName(SERIALIZED_NAME_NAME_STRING)
@@ -89,11 +89,11 @@ public class XmlItem {
public static final String SERIALIZED_NAME_NAME_ARRAY = "name_array";
@SerializedName(SERIALIZED_NAME_NAME_ARRAY)
private List<Integer> nameArray = null;
private List<Integer> nameArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAME_WRAPPED_ARRAY = "name_wrapped_array";
@SerializedName(SERIALIZED_NAME_NAME_WRAPPED_ARRAY)
private List<Integer> nameWrappedArray = null;
private List<Integer> nameWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_STRING = "prefix_string";
@SerializedName(SERIALIZED_NAME_PREFIX_STRING)
@@ -113,11 +113,11 @@ public class XmlItem {
public static final String SERIALIZED_NAME_PREFIX_ARRAY = "prefix_array";
@SerializedName(SERIALIZED_NAME_PREFIX_ARRAY)
private List<Integer> prefixArray = null;
private List<Integer> prefixArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_WRAPPED_ARRAY = "prefix_wrapped_array";
@SerializedName(SERIALIZED_NAME_PREFIX_WRAPPED_ARRAY)
private List<Integer> prefixWrappedArray = null;
private List<Integer> prefixWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAMESPACE_STRING = "namespace_string";
@SerializedName(SERIALIZED_NAME_NAMESPACE_STRING)
@@ -137,11 +137,11 @@ public class XmlItem {
public static final String SERIALIZED_NAME_NAMESPACE_ARRAY = "namespace_array";
@SerializedName(SERIALIZED_NAME_NAMESPACE_ARRAY)
private List<Integer> namespaceArray = null;
private List<Integer> namespaceArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAMESPACE_WRAPPED_ARRAY = "namespace_wrapped_array";
@SerializedName(SERIALIZED_NAME_NAMESPACE_WRAPPED_ARRAY)
private List<Integer> namespaceWrappedArray = null;
private List<Integer> namespaceWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_NS_STRING = "prefix_ns_string";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_STRING)
@@ -161,11 +161,11 @@ public class XmlItem {
public static final String SERIALIZED_NAME_PREFIX_NS_ARRAY = "prefix_ns_array";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_ARRAY)
private List<Integer> prefixNsArray = null;
private List<Integer> prefixNsArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_NS_WRAPPED_ARRAY = "prefix_ns_wrapped_array";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_WRAPPED_ARRAY)
private List<Integer> prefixNsWrappedArray = null;
private List<Integer> prefixNsWrappedArray = new ArrayList<>();
public XmlItem() {
}

View File

@@ -70,7 +70,7 @@ public class Pet {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -56,35 +56,35 @@ import org.openapitools.client.JSON;
public class AdditionalPropertiesClass implements Parcelable {
public static final String SERIALIZED_NAME_MAP_STRING = "map_string";
@SerializedName(SERIALIZED_NAME_MAP_STRING)
private Map<String, String> mapString = null;
private Map<String, String> mapString = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_NUMBER = "map_number";
@SerializedName(SERIALIZED_NAME_MAP_NUMBER)
private Map<String, BigDecimal> mapNumber = null;
private Map<String, BigDecimal> mapNumber = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_INTEGER = "map_integer";
@SerializedName(SERIALIZED_NAME_MAP_INTEGER)
private Map<String, Integer> mapInteger = null;
private Map<String, Integer> mapInteger = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_BOOLEAN = "map_boolean";
@SerializedName(SERIALIZED_NAME_MAP_BOOLEAN)
private Map<String, Boolean> mapBoolean = null;
private Map<String, Boolean> mapBoolean = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_ARRAY_INTEGER = "map_array_integer";
@SerializedName(SERIALIZED_NAME_MAP_ARRAY_INTEGER)
private Map<String, List<Integer>> mapArrayInteger = null;
private Map<String, List<Integer>> mapArrayInteger = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_ARRAY_ANYTYPE = "map_array_anytype";
@SerializedName(SERIALIZED_NAME_MAP_ARRAY_ANYTYPE)
private Map<String, List<Object>> mapArrayAnytype = null;
private Map<String, List<Object>> mapArrayAnytype = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_MAP_STRING = "map_map_string";
@SerializedName(SERIALIZED_NAME_MAP_MAP_STRING)
private Map<String, Map<String, String>> mapMapString = null;
private Map<String, Map<String, String>> mapMapString = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_MAP_ANYTYPE = "map_map_anytype";
@SerializedName(SERIALIZED_NAME_MAP_MAP_ANYTYPE)
private Map<String, Map<String, Object>> mapMapAnytype = null;
private Map<String, Map<String, Object>> mapMapAnytype = new HashMap<>();
public static final String SERIALIZED_NAME_ANYTYPE1 = "anytype_1";
@SerializedName(SERIALIZED_NAME_ANYTYPE1)

View File

@@ -55,7 +55,7 @@ import org.openapitools.client.JSON;
public class ArrayOfArrayOfNumberOnly implements Parcelable {
public static final String SERIALIZED_NAME_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_NUMBER)
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -55,7 +55,7 @@ import org.openapitools.client.JSON;
public class ArrayOfNumberOnly implements Parcelable {
public static final String SERIALIZED_NAME_ARRAY_NUMBER = "ArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_NUMBER)
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -55,15 +55,15 @@ import org.openapitools.client.JSON;
public class ArrayTest implements Parcelable {
public static final String SERIALIZED_NAME_ARRAY_OF_STRING = "array_of_string";
@SerializedName(SERIALIZED_NAME_ARRAY_OF_STRING)
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER)
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL)
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -152,7 +152,7 @@ public class EnumArrays implements Parcelable {
public static final String SERIALIZED_NAME_ARRAY_ENUM = "array_enum";
@SerializedName(SERIALIZED_NAME_ARRAY_ENUM)
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -59,7 +59,7 @@ public class FileSchemaTestClass implements Parcelable {
public static final String SERIALIZED_NAME_FILES = "files";
@SerializedName(SERIALIZED_NAME_FILES)
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -54,7 +54,7 @@ import org.openapitools.client.JSON;
public class MapTest implements Parcelable {
public static final String SERIALIZED_NAME_MAP_MAP_OF_STRING = "map_map_of_string";
@SerializedName(SERIALIZED_NAME_MAP_MAP_OF_STRING)
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -105,15 +105,15 @@ public class MapTest implements Parcelable {
public static final String SERIALIZED_NAME_MAP_OF_ENUM_STRING = "map_of_enum_string";
@SerializedName(SERIALIZED_NAME_MAP_OF_ENUM_STRING)
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String SERIALIZED_NAME_DIRECT_MAP = "direct_map";
@SerializedName(SERIALIZED_NAME_DIRECT_MAP)
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String SERIALIZED_NAME_INDIRECT_MAP = "indirect_map";
@SerializedName(SERIALIZED_NAME_INDIRECT_MAP)
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -65,7 +65,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass implements Parcelable {
public static final String SERIALIZED_NAME_MAP = "map";
@SerializedName(SERIALIZED_NAME_MAP)
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -74,7 +74,7 @@ public class Pet implements Parcelable {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -71,7 +71,7 @@ public class XmlItem implements Parcelable {
public static final String SERIALIZED_NAME_WRAPPED_ARRAY = "wrapped_array";
@SerializedName(SERIALIZED_NAME_WRAPPED_ARRAY)
private List<Integer> wrappedArray = null;
private List<Integer> wrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAME_STRING = "name_string";
@SerializedName(SERIALIZED_NAME_NAME_STRING)
@@ -91,11 +91,11 @@ public class XmlItem implements Parcelable {
public static final String SERIALIZED_NAME_NAME_ARRAY = "name_array";
@SerializedName(SERIALIZED_NAME_NAME_ARRAY)
private List<Integer> nameArray = null;
private List<Integer> nameArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAME_WRAPPED_ARRAY = "name_wrapped_array";
@SerializedName(SERIALIZED_NAME_NAME_WRAPPED_ARRAY)
private List<Integer> nameWrappedArray = null;
private List<Integer> nameWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_STRING = "prefix_string";
@SerializedName(SERIALIZED_NAME_PREFIX_STRING)
@@ -115,11 +115,11 @@ public class XmlItem implements Parcelable {
public static final String SERIALIZED_NAME_PREFIX_ARRAY = "prefix_array";
@SerializedName(SERIALIZED_NAME_PREFIX_ARRAY)
private List<Integer> prefixArray = null;
private List<Integer> prefixArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_WRAPPED_ARRAY = "prefix_wrapped_array";
@SerializedName(SERIALIZED_NAME_PREFIX_WRAPPED_ARRAY)
private List<Integer> prefixWrappedArray = null;
private List<Integer> prefixWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAMESPACE_STRING = "namespace_string";
@SerializedName(SERIALIZED_NAME_NAMESPACE_STRING)
@@ -139,11 +139,11 @@ public class XmlItem implements Parcelable {
public static final String SERIALIZED_NAME_NAMESPACE_ARRAY = "namespace_array";
@SerializedName(SERIALIZED_NAME_NAMESPACE_ARRAY)
private List<Integer> namespaceArray = null;
private List<Integer> namespaceArray = new ArrayList<>();
public static final String SERIALIZED_NAME_NAMESPACE_WRAPPED_ARRAY = "namespace_wrapped_array";
@SerializedName(SERIALIZED_NAME_NAMESPACE_WRAPPED_ARRAY)
private List<Integer> namespaceWrappedArray = null;
private List<Integer> namespaceWrappedArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_NS_STRING = "prefix_ns_string";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_STRING)
@@ -163,11 +163,11 @@ public class XmlItem implements Parcelable {
public static final String SERIALIZED_NAME_PREFIX_NS_ARRAY = "prefix_ns_array";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_ARRAY)
private List<Integer> prefixNsArray = null;
private List<Integer> prefixNsArray = new ArrayList<>();
public static final String SERIALIZED_NAME_PREFIX_NS_WRAPPED_ARRAY = "prefix_ns_wrapped_array";
@SerializedName(SERIALIZED_NAME_PREFIX_NS_WRAPPED_ARRAY)
private List<Integer> prefixNsWrappedArray = null;
private List<Integer> prefixNsWrappedArray = new ArrayList<>();
public XmlItem() {
}

View File

@@ -73,7 +73,7 @@ public class Pet {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -53,11 +53,11 @@ import org.openapitools.client.JSON;
public class AdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP_PROPERTY = "map_property";
@SerializedName(SERIALIZED_NAME_MAP_PROPERTY)
private Map<String, String> mapProperty = null;
private Map<String, String> mapProperty = new HashMap<>();
public static final String SERIALIZED_NAME_MAP_OF_MAP_PROPERTY = "map_of_map_property";
@SerializedName(SERIALIZED_NAME_MAP_OF_MAP_PROPERTY)
private Map<String, Map<String, String>> mapOfMapProperty = null;
private Map<String, Map<String, String>> mapOfMapProperty = new HashMap<>();
public static final String SERIALIZED_NAME_ANYTYPE1 = "anytype_1";
@SerializedName(SERIALIZED_NAME_ANYTYPE1)
@@ -73,7 +73,7 @@ public class AdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP_WITH_UNDECLARED_PROPERTIES_ANYTYPE3 = "map_with_undeclared_properties_anytype_3";
@SerializedName(SERIALIZED_NAME_MAP_WITH_UNDECLARED_PROPERTIES_ANYTYPE3)
private Map<String, Object> mapWithUndeclaredPropertiesAnytype3 = null;
private Map<String, Object> mapWithUndeclaredPropertiesAnytype3 = new HashMap<>();
public static final String SERIALIZED_NAME_EMPTY_MAP = "empty_map";
@SerializedName(SERIALIZED_NAME_EMPTY_MAP)
@@ -81,7 +81,7 @@ public class AdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP_WITH_UNDECLARED_PROPERTIES_STRING = "map_with_undeclared_properties_string";
@SerializedName(SERIALIZED_NAME_MAP_WITH_UNDECLARED_PROPERTIES_STRING)
private Map<String, String> mapWithUndeclaredPropertiesString = null;
private Map<String, String> mapWithUndeclaredPropertiesString = new HashMap<>();
public AdditionalPropertiesClass() {
}

View File

@@ -53,7 +53,7 @@ import org.openapitools.client.JSON;
public class ArrayOfArrayOfNumberOnly {
public static final String SERIALIZED_NAME_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_NUMBER)
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber = new ArrayList<>();
public ArrayOfArrayOfNumberOnly() {
}

View File

@@ -61,7 +61,7 @@ public class ArrayOfInlineAllOf {
public static final String SERIALIZED_NAME_ARRAY_ALLOF_DOG_PROPERTY = "array_allof_dog_property";
@SerializedName(SERIALIZED_NAME_ARRAY_ALLOF_DOG_PROPERTY)
private List<ArrayOfInlineAllOfArrayAllofDogPropertyInner> arrayAllofDogProperty = null;
private List<ArrayOfInlineAllOfArrayAllofDogPropertyInner> arrayAllofDogProperty = new ArrayList<>();
public ArrayOfInlineAllOf() {
}

View File

@@ -53,7 +53,7 @@ import org.openapitools.client.JSON;
public class ArrayOfNumberOnly {
public static final String SERIALIZED_NAME_ARRAY_NUMBER = "ArrayNumber";
@SerializedName(SERIALIZED_NAME_ARRAY_NUMBER)
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber = new ArrayList<>();
public ArrayOfNumberOnly() {
}

View File

@@ -53,15 +53,15 @@ import org.openapitools.client.JSON;
public class ArrayTest {
public static final String SERIALIZED_NAME_ARRAY_OF_STRING = "array_of_string";
@SerializedName(SERIALIZED_NAME_ARRAY_OF_STRING)
private List<String> arrayOfString = null;
private List<String> arrayOfString = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_INTEGER)
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger = new ArrayList<>();
public static final String SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
@SerializedName(SERIALIZED_NAME_ARRAY_ARRAY_OF_MODEL)
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel = new ArrayList<>();
public ArrayTest() {
}

View File

@@ -69,7 +69,7 @@ public class Drawing {
public static final String SERIALIZED_NAME_SHAPES = "shapes";
@SerializedName(SERIALIZED_NAME_SHAPES)
private List<Shape> shapes = null;
private List<Shape> shapes = new ArrayList<>();
public Drawing() {
}

View File

@@ -150,7 +150,7 @@ public class EnumArrays {
public static final String SERIALIZED_NAME_ARRAY_ENUM = "array_enum";
@SerializedName(SERIALIZED_NAME_ARRAY_ENUM)
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum = new ArrayList<>();
public EnumArrays() {
}

View File

@@ -57,7 +57,7 @@ public class FileSchemaTestClass {
public static final String SERIALIZED_NAME_FILES = "files";
@SerializedName(SERIALIZED_NAME_FILES)
private List<ModelFile> files = null;
private List<ModelFile> files = new ArrayList<>();
public FileSchemaTestClass() {
}

View File

@@ -52,7 +52,7 @@ import org.openapitools.client.JSON;
public class MapTest {
public static final String SERIALIZED_NAME_MAP_MAP_OF_STRING = "map_map_of_string";
@SerializedName(SERIALIZED_NAME_MAP_MAP_OF_STRING)
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString = new HashMap<>();
/**
* Gets or Sets inner
@@ -103,15 +103,15 @@ public class MapTest {
public static final String SERIALIZED_NAME_MAP_OF_ENUM_STRING = "map_of_enum_string";
@SerializedName(SERIALIZED_NAME_MAP_OF_ENUM_STRING)
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString = new HashMap<>();
public static final String SERIALIZED_NAME_DIRECT_MAP = "direct_map";
@SerializedName(SERIALIZED_NAME_DIRECT_MAP)
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap = new HashMap<>();
public static final String SERIALIZED_NAME_INDIRECT_MAP = "indirect_map";
@SerializedName(SERIALIZED_NAME_INDIRECT_MAP)
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap = new HashMap<>();
public MapTest() {
}

View File

@@ -63,7 +63,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
public static final String SERIALIZED_NAME_MAP = "map";
@SerializedName(SERIALIZED_NAME_MAP)
private Map<String, Animal> map = null;
private Map<String, Animal> map = new HashMap<>();
public MixedPropertiesAndAdditionalPropertiesClass() {
}

View File

@@ -82,27 +82,27 @@ public class NullableClass {
public static final String SERIALIZED_NAME_ARRAY_NULLABLE_PROP = "array_nullable_prop";
@SerializedName(SERIALIZED_NAME_ARRAY_NULLABLE_PROP)
private List<Object> arrayNullableProp = null;
private List<Object> arrayNullableProp;
public static final String SERIALIZED_NAME_ARRAY_AND_ITEMS_NULLABLE_PROP = "array_and_items_nullable_prop";
@SerializedName(SERIALIZED_NAME_ARRAY_AND_ITEMS_NULLABLE_PROP)
private List<Object> arrayAndItemsNullableProp = null;
private List<Object> arrayAndItemsNullableProp;
public static final String SERIALIZED_NAME_ARRAY_ITEMS_NULLABLE = "array_items_nullable";
@SerializedName(SERIALIZED_NAME_ARRAY_ITEMS_NULLABLE)
private List<Object> arrayItemsNullable = null;
private List<Object> arrayItemsNullable = new ArrayList<>();
public static final String SERIALIZED_NAME_OBJECT_NULLABLE_PROP = "object_nullable_prop";
@SerializedName(SERIALIZED_NAME_OBJECT_NULLABLE_PROP)
private Map<String, Object> objectNullableProp = null;
private Map<String, Object> objectNullableProp;
public static final String SERIALIZED_NAME_OBJECT_AND_ITEMS_NULLABLE_PROP = "object_and_items_nullable_prop";
@SerializedName(SERIALIZED_NAME_OBJECT_AND_ITEMS_NULLABLE_PROP)
private Map<String, Object> objectAndItemsNullableProp = null;
private Map<String, Object> objectAndItemsNullableProp;
public static final String SERIALIZED_NAME_OBJECT_ITEMS_NULLABLE = "object_items_nullable";
@SerializedName(SERIALIZED_NAME_OBJECT_ITEMS_NULLABLE)
private Map<String, Object> objectItemsNullable = null;
private Map<String, Object> objectItemsNullable = new HashMap<>();
public NullableClass() {
}
@@ -246,9 +246,6 @@ public class NullableClass {
}
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null) {
this.arrayNullableProp = null;
}
this.arrayNullableProp.add(arrayNullablePropItem);
return this;
}
@@ -276,9 +273,6 @@ public class NullableClass {
}
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null) {
this.arrayAndItemsNullableProp = null;
}
this.arrayAndItemsNullableProp.add(arrayAndItemsNullablePropItem);
return this;
}
@@ -336,9 +330,6 @@ public class NullableClass {
}
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null) {
this.objectNullableProp = null;
}
this.objectNullableProp.put(key, objectNullablePropItem);
return this;
}
@@ -366,9 +357,6 @@ public class NullableClass {
}
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null) {
this.objectAndItemsNullableProp = null;
}
this.objectAndItemsNullableProp.put(key, objectAndItemsNullablePropItem);
return this;
}

View File

@@ -66,7 +66,7 @@ public class ObjectWithDeprecatedFields {
public static final String SERIALIZED_NAME_BARS = "bars";
@SerializedName(SERIALIZED_NAME_BARS)
private List<String> bars = null;
private List<String> bars = new ArrayList<>();
public ObjectWithDeprecatedFields() {
}

View File

@@ -70,7 +70,7 @@ public class Pet {
public static final String SERIALIZED_NAME_TAGS = "tags";
@SerializedName(SERIALIZED_NAME_TAGS)
private List<Tag> tags = null;
private List<Tag> tags = new ArrayList<>();
/**
* pet status in the store

View File

@@ -46,28 +46,28 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AdditionalPropertiesClass {
public static final String JSON_PROPERTY_MAP_STRING = "map_string";
private Map<String, String> mapString = null;
private Map<String, String> mapString;
public static final String JSON_PROPERTY_MAP_NUMBER = "map_number";
private Map<String, BigDecimal> mapNumber = null;
private Map<String, BigDecimal> mapNumber;
public static final String JSON_PROPERTY_MAP_INTEGER = "map_integer";
private Map<String, Integer> mapInteger = null;
private Map<String, Integer> mapInteger;
public static final String JSON_PROPERTY_MAP_BOOLEAN = "map_boolean";
private Map<String, Boolean> mapBoolean = null;
private Map<String, Boolean> mapBoolean;
public static final String JSON_PROPERTY_MAP_ARRAY_INTEGER = "map_array_integer";
private Map<String, List<Integer>> mapArrayInteger = null;
private Map<String, List<Integer>> mapArrayInteger;
public static final String JSON_PROPERTY_MAP_ARRAY_ANYTYPE = "map_array_anytype";
private Map<String, List<Object>> mapArrayAnytype = null;
private Map<String, List<Object>> mapArrayAnytype;
public static final String JSON_PROPERTY_MAP_MAP_STRING = "map_map_string";
private Map<String, Map<String, String>> mapMapString = null;
private Map<String, Map<String, String>> mapMapString;
public static final String JSON_PROPERTY_MAP_MAP_ANYTYPE = "map_map_anytype";
private Map<String, Map<String, Object>> mapMapAnytype = null;
private Map<String, Map<String, Object>> mapMapAnytype;
public static final String JSON_PROPERTY_ANYTYPE1 = "anytype_1";
private Object anytype1;
@@ -88,9 +88,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapStringItem(String key, String mapStringItem) {
if (this.mapString == null) {
this.mapString = null;
}
this.mapString.put(key, mapStringItem);
return this;
}
@@ -122,9 +119,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapNumberItem(String key, BigDecimal mapNumberItem) {
if (this.mapNumber == null) {
this.mapNumber = null;
}
this.mapNumber.put(key, mapNumberItem);
return this;
}
@@ -156,9 +150,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapIntegerItem(String key, Integer mapIntegerItem) {
if (this.mapInteger == null) {
this.mapInteger = null;
}
this.mapInteger.put(key, mapIntegerItem);
return this;
}
@@ -190,9 +181,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapBooleanItem(String key, Boolean mapBooleanItem) {
if (this.mapBoolean == null) {
this.mapBoolean = null;
}
this.mapBoolean.put(key, mapBooleanItem);
return this;
}
@@ -224,9 +212,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapArrayIntegerItem(String key, List<Integer> mapArrayIntegerItem) {
if (this.mapArrayInteger == null) {
this.mapArrayInteger = null;
}
this.mapArrayInteger.put(key, mapArrayIntegerItem);
return this;
}
@@ -258,9 +243,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapArrayAnytypeItem(String key, List<Object> mapArrayAnytypeItem) {
if (this.mapArrayAnytype == null) {
this.mapArrayAnytype = null;
}
this.mapArrayAnytype.put(key, mapArrayAnytypeItem);
return this;
}
@@ -292,9 +274,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapMapStringItem(String key, Map<String, String> mapMapStringItem) {
if (this.mapMapString == null) {
this.mapMapString = null;
}
this.mapMapString.put(key, mapMapStringItem);
return this;
}
@@ -326,9 +305,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapMapAnytypeItem(String key, Map<String, Object> mapMapAnytypeItem) {
if (this.mapMapAnytype == null) {
this.mapMapAnytype = null;
}
this.mapMapAnytype.put(key, mapMapAnytypeItem);
return this;
}

View File

@@ -35,7 +35,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber;
public ArrayOfArrayOfNumberOnly() {
}
@@ -47,9 +47,6 @@ public class ArrayOfArrayOfNumberOnly {
}
public ArrayOfArrayOfNumberOnly addArrayArrayNumberItem(List<BigDecimal> arrayArrayNumberItem) {
if (this.arrayArrayNumber == null) {
this.arrayArrayNumber = null;
}
this.arrayArrayNumber.add(arrayArrayNumberItem);
return this;
}

View File

@@ -35,7 +35,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_NUMBER = "ArrayNumber";
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber;
public ArrayOfNumberOnly() {
}
@@ -47,9 +47,6 @@ public class ArrayOfNumberOnly {
}
public ArrayOfNumberOnly addArrayNumberItem(BigDecimal arrayNumberItem) {
if (this.arrayNumber == null) {
this.arrayNumber = null;
}
this.arrayNumber.add(arrayNumberItem);
return this;
}

View File

@@ -37,13 +37,13 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayTest {
public static final String JSON_PROPERTY_ARRAY_OF_STRING = "array_of_string";
private List<String> arrayOfString = null;
private List<String> arrayOfString;
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger;
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel;
public ArrayTest() {
}
@@ -55,9 +55,6 @@ public class ArrayTest {
}
public ArrayTest addArrayOfStringItem(String arrayOfStringItem) {
if (this.arrayOfString == null) {
this.arrayOfString = null;
}
this.arrayOfString.add(arrayOfStringItem);
return this;
}
@@ -89,9 +86,6 @@ public class ArrayTest {
}
public ArrayTest addArrayArrayOfIntegerItem(List<Long> arrayArrayOfIntegerItem) {
if (this.arrayArrayOfInteger == null) {
this.arrayArrayOfInteger = null;
}
this.arrayArrayOfInteger.add(arrayArrayOfIntegerItem);
return this;
}
@@ -123,9 +117,6 @@ public class ArrayTest {
}
public ArrayTest addArrayArrayOfModelItem(List<ReadOnlyFirst> arrayArrayOfModelItem) {
if (this.arrayArrayOfModel == null) {
this.arrayArrayOfModel = null;
}
this.arrayArrayOfModel.add(arrayArrayOfModelItem);
return this;
}

View File

@@ -108,7 +108,7 @@ public class EnumArrays {
}
public static final String JSON_PROPERTY_ARRAY_ENUM = "array_enum";
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum;
public EnumArrays() {
}
@@ -146,9 +146,6 @@ public class EnumArrays {
}
public EnumArrays addArrayEnumItem(ArrayEnumEnum arrayEnumItem) {
if (this.arrayEnum == null) {
this.arrayEnum = null;
}
this.arrayEnum.add(arrayEnumItem);
return this;
}

View File

@@ -39,7 +39,7 @@ public class FileSchemaTestClass {
private ModelFile _file;
public static final String JSON_PROPERTY_FILES = "files";
private List<ModelFile> files = null;
private List<ModelFile> files;
public FileSchemaTestClass() {
}
@@ -77,9 +77,6 @@ public class FileSchemaTestClass {
}
public FileSchemaTestClass addFilesItem(ModelFile filesItem) {
if (this.files == null) {
this.files = null;
}
this.files.add(filesItem);
return this;
}

View File

@@ -37,7 +37,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class MapTest {
public static final String JSON_PROPERTY_MAP_MAP_OF_STRING = "map_map_of_string";
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString;
/**
* Gets or Sets inner
@@ -75,13 +75,13 @@ public class MapTest {
}
public static final String JSON_PROPERTY_MAP_OF_ENUM_STRING = "map_of_enum_string";
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString;
public static final String JSON_PROPERTY_DIRECT_MAP = "direct_map";
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap;
public static final String JSON_PROPERTY_INDIRECT_MAP = "indirect_map";
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap;
public MapTest() {
}
@@ -93,9 +93,6 @@ public class MapTest {
}
public MapTest putMapMapOfStringItem(String key, Map<String, String> mapMapOfStringItem) {
if (this.mapMapOfString == null) {
this.mapMapOfString = null;
}
this.mapMapOfString.put(key, mapMapOfStringItem);
return this;
}
@@ -127,9 +124,6 @@ public class MapTest {
}
public MapTest putMapOfEnumStringItem(String key, InnerEnum mapOfEnumStringItem) {
if (this.mapOfEnumString == null) {
this.mapOfEnumString = null;
}
this.mapOfEnumString.put(key, mapOfEnumStringItem);
return this;
}
@@ -161,9 +155,6 @@ public class MapTest {
}
public MapTest putDirectMapItem(String key, Boolean directMapItem) {
if (this.directMap == null) {
this.directMap = null;
}
this.directMap.put(key, directMapItem);
return this;
}
@@ -195,9 +186,6 @@ public class MapTest {
}
public MapTest putIndirectMapItem(String key, Boolean indirectMapItem) {
if (this.indirectMap == null) {
this.indirectMap = null;
}
this.indirectMap.put(key, indirectMapItem);
return this;
}

View File

@@ -45,7 +45,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
private OffsetDateTime dateTime;
public static final String JSON_PROPERTY_MAP = "map";
private Map<String, Animal> map = null;
private Map<String, Animal> map;
public MixedPropertiesAndAdditionalPropertiesClass() {
}
@@ -109,9 +109,6 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
}
public MixedPropertiesAndAdditionalPropertiesClass putMapItem(String key, Animal mapItem) {
if (this.map == null) {
this.map = null;
}
this.map.put(key, mapItem);
return this;
}

View File

@@ -53,10 +53,10 @@ public class Pet {
private String name;
public static final String JSON_PROPERTY_PHOTO_URLS = "photoUrls";
private Set<String> photoUrls = null;
private Set<String> photoUrls;
public static final String JSON_PROPERTY_TAGS = "tags";
private List<Tag> tags = null;
private List<Tag> tags;
/**
* pet status in the store
@@ -218,9 +218,6 @@ public class Pet {
}
public Pet addTagsItem(Tag tagsItem) {
if (this.tags == null) {
this.tags = null;
}
this.tags.add(tagsItem);
return this;
}

View File

@@ -51,7 +51,7 @@ public class TypeHolderDefault {
private Boolean boolItem = true;
public static final String JSON_PROPERTY_ARRAY_ITEM = "array_item";
private List<Integer> arrayItem = null;
private List<Integer> arrayItem;
public TypeHolderDefault() {
}

View File

@@ -55,7 +55,7 @@ public class TypeHolderExample {
private Boolean boolItem;
public static final String JSON_PROPERTY_ARRAY_ITEM = "array_item";
private List<Integer> arrayItem = null;
private List<Integer> arrayItem;
public TypeHolderExample() {
}

View File

@@ -75,7 +75,7 @@ public class XmlItem {
private Boolean attributeBoolean;
public static final String JSON_PROPERTY_WRAPPED_ARRAY = "wrapped_array";
private List<Integer> wrappedArray = null;
private List<Integer> wrappedArray;
public static final String JSON_PROPERTY_NAME_STRING = "name_string";
private String nameString;
@@ -90,10 +90,10 @@ public class XmlItem {
private Boolean nameBoolean;
public static final String JSON_PROPERTY_NAME_ARRAY = "name_array";
private List<Integer> nameArray = null;
private List<Integer> nameArray;
public static final String JSON_PROPERTY_NAME_WRAPPED_ARRAY = "name_wrapped_array";
private List<Integer> nameWrappedArray = null;
private List<Integer> nameWrappedArray;
public static final String JSON_PROPERTY_PREFIX_STRING = "prefix_string";
private String prefixString;
@@ -108,10 +108,10 @@ public class XmlItem {
private Boolean prefixBoolean;
public static final String JSON_PROPERTY_PREFIX_ARRAY = "prefix_array";
private List<Integer> prefixArray = null;
private List<Integer> prefixArray;
public static final String JSON_PROPERTY_PREFIX_WRAPPED_ARRAY = "prefix_wrapped_array";
private List<Integer> prefixWrappedArray = null;
private List<Integer> prefixWrappedArray;
public static final String JSON_PROPERTY_NAMESPACE_STRING = "namespace_string";
private String namespaceString;
@@ -126,10 +126,10 @@ public class XmlItem {
private Boolean namespaceBoolean;
public static final String JSON_PROPERTY_NAMESPACE_ARRAY = "namespace_array";
private List<Integer> namespaceArray = null;
private List<Integer> namespaceArray;
public static final String JSON_PROPERTY_NAMESPACE_WRAPPED_ARRAY = "namespace_wrapped_array";
private List<Integer> namespaceWrappedArray = null;
private List<Integer> namespaceWrappedArray;
public static final String JSON_PROPERTY_PREFIX_NS_STRING = "prefix_ns_string";
private String prefixNsString;
@@ -144,10 +144,10 @@ public class XmlItem {
private Boolean prefixNsBoolean;
public static final String JSON_PROPERTY_PREFIX_NS_ARRAY = "prefix_ns_array";
private List<Integer> prefixNsArray = null;
private List<Integer> prefixNsArray;
public static final String JSON_PROPERTY_PREFIX_NS_WRAPPED_ARRAY = "prefix_ns_wrapped_array";
private List<Integer> prefixNsWrappedArray = null;
private List<Integer> prefixNsWrappedArray;
public XmlItem() {
}
@@ -263,9 +263,6 @@ public class XmlItem {
}
public XmlItem addWrappedArrayItem(Integer wrappedArrayItem) {
if (this.wrappedArray == null) {
this.wrappedArray = null;
}
this.wrappedArray.add(wrappedArrayItem);
return this;
}
@@ -401,9 +398,6 @@ public class XmlItem {
}
public XmlItem addNameArrayItem(Integer nameArrayItem) {
if (this.nameArray == null) {
this.nameArray = null;
}
this.nameArray.add(nameArrayItem);
return this;
}
@@ -435,9 +429,6 @@ public class XmlItem {
}
public XmlItem addNameWrappedArrayItem(Integer nameWrappedArrayItem) {
if (this.nameWrappedArray == null) {
this.nameWrappedArray = null;
}
this.nameWrappedArray.add(nameWrappedArrayItem);
return this;
}
@@ -573,9 +564,6 @@ public class XmlItem {
}
public XmlItem addPrefixArrayItem(Integer prefixArrayItem) {
if (this.prefixArray == null) {
this.prefixArray = null;
}
this.prefixArray.add(prefixArrayItem);
return this;
}
@@ -607,9 +595,6 @@ public class XmlItem {
}
public XmlItem addPrefixWrappedArrayItem(Integer prefixWrappedArrayItem) {
if (this.prefixWrappedArray == null) {
this.prefixWrappedArray = null;
}
this.prefixWrappedArray.add(prefixWrappedArrayItem);
return this;
}
@@ -745,9 +730,6 @@ public class XmlItem {
}
public XmlItem addNamespaceArrayItem(Integer namespaceArrayItem) {
if (this.namespaceArray == null) {
this.namespaceArray = null;
}
this.namespaceArray.add(namespaceArrayItem);
return this;
}
@@ -779,9 +761,6 @@ public class XmlItem {
}
public XmlItem addNamespaceWrappedArrayItem(Integer namespaceWrappedArrayItem) {
if (this.namespaceWrappedArray == null) {
this.namespaceWrappedArray = null;
}
this.namespaceWrappedArray.add(namespaceWrappedArrayItem);
return this;
}
@@ -917,9 +896,6 @@ public class XmlItem {
}
public XmlItem addPrefixNsArrayItem(Integer prefixNsArrayItem) {
if (this.prefixNsArray == null) {
this.prefixNsArray = null;
}
this.prefixNsArray.add(prefixNsArrayItem);
return this;
}
@@ -951,9 +927,6 @@ public class XmlItem {
}
public XmlItem addPrefixNsWrappedArrayItem(Integer prefixNsWrappedArrayItem) {
if (this.prefixNsWrappedArray == null) {
this.prefixNsWrappedArray = null;
}
this.prefixNsWrappedArray.add(prefixNsWrappedArrayItem);
return this;
}

View File

@@ -305,7 +305,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -351,7 +351,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -431,7 +431,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -477,7 +477,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);

View File

@@ -35,10 +35,10 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class AdditionalPropertiesClass {
public static final String JSON_PROPERTY_MAP_PROPERTY = "map_property";
private Map<String, String> mapProperty = null;
private Map<String, String> mapProperty;
public static final String JSON_PROPERTY_MAP_OF_MAP_PROPERTY = "map_of_map_property";
private Map<String, Map<String, String>> mapOfMapProperty = null;
private Map<String, Map<String, String>> mapOfMapProperty;
public AdditionalPropertiesClass() {
}
@@ -50,9 +50,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapPropertyItem(String key, String mapPropertyItem) {
if (this.mapProperty == null) {
this.mapProperty = null;
}
this.mapProperty.put(key, mapPropertyItem);
return this;
}
@@ -84,9 +81,6 @@ public class AdditionalPropertiesClass {
}
public AdditionalPropertiesClass putMapOfMapPropertyItem(String key, Map<String, String> mapOfMapPropertyItem) {
if (this.mapOfMapProperty == null) {
this.mapOfMapProperty = null;
}
this.mapOfMapProperty.put(key, mapOfMapPropertyItem);
return this;
}

View File

@@ -35,7 +35,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_ARRAY_NUMBER = "ArrayArrayNumber";
private List<List<BigDecimal>> arrayArrayNumber = null;
private List<List<BigDecimal>> arrayArrayNumber;
public ArrayOfArrayOfNumberOnly() {
}
@@ -47,9 +47,6 @@ public class ArrayOfArrayOfNumberOnly {
}
public ArrayOfArrayOfNumberOnly addArrayArrayNumberItem(List<BigDecimal> arrayArrayNumberItem) {
if (this.arrayArrayNumber == null) {
this.arrayArrayNumber = null;
}
this.arrayArrayNumber.add(arrayArrayNumberItem);
return this;
}

View File

@@ -35,7 +35,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayOfNumberOnly {
public static final String JSON_PROPERTY_ARRAY_NUMBER = "ArrayNumber";
private List<BigDecimal> arrayNumber = null;
private List<BigDecimal> arrayNumber;
public ArrayOfNumberOnly() {
}
@@ -47,9 +47,6 @@ public class ArrayOfNumberOnly {
}
public ArrayOfNumberOnly addArrayNumberItem(BigDecimal arrayNumberItem) {
if (this.arrayNumber == null) {
this.arrayNumber = null;
}
this.arrayNumber.add(arrayNumberItem);
return this;
}

View File

@@ -37,13 +37,13 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class ArrayTest {
public static final String JSON_PROPERTY_ARRAY_OF_STRING = "array_of_string";
private List<String> arrayOfString = null;
private List<String> arrayOfString;
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_INTEGER = "array_array_of_integer";
private List<List<Long>> arrayArrayOfInteger = null;
private List<List<Long>> arrayArrayOfInteger;
public static final String JSON_PROPERTY_ARRAY_ARRAY_OF_MODEL = "array_array_of_model";
private List<List<ReadOnlyFirst>> arrayArrayOfModel = null;
private List<List<ReadOnlyFirst>> arrayArrayOfModel;
public ArrayTest() {
}
@@ -55,9 +55,6 @@ public class ArrayTest {
}
public ArrayTest addArrayOfStringItem(String arrayOfStringItem) {
if (this.arrayOfString == null) {
this.arrayOfString = null;
}
this.arrayOfString.add(arrayOfStringItem);
return this;
}
@@ -89,9 +86,6 @@ public class ArrayTest {
}
public ArrayTest addArrayArrayOfIntegerItem(List<Long> arrayArrayOfIntegerItem) {
if (this.arrayArrayOfInteger == null) {
this.arrayArrayOfInteger = null;
}
this.arrayArrayOfInteger.add(arrayArrayOfIntegerItem);
return this;
}
@@ -123,9 +117,6 @@ public class ArrayTest {
}
public ArrayTest addArrayArrayOfModelItem(List<ReadOnlyFirst> arrayArrayOfModelItem) {
if (this.arrayArrayOfModel == null) {
this.arrayArrayOfModel = null;
}
this.arrayArrayOfModel.add(arrayArrayOfModelItem);
return this;
}

View File

@@ -108,7 +108,7 @@ public class EnumArrays {
}
public static final String JSON_PROPERTY_ARRAY_ENUM = "array_enum";
private List<ArrayEnumEnum> arrayEnum = null;
private List<ArrayEnumEnum> arrayEnum;
public EnumArrays() {
}
@@ -146,9 +146,6 @@ public class EnumArrays {
}
public EnumArrays addArrayEnumItem(ArrayEnumEnum arrayEnumItem) {
if (this.arrayEnum == null) {
this.arrayEnum = null;
}
this.arrayEnum.add(arrayEnumItem);
return this;
}

View File

@@ -39,7 +39,7 @@ public class FileSchemaTestClass {
private ModelFile _file;
public static final String JSON_PROPERTY_FILES = "files";
private List<ModelFile> files = null;
private List<ModelFile> files;
public FileSchemaTestClass() {
}
@@ -77,9 +77,6 @@ public class FileSchemaTestClass {
}
public FileSchemaTestClass addFilesItem(ModelFile filesItem) {
if (this.files == null) {
this.files = null;
}
this.files.add(filesItem);
return this;
}

View File

@@ -37,7 +37,7 @@ import com.fasterxml.jackson.annotation.JsonTypeName;
@javax.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class MapTest {
public static final String JSON_PROPERTY_MAP_MAP_OF_STRING = "map_map_of_string";
private Map<String, Map<String, String>> mapMapOfString = null;
private Map<String, Map<String, String>> mapMapOfString;
/**
* Gets or Sets inner
@@ -75,13 +75,13 @@ public class MapTest {
}
public static final String JSON_PROPERTY_MAP_OF_ENUM_STRING = "map_of_enum_string";
private Map<String, InnerEnum> mapOfEnumString = null;
private Map<String, InnerEnum> mapOfEnumString;
public static final String JSON_PROPERTY_DIRECT_MAP = "direct_map";
private Map<String, Boolean> directMap = null;
private Map<String, Boolean> directMap;
public static final String JSON_PROPERTY_INDIRECT_MAP = "indirect_map";
private Map<String, Boolean> indirectMap = null;
private Map<String, Boolean> indirectMap;
public MapTest() {
}
@@ -93,9 +93,6 @@ public class MapTest {
}
public MapTest putMapMapOfStringItem(String key, Map<String, String> mapMapOfStringItem) {
if (this.mapMapOfString == null) {
this.mapMapOfString = null;
}
this.mapMapOfString.put(key, mapMapOfStringItem);
return this;
}
@@ -127,9 +124,6 @@ public class MapTest {
}
public MapTest putMapOfEnumStringItem(String key, InnerEnum mapOfEnumStringItem) {
if (this.mapOfEnumString == null) {
this.mapOfEnumString = null;
}
this.mapOfEnumString.put(key, mapOfEnumStringItem);
return this;
}
@@ -161,9 +155,6 @@ public class MapTest {
}
public MapTest putDirectMapItem(String key, Boolean directMapItem) {
if (this.directMap == null) {
this.directMap = null;
}
this.directMap.put(key, directMapItem);
return this;
}
@@ -195,9 +186,6 @@ public class MapTest {
}
public MapTest putIndirectMapItem(String key, Boolean indirectMapItem) {
if (this.indirectMap == null) {
this.indirectMap = null;
}
this.indirectMap.put(key, indirectMapItem);
return this;
}

View File

@@ -45,7 +45,7 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
private OffsetDateTime dateTime;
public static final String JSON_PROPERTY_MAP = "map";
private Map<String, Animal> map = null;
private Map<String, Animal> map;
public MixedPropertiesAndAdditionalPropertiesClass() {
}
@@ -109,9 +109,6 @@ public class MixedPropertiesAndAdditionalPropertiesClass {
}
public MixedPropertiesAndAdditionalPropertiesClass putMapItem(String key, Animal mapItem) {
if (this.map == null) {
this.map = null;
}
this.map.put(key, mapItem);
return this;
}

View File

@@ -78,7 +78,7 @@ public class NullableClass extends HashMap<String, Object> {
private JsonNullable<List<Object>> arrayAndItemsNullableProp = JsonNullable.<List<Object>>undefined();
public static final String JSON_PROPERTY_ARRAY_ITEMS_NULLABLE = "array_items_nullable";
private List<Object> arrayItemsNullable = null;
private List<Object> arrayItemsNullable;
public static final String JSON_PROPERTY_OBJECT_NULLABLE_PROP = "object_nullable_prop";
private JsonNullable<Map<String, Object>> objectNullableProp = JsonNullable.<Map<String, Object>>undefined();
@@ -87,7 +87,7 @@ public class NullableClass extends HashMap<String, Object> {
private JsonNullable<Map<String, Object>> objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>undefined();
public static final String JSON_PROPERTY_OBJECT_ITEMS_NULLABLE = "object_items_nullable";
private Map<String, Object> objectItemsNullable = null;
private Map<String, Object> objectItemsNullable;
public NullableClass() {
@@ -305,7 +305,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayNullablePropItem(Object arrayNullablePropItem) {
if (this.arrayNullableProp == null || !this.arrayNullableProp.isPresent()) {
this.arrayNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayNullableProp.get().add(arrayNullablePropItem);
@@ -351,7 +351,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass addArrayAndItemsNullablePropItem(Object arrayAndItemsNullablePropItem) {
if (this.arrayAndItemsNullableProp == null || !this.arrayAndItemsNullableProp.isPresent()) {
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(null);
this.arrayAndItemsNullableProp = JsonNullable.<List<Object>>of(new ArrayList<>());
}
try {
this.arrayAndItemsNullableProp.get().add(arrayAndItemsNullablePropItem);
@@ -396,9 +396,6 @@ public class NullableClass extends HashMap<String, Object> {
}
public NullableClass addArrayItemsNullableItem(Object arrayItemsNullableItem) {
if (this.arrayItemsNullable == null) {
this.arrayItemsNullable = null;
}
this.arrayItemsNullable.add(arrayItemsNullableItem);
return this;
}
@@ -431,7 +428,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectNullablePropItem(String key, Object objectNullablePropItem) {
if (this.objectNullableProp == null || !this.objectNullableProp.isPresent()) {
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectNullableProp.get().put(key, objectNullablePropItem);
@@ -477,7 +474,7 @@ public class NullableClass extends HashMap<String, Object> {
public NullableClass putObjectAndItemsNullablePropItem(String key, Object objectAndItemsNullablePropItem) {
if (this.objectAndItemsNullableProp == null || !this.objectAndItemsNullableProp.isPresent()) {
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(null);
this.objectAndItemsNullableProp = JsonNullable.<Map<String, Object>>of(new HashMap<>());
}
try {
this.objectAndItemsNullableProp.get().put(key, objectAndItemsNullablePropItem);
@@ -522,9 +519,6 @@ public class NullableClass extends HashMap<String, Object> {
}
public NullableClass putObjectItemsNullableItem(String key, Object objectItemsNullableItem) {
if (this.objectItemsNullable == null) {
this.objectItemsNullable = null;
}
this.objectItemsNullable.put(key, objectItemsNullableItem);
return this;
}

View File

@@ -48,7 +48,7 @@ public class ObjectWithDeprecatedFields {
private DeprecatedObject deprecatedRef;
public static final String JSON_PROPERTY_BARS = "bars";
private List<String> bars = null;
private List<String> bars;
public ObjectWithDeprecatedFields() {
}
@@ -142,9 +142,6 @@ public class ObjectWithDeprecatedFields {
}
public ObjectWithDeprecatedFields addBarsItem(String barsItem) {
if (this.bars == null) {
this.bars = null;
}
this.bars.add(barsItem);
return this;
}

View File

@@ -53,10 +53,10 @@ public class Pet {
private String name;
public static final String JSON_PROPERTY_PHOTO_URLS = "photoUrls";
private Set<String> photoUrls = null;
private Set<String> photoUrls;
public static final String JSON_PROPERTY_TAGS = "tags";
private List<Tag> tags = null;
private List<Tag> tags;
/**
* pet status in the store
@@ -218,9 +218,6 @@ public class Pet {
}
public Pet addTagsItem(Tag tagsItem) {
if (this.tags == null) {
this.tags = null;
}
this.tags.add(tagsItem);
return this;
}