Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Java] fix bug to only remove "CustomInstantDeserializer" for Play v2.5 #6444

Merged
merged 3 commits into from
Sep 6, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -280,8 +280,8 @@ public void processOpts() {

if (additionalProperties.containsKey("jackson")) {
supportingFiles.add(new SupportingFile("RFC3339DateFormat.mustache", invokerFolder, "RFC3339DateFormat.java"));
if (!"threetenbp".equals(dateLibrary)) {
supportingFiles.remove("CustomInstantDeserializer.mustache");
if ("threetenbp".equals(dateLibrary) && !usePlayWS) {
supportingFiles.add(new SupportingFile("CustomInstantDeserializer.mustache", invokerFolder, "CustomInstantDeserializer.java"));
}
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ public AdditionalPropertiesClass mapProperty(Map<String, String> mapProperty) {

public AdditionalPropertiesClass putMapPropertyItem(String key, String mapPropertyItem) {
if (this.mapProperty == null) {
this.mapProperty = new HashMap<>();
this.mapProperty = new HashMap<String, String>();
}
this.mapProperty.put(key, mapPropertyItem);
return this;
Expand All @@ -67,7 +67,7 @@ public AdditionalPropertiesClass mapOfMapProperty(Map<String, Map<String, String

public AdditionalPropertiesClass putMapOfMapPropertyItem(String key, Map<String, String> mapOfMapPropertyItem) {
if (this.mapOfMapProperty == null) {
this.mapOfMapProperty = new HashMap<>();
this.mapOfMapProperty = new HashMap<String, Map<String, String>>();
}
this.mapOfMapProperty.put(key, mapOfMapPropertyItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public ArrayOfArrayOfNumberOnly arrayArrayNumber(List<List<BigDecimal>> arrayArr

public ArrayOfArrayOfNumberOnly addArrayArrayNumberItem(List<BigDecimal> arrayArrayNumberItem) {
if (this.arrayArrayNumber == null) {
this.arrayArrayNumber = new ArrayList<>();
this.arrayArrayNumber = new ArrayList<List<BigDecimal>>();
}
this.arrayArrayNumber.add(arrayArrayNumberItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ public ArrayOfNumberOnly arrayNumber(List<BigDecimal> arrayNumber) {

public ArrayOfNumberOnly addArrayNumberItem(BigDecimal arrayNumberItem) {
if (this.arrayNumber == null) {
this.arrayNumber = new ArrayList<>();
this.arrayNumber = new ArrayList<BigDecimal>();
}
this.arrayNumber.add(arrayNumberItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public ArrayTest arrayOfString(List<String> arrayOfString) {

public ArrayTest addArrayOfStringItem(String arrayOfStringItem) {
if (this.arrayOfString == null) {
this.arrayOfString = new ArrayList<>();
this.arrayOfString = new ArrayList<String>();
}
this.arrayOfString.add(arrayOfStringItem);
return this;
Expand All @@ -70,7 +70,7 @@ public ArrayTest arrayArrayOfInteger(List<List<Long>> arrayArrayOfInteger) {

public ArrayTest addArrayArrayOfIntegerItem(List<Long> arrayArrayOfIntegerItem) {
if (this.arrayArrayOfInteger == null) {
this.arrayArrayOfInteger = new ArrayList<>();
this.arrayArrayOfInteger = new ArrayList<List<Long>>();
}
this.arrayArrayOfInteger.add(arrayArrayOfIntegerItem);
return this;
Expand All @@ -96,7 +96,7 @@ public ArrayTest arrayArrayOfModel(List<List<ReadOnlyFirst>> arrayArrayOfModel)

public ArrayTest addArrayArrayOfModelItem(List<ReadOnlyFirst> arrayArrayOfModelItem) {
if (this.arrayArrayOfModel == null) {
this.arrayArrayOfModel = new ArrayList<>();
this.arrayArrayOfModel = new ArrayList<List<ReadOnlyFirst>>();
}
this.arrayArrayOfModel.add(arrayArrayOfModelItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ public EnumArrays arrayEnum(List<ArrayEnumEnum> arrayEnum) {

public EnumArrays addArrayEnumItem(ArrayEnumEnum arrayEnumItem) {
if (this.arrayEnum == null) {
this.arrayEnum = new ArrayList<>();
this.arrayEnum = new ArrayList<ArrayEnumEnum>();
}
this.arrayEnum.add(arrayEnumItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ public MapTest mapMapOfString(Map<String, Map<String, String>> mapMapOfString) {

public MapTest putMapMapOfStringItem(String key, Map<String, String> mapMapOfStringItem) {
if (this.mapMapOfString == null) {
this.mapMapOfString = new HashMap<>();
this.mapMapOfString = new HashMap<String, Map<String, String>>();
}
this.mapMapOfString.put(key, mapMapOfStringItem);
return this;
Expand All @@ -102,7 +102,7 @@ public MapTest mapOfEnumString(Map<String, InnerEnum> mapOfEnumString) {

public MapTest putMapOfEnumStringItem(String key, InnerEnum mapOfEnumStringItem) {
if (this.mapOfEnumString == null) {
this.mapOfEnumString = new HashMap<>();
this.mapOfEnumString = new HashMap<String, InnerEnum>();
}
this.mapOfEnumString.put(key, mapOfEnumStringItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ public MixedPropertiesAndAdditionalPropertiesClass map(Map<String, Animal> map)

public MixedPropertiesAndAdditionalPropertiesClass putMapItem(String key, Animal mapItem) {
if (this.map == null) {
this.map = new HashMap<>();
this.map = new HashMap<String, Animal>();
}
this.map.put(key, mapItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class Pet {
private String name = null;

@JsonProperty("photoUrls")
private List<String> photoUrls = new ArrayList<>();
private List<String> photoUrls = new ArrayList<String>();

@JsonProperty("tags")
private List<Tag> tags = null;
Expand Down Expand Up @@ -168,7 +168,7 @@ public Pet tags(List<Tag> tags) {

public Pet addTagsItem(Tag tagsItem) {
if (this.tags == null) {
this.tags = new ArrayList<>();
this.tags = new ArrayList<Tag>();
}
this.tags.add(tagsItem);
return this;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.math.BigDecimal;
import io.swagger.client.model.Client;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Client;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.io.File;
import io.swagger.client.model.ModelApiResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Order;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.User;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.math.BigDecimal;
import io.swagger.client.model.Client;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Client;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.io.File;
import io.swagger.client.model.ModelApiResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Order;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.User;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.math.BigDecimal;
import io.swagger.client.model.Client;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Client;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import java.io.File;
import io.swagger.client.model.ModelApiResponse;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.Order;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import retrofit2.http.*;

import okhttp3.RequestBody;
import okhttp3.ResponseBody;

import io.swagger.client.model.User;

Expand Down