Generate 'cwiki' (#351)

* Regenerate 'cwiki'

* Change default package value for cwiki
This commit is contained in:
Jérémie Bresson 2018-05-07 11:53:08 +02:00 committed by William Cheng
parent 230b0d24bb
commit e49e8ca169
4 changed files with 188 additions and 75 deletions

View File

@ -17,11 +17,17 @@
package org.openapitools.codegen.languages; package org.openapitools.codegen.languages;
import org.openapitools.codegen.*; import io.swagger.v3.oas.models.media.ArraySchema;
import io.swagger.v3.oas.models.media.Schema;
import org.openapitools.codegen.CliOption;
import org.openapitools.codegen.CodegenConfig;
import org.openapitools.codegen.CodegenConstants;
import org.openapitools.codegen.CodegenOperation;
import org.openapitools.codegen.CodegenType;
import org.openapitools.codegen.DefaultCodegen;
import org.openapitools.codegen.SupportingFile;
import org.openapitools.codegen.utils.ModelUtils; import org.openapitools.codegen.utils.ModelUtils;
import io.swagger.v3.oas.models.OpenAPI;
import io.swagger.v3.oas.models.Operation;
import io.swagger.v3.oas.models.media.*;
import java.util.HashMap; import java.util.HashMap;
import java.util.HashSet; import java.util.HashSet;
@ -30,7 +36,7 @@ import java.util.Map;
public class ConfluenceWikiCodegen extends DefaultCodegen implements CodegenConfig { public class ConfluenceWikiCodegen extends DefaultCodegen implements CodegenConfig {
private static final String ALL_OPERATIONS = ""; private static final String ALL_OPERATIONS = "";
protected String invokerPackage = "io.swagger.client"; protected String invokerPackage = "org.openapitools.client";
protected String groupId = "org.openapitools"; protected String groupId = "org.openapitools";
protected String artifactId = "openapi-client"; protected String artifactId = "openapi-client";
protected String artifactVersion = "1.0.0"; protected String artifactVersion = "1.0.0";

View File

@ -1,11 +1,11 @@
# Swagger Codegen Ignore # OpenAPI Generator Ignore
# Generated by swagger-codegen https://github.com/swagger-api/swagger-codegen # Generated by openapi-generator https://github.com/openapitools/openapi-generator
# Use this file to prevent files from being overwritten by the generator. # Use this file to prevent files from being overwritten by the generator.
# The patterns follow closely to .gitignore or .dockerignore. # The patterns follow closely to .gitignore or .dockerignore.
# As an example, the C# client generator defines ApiClient.cs. # As an example, the C# client generator defines ApiClient.cs.
# You can make changes and tell Swagger Codgen to ignore just this file by uncommenting the following line: # You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line:
#ApiClient.cs #ApiClient.cs
# You can match any string of characters against a directory, file or extension with a single asterisk (*): # You can match any string of characters against a directory, file or extension with a single asterisk (*):

View File

@ -1 +1 @@
2.2.3-SNAPSHOT 3.0.0-SNAPSHOT

View File

@ -21,7 +21,7 @@ h2. Endpoints
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |Pet object that needs to be added to the store |(/) | | | |pet |Pet object that needs to be added to the store |(/) | | |
@ -41,7 +41,8 @@ h2. Endpoints
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid input" "description" : "Invalid input",
"content" : { }
} }
{code} {code}
---- ----
@ -81,7 +82,8 @@ h2. Endpoints
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid pet value" "description" : "Invalid pet value",
"content" : { }
} }
{code} {code}
---- ----
@ -120,10 +122,22 @@ array[Pet]
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"type" : "array", "application/xml" : {
"items" : { "schema" : {
"$ref" : "#/definitions/Pet" "type" : "array",
"items" : {
"$ref" : "#/components/schemas/Pet"
}
}
},
"application/json" : {
"schema" : {
"type" : "array",
"items" : {
"$ref" : "#/components/schemas/Pet"
}
}
} }
} }
} }
@ -139,7 +153,8 @@ array[Pet]
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid status value" "description" : "Invalid status value",
"content" : { }
} }
{code} {code}
---- ----
@ -178,10 +193,22 @@ array[Pet]
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"type" : "array", "application/xml" : {
"items" : { "schema" : {
"$ref" : "#/definitions/Pet" "type" : "array",
"items" : {
"$ref" : "#/components/schemas/Pet"
}
}
},
"application/json" : {
"schema" : {
"type" : "array",
"items" : {
"$ref" : "#/components/schemas/Pet"
}
}
} }
} }
} }
@ -197,7 +224,8 @@ array[Pet]
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid tag value" "description" : "Invalid tag value",
"content" : { }
} }
{code} {code}
---- ----
@ -236,8 +264,17 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"$ref" : "#/definitions/Pet" "application/xml" : {
"schema" : {
"$ref" : "#/components/schemas/Pet"
}
},
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/Pet"
}
}
} }
} }
{code} {code}
@ -252,7 +289,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid ID supplied" "description" : "Invalid ID supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -266,7 +304,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Pet not found" "description" : "Pet not found",
"content" : { }
} }
{code} {code}
---- ----
@ -284,7 +323,7 @@ Pet
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |Pet object that needs to be added to the store |(/) | | | |pet |Pet object that needs to be added to the store |(/) | | |
@ -304,7 +343,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid ID supplied" "description" : "Invalid ID supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -318,7 +358,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Pet not found" "description" : "Pet not found",
"content" : { }
} }
{code} {code}
*Status Code:* 405 *Status Code:* 405
@ -332,7 +373,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Validation exception" "description" : "Validation exception",
"content" : { }
} }
{code} {code}
---- ----
@ -370,7 +412,8 @@ Pet
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid input" "description" : "Invalid input",
"content" : { }
} }
{code} {code}
---- ----
@ -409,8 +452,12 @@ ApiResponse
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"$ref" : "#/definitions/ApiResponse" "application/json" : {
"schema" : {
"$ref" : "#/components/schemas/ApiResponse"
}
}
} }
} }
{code} {code}
@ -449,7 +496,8 @@ ApiResponse
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid ID supplied" "description" : "Invalid ID supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -463,7 +511,8 @@ ApiResponse
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Order not found" "description" : "Order not found",
"content" : { }
} }
{code} {code}
---- ----
@ -498,11 +547,15 @@ map[String, Integer]
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"type" : "object", "application/json" : {
"additionalProperties" : { "schema" : {
"type" : "integer", "type" : "object",
"format" : "int32" "additionalProperties" : {
"type" : "integer",
"format" : "int32"
}
}
} }
} }
} }
@ -543,8 +596,17 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"$ref" : "#/definitions/Order" "application/xml" : {
"schema" : {
"$ref" : "#/components/schemas/Order"
}
},
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/Order"
}
}
} }
} }
{code} {code}
@ -559,7 +621,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid ID supplied" "description" : "Invalid ID supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -573,7 +636,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Order not found" "description" : "Order not found",
"content" : { }
} }
{code} {code}
---- ----
@ -591,7 +655,7 @@ Order
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |order placed for purchasing the pet |(/) | | | |order |order placed for purchasing the pet |(/) | | |
@ -612,8 +676,17 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"$ref" : "#/definitions/Order" "application/xml" : {
"schema" : {
"$ref" : "#/components/schemas/Order"
}
},
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/Order"
}
}
} }
} }
{code} {code}
@ -628,7 +701,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid Order" "description" : "Invalid Order",
"content" : { }
} }
{code} {code}
---- ----
@ -646,7 +720,7 @@ Order
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |Created user object |(/) | | | |user |Created user object |(/) | | |
@ -666,7 +740,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation" "description" : "successful operation",
"content" : { }
} }
{code} {code}
---- ----
@ -684,7 +759,7 @@ Order
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |List of user object |(/) | | | |user |List of user object |(/) | | |
@ -704,7 +779,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation" "description" : "successful operation",
"content" : { }
} }
{code} {code}
---- ----
@ -722,7 +798,7 @@ Order
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |List of user object |(/) | | | |user |List of user object |(/) | | |
@ -742,7 +818,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation" "description" : "successful operation",
"content" : { }
} }
{code} {code}
---- ----
@ -780,7 +857,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid username supplied" "description" : "Invalid username supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -794,7 +872,8 @@ Order
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "User not found" "description" : "User not found",
"content" : { }
} }
{code} {code}
---- ----
@ -811,7 +890,7 @@ Order
h4. Parameters h4. Parameters
h5. Path Parameters h5. Path Parameters
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|username |The name that needs to be fetched. Use user1 for testing. |(/) | | | |username |The name that needs to be fetched. Use user1 for testing. |(/) | | |
@ -833,8 +912,17 @@ User
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : { "content" : {
"$ref" : "#/definitions/User" "application/xml" : {
"schema" : {
"$ref" : "#/components/schemas/User"
}
},
"application/json" : {
"schema" : {
"$ref" : "#/components/schemas/User"
}
}
} }
} }
{code} {code}
@ -849,7 +937,8 @@ User
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid username supplied" "description" : "Invalid username supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -863,7 +952,8 @@ User
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "User not found" "description" : "User not found",
"content" : { }
} }
{code} {code}
---- ----
@ -904,19 +994,32 @@ String
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation", "description" : "successful operation",
"schema" : {
"type" : "string"
},
"headers" : { "headers" : {
"X-Rate-Limit" : { "X-Rate-Limit" : {
"type" : "integer", "description" : "calls per hour allowed by the user",
"format" : "int32", "schema" : {
"description" : "calls per hour allowed by the user" "type" : "integer",
"format" : "int32"
}
}, },
"X-Expires-After" : { "X-Expires-After" : {
"type" : "string", "description" : "date in UTC when toekn expires",
"format" : "date-time", "schema" : {
"description" : "date in UTC when toekn expires" "type" : "string",
"format" : "date-time"
}
}
},
"content" : {
"application/xml" : {
"schema" : {
"type" : "string"
}
},
"application/json" : {
"schema" : {
"type" : "string"
}
} }
} }
} }
@ -932,7 +1035,8 @@ String
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid username/password supplied" "description" : "Invalid username/password supplied",
"content" : { }
} }
{code} {code}
---- ----
@ -966,7 +1070,8 @@ String
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "successful operation" "description" : "successful operation",
"content" : { }
} }
{code} {code}
---- ----
@ -988,7 +1093,7 @@ String
h5. Body Parameter h5. Body Parameter
||Name||Description||Required||Default||Pattern|| ||Name||Description||Required||Default||Pattern||
|body |Updated user object |(/) | | | |user |Updated user object |(/) | | |
@ -1008,7 +1113,8 @@ String
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "Invalid user supplied" "description" : "Invalid user supplied",
"content" : { }
} }
{code} {code}
*Status Code:* 404 *Status Code:* 404
@ -1022,7 +1128,8 @@ String
{code:title=Response Schema |collapse=true} {code:title=Response Schema |collapse=true}
{ {
"description" : "User not found" "description" : "User not found",
"content" : { }
} }
{code} {code}
---- ----