forked from loafle/openapi-generator-original
removed swagger-core deps
This commit is contained in:
parent
df333fdfb5
commit
07ab7d98a6
@ -40,6 +40,7 @@ object JavaWordnikApiCodegen extends BasicJavaGenerator {
|
|||||||
override def supportingFiles =
|
override def supportingFiles =
|
||||||
List(
|
List(
|
||||||
("apiInvoker.mustache", destinationDir + java.io.File.separator + invokerPackage.get.replaceAll("\\.", java.io.File.separator) + java.io.File.separator, "ApiInvoker.java"),
|
("apiInvoker.mustache", destinationDir + java.io.File.separator + invokerPackage.get.replaceAll("\\.", java.io.File.separator) + java.io.File.separator, "ApiInvoker.java"),
|
||||||
|
("JsonUtil.mustache", destinationDir + java.io.File.separator + invokerPackage.get.replaceAll("\\.", java.io.File.separator) + java.io.File.separator, "JsonUtil.java"),
|
||||||
("apiException.mustache", destinationDir + java.io.File.separator + invokerPackage.get.replaceAll("\\.", java.io.File.separator) + java.io.File.separator, "ApiException.java"),
|
("apiException.mustache", destinationDir + java.io.File.separator + invokerPackage.get.replaceAll("\\.", java.io.File.separator) + java.io.File.separator, "ApiException.java"),
|
||||||
("pom.mustache", destinationRoot, "pom.xml"))
|
("pom.mustache", destinationRoot, "pom.xml"))
|
||||||
}
|
}
|
||||||
|
@ -170,13 +170,6 @@
|
|||||||
<groupId>org.scala-lang</groupId>
|
<groupId>org.scala-lang</groupId>
|
||||||
<artifactId>scala-library</artifactId>
|
<artifactId>scala-library</artifactId>
|
||||||
<version>${scala-version}</version>
|
<version>${scala-version}</version>
|
||||||
<scope>compile</scope>
|
|
||||||
</dependency>
|
|
||||||
<dependency>
|
|
||||||
<groupId>com.wordnik</groupId>
|
|
||||||
<artifactId>swagger-core_2.9.1</artifactId>
|
|
||||||
<version>${swagger-core-version}</version>
|
|
||||||
<scope>compile</scope>
|
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.scalatest</groupId>
|
<groupId>org.scalatest</groupId>
|
||||||
@ -184,6 +177,24 @@
|
|||||||
<version>${scala-test-version}</version>
|
<version>${scala-test-version}</version>
|
||||||
<scope>test</scope>
|
<scope>test</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.fasterxml.jackson.core</groupId>
|
||||||
|
<artifactId>jackson-annotations</artifactId>
|
||||||
|
<version>${jackson-version}</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.fasterxml.jackson.core</groupId>
|
||||||
|
<artifactId>jackson-core</artifactId>
|
||||||
|
<version>${jackson-version}</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
|
<dependency>
|
||||||
|
<groupId>com.fasterxml.jackson.core</groupId>
|
||||||
|
<artifactId>jackson-databind</artifactId>
|
||||||
|
<version>${jackson-version}</version>
|
||||||
|
<scope>compile</scope>
|
||||||
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>junit</groupId>
|
<groupId>junit</groupId>
|
||||||
<artifactId>junit</artifactId>
|
<artifactId>junit</artifactId>
|
||||||
@ -213,13 +224,11 @@
|
|||||||
|
|
||||||
<properties>
|
<properties>
|
||||||
<jersey-version>1.7</jersey-version>
|
<jersey-version>1.7</jersey-version>
|
||||||
<swagger-core-version>1.1.0</swagger-core-version>
|
|
||||||
<scala-version>2.9.1-1</scala-version>
|
<scala-version>2.9.1-1</scala-version>
|
||||||
<junit-version>4.8.1</junit-version>
|
<junit-version>4.8.1</junit-version>
|
||||||
|
<jackson-version>2.0.4</jackson-version>
|
||||||
<maven-plugin.version>1.0.0</maven-plugin.version>
|
<maven-plugin.version>1.0.0</maven-plugin.version>
|
||||||
<scala-test-version>1.6.1</scala-test-version>
|
<scala-test-version>1.6.1</scala-test-version>
|
||||||
<junit-version>4.8.1</junit-version>
|
|
||||||
<scala-test-version>1.6.1</scala-test-version>
|
|
||||||
</properties>
|
</properties>
|
||||||
</project>
|
</project>
|
||||||
|
|
||||||
|
@ -1,7 +1,5 @@
|
|||||||
package com.wordnik.client.common;
|
package com.wordnik.client.common;
|
||||||
|
|
||||||
import com.wordnik.swagger.core.util.JsonUtil;
|
|
||||||
|
|
||||||
import com.fasterxml.jackson.core.JsonGenerator.Feature;
|
import com.fasterxml.jackson.core.JsonGenerator.Feature;
|
||||||
import com.fasterxml.jackson.databind.*;
|
import com.fasterxml.jackson.databind.*;
|
||||||
import com.fasterxml.jackson.annotation.*;
|
import com.fasterxml.jackson.annotation.*;
|
||||||
|
@ -0,0 +1,20 @@
|
|||||||
|
package com.wordnik.client.common;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.*;
|
||||||
|
import com.fasterxml.jackson.databind.*;
|
||||||
|
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
|
||||||
|
import com.fasterxml.jackson.core.JsonGenerator.Feature;
|
||||||
|
|
||||||
|
public class JsonUtil {
|
||||||
|
public static ObjectMapper mapper;
|
||||||
|
|
||||||
|
static {
|
||||||
|
mapper = new ObjectMapper();
|
||||||
|
mapper.configure(DeserializationFeature.FAIL_ON_UNKNOWN_PROPERTIES, false);
|
||||||
|
mapper.disable(SerializationFeature.WRITE_DATES_AS_TIMESTAMPS);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static ObjectMapper getJsonMapper() {
|
||||||
|
return mapper;
|
||||||
|
}
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user