Rename default packages for 'jaxrs-spec' (#333)

This commit is contained in:
Jérémie Bresson 2018-05-06 12:34:36 +02:00 committed by GitHub
parent c4afaac285
commit d8fd560d64
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
139 changed files with 4585 additions and 174 deletions

View File

@ -27,7 +27,7 @@ fi
# if you've executed sbt assembly previously it will use that instead. # if you've executed sbt assembly previously it will use that instead.
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties" export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
ags="$@ generate -i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -l jaxrs-spec -o samples/server/petstore/jaxrs-spec-interface-response ags="$@ generate --artifact-id jaxrs-spec-interface-response-petstore-server -i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -l jaxrs-spec -o samples/server/petstore/jaxrs-spec-interface-response
-DhideGenerationTimestamp=true -DhideGenerationTimestamp=true
-DserializableModel=true -DserializableModel=true
-DinterfaceOnly=true -DinterfaceOnly=true

View File

@ -27,7 +27,7 @@ fi
# if you've executed sbt assembly previously it will use that instead. # if you've executed sbt assembly previously it will use that instead.
export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties" export JAVA_OPTS="${JAVA_OPTS} -XX:MaxPermSize=256M -Xmx1024M -DloggerPath=conf/log4j.properties"
ags="$@ generate -i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -l jaxrs-spec -o samples/server/petstore/jaxrs-spec-interface ags="$@ generate --artifact-id jaxrs-spec-interface-petstore-server -i modules/openapi-generator/src/test/resources/2_0/petstore-with-fake-endpoints-models-for-testing.yaml -l jaxrs-spec -o samples/server/petstore/jaxrs-spec-interface
-DhideGenerationTimestamp=true -DhideGenerationTimestamp=true
-DserializableModel=true -DserializableModel=true
-DinterfaceOnly=true" -DinterfaceOnly=true"

View File

@ -17,22 +17,21 @@
package org.openapitools.codegen.languages; package org.openapitools.codegen.languages;
import io.swagger.v3.oas.models.Operation;
import org.openapitools.codegen.CliOption;
import org.openapitools.codegen.CodegenConstants;
import org.openapitools.codegen.CodegenModel;
import org.openapitools.codegen.CodegenOperation;
import org.openapitools.codegen.CodegenProperty;
import org.openapitools.codegen.SupportingFile;
import java.io.File; import java.io.File;
import java.io.IOException;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.LinkedHashMap; import java.util.LinkedHashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import org.apache.commons.io.FileUtils;
import org.openapitools.codegen.*;
import org.openapitools.codegen.languages.features.BeanValidationFeatures;
import org.openapitools.codegen.languages.features.JbossFeature;
import org.openapitools.codegen.languages.features.SwaggerFeatures;
import io.swagger.v3.oas.models.*;
import io.swagger.v3.core.util.Json;
public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen { public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen {
public static final String INTERFACE_ONLY = "interfaceOnly"; public static final String INTERFACE_ONLY = "interfaceOnly";
@ -45,14 +44,14 @@ public class JavaJAXRSSpecServerCodegen extends AbstractJavaJAXRSServerCodegen {
public JavaJAXRSSpecServerCodegen() { public JavaJAXRSSpecServerCodegen() {
super(); super();
invokerPackage = "io.swagger.api"; invokerPackage = "org.openapitools.api";
artifactId = "openapi-jaxrs-server"; artifactId = "openapi-jaxrs-server";
outputFolder = "generated-code/JavaJaxRS-Spec"; outputFolder = "generated-code/JavaJaxRS-Spec";
modelTemplateFiles.put("model.mustache", ".java"); modelTemplateFiles.put("model.mustache", ".java");
apiTemplateFiles.put("api.mustache", ".java"); apiTemplateFiles.put("api.mustache", ".java");
apiPackage = "io.swagger.api"; apiPackage = "org.openapitools.api";
modelPackage = "io.swagger.model"; modelPackage = "org.openapitools.model";
apiTestTemplateFiles.clear(); // TODO: add api test template apiTestTemplateFiles.clear(); // TODO: add api test template
modelTestTemplateFiles.clear(); // TODO: add model test template modelTestTemplateFiles.clear(); // TODO: add model test template

View File

@ -1,9 +1,9 @@
package io.swagger.api; package org.openapitools.api;
import java.io.File; import java.io.File;
import io.swagger.model.ModelApiResponse; import org.openapitools.model.ModelApiResponse;
import io.swagger.model.Pet; import org.openapitools.model.Pet;
import io.swagger.api.PetApiService; import org.openapitools.api.PetApiService;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Context; import javax.ws.rs.core.Context;

View File

@ -1,14 +1,14 @@
package io.swagger.api; package org.openapitools.api;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import org.apache.cxf.jaxrs.ext.multipart.Multipart; import org.apache.cxf.jaxrs.ext.multipart.Multipart;
import java.io.File; import java.io.File;
import io.swagger.model.ModelApiResponse; import org.openapitools.model.ModelApiResponse;
import io.swagger.model.Pet; import org.openapitools.model.Pet;
import java.util.List; import java.util.List;

View File

@ -1,8 +1,8 @@
package io.swagger.api; package org.openapitools.api;
import java.util.Map; import java.util.Map;
import io.swagger.model.Order; import org.openapitools.model.Order;
import io.swagger.api.StoreApiService; import org.openapitools.api.StoreApiService;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Context; import javax.ws.rs.core.Context;
@ -69,7 +69,7 @@ public class StoreApi {
@ApiResponse(code = 200, message = "successful operation", response = Order.class), @ApiResponse(code = 200, message = "successful operation", response = Order.class),
@ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class), @ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class),
@ApiResponse(code = 404, message = "Order not found", response = Void.class) }) @ApiResponse(code = 404, message = "Order not found", response = Void.class) })
public Response getOrderById( @Min(1L) @Max(5L)@ApiParam(value = "ID of pet that needs to be fetched",required=true, allowableValues="range=[1, 5]") @PathParam("orderId") Long orderId) { public Response getOrderById( @Min(1L) @Max(5L)@ApiParam(value = "ID of pet that needs to be fetched",required=true) @PathParam("orderId") Long orderId) {
return delegate.getOrderById(orderId, securityContext); return delegate.getOrderById(orderId, securityContext);
} }

View File

@ -1,13 +1,13 @@
package io.swagger.api; package org.openapitools.api;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import org.apache.cxf.jaxrs.ext.multipart.Multipart; import org.apache.cxf.jaxrs.ext.multipart.Multipart;
import java.util.Map; import java.util.Map;
import io.swagger.model.Order; import org.openapitools.model.Order;
import java.util.List; import java.util.List;

View File

@ -1,8 +1,8 @@
package io.swagger.api; package org.openapitools.api;
import java.util.List; import java.util.List;
import io.swagger.model.User; import org.openapitools.model.User;
import io.swagger.api.UserApiService; import org.openapitools.api.UserApiService;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Context; import javax.ws.rs.core.Context;

View File

@ -1,13 +1,13 @@
package io.swagger.api; package org.openapitools.api;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import org.apache.cxf.jaxrs.ext.multipart.Multipart; import org.apache.cxf.jaxrs.ext.multipart.Multipart;
import java.util.List; import java.util.List;
import io.swagger.model.User; import org.openapitools.model.User;
import java.util.List; import java.util.List;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;

View File

@ -1,12 +1,12 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import io.swagger.model.Category;
import io.swagger.model.Tag;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import org.openapitools.model.Category;
import org.openapitools.model.Tag;
import javax.validation.constraints.*; import javax.validation.constraints.*;
/** /**

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonCreator;

View File

@ -1,4 +1,4 @@
package io.swagger.api; package org.openapitools.api;
import javax.ws.rs.ApplicationPath; import javax.ws.rs.ApplicationPath;
import javax.ws.rs.core.Application; import javax.ws.rs.core.Application;

View File

@ -1,13 +1,13 @@
package io.swagger.api.impl; package org.openapitools.api.impl;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import java.io.File; import java.io.File;
import io.swagger.model.ModelApiResponse; import org.openapitools.model.ModelApiResponse;
import io.swagger.model.Pet; import org.openapitools.model.Pet;
import java.util.List; import java.util.List;

View File

@ -1,12 +1,12 @@
package io.swagger.api.impl; package org.openapitools.api.impl;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import java.util.Map; import java.util.Map;
import io.swagger.model.Order; import org.openapitools.model.Order;
import java.util.List; import java.util.List;

View File

@ -1,12 +1,12 @@
package io.swagger.api.impl; package org.openapitools.api.impl;
import io.swagger.api.*; import org.openapitools.api.*;
import io.swagger.model.*; import org.openapitools.model.*;
import org.apache.cxf.jaxrs.ext.multipart.Attachment; import org.apache.cxf.jaxrs.ext.multipart.Attachment;
import java.util.List; import java.util.List;
import io.swagger.model.User; import org.openapitools.model.User;
import java.util.List; import java.util.List;

View File

@ -0,0 +1,23 @@
# OpenAPI Generator Ignore
# Generated by openapi-generator https://github.com/openapitools/openapi-generator
# Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore.
# As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs
# You can match any string of characters against a directory, file or extension with a single asterisk (*):
#foo/*/qux
# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux
# You can recursively match patterns against a directory, file or extension with a double asterisk (**):
#foo/**/qux
# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux
# You can also negate patterns with an exclamation (!).
# For example, you can ignore all files in a docs folder with the file extension .md:
#docs/*.md
# Then explicitly reverse the ignore rule for a single file:
#!docs/README.md

View File

@ -0,0 +1 @@
3.0.0-SNAPSHOT

View File

@ -0,0 +1,48 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>org.openapitools</groupId>
<artifactId>jaxrs-spec-interface-response-petstore-server</artifactId>
<packaging>jar</packaging>
<name>jaxrs-spec-interface-response-petstore-server</name>
<version>1.0.0</version>
<build>
<sourceDirectory>src/main/java</sourceDirectory>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-jar-plugin</artifactId>
<version>2.2</version>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>javax.ws.rs</groupId>
<artifactId>javax.ws.rs-api</artifactId>
<version>2.0</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>io.swagger</groupId>
<artifactId>swagger-annotations</artifactId>
<scope>provided</scope>
<version>1.5.3</version>
</dependency>
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit-version}</version>
<scope>test</scope>
</dependency>
<!-- Bean Validation API support -->
<dependency>
<groupId>javax.validation</groupId>
<artifactId>validation-api</artifactId>
<version>1.1.0.Final</version>
<scope>provided</scope>
</dependency>
</dependencies>
<properties>
<junit-version>4.8.1</junit-version>
</properties>
</project>

View File

@ -0,0 +1,27 @@
package org.openapitools.api;
import org.openapitools.model.Client;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/another-fake")
@Api(description = "the another-fake API")
public interface AnotherFakeApi {
@PATCH
@Path("/dummy")
@Consumes({ "application/json" })
@Produces({ "application/json" })
@ApiOperation(value = "To test special tags", notes = "To test special tags", tags={ "$another-fake?" })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Client.class) })
Response testSpecialTags(@Valid Client client);
}

View File

@ -0,0 +1,108 @@
package org.openapitools.api;
import java.math.BigDecimal;
import org.openapitools.model.Client;
import java.util.Date;
import java.io.File;
import org.joda.time.LocalDate;
import java.util.Map;
import org.openapitools.model.OuterComposite;
import org.openapitools.model.User;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/fake")
@Api(description = "the fake API")
public interface FakeApi {
@POST
@Path("/outer/boolean")
@Produces({ "*/*" })
@ApiOperation(value = "", notes = "Test serialization of outer boolean types", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "Output boolean", response = Boolean.class) })
Response fakeOuterBooleanSerialize(@Valid Boolean body);
@POST
@Path("/outer/composite")
@Produces({ "*/*" })
@ApiOperation(value = "", notes = "Test serialization of object with outer number type", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "Output composite", response = OuterComposite.class) })
Response fakeOuterCompositeSerialize(@Valid OuterComposite outerComposite);
@POST
@Path("/outer/number")
@Produces({ "*/*" })
@ApiOperation(value = "", notes = "Test serialization of outer number types", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "Output number", response = BigDecimal.class) })
Response fakeOuterNumberSerialize(@Valid BigDecimal body);
@POST
@Path("/outer/string")
@Produces({ "*/*" })
@ApiOperation(value = "", notes = "Test serialization of outer string types", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "Output string", response = String.class) })
Response fakeOuterStringSerialize(@Valid String body);
@PUT
@Path("/body-with-query-params")
@Consumes({ "application/json" })
@ApiOperation(value = "", notes = "", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "Success", response = Void.class) })
Response testBodyWithQueryParams(@QueryParam("query") @NotNull String query,@Valid User user);
@PATCH
@Consumes({ "application/json" })
@Produces({ "application/json" })
@ApiOperation(value = "To test \"client\" model", notes = "To test \"client\" model", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Client.class) })
Response testClientModel(@Valid Client client);
@POST
@Consumes({ "application/x-www-form-urlencoded" })
@ApiOperation(value = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", notes = "Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 ", authorizations = {
@Authorization(value = "http_basic_test")
}, tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid username supplied", response = Void.class),
@ApiResponse(code = 404, message = "User not found", response = Void.class) })
Response testEndpointParameters(@FormParam(value = "number") BigDecimal number,@FormParam(value = "double") Double _double,@FormParam(value = "pattern_without_delimiter") String patternWithoutDelimiter,@FormParam(value = "byte") byte[] _byte,@FormParam(value = "integer") Integer integer,@FormParam(value = "int32") Integer int32,@FormParam(value = "int64") Long int64,@FormParam(value = "float") Float _float,@FormParam(value = "string") String string, @FormParam(value = "binary") InputStream binaryInputStream,
@FormParam(value = "binary") Attachment binaryDetail,@FormParam(value = "date") LocalDate date,@FormParam(value = "dateTime") Date dateTime,@FormParam(value = "password") String password,@FormParam(value = "callback") String paramCallback);
@GET
@Consumes({ "application/x-www-form-urlencoded" })
@ApiOperation(value = "To test enum parameters", notes = "To test enum parameters", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid request", response = Void.class),
@ApiResponse(code = 404, message = "Not found", response = Void.class) })
Response testEnumParameters(@HeaderParam("enum_header_string_array") @ApiParam("Header parameter enum test (string array)") List<String> enumHeaderStringArray,@HeaderParam("enum_header_string") @DefaultValue("-efg") @ApiParam("Header parameter enum test (string)") String enumHeaderString,@QueryParam("enum_query_string_array") @ApiParam("Query parameter enum test (string array)") List<String> enumQueryStringArray,@QueryParam("enum_query_string") @DefaultValue("-efg") @ApiParam("Query parameter enum test (string)") String enumQueryString,@QueryParam("enum_query_integer") @ApiParam("Query parameter enum test (double)") Integer enumQueryInteger,@QueryParam("enum_query_double") @ApiParam("Query parameter enum test (double)") Double enumQueryDouble,@FormParam(value = "enum_form_string_array") String enumFormStringArray,@FormParam(value = "enum_form_string") String enumFormString);
@POST
@Path("/inline-additionalProperties")
@Consumes({ "application/json" })
@ApiOperation(value = "test inline additionalProperties", notes = "", tags={ "fake", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response testInlineAdditionalProperties(@Valid String requestBody);
@GET
@Path("/jsonFormData")
@Consumes({ "application/x-www-form-urlencoded" })
@ApiOperation(value = "test json serialization of form data", notes = "", tags={ "fake" })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response testJsonFormData(@FormParam(value = "param") String param,@FormParam(value = "param2") String param2);
}

View File

@ -0,0 +1,28 @@
package org.openapitools.api;
import org.openapitools.model.Client;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/fake_classname_test")
@Api(description = "the fake_classname_test API")
public interface FakeClassnameTestApi {
@PATCH
@Consumes({ "application/json" })
@Produces({ "application/json" })
@ApiOperation(value = "To test class name in snake case", notes = "To test class name in snake case", authorizations = {
@Authorization(value = "api_key_query")
}, tags={ "fake_classname_tags 123#$%^" })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Client.class) })
Response testClassname(@Valid Client client);
}

View File

@ -0,0 +1,126 @@
package org.openapitools.api;
import java.io.File;
import org.openapitools.model.ModelApiResponse;
import org.openapitools.model.Pet;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/pet")
@Api(description = "the pet API")
public interface PetApi {
@POST
@Consumes({ "application/json", "application/xml" })
@ApiOperation(value = "Add a new pet to the store", notes = "", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 405, message = "Invalid input", response = Void.class) })
Response addPet(@Valid Pet pet);
@DELETE
@Path("/{petId}")
@ApiOperation(value = "Deletes a pet", notes = "", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid pet value", response = Void.class) })
Response deletePet(@PathParam("petId") @ApiParam("Pet id to delete") Long petId,@HeaderParam("api_key") String apiKey);
@GET
@Path("/findByStatus")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Finds Pets by status", notes = "Multiple status values can be provided with comma separated strings", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Pet.class, responseContainer = "List"),
@ApiResponse(code = 400, message = "Invalid status value", response = Void.class, responseContainer = "List") })
Response findPetsByStatus(@QueryParam("status") @NotNull @ApiParam("Status values that need to be considered for filter") List<String> status);
@GET
@Path("/findByTags")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Finds Pets by tags", notes = "Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Pet.class, responseContainer = "List"),
@ApiResponse(code = 400, message = "Invalid tag value", response = Void.class, responseContainer = "List") })
Response findPetsByTags(@QueryParam("tags") @NotNull @ApiParam("Tags to filter by") List<String> tags);
@GET
@Path("/{petId}")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Find pet by ID", notes = "Returns a single pet", authorizations = {
@Authorization(value = "api_key")
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Pet.class),
@ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class),
@ApiResponse(code = 404, message = "Pet not found", response = Void.class) })
Response getPetById(@PathParam("petId") @ApiParam("ID of pet to return") Long petId);
@PUT
@Consumes({ "application/json", "application/xml" })
@ApiOperation(value = "Update an existing pet", notes = "", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class),
@ApiResponse(code = 404, message = "Pet not found", response = Void.class),
@ApiResponse(code = 405, message = "Validation exception", response = Void.class) })
Response updatePet(@Valid Pet pet);
@POST
@Path("/{petId}")
@Consumes({ "application/x-www-form-urlencoded" })
@ApiOperation(value = "Updates a pet in the store with form data", notes = "", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet", })
@ApiResponses(value = {
@ApiResponse(code = 405, message = "Invalid input", response = Void.class) })
Response updatePetWithForm(@PathParam("petId") @ApiParam("ID of pet that needs to be updated") Long petId,@FormParam(value = "name") String name,@FormParam(value = "status") String status);
@POST
@Path("/{petId}/uploadImage")
@Consumes({ "multipart/form-data" })
@Produces({ "application/json" })
@ApiOperation(value = "uploads an image", notes = "", authorizations = {
@Authorization(value = "petstore_auth", scopes = {
@AuthorizationScope(scope = "write:pets", description = "modify pets in your account"),
@AuthorizationScope(scope = "read:pets", description = "read your pets")
})
}, tags={ "pet" })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = ModelApiResponse.class) })
Response uploadFile(@PathParam("petId") @ApiParam("ID of pet to update") Long petId,@FormParam(value = "additionalMetadata") String additionalMetadata, @FormParam(value = "file") InputStream fileInputStream,
@FormParam(value = "file") Attachment fileDetail);
}

View File

@ -0,0 +1,56 @@
package org.openapitools.api;
import java.util.Map;
import org.openapitools.model.Order;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/store")
@Api(description = "the store API")
public interface StoreApi {
@DELETE
@Path("/order/{order_id}")
@ApiOperation(value = "Delete purchase order by ID", notes = "For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors", tags={ "store", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class),
@ApiResponse(code = 404, message = "Order not found", response = Void.class) })
Response deleteOrder(@PathParam("order_id") @ApiParam("ID of the order that needs to be deleted") String orderId);
@GET
@Path("/inventory")
@Produces({ "application/json" })
@ApiOperation(value = "Returns pet inventories by status", notes = "Returns a map of status codes to quantities", authorizations = {
@Authorization(value = "api_key")
}, tags={ "store", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Map.class, responseContainer = "Map") })
Response getInventory();
@GET
@Path("/order/{order_id}")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Find purchase order by ID", notes = "For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions", tags={ "store", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Order.class),
@ApiResponse(code = 400, message = "Invalid ID supplied", response = Void.class),
@ApiResponse(code = 404, message = "Order not found", response = Void.class) })
Response getOrderById(@PathParam("order_id") @Min(1L) @Max(5L) @ApiParam("ID of pet that needs to be fetched") Long orderId);
@POST
@Path("/order")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Place an order for a pet", notes = "", tags={ "store" })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Order.class),
@ApiResponse(code = 400, message = "Invalid Order", response = Void.class) })
Response placeOrder(@Valid Order order);
}

View File

@ -0,0 +1,81 @@
package org.openapitools.api;
import java.util.List;
import org.openapitools.model.User;
import javax.ws.rs.*;
import javax.ws.rs.core.Response;
import io.swagger.annotations.*;
import java.util.Map;
import java.util.List;
import javax.validation.constraints.*;
import javax.validation.Valid;
@Path("/user")
@Api(description = "the user API")
public interface UserApi {
@POST
@ApiOperation(value = "Create user", notes = "This can only be done by the logged in user.", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response createUser(@Valid User user);
@POST
@Path("/createWithArray")
@ApiOperation(value = "Creates list of users with given input array", notes = "", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response createUsersWithArrayInput(@Valid List<User> user);
@POST
@Path("/createWithList")
@ApiOperation(value = "Creates list of users with given input array", notes = "", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response createUsersWithListInput(@Valid List<User> user);
@DELETE
@Path("/{username}")
@ApiOperation(value = "Delete user", notes = "This can only be done by the logged in user.", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid username supplied", response = Void.class),
@ApiResponse(code = 404, message = "User not found", response = Void.class) })
Response deleteUser(@PathParam("username") @ApiParam("The name that needs to be deleted") String username);
@GET
@Path("/{username}")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Get user by user name", notes = "", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = User.class),
@ApiResponse(code = 400, message = "Invalid username supplied", response = Void.class),
@ApiResponse(code = 404, message = "User not found", response = Void.class) })
Response getUserByName(@PathParam("username") @ApiParam("The name that needs to be fetched. Use user1 for testing.") String username);
@GET
@Path("/login")
@Produces({ "application/xml", "application/json" })
@ApiOperation(value = "Logs user into the system", notes = "", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = String.class),
@ApiResponse(code = 400, message = "Invalid username/password supplied", response = Void.class) })
Response loginUser(@QueryParam("username") @NotNull @ApiParam("The user name for login") String username,@QueryParam("password") @NotNull @ApiParam("The password for login in clear text") String password);
@GET
@Path("/logout")
@ApiOperation(value = "Logs out current logged in user session", notes = "", tags={ "user", })
@ApiResponses(value = {
@ApiResponse(code = 200, message = "successful operation", response = Void.class) })
Response logoutUser();
@PUT
@Path("/{username}")
@ApiOperation(value = "Updated user", notes = "This can only be done by the logged in user.", tags={ "user" })
@ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid user supplied", response = Void.class),
@ApiResponse(code = 404, message = "User not found", response = Void.class) })
Response updateUser(@PathParam("username") @ApiParam("name that need to be deleted") String username,@Valid User user);
}

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeInfo;

View File

@ -0,0 +1,57 @@
package org.openapitools.model;
import java.util.ArrayList;
import java.util.List;
import org.openapitools.model.Animal;
import java.io.Serializable;
import javax.validation.constraints.*;
import javax.validation.Valid;
import io.swagger.annotations.*;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
public class AnimalFarm extends ArrayList<Animal> implements Serializable {
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
AnimalFarm animalFarm = (AnimalFarm) o;
return true;
}
@Override
public int hashCode() {
return Objects.hash();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class AnimalFarm {\n");
sb.append(" ").append(toIndentedString(super.toString())).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -1,8 +1,8 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.ReadOnlyFirst;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import org.openapitools.model.ReadOnlyFirst;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal; import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal; import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.OuterEnum; import org.openapitools.model.OuterEnum;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.File; import java.io.File;
import java.math.BigDecimal; import java.math.BigDecimal;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;

View File

@ -1,11 +1,11 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal;
import java.util.Date; import java.util.Date;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.UUID; import java.util.UUID;
import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.Date; import java.util.Date;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,9 +1,9 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Category;
import io.swagger.model.Tag;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import org.openapitools.model.Category;
import org.openapitools.model.Tag;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,9 +1,9 @@
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd"> <project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion> <modelVersion>4.0.0</modelVersion>
<groupId>org.openapitools</groupId> <groupId>org.openapitools</groupId>
<artifactId>openapi-jaxrs-client</artifactId> <artifactId>jaxrs-spec-interface-petstore-server</artifactId>
<packaging>jar</packaging> <packaging>jar</packaging>
<name>openapi-jaxrs-client</name> <name>jaxrs-spec-interface-petstore-server</name>
<version>1.0.0</version> <version>1.0.0</version>
<build> <build>
<sourceDirectory>src/main/java</sourceDirectory> <sourceDirectory>src/main/java</sourceDirectory>

View File

@ -1,6 +1,6 @@
package io.swagger.api; package org.openapitools.api;
import io.swagger.model.Client; import org.openapitools.model.Client;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;

View File

@ -1,13 +1,13 @@
package io.swagger.api; package org.openapitools.api;
import java.math.BigDecimal; import java.math.BigDecimal;
import io.swagger.model.Client; import org.openapitools.model.Client;
import java.util.Date; import java.util.Date;
import java.io.File; import java.io.File;
import org.joda.time.LocalDate; import org.joda.time.LocalDate;
import java.util.Map; import java.util.Map;
import io.swagger.model.OuterComposite; import org.openapitools.model.OuterComposite;
import io.swagger.model.User; import org.openapitools.model.User;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;
@ -29,7 +29,7 @@ public interface FakeApi {
@ApiOperation(value = "", notes = "Test serialization of outer boolean types", tags={ "fake", }) @ApiOperation(value = "", notes = "Test serialization of outer boolean types", tags={ "fake", })
@ApiResponses(value = { @ApiResponses(value = {
@ApiResponse(code = 200, message = "Output boolean", response = Boolean.class) }) @ApiResponse(code = 200, message = "Output boolean", response = Boolean.class) })
Boolean fakeOuterBooleanSerialize(@Valid Boolean booleanPostBody); Boolean fakeOuterBooleanSerialize(@Valid Boolean body);
@POST @POST
@Path("/outer/composite") @Path("/outer/composite")
@ -88,7 +88,7 @@ public interface FakeApi {
@ApiResponses(value = { @ApiResponses(value = {
@ApiResponse(code = 400, message = "Invalid request", response = Void.class), @ApiResponse(code = 400, message = "Invalid request", response = Void.class),
@ApiResponse(code = 404, message = "Not found", response = Void.class) }) @ApiResponse(code = 404, message = "Not found", response = Void.class) })
void testEnumParameters(@HeaderParam("enum_header_string_array") @ApiParam("Header parameter enum test (string array)") List<String> enumHeaderStringArray,@HeaderParam("enum_header_string") @DefaultValue("-efg") @ApiParam("Header parameter enum test (string)") String enumHeaderString,@QueryParam("enum_query_string_array") @ApiParam("Query parameter enum test (string array)") List<String> enumQueryStringArray,@QueryParam("enum_query_string") @DefaultValue("-efg") @ApiParam("Query parameter enum test (string)") String enumQueryString,@QueryParam("enum_query_integer") @ApiParam("Query parameter enum test (double)") Integer enumQueryInteger,@QueryParam("enum_query_double") @ApiParam("Query parameter enum test (double)") Double enumQueryDouble,@FormParam(value = "enum_form_string_array") List<String> enumFormStringArray,@FormParam(value = "enum_form_string") String enumFormString); void testEnumParameters(@HeaderParam("enum_header_string_array") @ApiParam("Header parameter enum test (string array)") List<String> enumHeaderStringArray,@HeaderParam("enum_header_string") @DefaultValue("-efg") @ApiParam("Header parameter enum test (string)") String enumHeaderString,@QueryParam("enum_query_string_array") @ApiParam("Query parameter enum test (string array)") List<String> enumQueryStringArray,@QueryParam("enum_query_string") @DefaultValue("-efg") @ApiParam("Query parameter enum test (string)") String enumQueryString,@QueryParam("enum_query_integer") @ApiParam("Query parameter enum test (double)") Integer enumQueryInteger,@QueryParam("enum_query_double") @ApiParam("Query parameter enum test (double)") Double enumQueryDouble,@FormParam(value = "enum_form_string_array") String enumFormStringArray,@FormParam(value = "enum_form_string") String enumFormString);
@POST @POST
@Path("/inline-additionalProperties") @Path("/inline-additionalProperties")

View File

@ -1,6 +1,6 @@
package io.swagger.api; package org.openapitools.api;
import io.swagger.model.Client; import org.openapitools.model.Client;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;

View File

@ -1,8 +1,8 @@
package io.swagger.api; package org.openapitools.api;
import java.io.File; import java.io.File;
import io.swagger.model.ModelApiResponse; import org.openapitools.model.ModelApiResponse;
import io.swagger.model.Pet; import org.openapitools.model.Pet;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;

View File

@ -1,7 +1,7 @@
package io.swagger.api; package org.openapitools.api;
import java.util.Map; import java.util.Map;
import io.swagger.model.Order; import org.openapitools.model.Order;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;

View File

@ -1,7 +1,7 @@
package io.swagger.api; package org.openapitools.api;
import java.util.List; import java.util.List;
import io.swagger.model.User; import org.openapitools.model.User;
import javax.ws.rs.*; import javax.ws.rs.*;
import javax.ws.rs.core.Response; import javax.ws.rs.core.Response;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonSubTypes;
import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeInfo;

View File

@ -0,0 +1,57 @@
package org.openapitools.model;
import java.util.ArrayList;
import java.util.List;
import org.openapitools.model.Animal;
import java.io.Serializable;
import javax.validation.constraints.*;
import javax.validation.Valid;
import io.swagger.annotations.*;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
public class AnimalFarm extends ArrayList<Animal> implements Serializable {
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
AnimalFarm animalFarm = (AnimalFarm) o;
return true;
}
@Override
public int hashCode() {
return Objects.hash();
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class AnimalFarm {\n");
sb.append(" ").append(toIndentedString(super.toString())).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.util.ArrayList; import java.util.ArrayList;

View File

@ -1,8 +1,8 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.ReadOnlyFirst;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import org.openapitools.model.ReadOnlyFirst;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal; import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal; import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,6 +1,6 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.OuterEnum; import org.openapitools.model.OuterEnum;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.File; import java.io.File;
import java.math.BigDecimal; import java.math.BigDecimal;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;

View File

@ -1,11 +1,11 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Animal;
import java.util.Date; import java.util.Date;
import java.util.HashMap; import java.util.HashMap;
import java.util.List; import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.UUID; import java.util.UUID;
import org.openapitools.model.Animal;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModel;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.util.Date; import java.util.Date;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.math.BigDecimal; import java.math.BigDecimal;
import java.io.Serializable; import java.io.Serializable;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,9 +1,9 @@
package io.swagger.model; package org.openapitools.model;
import io.swagger.model.Category;
import io.swagger.model.Tag;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List; import java.util.List;
import org.openapitools.model.Category;
import org.openapitools.model.Tag;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;
import javax.validation.Valid; import javax.validation.Valid;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

View File

@ -1,4 +1,4 @@
package io.swagger.model; package org.openapitools.model;
import java.io.Serializable; import java.io.Serializable;
import javax.validation.constraints.*; import javax.validation.constraints.*;

Some files were not shown because too many files have changed in this diff Show More