mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-09 03:26:09 +00:00
[JS] mark ES5 as deprecated (#6408)
* mark js es5 deprecated, remove samples, migrate samples to use oas3 * update test in pom.xml * update js samples * delete js es5 samples * update js petstore * remove openapi3 js petstore * fix tests * skip test/model/AdditionalPropertiesArray.spec.js * fix test * update doc
This commit is contained in:
@@ -43,6 +43,7 @@ class ApiClient {
|
||||
this.authentications = {
|
||||
'api_key': {type: 'apiKey', 'in': 'header', name: 'api_key'},
|
||||
'api_key_query': {type: 'apiKey', 'in': 'query', name: 'api_key_query'},
|
||||
'bearer_test': {type: 'bearer'}, // JWT
|
||||
'http_basic_test': {type: 'basic'},
|
||||
'petstore_auth': {type: 'oauth2'}
|
||||
}
|
||||
@@ -557,8 +558,41 @@ class ApiClient {
|
||||
hostSettings() {
|
||||
return [
|
||||
{
|
||||
'url': "http://petstore.swagger.io:80/v2",
|
||||
'description': "No description provided",
|
||||
'url': "http://{server}.swagger.io:{port}/v2",
|
||||
'description': "petstore server",
|
||||
'variables': {
|
||||
server: {
|
||||
'description': "No description provided",
|
||||
'default_value': "petstore",
|
||||
'enum_values': [
|
||||
"petstore",
|
||||
"qa-petstore",
|
||||
"dev-petstore"
|
||||
]
|
||||
},
|
||||
port: {
|
||||
'description': "No description provided",
|
||||
'default_value': "80",
|
||||
'enum_values': [
|
||||
"80",
|
||||
"8080"
|
||||
]
|
||||
}
|
||||
}
|
||||
},
|
||||
{
|
||||
'url': "https://localhost:8080/{version}",
|
||||
'description': "The local server",
|
||||
'variables': {
|
||||
version: {
|
||||
'description': "No description provided",
|
||||
'default_value': "v2",
|
||||
'enum_values': [
|
||||
"v1",
|
||||
"v2"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
];
|
||||
}
|
||||
|
||||
@@ -45,15 +45,15 @@ export default class AnotherFakeApi {
|
||||
/**
|
||||
* To test special tags
|
||||
* To test special tags and operation ID starting with number
|
||||
* @param {module:model/Client} body client model
|
||||
* @param {module:model/Client} client client model
|
||||
* @param {module:api/AnotherFakeApi~call123testSpecialTagsCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/Client}
|
||||
*/
|
||||
call123testSpecialTags(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling call123testSpecialTags");
|
||||
call123testSpecialTags(client, callback) {
|
||||
let postBody = client;
|
||||
// verify the required parameter 'client' is set
|
||||
if (client === undefined || client === null) {
|
||||
throw new Error("Missing the required parameter 'client' when calling call123testSpecialTags");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
|
||||
73
samples/client/petstore/javascript-es6/src/api/DefaultApi.js
Normal file
73
samples/client/petstore/javascript-es6/src/api/DefaultApi.js
Normal file
@@ -0,0 +1,73 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
|
||||
import ApiClient from "../ApiClient";
|
||||
import InlineResponseDefault from '../model/InlineResponseDefault';
|
||||
|
||||
/**
|
||||
* Default service.
|
||||
* @module api/DefaultApi
|
||||
* @version 1.0.0
|
||||
*/
|
||||
export default class DefaultApi {
|
||||
|
||||
/**
|
||||
* Constructs a new DefaultApi.
|
||||
* @alias module:api/DefaultApi
|
||||
* @class
|
||||
* @param {module:ApiClient} [apiClient] Optional API client implementation to use,
|
||||
* default to {@link module:ApiClient#instance} if unspecified.
|
||||
*/
|
||||
constructor(apiClient) {
|
||||
this.apiClient = apiClient || ApiClient.instance;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Callback function to receive the result of the fooGet operation.
|
||||
* @callback module:api/DefaultApi~fooGetCallback
|
||||
* @param {String} error Error message, if any.
|
||||
* @param {module:model/InlineResponseDefault} data The data returned by the service call.
|
||||
* @param {String} response The complete HTTP response.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @param {module:api/DefaultApi~fooGetCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/InlineResponseDefault}
|
||||
*/
|
||||
fooGet(callback) {
|
||||
let postBody = null;
|
||||
|
||||
let pathParams = {
|
||||
};
|
||||
let queryParams = {
|
||||
};
|
||||
let headerParams = {
|
||||
};
|
||||
let formParams = {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let accepts = ['application/json'];
|
||||
let returnType = InlineResponseDefault;
|
||||
return this.apiClient.callApi(
|
||||
'/foo', 'GET',
|
||||
pathParams, queryParams, headerParams, formParams, postBody,
|
||||
authNames, contentTypes, accepts, returnType, null, callback
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -15,9 +15,10 @@
|
||||
import ApiClient from "../ApiClient";
|
||||
import Client from '../model/Client';
|
||||
import FileSchemaTestClass from '../model/FileSchemaTestClass';
|
||||
import HealthCheckResult from '../model/HealthCheckResult';
|
||||
import OuterComposite from '../model/OuterComposite';
|
||||
import Pet from '../model/Pet';
|
||||
import User from '../model/User';
|
||||
import XmlItem from '../model/XmlItem';
|
||||
|
||||
/**
|
||||
* Fake service.
|
||||
@@ -39,25 +40,20 @@ export default class FakeApi {
|
||||
|
||||
|
||||
/**
|
||||
* Callback function to receive the result of the createXmlItem operation.
|
||||
* @callback module:api/FakeApi~createXmlItemCallback
|
||||
* Callback function to receive the result of the fakeHealthGet operation.
|
||||
* @callback module:api/FakeApi~fakeHealthGetCallback
|
||||
* @param {String} error Error message, if any.
|
||||
* @param data This operation does not return a value.
|
||||
* @param {module:model/HealthCheckResult} data The data returned by the service call.
|
||||
* @param {String} response The complete HTTP response.
|
||||
*/
|
||||
|
||||
/**
|
||||
* creates an XmlItem
|
||||
* this route creates an XmlItem
|
||||
* @param {module:model/XmlItem} xmlItem XmlItem Body
|
||||
* @param {module:api/FakeApi~createXmlItemCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* Health check endpoint
|
||||
* @param {module:api/FakeApi~fakeHealthGetCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/HealthCheckResult}
|
||||
*/
|
||||
createXmlItem(xmlItem, callback) {
|
||||
let postBody = xmlItem;
|
||||
// verify the required parameter 'xmlItem' is set
|
||||
if (xmlItem === undefined || xmlItem === null) {
|
||||
throw new Error("Missing the required parameter 'xmlItem' when calling createXmlItem");
|
||||
}
|
||||
fakeHealthGet(callback) {
|
||||
let postBody = null;
|
||||
|
||||
let pathParams = {
|
||||
};
|
||||
@@ -69,11 +65,57 @@ export default class FakeApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = ['application/xml', 'application/xml; charset=utf-8', 'application/xml; charset=utf-16', 'text/xml', 'text/xml; charset=utf-8', 'text/xml; charset=utf-16'];
|
||||
let contentTypes = [];
|
||||
let accepts = ['application/json'];
|
||||
let returnType = HealthCheckResult;
|
||||
return this.apiClient.callApi(
|
||||
'/fake/health', 'GET',
|
||||
pathParams, queryParams, headerParams, formParams, postBody,
|
||||
authNames, contentTypes, accepts, returnType, null, callback
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Callback function to receive the result of the fakeHttpSignatureTest operation.
|
||||
* @callback module:api/FakeApi~fakeHttpSignatureTestCallback
|
||||
* @param {String} error Error message, if any.
|
||||
* @param data This operation does not return a value.
|
||||
* @param {String} response The complete HTTP response.
|
||||
*/
|
||||
|
||||
/**
|
||||
* test http signature authentication
|
||||
* @param {module:model/Pet} pet Pet object that needs to be added to the store
|
||||
* @param {Object} opts Optional parameters
|
||||
* @param {String} opts.query1 query parameter
|
||||
* @param {String} opts.header1 header parameter
|
||||
* @param {module:api/FakeApi~fakeHttpSignatureTestCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
fakeHttpSignatureTest(pet, opts, callback) {
|
||||
opts = opts || {};
|
||||
let postBody = pet;
|
||||
// verify the required parameter 'pet' is set
|
||||
if (pet === undefined || pet === null) {
|
||||
throw new Error("Missing the required parameter 'pet' when calling fakeHttpSignatureTest");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
};
|
||||
let queryParams = {
|
||||
'query_1': opts['query1']
|
||||
};
|
||||
let headerParams = {
|
||||
'header_1': opts['header1']
|
||||
};
|
||||
let formParams = {
|
||||
};
|
||||
|
||||
let authNames = ['http_signature_test'];
|
||||
let contentTypes = ['application/json', 'application/xml'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
return this.apiClient.callApi(
|
||||
'/fake/create_xml_item', 'POST',
|
||||
'/fake/http-signature-test', 'GET',
|
||||
pathParams, queryParams, headerParams, formParams, postBody,
|
||||
authNames, contentTypes, accepts, returnType, null, callback
|
||||
);
|
||||
@@ -108,7 +150,7 @@ export default class FakeApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = ['*/*'];
|
||||
let returnType = 'Boolean';
|
||||
return this.apiClient.callApi(
|
||||
@@ -129,13 +171,13 @@ export default class FakeApi {
|
||||
/**
|
||||
* Test serialization of object with outer number type
|
||||
* @param {Object} opts Optional parameters
|
||||
* @param {module:model/OuterComposite} opts.body Input composite as post body
|
||||
* @param {module:model/OuterComposite} opts.outerComposite Input composite as post body
|
||||
* @param {module:api/FakeApi~fakeOuterCompositeSerializeCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/OuterComposite}
|
||||
*/
|
||||
fakeOuterCompositeSerialize(opts, callback) {
|
||||
opts = opts || {};
|
||||
let postBody = opts['body'];
|
||||
let postBody = opts['outerComposite'];
|
||||
|
||||
let pathParams = {
|
||||
};
|
||||
@@ -147,7 +189,7 @@ export default class FakeApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = ['*/*'];
|
||||
let returnType = OuterComposite;
|
||||
return this.apiClient.callApi(
|
||||
@@ -186,7 +228,7 @@ export default class FakeApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = ['*/*'];
|
||||
let returnType = 'Number';
|
||||
return this.apiClient.callApi(
|
||||
@@ -225,7 +267,7 @@ export default class FakeApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = ['*/*'];
|
||||
let returnType = 'String';
|
||||
return this.apiClient.callApi(
|
||||
@@ -245,14 +287,14 @@ export default class FakeApi {
|
||||
|
||||
/**
|
||||
* For this test, the body for this request much reference a schema named `File`.
|
||||
* @param {module:model/FileSchemaTestClass} body
|
||||
* @param {module:model/FileSchemaTestClass} fileSchemaTestClass
|
||||
* @param {module:api/FakeApi~testBodyWithFileSchemaCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
testBodyWithFileSchema(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling testBodyWithFileSchema");
|
||||
testBodyWithFileSchema(fileSchemaTestClass, callback) {
|
||||
let postBody = fileSchemaTestClass;
|
||||
// verify the required parameter 'fileSchemaTestClass' is set
|
||||
if (fileSchemaTestClass === undefined || fileSchemaTestClass === null) {
|
||||
throw new Error("Missing the required parameter 'fileSchemaTestClass' when calling testBodyWithFileSchema");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -285,18 +327,18 @@ export default class FakeApi {
|
||||
|
||||
/**
|
||||
* @param {String} query
|
||||
* @param {module:model/User} body
|
||||
* @param {module:model/User} user
|
||||
* @param {module:api/FakeApi~testBodyWithQueryParamsCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
testBodyWithQueryParams(query, body, callback) {
|
||||
let postBody = body;
|
||||
testBodyWithQueryParams(query, user, callback) {
|
||||
let postBody = user;
|
||||
// verify the required parameter 'query' is set
|
||||
if (query === undefined || query === null) {
|
||||
throw new Error("Missing the required parameter 'query' when calling testBodyWithQueryParams");
|
||||
}
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling testBodyWithQueryParams");
|
||||
// verify the required parameter 'user' is set
|
||||
if (user === undefined || user === null) {
|
||||
throw new Error("Missing the required parameter 'user' when calling testBodyWithQueryParams");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -331,15 +373,15 @@ export default class FakeApi {
|
||||
/**
|
||||
* To test \"client\" model
|
||||
* To test \"client\" model
|
||||
* @param {module:model/Client} body client model
|
||||
* @param {module:model/Client} client client model
|
||||
* @param {module:api/FakeApi~testClientModelCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/Client}
|
||||
*/
|
||||
testClientModel(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling testClientModel");
|
||||
testClientModel(client, callback) {
|
||||
let postBody = client;
|
||||
// verify the required parameter 'client' is set
|
||||
if (client === undefined || client === null) {
|
||||
throw new Error("Missing the required parameter 'client' when calling testClientModel");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -371,8 +413,8 @@ export default class FakeApi {
|
||||
*/
|
||||
|
||||
/**
|
||||
* Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
* Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
* Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
* Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트
|
||||
* @param {Number} _number None
|
||||
* @param {Number} _double None
|
||||
* @param {String} patternWithoutDelimiter None
|
||||
@@ -473,7 +515,7 @@ export default class FakeApi {
|
||||
let pathParams = {
|
||||
};
|
||||
let queryParams = {
|
||||
'enum_query_string_array': this.apiClient.buildCollectionParam(opts['enumQueryStringArray'], 'csv'),
|
||||
'enum_query_string_array': this.apiClient.buildCollectionParam(opts['enumQueryStringArray'], 'multi'),
|
||||
'enum_query_string': opts['enumQueryString'],
|
||||
'enum_query_integer': opts['enumQueryInteger'],
|
||||
'enum_query_double': opts['enumQueryDouble']
|
||||
@@ -549,7 +591,7 @@ export default class FakeApi {
|
||||
let formParams = {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let authNames = ['bearer_test'];
|
||||
let contentTypes = [];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
@@ -570,14 +612,14 @@ export default class FakeApi {
|
||||
|
||||
/**
|
||||
* test inline additionalProperties
|
||||
* @param {Object.<String, {String: String}>} param request body
|
||||
* @param {Object.<String, {String: String}>} requestBody request body
|
||||
* @param {module:api/FakeApi~testInlineAdditionalPropertiesCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
testInlineAdditionalProperties(param, callback) {
|
||||
let postBody = param;
|
||||
// verify the required parameter 'param' is set
|
||||
if (param === undefined || param === null) {
|
||||
throw new Error("Missing the required parameter 'param' when calling testInlineAdditionalProperties");
|
||||
testInlineAdditionalProperties(requestBody, callback) {
|
||||
let postBody = requestBody;
|
||||
// verify the required parameter 'requestBody' is set
|
||||
if (requestBody === undefined || requestBody === null) {
|
||||
throw new Error("Missing the required parameter 'requestBody' when calling testInlineAdditionalProperties");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -690,7 +732,7 @@ export default class FakeApi {
|
||||
let pathParams = {
|
||||
};
|
||||
let queryParams = {
|
||||
'pipe': this.apiClient.buildCollectionParam(pipe, 'csv'),
|
||||
'pipe': this.apiClient.buildCollectionParam(pipe, 'multi'),
|
||||
'ioutil': this.apiClient.buildCollectionParam(ioutil, 'csv'),
|
||||
'http': this.apiClient.buildCollectionParam(http, 'space'),
|
||||
'url': this.apiClient.buildCollectionParam(url, 'csv'),
|
||||
|
||||
@@ -45,15 +45,15 @@ export default class FakeClassnameTags123Api {
|
||||
/**
|
||||
* To test class name in snake case
|
||||
* To test class name in snake case
|
||||
* @param {module:model/Client} body client model
|
||||
* @param {module:model/Client} client client model
|
||||
* @param {module:api/FakeClassnameTags123Api~testClassnameCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/Client}
|
||||
*/
|
||||
testClassname(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling testClassname");
|
||||
testClassname(client, callback) {
|
||||
let postBody = client;
|
||||
// verify the required parameter 'client' is set
|
||||
if (client === undefined || client === null) {
|
||||
throw new Error("Missing the required parameter 'client' when calling testClassname");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
|
||||
@@ -45,14 +45,15 @@ export default class PetApi {
|
||||
|
||||
/**
|
||||
* Add a new pet to the store
|
||||
* @param {module:model/Pet} body Pet object that needs to be added to the store
|
||||
* @param {module:model/Pet} pet Pet object that needs to be added to the store
|
||||
* @param {module:api/PetApi~addPetCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
addPet(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling addPet");
|
||||
addPet(pet, opts, callback) {
|
||||
opts = opts || {};
|
||||
let postBody = pet;
|
||||
// verify the required parameter 'pet' is set
|
||||
if (pet === undefined || pet === null) {
|
||||
throw new Error("Missing the required parameter 'pet' when calling addPet");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -68,10 +69,19 @@ export default class PetApi {
|
||||
let contentTypes = ['application/json', 'application/xml'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
let basePaths = ['http://petstore.swagger.io/v2', 'http://path-server-test.petstore.local/v2'];
|
||||
let basePath = basePaths[0]; // by default use the first one in "servers" defined in OpenAPI
|
||||
if (typeof opts['_base_path_index'] !== 'undefined') {
|
||||
if (opts['_base_path_index'] >= basePaths.length || opts['_base_path_index'] < 0) {
|
||||
throw new Error("Invalid index " + opts['_base_path_index'] + " when selecting the host settings. Must be less than " + basePaths.length);
|
||||
}
|
||||
basePath = basePaths[opts['_base_path_index']];
|
||||
}
|
||||
|
||||
return this.apiClient.callApi(
|
||||
'/pet', 'POST',
|
||||
pathParams, queryParams, headerParams, formParams, postBody,
|
||||
authNames, contentTypes, accepts, returnType, null, callback
|
||||
authNames, contentTypes, accepts, returnType, basePath, callback
|
||||
);
|
||||
}
|
||||
|
||||
@@ -259,14 +269,15 @@ export default class PetApi {
|
||||
|
||||
/**
|
||||
* Update an existing pet
|
||||
* @param {module:model/Pet} body Pet object that needs to be added to the store
|
||||
* @param {module:model/Pet} pet Pet object that needs to be added to the store
|
||||
* @param {module:api/PetApi~updatePetCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
updatePet(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling updatePet");
|
||||
updatePet(pet, opts, callback) {
|
||||
opts = opts || {};
|
||||
let postBody = pet;
|
||||
// verify the required parameter 'pet' is set
|
||||
if (pet === undefined || pet === null) {
|
||||
throw new Error("Missing the required parameter 'pet' when calling updatePet");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -282,10 +293,19 @@ export default class PetApi {
|
||||
let contentTypes = ['application/json', 'application/xml'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
let basePaths = ['http://petstore.swagger.io/v2', 'http://path-server-test.petstore.local/v2'];
|
||||
let basePath = basePaths[0]; // by default use the first one in "servers" defined in OpenAPI
|
||||
if (typeof opts['_base_path_index'] !== 'undefined') {
|
||||
if (opts['_base_path_index'] >= basePaths.length || opts['_base_path_index'] < 0) {
|
||||
throw new Error("Invalid index " + opts['_base_path_index'] + " when selecting the host settings. Must be less than " + basePaths.length);
|
||||
}
|
||||
basePath = basePaths[opts['_base_path_index']];
|
||||
}
|
||||
|
||||
return this.apiClient.callApi(
|
||||
'/pet', 'PUT',
|
||||
pathParams, queryParams, headerParams, formParams, postBody,
|
||||
authNames, contentTypes, accepts, returnType, null, callback
|
||||
authNames, contentTypes, accepts, returnType, basePath, callback
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
@@ -166,15 +166,15 @@ export default class StoreApi {
|
||||
|
||||
/**
|
||||
* Place an order for a pet
|
||||
* @param {module:model/Order} body order placed for purchasing the pet
|
||||
* @param {module:model/Order} order order placed for purchasing the pet
|
||||
* @param {module:api/StoreApi~placeOrderCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
* data is of type: {@link module:model/Order}
|
||||
*/
|
||||
placeOrder(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling placeOrder");
|
||||
placeOrder(order, callback) {
|
||||
let postBody = order;
|
||||
// verify the required parameter 'order' is set
|
||||
if (order === undefined || order === null) {
|
||||
throw new Error("Missing the required parameter 'order' when calling placeOrder");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -187,7 +187,7 @@ export default class StoreApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = ['application/xml', 'application/json'];
|
||||
let returnType = Order;
|
||||
return this.apiClient.callApi(
|
||||
|
||||
@@ -45,14 +45,14 @@ export default class UserApi {
|
||||
/**
|
||||
* Create user
|
||||
* This can only be done by the logged in user.
|
||||
* @param {module:model/User} body Created user object
|
||||
* @param {module:model/User} user Created user object
|
||||
* @param {module:api/UserApi~createUserCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
createUser(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling createUser");
|
||||
createUser(user, callback) {
|
||||
let postBody = user;
|
||||
// verify the required parameter 'user' is set
|
||||
if (user === undefined || user === null) {
|
||||
throw new Error("Missing the required parameter 'user' when calling createUser");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -65,7 +65,7 @@ export default class UserApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
return this.apiClient.callApi(
|
||||
@@ -85,14 +85,14 @@ export default class UserApi {
|
||||
|
||||
/**
|
||||
* Creates list of users with given input array
|
||||
* @param {Array.<module:model/User>} body List of user object
|
||||
* @param {Array.<module:model/User>} user List of user object
|
||||
* @param {module:api/UserApi~createUsersWithArrayInputCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
createUsersWithArrayInput(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling createUsersWithArrayInput");
|
||||
createUsersWithArrayInput(user, callback) {
|
||||
let postBody = user;
|
||||
// verify the required parameter 'user' is set
|
||||
if (user === undefined || user === null) {
|
||||
throw new Error("Missing the required parameter 'user' when calling createUsersWithArrayInput");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -105,7 +105,7 @@ export default class UserApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
return this.apiClient.callApi(
|
||||
@@ -125,14 +125,14 @@ export default class UserApi {
|
||||
|
||||
/**
|
||||
* Creates list of users with given input array
|
||||
* @param {Array.<module:model/User>} body List of user object
|
||||
* @param {Array.<module:model/User>} user List of user object
|
||||
* @param {module:api/UserApi~createUsersWithListInputCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
createUsersWithListInput(body, callback) {
|
||||
let postBody = body;
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling createUsersWithListInput");
|
||||
createUsersWithListInput(user, callback) {
|
||||
let postBody = user;
|
||||
// verify the required parameter 'user' is set
|
||||
if (user === undefined || user === null) {
|
||||
throw new Error("Missing the required parameter 'user' when calling createUsersWithListInput");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -145,7 +145,7 @@ export default class UserApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
return this.apiClient.callApi(
|
||||
@@ -334,18 +334,18 @@ export default class UserApi {
|
||||
* Updated user
|
||||
* This can only be done by the logged in user.
|
||||
* @param {String} username name that need to be deleted
|
||||
* @param {module:model/User} body Updated user object
|
||||
* @param {module:model/User} user Updated user object
|
||||
* @param {module:api/UserApi~updateUserCallback} callback The callback function, accepting three arguments: error, data, response
|
||||
*/
|
||||
updateUser(username, body, callback) {
|
||||
let postBody = body;
|
||||
updateUser(username, user, callback) {
|
||||
let postBody = user;
|
||||
// verify the required parameter 'username' is set
|
||||
if (username === undefined || username === null) {
|
||||
throw new Error("Missing the required parameter 'username' when calling updateUser");
|
||||
}
|
||||
// verify the required parameter 'body' is set
|
||||
if (body === undefined || body === null) {
|
||||
throw new Error("Missing the required parameter 'body' when calling updateUser");
|
||||
// verify the required parameter 'user' is set
|
||||
if (user === undefined || user === null) {
|
||||
throw new Error("Missing the required parameter 'user' when calling updateUser");
|
||||
}
|
||||
|
||||
let pathParams = {
|
||||
@@ -359,7 +359,7 @@ export default class UserApi {
|
||||
};
|
||||
|
||||
let authNames = [];
|
||||
let contentTypes = [];
|
||||
let contentTypes = ['application/json'];
|
||||
let accepts = [];
|
||||
let returnType = null;
|
||||
return this.apiClient.callApi(
|
||||
|
||||
@@ -13,21 +13,12 @@
|
||||
|
||||
|
||||
import ApiClient from './ApiClient';
|
||||
import AdditionalPropertiesAnyType from './model/AdditionalPropertiesAnyType';
|
||||
import AdditionalPropertiesArray from './model/AdditionalPropertiesArray';
|
||||
import AdditionalPropertiesBoolean from './model/AdditionalPropertiesBoolean';
|
||||
import AdditionalPropertiesClass from './model/AdditionalPropertiesClass';
|
||||
import AdditionalPropertiesInteger from './model/AdditionalPropertiesInteger';
|
||||
import AdditionalPropertiesNumber from './model/AdditionalPropertiesNumber';
|
||||
import AdditionalPropertiesObject from './model/AdditionalPropertiesObject';
|
||||
import AdditionalPropertiesString from './model/AdditionalPropertiesString';
|
||||
import Animal from './model/Animal';
|
||||
import ApiResponse from './model/ApiResponse';
|
||||
import ArrayOfArrayOfNumberOnly from './model/ArrayOfArrayOfNumberOnly';
|
||||
import ArrayOfNumberOnly from './model/ArrayOfNumberOnly';
|
||||
import ArrayTest from './model/ArrayTest';
|
||||
import BigCat from './model/BigCat';
|
||||
import BigCatAllOf from './model/BigCatAllOf';
|
||||
import Capitalization from './model/Capitalization';
|
||||
import Cat from './model/Cat';
|
||||
import CatAllOf from './model/CatAllOf';
|
||||
@@ -41,27 +32,38 @@ import EnumClass from './model/EnumClass';
|
||||
import EnumTest from './model/EnumTest';
|
||||
import File from './model/File';
|
||||
import FileSchemaTestClass from './model/FileSchemaTestClass';
|
||||
import Foo from './model/Foo';
|
||||
import FormatTest from './model/FormatTest';
|
||||
import HasOnlyReadOnly from './model/HasOnlyReadOnly';
|
||||
import HealthCheckResult from './model/HealthCheckResult';
|
||||
import InlineObject from './model/InlineObject';
|
||||
import InlineObject1 from './model/InlineObject1';
|
||||
import InlineObject2 from './model/InlineObject2';
|
||||
import InlineObject3 from './model/InlineObject3';
|
||||
import InlineObject4 from './model/InlineObject4';
|
||||
import InlineObject5 from './model/InlineObject5';
|
||||
import InlineResponseDefault from './model/InlineResponseDefault';
|
||||
import List from './model/List';
|
||||
import MapTest from './model/MapTest';
|
||||
import MixedPropertiesAndAdditionalPropertiesClass from './model/MixedPropertiesAndAdditionalPropertiesClass';
|
||||
import Model200Response from './model/Model200Response';
|
||||
import ModelReturn from './model/ModelReturn';
|
||||
import Name from './model/Name';
|
||||
import NullableClass from './model/NullableClass';
|
||||
import NumberOnly from './model/NumberOnly';
|
||||
import Order from './model/Order';
|
||||
import OuterComposite from './model/OuterComposite';
|
||||
import OuterEnum from './model/OuterEnum';
|
||||
import OuterEnumDefaultValue from './model/OuterEnumDefaultValue';
|
||||
import OuterEnumInteger from './model/OuterEnumInteger';
|
||||
import OuterEnumIntegerDefaultValue from './model/OuterEnumIntegerDefaultValue';
|
||||
import Pet from './model/Pet';
|
||||
import ReadOnlyFirst from './model/ReadOnlyFirst';
|
||||
import SpecialModelName from './model/SpecialModelName';
|
||||
import Tag from './model/Tag';
|
||||
import TypeHolderDefault from './model/TypeHolderDefault';
|
||||
import TypeHolderExample from './model/TypeHolderExample';
|
||||
import User from './model/User';
|
||||
import XmlItem from './model/XmlItem';
|
||||
import AnotherFakeApi from './api/AnotherFakeApi';
|
||||
import DefaultApi from './api/DefaultApi';
|
||||
import FakeApi from './api/FakeApi';
|
||||
import FakeClassnameTags123Api from './api/FakeClassnameTags123Api';
|
||||
import PetApi from './api/PetApi';
|
||||
@@ -107,54 +109,12 @@ export {
|
||||
*/
|
||||
ApiClient,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesAnyType model constructor.
|
||||
* @property {module:model/AdditionalPropertiesAnyType}
|
||||
*/
|
||||
AdditionalPropertiesAnyType,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesArray model constructor.
|
||||
* @property {module:model/AdditionalPropertiesArray}
|
||||
*/
|
||||
AdditionalPropertiesArray,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesBoolean model constructor.
|
||||
* @property {module:model/AdditionalPropertiesBoolean}
|
||||
*/
|
||||
AdditionalPropertiesBoolean,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesClass model constructor.
|
||||
* @property {module:model/AdditionalPropertiesClass}
|
||||
*/
|
||||
AdditionalPropertiesClass,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesInteger model constructor.
|
||||
* @property {module:model/AdditionalPropertiesInteger}
|
||||
*/
|
||||
AdditionalPropertiesInteger,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesNumber model constructor.
|
||||
* @property {module:model/AdditionalPropertiesNumber}
|
||||
*/
|
||||
AdditionalPropertiesNumber,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesObject model constructor.
|
||||
* @property {module:model/AdditionalPropertiesObject}
|
||||
*/
|
||||
AdditionalPropertiesObject,
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesString model constructor.
|
||||
* @property {module:model/AdditionalPropertiesString}
|
||||
*/
|
||||
AdditionalPropertiesString,
|
||||
|
||||
/**
|
||||
* The Animal model constructor.
|
||||
* @property {module:model/Animal}
|
||||
@@ -185,18 +145,6 @@ export {
|
||||
*/
|
||||
ArrayTest,
|
||||
|
||||
/**
|
||||
* The BigCat model constructor.
|
||||
* @property {module:model/BigCat}
|
||||
*/
|
||||
BigCat,
|
||||
|
||||
/**
|
||||
* The BigCatAllOf model constructor.
|
||||
* @property {module:model/BigCatAllOf}
|
||||
*/
|
||||
BigCatAllOf,
|
||||
|
||||
/**
|
||||
* The Capitalization model constructor.
|
||||
* @property {module:model/Capitalization}
|
||||
@@ -275,6 +223,12 @@ export {
|
||||
*/
|
||||
FileSchemaTestClass,
|
||||
|
||||
/**
|
||||
* The Foo model constructor.
|
||||
* @property {module:model/Foo}
|
||||
*/
|
||||
Foo,
|
||||
|
||||
/**
|
||||
* The FormatTest model constructor.
|
||||
* @property {module:model/FormatTest}
|
||||
@@ -287,6 +241,54 @@ export {
|
||||
*/
|
||||
HasOnlyReadOnly,
|
||||
|
||||
/**
|
||||
* The HealthCheckResult model constructor.
|
||||
* @property {module:model/HealthCheckResult}
|
||||
*/
|
||||
HealthCheckResult,
|
||||
|
||||
/**
|
||||
* The InlineObject model constructor.
|
||||
* @property {module:model/InlineObject}
|
||||
*/
|
||||
InlineObject,
|
||||
|
||||
/**
|
||||
* The InlineObject1 model constructor.
|
||||
* @property {module:model/InlineObject1}
|
||||
*/
|
||||
InlineObject1,
|
||||
|
||||
/**
|
||||
* The InlineObject2 model constructor.
|
||||
* @property {module:model/InlineObject2}
|
||||
*/
|
||||
InlineObject2,
|
||||
|
||||
/**
|
||||
* The InlineObject3 model constructor.
|
||||
* @property {module:model/InlineObject3}
|
||||
*/
|
||||
InlineObject3,
|
||||
|
||||
/**
|
||||
* The InlineObject4 model constructor.
|
||||
* @property {module:model/InlineObject4}
|
||||
*/
|
||||
InlineObject4,
|
||||
|
||||
/**
|
||||
* The InlineObject5 model constructor.
|
||||
* @property {module:model/InlineObject5}
|
||||
*/
|
||||
InlineObject5,
|
||||
|
||||
/**
|
||||
* The InlineResponseDefault model constructor.
|
||||
* @property {module:model/InlineResponseDefault}
|
||||
*/
|
||||
InlineResponseDefault,
|
||||
|
||||
/**
|
||||
* The List model constructor.
|
||||
* @property {module:model/List}
|
||||
@@ -323,6 +325,12 @@ export {
|
||||
*/
|
||||
Name,
|
||||
|
||||
/**
|
||||
* The NullableClass model constructor.
|
||||
* @property {module:model/NullableClass}
|
||||
*/
|
||||
NullableClass,
|
||||
|
||||
/**
|
||||
* The NumberOnly model constructor.
|
||||
* @property {module:model/NumberOnly}
|
||||
@@ -347,6 +355,24 @@ export {
|
||||
*/
|
||||
OuterEnum,
|
||||
|
||||
/**
|
||||
* The OuterEnumDefaultValue model constructor.
|
||||
* @property {module:model/OuterEnumDefaultValue}
|
||||
*/
|
||||
OuterEnumDefaultValue,
|
||||
|
||||
/**
|
||||
* The OuterEnumInteger model constructor.
|
||||
* @property {module:model/OuterEnumInteger}
|
||||
*/
|
||||
OuterEnumInteger,
|
||||
|
||||
/**
|
||||
* The OuterEnumIntegerDefaultValue model constructor.
|
||||
* @property {module:model/OuterEnumIntegerDefaultValue}
|
||||
*/
|
||||
OuterEnumIntegerDefaultValue,
|
||||
|
||||
/**
|
||||
* The Pet model constructor.
|
||||
* @property {module:model/Pet}
|
||||
@@ -371,36 +397,24 @@ export {
|
||||
*/
|
||||
Tag,
|
||||
|
||||
/**
|
||||
* The TypeHolderDefault model constructor.
|
||||
* @property {module:model/TypeHolderDefault}
|
||||
*/
|
||||
TypeHolderDefault,
|
||||
|
||||
/**
|
||||
* The TypeHolderExample model constructor.
|
||||
* @property {module:model/TypeHolderExample}
|
||||
*/
|
||||
TypeHolderExample,
|
||||
|
||||
/**
|
||||
* The User model constructor.
|
||||
* @property {module:model/User}
|
||||
*/
|
||||
User,
|
||||
|
||||
/**
|
||||
* The XmlItem model constructor.
|
||||
* @property {module:model/XmlItem}
|
||||
*/
|
||||
XmlItem,
|
||||
|
||||
/**
|
||||
* The AnotherFakeApi service constructor.
|
||||
* @property {module:api/AnotherFakeApi}
|
||||
*/
|
||||
AnotherFakeApi,
|
||||
|
||||
/**
|
||||
* The DefaultApi service constructor.
|
||||
* @property {module:api/DefaultApi}
|
||||
*/
|
||||
DefaultApi,
|
||||
|
||||
/**
|
||||
* The FakeApi service constructor.
|
||||
* @property {module:api/FakeApi}
|
||||
|
||||
@@ -47,38 +47,11 @@ class AdditionalPropertiesClass {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesClass();
|
||||
|
||||
if (data.hasOwnProperty('map_string')) {
|
||||
obj['map_string'] = ApiClient.convertToType(data['map_string'], {'String': 'String'});
|
||||
if (data.hasOwnProperty('map_property')) {
|
||||
obj['map_property'] = ApiClient.convertToType(data['map_property'], {'String': 'String'});
|
||||
}
|
||||
if (data.hasOwnProperty('map_number')) {
|
||||
obj['map_number'] = ApiClient.convertToType(data['map_number'], {'String': 'Number'});
|
||||
}
|
||||
if (data.hasOwnProperty('map_integer')) {
|
||||
obj['map_integer'] = ApiClient.convertToType(data['map_integer'], {'String': 'Number'});
|
||||
}
|
||||
if (data.hasOwnProperty('map_boolean')) {
|
||||
obj['map_boolean'] = ApiClient.convertToType(data['map_boolean'], {'String': 'Boolean'});
|
||||
}
|
||||
if (data.hasOwnProperty('map_array_integer')) {
|
||||
obj['map_array_integer'] = ApiClient.convertToType(data['map_array_integer'], {'String': ['Number']});
|
||||
}
|
||||
if (data.hasOwnProperty('map_array_anytype')) {
|
||||
obj['map_array_anytype'] = ApiClient.convertToType(data['map_array_anytype'], {'String': [Object]});
|
||||
}
|
||||
if (data.hasOwnProperty('map_map_string')) {
|
||||
obj['map_map_string'] = ApiClient.convertToType(data['map_map_string'], {'String': {'String': 'String'}});
|
||||
}
|
||||
if (data.hasOwnProperty('map_map_anytype')) {
|
||||
obj['map_map_anytype'] = ApiClient.convertToType(data['map_map_anytype'], {'String': {'String': Object}});
|
||||
}
|
||||
if (data.hasOwnProperty('anytype_1')) {
|
||||
obj['anytype_1'] = ApiClient.convertToType(data['anytype_1'], Object);
|
||||
}
|
||||
if (data.hasOwnProperty('anytype_2')) {
|
||||
obj['anytype_2'] = ApiClient.convertToType(data['anytype_2'], Object);
|
||||
}
|
||||
if (data.hasOwnProperty('anytype_3')) {
|
||||
obj['anytype_3'] = ApiClient.convertToType(data['anytype_3'], Object);
|
||||
if (data.hasOwnProperty('map_of_map_property')) {
|
||||
obj['map_of_map_property'] = ApiClient.convertToType(data['map_of_map_property'], {'String': {'String': 'String'}});
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -88,59 +61,14 @@ class AdditionalPropertiesClass {
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {Object.<String, String>} map_string
|
||||
* @member {Object.<String, String>} map_property
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_string'] = undefined;
|
||||
AdditionalPropertiesClass.prototype['map_property'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Number>} map_number
|
||||
* @member {Object.<String, Object.<String, String>>} map_of_map_property
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Number>} map_integer
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Boolean>} map_boolean
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Array.<Number>>} map_array_integer
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_array_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Array.<Object>>} map_array_anytype
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_array_anytype'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Object.<String, String>>} map_map_string
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_map_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Object.<String, Object>>} map_map_anytype
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['map_map_anytype'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object} anytype_1
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['anytype_1'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object} anytype_2
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['anytype_2'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object} anytype_3
|
||||
*/
|
||||
AdditionalPropertiesClass.prototype['anytype_3'] = undefined;
|
||||
AdditionalPropertiesClass.prototype['map_of_map_property'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -1,75 +0,0 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesInteger model module.
|
||||
* @module model/AdditionalPropertiesInteger
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesInteger {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesInteger</code>.
|
||||
* @alias module:model/AdditionalPropertiesInteger
|
||||
* @extends Object
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesInteger.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesInteger</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesInteger} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesInteger} The populated <code>AdditionalPropertiesInteger</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesInteger();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Number');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
*/
|
||||
AdditionalPropertiesInteger.prototype['name'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesInteger;
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
import Animal from './Animal';
|
||||
|
||||
/**
|
||||
* The AnimalFarm model module.
|
||||
* @module model/AnimalFarm
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AnimalFarm extends Array {
|
||||
/**
|
||||
* Constructs a new <code>AnimalFarm</code>.
|
||||
* @alias module:model/AnimalFarm
|
||||
* @extends Array
|
||||
*/
|
||||
constructor() {
|
||||
super();
|
||||
|
||||
|
||||
AnimalFarm.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AnimalFarm</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AnimalFarm} obj Optional instance to populate.
|
||||
* @return {module:model/AnimalFarm} The populated <code>AnimalFarm</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AnimalFarm();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Animal');
|
||||
|
||||
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AnimalFarm;
|
||||
|
||||
@@ -1,132 +0,0 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
import BigCatAllOf from './BigCatAllOf';
|
||||
import Cat from './Cat';
|
||||
|
||||
/**
|
||||
* The BigCat model module.
|
||||
* @module model/BigCat
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class BigCat {
|
||||
/**
|
||||
* Constructs a new <code>BigCat</code>.
|
||||
* @alias module:model/BigCat
|
||||
* @extends module:model/Cat
|
||||
* @implements module:model/Cat
|
||||
* @implements module:model/BigCatAllOf
|
||||
* @param className {String}
|
||||
*/
|
||||
constructor(className) {
|
||||
Cat.initialize(this, className);BigCatAllOf.initialize(this);
|
||||
BigCat.initialize(this, className);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj, className) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>BigCat</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/BigCat} obj Optional instance to populate.
|
||||
* @return {module:model/BigCat} The populated <code>BigCat</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new BigCat();
|
||||
Cat.constructFromObject(data, obj);
|
||||
Cat.constructFromObject(data, obj);
|
||||
BigCatAllOf.constructFromObject(data, obj);
|
||||
|
||||
if (data.hasOwnProperty('kind')) {
|
||||
obj['kind'] = ApiClient.convertToType(data['kind'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {module:model/BigCat.KindEnum} kind
|
||||
*/
|
||||
BigCat.prototype['kind'] = undefined;
|
||||
|
||||
|
||||
// Implement Cat interface:
|
||||
/**
|
||||
* @member {String} className
|
||||
*/
|
||||
Cat.prototype['className'] = undefined;
|
||||
/**
|
||||
* @member {String} color
|
||||
* @default 'red'
|
||||
*/
|
||||
Cat.prototype['color'] = 'red';
|
||||
/**
|
||||
* @member {Boolean} declawed
|
||||
*/
|
||||
Cat.prototype['declawed'] = undefined;
|
||||
// Implement BigCatAllOf interface:
|
||||
/**
|
||||
* @member {module:model/BigCatAllOf.KindEnum} kind
|
||||
*/
|
||||
BigCatAllOf.prototype['kind'] = undefined;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>kind</code> property.
|
||||
* @enum {String}
|
||||
* @readonly
|
||||
*/
|
||||
BigCat['KindEnum'] = {
|
||||
|
||||
/**
|
||||
* value: "lions"
|
||||
* @const
|
||||
*/
|
||||
"lions": "lions",
|
||||
|
||||
/**
|
||||
* value: "tigers"
|
||||
* @const
|
||||
*/
|
||||
"tigers": "tigers",
|
||||
|
||||
/**
|
||||
* value: "leopards"
|
||||
* @const
|
||||
*/
|
||||
"leopards": "leopards",
|
||||
|
||||
/**
|
||||
* value: "jaguars"
|
||||
* @const
|
||||
*/
|
||||
"jaguars": "jaguars"
|
||||
};
|
||||
|
||||
|
||||
|
||||
export default BigCat;
|
||||
|
||||
@@ -1,104 +0,0 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The BigCatAllOf model module.
|
||||
* @module model/BigCatAllOf
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class BigCatAllOf {
|
||||
/**
|
||||
* Constructs a new <code>BigCatAllOf</code>.
|
||||
* @alias module:model/BigCatAllOf
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
BigCatAllOf.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>BigCatAllOf</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/BigCatAllOf} obj Optional instance to populate.
|
||||
* @return {module:model/BigCatAllOf} The populated <code>BigCatAllOf</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new BigCatAllOf();
|
||||
|
||||
if (data.hasOwnProperty('kind')) {
|
||||
obj['kind'] = ApiClient.convertToType(data['kind'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {module:model/BigCatAllOf.KindEnum} kind
|
||||
*/
|
||||
BigCatAllOf.prototype['kind'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>kind</code> property.
|
||||
* @enum {String}
|
||||
* @readonly
|
||||
*/
|
||||
BigCatAllOf['KindEnum'] = {
|
||||
|
||||
/**
|
||||
* value: "lions"
|
||||
* @const
|
||||
*/
|
||||
"lions": "lions",
|
||||
|
||||
/**
|
||||
* value: "tigers"
|
||||
* @const
|
||||
*/
|
||||
"tigers": "tigers",
|
||||
|
||||
/**
|
||||
* value: "leopards"
|
||||
* @const
|
||||
*/
|
||||
"leopards": "leopards",
|
||||
|
||||
/**
|
||||
* value: "jaguars"
|
||||
* @const
|
||||
*/
|
||||
"jaguars": "jaguars"
|
||||
};
|
||||
|
||||
|
||||
|
||||
export default BigCatAllOf;
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
import OuterEnum from './OuterEnum';
|
||||
import OuterEnumDefaultValue from './OuterEnumDefaultValue';
|
||||
import OuterEnumInteger from './OuterEnumInteger';
|
||||
import OuterEnumIntegerDefaultValue from './OuterEnumIntegerDefaultValue';
|
||||
|
||||
/**
|
||||
* The EnumTest model module.
|
||||
@@ -65,6 +68,15 @@ class EnumTest {
|
||||
if (data.hasOwnProperty('outerEnum')) {
|
||||
obj['outerEnum'] = OuterEnum.constructFromObject(data['outerEnum']);
|
||||
}
|
||||
if (data.hasOwnProperty('outerEnumInteger')) {
|
||||
obj['outerEnumInteger'] = OuterEnumInteger.constructFromObject(data['outerEnumInteger']);
|
||||
}
|
||||
if (data.hasOwnProperty('outerEnumDefaultValue')) {
|
||||
obj['outerEnumDefaultValue'] = OuterEnumDefaultValue.constructFromObject(data['outerEnumDefaultValue']);
|
||||
}
|
||||
if (data.hasOwnProperty('outerEnumIntegerDefaultValue')) {
|
||||
obj['outerEnumIntegerDefaultValue'] = OuterEnumIntegerDefaultValue.constructFromObject(data['outerEnumIntegerDefaultValue']);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
@@ -97,6 +109,21 @@ EnumTest.prototype['enum_number'] = undefined;
|
||||
*/
|
||||
EnumTest.prototype['outerEnum'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {module:model/OuterEnumInteger} outerEnumInteger
|
||||
*/
|
||||
EnumTest.prototype['outerEnumInteger'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {module:model/OuterEnumDefaultValue} outerEnumDefaultValue
|
||||
*/
|
||||
EnumTest.prototype['outerEnumDefaultValue'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {module:model/OuterEnumIntegerDefaultValue} outerEnumIntegerDefaultValue
|
||||
*/
|
||||
EnumTest.prototype['outerEnumIntegerDefaultValue'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -14,19 +14,18 @@
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesArray model module.
|
||||
* @module model/AdditionalPropertiesArray
|
||||
* The Foo model module.
|
||||
* @module model/Foo
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesArray {
|
||||
class Foo {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesArray</code>.
|
||||
* @alias module:model/AdditionalPropertiesArray
|
||||
* @extends Object
|
||||
* Constructs a new <code>Foo</code>.
|
||||
* @alias module:model/Foo
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesArray.initialize(this);
|
||||
Foo.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,21 +37,18 @@ class AdditionalPropertiesArray {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesArray</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>Foo</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesArray} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesArray} The populated <code>AdditionalPropertiesArray</code> instance.
|
||||
* @param {module:model/Foo} obj Optional instance to populate.
|
||||
* @return {module:model/Foo} The populated <code>Foo</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesArray();
|
||||
obj = obj || new Foo();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Array');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
if (data.hasOwnProperty('bar')) {
|
||||
obj['bar'] = ApiClient.convertToType(data['bar'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -62,14 +58,15 @@ class AdditionalPropertiesArray {
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
* @member {String} bar
|
||||
* @default 'bar'
|
||||
*/
|
||||
AdditionalPropertiesArray.prototype['name'] = undefined;
|
||||
Foo.prototype['bar'] = 'bar';
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesArray;
|
||||
export default Foo;
|
||||
|
||||
@@ -94,8 +94,11 @@ class FormatTest {
|
||||
if (data.hasOwnProperty('password')) {
|
||||
obj['password'] = ApiClient.convertToType(data['password'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('BigDecimal')) {
|
||||
obj['BigDecimal'] = ApiClient.convertToType(data['BigDecimal'], 'Number');
|
||||
if (data.hasOwnProperty('pattern_with_digits')) {
|
||||
obj['pattern_with_digits'] = ApiClient.convertToType(data['pattern_with_digits'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('pattern_with_digits_and_delimiter')) {
|
||||
obj['pattern_with_digits_and_delimiter'] = ApiClient.convertToType(data['pattern_with_digits_and_delimiter'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -170,9 +173,16 @@ FormatTest.prototype['uuid'] = undefined;
|
||||
FormatTest.prototype['password'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} BigDecimal
|
||||
* A string that is a 10 digit number. Can have leading zeros.
|
||||
* @member {String} pattern_with_digits
|
||||
*/
|
||||
FormatTest.prototype['BigDecimal'] = undefined;
|
||||
FormatTest.prototype['pattern_with_digits'] = undefined;
|
||||
|
||||
/**
|
||||
* A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01.
|
||||
* @member {String} pattern_with_digits_and_delimiter
|
||||
*/
|
||||
FormatTest.prototype['pattern_with_digits_and_delimiter'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -14,19 +14,19 @@
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesNumber model module.
|
||||
* @module model/AdditionalPropertiesNumber
|
||||
* The HealthCheckResult model module.
|
||||
* @module model/HealthCheckResult
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesNumber {
|
||||
class HealthCheckResult {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesNumber</code>.
|
||||
* @alias module:model/AdditionalPropertiesNumber
|
||||
* @extends Object
|
||||
* Constructs a new <code>HealthCheckResult</code>.
|
||||
* Just a string to inform instance is up and running. Make it nullable in hope to get it as pointer in generated model.
|
||||
* @alias module:model/HealthCheckResult
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesNumber.initialize(this);
|
||||
HealthCheckResult.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,21 +38,18 @@ class AdditionalPropertiesNumber {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesNumber</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>HealthCheckResult</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesNumber} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesNumber} The populated <code>AdditionalPropertiesNumber</code> instance.
|
||||
* @param {module:model/HealthCheckResult} obj Optional instance to populate.
|
||||
* @return {module:model/HealthCheckResult} The populated <code>HealthCheckResult</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesNumber();
|
||||
obj = obj || new HealthCheckResult();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Number');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
if (data.hasOwnProperty('NullableMessage')) {
|
||||
obj['NullableMessage'] = ApiClient.convertToType(data['NullableMessage'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -62,14 +59,14 @@ class AdditionalPropertiesNumber {
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
* @member {String} NullableMessage
|
||||
*/
|
||||
AdditionalPropertiesNumber.prototype['name'] = undefined;
|
||||
HealthCheckResult.prototype['NullableMessage'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesNumber;
|
||||
export default HealthCheckResult;
|
||||
|
||||
@@ -14,19 +14,18 @@
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesObject model module.
|
||||
* @module model/AdditionalPropertiesObject
|
||||
* The InlineObject model module.
|
||||
* @module model/InlineObject
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesObject {
|
||||
class InlineObject {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesObject</code>.
|
||||
* @alias module:model/AdditionalPropertiesObject
|
||||
* @extends Object
|
||||
* Constructs a new <code>InlineObject</code>.
|
||||
* @alias module:model/InlineObject
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesObject.initialize(this);
|
||||
InlineObject.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,22 +37,22 @@ class AdditionalPropertiesObject {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesObject</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>InlineObject</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesObject} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesObject} The populated <code>AdditionalPropertiesObject</code> instance.
|
||||
* @param {module:model/InlineObject} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject} The populated <code>InlineObject</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesObject();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Object');
|
||||
|
||||
obj = obj || new InlineObject();
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('status')) {
|
||||
obj['status'] = ApiClient.convertToType(data['status'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
@@ -62,14 +61,21 @@ class AdditionalPropertiesObject {
|
||||
}
|
||||
|
||||
/**
|
||||
* Updated name of the pet
|
||||
* @member {String} name
|
||||
*/
|
||||
AdditionalPropertiesObject.prototype['name'] = undefined;
|
||||
InlineObject.prototype['name'] = undefined;
|
||||
|
||||
/**
|
||||
* Updated status of the pet
|
||||
* @member {String} status
|
||||
*/
|
||||
InlineObject.prototype['status'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesObject;
|
||||
export default InlineObject;
|
||||
|
||||
@@ -14,19 +14,18 @@
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesAnyType model module.
|
||||
* @module model/AdditionalPropertiesAnyType
|
||||
* The InlineObject1 model module.
|
||||
* @module model/InlineObject1
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesAnyType {
|
||||
class InlineObject1 {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesAnyType</code>.
|
||||
* @alias module:model/AdditionalPropertiesAnyType
|
||||
* @extends Object
|
||||
* Constructs a new <code>InlineObject1</code>.
|
||||
* @alias module:model/InlineObject1
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesAnyType.initialize(this);
|
||||
InlineObject1.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,21 +37,21 @@ class AdditionalPropertiesAnyType {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesAnyType</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>InlineObject1</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesAnyType} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesAnyType} The populated <code>AdditionalPropertiesAnyType</code> instance.
|
||||
* @param {module:model/InlineObject1} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject1} The populated <code>InlineObject1</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesAnyType();
|
||||
obj = obj || new InlineObject1();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Object');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
if (data.hasOwnProperty('additionalMetadata')) {
|
||||
obj['additionalMetadata'] = ApiClient.convertToType(data['additionalMetadata'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('file')) {
|
||||
obj['file'] = ApiClient.convertToType(data['file'], File);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -62,14 +61,21 @@ class AdditionalPropertiesAnyType {
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
* Additional data to pass to server
|
||||
* @member {String} additionalMetadata
|
||||
*/
|
||||
AdditionalPropertiesAnyType.prototype['name'] = undefined;
|
||||
InlineObject1.prototype['additionalMetadata'] = undefined;
|
||||
|
||||
/**
|
||||
* file to upload
|
||||
* @member {File} file
|
||||
*/
|
||||
InlineObject1.prototype['file'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesAnyType;
|
||||
export default InlineObject1;
|
||||
|
||||
@@ -0,0 +1,130 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The InlineObject2 model module.
|
||||
* @module model/InlineObject2
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class InlineObject2 {
|
||||
/**
|
||||
* Constructs a new <code>InlineObject2</code>.
|
||||
* @alias module:model/InlineObject2
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
InlineObject2.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>InlineObject2</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/InlineObject2} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject2} The populated <code>InlineObject2</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new InlineObject2();
|
||||
|
||||
if (data.hasOwnProperty('enum_form_string_array')) {
|
||||
obj['enum_form_string_array'] = ApiClient.convertToType(data['enum_form_string_array'], ['String']);
|
||||
}
|
||||
if (data.hasOwnProperty('enum_form_string')) {
|
||||
obj['enum_form_string'] = ApiClient.convertToType(data['enum_form_string'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Form parameter enum test (string array)
|
||||
* @member {Array.<module:model/InlineObject2.EnumFormStringArrayEnum>} enum_form_string_array
|
||||
*/
|
||||
InlineObject2.prototype['enum_form_string_array'] = undefined;
|
||||
|
||||
/**
|
||||
* Form parameter enum test (string)
|
||||
* @member {module:model/InlineObject2.EnumFormStringEnum} enum_form_string
|
||||
* @default '-efg'
|
||||
*/
|
||||
InlineObject2.prototype['enum_form_string'] = '-efg';
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>enumFormStringArray</code> property.
|
||||
* @enum {String}
|
||||
* @readonly
|
||||
*/
|
||||
InlineObject2['EnumFormStringArrayEnum'] = {
|
||||
|
||||
/**
|
||||
* value: ">"
|
||||
* @const
|
||||
*/
|
||||
"GREATER_THAN": ">",
|
||||
|
||||
/**
|
||||
* value: "$"
|
||||
* @const
|
||||
*/
|
||||
"DOLLAR": "$"
|
||||
};
|
||||
|
||||
|
||||
/**
|
||||
* Allowed values for the <code>enum_form_string</code> property.
|
||||
* @enum {String}
|
||||
* @readonly
|
||||
*/
|
||||
InlineObject2['EnumFormStringEnum'] = {
|
||||
|
||||
/**
|
||||
* value: "_abc"
|
||||
* @const
|
||||
*/
|
||||
"_abc": "_abc",
|
||||
|
||||
/**
|
||||
* value: "-efg"
|
||||
* @const
|
||||
*/
|
||||
"-efg": "-efg",
|
||||
|
||||
/**
|
||||
* value: "(xyz)"
|
||||
* @const
|
||||
*/
|
||||
"(xyz)": "(xyz)"
|
||||
};
|
||||
|
||||
|
||||
|
||||
export default InlineObject2;
|
||||
|
||||
@@ -0,0 +1,197 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The InlineObject3 model module.
|
||||
* @module model/InlineObject3
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class InlineObject3 {
|
||||
/**
|
||||
* Constructs a new <code>InlineObject3</code>.
|
||||
* @alias module:model/InlineObject3
|
||||
* @param _number {Number} None
|
||||
* @param _double {Number} None
|
||||
* @param patternWithoutDelimiter {String} None
|
||||
* @param _byte {Blob} None
|
||||
*/
|
||||
constructor(_number, _double, patternWithoutDelimiter, _byte) {
|
||||
|
||||
InlineObject3.initialize(this, _number, _double, patternWithoutDelimiter, _byte);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj, _number, _double, patternWithoutDelimiter, _byte) {
|
||||
obj['number'] = _number;
|
||||
obj['double'] = _double;
|
||||
obj['pattern_without_delimiter'] = patternWithoutDelimiter;
|
||||
obj['byte'] = _byte;
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>InlineObject3</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/InlineObject3} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject3} The populated <code>InlineObject3</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new InlineObject3();
|
||||
|
||||
if (data.hasOwnProperty('integer')) {
|
||||
obj['integer'] = ApiClient.convertToType(data['integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('int32')) {
|
||||
obj['int32'] = ApiClient.convertToType(data['int32'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('int64')) {
|
||||
obj['int64'] = ApiClient.convertToType(data['int64'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('number')) {
|
||||
obj['number'] = ApiClient.convertToType(data['number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('float')) {
|
||||
obj['float'] = ApiClient.convertToType(data['float'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('double')) {
|
||||
obj['double'] = ApiClient.convertToType(data['double'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('string')) {
|
||||
obj['string'] = ApiClient.convertToType(data['string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('pattern_without_delimiter')) {
|
||||
obj['pattern_without_delimiter'] = ApiClient.convertToType(data['pattern_without_delimiter'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('byte')) {
|
||||
obj['byte'] = ApiClient.convertToType(data['byte'], 'Blob');
|
||||
}
|
||||
if (data.hasOwnProperty('binary')) {
|
||||
obj['binary'] = ApiClient.convertToType(data['binary'], File);
|
||||
}
|
||||
if (data.hasOwnProperty('date')) {
|
||||
obj['date'] = ApiClient.convertToType(data['date'], 'Date');
|
||||
}
|
||||
if (data.hasOwnProperty('dateTime')) {
|
||||
obj['dateTime'] = ApiClient.convertToType(data['dateTime'], 'Date');
|
||||
}
|
||||
if (data.hasOwnProperty('password')) {
|
||||
obj['password'] = ApiClient.convertToType(data['password'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('callback')) {
|
||||
obj['callback'] = ApiClient.convertToType(data['callback'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} integer
|
||||
*/
|
||||
InlineObject3.prototype['integer'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} int32
|
||||
*/
|
||||
InlineObject3.prototype['int32'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} int64
|
||||
*/
|
||||
InlineObject3.prototype['int64'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} number
|
||||
*/
|
||||
InlineObject3.prototype['number'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} float
|
||||
*/
|
||||
InlineObject3.prototype['float'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Number} double
|
||||
*/
|
||||
InlineObject3.prototype['double'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {String} string
|
||||
*/
|
||||
InlineObject3.prototype['string'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {String} pattern_without_delimiter
|
||||
*/
|
||||
InlineObject3.prototype['pattern_without_delimiter'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Blob} byte
|
||||
*/
|
||||
InlineObject3.prototype['byte'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {File} binary
|
||||
*/
|
||||
InlineObject3.prototype['binary'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Date} date
|
||||
*/
|
||||
InlineObject3.prototype['date'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {Date} dateTime
|
||||
*/
|
||||
InlineObject3.prototype['dateTime'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {String} password
|
||||
*/
|
||||
InlineObject3.prototype['password'] = undefined;
|
||||
|
||||
/**
|
||||
* None
|
||||
* @member {String} callback
|
||||
*/
|
||||
InlineObject3.prototype['callback'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default InlineObject3;
|
||||
|
||||
@@ -0,0 +1,85 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The InlineObject4 model module.
|
||||
* @module model/InlineObject4
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class InlineObject4 {
|
||||
/**
|
||||
* Constructs a new <code>InlineObject4</code>.
|
||||
* @alias module:model/InlineObject4
|
||||
* @param param {String} field1
|
||||
* @param param2 {String} field2
|
||||
*/
|
||||
constructor(param, param2) {
|
||||
|
||||
InlineObject4.initialize(this, param, param2);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj, param, param2) {
|
||||
obj['param'] = param;
|
||||
obj['param2'] = param2;
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>InlineObject4</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/InlineObject4} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject4} The populated <code>InlineObject4</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new InlineObject4();
|
||||
|
||||
if (data.hasOwnProperty('param')) {
|
||||
obj['param'] = ApiClient.convertToType(data['param'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('param2')) {
|
||||
obj['param2'] = ApiClient.convertToType(data['param2'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* field1
|
||||
* @member {String} param
|
||||
*/
|
||||
InlineObject4.prototype['param'] = undefined;
|
||||
|
||||
/**
|
||||
* field2
|
||||
* @member {String} param2
|
||||
*/
|
||||
InlineObject4.prototype['param2'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default InlineObject4;
|
||||
|
||||
@@ -0,0 +1,83 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The InlineObject5 model module.
|
||||
* @module model/InlineObject5
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class InlineObject5 {
|
||||
/**
|
||||
* Constructs a new <code>InlineObject5</code>.
|
||||
* @alias module:model/InlineObject5
|
||||
* @param requiredFile {File} file to upload
|
||||
*/
|
||||
constructor(requiredFile) {
|
||||
|
||||
InlineObject5.initialize(this, requiredFile);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj, requiredFile) {
|
||||
obj['requiredFile'] = requiredFile;
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>InlineObject5</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/InlineObject5} obj Optional instance to populate.
|
||||
* @return {module:model/InlineObject5} The populated <code>InlineObject5</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new InlineObject5();
|
||||
|
||||
if (data.hasOwnProperty('additionalMetadata')) {
|
||||
obj['additionalMetadata'] = ApiClient.convertToType(data['additionalMetadata'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('requiredFile')) {
|
||||
obj['requiredFile'] = ApiClient.convertToType(data['requiredFile'], File);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Additional data to pass to server
|
||||
* @member {String} additionalMetadata
|
||||
*/
|
||||
InlineObject5.prototype['additionalMetadata'] = undefined;
|
||||
|
||||
/**
|
||||
* file to upload
|
||||
* @member {File} requiredFile
|
||||
*/
|
||||
InlineObject5.prototype['requiredFile'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default InlineObject5;
|
||||
|
||||
@@ -12,21 +12,21 @@
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
import Foo from './Foo';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesString model module.
|
||||
* @module model/AdditionalPropertiesString
|
||||
* The InlineResponseDefault model module.
|
||||
* @module model/InlineResponseDefault
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesString {
|
||||
class InlineResponseDefault {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesString</code>.
|
||||
* @alias module:model/AdditionalPropertiesString
|
||||
* @extends Object
|
||||
* Constructs a new <code>InlineResponseDefault</code>.
|
||||
* @alias module:model/InlineResponseDefault
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesString.initialize(this);
|
||||
InlineResponseDefault.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,21 +38,18 @@ class AdditionalPropertiesString {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesString</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>InlineResponseDefault</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesString} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesString} The populated <code>AdditionalPropertiesString</code> instance.
|
||||
* @param {module:model/InlineResponseDefault} obj Optional instance to populate.
|
||||
* @return {module:model/InlineResponseDefault} The populated <code>InlineResponseDefault</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesString();
|
||||
obj = obj || new InlineResponseDefault();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'String');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
if (data.hasOwnProperty('string')) {
|
||||
obj['string'] = Foo.constructFromObject(data['string']);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
@@ -62,14 +59,14 @@ class AdditionalPropertiesString {
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
* @member {module:model/Foo} string
|
||||
*/
|
||||
AdditionalPropertiesString.prototype['name'] = undefined;
|
||||
InlineResponseDefault.prototype['string'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesString;
|
||||
export default InlineResponseDefault;
|
||||
|
||||
@@ -0,0 +1,163 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The NullableClass model module.
|
||||
* @module model/NullableClass
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class NullableClass {
|
||||
/**
|
||||
* Constructs a new <code>NullableClass</code>.
|
||||
* @alias module:model/NullableClass
|
||||
* @extends Object
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
NullableClass.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>NullableClass</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/NullableClass} obj Optional instance to populate.
|
||||
* @return {module:model/NullableClass} The populated <code>NullableClass</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new NullableClass();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Object');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('integer_prop')) {
|
||||
obj['integer_prop'] = ApiClient.convertToType(data['integer_prop'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('number_prop')) {
|
||||
obj['number_prop'] = ApiClient.convertToType(data['number_prop'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('boolean_prop')) {
|
||||
obj['boolean_prop'] = ApiClient.convertToType(data['boolean_prop'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('string_prop')) {
|
||||
obj['string_prop'] = ApiClient.convertToType(data['string_prop'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('date_prop')) {
|
||||
obj['date_prop'] = ApiClient.convertToType(data['date_prop'], 'Date');
|
||||
}
|
||||
if (data.hasOwnProperty('datetime_prop')) {
|
||||
obj['datetime_prop'] = ApiClient.convertToType(data['datetime_prop'], 'Date');
|
||||
}
|
||||
if (data.hasOwnProperty('array_nullable_prop')) {
|
||||
obj['array_nullable_prop'] = ApiClient.convertToType(data['array_nullable_prop'], [Object]);
|
||||
}
|
||||
if (data.hasOwnProperty('array_and_items_nullable_prop')) {
|
||||
obj['array_and_items_nullable_prop'] = ApiClient.convertToType(data['array_and_items_nullable_prop'], [Object]);
|
||||
}
|
||||
if (data.hasOwnProperty('array_items_nullable')) {
|
||||
obj['array_items_nullable'] = ApiClient.convertToType(data['array_items_nullable'], [Object]);
|
||||
}
|
||||
if (data.hasOwnProperty('object_nullable_prop')) {
|
||||
obj['object_nullable_prop'] = ApiClient.convertToType(data['object_nullable_prop'], {'String': Object});
|
||||
}
|
||||
if (data.hasOwnProperty('object_and_items_nullable_prop')) {
|
||||
obj['object_and_items_nullable_prop'] = ApiClient.convertToType(data['object_and_items_nullable_prop'], {'String': Object});
|
||||
}
|
||||
if (data.hasOwnProperty('object_items_nullable')) {
|
||||
obj['object_items_nullable'] = ApiClient.convertToType(data['object_items_nullable'], {'String': Object});
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {Number} integer_prop
|
||||
*/
|
||||
NullableClass.prototype['integer_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} number_prop
|
||||
*/
|
||||
NullableClass.prototype['number_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} boolean_prop
|
||||
*/
|
||||
NullableClass.prototype['boolean_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {String} string_prop
|
||||
*/
|
||||
NullableClass.prototype['string_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Date} date_prop
|
||||
*/
|
||||
NullableClass.prototype['date_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Date} datetime_prop
|
||||
*/
|
||||
NullableClass.prototype['datetime_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Object>} array_nullable_prop
|
||||
*/
|
||||
NullableClass.prototype['array_nullable_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Object>} array_and_items_nullable_prop
|
||||
*/
|
||||
NullableClass.prototype['array_and_items_nullable_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Object>} array_items_nullable
|
||||
*/
|
||||
NullableClass.prototype['array_items_nullable'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Object>} object_nullable_prop
|
||||
*/
|
||||
NullableClass.prototype['object_nullable_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Object>} object_and_items_nullable_prop
|
||||
*/
|
||||
NullableClass.prototype['object_and_items_nullable_prop'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Object.<String, Object>} object_items_nullable
|
||||
*/
|
||||
NullableClass.prototype['object_items_nullable'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default NullableClass;
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
/**
|
||||
* Enum class OuterEnumDefaultValue.
|
||||
* @enum {}
|
||||
* @readonly
|
||||
*/
|
||||
export default class OuterEnumDefaultValue {
|
||||
|
||||
/**
|
||||
* value: "placed"
|
||||
* @const
|
||||
*/
|
||||
"placed" = "placed";
|
||||
|
||||
|
||||
/**
|
||||
* value: "approved"
|
||||
* @const
|
||||
*/
|
||||
"approved" = "approved";
|
||||
|
||||
|
||||
/**
|
||||
* value: "delivered"
|
||||
* @const
|
||||
*/
|
||||
"delivered" = "delivered";
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Returns a <code>OuterEnumDefaultValue</code> enum value from a Javascript object name.
|
||||
* @param {Object} data The plain JavaScript object containing the name of the enum value.
|
||||
* @return {module:model/OuterEnumDefaultValue} The enum <code>OuterEnumDefaultValue</code> value.
|
||||
*/
|
||||
static constructFromObject(object) {
|
||||
return object;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
/**
|
||||
* Enum class OuterEnumInteger.
|
||||
* @enum {}
|
||||
* @readonly
|
||||
*/
|
||||
export default class OuterEnumInteger {
|
||||
|
||||
/**
|
||||
* value: 0
|
||||
* @const
|
||||
*/
|
||||
"0" = 0;
|
||||
|
||||
|
||||
/**
|
||||
* value: 1
|
||||
* @const
|
||||
*/
|
||||
"1" = 1;
|
||||
|
||||
|
||||
/**
|
||||
* value: 2
|
||||
* @const
|
||||
*/
|
||||
"2" = 2;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Returns a <code>OuterEnumInteger</code> enum value from a Javascript object name.
|
||||
* @param {Object} data The plain JavaScript object containing the name of the enum value.
|
||||
* @return {module:model/OuterEnumInteger} The enum <code>OuterEnumInteger</code> value.
|
||||
*/
|
||||
static constructFromObject(object) {
|
||||
return object;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
/**
|
||||
* Enum class OuterEnumIntegerDefaultValue.
|
||||
* @enum {}
|
||||
* @readonly
|
||||
*/
|
||||
export default class OuterEnumIntegerDefaultValue {
|
||||
|
||||
/**
|
||||
* value: 0
|
||||
* @const
|
||||
*/
|
||||
"0" = 0;
|
||||
|
||||
|
||||
/**
|
||||
* value: 1
|
||||
* @const
|
||||
*/
|
||||
"1" = 1;
|
||||
|
||||
|
||||
/**
|
||||
* value: 2
|
||||
* @const
|
||||
*/
|
||||
"2" = 2;
|
||||
|
||||
|
||||
|
||||
/**
|
||||
* Returns a <code>OuterEnumIntegerDefaultValue</code> enum value from a Javascript object name.
|
||||
* @param {Object} data The plain JavaScript object containing the name of the enum value.
|
||||
* @return {module:model/OuterEnumIntegerDefaultValue} The enum <code>OuterEnumIntegerDefaultValue</code> value.
|
||||
*/
|
||||
static constructFromObject(object) {
|
||||
return object;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
* OpenAPI spec version: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
@@ -14,19 +14,19 @@
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The AdditionalPropertiesBoolean model module.
|
||||
* @module model/AdditionalPropertiesBoolean
|
||||
* The StringBooleanMap model module.
|
||||
* @module model/StringBooleanMap
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class AdditionalPropertiesBoolean {
|
||||
class StringBooleanMap {
|
||||
/**
|
||||
* Constructs a new <code>AdditionalPropertiesBoolean</code>.
|
||||
* @alias module:model/AdditionalPropertiesBoolean
|
||||
* Constructs a new <code>StringBooleanMap</code>.
|
||||
* @alias module:model/StringBooleanMap
|
||||
* @extends Object
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
AdditionalPropertiesBoolean.initialize(this);
|
||||
StringBooleanMap.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -38,22 +38,19 @@ class AdditionalPropertiesBoolean {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>AdditionalPropertiesBoolean</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Constructs a <code>StringBooleanMap</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/AdditionalPropertiesBoolean} obj Optional instance to populate.
|
||||
* @return {module:model/AdditionalPropertiesBoolean} The populated <code>AdditionalPropertiesBoolean</code> instance.
|
||||
* @param {module:model/StringBooleanMap} obj Optional instance to populate.
|
||||
* @return {module:model/StringBooleanMap} The populated <code>StringBooleanMap</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new AdditionalPropertiesBoolean();
|
||||
obj = obj || new StringBooleanMap();
|
||||
|
||||
ApiClient.constructFromObject(data, obj, 'Boolean');
|
||||
|
||||
|
||||
if (data.hasOwnProperty('name')) {
|
||||
obj['name'] = ApiClient.convertToType(data['name'], 'String');
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
@@ -61,15 +58,10 @@ class AdditionalPropertiesBoolean {
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} name
|
||||
*/
|
||||
AdditionalPropertiesBoolean.prototype['name'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default AdditionalPropertiesBoolean;
|
||||
export default StringBooleanMap;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
* OpenAPI spec version: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
* OpenAPI spec version: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
@@ -24,14 +24,13 @@ class TypeHolderExample {
|
||||
* @alias module:model/TypeHolderExample
|
||||
* @param stringItem {String}
|
||||
* @param numberItem {Number}
|
||||
* @param floatItem {Number}
|
||||
* @param integerItem {Number}
|
||||
* @param boolItem {Boolean}
|
||||
* @param arrayItem {Array.<Number>}
|
||||
*/
|
||||
constructor(stringItem, numberItem, floatItem, integerItem, boolItem, arrayItem) {
|
||||
constructor(stringItem, numberItem, integerItem, boolItem, arrayItem) {
|
||||
|
||||
TypeHolderExample.initialize(this, stringItem, numberItem, floatItem, integerItem, boolItem, arrayItem);
|
||||
TypeHolderExample.initialize(this, stringItem, numberItem, integerItem, boolItem, arrayItem);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -39,10 +38,9 @@ class TypeHolderExample {
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj, stringItem, numberItem, floatItem, integerItem, boolItem, arrayItem) {
|
||||
static initialize(obj, stringItem, numberItem, integerItem, boolItem, arrayItem) {
|
||||
obj['string_item'] = stringItem;
|
||||
obj['number_item'] = numberItem;
|
||||
obj['float_item'] = floatItem;
|
||||
obj['integer_item'] = integerItem;
|
||||
obj['bool_item'] = boolItem;
|
||||
obj['array_item'] = arrayItem;
|
||||
@@ -65,9 +63,6 @@ class TypeHolderExample {
|
||||
if (data.hasOwnProperty('number_item')) {
|
||||
obj['number_item'] = ApiClient.convertToType(data['number_item'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('float_item')) {
|
||||
obj['float_item'] = ApiClient.convertToType(data['float_item'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('integer_item')) {
|
||||
obj['integer_item'] = ApiClient.convertToType(data['integer_item'], 'Number');
|
||||
}
|
||||
@@ -94,11 +89,6 @@ TypeHolderExample.prototype['string_item'] = undefined;
|
||||
*/
|
||||
TypeHolderExample.prototype['number_item'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} float_item
|
||||
*/
|
||||
TypeHolderExample.prototype['float_item'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} integer_item
|
||||
*/
|
||||
|
||||
@@ -1,295 +0,0 @@
|
||||
/**
|
||||
* OpenAPI Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* The version of the OpenAPI document: 1.0.0
|
||||
*
|
||||
*
|
||||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
||||
* https://openapi-generator.tech
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
import ApiClient from '../ApiClient';
|
||||
|
||||
/**
|
||||
* The XmlItem model module.
|
||||
* @module model/XmlItem
|
||||
* @version 1.0.0
|
||||
*/
|
||||
class XmlItem {
|
||||
/**
|
||||
* Constructs a new <code>XmlItem</code>.
|
||||
* @alias module:model/XmlItem
|
||||
*/
|
||||
constructor() {
|
||||
|
||||
XmlItem.initialize(this);
|
||||
}
|
||||
|
||||
/**
|
||||
* Initializes the fields of this object.
|
||||
* This method is used by the constructors of any subclasses, in order to implement multiple inheritance (mix-ins).
|
||||
* Only for internal use.
|
||||
*/
|
||||
static initialize(obj) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructs a <code>XmlItem</code> from a plain JavaScript object, optionally creating a new instance.
|
||||
* Copies all relevant properties from <code>data</code> to <code>obj</code> if supplied or a new instance if not.
|
||||
* @param {Object} data The plain JavaScript object bearing properties of interest.
|
||||
* @param {module:model/XmlItem} obj Optional instance to populate.
|
||||
* @return {module:model/XmlItem} The populated <code>XmlItem</code> instance.
|
||||
*/
|
||||
static constructFromObject(data, obj) {
|
||||
if (data) {
|
||||
obj = obj || new XmlItem();
|
||||
|
||||
if (data.hasOwnProperty('attribute_string')) {
|
||||
obj['attribute_string'] = ApiClient.convertToType(data['attribute_string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('attribute_number')) {
|
||||
obj['attribute_number'] = ApiClient.convertToType(data['attribute_number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('attribute_integer')) {
|
||||
obj['attribute_integer'] = ApiClient.convertToType(data['attribute_integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('attribute_boolean')) {
|
||||
obj['attribute_boolean'] = ApiClient.convertToType(data['attribute_boolean'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('wrapped_array')) {
|
||||
obj['wrapped_array'] = ApiClient.convertToType(data['wrapped_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('name_string')) {
|
||||
obj['name_string'] = ApiClient.convertToType(data['name_string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('name_number')) {
|
||||
obj['name_number'] = ApiClient.convertToType(data['name_number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('name_integer')) {
|
||||
obj['name_integer'] = ApiClient.convertToType(data['name_integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('name_boolean')) {
|
||||
obj['name_boolean'] = ApiClient.convertToType(data['name_boolean'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('name_array')) {
|
||||
obj['name_array'] = ApiClient.convertToType(data['name_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('name_wrapped_array')) {
|
||||
obj['name_wrapped_array'] = ApiClient.convertToType(data['name_wrapped_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_string')) {
|
||||
obj['prefix_string'] = ApiClient.convertToType(data['prefix_string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_number')) {
|
||||
obj['prefix_number'] = ApiClient.convertToType(data['prefix_number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_integer')) {
|
||||
obj['prefix_integer'] = ApiClient.convertToType(data['prefix_integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_boolean')) {
|
||||
obj['prefix_boolean'] = ApiClient.convertToType(data['prefix_boolean'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_array')) {
|
||||
obj['prefix_array'] = ApiClient.convertToType(data['prefix_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_wrapped_array')) {
|
||||
obj['prefix_wrapped_array'] = ApiClient.convertToType(data['prefix_wrapped_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_string')) {
|
||||
obj['namespace_string'] = ApiClient.convertToType(data['namespace_string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_number')) {
|
||||
obj['namespace_number'] = ApiClient.convertToType(data['namespace_number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_integer')) {
|
||||
obj['namespace_integer'] = ApiClient.convertToType(data['namespace_integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_boolean')) {
|
||||
obj['namespace_boolean'] = ApiClient.convertToType(data['namespace_boolean'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_array')) {
|
||||
obj['namespace_array'] = ApiClient.convertToType(data['namespace_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('namespace_wrapped_array')) {
|
||||
obj['namespace_wrapped_array'] = ApiClient.convertToType(data['namespace_wrapped_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_string')) {
|
||||
obj['prefix_ns_string'] = ApiClient.convertToType(data['prefix_ns_string'], 'String');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_number')) {
|
||||
obj['prefix_ns_number'] = ApiClient.convertToType(data['prefix_ns_number'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_integer')) {
|
||||
obj['prefix_ns_integer'] = ApiClient.convertToType(data['prefix_ns_integer'], 'Number');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_boolean')) {
|
||||
obj['prefix_ns_boolean'] = ApiClient.convertToType(data['prefix_ns_boolean'], 'Boolean');
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_array')) {
|
||||
obj['prefix_ns_array'] = ApiClient.convertToType(data['prefix_ns_array'], ['Number']);
|
||||
}
|
||||
if (data.hasOwnProperty('prefix_ns_wrapped_array')) {
|
||||
obj['prefix_ns_wrapped_array'] = ApiClient.convertToType(data['prefix_ns_wrapped_array'], ['Number']);
|
||||
}
|
||||
}
|
||||
return obj;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* @member {String} attribute_string
|
||||
*/
|
||||
XmlItem.prototype['attribute_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} attribute_number
|
||||
*/
|
||||
XmlItem.prototype['attribute_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} attribute_integer
|
||||
*/
|
||||
XmlItem.prototype['attribute_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} attribute_boolean
|
||||
*/
|
||||
XmlItem.prototype['attribute_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} wrapped_array
|
||||
*/
|
||||
XmlItem.prototype['wrapped_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {String} name_string
|
||||
*/
|
||||
XmlItem.prototype['name_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} name_number
|
||||
*/
|
||||
XmlItem.prototype['name_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} name_integer
|
||||
*/
|
||||
XmlItem.prototype['name_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} name_boolean
|
||||
*/
|
||||
XmlItem.prototype['name_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} name_array
|
||||
*/
|
||||
XmlItem.prototype['name_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} name_wrapped_array
|
||||
*/
|
||||
XmlItem.prototype['name_wrapped_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {String} prefix_string
|
||||
*/
|
||||
XmlItem.prototype['prefix_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} prefix_number
|
||||
*/
|
||||
XmlItem.prototype['prefix_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} prefix_integer
|
||||
*/
|
||||
XmlItem.prototype['prefix_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} prefix_boolean
|
||||
*/
|
||||
XmlItem.prototype['prefix_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} prefix_array
|
||||
*/
|
||||
XmlItem.prototype['prefix_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} prefix_wrapped_array
|
||||
*/
|
||||
XmlItem.prototype['prefix_wrapped_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {String} namespace_string
|
||||
*/
|
||||
XmlItem.prototype['namespace_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} namespace_number
|
||||
*/
|
||||
XmlItem.prototype['namespace_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} namespace_integer
|
||||
*/
|
||||
XmlItem.prototype['namespace_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} namespace_boolean
|
||||
*/
|
||||
XmlItem.prototype['namespace_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} namespace_array
|
||||
*/
|
||||
XmlItem.prototype['namespace_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} namespace_wrapped_array
|
||||
*/
|
||||
XmlItem.prototype['namespace_wrapped_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {String} prefix_ns_string
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_string'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} prefix_ns_number
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_number'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Number} prefix_ns_integer
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_integer'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Boolean} prefix_ns_boolean
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_boolean'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} prefix_ns_array
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_array'] = undefined;
|
||||
|
||||
/**
|
||||
* @member {Array.<Number>} prefix_ns_wrapped_array
|
||||
*/
|
||||
XmlItem.prototype['prefix_ns_wrapped_array'] = undefined;
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
export default XmlItem;
|
||||
|
||||
@@ -0,0 +1,63 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.AnotherFakeApi();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('AnotherFakeApi', function() {
|
||||
describe('testSpecialTags', function() {
|
||||
it('should call testSpecialTags successfully', function(done) {
|
||||
//uncomment below and update the code to test testSpecialTags
|
||||
//instance.testSpecialTags(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,123 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.FakeApi();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('FakeApi', function() {
|
||||
describe('fakeOuterBooleanSerialize', function() {
|
||||
it('should call fakeOuterBooleanSerialize successfully', function(done) {
|
||||
//uncomment below and update the code to test fakeOuterBooleanSerialize
|
||||
//instance.fakeOuterBooleanSerialize(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('fakeOuterCompositeSerialize', function() {
|
||||
it('should call fakeOuterCompositeSerialize successfully', function(done) {
|
||||
//uncomment below and update the code to test fakeOuterCompositeSerialize
|
||||
//instance.fakeOuterCompositeSerialize(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('fakeOuterNumberSerialize', function() {
|
||||
it('should call fakeOuterNumberSerialize successfully', function(done) {
|
||||
//uncomment below and update the code to test fakeOuterNumberSerialize
|
||||
//instance.fakeOuterNumberSerialize(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('fakeOuterStringSerialize', function() {
|
||||
it('should call fakeOuterStringSerialize successfully', function(done) {
|
||||
//uncomment below and update the code to test fakeOuterStringSerialize
|
||||
//instance.fakeOuterStringSerialize(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('testClientModel', function() {
|
||||
it('should call testClientModel successfully', function(done) {
|
||||
//uncomment below and update the code to test testClientModel
|
||||
//instance.testClientModel(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('testEndpointParameters', function() {
|
||||
it('should call testEndpointParameters successfully', function(done) {
|
||||
//uncomment below and update the code to test testEndpointParameters
|
||||
//instance.testEndpointParameters(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('testEnumParameters', function() {
|
||||
it('should call testEnumParameters successfully', function(done) {
|
||||
//uncomment below and update the code to test testEnumParameters
|
||||
//instance.testEnumParameters(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,63 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.FakeClassnameTags123Api();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('FakeClassnameTags123Api', function() {
|
||||
describe('testClassname', function() {
|
||||
it('should call testClassname successfully', function(done) {
|
||||
//uncomment below and update the code to test testClassname
|
||||
//instance.testClassname(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,133 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.PetApi();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('PetApi', function() {
|
||||
describe('addPet', function() {
|
||||
it('should call addPet successfully', function(done) {
|
||||
//uncomment below and update the code to test addPet
|
||||
//instance.addPet(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('deletePet', function() {
|
||||
it('should call deletePet successfully', function(done) {
|
||||
//uncomment below and update the code to test deletePet
|
||||
//instance.deletePet(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('findPetsByStatus', function() {
|
||||
it('should call findPetsByStatus successfully', function(done) {
|
||||
//uncomment below and update the code to test findPetsByStatus
|
||||
//instance.findPetsByStatus(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('findPetsByTags', function() {
|
||||
it('should call findPetsByTags successfully', function(done) {
|
||||
//uncomment below and update the code to test findPetsByTags
|
||||
//instance.findPetsByTags(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('getPetById', function() {
|
||||
it('should call getPetById successfully', function(done) {
|
||||
//uncomment below and update the code to test getPetById
|
||||
//instance.getPetById(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('updatePet', function() {
|
||||
it('should call updatePet successfully', function(done) {
|
||||
//uncomment below and update the code to test updatePet
|
||||
//instance.updatePet(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('updatePetWithForm', function() {
|
||||
it('should call updatePetWithForm successfully', function(done) {
|
||||
//uncomment below and update the code to test updatePetWithForm
|
||||
//instance.updatePetWithForm(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('uploadFile', function() {
|
||||
it('should call uploadFile successfully', function(done) {
|
||||
//uncomment below and update the code to test uploadFile
|
||||
//instance.uploadFile(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,93 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.StoreApi();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('StoreApi', function() {
|
||||
describe('deleteOrder', function() {
|
||||
it('should call deleteOrder successfully', function(done) {
|
||||
//uncomment below and update the code to test deleteOrder
|
||||
//instance.deleteOrder(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('getInventory', function() {
|
||||
it('should call getInventory successfully', function(done) {
|
||||
//uncomment below and update the code to test getInventory
|
||||
//instance.getInventory(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('getOrderById', function() {
|
||||
it('should call getOrderById successfully', function(done) {
|
||||
//uncomment below and update the code to test getOrderById
|
||||
//instance.getOrderById(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('placeOrder', function() {
|
||||
it('should call placeOrder successfully', function(done) {
|
||||
//uncomment below and update the code to test placeOrder
|
||||
//instance.placeOrder(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
@@ -0,0 +1,133 @@
|
||||
/**
|
||||
* Swagger Petstore
|
||||
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
|
||||
*
|
||||
* OpenAPI spec version: 1.0.0
|
||||
* Contact: apiteam@swagger.io
|
||||
*
|
||||
* NOTE: This class is auto generated by the swagger code generator program.
|
||||
* https://github.com/swagger-api/swagger-codegen.git
|
||||
* Do not edit the class manually.
|
||||
*
|
||||
*/
|
||||
|
||||
(function(root, factory) {
|
||||
if (typeof define === 'function' && define.amd) {
|
||||
// AMD.
|
||||
define(['expect.js', '../../src/index'], factory);
|
||||
} else if (typeof module === 'object' && module.exports) {
|
||||
// CommonJS-like environments that support module.exports, like Node.
|
||||
factory(require('expect.js'), require('../../src/index'));
|
||||
} else {
|
||||
// Browser globals (root is window)
|
||||
factory(root.expect, root.SwaggerPetstore);
|
||||
}
|
||||
}(this, function(expect, SwaggerPetstore) {
|
||||
'use strict';
|
||||
|
||||
var instance;
|
||||
|
||||
beforeEach(function() {
|
||||
instance = new SwaggerPetstore.UserApi();
|
||||
});
|
||||
|
||||
var getProperty = function(object, getter, property) {
|
||||
// Use getter method if present; otherwise, get the property directly.
|
||||
if (typeof object[getter] === 'function')
|
||||
return object[getter]();
|
||||
else
|
||||
return object[property];
|
||||
}
|
||||
|
||||
var setProperty = function(object, setter, property, value) {
|
||||
// Use setter method if present; otherwise, set the property directly.
|
||||
if (typeof object[setter] === 'function')
|
||||
object[setter](value);
|
||||
else
|
||||
object[property] = value;
|
||||
}
|
||||
|
||||
describe('UserApi', function() {
|
||||
describe('createUser', function() {
|
||||
it('should call createUser successfully', function(done) {
|
||||
//uncomment below and update the code to test createUser
|
||||
//instance.createUser(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('createUsersWithArrayInput', function() {
|
||||
it('should call createUsersWithArrayInput successfully', function(done) {
|
||||
//uncomment below and update the code to test createUsersWithArrayInput
|
||||
//instance.createUsersWithArrayInput(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('createUsersWithListInput', function() {
|
||||
it('should call createUsersWithListInput successfully', function(done) {
|
||||
//uncomment below and update the code to test createUsersWithListInput
|
||||
//instance.createUsersWithListInput(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('deleteUser', function() {
|
||||
it('should call deleteUser successfully', function(done) {
|
||||
//uncomment below and update the code to test deleteUser
|
||||
//instance.deleteUser(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('getUserByName', function() {
|
||||
it('should call getUserByName successfully', function(done) {
|
||||
//uncomment below and update the code to test getUserByName
|
||||
//instance.getUserByName(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('loginUser', function() {
|
||||
it('should call loginUser successfully', function(done) {
|
||||
//uncomment below and update the code to test loginUser
|
||||
//instance.loginUser(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('logoutUser', function() {
|
||||
it('should call logoutUser successfully', function(done) {
|
||||
//uncomment below and update the code to test logoutUser
|
||||
//instance.logoutUser(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
describe('updateUser', function() {
|
||||
it('should call updateUser successfully', function(done) {
|
||||
//uncomment below and update the code to test updateUser
|
||||
//instance.updateUser(function(error) {
|
||||
// if (error) throw error;
|
||||
//expect().to.be();
|
||||
//});
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
}));
|
||||
Reference in New Issue
Block a user