diff --git a/bin/configs/dart-petstore-json-serializable-client-lib-fake.yaml b/bin/configs/dart-petstore-json-serializable-client-lib-fake.yaml deleted file mode 100644 index 8582a881d51d..000000000000 --- a/bin/configs/dart-petstore-json-serializable-client-lib-fake.yaml +++ /dev/null @@ -1,10 +0,0 @@ -generatorName: dart -outputDir: samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake -inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore-with-fake-endpoints-models-for-testing.yaml -templateDir: modules/openapi-generator/src/main/resources/dart2 -typeMappings: - Client: "ModelClient" - File: "ModelFile" -additionalProperties: - hideGenerationTimestamp: "true" - serializationLibrary: json_serializable diff --git a/docs/generators/dart.md b/docs/generators/dart.md index ef805b784512..cb783be68109 100644 --- a/docs/generators/dart.md +++ b/docs/generators/dart.md @@ -19,7 +19,7 @@ These options may be applied as additional-properties (cli) or configOptions (pl |pubLibrary|Library name in generated code| |null| |pubName|Name in generated pubspec| |null| |pubVersion|Version in generated pubspec| |null| -|serializationLibrary|Specify serialization library|
**native_serialization**
Use native serializer, backwards compatible
**json_serializable**
Use json_serializable. Experimental and subject to breaking changes without further notice
|native_serialization| +|serializationLibrary|Specify serialization library|
**native_serialization**
Use native serializer, backwards compatible
|native_serialization| |sortModelPropertiesByRequiredFlag|Sort model properties to place required parameters before optional parameters.| |true| |sortParamsByRequiredFlag|Sort method arguments to place required parameters before optional parameters.| |true| |sourceFolder|Source folder for generated code| |null| diff --git a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartClientCodegen.java b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartClientCodegen.java index b26f23891c0b..25853e0b2541 100644 --- a/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartClientCodegen.java +++ b/modules/openapi-generator/src/main/java/org/openapitools/codegen/languages/DartClientCodegen.java @@ -33,7 +33,6 @@ public class DartClientCodegen extends AbstractDartCodegen { private final Logger LOGGER = LoggerFactory.getLogger(DartClientCodegen.class); public static final String SERIALIZATION_LIBRARY_NATIVE = "native_serialization"; - public static final String SERIALIZATION_LIBRARY_JSON_SERIALIZABLE = "json_serializable"; public DartClientCodegen() { super(); @@ -43,7 +42,6 @@ public DartClientCodegen() { final Map serializationOptions = new HashMap<>(); serializationOptions.put(SERIALIZATION_LIBRARY_NATIVE, "Use native serializer, backwards compatible"); - serializationOptions.put(SERIALIZATION_LIBRARY_JSON_SERIALIZABLE, "Use json_serializable. Experimental and subject to breaking changes without further notice"); serializationLibrary.setEnum(serializationOptions); cliOptions.add(serializationLibrary); } @@ -88,15 +86,7 @@ private void setSerializationLibrary() { LOGGER.info("Using serialization library {}", serialization_library); switch (serialization_library) { - case SERIALIZATION_LIBRARY_JSON_SERIALIZABLE: - additionalProperties.put(SERIALIZATION_LIBRARY_JSON_SERIALIZABLE, "true"); - // json_serializable requires build.yaml - supportingFiles.add(new SupportingFile("build.yaml.mustache", - "" /* main project dir */, - "build.yaml")); - break; - - case SERIALIZATION_LIBRARY_NATIVE: // fall trough to default backwards compatible generator + case SERIALIZATION_LIBRARY_NATIVE: // fall through to default backwards compatible generator default: additionalProperties.put(SERIALIZATION_LIBRARY_NATIVE, "true"); diff --git a/modules/openapi-generator/src/main/resources/dart2/api.mustache b/modules/openapi-generator/src/main/resources/dart2/api.mustache index c16db47c110b..32f3ee2d8c42 100644 --- a/modules/openapi-generator/src/main/resources/dart2/api.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/api.mustache @@ -197,33 +197,7 @@ class {{{classname}}} { {{/isMap}} {{^isMap}} return await apiClient.deserializeAsync(await _decodeBodyBytes(response), '{{{returnType}}}',) as {{{returnType}}}; - {{/isMap}}{{/isArray}}{{/native_serialization}}{{#json_serializable}} - {{#isArray}} - {{#uniqueItems}} - return (json.decode(response.body) as List) - .map((i) => {{{returnBaseType}}}.fromJson(i)) - .toSet(); - {{/uniqueItems}} - {{^uniqueItems}} - return (json.decode(response.body) as List) - .map((i) => {{{returnBaseType}}}.fromJson(i)) - .toList(); - {{/uniqueItems}} - {{/isArray}} - {{^isArray}} - {{#isMap}} - return {{{returnType}}}.from(json.decode(response.body)); - {{/isMap}} - {{^isMap}} - {{#returnTypeIsPrimitive}} - return response.body as {{{returnBaseType}}}; - {{/returnTypeIsPrimitive}} - {{^returnTypeIsPrimitive}} - return {{{returnType}}}.fromJson(json.decode(response.body)); - {{/returnTypeIsPrimitive}} - {{/isMap}} - {{/isArray}} - {{/json_serializable}} + {{/isMap}}{{/isArray}}{{/native_serialization}} } return Future<{{{returnType}}}>.value(); {{/returnType}} diff --git a/modules/openapi-generator/src/main/resources/dart2/api_client.mustache b/modules/openapi-generator/src/main/resources/dart2/api_client.mustache index 85be6bc9376b..7eb14870b7ca 100644 --- a/modules/openapi-generator/src/main/resources/dart2/api_client.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/api_client.mustache @@ -208,7 +208,6 @@ class ApiClient { case '{{{classname}}}': {{#isEnum}} {{#native_serialization}}return {{{classname}}}TypeTransformer().decode(value);{{/native_serialization}} - {{#json_serializable}} return _$enumDecode(_${{{classname}}}EnumMap, value);{{/json_serializable}} {{/isEnum}} {{^isEnum}} return {{{classname}}}.fromJson(value); diff --git a/modules/openapi-generator/src/main/resources/dart2/api_helper.mustache b/modules/openapi-generator/src/main/resources/dart2/api_helper.mustache index c64effcdda0f..6b2f4f2fdef8 100644 --- a/modules/openapi-generator/src/main/resources/dart2/api_helper.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/api_helper.mustache @@ -54,7 +54,7 @@ String parameterToString(dynamic value) { {{#model}} {{#isEnum}} if (value is {{{classname}}}) { -{{#native_serialization}} return {{{classname}}}TypeTransformer().encode(value).toString();{{/native_serialization}}{{#json_serializable}} return value.toString();{{/json_serializable}} +{{#native_serialization}} return {{{classname}}}TypeTransformer().encode(value).toString();{{/native_serialization}} } {{/isEnum}} {{/model}} diff --git a/modules/openapi-generator/src/main/resources/dart2/apilib.mustache b/modules/openapi-generator/src/main/resources/dart2/apilib.mustache index e2233d95ec49..2fcebda4ea46 100644 --- a/modules/openapi-generator/src/main/resources/dart2/apilib.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/apilib.mustache @@ -7,9 +7,6 @@ import 'dart:io'; import 'package:http/http.dart'; import 'package:intl/intl.dart'; -{{#json_serializable}} -import 'package:json_annotation/json_annotation.dart'; -{{/json_serializable}} import 'package:meta/meta.dart'; part 'api_client.dart'; @@ -26,9 +23,6 @@ part 'auth/http_bearer_auth.dart'; {{#models}}{{#model}}part 'model/{{{classFilename}}}.dart'; {{/model}}{{/models}} -{{#json_serializable}} -part 'api.g.dart'; -{{/json_serializable}} const _delimiters = {'csv': ',', 'ssv': ' ', 'tsv': '\t', 'pipes': '|'}; const _dateEpochMarker = 'epoch'; final _dateFormatter = DateFormat('yyyy-MM-dd'); diff --git a/modules/openapi-generator/src/main/resources/dart2/build.yaml.mustache b/modules/openapi-generator/src/main/resources/dart2/build.yaml.mustache deleted file mode 100644 index 89a4dd6e1c2e..000000000000 --- a/modules/openapi-generator/src/main/resources/dart2/build.yaml.mustache +++ /dev/null @@ -1,18 +0,0 @@ -targets: - $default: - builders: - json_serializable: - options: - # Options configure how source code is generated for every - # `@JsonSerializable`-annotated class in the package. - # - # The default value for each is listed. - any_map: false - checked: true - create_factory: true - create_to_json: true - disallow_unrecognized_keys: true - explicit_to_json: true - field_rename: none - ignore_unannotated: false - include_if_null: false diff --git a/modules/openapi-generator/src/main/resources/dart2/model.mustache b/modules/openapi-generator/src/main/resources/dart2/model.mustache index 9c738da279bd..306c54e417e6 100644 --- a/modules/openapi-generator/src/main/resources/dart2/model.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/model.mustache @@ -6,17 +6,11 @@ {{#native_serialization}} {{>serialization/native/native_enum}} {{/native_serialization}} -{{#json_serializable}} -{{>serialization/json_serializable/json_serializable_enum}} -{{/json_serializable}} {{/isEnum}} {{^isEnum}} {{#native_serialization}} {{>serialization/native/native_class}} {{/native_serialization}} -{{#json_serializable}} -{{>serialization/json_serializable/json_serializable_class}} -{{/json_serializable}} {{/isEnum}} {{/model}} {{/models}} diff --git a/modules/openapi-generator/src/main/resources/dart2/pubspec.mustache b/modules/openapi-generator/src/main/resources/dart2/pubspec.mustache index 4ce12df9e486..186986237424 100644 --- a/modules/openapi-generator/src/main/resources/dart2/pubspec.mustache +++ b/modules/openapi-generator/src/main/resources/dart2/pubspec.mustache @@ -12,10 +12,5 @@ dependencies: http: '>=0.13.0 <0.14.0' intl: '^0.17.0' meta: '^1.1.8' -{{#json_serializable}} - json_annotation: '^3.1.1'{{/json_serializable}} dev_dependencies: test: '>=1.16.0 <1.18.0' -{{#json_serializable}} - build_runner: '^1.10.9' - json_serializable: '^3.5.1'{{/json_serializable}} diff --git a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_class.mustache b/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_class.mustache deleted file mode 100644 index ec97f23eb726..000000000000 --- a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_class.mustache +++ /dev/null @@ -1,67 +0,0 @@ -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class {{{classname}}} { -{{>dart_constructor}} - -{{#vars}} - {{#description}} - /// {{{.}}} - {{/description}} - {{^isEnum}} - {{#minimum}} - // minimum: {{{.}}} - {{/minimum}} - {{#maximum}} - // maximum: {{{.}}} - {{/maximum}} - {{/isEnum}} - {{^isBinary}} - @JsonKey( - {{#defaultValue}}defaultValue: {{{.}}},{{/defaultValue}}{{^defaultValue}}nullable: {{isNullable}},{{/defaultValue}} - name: r'{{{baseName}}}', - required: {{#required}}true{{/required}}{{^required}}false{{/required}}, - ) - {{/isBinary}} - {{#isBinary}} - @JsonKey(ignore: true) - {{/isBinary}} - {{{datatypeWithEnum}}} {{{name}}}; - -{{/vars}} - @override - bool operator ==(Object other) => identical(this, other) || other is {{{classname}}} && - {{#vars}} - other.{{{name}}} == {{{name}}}{{^-last}} &&{{/-last}}{{#-last}};{{/-last}} - {{/vars}} - - @override - int get hashCode => - {{#vars}} - ({{{name}}} == null ? 0 : {{{name}}}.hashCode){{^-last}} +{{/-last}}{{#-last}};{{/-last}} - {{/vars}} - - factory {{{classname}}}.fromJson(Map json) => _${{{classname}}}FromJson(json); - - Map toJson() => _${{{classname}}}ToJson(this); - - @override - String toString() => toJson().toString(); -} -{{#vars}} - {{#isEnum}} - {{^isContainer}} - -{{>serialization/json_serializable/json_serializable_enum_inline}} - {{/isContainer}} - {{#isContainer}} - {{#mostInnerItems}} - -{{>serialization/json_serializable/json_serializable_enum_inline}} - {{/mostInnerItems}} - {{/isContainer}} - {{/isEnum}} -{{/vars}} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum.mustache b/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum.mustache deleted file mode 100644 index 3fe458ab91f6..000000000000 --- a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum.mustache +++ /dev/null @@ -1,7 +0,0 @@ -enum {{{classname}}} { -{{#allowableValues}} -{{#enumVars}} - {{{name}}}, -{{/enumVars}} -{{/allowableValues}} -} \ No newline at end of file diff --git a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum_inline.mustache b/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum_inline.mustache deleted file mode 100644 index 6e9f9016750b..000000000000 --- a/modules/openapi-generator/src/main/resources/dart2/serialization/json_serializable/json_serializable_enum_inline.mustache +++ /dev/null @@ -1,8 +0,0 @@ -{{#description}}/// {{{.}}}{{/description}} -enum {{{enumName}}} { -{{#allowableValues}} -{{#enumVars}} - {{{name}}}, -{{/enumVars}} -{{/allowableValues}} -} \ No newline at end of file diff --git a/pom.xml b/pom.xml index 540b8505cd7d..63e68566c634 100644 --- a/pom.xml +++ b/pom.xml @@ -1413,7 +1413,6 @@ samples/openapi3/client/petstore/dart2/petstore_client_lib samples/openapi3/client/petstore/dart2/petstore - samples/openapi3/client/petstore/dart-dio-next/petstore_client_lib_fake samples/openapi3/client/petstore/dart-dio-next/dio_http_petstore_client_lib_fake diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/pet_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/pet_api.dart index 2b7e10416d27..5b299b6b2cdb 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/pet_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/pet_api.dart @@ -72,7 +72,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Pet',) as Pet; - } + + } return Future.value(); } @@ -203,6 +204,7 @@ class PetApi { return (await apiClient.deserializeAsync(responseBody, 'List') as List) .cast() .toList(growable: false); + } return Future>.value(); } @@ -272,6 +274,7 @@ class PetApi { return (await apiClient.deserializeAsync(responseBody, 'List') as List) .cast() .toList(growable: false); + } return Future>.value(); } @@ -337,7 +340,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Pet',) as Pet; - } + + } return Future.value(); } @@ -397,7 +401,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Pet',) as Pet; - } + + } return Future.value(); } @@ -556,7 +561,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ApiResponse',) as ApiResponse; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/store_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/store_api.dart index 9a02b1f95106..0c5c49a95541 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/store_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/store_api.dart @@ -119,6 +119,7 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return Map.from(await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Map'),); + } return Future>.value(); } @@ -184,7 +185,8 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Order',) as Order; - } + + } return Future.value(); } @@ -244,7 +246,8 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Order',) as Order; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/user_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/user_api.dart index 22f0fb7b25f2..3d30943890f1 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/user_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib/lib/api/user_api.dart @@ -294,7 +294,8 @@ class UserApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'User',) as User; - } + + } return Future.value(); } @@ -366,7 +367,8 @@ class UserApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'String',) as String; - } + + } return Future.value(); } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib/pubspec.yaml b/samples/openapi3/client/petstore/dart2/petstore_client_lib/pubspec.yaml index 163b29ec3ecc..00043ba660cd 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib/pubspec.yaml +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib/pubspec.yaml @@ -12,7 +12,5 @@ dependencies: http: '>=0.13.0 <0.14.0' intl: '^0.17.0' meta: '^1.1.8' - dev_dependencies: test: '>=1.16.0 <1.18.0' - diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/another_fake_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/another_fake_api.dart index e74ea06483b1..61a4d7786677 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/another_fake_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/another_fake_api.dart @@ -76,7 +76,8 @@ class AnotherFakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ModelClient',) as ModelClient; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/default_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/default_api.dart index 1f3eca5bc847..15119087b633 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/default_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/default_api.dart @@ -54,7 +54,8 @@ class DefaultApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'InlineResponseDefault',) as InlineResponseDefault; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_api.dart index 33c432434040..5ffad95f3b68 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_api.dart @@ -57,7 +57,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'HealthCheckResult',) as HealthCheckResult; - } + + } return Future.value(); } @@ -187,7 +188,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'bool',) as bool; - } + + } return Future.value(); } @@ -244,7 +246,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'OuterComposite',) as OuterComposite; - } + + } return Future.value(); } @@ -301,7 +304,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'num',) as num; - } + + } return Future.value(); } @@ -358,7 +362,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'String',) as String; - } + + } return Future.value(); } @@ -418,7 +423,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'OuterObjectWithEnumProperty',) as OuterObjectWithEnumProperty; - } + + } return Future.value(); } @@ -641,7 +647,8 @@ class FakeApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ModelClient',) as ModelClient; - } + + } return Future.value(); } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_classname_tags123_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_classname_tags123_api.dart index 9f92e00b7bd7..8686e9e7bab5 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_classname_tags123_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/fake_classname_tags123_api.dart @@ -76,7 +76,8 @@ class FakeClassnameTags123Api { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ModelClient',) as ModelClient; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/pet_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/pet_api.dart index b9217fef597b..8cfcf9eb9a09 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/pet_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/pet_api.dart @@ -196,6 +196,7 @@ class PetApi { return (await apiClient.deserializeAsync(responseBody, 'List') as List) .cast() .toList(growable: false); + } return Future>.value(); } @@ -265,6 +266,7 @@ class PetApi { return (await apiClient.deserializeAsync(responseBody, 'Set') as List) .cast() .toSet(); + } return Future>.value(); } @@ -330,7 +332,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Pet',) as Pet; - } + + } return Future.value(); } @@ -542,7 +545,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ApiResponse',) as ApiResponse; - } + + } return Future.value(); } @@ -632,7 +636,8 @@ class PetApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'ApiResponse',) as ApiResponse; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/store_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/store_api.dart index 2137c99ba85f..121f16a9f90d 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/store_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/store_api.dart @@ -119,6 +119,7 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return Map.from(await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Map'),); + } return Future>.value(); } @@ -184,7 +185,8 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Order',) as Order; - } + + } return Future.value(); } @@ -244,7 +246,8 @@ class StoreApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'Order',) as Order; - } + + } return Future.value(); } } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/user_api.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/user_api.dart index ceecb982903e..9838b689d7a7 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/user_api.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api/user_api.dart @@ -294,7 +294,8 @@ class UserApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'User',) as User; - } + + } return Future.value(); } @@ -366,7 +367,8 @@ class UserApi { // FormatException when trying to decode an empty string. if (response.body != null && response.statusCode != HttpStatus.noContent) { return await apiClient.deserializeAsync(await _decodeBodyBytes(response), 'String',) as String; - } + + } return Future.value(); } diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api_client.dart b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api_client.dart index ed19ac296344..d3c64b9adc3c 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api_client.dart +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/lib/api_client.dart @@ -229,7 +229,6 @@ class ApiClient { return EnumArrays.fromJson(value); case 'EnumClass': return EnumClassTypeTransformer().decode(value); - case 'EnumTest': return EnumTest.fromJson(value); case 'FileSchemaTestClass': @@ -272,16 +271,12 @@ class ApiClient { return OuterComposite.fromJson(value); case 'OuterEnum': return OuterEnumTypeTransformer().decode(value); - case 'OuterEnumDefaultValue': return OuterEnumDefaultValueTypeTransformer().decode(value); - case 'OuterEnumInteger': return OuterEnumIntegerTypeTransformer().decode(value); - case 'OuterEnumIntegerDefaultValue': return OuterEnumIntegerDefaultValueTypeTransformer().decode(value); - case 'OuterObjectWithEnumProperty': return OuterObjectWithEnumProperty.fromJson(value); case 'Pet': diff --git a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/pubspec.yaml b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/pubspec.yaml index 163b29ec3ecc..00043ba660cd 100644 --- a/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/pubspec.yaml +++ b/samples/openapi3/client/petstore/dart2/petstore_client_lib_fake/pubspec.yaml @@ -12,7 +12,5 @@ dependencies: http: '>=0.13.0 <0.14.0' intl: '^0.17.0' meta: '^1.1.8' - dev_dependencies: test: '>=1.16.0 <1.18.0' - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.gitignore b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.gitignore deleted file mode 100644 index 8b7331fd822c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.gitignore +++ /dev/null @@ -1,27 +0,0 @@ -# See https://www.dartlang.org/tools/private-files.html - -# Files and directories created by pub -.buildlog -.packages -.project -.pub/ -build/ -**/packages/ - -# Files created by dart2js -# (Most Dart developers will use pub build to compile Dart, use/modify these -# rules if you intend to use dart2js directly -# Convention is to use extension '.dart.js' for Dart compiled to Javascript to -# differentiate from explicit Javascript files) -*.dart.js -*.part.js -*.js.deps -*.js.map -*.info.json - -# Directory created by dartdoc -doc/api/ - -# Don't commit pubspec lock file -# (Library packages only! Remove pattern if developing an application package) -pubspec.lock diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator-ignore b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator-ignore deleted file mode 100644 index 7484ee590a38..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator-ignore +++ /dev/null @@ -1,23 +0,0 @@ -# OpenAPI Generator Ignore -# Generated by openapi-generator https://github.com/openapitools/openapi-generator - -# Use this file to prevent files from being overwritten by the generator. -# The patterns follow closely to .gitignore or .dockerignore. - -# As an example, the C# client generator defines ApiClient.cs. -# You can make changes and tell OpenAPI Generator to ignore just this file by uncommenting the following line: -#ApiClient.cs - -# You can match any string of characters against a directory, file or extension with a single asterisk (*): -#foo/*/qux -# The above matches foo/bar/qux and foo/baz/qux, but not foo/bar/baz/qux - -# You can recursively match patterns against a directory, file or extension with a double asterisk (**): -#foo/**/qux -# This matches foo/bar/qux, foo/baz/qux, and foo/bar/baz/qux - -# You can also negate patterns with an exclamation (!). -# For example, you can ignore all files in a docs folder with the file extension .md: -#docs/*.md -# Then explicitly reverse the ignore rule for a single file: -#!docs/README.md diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/FILES b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/FILES deleted file mode 100644 index f944df3328e1..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/FILES +++ /dev/null @@ -1,122 +0,0 @@ -.gitignore -.travis.yml -README.md -analysis_options.yaml -build.yaml -doc/AdditionalPropertiesClass.md -doc/Animal.md -doc/AnotherFakeApi.md -doc/ApiResponse.md -doc/ArrayOfArrayOfNumberOnly.md -doc/ArrayOfNumberOnly.md -doc/ArrayTest.md -doc/Capitalization.md -doc/Cat.md -doc/CatAllOf.md -doc/Category.md -doc/ClassModel.md -doc/DefaultApi.md -doc/DeprecatedObject.md -doc/Dog.md -doc/DogAllOf.md -doc/EnumArrays.md -doc/EnumClass.md -doc/EnumTest.md -doc/FakeApi.md -doc/FakeClassnameTags123Api.md -doc/FileSchemaTestClass.md -doc/Foo.md -doc/FormatTest.md -doc/HasOnlyReadOnly.md -doc/HealthCheckResult.md -doc/InlineResponseDefault.md -doc/MapTest.md -doc/MixedPropertiesAndAdditionalPropertiesClass.md -doc/Model200Response.md -doc/ModelClient.md -doc/ModelFile.md -doc/ModelList.md -doc/ModelReturn.md -doc/Name.md -doc/NullableClass.md -doc/NumberOnly.md -doc/ObjectWithDeprecatedFields.md -doc/Order.md -doc/OuterComposite.md -doc/OuterEnum.md -doc/OuterEnumDefaultValue.md -doc/OuterEnumInteger.md -doc/OuterEnumIntegerDefaultValue.md -doc/OuterObjectWithEnumProperty.md -doc/Pet.md -doc/PetApi.md -doc/ReadOnlyFirst.md -doc/SpecialModelName.md -doc/StoreApi.md -doc/Tag.md -doc/User.md -doc/UserApi.md -git_push.sh -lib/api.dart -lib/api/another_fake_api.dart -lib/api/default_api.dart -lib/api/fake_api.dart -lib/api/fake_classname_tags123_api.dart -lib/api/pet_api.dart -lib/api/store_api.dart -lib/api/user_api.dart -lib/api_client.dart -lib/api_exception.dart -lib/api_helper.dart -lib/auth/api_key_auth.dart -lib/auth/authentication.dart -lib/auth/http_basic_auth.dart -lib/auth/http_bearer_auth.dart -lib/auth/oauth.dart -lib/model/additional_properties_class.dart -lib/model/animal.dart -lib/model/api_response.dart -lib/model/array_of_array_of_number_only.dart -lib/model/array_of_number_only.dart -lib/model/array_test.dart -lib/model/capitalization.dart -lib/model/cat.dart -lib/model/cat_all_of.dart -lib/model/category.dart -lib/model/class_model.dart -lib/model/deprecated_object.dart -lib/model/dog.dart -lib/model/dog_all_of.dart -lib/model/enum_arrays.dart -lib/model/enum_class.dart -lib/model/enum_test.dart -lib/model/file_schema_test_class.dart -lib/model/foo.dart -lib/model/format_test.dart -lib/model/has_only_read_only.dart -lib/model/health_check_result.dart -lib/model/inline_response_default.dart -lib/model/map_test.dart -lib/model/mixed_properties_and_additional_properties_class.dart -lib/model/model200_response.dart -lib/model/model_client.dart -lib/model/model_file.dart -lib/model/model_list.dart -lib/model/model_return.dart -lib/model/name.dart -lib/model/nullable_class.dart -lib/model/number_only.dart -lib/model/object_with_deprecated_fields.dart -lib/model/order.dart -lib/model/outer_composite.dart -lib/model/outer_enum.dart -lib/model/outer_enum_default_value.dart -lib/model/outer_enum_integer.dart -lib/model/outer_enum_integer_default_value.dart -lib/model/outer_object_with_enum_property.dart -lib/model/pet.dart -lib/model/read_only_first.dart -lib/model/special_model_name.dart -lib/model/tag.dart -lib/model/user.dart -pubspec.yaml diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/VERSION b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/VERSION deleted file mode 100644 index 4b448de535c7..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.openapi-generator/VERSION +++ /dev/null @@ -1 +0,0 @@ -5.3.0-SNAPSHOT \ No newline at end of file diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.travis.yml b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.travis.yml deleted file mode 100644 index 1a3af66d54c7..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/.travis.yml +++ /dev/null @@ -1,14 +0,0 @@ -# -# AUTO-GENERATED FILE, DO NOT MODIFY! -# -# https://docs.travis-ci.com/user/languages/dart/ -# -language: dart -dart: -# Install a specific stable release -- "2.2.0" -install: -- pub get - -script: -- pub run test diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/README.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/README.md deleted file mode 100644 index db2f2c26eac2..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/README.md +++ /dev/null @@ -1,193 +0,0 @@ -# openapi -This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\ - -This Dart package is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project: - -- API version: 1.0.0 -- Build package: org.openapitools.codegen.languages.DartClientCodegen - -## Requirements - -Dart 2.0 or later - -## Installation & Usage - -### Github -If this Dart package is published to Github, add the following dependency to your pubspec.yaml -``` -dependencies: - openapi: - git: https://github.com/GIT_USER_ID/GIT_REPO_ID.git -``` - -### Local -To use the package in your local drive, add the following dependency to your pubspec.yaml -``` -dependencies: - openapi: - path: /path/to/openapi -``` - -## Tests - -TODO - -## Getting Started - -Please follow the [installation procedure](#installation--usage) and then run the following: - -```dart -import 'package:openapi/api.dart'; - - -final api_instance = AnotherFakeApi(); -final modelClient = ModelClient(); // ModelClient | client model - -try { - final result = api_instance.call123testSpecialTags(modelClient); - print(result); -} catch (e) { - print('Exception when calling AnotherFakeApi->call123testSpecialTags: $e\n'); -} - -``` - -## Documentation for API Endpoints - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Class | Method | HTTP request | Description ------------- | ------------- | ------------- | ------------- -*AnotherFakeApi* | [**call123testSpecialTags**](doc//AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags -*DefaultApi* | [**fooGet**](doc//DefaultApi.md#fooget) | **GET** /foo | -*FakeApi* | [**fakeHealthGet**](doc//FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint -*FakeApi* | [**fakeHttpSignatureTest**](doc//FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication -*FakeApi* | [**fakeOuterBooleanSerialize**](doc//FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | -*FakeApi* | [**fakeOuterCompositeSerialize**](doc//FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | -*FakeApi* | [**fakeOuterNumberSerialize**](doc//FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | -*FakeApi* | [**fakeOuterStringSerialize**](doc//FakeApi.md#fakeouterstringserialize) | **POST** /fake/outer/string | -*FakeApi* | [**fakePropertyEnumIntegerSerialize**](doc//FakeApi.md#fakepropertyenumintegerserialize) | **POST** /fake/property/enum-int | -*FakeApi* | [**testBodyWithBinary**](doc//FakeApi.md#testbodywithbinary) | **PUT** /fake/body-with-binary | -*FakeApi* | [**testBodyWithFileSchema**](doc//FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | -*FakeApi* | [**testBodyWithQueryParams**](doc//FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | -*FakeApi* | [**testClientModel**](doc//FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -*FakeApi* | [**testEndpointParameters**](doc//FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -*FakeApi* | [**testEnumParameters**](doc//FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters -*FakeApi* | [**testGroupParameters**](doc//FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) -*FakeApi* | [**testInlineAdditionalProperties**](doc//FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties -*FakeApi* | [**testJsonFormData**](doc//FakeApi.md#testjsonformdata) | **GET** /fake/jsonFormData | test json serialization of form data -*FakeApi* | [**testQueryParameterCollectionFormat**](doc//FakeApi.md#testqueryparametercollectionformat) | **PUT** /fake/test-query-parameters | -*FakeClassnameTags123Api* | [**testClassname**](doc//FakeClassnameTags123Api.md#testclassname) | **PATCH** /fake_classname_test | To test class name in snake case -*PetApi* | [**addPet**](doc//PetApi.md#addpet) | **POST** /pet | Add a new pet to the store -*PetApi* | [**deletePet**](doc//PetApi.md#deletepet) | **DELETE** /pet/{petId} | Deletes a pet -*PetApi* | [**findPetsByStatus**](doc//PetApi.md#findpetsbystatus) | **GET** /pet/findByStatus | Finds Pets by status -*PetApi* | [**findPetsByTags**](doc//PetApi.md#findpetsbytags) | **GET** /pet/findByTags | Finds Pets by tags -*PetApi* | [**getPetById**](doc//PetApi.md#getpetbyid) | **GET** /pet/{petId} | Find pet by ID -*PetApi* | [**updatePet**](doc//PetApi.md#updatepet) | **PUT** /pet | Update an existing pet -*PetApi* | [**updatePetWithForm**](doc//PetApi.md#updatepetwithform) | **POST** /pet/{petId} | Updates a pet in the store with form data -*PetApi* | [**uploadFile**](doc//PetApi.md#uploadfile) | **POST** /pet/{petId}/uploadImage | uploads an image -*PetApi* | [**uploadFileWithRequiredFile**](doc//PetApi.md#uploadfilewithrequiredfile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) -*StoreApi* | [**deleteOrder**](doc//StoreApi.md#deleteorder) | **DELETE** /store/order/{order_id} | Delete purchase order by ID -*StoreApi* | [**getInventory**](doc//StoreApi.md#getinventory) | **GET** /store/inventory | Returns pet inventories by status -*StoreApi* | [**getOrderById**](doc//StoreApi.md#getorderbyid) | **GET** /store/order/{order_id} | Find purchase order by ID -*StoreApi* | [**placeOrder**](doc//StoreApi.md#placeorder) | **POST** /store/order | Place an order for a pet -*UserApi* | [**createUser**](doc//UserApi.md#createuser) | **POST** /user | Create user -*UserApi* | [**createUsersWithArrayInput**](doc//UserApi.md#createuserswitharrayinput) | **POST** /user/createWithArray | Creates list of users with given input array -*UserApi* | [**createUsersWithListInput**](doc//UserApi.md#createuserswithlistinput) | **POST** /user/createWithList | Creates list of users with given input array -*UserApi* | [**deleteUser**](doc//UserApi.md#deleteuser) | **DELETE** /user/{username} | Delete user -*UserApi* | [**getUserByName**](doc//UserApi.md#getuserbyname) | **GET** /user/{username} | Get user by user name -*UserApi* | [**loginUser**](doc//UserApi.md#loginuser) | **GET** /user/login | Logs user into the system -*UserApi* | [**logoutUser**](doc//UserApi.md#logoutuser) | **GET** /user/logout | Logs out current logged in user session -*UserApi* | [**updateUser**](doc//UserApi.md#updateuser) | **PUT** /user/{username} | Updated user - - -## Documentation For Models - - - [AdditionalPropertiesClass](doc//AdditionalPropertiesClass.md) - - [Animal](doc//Animal.md) - - [ApiResponse](doc//ApiResponse.md) - - [ArrayOfArrayOfNumberOnly](doc//ArrayOfArrayOfNumberOnly.md) - - [ArrayOfNumberOnly](doc//ArrayOfNumberOnly.md) - - [ArrayTest](doc//ArrayTest.md) - - [Capitalization](doc//Capitalization.md) - - [Cat](doc//Cat.md) - - [CatAllOf](doc//CatAllOf.md) - - [Category](doc//Category.md) - - [ClassModel](doc//ClassModel.md) - - [DeprecatedObject](doc//DeprecatedObject.md) - - [Dog](doc//Dog.md) - - [DogAllOf](doc//DogAllOf.md) - - [EnumArrays](doc//EnumArrays.md) - - [EnumClass](doc//EnumClass.md) - - [EnumTest](doc//EnumTest.md) - - [FileSchemaTestClass](doc//FileSchemaTestClass.md) - - [Foo](doc//Foo.md) - - [FormatTest](doc//FormatTest.md) - - [HasOnlyReadOnly](doc//HasOnlyReadOnly.md) - - [HealthCheckResult](doc//HealthCheckResult.md) - - [InlineResponseDefault](doc//InlineResponseDefault.md) - - [MapTest](doc//MapTest.md) - - [MixedPropertiesAndAdditionalPropertiesClass](doc//MixedPropertiesAndAdditionalPropertiesClass.md) - - [Model200Response](doc//Model200Response.md) - - [ModelClient](doc//ModelClient.md) - - [ModelFile](doc//ModelFile.md) - - [ModelList](doc//ModelList.md) - - [ModelReturn](doc//ModelReturn.md) - - [Name](doc//Name.md) - - [NullableClass](doc//NullableClass.md) - - [NumberOnly](doc//NumberOnly.md) - - [ObjectWithDeprecatedFields](doc//ObjectWithDeprecatedFields.md) - - [Order](doc//Order.md) - - [OuterComposite](doc//OuterComposite.md) - - [OuterEnum](doc//OuterEnum.md) - - [OuterEnumDefaultValue](doc//OuterEnumDefaultValue.md) - - [OuterEnumInteger](doc//OuterEnumInteger.md) - - [OuterEnumIntegerDefaultValue](doc//OuterEnumIntegerDefaultValue.md) - - [OuterObjectWithEnumProperty](doc//OuterObjectWithEnumProperty.md) - - [Pet](doc//Pet.md) - - [ReadOnlyFirst](doc//ReadOnlyFirst.md) - - [SpecialModelName](doc//SpecialModelName.md) - - [Tag](doc//Tag.md) - - [User](doc//User.md) - - -## Documentation For Authorization - - -## api_key - -- **Type**: API key -- **API key parameter name**: api_key -- **Location**: HTTP header - -## api_key_query - -- **Type**: API key -- **API key parameter name**: api_key_query -- **Location**: URL query string - -## bearer_test - -- **Type**: HTTP Bearer authentication - -## http_basic_test - -- **Type**: HTTP Basic authentication - -## http_signature_test - - -## petstore_auth - -- **Type**: OAuth -- **Flow**: implicit -- **Authorization URL**: http://petstore.swagger.io/api/oauth/dialog -- **Scopes**: - - **write:pets**: modify pets in your account - - **read:pets**: read your pets - - -## Author - - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/analysis_options.yaml b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/analysis_options.yaml deleted file mode 100644 index e69de29bb2d1..000000000000 diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/build.yaml b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/build.yaml deleted file mode 100644 index 89a4dd6e1c2e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/build.yaml +++ /dev/null @@ -1,18 +0,0 @@ -targets: - $default: - builders: - json_serializable: - options: - # Options configure how source code is generated for every - # `@JsonSerializable`-annotated class in the package. - # - # The default value for each is listed. - any_map: false - checked: true - create_factory: true - create_to_json: true - disallow_unrecognized_keys: true - explicit_to_json: true - field_rename: none - ignore_unannotated: false - include_if_null: false diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AdditionalPropertiesClass.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AdditionalPropertiesClass.md deleted file mode 100644 index 859d4d0b7a0c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AdditionalPropertiesClass.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.AdditionalPropertiesClass - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**mapProperty** | **Map** | | [optional] [default to const {}] -**mapOfMapProperty** | [**Map>**](Map.md) | | [optional] [default to const {}] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Animal.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Animal.md deleted file mode 100644 index 415b56e9bc2e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Animal.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.Animal - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**className** | **String** | | -**color** | **String** | | [optional] [default to 'red'] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AnotherFakeApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AnotherFakeApi.md deleted file mode 100644 index 241c82e575d4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/AnotherFakeApi.md +++ /dev/null @@ -1,57 +0,0 @@ -# openapi.api.AnotherFakeApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**call123testSpecialTags**](AnotherFakeApi.md#call123testspecialtags) | **PATCH** /another-fake/dummy | To test special tags - - -# **call123testSpecialTags** -> ModelClient call123testSpecialTags(modelClient) - -To test special tags - -To test special tags and operation ID starting with number - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = AnotherFakeApi(); -final modelClient = ModelClient(); // ModelClient | client model - -try { - final result = api_instance.call123testSpecialTags(modelClient); - print(result); -} catch (e) { - print('Exception when calling AnotherFakeApi->call123testSpecialTags: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **modelClient** | [**ModelClient**](ModelClient.md)| client model | - -### Return type - -[**ModelClient**](ModelClient.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ApiResponse.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ApiResponse.md deleted file mode 100644 index 7ad5da0f89e4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ApiResponse.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.ApiResponse - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**code** | **int** | | [optional] -**type** | **String** | | [optional] -**message** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfArrayOfNumberOnly.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfArrayOfNumberOnly.md deleted file mode 100644 index 0a0dc2a7b752..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfArrayOfNumberOnly.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ArrayOfArrayOfNumberOnly - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**arrayArrayNumber** | [**List>**](List.md) | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfNumberOnly.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfNumberOnly.md deleted file mode 100644 index 01b6f58870ff..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayOfNumberOnly.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ArrayOfNumberOnly - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**arrayNumber** | **List** | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayTest.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayTest.md deleted file mode 100644 index 598a895bb209..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ArrayTest.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.ArrayTest - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**arrayOfString** | **List** | | [optional] [default to const []] -**arrayArrayOfInteger** | [**List>**](List.md) | | [optional] [default to const []] -**arrayArrayOfModel** | [**List>**](List.md) | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Capitalization.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Capitalization.md deleted file mode 100644 index 4a07b4eb820d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Capitalization.md +++ /dev/null @@ -1,20 +0,0 @@ -# openapi.model.Capitalization - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**smallCamel** | **String** | | [optional] -**capitalCamel** | **String** | | [optional] -**smallSnake** | **String** | | [optional] -**capitalSnake** | **String** | | [optional] -**sCAETHFlowPoints** | **String** | | [optional] -**ATT_NAME** | **String** | Name of the pet | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Cat.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Cat.md deleted file mode 100644 index 6552eea4b435..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Cat.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.Cat - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**className** | **String** | | -**color** | **String** | | [optional] [default to 'red'] -**declawed** | **bool** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/CatAllOf.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/CatAllOf.md deleted file mode 100644 index 36b2ae0e8ab3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/CatAllOf.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.CatAllOf - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**declawed** | **bool** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Category.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Category.md deleted file mode 100644 index ae6bc52e89d8..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Category.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.Category - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **int** | | [optional] -**name** | **String** | | [default to 'default-name'] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ClassModel.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ClassModel.md deleted file mode 100644 index 13ae5d3a4708..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ClassModel.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ClassModel - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**class_** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DefaultApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DefaultApi.md deleted file mode 100644 index d7b1c748f14e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DefaultApi.md +++ /dev/null @@ -1,51 +0,0 @@ -# openapi.api.DefaultApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**fooGet**](DefaultApi.md#fooget) | **GET** /foo | - - -# **fooGet** -> InlineResponseDefault fooGet() - - - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = DefaultApi(); - -try { - final result = api_instance.fooGet(); - print(result); -} catch (e) { - print('Exception when calling DefaultApi->fooGet: $e\n'); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**InlineResponseDefault**](InlineResponseDefault.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DeprecatedObject.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DeprecatedObject.md deleted file mode 100644 index bf2ef67a26fc..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DeprecatedObject.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.DeprecatedObject - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Dog.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Dog.md deleted file mode 100644 index d36439b767bb..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Dog.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.Dog - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**className** | **String** | | -**color** | **String** | | [optional] [default to 'red'] -**breed** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DogAllOf.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DogAllOf.md deleted file mode 100644 index 97a7c8fba492..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/DogAllOf.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.DogAllOf - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**breed** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumArrays.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumArrays.md deleted file mode 100644 index 2c12a0e6168d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumArrays.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.EnumArrays - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**justSymbol** | **String** | | [optional] -**arrayEnum** | **List** | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumClass.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumClass.md deleted file mode 100644 index a9ed4c1f0c8b..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumClass.md +++ /dev/null @@ -1,14 +0,0 @@ -# openapi.model.EnumClass - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumTest.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumTest.md deleted file mode 100644 index 7c24fe2347b4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/EnumTest.md +++ /dev/null @@ -1,22 +0,0 @@ -# openapi.model.EnumTest - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**enumString** | **String** | | [optional] -**enumStringRequired** | **String** | | -**enumInteger** | **int** | | [optional] -**enumNumber** | **double** | | [optional] -**outerEnum** | [**OuterEnum**](OuterEnum.md) | | [optional] -**outerEnumInteger** | [**OuterEnumInteger**](OuterEnumInteger.md) | | [optional] -**outerEnumDefaultValue** | [**OuterEnumDefaultValue**](OuterEnumDefaultValue.md) | | [optional] -**outerEnumIntegerDefaultValue** | [**OuterEnumIntegerDefaultValue**](OuterEnumIntegerDefaultValue.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeApi.md deleted file mode 100644 index 869c513b1f26..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeApi.md +++ /dev/null @@ -1,816 +0,0 @@ -# openapi.api.FakeApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**fakeHealthGet**](FakeApi.md#fakehealthget) | **GET** /fake/health | Health check endpoint -[**fakeHttpSignatureTest**](FakeApi.md#fakehttpsignaturetest) | **GET** /fake/http-signature-test | test http signature authentication -[**fakeOuterBooleanSerialize**](FakeApi.md#fakeouterbooleanserialize) | **POST** /fake/outer/boolean | -[**fakeOuterCompositeSerialize**](FakeApi.md#fakeoutercompositeserialize) | **POST** /fake/outer/composite | -[**fakeOuterNumberSerialize**](FakeApi.md#fakeouternumberserialize) | **POST** /fake/outer/number | -[**fakeOuterStringSerialize**](FakeApi.md#fakeouterstringserialize) | **POST** /fake/outer/string | -[**fakePropertyEnumIntegerSerialize**](FakeApi.md#fakepropertyenumintegerserialize) | **POST** /fake/property/enum-int | -[**testBodyWithBinary**](FakeApi.md#testbodywithbinary) | **PUT** /fake/body-with-binary | -[**testBodyWithFileSchema**](FakeApi.md#testbodywithfileschema) | **PUT** /fake/body-with-file-schema | -[**testBodyWithQueryParams**](FakeApi.md#testbodywithqueryparams) | **PUT** /fake/body-with-query-params | -[**testClientModel**](FakeApi.md#testclientmodel) | **PATCH** /fake | To test \"client\" model -[**testEndpointParameters**](FakeApi.md#testendpointparameters) | **POST** /fake | Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 -[**testEnumParameters**](FakeApi.md#testenumparameters) | **GET** /fake | To test enum parameters -[**testGroupParameters**](FakeApi.md#testgroupparameters) | **DELETE** /fake | Fake endpoint to test group parameters (optional) -[**testInlineAdditionalProperties**](FakeApi.md#testinlineadditionalproperties) | **POST** /fake/inline-additionalProperties | test inline additionalProperties -[**testJsonFormData**](FakeApi.md#testjsonformdata) | **GET** /fake/jsonFormData | test json serialization of form data -[**testQueryParameterCollectionFormat**](FakeApi.md#testqueryparametercollectionformat) | **PUT** /fake/test-query-parameters | - - -# **fakeHealthGet** -> HealthCheckResult fakeHealthGet() - -Health check endpoint - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); - -try { - final result = api_instance.fakeHealthGet(); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakeHealthGet: $e\n'); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -[**HealthCheckResult**](HealthCheckResult.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakeHttpSignatureTest** -> fakeHttpSignatureTest(pet, query1, header1) - -test http signature authentication - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final pet = Pet(); // Pet | Pet object that needs to be added to the store -final query1 = query1_example; // String | query parameter -final header1 = header1_example; // String | header parameter - -try { - api_instance.fakeHttpSignatureTest(pet, query1, header1); -} catch (e) { - print('Exception when calling FakeApi->fakeHttpSignatureTest: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | - **query1** | **String**| query parameter | [optional] - **header1** | **String**| header parameter | [optional] - -### Return type - -void (empty response body) - -### Authorization - -[http_signature_test](../README.md#http_signature_test) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakeOuterBooleanSerialize** -> bool fakeOuterBooleanSerialize(body) - - - -Test serialization of outer boolean types - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final body = bool(); // bool | Input boolean as post body - -try { - final result = api_instance.fakeOuterBooleanSerialize(body); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakeOuterBooleanSerialize: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **bool**| Input boolean as post body | [optional] - -### Return type - -**bool** - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: */* - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakeOuterCompositeSerialize** -> OuterComposite fakeOuterCompositeSerialize(outerComposite) - - - -Test serialization of object with outer number type - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final outerComposite = OuterComposite(); // OuterComposite | Input composite as post body - -try { - final result = api_instance.fakeOuterCompositeSerialize(outerComposite); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakeOuterCompositeSerialize: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **outerComposite** | [**OuterComposite**](OuterComposite.md)| Input composite as post body | [optional] - -### Return type - -[**OuterComposite**](OuterComposite.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: */* - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakeOuterNumberSerialize** -> num fakeOuterNumberSerialize(body) - - - -Test serialization of outer number types - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final body = num(); // num | Input number as post body - -try { - final result = api_instance.fakeOuterNumberSerialize(body); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakeOuterNumberSerialize: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **num**| Input number as post body | [optional] - -### Return type - -**num** - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: */* - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakeOuterStringSerialize** -> String fakeOuterStringSerialize(body) - - - -Test serialization of outer string types - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final body = String(); // String | Input string as post body - -try { - final result = api_instance.fakeOuterStringSerialize(body); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakeOuterStringSerialize: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **String**| Input string as post body | [optional] - -### Return type - -**String** - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: */* - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **fakePropertyEnumIntegerSerialize** -> OuterObjectWithEnumProperty fakePropertyEnumIntegerSerialize(outerObjectWithEnumProperty) - - - -Test serialization of enum (int) properties with examples - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final outerObjectWithEnumProperty = OuterObjectWithEnumProperty(); // OuterObjectWithEnumProperty | Input enum (int) as post body - -try { - final result = api_instance.fakePropertyEnumIntegerSerialize(outerObjectWithEnumProperty); - print(result); -} catch (e) { - print('Exception when calling FakeApi->fakePropertyEnumIntegerSerialize: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **outerObjectWithEnumProperty** | [**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md)| Input enum (int) as post body | - -### Return type - -[**OuterObjectWithEnumProperty**](OuterObjectWithEnumProperty.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: */* - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testBodyWithBinary** -> testBodyWithBinary(body) - - - -For this test, the body has to be a binary file. - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final body = MultipartFile(); // MultipartFile | image to upload - -try { - api_instance.testBodyWithBinary(body); -} catch (e) { - print('Exception when calling FakeApi->testBodyWithBinary: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **body** | **MultipartFile**| image to upload | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: image/png - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testBodyWithFileSchema** -> testBodyWithFileSchema(fileSchemaTestClass) - - - -For this test, the body for this request must reference a schema named `File`. - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final fileSchemaTestClass = FileSchemaTestClass(); // FileSchemaTestClass | - -try { - api_instance.testBodyWithFileSchema(fileSchemaTestClass); -} catch (e) { - print('Exception when calling FakeApi->testBodyWithFileSchema: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **fileSchemaTestClass** | [**FileSchemaTestClass**](FileSchemaTestClass.md)| | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testBodyWithQueryParams** -> testBodyWithQueryParams(query, user) - - - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final query = query_example; // String | -final user = User(); // User | - -try { - api_instance.testBodyWithQueryParams(query, user); -} catch (e) { - print('Exception when calling FakeApi->testBodyWithQueryParams: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **query** | **String**| | - **user** | [**User**](User.md)| | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testClientModel** -> ModelClient testClientModel(modelClient) - -To test \"client\" model - -To test \"client\" model - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final modelClient = ModelClient(); // ModelClient | client model - -try { - final result = api_instance.testClientModel(modelClient); - print(result); -} catch (e) { - print('Exception when calling FakeApi->testClientModel: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **modelClient** | [**ModelClient**](ModelClient.md)| client model | - -### Return type - -[**ModelClient**](ModelClient.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testEndpointParameters** -> testEndpointParameters(number, double_, patternWithoutDelimiter, byte, integer, int32, int64, float, string, binary, date, dateTime, password, callback) - -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - -Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure HTTP basic authorization: http_basic_test -//defaultApiClient.getAuthentication('http_basic_test').username = 'YOUR_USERNAME' -//defaultApiClient.getAuthentication('http_basic_test').password = 'YOUR_PASSWORD'; - -final api_instance = FakeApi(); -final number = 8.14; // num | None -final double_ = 1.2; // double | None -final patternWithoutDelimiter = patternWithoutDelimiter_example; // String | None -final byte = BYTE_ARRAY_DATA_HERE; // String | None -final integer = 56; // int | None -final int32 = 56; // int | None -final int64 = 789; // int | None -final float = 3.4; // double | None -final string = string_example; // String | None -final binary = BINARY_DATA_HERE; // MultipartFile | None -final date = 2013-10-20; // DateTime | None -final dateTime = 2013-10-20T19:20:30+01:00; // DateTime | None -final password = password_example; // String | None -final callback = callback_example; // String | None - -try { - api_instance.testEndpointParameters(number, double_, patternWithoutDelimiter, byte, integer, int32, int64, float, string, binary, date, dateTime, password, callback); -} catch (e) { - print('Exception when calling FakeApi->testEndpointParameters: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **number** | **num**| None | - **double_** | **double**| None | - **patternWithoutDelimiter** | **String**| None | - **byte** | **String**| None | - **integer** | **int**| None | [optional] - **int32** | **int**| None | [optional] - **int64** | **int**| None | [optional] - **float** | **double**| None | [optional] - **string** | **String**| None | [optional] - **binary** | **MultipartFile**| None | [optional] - **date** | **DateTime**| None | [optional] - **dateTime** | **DateTime**| None | [optional] - **password** | **String**| None | [optional] - **callback** | **String**| None | [optional] - -### Return type - -void (empty response body) - -### Authorization - -[http_basic_test](../README.md#http_basic_test) - -### HTTP request headers - - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testEnumParameters** -> testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString) - -To test enum parameters - -To test enum parameters - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final enumHeaderStringArray = []; // List | Header parameter enum test (string array) -final enumHeaderString = enumHeaderString_example; // String | Header parameter enum test (string) -final enumQueryStringArray = []; // List | Query parameter enum test (string array) -final enumQueryString = enumQueryString_example; // String | Query parameter enum test (string) -final enumQueryInteger = 56; // int | Query parameter enum test (double) -final enumQueryDouble = 1.2; // double | Query parameter enum test (double) -final enumFormStringArray = []; // List | Form parameter enum test (string array) -final enumFormString = enumFormString_example; // String | Form parameter enum test (string) - -try { - api_instance.testEnumParameters(enumHeaderStringArray, enumHeaderString, enumQueryStringArray, enumQueryString, enumQueryInteger, enumQueryDouble, enumFormStringArray, enumFormString); -} catch (e) { - print('Exception when calling FakeApi->testEnumParameters: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **enumHeaderStringArray** | [**List**](String.md)| Header parameter enum test (string array) | [optional] [default to const []] - **enumHeaderString** | **String**| Header parameter enum test (string) | [optional] [default to '-efg'] - **enumQueryStringArray** | [**List**](String.md)| Query parameter enum test (string array) | [optional] [default to const []] - **enumQueryString** | **String**| Query parameter enum test (string) | [optional] [default to '-efg'] - **enumQueryInteger** | **int**| Query parameter enum test (double) | [optional] - **enumQueryDouble** | **double**| Query parameter enum test (double) | [optional] - **enumFormStringArray** | [**List**](String.md)| Form parameter enum test (string array) | [optional] [default to '$'] - **enumFormString** | **String**| Form parameter enum test (string) | [optional] [default to '-efg'] - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testGroupParameters** -> testGroupParameters(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup, booleanGroup, int64Group) - -Fake endpoint to test group parameters (optional) - -Fake endpoint to test group parameters (optional) - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure HTTP Bearer authorization: bearer_test -// Case 1. Use String Token -//defaultApiClient.getAuthentication('bearer_test').setAccessToken('YOUR_ACCESS_TOKEN'); -// Case 2. Use Function which generate token. -// String yourTokenGeneratorFunction() { ... } -//defaultApiClient.getAuthentication('bearer_test').setAccessToken(yourTokenGeneratorFunction); - -final api_instance = FakeApi(); -final requiredStringGroup = 56; // int | Required String in group parameters -final requiredBooleanGroup = true; // bool | Required Boolean in group parameters -final requiredInt64Group = 789; // int | Required Integer in group parameters -final stringGroup = 56; // int | String in group parameters -final booleanGroup = true; // bool | Boolean in group parameters -final int64Group = 789; // int | Integer in group parameters - -try { - api_instance.testGroupParameters(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup, booleanGroup, int64Group); -} catch (e) { - print('Exception when calling FakeApi->testGroupParameters: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **requiredStringGroup** | **int**| Required String in group parameters | - **requiredBooleanGroup** | **bool**| Required Boolean in group parameters | - **requiredInt64Group** | **int**| Required Integer in group parameters | - **stringGroup** | **int**| String in group parameters | [optional] - **booleanGroup** | **bool**| Boolean in group parameters | [optional] - **int64Group** | **int**| Integer in group parameters | [optional] - -### Return type - -void (empty response body) - -### Authorization - -[bearer_test](../README.md#bearer_test) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testInlineAdditionalProperties** -> testInlineAdditionalProperties(requestBody) - -test inline additionalProperties - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final requestBody = Map(); // Map | request body - -try { - api_instance.testInlineAdditionalProperties(requestBody); -} catch (e) { - print('Exception when calling FakeApi->testInlineAdditionalProperties: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **requestBody** | [**Map**](String.md)| request body | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testJsonFormData** -> testJsonFormData(param, param2) - -test json serialization of form data - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final param = param_example; // String | field1 -final param2 = param2_example; // String | field2 - -try { - api_instance.testJsonFormData(param, param2); -} catch (e) { - print('Exception when calling FakeApi->testJsonFormData: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **param** | **String**| field1 | - **param2** | **String**| field2 | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **testQueryParameterCollectionFormat** -> testQueryParameterCollectionFormat(pipe, ioutil, http, url, context, allowEmpty, language) - - - -To test the collection format in query parameters - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = FakeApi(); -final pipe = []; // List | -final ioutil = []; // List | -final http = []; // List | -final url = []; // List | -final context = []; // List | -final allowEmpty = allowEmpty_example; // String | -final language = ; // Map | - -try { - api_instance.testQueryParameterCollectionFormat(pipe, ioutil, http, url, context, allowEmpty, language); -} catch (e) { - print('Exception when calling FakeApi->testQueryParameterCollectionFormat: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pipe** | [**List**](String.md)| | [default to const []] - **ioutil** | [**List**](String.md)| | [default to const []] - **http** | [**List**](String.md)| | [default to const []] - **url** | [**List**](String.md)| | [default to const []] - **context** | [**List**](String.md)| | [default to const []] - **allowEmpty** | **String**| | - **language** | [**Map**](String.md)| | [optional] [default to const {}] - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeClassnameTags123Api.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeClassnameTags123Api.md deleted file mode 100644 index 5518c67403ff..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FakeClassnameTags123Api.md +++ /dev/null @@ -1,61 +0,0 @@ -# openapi.api.FakeClassnameTags123Api - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**testClassname**](FakeClassnameTags123Api.md#testclassname) | **PATCH** /fake_classname_test | To test class name in snake case - - -# **testClassname** -> ModelClient testClassname(modelClient) - -To test class name in snake case - -To test class name in snake case - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure API key authorization: api_key_query -//defaultApiClient.getAuthentication('api_key_query').apiKey = 'YOUR_API_KEY'; -// uncomment below to setup prefix (e.g. Bearer) for API key, if needed -//defaultApiClient.getAuthentication('api_key_query').apiKeyPrefix = 'Bearer'; - -final api_instance = FakeClassnameTags123Api(); -final modelClient = ModelClient(); // ModelClient | client model - -try { - final result = api_instance.testClassname(modelClient); - print(result); -} catch (e) { - print('Exception when calling FakeClassnameTags123Api->testClassname: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **modelClient** | [**ModelClient**](ModelClient.md)| client model | - -### Return type - -[**ModelClient**](ModelClient.md) - -### Authorization - -[api_key_query](../README.md#api_key_query) - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FileSchemaTestClass.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FileSchemaTestClass.md deleted file mode 100644 index eae1dfbe979f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FileSchemaTestClass.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.FileSchemaTestClass - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**file** | [**ModelFile**](ModelFile.md) | | [optional] -**files** | [**List**](ModelFile.md) | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Foo.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Foo.md deleted file mode 100644 index 185b76e3f5b4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Foo.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.Foo - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [default to 'bar'] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FormatTest.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FormatTest.md deleted file mode 100644 index 83b60545eb61..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/FormatTest.md +++ /dev/null @@ -1,30 +0,0 @@ -# openapi.model.FormatTest - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integer** | **int** | | [optional] -**int32** | **int** | | [optional] -**int64** | **int** | | [optional] -**number** | **num** | | -**float** | **double** | | [optional] -**double_** | **double** | | [optional] -**decimal** | **double** | | [optional] -**string** | **String** | | [optional] -**byte** | **String** | | -**binary** | [**MultipartFile**](MultipartFile.md) | | [optional] -**date** | [**DateTime**](DateTime.md) | | -**dateTime** | [**DateTime**](DateTime.md) | | [optional] -**uuid** | **String** | | [optional] -**password** | **String** | | -**patternWithDigits** | **String** | A string that is a 10 digit number. Can have leading zeros. | [optional] -**patternWithDigitsAndDelimiter** | **String** | A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HasOnlyReadOnly.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HasOnlyReadOnly.md deleted file mode 100644 index f2d30e9fb688..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HasOnlyReadOnly.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.HasOnlyReadOnly - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**foo** | **String** | | [optional] [readonly] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HealthCheckResult.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HealthCheckResult.md deleted file mode 100644 index 4d6aeb75d965..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/HealthCheckResult.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.HealthCheckResult - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**nullableMessage** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/InlineResponseDefault.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/InlineResponseDefault.md deleted file mode 100644 index c5e61e1162bf..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/InlineResponseDefault.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.InlineResponseDefault - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**string** | [**Foo**](Foo.md) | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MapTest.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MapTest.md deleted file mode 100644 index a1732207bfc9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MapTest.md +++ /dev/null @@ -1,18 +0,0 @@ -# openapi.model.MapTest - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**mapMapOfString** | [**Map>**](Map.md) | | [optional] [default to const {}] -**mapOfEnumString** | **Map** | | [optional] [default to const {}] -**directMap** | **Map** | | [optional] [default to const {}] -**indirectMap** | **Map** | | [optional] [default to const {}] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MixedPropertiesAndAdditionalPropertiesClass.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MixedPropertiesAndAdditionalPropertiesClass.md deleted file mode 100644 index 1f7f66b684fd..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/MixedPropertiesAndAdditionalPropertiesClass.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.MixedPropertiesAndAdditionalPropertiesClass - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**uuid** | **String** | | [optional] -**dateTime** | [**DateTime**](DateTime.md) | | [optional] -**map** | [**Map**](Animal.md) | | [optional] [default to const {}] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Model200Response.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Model200Response.md deleted file mode 100644 index 5aa3fb97c32e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Model200Response.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.Model200Response - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **int** | | [optional] -**class_** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelClient.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelClient.md deleted file mode 100644 index f7b922f4a398..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelClient.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ModelClient - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**client** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelFile.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelFile.md deleted file mode 100644 index 4be260e93f6e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelFile.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ModelFile - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**sourceURI** | **String** | Test capitalization | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelList.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelList.md deleted file mode 100644 index 283aa1f6b711..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelList.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ModelList - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**n123list** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelReturn.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelReturn.md deleted file mode 100644 index bc02df7a3692..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ModelReturn.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.ModelReturn - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**return_** | **int** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Name.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Name.md deleted file mode 100644 index 9da6e75fbf5e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Name.md +++ /dev/null @@ -1,18 +0,0 @@ -# openapi.model.Name - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**name** | **int** | | -**snakeCase** | **int** | | [optional] [readonly] -**property** | **String** | | [optional] -**n123number** | **int** | | [optional] [readonly] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NullableClass.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NullableClass.md deleted file mode 100644 index 9b2e46df0a09..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NullableClass.md +++ /dev/null @@ -1,26 +0,0 @@ -# openapi.model.NullableClass - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**integerProp** | **int** | | [optional] -**numberProp** | **num** | | [optional] -**booleanProp** | **bool** | | [optional] -**stringProp** | **String** | | [optional] -**dateProp** | [**DateTime**](DateTime.md) | | [optional] -**datetimeProp** | [**DateTime**](DateTime.md) | | [optional] -**arrayNullableProp** | [**List**](Object.md) | | [optional] [default to const []] -**arrayAndItemsNullableProp** | [**List**](Object.md) | | [optional] [default to const []] -**arrayItemsNullable** | [**List**](Object.md) | | [optional] [default to const []] -**objectNullableProp** | [**Map**](Object.md) | | [optional] [default to const {}] -**objectAndItemsNullableProp** | [**Map**](Object.md) | | [optional] [default to const {}] -**objectItemsNullable** | [**Map**](Object.md) | | [optional] [default to const {}] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NumberOnly.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NumberOnly.md deleted file mode 100644 index d8096a3db37a..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/NumberOnly.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.NumberOnly - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**justNumber** | **num** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ObjectWithDeprecatedFields.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ObjectWithDeprecatedFields.md deleted file mode 100644 index 566816d8d278..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ObjectWithDeprecatedFields.md +++ /dev/null @@ -1,18 +0,0 @@ -# openapi.model.ObjectWithDeprecatedFields - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**uuid** | **String** | | [optional] -**id** | **num** | | [optional] -**deprecatedRef** | [**DeprecatedObject**](DeprecatedObject.md) | | [optional] -**bars** | **List** | | [optional] [default to const []] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Order.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Order.md deleted file mode 100644 index bde5ffe51a2c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Order.md +++ /dev/null @@ -1,20 +0,0 @@ -# openapi.model.Order - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **int** | | [optional] -**petId** | **int** | | [optional] -**quantity** | **int** | | [optional] -**shipDate** | [**DateTime**](DateTime.md) | | [optional] -**status** | **String** | Order Status | [optional] -**complete** | **bool** | | [optional] [default to false] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterComposite.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterComposite.md deleted file mode 100644 index 04bab7eff5d1..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterComposite.md +++ /dev/null @@ -1,17 +0,0 @@ -# openapi.model.OuterComposite - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**myNumber** | **num** | | [optional] -**myString** | **String** | | [optional] -**myBoolean** | **bool** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnum.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnum.md deleted file mode 100644 index af62ad87ab2e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnum.md +++ /dev/null @@ -1,14 +0,0 @@ -# openapi.model.OuterEnum - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumDefaultValue.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumDefaultValue.md deleted file mode 100644 index c1bf8b0dec44..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumDefaultValue.md +++ /dev/null @@ -1,14 +0,0 @@ -# openapi.model.OuterEnumDefaultValue - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumInteger.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumInteger.md deleted file mode 100644 index 8c80a9e5c85f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumInteger.md +++ /dev/null @@ -1,14 +0,0 @@ -# openapi.model.OuterEnumInteger - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumIntegerDefaultValue.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumIntegerDefaultValue.md deleted file mode 100644 index eb8b55d70249..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterEnumIntegerDefaultValue.md +++ /dev/null @@ -1,14 +0,0 @@ -# openapi.model.OuterEnumIntegerDefaultValue - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterObjectWithEnumProperty.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterObjectWithEnumProperty.md deleted file mode 100644 index eab2ae8f66b4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/OuterObjectWithEnumProperty.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.OuterObjectWithEnumProperty - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**value** | [**OuterEnumInteger**](OuterEnumInteger.md) | | - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Pet.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Pet.md deleted file mode 100644 index b6fdea5299ba..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Pet.md +++ /dev/null @@ -1,20 +0,0 @@ -# openapi.model.Pet - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **int** | | [optional] -**category** | [**Category**](Category.md) | | [optional] -**name** | **String** | | -**photoUrls** | **Set** | | [default to const {}] -**tags** | [**List**](Tag.md) | | [optional] [default to const []] -**status** | **String** | pet status in the store | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/PetApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/PetApi.md deleted file mode 100644 index 387717e3f917..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/PetApi.md +++ /dev/null @@ -1,427 +0,0 @@ -# openapi.api.PetApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**addPet**](PetApi.md#addpet) | **POST** /pet | Add a new pet to the store -[**deletePet**](PetApi.md#deletepet) | **DELETE** /pet/{petId} | Deletes a pet -[**findPetsByStatus**](PetApi.md#findpetsbystatus) | **GET** /pet/findByStatus | Finds Pets by status -[**findPetsByTags**](PetApi.md#findpetsbytags) | **GET** /pet/findByTags | Finds Pets by tags -[**getPetById**](PetApi.md#getpetbyid) | **GET** /pet/{petId} | Find pet by ID -[**updatePet**](PetApi.md#updatepet) | **PUT** /pet | Update an existing pet -[**updatePetWithForm**](PetApi.md#updatepetwithform) | **POST** /pet/{petId} | Updates a pet in the store with form data -[**uploadFile**](PetApi.md#uploadfile) | **POST** /pet/{petId}/uploadImage | uploads an image -[**uploadFileWithRequiredFile**](PetApi.md#uploadfilewithrequiredfile) | **POST** /fake/{petId}/uploadImageWithRequiredFile | uploads an image (required) - - -# **addPet** -> addPet(pet) - -Add a new pet to the store - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final pet = Pet(); // Pet | Pet object that needs to be added to the store - -try { - api_instance.addPet(pet); -} catch (e) { - print('Exception when calling PetApi->addPet: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | - -### Return type - -void (empty response body) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **deletePet** -> deletePet(petId, apiKey) - -Deletes a pet - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final petId = 789; // int | Pet id to delete -final apiKey = apiKey_example; // String | - -try { - api_instance.deletePet(petId, apiKey); -} catch (e) { - print('Exception when calling PetApi->deletePet: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **petId** | **int**| Pet id to delete | - **apiKey** | **String**| | [optional] - -### Return type - -void (empty response body) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **findPetsByStatus** -> List findPetsByStatus(status) - -Finds Pets by status - -Multiple status values can be provided with comma separated strings - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final status = []; // List | Status values that need to be considered for filter - -try { - final result = api_instance.findPetsByStatus(status); - print(result); -} catch (e) { - print('Exception when calling PetApi->findPetsByStatus: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **status** | [**List**](String.md)| Status values that need to be considered for filter | [default to const []] - -### Return type - -[**List**](Pet.md) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **findPetsByTags** -> Set findPetsByTags(tags) - -Finds Pets by tags - -Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final tags = []; // Set | Tags to filter by - -try { - final result = api_instance.findPetsByTags(tags); - print(result); -} catch (e) { - print('Exception when calling PetApi->findPetsByTags: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **tags** | [**Set**](String.md)| Tags to filter by | [default to const {}] - -### Return type - -[**Set**](Pet.md) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **getPetById** -> Pet getPetById(petId) - -Find pet by ID - -Returns a single pet - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure API key authorization: api_key -//defaultApiClient.getAuthentication('api_key').apiKey = 'YOUR_API_KEY'; -// uncomment below to setup prefix (e.g. Bearer) for API key, if needed -//defaultApiClient.getAuthentication('api_key').apiKeyPrefix = 'Bearer'; - -final api_instance = PetApi(); -final petId = 789; // int | ID of pet to return - -try { - final result = api_instance.getPetById(petId); - print(result); -} catch (e) { - print('Exception when calling PetApi->getPetById: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **petId** | **int**| ID of pet to return | - -### Return type - -[**Pet**](Pet.md) - -### Authorization - -[api_key](../README.md#api_key) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **updatePet** -> updatePet(pet) - -Update an existing pet - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final pet = Pet(); // Pet | Pet object that needs to be added to the store - -try { - api_instance.updatePet(pet); -} catch (e) { - print('Exception when calling PetApi->updatePet: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store | - -### Return type - -void (empty response body) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: application/json, application/xml - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **updatePetWithForm** -> updatePetWithForm(petId, name, status) - -Updates a pet in the store with form data - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final petId = 789; // int | ID of pet that needs to be updated -final name = name_example; // String | Updated name of the pet -final status = status_example; // String | Updated status of the pet - -try { - api_instance.updatePetWithForm(petId, name, status); -} catch (e) { - print('Exception when calling PetApi->updatePetWithForm: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **petId** | **int**| ID of pet that needs to be updated | - **name** | **String**| Updated name of the pet | [optional] - **status** | **String**| Updated status of the pet | [optional] - -### Return type - -void (empty response body) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: application/x-www-form-urlencoded - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **uploadFile** -> ApiResponse uploadFile(petId, additionalMetadata, file) - -uploads an image - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final petId = 789; // int | ID of pet to update -final additionalMetadata = additionalMetadata_example; // String | Additional data to pass to server -final file = BINARY_DATA_HERE; // MultipartFile | file to upload - -try { - final result = api_instance.uploadFile(petId, additionalMetadata, file); - print(result); -} catch (e) { - print('Exception when calling PetApi->uploadFile: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **petId** | **int**| ID of pet to update | - **additionalMetadata** | **String**| Additional data to pass to server | [optional] - **file** | **MultipartFile**| file to upload | [optional] - -### Return type - -[**ApiResponse**](ApiResponse.md) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: multipart/form-data - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **uploadFileWithRequiredFile** -> ApiResponse uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata) - -uploads an image (required) - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure OAuth2 access token for authorization: petstore_auth -//defaultApiClient.getAuthentication('petstore_auth').accessToken = 'YOUR_ACCESS_TOKEN'; - -final api_instance = PetApi(); -final petId = 789; // int | ID of pet to update -final requiredFile = BINARY_DATA_HERE; // MultipartFile | file to upload -final additionalMetadata = additionalMetadata_example; // String | Additional data to pass to server - -try { - final result = api_instance.uploadFileWithRequiredFile(petId, requiredFile, additionalMetadata); - print(result); -} catch (e) { - print('Exception when calling PetApi->uploadFileWithRequiredFile: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **petId** | **int**| ID of pet to update | - **requiredFile** | **MultipartFile**| file to upload | - **additionalMetadata** | **String**| Additional data to pass to server | [optional] - -### Return type - -[**ApiResponse**](ApiResponse.md) - -### Authorization - -[petstore_auth](../README.md#petstore_auth) - -### HTTP request headers - - - **Content-Type**: multipart/form-data - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ReadOnlyFirst.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ReadOnlyFirst.md deleted file mode 100644 index fa6f9e4305d4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/ReadOnlyFirst.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.ReadOnlyFirst - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**bar** | **String** | | [optional] [readonly] -**baz** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/SpecialModelName.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/SpecialModelName.md deleted file mode 100644 index 5fcfa98e0b36..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/SpecialModelName.md +++ /dev/null @@ -1,15 +0,0 @@ -# openapi.model.SpecialModelName - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket** | **int** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/StoreApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/StoreApi.md deleted file mode 100644 index f43230375e7b..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/StoreApi.md +++ /dev/null @@ -1,186 +0,0 @@ -# openapi.api.StoreApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**deleteOrder**](StoreApi.md#deleteorder) | **DELETE** /store/order/{order_id} | Delete purchase order by ID -[**getInventory**](StoreApi.md#getinventory) | **GET** /store/inventory | Returns pet inventories by status -[**getOrderById**](StoreApi.md#getorderbyid) | **GET** /store/order/{order_id} | Find purchase order by ID -[**placeOrder**](StoreApi.md#placeorder) | **POST** /store/order | Place an order for a pet - - -# **deleteOrder** -> deleteOrder(orderId) - -Delete purchase order by ID - -For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = StoreApi(); -final orderId = orderId_example; // String | ID of the order that needs to be deleted - -try { - api_instance.deleteOrder(orderId); -} catch (e) { - print('Exception when calling StoreApi->deleteOrder: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **orderId** | **String**| ID of the order that needs to be deleted | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **getInventory** -> Map getInventory() - -Returns pet inventories by status - -Returns a map of status codes to quantities - -### Example -```dart -import 'package:openapi/api.dart'; -// TODO Configure API key authorization: api_key -//defaultApiClient.getAuthentication('api_key').apiKey = 'YOUR_API_KEY'; -// uncomment below to setup prefix (e.g. Bearer) for API key, if needed -//defaultApiClient.getAuthentication('api_key').apiKeyPrefix = 'Bearer'; - -final api_instance = StoreApi(); - -try { - final result = api_instance.getInventory(); - print(result); -} catch (e) { - print('Exception when calling StoreApi->getInventory: $e\n'); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -**Map** - -### Authorization - -[api_key](../README.md#api_key) - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **getOrderById** -> Order getOrderById(orderId) - -Find purchase order by ID - -For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = StoreApi(); -final orderId = 789; // int | ID of pet that needs to be fetched - -try { - final result = api_instance.getOrderById(orderId); - print(result); -} catch (e) { - print('Exception when calling StoreApi->getOrderById: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **orderId** | **int**| ID of pet that needs to be fetched | - -### Return type - -[**Order**](Order.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **placeOrder** -> Order placeOrder(order) - -Place an order for a pet - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = StoreApi(); -final order = Order(); // Order | order placed for purchasing the pet - -try { - final result = api_instance.placeOrder(order); - print(result); -} catch (e) { - print('Exception when calling StoreApi->placeOrder: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **order** | [**Order**](Order.md)| order placed for purchasing the pet | - -### Return type - -[**Order**](Order.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Tag.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Tag.md deleted file mode 100644 index c219f987c19c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/Tag.md +++ /dev/null @@ -1,16 +0,0 @@ -# openapi.model.Tag - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **int** | | [optional] -**name** | **String** | | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/User.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/User.md deleted file mode 100644 index fa87e64d8595..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/User.md +++ /dev/null @@ -1,22 +0,0 @@ -# openapi.model.User - -## Load the model package -```dart -import 'package:openapi/api.dart'; -``` - -## Properties -Name | Type | Description | Notes ------------- | ------------- | ------------- | ------------- -**id** | **int** | | [optional] -**username** | **String** | | [optional] -**firstName** | **String** | | [optional] -**lastName** | **String** | | [optional] -**email** | **String** | | [optional] -**password** | **String** | | [optional] -**phone** | **String** | | [optional] -**userStatus** | **int** | User Status | [optional] - -[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md) - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/UserApi.md b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/UserApi.md deleted file mode 100644 index f318f92ccefd..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/doc/UserApi.md +++ /dev/null @@ -1,349 +0,0 @@ -# openapi.api.UserApi - -## Load the API package -```dart -import 'package:openapi/api.dart'; -``` - -All URIs are relative to *http://petstore.swagger.io:80/v2* - -Method | HTTP request | Description -------------- | ------------- | ------------- -[**createUser**](UserApi.md#createuser) | **POST** /user | Create user -[**createUsersWithArrayInput**](UserApi.md#createuserswitharrayinput) | **POST** /user/createWithArray | Creates list of users with given input array -[**createUsersWithListInput**](UserApi.md#createuserswithlistinput) | **POST** /user/createWithList | Creates list of users with given input array -[**deleteUser**](UserApi.md#deleteuser) | **DELETE** /user/{username} | Delete user -[**getUserByName**](UserApi.md#getuserbyname) | **GET** /user/{username} | Get user by user name -[**loginUser**](UserApi.md#loginuser) | **GET** /user/login | Logs user into the system -[**logoutUser**](UserApi.md#logoutuser) | **GET** /user/logout | Logs out current logged in user session -[**updateUser**](UserApi.md#updateuser) | **PUT** /user/{username} | Updated user - - -# **createUser** -> createUser(user) - -Create user - -This can only be done by the logged in user. - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final user = User(); // User | Created user object - -try { - api_instance.createUser(user); -} catch (e) { - print('Exception when calling UserApi->createUser: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**User**](User.md)| Created user object | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **createUsersWithArrayInput** -> createUsersWithArrayInput(user) - -Creates list of users with given input array - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final user = [List()]; // List | List of user object - -try { - api_instance.createUsersWithArrayInput(user); -} catch (e) { - print('Exception when calling UserApi->createUsersWithArrayInput: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**List**](User.md)| List of user object | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **createUsersWithListInput** -> createUsersWithListInput(user) - -Creates list of users with given input array - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final user = [List()]; // List | List of user object - -try { - api_instance.createUsersWithListInput(user); -} catch (e) { - print('Exception when calling UserApi->createUsersWithListInput: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **user** | [**List**](User.md)| List of user object | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **deleteUser** -> deleteUser(username) - -Delete user - -This can only be done by the logged in user. - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final username = username_example; // String | The name that needs to be deleted - -try { - api_instance.deleteUser(username); -} catch (e) { - print('Exception when calling UserApi->deleteUser: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be deleted | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **getUserByName** -> User getUserByName(username) - -Get user by user name - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final username = username_example; // String | The name that needs to be fetched. Use user1 for testing. - -try { - final result = api_instance.getUserByName(username); - print(result); -} catch (e) { - print('Exception when calling UserApi->getUserByName: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The name that needs to be fetched. Use user1 for testing. | - -### Return type - -[**User**](User.md) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **loginUser** -> String loginUser(username, password) - -Logs user into the system - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final username = username_example; // String | The user name for login -final password = password_example; // String | The password for login in clear text - -try { - final result = api_instance.loginUser(username, password); - print(result); -} catch (e) { - print('Exception when calling UserApi->loginUser: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| The user name for login | - **password** | **String**| The password for login in clear text | - -### Return type - -**String** - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: application/xml, application/json - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **logoutUser** -> logoutUser() - -Logs out current logged in user session - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); - -try { - api_instance.logoutUser(); -} catch (e) { - print('Exception when calling UserApi->logoutUser: $e\n'); -} -``` - -### Parameters -This endpoint does not need any parameter. - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: Not defined - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - -# **updateUser** -> updateUser(username, user) - -Updated user - -This can only be done by the logged in user. - -### Example -```dart -import 'package:openapi/api.dart'; - -final api_instance = UserApi(); -final username = username_example; // String | name that need to be deleted -final user = User(); // User | Updated user object - -try { - api_instance.updateUser(username, user); -} catch (e) { - print('Exception when calling UserApi->updateUser: $e\n'); -} -``` - -### Parameters - -Name | Type | Description | Notes -------------- | ------------- | ------------- | ------------- - **username** | **String**| name that need to be deleted | - **user** | [**User**](User.md)| Updated user object | - -### Return type - -void (empty response body) - -### Authorization - -No authorization required - -### HTTP request headers - - - **Content-Type**: application/json - - **Accept**: Not defined - -[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md) - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/git_push.sh b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/git_push.sh deleted file mode 100644 index f53a75d4fabe..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/git_push.sh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/sh -# ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/ -# -# Usage example: /bin/sh ./git_push.sh wing328 openapi-petstore-perl "minor update" "gitlab.com" - -git_user_id=$1 -git_repo_id=$2 -release_note=$3 -git_host=$4 - -if [ "$git_host" = "" ]; then - git_host="github.com" - echo "[INFO] No command line input provided. Set \$git_host to $git_host" -fi - -if [ "$git_user_id" = "" ]; then - git_user_id="GIT_USER_ID" - echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id" -fi - -if [ "$git_repo_id" = "" ]; then - git_repo_id="GIT_REPO_ID" - echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id" -fi - -if [ "$release_note" = "" ]; then - release_note="Minor update" - echo "[INFO] No command line input provided. Set \$release_note to $release_note" -fi - -# Initialize the local directory as a Git repository -git init - -# Adds the files in the local repository and stages them for commit. -git add . - -# Commits the tracked changes and prepares them to be pushed to a remote repository. -git commit -m "$release_note" - -# Sets the new remote -git_remote=$(git remote) -if [ "$git_remote" = "" ]; then # git remote not defined - - if [ "$GIT_TOKEN" = "" ]; then - echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment." - git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git - else - git remote add origin https://${git_user_id}:"${GIT_TOKEN}"@${git_host}/${git_user_id}/${git_repo_id}.git - fi - -fi - -git pull origin master - -# Pushes (Forces) the changes in the local repository up to the remote repository -echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git" -git push origin master 2>&1 | grep -v 'To https' diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api.dart deleted file mode 100644 index 920f26ddc57d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api.dart +++ /dev/null @@ -1,95 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -library openapi.api; - -import 'dart:async'; -import 'dart:convert'; -import 'dart:io'; - -import 'package:http/http.dart'; -import 'package:intl/intl.dart'; -import 'package:json_annotation/json_annotation.dart'; -import 'package:meta/meta.dart'; - -part 'api_client.dart'; -part 'api_helper.dart'; -part 'api_exception.dart'; -part 'auth/authentication.dart'; -part 'auth/api_key_auth.dart'; -part 'auth/oauth.dart'; -part 'auth/http_basic_auth.dart'; -part 'auth/http_bearer_auth.dart'; - -part 'api/another_fake_api.dart'; -part 'api/default_api.dart'; -part 'api/fake_api.dart'; -part 'api/fake_classname_tags123_api.dart'; -part 'api/pet_api.dart'; -part 'api/store_api.dart'; -part 'api/user_api.dart'; - -part 'model/additional_properties_class.dart'; -part 'model/animal.dart'; -part 'model/api_response.dart'; -part 'model/array_of_array_of_number_only.dart'; -part 'model/array_of_number_only.dart'; -part 'model/array_test.dart'; -part 'model/capitalization.dart'; -part 'model/cat.dart'; -part 'model/cat_all_of.dart'; -part 'model/category.dart'; -part 'model/class_model.dart'; -part 'model/deprecated_object.dart'; -part 'model/dog.dart'; -part 'model/dog_all_of.dart'; -part 'model/enum_arrays.dart'; -part 'model/enum_class.dart'; -part 'model/enum_test.dart'; -part 'model/file_schema_test_class.dart'; -part 'model/foo.dart'; -part 'model/format_test.dart'; -part 'model/has_only_read_only.dart'; -part 'model/health_check_result.dart'; -part 'model/inline_response_default.dart'; -part 'model/map_test.dart'; -part 'model/mixed_properties_and_additional_properties_class.dart'; -part 'model/model200_response.dart'; -part 'model/model_client.dart'; -part 'model/model_file.dart'; -part 'model/model_list.dart'; -part 'model/model_return.dart'; -part 'model/name.dart'; -part 'model/nullable_class.dart'; -part 'model/number_only.dart'; -part 'model/object_with_deprecated_fields.dart'; -part 'model/order.dart'; -part 'model/outer_composite.dart'; -part 'model/outer_enum.dart'; -part 'model/outer_enum_default_value.dart'; -part 'model/outer_enum_integer.dart'; -part 'model/outer_enum_integer_default_value.dart'; -part 'model/outer_object_with_enum_property.dart'; -part 'model/pet.dart'; -part 'model/read_only_first.dart'; -part 'model/special_model_name.dart'; -part 'model/tag.dart'; -part 'model/user.dart'; - - -part 'api.g.dart'; -const _delimiters = {'csv': ',', 'ssv': ' ', 'tsv': '\t', 'pipes': '|'}; -const _dateEpochMarker = 'epoch'; -final _dateFormatter = DateFormat('yyyy-MM-dd'); -final _regList = RegExp(r'^List<(.*)>$'); -final _regSet = RegExp(r'^Set<(.*)>$'); -final _regMap = RegExp(r'^Map$'); - -ApiClient defaultApiClient = ApiClient(); diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/another_fake_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/another_fake_api.dart deleted file mode 100644 index 2295e5df8ad7..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/another_fake_api.dart +++ /dev/null @@ -1,83 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class AnotherFakeApi { - AnotherFakeApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// To test special tags - /// - /// To test special tags and operation ID starting with number - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future call123testSpecialTagsWithHttpInfo(ModelClient modelClient,) async { - // Verify required params are set. - if (modelClient == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: modelClient'); - } - - // ignore: prefer_const_declarations - final path = r'/another-fake/dummy'; - - // ignore: prefer_final_locals - Object postBody = modelClient; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PATCH', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// To test special tags - /// - /// To test special tags and operation ID starting with number - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future call123testSpecialTags(ModelClient modelClient,) async { - final response = await call123testSpecialTagsWithHttpInfo(modelClient,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return ModelClient.fromJson(json.decode(response.body)); - } - return Future.value(); - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/default_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/default_api.dart deleted file mode 100644 index 8f485dacf175..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/default_api.dart +++ /dev/null @@ -1,61 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class DefaultApi { - DefaultApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// Performs an HTTP 'GET /foo' operation and returns the [Response]. - Future fooGetWithHttpInfo() async { - // ignore: prefer_const_declarations - final path = r'/foo'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - Future fooGet() async { - final response = await fooGetWithHttpInfo(); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return InlineResponseDefault.fromJson(json.decode(response.body)); - } - return Future.value(); - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_api.dart deleted file mode 100644 index 05fedc622a29..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_api.dart +++ /dev/null @@ -1,1287 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class FakeApi { - FakeApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// Health check endpoint - /// - /// Note: This method returns the HTTP [Response]. - Future fakeHealthGetWithHttpInfo() async { - // ignore: prefer_const_declarations - final path = r'/fake/health'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Health check endpoint - Future fakeHealthGet() async { - final response = await fakeHealthGetWithHttpInfo(); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return HealthCheckResult.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// test http signature authentication - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - /// - /// * [String] query1: - /// query parameter - /// - /// * [String] header1: - /// header parameter - Future fakeHttpSignatureTestWithHttpInfo(Pet pet, { String query1, String header1, }) async { - // Verify required params are set. - if (pet == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: pet'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/http-signature-test'; - - // ignore: prefer_final_locals - Object postBody = pet; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - if (query1 != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'query_1', query1)); - } - - if (header1 != null) { - headerParams[r'header_1'] = parameterToString(header1); - } - - const authNames = ['http_signature_test']; - const contentTypes = ['application/json', 'application/xml']; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// test http signature authentication - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - /// - /// * [String] query1: - /// query parameter - /// - /// * [String] header1: - /// header parameter - Future fakeHttpSignatureTest(Pet pet, { String query1, String header1, }) async { - final response = await fakeHttpSignatureTestWithHttpInfo(pet, query1: query1, header1: header1, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Test serialization of outer boolean types - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [bool] body: - /// Input boolean as post body - Future fakeOuterBooleanSerializeWithHttpInfo({ bool body, }) async { - // Verify required params are set. - - // ignore: prefer_const_declarations - final path = r'/fake/outer/boolean'; - - // ignore: prefer_final_locals - Object postBody = body; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Test serialization of outer boolean types - /// - /// Parameters: - /// - /// * [bool] body: - /// Input boolean as post body - Future fakeOuterBooleanSerialize({ bool body, }) async { - final response = await fakeOuterBooleanSerializeWithHttpInfo( body: body, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return response.body as bool; - } - return Future.value(); - } - - /// Test serialization of object with outer number type - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [OuterComposite] outerComposite: - /// Input composite as post body - Future fakeOuterCompositeSerializeWithHttpInfo({ OuterComposite outerComposite, }) async { - // Verify required params are set. - - // ignore: prefer_const_declarations - final path = r'/fake/outer/composite'; - - // ignore: prefer_final_locals - Object postBody = outerComposite; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Test serialization of object with outer number type - /// - /// Parameters: - /// - /// * [OuterComposite] outerComposite: - /// Input composite as post body - Future fakeOuterCompositeSerialize({ OuterComposite outerComposite, }) async { - final response = await fakeOuterCompositeSerializeWithHttpInfo( outerComposite: outerComposite, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return OuterComposite.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// Test serialization of outer number types - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [num] body: - /// Input number as post body - Future fakeOuterNumberSerializeWithHttpInfo({ num body, }) async { - // Verify required params are set. - - // ignore: prefer_const_declarations - final path = r'/fake/outer/number'; - - // ignore: prefer_final_locals - Object postBody = body; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Test serialization of outer number types - /// - /// Parameters: - /// - /// * [num] body: - /// Input number as post body - Future fakeOuterNumberSerialize({ num body, }) async { - final response = await fakeOuterNumberSerializeWithHttpInfo( body: body, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return response.body as num; - } - return Future.value(); - } - - /// Test serialization of outer string types - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] body: - /// Input string as post body - Future fakeOuterStringSerializeWithHttpInfo({ String body, }) async { - // Verify required params are set. - - // ignore: prefer_const_declarations - final path = r'/fake/outer/string'; - - // ignore: prefer_final_locals - Object postBody = body; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Test serialization of outer string types - /// - /// Parameters: - /// - /// * [String] body: - /// Input string as post body - Future fakeOuterStringSerialize({ String body, }) async { - final response = await fakeOuterStringSerializeWithHttpInfo( body: body, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return response.body as String; - } - return Future.value(); - } - - /// Test serialization of enum (int) properties with examples - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [OuterObjectWithEnumProperty] outerObjectWithEnumProperty (required): - /// Input enum (int) as post body - Future fakePropertyEnumIntegerSerializeWithHttpInfo(OuterObjectWithEnumProperty outerObjectWithEnumProperty,) async { - // Verify required params are set. - if (outerObjectWithEnumProperty == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: outerObjectWithEnumProperty'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/property/enum-int'; - - // ignore: prefer_final_locals - Object postBody = outerObjectWithEnumProperty; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Test serialization of enum (int) properties with examples - /// - /// Parameters: - /// - /// * [OuterObjectWithEnumProperty] outerObjectWithEnumProperty (required): - /// Input enum (int) as post body - Future fakePropertyEnumIntegerSerialize(OuterObjectWithEnumProperty outerObjectWithEnumProperty,) async { - final response = await fakePropertyEnumIntegerSerializeWithHttpInfo(outerObjectWithEnumProperty,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return OuterObjectWithEnumProperty.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// For this test, the body has to be a binary file. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [MultipartFile] body (required): - /// image to upload - Future testBodyWithBinaryWithHttpInfo(MultipartFile body,) async { - // Verify required params are set. - if (body == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: body'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/body-with-binary'; - - // ignore: prefer_final_locals - Object postBody = body; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['image/png']; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// For this test, the body has to be a binary file. - /// - /// Parameters: - /// - /// * [MultipartFile] body (required): - /// image to upload - Future testBodyWithBinary(MultipartFile body,) async { - final response = await testBodyWithBinaryWithHttpInfo(body,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// For this test, the body for this request must reference a schema named `File`. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [FileSchemaTestClass] fileSchemaTestClass (required): - Future testBodyWithFileSchemaWithHttpInfo(FileSchemaTestClass fileSchemaTestClass,) async { - // Verify required params are set. - if (fileSchemaTestClass == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: fileSchemaTestClass'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/body-with-file-schema'; - - // ignore: prefer_final_locals - Object postBody = fileSchemaTestClass; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// For this test, the body for this request must reference a schema named `File`. - /// - /// Parameters: - /// - /// * [FileSchemaTestClass] fileSchemaTestClass (required): - Future testBodyWithFileSchema(FileSchemaTestClass fileSchemaTestClass,) async { - final response = await testBodyWithFileSchemaWithHttpInfo(fileSchemaTestClass,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Performs an HTTP 'PUT /fake/body-with-query-params' operation and returns the [Response]. - /// Parameters: - /// - /// * [String] query (required): - /// - /// * [User] user (required): - Future testBodyWithQueryParamsWithHttpInfo(String query, User user,) async { - // Verify required params are set. - if (query == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: query'); - } - if (user == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: user'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/body-with-query-params'; - - // ignore: prefer_final_locals - Object postBody = user; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('', 'query', query)); - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Parameters: - /// - /// * [String] query (required): - /// - /// * [User] user (required): - Future testBodyWithQueryParams(String query, User user,) async { - final response = await testBodyWithQueryParamsWithHttpInfo(query, user,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// To test \"client\" model - /// - /// To test \"client\" model - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future testClientModelWithHttpInfo(ModelClient modelClient,) async { - // Verify required params are set. - if (modelClient == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: modelClient'); - } - - // ignore: prefer_const_declarations - final path = r'/fake'; - - // ignore: prefer_final_locals - Object postBody = modelClient; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PATCH', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// To test \"client\" model - /// - /// To test \"client\" model - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future testClientModel(ModelClient modelClient,) async { - final response = await testClientModelWithHttpInfo(modelClient,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return ModelClient.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [num] number (required): - /// None - /// - /// * [double] double_ (required): - /// None - /// - /// * [String] patternWithoutDelimiter (required): - /// None - /// - /// * [String] byte (required): - /// None - /// - /// * [int] integer: - /// None - /// - /// * [int] int32: - /// None - /// - /// * [int] int64: - /// None - /// - /// * [double] float: - /// None - /// - /// * [String] string: - /// None - /// - /// * [MultipartFile] binary: - /// None - /// - /// * [DateTime] date: - /// None - /// - /// * [DateTime] dateTime: - /// None - /// - /// * [String] password: - /// None - /// - /// * [String] callback: - /// None - Future testEndpointParametersWithHttpInfo(num number, double double_, String patternWithoutDelimiter, String byte, { int integer, int int32, int int64, double float, String string, MultipartFile binary, DateTime date, DateTime dateTime, String password, String callback, }) async { - // Verify required params are set. - if (number == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: number'); - } - if (double_ == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: double_'); - } - if (patternWithoutDelimiter == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: patternWithoutDelimiter'); - } - if (byte == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: byte'); - } - - // ignore: prefer_const_declarations - final path = r'/fake'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['http_basic_test']; - const contentTypes = ['application/x-www-form-urlencoded']; - - if (integer != null) { - formParams[r'integer'] = parameterToString(integer); - } - if (int32 != null) { - formParams[r'int32'] = parameterToString(int32); - } - if (int64 != null) { - formParams[r'int64'] = parameterToString(int64); - } - if (number != null) { - formParams[r'number'] = parameterToString(number); - } - if (float != null) { - formParams[r'float'] = parameterToString(float); - } - if (double_ != null) { - formParams[r'double'] = parameterToString(double_); - } - if (string != null) { - formParams[r'string'] = parameterToString(string); - } - if (patternWithoutDelimiter != null) { - formParams[r'pattern_without_delimiter'] = parameterToString(patternWithoutDelimiter); - } - if (byte != null) { - formParams[r'byte'] = parameterToString(byte); - } - if (date != null) { - formParams[r'date'] = parameterToString(date); - } - if (dateTime != null) { - formParams[r'dateTime'] = parameterToString(dateTime); - } - if (password != null) { - formParams[r'password'] = parameterToString(password); - } - if (callback != null) { - formParams[r'callback'] = parameterToString(callback); - } - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - /// - /// Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - /// - /// Parameters: - /// - /// * [num] number (required): - /// None - /// - /// * [double] double_ (required): - /// None - /// - /// * [String] patternWithoutDelimiter (required): - /// None - /// - /// * [String] byte (required): - /// None - /// - /// * [int] integer: - /// None - /// - /// * [int] int32: - /// None - /// - /// * [int] int64: - /// None - /// - /// * [double] float: - /// None - /// - /// * [String] string: - /// None - /// - /// * [MultipartFile] binary: - /// None - /// - /// * [DateTime] date: - /// None - /// - /// * [DateTime] dateTime: - /// None - /// - /// * [String] password: - /// None - /// - /// * [String] callback: - /// None - Future testEndpointParameters(num number, double double_, String patternWithoutDelimiter, String byte, { int integer, int int32, int int64, double float, String string, MultipartFile binary, DateTime date, DateTime dateTime, String password, String callback, }) async { - final response = await testEndpointParametersWithHttpInfo(number, double_, patternWithoutDelimiter, byte, integer: integer, int32: int32, int64: int64, float: float, string: string, binary: binary, date: date, dateTime: dateTime, password: password, callback: callback, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// To test enum parameters - /// - /// To test enum parameters - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [List] enumHeaderStringArray: - /// Header parameter enum test (string array) - /// - /// * [String] enumHeaderString: - /// Header parameter enum test (string) - /// - /// * [List] enumQueryStringArray: - /// Query parameter enum test (string array) - /// - /// * [String] enumQueryString: - /// Query parameter enum test (string) - /// - /// * [int] enumQueryInteger: - /// Query parameter enum test (double) - /// - /// * [double] enumQueryDouble: - /// Query parameter enum test (double) - /// - /// * [List] enumFormStringArray: - /// Form parameter enum test (string array) - /// - /// * [String] enumFormString: - /// Form parameter enum test (string) - Future testEnumParametersWithHttpInfo({ List enumHeaderStringArray, String enumHeaderString, List enumQueryStringArray, String enumQueryString, int enumQueryInteger, double enumQueryDouble, List enumFormStringArray, String enumFormString, }) async { - // Verify required params are set. - - // ignore: prefer_const_declarations - final path = r'/fake'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - if (enumQueryStringArray != null) { - queryParams.addAll(_convertParametersForCollectionFormat('multi', 'enum_query_string_array', enumQueryStringArray)); - } - if (enumQueryString != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'enum_query_string', enumQueryString)); - } - if (enumQueryInteger != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'enum_query_integer', enumQueryInteger)); - } - if (enumQueryDouble != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'enum_query_double', enumQueryDouble)); - } - - if (enumHeaderStringArray != null) { - headerParams[r'enum_header_string_array'] = parameterToString(enumHeaderStringArray); - } - if (enumHeaderString != null) { - headerParams[r'enum_header_string'] = parameterToString(enumHeaderString); - } - - const authNames = []; - const contentTypes = ['application/x-www-form-urlencoded']; - - if (enumFormStringArray != null) { - formParams[r'enum_form_string_array'] = parameterToString(enumFormStringArray); - } - if (enumFormString != null) { - formParams[r'enum_form_string'] = parameterToString(enumFormString); - } - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// To test enum parameters - /// - /// To test enum parameters - /// - /// Parameters: - /// - /// * [List] enumHeaderStringArray: - /// Header parameter enum test (string array) - /// - /// * [String] enumHeaderString: - /// Header parameter enum test (string) - /// - /// * [List] enumQueryStringArray: - /// Query parameter enum test (string array) - /// - /// * [String] enumQueryString: - /// Query parameter enum test (string) - /// - /// * [int] enumQueryInteger: - /// Query parameter enum test (double) - /// - /// * [double] enumQueryDouble: - /// Query parameter enum test (double) - /// - /// * [List] enumFormStringArray: - /// Form parameter enum test (string array) - /// - /// * [String] enumFormString: - /// Form parameter enum test (string) - Future testEnumParameters({ List enumHeaderStringArray, String enumHeaderString, List enumQueryStringArray, String enumQueryString, int enumQueryInteger, double enumQueryDouble, List enumFormStringArray, String enumFormString, }) async { - final response = await testEnumParametersWithHttpInfo( enumHeaderStringArray: enumHeaderStringArray, enumHeaderString: enumHeaderString, enumQueryStringArray: enumQueryStringArray, enumQueryString: enumQueryString, enumQueryInteger: enumQueryInteger, enumQueryDouble: enumQueryDouble, enumFormStringArray: enumFormStringArray, enumFormString: enumFormString, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Fake endpoint to test group parameters (optional) - /// - /// Fake endpoint to test group parameters (optional) - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] requiredStringGroup (required): - /// Required String in group parameters - /// - /// * [bool] requiredBooleanGroup (required): - /// Required Boolean in group parameters - /// - /// * [int] requiredInt64Group (required): - /// Required Integer in group parameters - /// - /// * [int] stringGroup: - /// String in group parameters - /// - /// * [bool] booleanGroup: - /// Boolean in group parameters - /// - /// * [int] int64Group: - /// Integer in group parameters - Future testGroupParametersWithHttpInfo(int requiredStringGroup, bool requiredBooleanGroup, int requiredInt64Group, { int stringGroup, bool booleanGroup, int int64Group, }) async { - // Verify required params are set. - if (requiredStringGroup == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: requiredStringGroup'); - } - if (requiredBooleanGroup == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: requiredBooleanGroup'); - } - if (requiredInt64Group == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: requiredInt64Group'); - } - - // ignore: prefer_const_declarations - final path = r'/fake'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('', 'required_string_group', requiredStringGroup)); - queryParams.addAll(_convertParametersForCollectionFormat('', 'required_int64_group', requiredInt64Group)); - if (stringGroup != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'string_group', stringGroup)); - } - if (int64Group != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'int64_group', int64Group)); - } - - headerParams[r'required_boolean_group'] = parameterToString(requiredBooleanGroup); - if (booleanGroup != null) { - headerParams[r'boolean_group'] = parameterToString(booleanGroup); - } - - const authNames = ['bearer_test']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'DELETE', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Fake endpoint to test group parameters (optional) - /// - /// Fake endpoint to test group parameters (optional) - /// - /// Parameters: - /// - /// * [int] requiredStringGroup (required): - /// Required String in group parameters - /// - /// * [bool] requiredBooleanGroup (required): - /// Required Boolean in group parameters - /// - /// * [int] requiredInt64Group (required): - /// Required Integer in group parameters - /// - /// * [int] stringGroup: - /// String in group parameters - /// - /// * [bool] booleanGroup: - /// Boolean in group parameters - /// - /// * [int] int64Group: - /// Integer in group parameters - Future testGroupParameters(int requiredStringGroup, bool requiredBooleanGroup, int requiredInt64Group, { int stringGroup, bool booleanGroup, int int64Group, }) async { - final response = await testGroupParametersWithHttpInfo(requiredStringGroup, requiredBooleanGroup, requiredInt64Group, stringGroup: stringGroup, booleanGroup: booleanGroup, int64Group: int64Group, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// test inline additionalProperties - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Map] requestBody (required): - /// request body - Future testInlineAdditionalPropertiesWithHttpInfo(Map requestBody,) async { - // Verify required params are set. - if (requestBody == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: requestBody'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/inline-additionalProperties'; - - // ignore: prefer_final_locals - Object postBody = requestBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// test inline additionalProperties - /// - /// Parameters: - /// - /// * [Map] requestBody (required): - /// request body - Future testInlineAdditionalProperties(Map requestBody,) async { - final response = await testInlineAdditionalPropertiesWithHttpInfo(requestBody,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// test json serialization of form data - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] param (required): - /// field1 - /// - /// * [String] param2 (required): - /// field2 - Future testJsonFormDataWithHttpInfo(String param, String param2,) async { - // Verify required params are set. - if (param == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: param'); - } - if (param2 == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: param2'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/jsonFormData'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/x-www-form-urlencoded']; - - if (param != null) { - formParams[r'param'] = parameterToString(param); - } - if (param2 != null) { - formParams[r'param2'] = parameterToString(param2); - } - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// test json serialization of form data - /// - /// Parameters: - /// - /// * [String] param (required): - /// field1 - /// - /// * [String] param2 (required): - /// field2 - Future testJsonFormData(String param, String param2,) async { - final response = await testJsonFormDataWithHttpInfo(param, param2,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// To test the collection format in query parameters - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [List] pipe (required): - /// - /// * [List] ioutil (required): - /// - /// * [List] http (required): - /// - /// * [List] url (required): - /// - /// * [List] context (required): - /// - /// * [String] allowEmpty (required): - /// - /// * [Map] language: - Future testQueryParameterCollectionFormatWithHttpInfo(List pipe, List ioutil, List http, List url, List context, String allowEmpty, { Map language, }) async { - // Verify required params are set. - if (pipe == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: pipe'); - } - if (ioutil == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: ioutil'); - } - if (http == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: http'); - } - if (url == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: url'); - } - if (context == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: context'); - } - if (allowEmpty == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: allowEmpty'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/test-query-parameters'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('pipes', 'pipe', pipe)); - queryParams.addAll(_convertParametersForCollectionFormat('csv', 'ioutil', ioutil)); - queryParams.addAll(_convertParametersForCollectionFormat('ssv', 'http', http)); - queryParams.addAll(_convertParametersForCollectionFormat('csv', 'url', url)); - queryParams.addAll(_convertParametersForCollectionFormat('multi', 'context', context)); - if (language != null) { - queryParams.addAll(_convertParametersForCollectionFormat('', 'language', language)); - } - queryParams.addAll(_convertParametersForCollectionFormat('', 'allowEmpty', allowEmpty)); - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// To test the collection format in query parameters - /// - /// Parameters: - /// - /// * [List] pipe (required): - /// - /// * [List] ioutil (required): - /// - /// * [List] http (required): - /// - /// * [List] url (required): - /// - /// * [List] context (required): - /// - /// * [String] allowEmpty (required): - /// - /// * [Map] language: - Future testQueryParameterCollectionFormat(List pipe, List ioutil, List http, List url, List context, String allowEmpty, { Map language, }) async { - final response = await testQueryParameterCollectionFormatWithHttpInfo(pipe, ioutil, http, url, context, allowEmpty, language: language, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_classname_tags123_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_classname_tags123_api.dart deleted file mode 100644 index 42639bc346e9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/fake_classname_tags123_api.dart +++ /dev/null @@ -1,83 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class FakeClassnameTags123Api { - FakeClassnameTags123Api([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// To test class name in snake case - /// - /// To test class name in snake case - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future testClassnameWithHttpInfo(ModelClient modelClient,) async { - // Verify required params are set. - if (modelClient == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: modelClient'); - } - - // ignore: prefer_const_declarations - final path = r'/fake_classname_test'; - - // ignore: prefer_final_locals - Object postBody = modelClient; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['api_key_query']; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PATCH', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// To test class name in snake case - /// - /// To test class name in snake case - /// - /// Parameters: - /// - /// * [ModelClient] modelClient (required): - /// client model - Future testClassname(ModelClient modelClient,) async { - final response = await testClassnameWithHttpInfo(modelClient,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return ModelClient.fromJson(json.decode(response.body)); - } - return Future.value(); - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/pet_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/pet_api.dart deleted file mode 100644 index 398fd5762245..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/pet_api.dart +++ /dev/null @@ -1,641 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class PetApi { - PetApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// Add a new pet to the store - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - Future addPetWithHttpInfo(Pet pet,) async { - // Verify required params are set. - if (pet == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: pet'); - } - - // ignore: prefer_const_declarations - final path = r'/pet'; - - // ignore: prefer_final_locals - Object postBody = pet; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['petstore_auth']; - const contentTypes = ['application/json', 'application/xml']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Add a new pet to the store - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - Future addPet(Pet pet,) async { - final response = await addPetWithHttpInfo(pet,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Deletes a pet - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] petId (required): - /// Pet id to delete - /// - /// * [String] apiKey: - Future deletePetWithHttpInfo(int petId, { String apiKey, }) async { - // Verify required params are set. - if (petId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: petId'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/{petId}' - .replaceAll('{petId}', petId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - if (apiKey != null) { - headerParams[r'api_key'] = parameterToString(apiKey); - } - - const authNames = ['petstore_auth']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'DELETE', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Deletes a pet - /// - /// Parameters: - /// - /// * [int] petId (required): - /// Pet id to delete - /// - /// * [String] apiKey: - Future deletePet(int petId, { String apiKey, }) async { - final response = await deletePetWithHttpInfo(petId, apiKey: apiKey, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Finds Pets by status - /// - /// Multiple status values can be provided with comma separated strings - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [List] status (required): - /// Status values that need to be considered for filter - Future findPetsByStatusWithHttpInfo(List status,) async { - // Verify required params are set. - if (status == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: status'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/findByStatus'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('csv', 'status', status)); - - const authNames = ['petstore_auth']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Finds Pets by status - /// - /// Multiple status values can be provided with comma separated strings - /// - /// Parameters: - /// - /// * [List] status (required): - /// Status values that need to be considered for filter - Future> findPetsByStatus(List status,) async { - final response = await findPetsByStatusWithHttpInfo(status,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return (json.decode(response.body) as List) - .map((i) => Pet.fromJson(i)) - .toList(); - } - return Future>.value(); - } - - /// Finds Pets by tags - /// - /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Set] tags (required): - /// Tags to filter by - Future findPetsByTagsWithHttpInfo(Set tags,) async { - // Verify required params are set. - if (tags == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: tags'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/findByTags'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('csv', 'tags', tags)); - - const authNames = ['petstore_auth']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Finds Pets by tags - /// - /// Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - /// - /// Parameters: - /// - /// * [Set] tags (required): - /// Tags to filter by - Future> findPetsByTags(Set tags,) async { - final response = await findPetsByTagsWithHttpInfo(tags,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return (json.decode(response.body) as List) - .map((i) => Pet.fromJson(i)) - .toSet(); - } - return Future>.value(); - } - - /// Find pet by ID - /// - /// Returns a single pet - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to return - Future getPetByIdWithHttpInfo(int petId,) async { - // Verify required params are set. - if (petId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: petId'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/{petId}' - .replaceAll('{petId}', petId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['api_key']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Find pet by ID - /// - /// Returns a single pet - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to return - Future getPetById(int petId,) async { - final response = await getPetByIdWithHttpInfo(petId,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return Pet.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// Update an existing pet - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - Future updatePetWithHttpInfo(Pet pet,) async { - // Verify required params are set. - if (pet == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: pet'); - } - - // ignore: prefer_const_declarations - final path = r'/pet'; - - // ignore: prefer_final_locals - Object postBody = pet; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['petstore_auth']; - const contentTypes = ['application/json', 'application/xml']; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Update an existing pet - /// - /// Parameters: - /// - /// * [Pet] pet (required): - /// Pet object that needs to be added to the store - Future updatePet(Pet pet,) async { - final response = await updatePetWithHttpInfo(pet,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Updates a pet in the store with form data - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet that needs to be updated - /// - /// * [String] name: - /// Updated name of the pet - /// - /// * [String] status: - /// Updated status of the pet - Future updatePetWithFormWithHttpInfo(int petId, { String name, String status, }) async { - // Verify required params are set. - if (petId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: petId'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/{petId}' - .replaceAll('{petId}', petId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['petstore_auth']; - const contentTypes = ['application/x-www-form-urlencoded']; - - if (name != null) { - formParams[r'name'] = parameterToString(name); - } - if (status != null) { - formParams[r'status'] = parameterToString(status); - } - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Updates a pet in the store with form data - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet that needs to be updated - /// - /// * [String] name: - /// Updated name of the pet - /// - /// * [String] status: - /// Updated status of the pet - Future updatePetWithForm(int petId, { String name, String status, }) async { - final response = await updatePetWithFormWithHttpInfo(petId, name: name, status: status, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// uploads an image - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to update - /// - /// * [String] additionalMetadata: - /// Additional data to pass to server - /// - /// * [MultipartFile] file: - /// file to upload - Future uploadFileWithHttpInfo(int petId, { String additionalMetadata, MultipartFile file, }) async { - // Verify required params are set. - if (petId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: petId'); - } - - // ignore: prefer_const_declarations - final path = r'/pet/{petId}/uploadImage' - .replaceAll('{petId}', petId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['petstore_auth']; - const contentTypes = ['multipart/form-data']; - - bool hasFields = false; - final mp = MultipartRequest('POST', Uri.parse(path)); - if (additionalMetadata != null) { - hasFields = true; - mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); - } - if (file != null) { - hasFields = true; - mp.fields[r'file'] = file.field; - mp.files.add(file); - } - if (hasFields) { - postBody = mp; - } - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// uploads an image - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to update - /// - /// * [String] additionalMetadata: - /// Additional data to pass to server - /// - /// * [MultipartFile] file: - /// file to upload - Future uploadFile(int petId, { String additionalMetadata, MultipartFile file, }) async { - final response = await uploadFileWithHttpInfo(petId, additionalMetadata: additionalMetadata, file: file, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return ApiResponse.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// uploads an image (required) - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to update - /// - /// * [MultipartFile] requiredFile (required): - /// file to upload - /// - /// * [String] additionalMetadata: - /// Additional data to pass to server - Future uploadFileWithRequiredFileWithHttpInfo(int petId, MultipartFile requiredFile, { String additionalMetadata, }) async { - // Verify required params are set. - if (petId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: petId'); - } - if (requiredFile == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: requiredFile'); - } - - // ignore: prefer_const_declarations - final path = r'/fake/{petId}/uploadImageWithRequiredFile' - .replaceAll('{petId}', petId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['petstore_auth']; - const contentTypes = ['multipart/form-data']; - - bool hasFields = false; - final mp = MultipartRequest('POST', Uri.parse(path)); - if (additionalMetadata != null) { - hasFields = true; - mp.fields[r'additionalMetadata'] = parameterToString(additionalMetadata); - } - if (requiredFile != null) { - hasFields = true; - mp.fields[r'requiredFile'] = requiredFile.field; - mp.files.add(requiredFile); - } - if (hasFields) { - postBody = mp; - } - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// uploads an image (required) - /// - /// Parameters: - /// - /// * [int] petId (required): - /// ID of pet to update - /// - /// * [MultipartFile] requiredFile (required): - /// file to upload - /// - /// * [String] additionalMetadata: - /// Additional data to pass to server - Future uploadFileWithRequiredFile(int petId, MultipartFile requiredFile, { String additionalMetadata, }) async { - final response = await uploadFileWithRequiredFileWithHttpInfo(petId, requiredFile, additionalMetadata: additionalMetadata, ); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return ApiResponse.fromJson(json.decode(response.body)); - } - return Future.value(); - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/store_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/store_api.dart deleted file mode 100644 index 9b60b28a7e57..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/store_api.dart +++ /dev/null @@ -1,253 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class StoreApi { - StoreApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// Delete purchase order by ID - /// - /// For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] orderId (required): - /// ID of the order that needs to be deleted - Future deleteOrderWithHttpInfo(String orderId,) async { - // Verify required params are set. - if (orderId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: orderId'); - } - - // ignore: prefer_const_declarations - final path = r'/store/order/{order_id}' - .replaceAll('{order_id}', orderId); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'DELETE', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Delete purchase order by ID - /// - /// For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - /// - /// Parameters: - /// - /// * [String] orderId (required): - /// ID of the order that needs to be deleted - Future deleteOrder(String orderId,) async { - final response = await deleteOrderWithHttpInfo(orderId,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Returns pet inventories by status - /// - /// Returns a map of status codes to quantities - /// - /// Note: This method returns the HTTP [Response]. - Future getInventoryWithHttpInfo() async { - // ignore: prefer_const_declarations - final path = r'/store/inventory'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = ['api_key']; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Returns pet inventories by status - /// - /// Returns a map of status codes to quantities - Future> getInventory() async { - final response = await getInventoryWithHttpInfo(); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return Map.from(json.decode(response.body)); - } - return Future>.value(); - } - - /// Find purchase order by ID - /// - /// For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [int] orderId (required): - /// ID of pet that needs to be fetched - Future getOrderByIdWithHttpInfo(int orderId,) async { - // Verify required params are set. - if (orderId == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: orderId'); - } - - // ignore: prefer_const_declarations - final path = r'/store/order/{order_id}' - .replaceAll('{order_id}', orderId.toString()); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Find purchase order by ID - /// - /// For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - /// - /// Parameters: - /// - /// * [int] orderId (required): - /// ID of pet that needs to be fetched - Future getOrderById(int orderId,) async { - final response = await getOrderByIdWithHttpInfo(orderId,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return Order.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// Place an order for a pet - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [Order] order (required): - /// order placed for purchasing the pet - Future placeOrderWithHttpInfo(Order order,) async { - // Verify required params are set. - if (order == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: order'); - } - - // ignore: prefer_const_declarations - final path = r'/store/order'; - - // ignore: prefer_final_locals - Object postBody = order; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Place an order for a pet - /// - /// Parameters: - /// - /// * [Order] order (required): - /// order placed for purchasing the pet - Future placeOrder(Order order,) async { - final response = await placeOrderWithHttpInfo(order,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return Order.fromJson(json.decode(response.body)); - } - return Future.value(); - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/user_api.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/user_api.dart deleted file mode 100644 index 2e3e07579582..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api/user_api.dart +++ /dev/null @@ -1,479 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - - -class UserApi { - UserApi([ApiClient apiClient]) : apiClient = apiClient ?? defaultApiClient; - - final ApiClient apiClient; - - /// Create user - /// - /// This can only be done by the logged in user. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [User] user (required): - /// Created user object - Future createUserWithHttpInfo(User user,) async { - // Verify required params are set. - if (user == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: user'); - } - - // ignore: prefer_const_declarations - final path = r'/user'; - - // ignore: prefer_final_locals - Object postBody = user; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Create user - /// - /// This can only be done by the logged in user. - /// - /// Parameters: - /// - /// * [User] user (required): - /// Created user object - Future createUser(User user,) async { - final response = await createUserWithHttpInfo(user,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Creates list of users with given input array - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [List] user (required): - /// List of user object - Future createUsersWithArrayInputWithHttpInfo(List user,) async { - // Verify required params are set. - if (user == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: user'); - } - - // ignore: prefer_const_declarations - final path = r'/user/createWithArray'; - - // ignore: prefer_final_locals - Object postBody = user; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Creates list of users with given input array - /// - /// Parameters: - /// - /// * [List] user (required): - /// List of user object - Future createUsersWithArrayInput(List user,) async { - final response = await createUsersWithArrayInputWithHttpInfo(user,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Creates list of users with given input array - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [List] user (required): - /// List of user object - Future createUsersWithListInputWithHttpInfo(List user,) async { - // Verify required params are set. - if (user == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: user'); - } - - // ignore: prefer_const_declarations - final path = r'/user/createWithList'; - - // ignore: prefer_final_locals - Object postBody = user; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'POST', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Creates list of users with given input array - /// - /// Parameters: - /// - /// * [List] user (required): - /// List of user object - Future createUsersWithListInput(List user,) async { - final response = await createUsersWithListInputWithHttpInfo(user,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Delete user - /// - /// This can only be done by the logged in user. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] username (required): - /// The name that needs to be deleted - Future deleteUserWithHttpInfo(String username,) async { - // Verify required params are set. - if (username == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: username'); - } - - // ignore: prefer_const_declarations - final path = r'/user/{username}' - .replaceAll('{username}', username); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'DELETE', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Delete user - /// - /// This can only be done by the logged in user. - /// - /// Parameters: - /// - /// * [String] username (required): - /// The name that needs to be deleted - Future deleteUser(String username,) async { - final response = await deleteUserWithHttpInfo(username,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Get user by user name - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] username (required): - /// The name that needs to be fetched. Use user1 for testing. - Future getUserByNameWithHttpInfo(String username,) async { - // Verify required params are set. - if (username == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: username'); - } - - // ignore: prefer_const_declarations - final path = r'/user/{username}' - .replaceAll('{username}', username); - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Get user by user name - /// - /// Parameters: - /// - /// * [String] username (required): - /// The name that needs to be fetched. Use user1 for testing. - Future getUserByName(String username,) async { - final response = await getUserByNameWithHttpInfo(username,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return User.fromJson(json.decode(response.body)); - } - return Future.value(); - } - - /// Logs user into the system - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] username (required): - /// The user name for login - /// - /// * [String] password (required): - /// The password for login in clear text - Future loginUserWithHttpInfo(String username, String password,) async { - // Verify required params are set. - if (username == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: username'); - } - if (password == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: password'); - } - - // ignore: prefer_const_declarations - final path = r'/user/login'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - queryParams.addAll(_convertParametersForCollectionFormat('', 'username', username)); - queryParams.addAll(_convertParametersForCollectionFormat('', 'password', password)); - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Logs user into the system - /// - /// Parameters: - /// - /// * [String] username (required): - /// The user name for login - /// - /// * [String] password (required): - /// The password for login in clear text - Future loginUser(String username, String password,) async { - final response = await loginUserWithHttpInfo(username, password,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - // When a remote server returns no body with a status of 204, we shall not decode it. - // At the time of writing this, `dart:convert` will throw an "Unexpected end of input" - // FormatException when trying to decode an empty string. - if (response.body != null && response.statusCode != HttpStatus.noContent) { - - return response.body as String; - } - return Future.value(); - } - - /// Logs out current logged in user session - /// - /// Note: This method returns the HTTP [Response]. - Future logoutUserWithHttpInfo() async { - // ignore: prefer_const_declarations - final path = r'/user/logout'; - - // ignore: prefer_final_locals - Object postBody; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = []; - - - return apiClient.invokeAPI( - path, - 'GET', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Logs out current logged in user session - Future logoutUser() async { - final response = await logoutUserWithHttpInfo(); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } - - /// Updated user - /// - /// This can only be done by the logged in user. - /// - /// Note: This method returns the HTTP [Response]. - /// - /// Parameters: - /// - /// * [String] username (required): - /// name that need to be deleted - /// - /// * [User] user (required): - /// Updated user object - Future updateUserWithHttpInfo(String username, User user,) async { - // Verify required params are set. - if (username == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: username'); - } - if (user == null) { - throw ApiException(HttpStatus.badRequest, 'Missing required param: user'); - } - - // ignore: prefer_const_declarations - final path = r'/user/{username}' - .replaceAll('{username}', username); - - // ignore: prefer_final_locals - Object postBody = user; - - final queryParams = []; - final headerParams = {}; - final formParams = {}; - - const authNames = []; - const contentTypes = ['application/json']; - - - return apiClient.invokeAPI( - path, - 'PUT', - queryParams, - postBody, - headerParams, - formParams, - contentTypes.isEmpty ? null : contentTypes[0], - authNames, - ); - } - - /// Updated user - /// - /// This can only be done by the logged in user. - /// - /// Parameters: - /// - /// * [String] username (required): - /// name that need to be deleted - /// - /// * [User] user (required): - /// Updated user object - Future updateUser(String username, User user,) async { - final response = await updateUserWithHttpInfo(username, user,); - if (response.statusCode >= HttpStatus.badRequest) { - throw ApiException(response.statusCode, await _decodeBodyBytes(response)); - } - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_client.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_client.dart deleted file mode 100644 index 18e47e887157..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_client.dart +++ /dev/null @@ -1,173 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class ApiClient { - ApiClient({this.basePath = 'http://petstore.swagger.io:80/v2'}) { - // Setup authentications (key: authentication name, value: authentication). - _authentications[r'api_key'] = ApiKeyAuth('header', 'api_key'); - _authentications[r'api_key_query'] = ApiKeyAuth('query', 'api_key_query'); - _authentications[r'bearer_test'] = HttpBearerAuth(); - _authentications[r'http_basic_test'] = HttpBasicAuth(); - _authentications[r'petstore_auth'] = OAuth(); - } - - final String basePath; - - var _client = Client(); - - /// Returns the current HTTP [Client] instance to use in this class. - /// - /// The return value is guaranteed to never be null. - Client get client => _client; - - /// Requests to use a new HTTP [Client] in this class. - /// - /// If the [newClient] is null, an [ArgumentError] is thrown. - set client(Client newClient) { - if (newClient == null) { - throw ArgumentError('New client instance cannot be null.'); - } - _client = newClient; - } - - final _defaultHeaderMap = {}; - final _authentications = {}; - - void addDefaultHeader(String key, String value) { - _defaultHeaderMap[key] = value; - } - - Map get defaultHeaderMap => _defaultHeaderMap; - - /// Returns an unmodifiable [Map] of the authentications, since none should be added - /// or deleted. - Map get authentications => Map.unmodifiable(_authentications); - - T getAuthentication(String name) { - final authentication = _authentications[name]; - return authentication is T ? authentication : null; - } - - // We don't use a Map for queryParams. - // If collectionFormat is 'multi', a key might appear multiple times. - Future invokeAPI( - String path, - String method, - List queryParams, - Object body, - Map headerParams, - Map formParams, - String nullableContentType, - List authNames, - ) async { - _updateParamsForAuth(authNames, queryParams, headerParams); - - headerParams.addAll(_defaultHeaderMap); - - final urlEncodedQueryParams = queryParams - .where((param) => param.value != null) - .map((param) => '$param'); - - final queryString = urlEncodedQueryParams.isNotEmpty - ? '?${urlEncodedQueryParams.join('&')}' - : ''; - - final uri = Uri.parse('$basePath$path$queryString'); - - if (nullableContentType != null) { - headerParams['Content-Type'] = nullableContentType; - } - - try { - // Special case for uploading a single file which isn't a 'multipart/form-data'. - if ( - body is MultipartFile && (nullableContentType == null || - !nullableContentType.toLowerCase().startsWith('multipart/form-data')) - ) { - final request = StreamedRequest(method, uri); - request.headers.addAll(headerParams); - request.contentLength = body.length; - body.finalize().listen( - request.sink.add, - onDone: request.sink.close, - // ignore: avoid_types_on_closure_parameters - onError: (Object error, StackTrace trace) => request.sink.close(), - cancelOnError: true, - ); - final response = await _client.send(request); - return Response.fromStream(response); - } - - if (body is MultipartRequest) { - final request = MultipartRequest(method, uri); - request.fields.addAll(body.fields); - request.files.addAll(body.files); - request.headers.addAll(body.headers); - request.headers.addAll(headerParams); - final response = await _client.send(request); - return Response.fromStream(response); - } - - final msgBody = nullableContentType == 'application/x-www-form-urlencoded' - ? formParams - : await serializeAsync(body); - final nullableHeaderParams = headerParams.isEmpty ? null : headerParams; - - switch(method) { - case 'POST': return await _client.post(uri, headers: nullableHeaderParams, body: msgBody,); - case 'PUT': return await _client.put(uri, headers: nullableHeaderParams, body: msgBody,); - case 'DELETE': return await _client.delete(uri, headers: nullableHeaderParams, body: msgBody,); - case 'PATCH': return await _client.patch(uri, headers: nullableHeaderParams, body: msgBody,); - case 'HEAD': return await _client.head(uri, headers: nullableHeaderParams,); - case 'GET': return await _client.get(uri, headers: nullableHeaderParams,); - } - } on SocketException catch (e, trace) { - throw ApiException.withInner(HttpStatus.badRequest, 'Socket operation failed: $method $path', e, trace,); - } on TlsException catch (e, trace) { - throw ApiException.withInner(HttpStatus.badRequest, 'TLS/SSL communication failed: $method $path', e, trace,); - } on IOException catch (e, trace) { - throw ApiException.withInner(HttpStatus.badRequest, 'I/O operation failed: $method $path', e, trace,); - } on ClientException catch (e, trace) { - throw ApiException.withInner(HttpStatus.badRequest, 'HTTP connection failed: $method $path', e, trace,); - } on Exception catch (e, trace) { - throw ApiException.withInner(HttpStatus.badRequest, 'Exception occurred: $method $path', e, trace,); - } - - throw ApiException(HttpStatus.badRequest, 'Invalid HTTP operation: $method $path',); - } - - // ignore: deprecated_member_use_from_same_package - Future serializeAsync(Object value) async => serialize(value); - - @Deprecated('Scheduled for removal in OpenAPI Generator 6.x. Use serializeAsync() instead.') - String serialize(Object value) => value == null ? '' : json.encode(value); - - /// Update query and header parameters based on authentication settings. - /// @param authNames The authentications to apply - void _updateParamsForAuth( - List authNames, - List queryParams, - Map headerParams, - ) { - for(final authName in authNames) { - final auth = _authentications[authName]; - if (auth == null) { - throw ArgumentError('Authentication undefined: $authName'); - } - auth.applyToParams(queryParams, headerParams); - } - } - -} - -/// Primarily intended for use in an isolate. -Future serializeAsync(Object value) async => value == null ? '' : json.encode(value); diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_exception.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_exception.dart deleted file mode 100644 index 8ffc340b4c9d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_exception.dart +++ /dev/null @@ -1,33 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class ApiException implements Exception { - ApiException(this.code, this.message); - - ApiException.withInner(this.code, this.message, this.innerException, this.stackTrace); - - int code = 0; - String message; - Exception innerException; - StackTrace stackTrace; - - @override - String toString() { - if (message == null) { - return 'ApiException'; - } - if (innerException == null) { - return 'ApiException $code: $message'; - } - return 'ApiException $code: $message (Inner exception: $innerException)\n\n$stackTrace'; - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_helper.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_helper.dart deleted file mode 100644 index e2ffc78abb79..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/api_helper.dart +++ /dev/null @@ -1,121 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class QueryParam { - const QueryParam(this.name, this.value); - - final String name; - final String value; - - @override - String toString() => '${Uri.encodeQueryComponent(name)}=${Uri.encodeQueryComponent(value)}'; -} - -// Ported from the Java version. -Iterable _convertParametersForCollectionFormat( - String collectionFormat, - String name, - dynamic value, -) { - final params = []; - - // preconditions - if (name != null && name.isNotEmpty && value != null) { - if (value is List) { - if (collectionFormat == 'multi') { - return value.map((dynamic v) => QueryParam(name, parameterToString(v)),); - } - - // Default collection format is 'csv'. - if (collectionFormat == null || collectionFormat.isEmpty) { - // ignore: parameter_assignments - collectionFormat = 'csv'; - } - - final delimiter = _delimiters[collectionFormat] ?? ','; - - params.add(QueryParam(name, value.map(parameterToString).join(delimiter)),); - } else { - params.add(QueryParam(name, parameterToString(value),)); - } - } - - return params; -} - -/// Format the given parameter object into a [String]. -String parameterToString(dynamic value) { - if (value == null) { - return ''; - } - if (value is DateTime) { - return value.toUtc().toIso8601String(); - } - if (value is EnumClass) { - return value.toString(); - } - if (value is OuterEnum) { - return value.toString(); - } - if (value is OuterEnumDefaultValue) { - return value.toString(); - } - if (value is OuterEnumInteger) { - return value.toString(); - } - if (value is OuterEnumIntegerDefaultValue) { - return value.toString(); - } - return value.toString(); -} - -/// Returns the decoded body as UTF-8 if the given headers indicate an 'application/json' -/// content type. Otherwise, returns the decoded body as decoded by dart:http package. -Future _decodeBodyBytes(Response response) async { - final contentType = response.headers['content-type']; - return contentType != null && contentType.toLowerCase().startsWith('application/json') - ? response.bodyBytes == null ? null : utf8.decode(response.bodyBytes) - : response.body; -} - -/// Returns a valid [T] value found at the specified Map [key], null otherwise. -T mapValueOfType(dynamic map, String key) { - final dynamic value = map is Map ? map[key] : null; - return value is T ? value : null; -} - -/// Returns a valid Map found at the specified Map [key], null otherwise. -Map mapCastOfType(dynamic map, String key) { - final dynamic value = map is Map ? map[key] : null; - return value is Map ? value.cast() : null; -} - -/// Returns a valid [DateTime] found at the specified Map [key], null otherwise. -DateTime mapDateTime(dynamic map, String key, [String pattern]) { - final dynamic value = map is Map ? map[key] : null; - if (value != null) { - int millis; - if (value is int) { - millis = value; - } else if (value is String) { - if (pattern == _dateEpochMarker) { - millis = int.tryParse(value); - } else { - return DateTime.tryParse(value); - } - } - if (millis != null) { - return DateTime.fromMillisecondsSinceEpoch(millis, isUtc: true); - } - } - return null; -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/api_key_auth.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/api_key_auth.dart deleted file mode 100644 index 0c2303af09e9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/api_key_auth.dart +++ /dev/null @@ -1,38 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class ApiKeyAuth implements Authentication { - ApiKeyAuth(this.location, this.paramName); - - final String location; - final String paramName; - - String apiKeyPrefix; - String apiKey; - - @override - void applyToParams(List queryParams, Map headerParams) { - final value = apiKeyPrefix == null ? apiKey : '$apiKeyPrefix $apiKey'; - - if (location == 'query' && value != null) { - queryParams.add(QueryParam(paramName, value)); - } else if (location == 'header' && value != null) { - headerParams[paramName] = value; - } else if (location == 'cookie' && value != null) { - headerParams.update( - 'Cookie', - (existingCookie) => '$existingCookie; $paramName=$value', - ifAbsent: () => '$paramName=$value', - ); - } - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/authentication.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/authentication.dart deleted file mode 100644 index 4257e1900069..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/authentication.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -// ignore: one_member_abstracts -abstract class Authentication { - /// Apply authentication settings to header and query params. - void applyToParams(List queryParams, Map headerParams); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_basic_auth.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_basic_auth.dart deleted file mode 100644 index 0494f402d958..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_basic_auth.dart +++ /dev/null @@ -1,22 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class HttpBasicAuth implements Authentication { - String username; - String password; - - @override - void applyToParams(List queryParams, Map headerParams) { - final credentials = '${username ?? ''}:${password ?? ''}'; - headerParams['Authorization'] = 'Basic ${base64.encode(utf8.encode(credentials))}'; - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_bearer_auth.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_bearer_auth.dart deleted file mode 100644 index 23e243523dd8..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/http_bearer_auth.dart +++ /dev/null @@ -1,39 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -typedef HttpBearerAuthProvider = String Function(); - -class HttpBearerAuth implements Authentication { - HttpBearerAuth(); - - dynamic _accessToken; - - dynamic get accessToken => _accessToken; - - set accessToken(dynamic accessToken) { - if (accessToken is! String && accessToken is! HttpBearerAuthProvider) { - throw ArgumentError('Type of Bearer accessToken should be a String or a String Function().'); - } - _accessToken = accessToken; - } - - @override - void applyToParams(List queryParams, Map headerParams) { - if (_accessToken is String) { - headerParams['Authorization'] = 'Bearer $_accessToken'; - } else if (_accessToken is HttpBearerAuthProvider) { - headerParams['Authorization'] = 'Bearer ${_accessToken()}'; - } else { - throw ArgumentError('Type of Bearer accessToken should be a String or a String Function().'); - } - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/oauth.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/oauth.dart deleted file mode 100644 index 9299ac13f5bf..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/auth/oauth.dart +++ /dev/null @@ -1,24 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -class OAuth implements Authentication { - OAuth({this.accessToken}); - - String accessToken; - - @override - void applyToParams(List queryParams, Map headerParams) { - if (accessToken != null) { - headerParams['Authorization'] = 'Bearer $accessToken'; - } - } -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/additional_properties_class.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/additional_properties_class.dart deleted file mode 100644 index de1ac810d591..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/additional_properties_class.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class AdditionalPropertiesClass { - /// Returns a new [AdditionalPropertiesClass] instance. - AdditionalPropertiesClass({ - this.mapProperty = const {}, - this.mapOfMapProperty = const {}, - }); - - @JsonKey( - defaultValue: const {}, - name: r'map_property', - required: false, - ) - Map mapProperty; - - @JsonKey( - defaultValue: const {}, - name: r'map_of_map_property', - required: false, - ) - Map> mapOfMapProperty; - - @override - bool operator ==(Object other) => identical(this, other) || other is AdditionalPropertiesClass && - other.mapProperty == mapProperty && - other.mapOfMapProperty == mapOfMapProperty; - - @override - int get hashCode => - (mapProperty == null ? 0 : mapProperty.hashCode) + - (mapOfMapProperty == null ? 0 : mapOfMapProperty.hashCode); - - factory AdditionalPropertiesClass.fromJson(Map json) => _$AdditionalPropertiesClassFromJson(json); - - Map toJson() => _$AdditionalPropertiesClassToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/animal.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/animal.dart deleted file mode 100644 index 8d4772ba251c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/animal.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Animal { - /// Returns a new [Animal] instance. - Animal({ - @required this.className, - this.color = 'red', - }); - - @JsonKey( - nullable: false, - name: r'className', - required: true, - ) - String className; - - @JsonKey( - defaultValue: 'red', - name: r'color', - required: false, - ) - String color; - - @override - bool operator ==(Object other) => identical(this, other) || other is Animal && - other.className == className && - other.color == color; - - @override - int get hashCode => - (className == null ? 0 : className.hashCode) + - (color == null ? 0 : color.hashCode); - - factory Animal.fromJson(Map json) => _$AnimalFromJson(json); - - Map toJson() => _$AnimalToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/api_response.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/api_response.dart deleted file mode 100644 index 24516bbcb1c5..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/api_response.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ApiResponse { - /// Returns a new [ApiResponse] instance. - ApiResponse({ - this.code, - this.type, - this.message, - }); - - @JsonKey( - nullable: false, - name: r'code', - required: false, - ) - int code; - - @JsonKey( - nullable: false, - name: r'type', - required: false, - ) - String type; - - @JsonKey( - nullable: false, - name: r'message', - required: false, - ) - String message; - - @override - bool operator ==(Object other) => identical(this, other) || other is ApiResponse && - other.code == code && - other.type == type && - other.message == message; - - @override - int get hashCode => - (code == null ? 0 : code.hashCode) + - (type == null ? 0 : type.hashCode) + - (message == null ? 0 : message.hashCode); - - factory ApiResponse.fromJson(Map json) => _$ApiResponseFromJson(json); - - Map toJson() => _$ApiResponseToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_array_of_number_only.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_array_of_number_only.dart deleted file mode 100644 index 7d7d2d004eff..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_array_of_number_only.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ArrayOfArrayOfNumberOnly { - /// Returns a new [ArrayOfArrayOfNumberOnly] instance. - ArrayOfArrayOfNumberOnly({ - this.arrayArrayNumber = const [], - }); - - @JsonKey( - defaultValue: const [], - name: r'ArrayArrayNumber', - required: false, - ) - List> arrayArrayNumber; - - @override - bool operator ==(Object other) => identical(this, other) || other is ArrayOfArrayOfNumberOnly && - other.arrayArrayNumber == arrayArrayNumber; - - @override - int get hashCode => - (arrayArrayNumber == null ? 0 : arrayArrayNumber.hashCode); - - factory ArrayOfArrayOfNumberOnly.fromJson(Map json) => _$ArrayOfArrayOfNumberOnlyFromJson(json); - - Map toJson() => _$ArrayOfArrayOfNumberOnlyToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_number_only.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_number_only.dart deleted file mode 100644 index 27bea05339d4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_of_number_only.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ArrayOfNumberOnly { - /// Returns a new [ArrayOfNumberOnly] instance. - ArrayOfNumberOnly({ - this.arrayNumber = const [], - }); - - @JsonKey( - defaultValue: const [], - name: r'ArrayNumber', - required: false, - ) - List arrayNumber; - - @override - bool operator ==(Object other) => identical(this, other) || other is ArrayOfNumberOnly && - other.arrayNumber == arrayNumber; - - @override - int get hashCode => - (arrayNumber == null ? 0 : arrayNumber.hashCode); - - factory ArrayOfNumberOnly.fromJson(Map json) => _$ArrayOfNumberOnlyFromJson(json); - - Map toJson() => _$ArrayOfNumberOnlyToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_test.dart deleted file mode 100644 index 03656ce5fbc3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/array_test.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ArrayTest { - /// Returns a new [ArrayTest] instance. - ArrayTest({ - this.arrayOfString = const [], - this.arrayArrayOfInteger = const [], - this.arrayArrayOfModel = const [], - }); - - @JsonKey( - defaultValue: const [], - name: r'array_of_string', - required: false, - ) - List arrayOfString; - - @JsonKey( - defaultValue: const [], - name: r'array_array_of_integer', - required: false, - ) - List> arrayArrayOfInteger; - - @JsonKey( - defaultValue: const [], - name: r'array_array_of_model', - required: false, - ) - List> arrayArrayOfModel; - - @override - bool operator ==(Object other) => identical(this, other) || other is ArrayTest && - other.arrayOfString == arrayOfString && - other.arrayArrayOfInteger == arrayArrayOfInteger && - other.arrayArrayOfModel == arrayArrayOfModel; - - @override - int get hashCode => - (arrayOfString == null ? 0 : arrayOfString.hashCode) + - (arrayArrayOfInteger == null ? 0 : arrayArrayOfInteger.hashCode) + - (arrayArrayOfModel == null ? 0 : arrayArrayOfModel.hashCode); - - factory ArrayTest.fromJson(Map json) => _$ArrayTestFromJson(json); - - Map toJson() => _$ArrayTestToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/capitalization.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/capitalization.dart deleted file mode 100644 index bb906c2c45e3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/capitalization.dart +++ /dev/null @@ -1,98 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Capitalization { - /// Returns a new [Capitalization] instance. - Capitalization({ - this.smallCamel, - this.capitalCamel, - this.smallSnake, - this.capitalSnake, - this.sCAETHFlowPoints, - this.ATT_NAME, - }); - - @JsonKey( - nullable: false, - name: r'smallCamel', - required: false, - ) - String smallCamel; - - @JsonKey( - nullable: false, - name: r'CapitalCamel', - required: false, - ) - String capitalCamel; - - @JsonKey( - nullable: false, - name: r'small_Snake', - required: false, - ) - String smallSnake; - - @JsonKey( - nullable: false, - name: r'Capital_Snake', - required: false, - ) - String capitalSnake; - - @JsonKey( - nullable: false, - name: r'SCA_ETH_Flow_Points', - required: false, - ) - String sCAETHFlowPoints; - - /// Name of the pet - @JsonKey( - nullable: false, - name: r'ATT_NAME', - required: false, - ) - String ATT_NAME; - - @override - bool operator ==(Object other) => identical(this, other) || other is Capitalization && - other.smallCamel == smallCamel && - other.capitalCamel == capitalCamel && - other.smallSnake == smallSnake && - other.capitalSnake == capitalSnake && - other.sCAETHFlowPoints == sCAETHFlowPoints && - other.ATT_NAME == ATT_NAME; - - @override - int get hashCode => - (smallCamel == null ? 0 : smallCamel.hashCode) + - (capitalCamel == null ? 0 : capitalCamel.hashCode) + - (smallSnake == null ? 0 : smallSnake.hashCode) + - (capitalSnake == null ? 0 : capitalSnake.hashCode) + - (sCAETHFlowPoints == null ? 0 : sCAETHFlowPoints.hashCode) + - (ATT_NAME == null ? 0 : ATT_NAME.hashCode); - - factory Capitalization.fromJson(Map json) => _$CapitalizationFromJson(json); - - Map toJson() => _$CapitalizationToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat.dart deleted file mode 100644 index 479cf62f2cda..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Cat { - /// Returns a new [Cat] instance. - Cat({ - @required this.className, - this.color = 'red', - this.declawed, - }); - - @JsonKey( - nullable: false, - name: r'className', - required: true, - ) - String className; - - @JsonKey( - defaultValue: 'red', - name: r'color', - required: false, - ) - String color; - - @JsonKey( - nullable: false, - name: r'declawed', - required: false, - ) - bool declawed; - - @override - bool operator ==(Object other) => identical(this, other) || other is Cat && - other.className == className && - other.color == color && - other.declawed == declawed; - - @override - int get hashCode => - (className == null ? 0 : className.hashCode) + - (color == null ? 0 : color.hashCode) + - (declawed == null ? 0 : declawed.hashCode); - - factory Cat.fromJson(Map json) => _$CatFromJson(json); - - Map toJson() => _$CatToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat_all_of.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat_all_of.dart deleted file mode 100644 index e3ca59d3b37e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/cat_all_of.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class CatAllOf { - /// Returns a new [CatAllOf] instance. - CatAllOf({ - this.declawed, - }); - - @JsonKey( - nullable: false, - name: r'declawed', - required: false, - ) - bool declawed; - - @override - bool operator ==(Object other) => identical(this, other) || other is CatAllOf && - other.declawed == declawed; - - @override - int get hashCode => - (declawed == null ? 0 : declawed.hashCode); - - factory CatAllOf.fromJson(Map json) => _$CatAllOfFromJson(json); - - Map toJson() => _$CatAllOfToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/category.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/category.dart deleted file mode 100644 index 1275e305b824..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/category.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Category { - /// Returns a new [Category] instance. - Category({ - this.id, - this.name = 'default-name', - }); - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - int id; - - @JsonKey( - defaultValue: 'default-name', - name: r'name', - required: true, - ) - String name; - - @override - bool operator ==(Object other) => identical(this, other) || other is Category && - other.id == id && - other.name == name; - - @override - int get hashCode => - (id == null ? 0 : id.hashCode) + - (name == null ? 0 : name.hashCode); - - factory Category.fromJson(Map json) => _$CategoryFromJson(json); - - Map toJson() => _$CategoryToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/class_model.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/class_model.dart deleted file mode 100644 index fc2d7534ce79..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/class_model.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ClassModel { - /// Returns a new [ClassModel] instance. - ClassModel({ - this.class_, - }); - - @JsonKey( - nullable: false, - name: r'_class', - required: false, - ) - String class_; - - @override - bool operator ==(Object other) => identical(this, other) || other is ClassModel && - other.class_ == class_; - - @override - int get hashCode => - (class_ == null ? 0 : class_.hashCode); - - factory ClassModel.fromJson(Map json) => _$ClassModelFromJson(json); - - Map toJson() => _$ClassModelToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/deprecated_object.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/deprecated_object.dart deleted file mode 100644 index 945fbc85e1f3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/deprecated_object.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class DeprecatedObject { - /// Returns a new [DeprecatedObject] instance. - DeprecatedObject({ - this.name, - }); - - @JsonKey( - nullable: false, - name: r'name', - required: false, - ) - String name; - - @override - bool operator ==(Object other) => identical(this, other) || other is DeprecatedObject && - other.name == name; - - @override - int get hashCode => - (name == null ? 0 : name.hashCode); - - factory DeprecatedObject.fromJson(Map json) => _$DeprecatedObjectFromJson(json); - - Map toJson() => _$DeprecatedObjectToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog.dart deleted file mode 100644 index 8b8d1d36a04a..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Dog { - /// Returns a new [Dog] instance. - Dog({ - @required this.className, - this.color = 'red', - this.breed, - }); - - @JsonKey( - nullable: false, - name: r'className', - required: true, - ) - String className; - - @JsonKey( - defaultValue: 'red', - name: r'color', - required: false, - ) - String color; - - @JsonKey( - nullable: false, - name: r'breed', - required: false, - ) - String breed; - - @override - bool operator ==(Object other) => identical(this, other) || other is Dog && - other.className == className && - other.color == color && - other.breed == breed; - - @override - int get hashCode => - (className == null ? 0 : className.hashCode) + - (color == null ? 0 : color.hashCode) + - (breed == null ? 0 : breed.hashCode); - - factory Dog.fromJson(Map json) => _$DogFromJson(json); - - Map toJson() => _$DogToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog_all_of.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog_all_of.dart deleted file mode 100644 index 0a2672d908a5..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/dog_all_of.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class DogAllOf { - /// Returns a new [DogAllOf] instance. - DogAllOf({ - this.breed, - }); - - @JsonKey( - nullable: false, - name: r'breed', - required: false, - ) - String breed; - - @override - bool operator ==(Object other) => identical(this, other) || other is DogAllOf && - other.breed == breed; - - @override - int get hashCode => - (breed == null ? 0 : breed.hashCode); - - factory DogAllOf.fromJson(Map json) => _$DogAllOfFromJson(json); - - Map toJson() => _$DogAllOfToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_arrays.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_arrays.dart deleted file mode 100644 index f1eb8b7d367b..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_arrays.dart +++ /dev/null @@ -1,69 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class EnumArrays { - /// Returns a new [EnumArrays] instance. - EnumArrays({ - this.justSymbol, - this.arrayEnum = const [], - }); - - @JsonKey( - nullable: false, - name: r'just_symbol', - required: false, - ) - EnumArraysJustSymbolEnum justSymbol; - - @JsonKey( - defaultValue: const [], - name: r'array_enum', - required: false, - ) - List arrayEnum; - - @override - bool operator ==(Object other) => identical(this, other) || other is EnumArrays && - other.justSymbol == justSymbol && - other.arrayEnum == arrayEnum; - - @override - int get hashCode => - (justSymbol == null ? 0 : justSymbol.hashCode) + - (arrayEnum == null ? 0 : arrayEnum.hashCode); - - factory EnumArrays.fromJson(Map json) => _$EnumArraysFromJson(json); - - Map toJson() => _$EnumArraysToJson(this); - - @override - String toString() => toJson().toString(); -} - - -enum EnumArraysJustSymbolEnum { - greaterThanEqual, - dollar, -} - - -enum EnumArraysArrayEnumEnum { - fish, - crab, -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_class.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_class.dart deleted file mode 100644 index 37273211efc4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_class.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -enum EnumClass { - abc, - efg, - leftParenthesisXyzRightParenthesis, -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_test.dart deleted file mode 100644 index 27d07a985e26..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/enum_test.dart +++ /dev/null @@ -1,143 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class EnumTest { - /// Returns a new [EnumTest] instance. - EnumTest({ - this.enumString, - @required this.enumStringRequired, - this.enumInteger, - this.enumNumber, - this.outerEnum, - this.outerEnumInteger, - this.outerEnumDefaultValue, - this.outerEnumIntegerDefaultValue, - }); - - @JsonKey( - nullable: false, - name: r'enum_string', - required: false, - ) - EnumTestEnumStringEnum enumString; - - @JsonKey( - nullable: false, - name: r'enum_string_required', - required: true, - ) - EnumTestEnumStringRequiredEnum enumStringRequired; - - @JsonKey( - nullable: false, - name: r'enum_integer', - required: false, - ) - EnumTestEnumIntegerEnum enumInteger; - - @JsonKey( - nullable: false, - name: r'enum_number', - required: false, - ) - EnumTestEnumNumberEnum enumNumber; - - @JsonKey( - nullable: true, - name: r'outerEnum', - required: false, - ) - OuterEnum outerEnum; - - @JsonKey( - nullable: false, - name: r'outerEnumInteger', - required: false, - ) - OuterEnumInteger outerEnumInteger; - - @JsonKey( - nullable: false, - name: r'outerEnumDefaultValue', - required: false, - ) - OuterEnumDefaultValue outerEnumDefaultValue; - - @JsonKey( - nullable: false, - name: r'outerEnumIntegerDefaultValue', - required: false, - ) - OuterEnumIntegerDefaultValue outerEnumIntegerDefaultValue; - - @override - bool operator ==(Object other) => identical(this, other) || other is EnumTest && - other.enumString == enumString && - other.enumStringRequired == enumStringRequired && - other.enumInteger == enumInteger && - other.enumNumber == enumNumber && - other.outerEnum == outerEnum && - other.outerEnumInteger == outerEnumInteger && - other.outerEnumDefaultValue == outerEnumDefaultValue && - other.outerEnumIntegerDefaultValue == outerEnumIntegerDefaultValue; - - @override - int get hashCode => - (enumString == null ? 0 : enumString.hashCode) + - (enumStringRequired == null ? 0 : enumStringRequired.hashCode) + - (enumInteger == null ? 0 : enumInteger.hashCode) + - (enumNumber == null ? 0 : enumNumber.hashCode) + - (outerEnum == null ? 0 : outerEnum.hashCode) + - (outerEnumInteger == null ? 0 : outerEnumInteger.hashCode) + - (outerEnumDefaultValue == null ? 0 : outerEnumDefaultValue.hashCode) + - (outerEnumIntegerDefaultValue == null ? 0 : outerEnumIntegerDefaultValue.hashCode); - - factory EnumTest.fromJson(Map json) => _$EnumTestFromJson(json); - - Map toJson() => _$EnumTestToJson(this); - - @override - String toString() => toJson().toString(); -} - - -enum EnumTestEnumStringEnum { - UPPER, - lower, - empty, -} - - -enum EnumTestEnumStringRequiredEnum { - UPPER, - lower, - empty, -} - - -enum EnumTestEnumIntegerEnum { - number1, - numberNegative1, -} - - -enum EnumTestEnumNumberEnum { - number1Period1, - numberNegative1Period2, -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/file_schema_test_class.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/file_schema_test_class.dart deleted file mode 100644 index 15a0b8d7daa5..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/file_schema_test_class.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class FileSchemaTestClass { - /// Returns a new [FileSchemaTestClass] instance. - FileSchemaTestClass({ - this.file, - this.files = const [], - }); - - @JsonKey( - nullable: false, - name: r'file', - required: false, - ) - ModelFile file; - - @JsonKey( - defaultValue: const [], - name: r'files', - required: false, - ) - List files; - - @override - bool operator ==(Object other) => identical(this, other) || other is FileSchemaTestClass && - other.file == file && - other.files == files; - - @override - int get hashCode => - (file == null ? 0 : file.hashCode) + - (files == null ? 0 : files.hashCode); - - factory FileSchemaTestClass.fromJson(Map json) => _$FileSchemaTestClassFromJson(json); - - Map toJson() => _$FileSchemaTestClassToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/foo.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/foo.dart deleted file mode 100644 index a2917b7c2e8f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/foo.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Foo { - /// Returns a new [Foo] instance. - Foo({ - this.bar = 'bar', - }); - - @JsonKey( - defaultValue: 'bar', - name: r'bar', - required: false, - ) - String bar; - - @override - bool operator ==(Object other) => identical(this, other) || other is Foo && - other.bar == bar; - - @override - int get hashCode => - (bar == null ? 0 : bar.hashCode); - - factory Foo.fromJson(Map json) => _$FooFromJson(json); - - Map toJson() => _$FooToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/format_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/format_test.dart deleted file mode 100644 index 6c66d9281754..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/format_test.dart +++ /dev/null @@ -1,205 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class FormatTest { - /// Returns a new [FormatTest] instance. - FormatTest({ - this.integer, - this.int32, - this.int64, - @required this.number, - this.float, - this.double_, - this.decimal, - this.string, - @required this.byte, - this.binary, - @required this.date, - this.dateTime, - this.uuid, - @required this.password, - this.patternWithDigits, - this.patternWithDigitsAndDelimiter, - }); - - // minimum: 10 - // maximum: 100 - @JsonKey( - nullable: false, - name: r'integer', - required: false, - ) - int integer; - - // minimum: 20 - // maximum: 200 - @JsonKey( - nullable: false, - name: r'int32', - required: false, - ) - int int32; - - @JsonKey( - nullable: false, - name: r'int64', - required: false, - ) - int int64; - - // minimum: 32.1 - // maximum: 543.2 - @JsonKey( - nullable: false, - name: r'number', - required: true, - ) - num number; - - // minimum: 54.3 - // maximum: 987.6 - @JsonKey( - nullable: false, - name: r'float', - required: false, - ) - double float; - - // minimum: 67.8 - // maximum: 123.4 - @JsonKey( - nullable: false, - name: r'double', - required: false, - ) - double double_; - - @JsonKey( - nullable: false, - name: r'decimal', - required: false, - ) - double decimal; - - @JsonKey( - nullable: false, - name: r'string', - required: false, - ) - String string; - - @JsonKey( - nullable: false, - name: r'byte', - required: true, - ) - String byte; - - @JsonKey(ignore: true) - MultipartFile binary; - - @JsonKey( - nullable: false, - name: r'date', - required: true, - ) - DateTime date; - - @JsonKey( - nullable: false, - name: r'dateTime', - required: false, - ) - DateTime dateTime; - - @JsonKey( - nullable: false, - name: r'uuid', - required: false, - ) - String uuid; - - @JsonKey( - nullable: false, - name: r'password', - required: true, - ) - String password; - - /// A string that is a 10 digit number. Can have leading zeros. - @JsonKey( - nullable: false, - name: r'pattern_with_digits', - required: false, - ) - String patternWithDigits; - - /// A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. - @JsonKey( - nullable: false, - name: r'pattern_with_digits_and_delimiter', - required: false, - ) - String patternWithDigitsAndDelimiter; - - @override - bool operator ==(Object other) => identical(this, other) || other is FormatTest && - other.integer == integer && - other.int32 == int32 && - other.int64 == int64 && - other.number == number && - other.float == float && - other.double_ == double_ && - other.decimal == decimal && - other.string == string && - other.byte == byte && - other.binary == binary && - other.date == date && - other.dateTime == dateTime && - other.uuid == uuid && - other.password == password && - other.patternWithDigits == patternWithDigits && - other.patternWithDigitsAndDelimiter == patternWithDigitsAndDelimiter; - - @override - int get hashCode => - (integer == null ? 0 : integer.hashCode) + - (int32 == null ? 0 : int32.hashCode) + - (int64 == null ? 0 : int64.hashCode) + - (number == null ? 0 : number.hashCode) + - (float == null ? 0 : float.hashCode) + - (double_ == null ? 0 : double_.hashCode) + - (decimal == null ? 0 : decimal.hashCode) + - (string == null ? 0 : string.hashCode) + - (byte == null ? 0 : byte.hashCode) + - (binary == null ? 0 : binary.hashCode) + - (date == null ? 0 : date.hashCode) + - (dateTime == null ? 0 : dateTime.hashCode) + - (uuid == null ? 0 : uuid.hashCode) + - (password == null ? 0 : password.hashCode) + - (patternWithDigits == null ? 0 : patternWithDigits.hashCode) + - (patternWithDigitsAndDelimiter == null ? 0 : patternWithDigitsAndDelimiter.hashCode); - - factory FormatTest.fromJson(Map json) => _$FormatTestFromJson(json); - - Map toJson() => _$FormatTestToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/has_only_read_only.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/has_only_read_only.dart deleted file mode 100644 index 5d016561de78..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/has_only_read_only.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class HasOnlyReadOnly { - /// Returns a new [HasOnlyReadOnly] instance. - HasOnlyReadOnly({ - this.bar, - this.foo, - }); - - @JsonKey( - nullable: false, - name: r'bar', - required: false, - ) - String bar; - - @JsonKey( - nullable: false, - name: r'foo', - required: false, - ) - String foo; - - @override - bool operator ==(Object other) => identical(this, other) || other is HasOnlyReadOnly && - other.bar == bar && - other.foo == foo; - - @override - int get hashCode => - (bar == null ? 0 : bar.hashCode) + - (foo == null ? 0 : foo.hashCode); - - factory HasOnlyReadOnly.fromJson(Map json) => _$HasOnlyReadOnlyFromJson(json); - - Map toJson() => _$HasOnlyReadOnlyToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/health_check_result.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/health_check_result.dart deleted file mode 100644 index eaa93075b46f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/health_check_result.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class HealthCheckResult { - /// Returns a new [HealthCheckResult] instance. - HealthCheckResult({ - this.nullableMessage, - }); - - @JsonKey( - nullable: true, - name: r'NullableMessage', - required: false, - ) - String nullableMessage; - - @override - bool operator ==(Object other) => identical(this, other) || other is HealthCheckResult && - other.nullableMessage == nullableMessage; - - @override - int get hashCode => - (nullableMessage == null ? 0 : nullableMessage.hashCode); - - factory HealthCheckResult.fromJson(Map json) => _$HealthCheckResultFromJson(json); - - Map toJson() => _$HealthCheckResultToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/inline_response_default.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/inline_response_default.dart deleted file mode 100644 index 55baf5104085..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/inline_response_default.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class InlineResponseDefault { - /// Returns a new [InlineResponseDefault] instance. - InlineResponseDefault({ - this.string, - }); - - @JsonKey( - nullable: false, - name: r'string', - required: false, - ) - Foo string; - - @override - bool operator ==(Object other) => identical(this, other) || other is InlineResponseDefault && - other.string == string; - - @override - int get hashCode => - (string == null ? 0 : string.hashCode); - - factory InlineResponseDefault.fromJson(Map json) => _$InlineResponseDefaultFromJson(json); - - Map toJson() => _$InlineResponseDefaultToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/map_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/map_test.dart deleted file mode 100644 index 3c06f1815f75..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/map_test.dart +++ /dev/null @@ -1,83 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class MapTest { - /// Returns a new [MapTest] instance. - MapTest({ - this.mapMapOfString = const {}, - this.mapOfEnumString = const {}, - this.directMap = const {}, - this.indirectMap = const {}, - }); - - @JsonKey( - defaultValue: const {}, - name: r'map_map_of_string', - required: false, - ) - Map> mapMapOfString; - - @JsonKey( - defaultValue: const {}, - name: r'map_of_enum_string', - required: false, - ) - Map mapOfEnumString; - - @JsonKey( - defaultValue: const {}, - name: r'direct_map', - required: false, - ) - Map directMap; - - @JsonKey( - defaultValue: const {}, - name: r'indirect_map', - required: false, - ) - Map indirectMap; - - @override - bool operator ==(Object other) => identical(this, other) || other is MapTest && - other.mapMapOfString == mapMapOfString && - other.mapOfEnumString == mapOfEnumString && - other.directMap == directMap && - other.indirectMap == indirectMap; - - @override - int get hashCode => - (mapMapOfString == null ? 0 : mapMapOfString.hashCode) + - (mapOfEnumString == null ? 0 : mapOfEnumString.hashCode) + - (directMap == null ? 0 : directMap.hashCode) + - (indirectMap == null ? 0 : indirectMap.hashCode); - - factory MapTest.fromJson(Map json) => _$MapTestFromJson(json); - - Map toJson() => _$MapTestToJson(this); - - @override - String toString() => toJson().toString(); -} - - -enum MapTestMapOfEnumStringEnum { - UPPER, - lower, -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/mixed_properties_and_additional_properties_class.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/mixed_properties_and_additional_properties_class.dart deleted file mode 100644 index 1fd6acc5160f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/mixed_properties_and_additional_properties_class.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class MixedPropertiesAndAdditionalPropertiesClass { - /// Returns a new [MixedPropertiesAndAdditionalPropertiesClass] instance. - MixedPropertiesAndAdditionalPropertiesClass({ - this.uuid, - this.dateTime, - this.map = const {}, - }); - - @JsonKey( - nullable: false, - name: r'uuid', - required: false, - ) - String uuid; - - @JsonKey( - nullable: false, - name: r'dateTime', - required: false, - ) - DateTime dateTime; - - @JsonKey( - defaultValue: const {}, - name: r'map', - required: false, - ) - Map map; - - @override - bool operator ==(Object other) => identical(this, other) || other is MixedPropertiesAndAdditionalPropertiesClass && - other.uuid == uuid && - other.dateTime == dateTime && - other.map == map; - - @override - int get hashCode => - (uuid == null ? 0 : uuid.hashCode) + - (dateTime == null ? 0 : dateTime.hashCode) + - (map == null ? 0 : map.hashCode); - - factory MixedPropertiesAndAdditionalPropertiesClass.fromJson(Map json) => _$MixedPropertiesAndAdditionalPropertiesClassFromJson(json); - - Map toJson() => _$MixedPropertiesAndAdditionalPropertiesClassToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model200_response.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model200_response.dart deleted file mode 100644 index a1c8996439b5..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model200_response.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Model200Response { - /// Returns a new [Model200Response] instance. - Model200Response({ - this.name, - this.class_, - }); - - @JsonKey( - nullable: false, - name: r'name', - required: false, - ) - int name; - - @JsonKey( - nullable: false, - name: r'class', - required: false, - ) - String class_; - - @override - bool operator ==(Object other) => identical(this, other) || other is Model200Response && - other.name == name && - other.class_ == class_; - - @override - int get hashCode => - (name == null ? 0 : name.hashCode) + - (class_ == null ? 0 : class_.hashCode); - - factory Model200Response.fromJson(Map json) => _$Model200ResponseFromJson(json); - - Map toJson() => _$Model200ResponseToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_client.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_client.dart deleted file mode 100644 index 70e3a6ebeb83..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_client.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ModelClient { - /// Returns a new [ModelClient] instance. - ModelClient({ - this.client, - }); - - @JsonKey( - nullable: false, - name: r'client', - required: false, - ) - String client; - - @override - bool operator ==(Object other) => identical(this, other) || other is ModelClient && - other.client == client; - - @override - int get hashCode => - (client == null ? 0 : client.hashCode); - - factory ModelClient.fromJson(Map json) => _$ModelClientFromJson(json); - - Map toJson() => _$ModelClientToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_file.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_file.dart deleted file mode 100644 index 6fb382ebf1c1..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_file.dart +++ /dev/null @@ -1,48 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ModelFile { - /// Returns a new [ModelFile] instance. - ModelFile({ - this.sourceURI, - }); - - /// Test capitalization - @JsonKey( - nullable: false, - name: r'sourceURI', - required: false, - ) - String sourceURI; - - @override - bool operator ==(Object other) => identical(this, other) || other is ModelFile && - other.sourceURI == sourceURI; - - @override - int get hashCode => - (sourceURI == null ? 0 : sourceURI.hashCode); - - factory ModelFile.fromJson(Map json) => _$ModelFileFromJson(json); - - Map toJson() => _$ModelFileToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_list.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_list.dart deleted file mode 100644 index b69abf130f50..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_list.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ModelList { - /// Returns a new [ModelList] instance. - ModelList({ - this.n123list, - }); - - @JsonKey( - nullable: false, - name: r'123-list', - required: false, - ) - String n123list; - - @override - bool operator ==(Object other) => identical(this, other) || other is ModelList && - other.n123list == n123list; - - @override - int get hashCode => - (n123list == null ? 0 : n123list.hashCode); - - factory ModelList.fromJson(Map json) => _$ModelListFromJson(json); - - Map toJson() => _$ModelListToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_return.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_return.dart deleted file mode 100644 index 0a18d3ed4890..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/model_return.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ModelReturn { - /// Returns a new [ModelReturn] instance. - ModelReturn({ - this.return_, - }); - - @JsonKey( - nullable: false, - name: r'return', - required: false, - ) - int return_; - - @override - bool operator ==(Object other) => identical(this, other) || other is ModelReturn && - other.return_ == return_; - - @override - int get hashCode => - (return_ == null ? 0 : return_.hashCode); - - factory ModelReturn.fromJson(Map json) => _$ModelReturnFromJson(json); - - Map toJson() => _$ModelReturnToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/name.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/name.dart deleted file mode 100644 index c554627bfcde..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/name.dart +++ /dev/null @@ -1,77 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Name { - /// Returns a new [Name] instance. - Name({ - @required this.name, - this.snakeCase, - this.property, - this.n123number, - }); - - @JsonKey( - nullable: false, - name: r'name', - required: true, - ) - int name; - - @JsonKey( - nullable: false, - name: r'snake_case', - required: false, - ) - int snakeCase; - - @JsonKey( - nullable: false, - name: r'property', - required: false, - ) - String property; - - @JsonKey( - nullable: false, - name: r'123Number', - required: false, - ) - int n123number; - - @override - bool operator ==(Object other) => identical(this, other) || other is Name && - other.name == name && - other.snakeCase == snakeCase && - other.property == property && - other.n123number == n123number; - - @override - int get hashCode => - (name == null ? 0 : name.hashCode) + - (snakeCase == null ? 0 : snakeCase.hashCode) + - (property == null ? 0 : property.hashCode) + - (n123number == null ? 0 : n123number.hashCode); - - factory Name.fromJson(Map json) => _$NameFromJson(json); - - Map toJson() => _$NameToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/nullable_class.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/nullable_class.dart deleted file mode 100644 index 68c0deefc5af..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/nullable_class.dart +++ /dev/null @@ -1,157 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class NullableClass { - /// Returns a new [NullableClass] instance. - NullableClass({ - this.integerProp, - this.numberProp, - this.booleanProp, - this.stringProp, - this.dateProp, - this.datetimeProp, - this.arrayNullableProp, - this.arrayAndItemsNullableProp, - this.arrayItemsNullable = const [], - this.objectNullableProp, - this.objectAndItemsNullableProp, - this.objectItemsNullable = const {}, - }); - - @JsonKey( - nullable: true, - name: r'integer_prop', - required: false, - ) - int integerProp; - - @JsonKey( - nullable: true, - name: r'number_prop', - required: false, - ) - num numberProp; - - @JsonKey( - nullable: true, - name: r'boolean_prop', - required: false, - ) - bool booleanProp; - - @JsonKey( - nullable: true, - name: r'string_prop', - required: false, - ) - String stringProp; - - @JsonKey( - nullable: true, - name: r'date_prop', - required: false, - ) - DateTime dateProp; - - @JsonKey( - nullable: true, - name: r'datetime_prop', - required: false, - ) - DateTime datetimeProp; - - @JsonKey( - defaultValue: const [], - name: r'array_nullable_prop', - required: false, - ) - List arrayNullableProp; - - @JsonKey( - defaultValue: const [], - name: r'array_and_items_nullable_prop', - required: false, - ) - List arrayAndItemsNullableProp; - - @JsonKey( - defaultValue: const [], - name: r'array_items_nullable', - required: false, - ) - List arrayItemsNullable; - - @JsonKey( - defaultValue: const {}, - name: r'object_nullable_prop', - required: false, - ) - Map objectNullableProp; - - @JsonKey( - defaultValue: const {}, - name: r'object_and_items_nullable_prop', - required: false, - ) - Map objectAndItemsNullableProp; - - @JsonKey( - defaultValue: const {}, - name: r'object_items_nullable', - required: false, - ) - Map objectItemsNullable; - - @override - bool operator ==(Object other) => identical(this, other) || other is NullableClass && - other.integerProp == integerProp && - other.numberProp == numberProp && - other.booleanProp == booleanProp && - other.stringProp == stringProp && - other.dateProp == dateProp && - other.datetimeProp == datetimeProp && - other.arrayNullableProp == arrayNullableProp && - other.arrayAndItemsNullableProp == arrayAndItemsNullableProp && - other.arrayItemsNullable == arrayItemsNullable && - other.objectNullableProp == objectNullableProp && - other.objectAndItemsNullableProp == objectAndItemsNullableProp && - other.objectItemsNullable == objectItemsNullable; - - @override - int get hashCode => - (integerProp == null ? 0 : integerProp.hashCode) + - (numberProp == null ? 0 : numberProp.hashCode) + - (booleanProp == null ? 0 : booleanProp.hashCode) + - (stringProp == null ? 0 : stringProp.hashCode) + - (dateProp == null ? 0 : dateProp.hashCode) + - (datetimeProp == null ? 0 : datetimeProp.hashCode) + - (arrayNullableProp == null ? 0 : arrayNullableProp.hashCode) + - (arrayAndItemsNullableProp == null ? 0 : arrayAndItemsNullableProp.hashCode) + - (arrayItemsNullable == null ? 0 : arrayItemsNullable.hashCode) + - (objectNullableProp == null ? 0 : objectNullableProp.hashCode) + - (objectAndItemsNullableProp == null ? 0 : objectAndItemsNullableProp.hashCode) + - (objectItemsNullable == null ? 0 : objectItemsNullable.hashCode); - - factory NullableClass.fromJson(Map json) => _$NullableClassFromJson(json); - - Map toJson() => _$NullableClassToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/number_only.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/number_only.dart deleted file mode 100644 index deccb0c854d9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/number_only.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class NumberOnly { - /// Returns a new [NumberOnly] instance. - NumberOnly({ - this.justNumber, - }); - - @JsonKey( - nullable: false, - name: r'JustNumber', - required: false, - ) - num justNumber; - - @override - bool operator ==(Object other) => identical(this, other) || other is NumberOnly && - other.justNumber == justNumber; - - @override - int get hashCode => - (justNumber == null ? 0 : justNumber.hashCode); - - factory NumberOnly.fromJson(Map json) => _$NumberOnlyFromJson(json); - - Map toJson() => _$NumberOnlyToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/object_with_deprecated_fields.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/object_with_deprecated_fields.dart deleted file mode 100644 index 936ecc671f8f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/object_with_deprecated_fields.dart +++ /dev/null @@ -1,77 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ObjectWithDeprecatedFields { - /// Returns a new [ObjectWithDeprecatedFields] instance. - ObjectWithDeprecatedFields({ - this.uuid, - this.id, - this.deprecatedRef, - this.bars = const [], - }); - - @JsonKey( - nullable: false, - name: r'uuid', - required: false, - ) - String uuid; - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - num id; - - @JsonKey( - nullable: false, - name: r'deprecatedRef', - required: false, - ) - DeprecatedObject deprecatedRef; - - @JsonKey( - defaultValue: const [], - name: r'bars', - required: false, - ) - List bars; - - @override - bool operator ==(Object other) => identical(this, other) || other is ObjectWithDeprecatedFields && - other.uuid == uuid && - other.id == id && - other.deprecatedRef == deprecatedRef && - other.bars == bars; - - @override - int get hashCode => - (uuid == null ? 0 : uuid.hashCode) + - (id == null ? 0 : id.hashCode) + - (deprecatedRef == null ? 0 : deprecatedRef.hashCode) + - (bars == null ? 0 : bars.hashCode); - - factory ObjectWithDeprecatedFields.fromJson(Map json) => _$ObjectWithDeprecatedFieldsFromJson(json); - - Map toJson() => _$ObjectWithDeprecatedFieldsToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/order.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/order.dart deleted file mode 100644 index 096ccfe4b4ea..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/order.dart +++ /dev/null @@ -1,105 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Order { - /// Returns a new [Order] instance. - Order({ - this.id, - this.petId, - this.quantity, - this.shipDate, - this.status, - this.complete = false, - }); - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - int id; - - @JsonKey( - nullable: false, - name: r'petId', - required: false, - ) - int petId; - - @JsonKey( - nullable: false, - name: r'quantity', - required: false, - ) - int quantity; - - @JsonKey( - nullable: false, - name: r'shipDate', - required: false, - ) - DateTime shipDate; - - /// Order Status - @JsonKey( - nullable: false, - name: r'status', - required: false, - ) - OrderStatusEnum status; - - @JsonKey( - defaultValue: false, - name: r'complete', - required: false, - ) - bool complete; - - @override - bool operator ==(Object other) => identical(this, other) || other is Order && - other.id == id && - other.petId == petId && - other.quantity == quantity && - other.shipDate == shipDate && - other.status == status && - other.complete == complete; - - @override - int get hashCode => - (id == null ? 0 : id.hashCode) + - (petId == null ? 0 : petId.hashCode) + - (quantity == null ? 0 : quantity.hashCode) + - (shipDate == null ? 0 : shipDate.hashCode) + - (status == null ? 0 : status.hashCode) + - (complete == null ? 0 : complete.hashCode); - - factory Order.fromJson(Map json) => _$OrderFromJson(json); - - Map toJson() => _$OrderToJson(this); - - @override - String toString() => toJson().toString(); -} - -/// Order Status -enum OrderStatusEnum { - placed, - approved, - delivered, -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_composite.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_composite.dart deleted file mode 100644 index 2f2bd6f221ed..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_composite.dart +++ /dev/null @@ -1,67 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class OuterComposite { - /// Returns a new [OuterComposite] instance. - OuterComposite({ - this.myNumber, - this.myString, - this.myBoolean, - }); - - @JsonKey( - nullable: false, - name: r'my_number', - required: false, - ) - num myNumber; - - @JsonKey( - nullable: false, - name: r'my_string', - required: false, - ) - String myString; - - @JsonKey( - nullable: false, - name: r'my_boolean', - required: false, - ) - bool myBoolean; - - @override - bool operator ==(Object other) => identical(this, other) || other is OuterComposite && - other.myNumber == myNumber && - other.myString == myString && - other.myBoolean == myBoolean; - - @override - int get hashCode => - (myNumber == null ? 0 : myNumber.hashCode) + - (myString == null ? 0 : myString.hashCode) + - (myBoolean == null ? 0 : myBoolean.hashCode); - - factory OuterComposite.fromJson(Map json) => _$OuterCompositeFromJson(json); - - Map toJson() => _$OuterCompositeToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum.dart deleted file mode 100644 index a91f63c0ed29..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -enum OuterEnum { - placed, - approved, - delivered, -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_default_value.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_default_value.dart deleted file mode 100644 index a1e262354556..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_default_value.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -enum OuterEnumDefaultValue { - placed, - approved, - delivered, -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer.dart deleted file mode 100644 index 5fa167be541c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -enum OuterEnumInteger { - number0, - number1, - number2, -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer_default_value.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer_default_value.dart deleted file mode 100644 index 5d6ed62ea7c8..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_enum_integer_default_value.dart +++ /dev/null @@ -1,17 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -enum OuterEnumIntegerDefaultValue { - number0, - number1, - number2, -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_object_with_enum_property.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_object_with_enum_property.dart deleted file mode 100644 index 9971d8b005db..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/outer_object_with_enum_property.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class OuterObjectWithEnumProperty { - /// Returns a new [OuterObjectWithEnumProperty] instance. - OuterObjectWithEnumProperty({ - @required this.value, - }); - - @JsonKey( - nullable: false, - name: r'value', - required: true, - ) - OuterEnumInteger value; - - @override - bool operator ==(Object other) => identical(this, other) || other is OuterObjectWithEnumProperty && - other.value == value; - - @override - int get hashCode => - (value == null ? 0 : value.hashCode); - - factory OuterObjectWithEnumProperty.fromJson(Map json) => _$OuterObjectWithEnumPropertyFromJson(json); - - Map toJson() => _$OuterObjectWithEnumPropertyToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/pet.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/pet.dart deleted file mode 100644 index 572f3e67f7cc..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/pet.dart +++ /dev/null @@ -1,105 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Pet { - /// Returns a new [Pet] instance. - Pet({ - this.id, - this.category, - @required this.name, - this.photoUrls = const {}, - this.tags = const [], - this.status, - }); - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - int id; - - @JsonKey( - nullable: false, - name: r'category', - required: false, - ) - Category category; - - @JsonKey( - nullable: false, - name: r'name', - required: true, - ) - String name; - - @JsonKey( - defaultValue: const {}, - name: r'photoUrls', - required: true, - ) - Set photoUrls; - - @JsonKey( - defaultValue: const [], - name: r'tags', - required: false, - ) - List tags; - - /// pet status in the store - @JsonKey( - nullable: false, - name: r'status', - required: false, - ) - PetStatusEnum status; - - @override - bool operator ==(Object other) => identical(this, other) || other is Pet && - other.id == id && - other.category == category && - other.name == name && - other.photoUrls == photoUrls && - other.tags == tags && - other.status == status; - - @override - int get hashCode => - (id == null ? 0 : id.hashCode) + - (category == null ? 0 : category.hashCode) + - (name == null ? 0 : name.hashCode) + - (photoUrls == null ? 0 : photoUrls.hashCode) + - (tags == null ? 0 : tags.hashCode) + - (status == null ? 0 : status.hashCode); - - factory Pet.fromJson(Map json) => _$PetFromJson(json); - - Map toJson() => _$PetToJson(this); - - @override - String toString() => toJson().toString(); -} - -/// pet status in the store -enum PetStatusEnum { - available, - pending, - sold, -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/read_only_first.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/read_only_first.dart deleted file mode 100644 index 46af402a0e5a..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/read_only_first.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class ReadOnlyFirst { - /// Returns a new [ReadOnlyFirst] instance. - ReadOnlyFirst({ - this.bar, - this.baz, - }); - - @JsonKey( - nullable: false, - name: r'bar', - required: false, - ) - String bar; - - @JsonKey( - nullable: false, - name: r'baz', - required: false, - ) - String baz; - - @override - bool operator ==(Object other) => identical(this, other) || other is ReadOnlyFirst && - other.bar == bar && - other.baz == baz; - - @override - int get hashCode => - (bar == null ? 0 : bar.hashCode) + - (baz == null ? 0 : baz.hashCode); - - factory ReadOnlyFirst.fromJson(Map json) => _$ReadOnlyFirstFromJson(json); - - Map toJson() => _$ReadOnlyFirstToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/special_model_name.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/special_model_name.dart deleted file mode 100644 index 34e81dbe4d98..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/special_model_name.dart +++ /dev/null @@ -1,47 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class SpecialModelName { - /// Returns a new [SpecialModelName] instance. - SpecialModelName({ - this.dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket, - }); - - @JsonKey( - nullable: false, - name: r'$special[property.name]', - required: false, - ) - int dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket; - - @override - bool operator ==(Object other) => identical(this, other) || other is SpecialModelName && - other.dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket == dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket; - - @override - int get hashCode => - (dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket == null ? 0 : dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket.hashCode); - - factory SpecialModelName.fromJson(Map json) => _$SpecialModelNameFromJson(json); - - Map toJson() => _$SpecialModelNameToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/tag.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/tag.dart deleted file mode 100644 index 797f3fdcded3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/tag.dart +++ /dev/null @@ -1,57 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class Tag { - /// Returns a new [Tag] instance. - Tag({ - this.id, - this.name, - }); - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - int id; - - @JsonKey( - nullable: false, - name: r'name', - required: false, - ) - String name; - - @override - bool operator ==(Object other) => identical(this, other) || other is Tag && - other.id == id && - other.name == name; - - @override - int get hashCode => - (id == null ? 0 : id.hashCode) + - (name == null ? 0 : name.hashCode); - - factory Tag.fromJson(Map json) => _$TagFromJson(json); - - Map toJson() => _$TagToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/user.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/user.dart deleted file mode 100644 index 8ca6ebef6958..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/lib/model/user.dart +++ /dev/null @@ -1,118 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: constant_identifier_names -// ignore_for_file: lines_longer_than_80_chars - -part of openapi.api; - -@JsonSerializable( - checked: true, - createToJson: true, - disallowUnrecognizedKeys: true, - explicitToJson: true, -) -class User { - /// Returns a new [User] instance. - User({ - this.id, - this.username, - this.firstName, - this.lastName, - this.email, - this.password, - this.phone, - this.userStatus, - }); - - @JsonKey( - nullable: false, - name: r'id', - required: false, - ) - int id; - - @JsonKey( - nullable: false, - name: r'username', - required: false, - ) - String username; - - @JsonKey( - nullable: false, - name: r'firstName', - required: false, - ) - String firstName; - - @JsonKey( - nullable: false, - name: r'lastName', - required: false, - ) - String lastName; - - @JsonKey( - nullable: false, - name: r'email', - required: false, - ) - String email; - - @JsonKey( - nullable: false, - name: r'password', - required: false, - ) - String password; - - @JsonKey( - nullable: false, - name: r'phone', - required: false, - ) - String phone; - - /// User Status - @JsonKey( - nullable: false, - name: r'userStatus', - required: false, - ) - int userStatus; - - @override - bool operator ==(Object other) => identical(this, other) || other is User && - other.id == id && - other.username == username && - other.firstName == firstName && - other.lastName == lastName && - other.email == email && - other.password == password && - other.phone == phone && - other.userStatus == userStatus; - - @override - int get hashCode => - (id == null ? 0 : id.hashCode) + - (username == null ? 0 : username.hashCode) + - (firstName == null ? 0 : firstName.hashCode) + - (lastName == null ? 0 : lastName.hashCode) + - (email == null ? 0 : email.hashCode) + - (password == null ? 0 : password.hashCode) + - (phone == null ? 0 : phone.hashCode) + - (userStatus == null ? 0 : userStatus.hashCode); - - factory User.fromJson(Map json) => _$UserFromJson(json); - - Map toJson() => _$UserToJson(this); - - @override - String toString() => toJson().toString(); -} - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pom.xml b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pom.xml deleted file mode 100644 index 708ad4155156..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pom.xml +++ /dev/null @@ -1,88 +0,0 @@ - - 4.0.0 - org.openapitools - Dart2PetstoreClientJsonSerializableLibTests - pom - 1.0.0-SNAPSHOT - Dart2 Petstore Client with json_serializable Lib - - - - maven-dependency-plugin - - - package - - copy-dependencies - - - ${project.build.directory} - - - - - - org.codehaus.mojo - exec-maven-plugin - 1.2.1 - - - export-dartfmt - pre-install-test - - exec - - - export - - DART_FMT_PATH=/usr/local/bin/dartfmt - - - - - pub-get - pre-integration-test - - exec - - - pub - - get - - - - - pub-build-runner - pre-integration-test - - exec - - - pub - - run - build_runner - build - - - - - pub-test - integration-test - - exec - - - pub - - run - test - - - - - - - - diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pubspec.yaml b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pubspec.yaml deleted file mode 100644 index 66b0d5a7acde..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/pubspec.yaml +++ /dev/null @@ -1,19 +0,0 @@ -# -# AUTO-GENERATED FILE, DO NOT MODIFY! -# - -name: 'openapi' -version: '1.0.0' -description: 'OpenAPI API client' -homepage: 'homepage' -environment: - sdk: '>=2.12.0 <3.0.0' -dependencies: - http: '>=0.13.0 <0.14.0' - intl: '^0.17.0' - meta: '^1.1.8' - json_annotation: '^3.1.1' -dev_dependencies: - test: '>=1.16.0 <1.18.0' - build_runner: '^1.10.9' - json_serializable: '^3.5.1' diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/additional_properties_class_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/additional_properties_class_test.dart deleted file mode 100644 index 3f231dddf74d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/additional_properties_class_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for AdditionalPropertiesClass -void main() { - final instance = AdditionalPropertiesClass(); - - group('test AdditionalPropertiesClass', () { - // Map mapProperty (default value: const {}) - test('to test the property `mapProperty`', () async { - // TODO - }); - - // Map> mapOfMapProperty (default value: const {}) - test('to test the property `mapOfMapProperty`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/animal_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/animal_test.dart deleted file mode 100644 index 3e6526e71957..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/animal_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Animal -void main() { - final instance = Animal(); - - group('test Animal', () { - // String className - test('to test the property `className`', () async { - // TODO - }); - - // String color (default value: 'red') - test('to test the property `color`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/another_fake_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/another_fake_api_test.dart deleted file mode 100644 index 355b4140bdd6..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/another_fake_api_test.dart +++ /dev/null @@ -1,29 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for AnotherFakeApi -void main() { - final instance = AnotherFakeApi(); - - group('tests for AnotherFakeApi', () { - // To test special tags - // - // To test special tags and operation ID starting with number - // - //Future call123testSpecialTags(ModelClient modelClient) async - test('test call123testSpecialTags', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/api_response_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/api_response_test.dart deleted file mode 100644 index b0c30615b926..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/api_response_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ApiResponse -void main() { - final instance = ApiResponse(); - - group('test ApiResponse', () { - // int code - test('to test the property `code`', () async { - // TODO - }); - - // String type - test('to test the property `type`', () async { - // TODO - }); - - // String message - test('to test the property `message`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_array_of_number_only_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_array_of_number_only_test.dart deleted file mode 100644 index 53ed7123a884..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_array_of_number_only_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ArrayOfArrayOfNumberOnly -void main() { - final instance = ArrayOfArrayOfNumberOnly(); - - group('test ArrayOfArrayOfNumberOnly', () { - // List> arrayArrayNumber (default value: const []) - test('to test the property `arrayArrayNumber`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_number_only_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_number_only_test.dart deleted file mode 100644 index 99fb4e3ddf79..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_of_number_only_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ArrayOfNumberOnly -void main() { - final instance = ArrayOfNumberOnly(); - - group('test ArrayOfNumberOnly', () { - // List arrayNumber (default value: const []) - test('to test the property `arrayNumber`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_test_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_test_test.dart deleted file mode 100644 index f1af158fe2fe..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/array_test_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ArrayTest -void main() { - final instance = ArrayTest(); - - group('test ArrayTest', () { - // List arrayOfString (default value: const []) - test('to test the property `arrayOfString`', () async { - // TODO - }); - - // List> arrayArrayOfInteger (default value: const []) - test('to test the property `arrayArrayOfInteger`', () async { - // TODO - }); - - // List> arrayArrayOfModel (default value: const []) - test('to test the property `arrayArrayOfModel`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/capitalization_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/capitalization_test.dart deleted file mode 100644 index c21e1a31c933..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/capitalization_test.dart +++ /dev/null @@ -1,52 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Capitalization -void main() { - final instance = Capitalization(); - - group('test Capitalization', () { - // String smallCamel - test('to test the property `smallCamel`', () async { - // TODO - }); - - // String capitalCamel - test('to test the property `capitalCamel`', () async { - // TODO - }); - - // String smallSnake - test('to test the property `smallSnake`', () async { - // TODO - }); - - // String capitalSnake - test('to test the property `capitalSnake`', () async { - // TODO - }); - - // String sCAETHFlowPoints - test('to test the property `sCAETHFlowPoints`', () async { - // TODO - }); - - // Name of the pet - // String ATT_NAME - test('to test the property `ATT_NAME`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_all_of_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_all_of_test.dart deleted file mode 100644 index f4d0a69b7ca3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_all_of_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for CatAllOf -void main() { - final instance = CatAllOf(); - - group('test CatAllOf', () { - // bool declawed - test('to test the property `declawed`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_test.dart deleted file mode 100644 index e7d33048bbc4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/cat_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Cat -void main() { - final instance = Cat(); - - group('test Cat', () { - // String className - test('to test the property `className`', () async { - // TODO - }); - - // String color (default value: 'red') - test('to test the property `color`', () async { - // TODO - }); - - // bool declawed - test('to test the property `declawed`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/category_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/category_test.dart deleted file mode 100644 index 54d51663d9d9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/category_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Category -void main() { - final instance = Category(); - - group('test Category', () { - // int id - test('to test the property `id`', () async { - // TODO - }); - - // String name (default value: 'default-name') - test('to test the property `name`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/class_model_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/class_model_test.dart deleted file mode 100644 index 047ce788765a..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/class_model_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ClassModel -void main() { - final instance = ClassModel(); - - group('test ClassModel', () { - // String class_ - test('to test the property `class_`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/default_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/default_api_test.dart deleted file mode 100644 index 2756c463df1c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/default_api_test.dart +++ /dev/null @@ -1,25 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for DefaultApi -void main() { - final instance = DefaultApi(); - - group('tests for DefaultApi', () { - //Future fooGet() async - test('test fooGet', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/deprecated_object_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/deprecated_object_test.dart deleted file mode 100644 index a1c6df250582..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/deprecated_object_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for DeprecatedObject -void main() { - final instance = DeprecatedObject(); - - group('test DeprecatedObject', () { - // String name - test('to test the property `name`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_all_of_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_all_of_test.dart deleted file mode 100644 index 5a0209898b88..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_all_of_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for DogAllOf -void main() { - final instance = DogAllOf(); - - group('test DogAllOf', () { - // String breed - test('to test the property `breed`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_test.dart deleted file mode 100644 index bce7e5bbdece..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/dog_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Dog -void main() { - final instance = Dog(); - - group('test Dog', () { - // String className - test('to test the property `className`', () async { - // TODO - }); - - // String color (default value: 'red') - test('to test the property `color`', () async { - // TODO - }); - - // String breed - test('to test the property `breed`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_arrays_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_arrays_test.dart deleted file mode 100644 index b3364c9a89a6..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_arrays_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for EnumArrays -void main() { - final instance = EnumArrays(); - - group('test EnumArrays', () { - // String justSymbol - test('to test the property `justSymbol`', () async { - // TODO - }); - - // List arrayEnum (default value: const []) - test('to test the property `arrayEnum`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_class_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_class_test.dart deleted file mode 100644 index 496ffbd68cfd..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_class_test.dart +++ /dev/null @@ -1,20 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for EnumClass -void main() { - - group('test EnumClass', () { - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_test_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_test_test.dart deleted file mode 100644 index 52618838aff4..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/enum_test_test.dart +++ /dev/null @@ -1,61 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for EnumTest -void main() { - final instance = EnumTest(); - - group('test EnumTest', () { - // String enumString - test('to test the property `enumString`', () async { - // TODO - }); - - // String enumStringRequired - test('to test the property `enumStringRequired`', () async { - // TODO - }); - - // int enumInteger - test('to test the property `enumInteger`', () async { - // TODO - }); - - // double enumNumber - test('to test the property `enumNumber`', () async { - // TODO - }); - - // OuterEnum outerEnum - test('to test the property `outerEnum`', () async { - // TODO - }); - - // OuterEnumInteger outerEnumInteger - test('to test the property `outerEnumInteger`', () async { - // TODO - }); - - // OuterEnumDefaultValue outerEnumDefaultValue - test('to test the property `outerEnumDefaultValue`', () async { - // TODO - }); - - // OuterEnumIntegerDefaultValue outerEnumIntegerDefaultValue - test('to test the property `outerEnumIntegerDefaultValue`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_api_test.dart deleted file mode 100644 index 065e89afdc1e..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_api_test.dart +++ /dev/null @@ -1,138 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for FakeApi -void main() { - final instance = FakeApi(); - - group('tests for FakeApi', () { - // Health check endpoint - // - //Future fakeHealthGet() async - test('test fakeHealthGet', () async { - // TODO - }); - - // test http signature authentication - // - //Future fakeHttpSignatureTest(Pet pet, { String query1, String header1 }) async - test('test fakeHttpSignatureTest', () async { - // TODO - }); - - // Test serialization of outer boolean types - // - //Future fakeOuterBooleanSerialize({ bool body }) async - test('test fakeOuterBooleanSerialize', () async { - // TODO - }); - - // Test serialization of object with outer number type - // - //Future fakeOuterCompositeSerialize({ OuterComposite outerComposite }) async - test('test fakeOuterCompositeSerialize', () async { - // TODO - }); - - // Test serialization of outer number types - // - //Future fakeOuterNumberSerialize({ num body }) async - test('test fakeOuterNumberSerialize', () async { - // TODO - }); - - // Test serialization of outer string types - // - //Future fakeOuterStringSerialize({ String body }) async - test('test fakeOuterStringSerialize', () async { - // TODO - }); - - // Test serialization of enum (int) properties with examples - // - //Future fakePropertyEnumIntegerSerialize(OuterObjectWithEnumProperty outerObjectWithEnumProperty) async - test('test fakePropertyEnumIntegerSerialize', () async { - // TODO - }); - - // For this test, the body for this request much reference a schema named `File`. - // - //Future testBodyWithFileSchema(FileSchemaTestClass fileSchemaTestClass) async - test('test testBodyWithFileSchema', () async { - // TODO - }); - - //Future testBodyWithQueryParams(String query, User user) async - test('test testBodyWithQueryParams', () async { - // TODO - }); - - // To test \"client\" model - // - // To test \"client\" model - // - //Future testClientModel(ModelClient modelClient) async - test('test testClientModel', () async { - // TODO - }); - - // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - // - // Fake endpoint for testing various parameters 假端點 偽のエンドポイント 가짜 엔드 포인트 - // - //Future testEndpointParameters(num number, double double_, String patternWithoutDelimiter, String byte, { int integer, int int32, int int64, double float, String string, MultipartFile binary, DateTime date, DateTime dateTime, String password, String callback }) async - test('test testEndpointParameters', () async { - // TODO - }); - - // To test enum parameters - // - // To test enum parameters - // - //Future testEnumParameters({ List enumHeaderStringArray, String enumHeaderString, List enumQueryStringArray, String enumQueryString, int enumQueryInteger, double enumQueryDouble, List enumFormStringArray, String enumFormString }) async - test('test testEnumParameters', () async { - // TODO - }); - - // Fake endpoint to test group parameters (optional) - // - // Fake endpoint to test group parameters (optional) - // - //Future testGroupParameters(int requiredStringGroup, bool requiredBooleanGroup, int requiredInt64Group, { int stringGroup, bool booleanGroup, int int64Group }) async - test('test testGroupParameters', () async { - // TODO - }); - - // test inline additionalProperties - // - //Future testInlineAdditionalProperties(Map requestBody) async - test('test testInlineAdditionalProperties', () async { - // TODO - }); - - // test json serialization of form data - // - //Future testJsonFormData(String param, String param2) async - test('test testJsonFormData', () async { - // TODO - }); - - // To test the collection format in query parameters - // - //Future testQueryParameterCollectionFormat(List pipe, List ioutil, List http, List url, List context) async - test('test testQueryParameterCollectionFormat', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_classname_tags123_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_classname_tags123_api_test.dart deleted file mode 100644 index 1a0f96589476..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/fake_classname_tags123_api_test.dart +++ /dev/null @@ -1,29 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for FakeClassnameTags123Api -void main() { - final instance = FakeClassnameTags123Api(); - - group('tests for FakeClassnameTags123Api', () { - // To test class name in snake case - // - // To test class name in snake case - // - //Future testClassname(ModelClient modelClient) async - test('test testClassname', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/file_schema_test_class_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/file_schema_test_class_test.dart deleted file mode 100644 index 4316bb385a76..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/file_schema_test_class_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for FileSchemaTestClass -void main() { - final instance = FileSchemaTestClass(); - - group('test FileSchemaTestClass', () { - // ModelFile file - test('to test the property `file`', () async { - // TODO - }); - - // List files (default value: const []) - test('to test the property `files`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/foo_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/foo_test.dart deleted file mode 100644 index 7b72da51b0e8..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/foo_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Foo -void main() { - final instance = Foo(); - - group('test Foo', () { - // String bar (default value: 'bar') - test('to test the property `bar`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/format_test_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/format_test_test.dart deleted file mode 100644 index e776be1d9f68..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/format_test_test.dart +++ /dev/null @@ -1,103 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for FormatTest -void main() { - final instance = FormatTest(); - - group('test FormatTest', () { - // int integer - test('to test the property `integer`', () async { - // TODO - }); - - // int int32 - test('to test the property `int32`', () async { - // TODO - }); - - // int int64 - test('to test the property `int64`', () async { - // TODO - }); - - // num number - test('to test the property `number`', () async { - // TODO - }); - - // double float - test('to test the property `float`', () async { - // TODO - }); - - // double double_ - test('to test the property `double_`', () async { - // TODO - }); - - // double decimal - test('to test the property `decimal`', () async { - // TODO - }); - - // String string - test('to test the property `string`', () async { - // TODO - }); - - // String byte - test('to test the property `byte`', () async { - // TODO - }); - - // MultipartFile binary - test('to test the property `binary`', () async { - // TODO - }); - - // DateTime date - test('to test the property `date`', () async { - // TODO - }); - - // DateTime dateTime - test('to test the property `dateTime`', () async { - // TODO - }); - - // String uuid - test('to test the property `uuid`', () async { - // TODO - }); - - // String password - test('to test the property `password`', () async { - // TODO - }); - - // A string that is a 10 digit number. Can have leading zeros. - // String patternWithDigits - test('to test the property `patternWithDigits`', () async { - // TODO - }); - - // A string starting with 'image_' (case insensitive) and one to three digits following i.e. Image_01. - // String patternWithDigitsAndDelimiter - test('to test the property `patternWithDigitsAndDelimiter`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/has_only_read_only_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/has_only_read_only_test.dart deleted file mode 100644 index 16b36e117094..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/has_only_read_only_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for HasOnlyReadOnly -void main() { - final instance = HasOnlyReadOnly(); - - group('test HasOnlyReadOnly', () { - // String bar - test('to test the property `bar`', () async { - // TODO - }); - - // String foo - test('to test the property `foo`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/health_check_result_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/health_check_result_test.dart deleted file mode 100644 index 1599fc46a283..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/health_check_result_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for HealthCheckResult -void main() { - final instance = HealthCheckResult(); - - group('test HealthCheckResult', () { - // String nullableMessage - test('to test the property `nullableMessage`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/inline_response_default_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/inline_response_default_test.dart deleted file mode 100644 index ecb2a874f05f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/inline_response_default_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for InlineResponseDefault -void main() { - final instance = InlineResponseDefault(); - - group('test InlineResponseDefault', () { - // Foo string - test('to test the property `string`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/map_test_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/map_test_test.dart deleted file mode 100644 index 21af0b85fa36..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/map_test_test.dart +++ /dev/null @@ -1,41 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for MapTest -void main() { - final instance = MapTest(); - - group('test MapTest', () { - // Map> mapMapOfString (default value: const {}) - test('to test the property `mapMapOfString`', () async { - // TODO - }); - - // Map mapOfEnumString (default value: const {}) - test('to test the property `mapOfEnumString`', () async { - // TODO - }); - - // Map directMap (default value: const {}) - test('to test the property `directMap`', () async { - // TODO - }); - - // Map indirectMap (default value: const {}) - test('to test the property `indirectMap`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/mixed_properties_and_additional_properties_class_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/mixed_properties_and_additional_properties_class_test.dart deleted file mode 100644 index a8e0fdd8da64..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/mixed_properties_and_additional_properties_class_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for MixedPropertiesAndAdditionalPropertiesClass -void main() { - final instance = MixedPropertiesAndAdditionalPropertiesClass(); - - group('test MixedPropertiesAndAdditionalPropertiesClass', () { - // String uuid - test('to test the property `uuid`', () async { - // TODO - }); - - // DateTime dateTime - test('to test the property `dateTime`', () async { - // TODO - }); - - // Map map (default value: const {}) - test('to test the property `map`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model200_response_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model200_response_test.dart deleted file mode 100644 index c28d3671dfc1..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model200_response_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Model200Response -void main() { - final instance = Model200Response(); - - group('test Model200Response', () { - // int name - test('to test the property `name`', () async { - // TODO - }); - - // String class_ - test('to test the property `class_`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_client_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_client_test.dart deleted file mode 100644 index c0a59729e3d5..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_client_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ModelClient -void main() { - final instance = ModelClient(); - - group('test ModelClient', () { - // String client - test('to test the property `client`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_file_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_file_test.dart deleted file mode 100644 index b2f6d48afa74..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_file_test.dart +++ /dev/null @@ -1,27 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ModelFile -void main() { - final instance = ModelFile(); - - group('test ModelFile', () { - // Test capitalization - // String sourceURI - test('to test the property `sourceURI`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_list_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_list_test.dart deleted file mode 100644 index 02e98011b21f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_list_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ModelList -void main() { - final instance = ModelList(); - - group('test ModelList', () { - // String n123list - test('to test the property `n123list`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_return_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_return_test.dart deleted file mode 100644 index b7f065e4fb45..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/model_return_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ModelReturn -void main() { - final instance = ModelReturn(); - - group('test ModelReturn', () { - // int return_ - test('to test the property `return_`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/name_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/name_test.dart deleted file mode 100644 index 8e0ef41e9f2f..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/name_test.dart +++ /dev/null @@ -1,41 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Name -void main() { - final instance = Name(); - - group('test Name', () { - // int name - test('to test the property `name`', () async { - // TODO - }); - - // int snakeCase - test('to test the property `snakeCase`', () async { - // TODO - }); - - // String property - test('to test the property `property`', () async { - // TODO - }); - - // int n123number - test('to test the property `n123number`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/nullable_class_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/nullable_class_test.dart deleted file mode 100644 index 6147fbe1336b..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/nullable_class_test.dart +++ /dev/null @@ -1,81 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for NullableClass -void main() { - final instance = NullableClass(); - - group('test NullableClass', () { - // int integerProp - test('to test the property `integerProp`', () async { - // TODO - }); - - // num numberProp - test('to test the property `numberProp`', () async { - // TODO - }); - - // bool booleanProp - test('to test the property `booleanProp`', () async { - // TODO - }); - - // String stringProp - test('to test the property `stringProp`', () async { - // TODO - }); - - // DateTime dateProp - test('to test the property `dateProp`', () async { - // TODO - }); - - // DateTime datetimeProp - test('to test the property `datetimeProp`', () async { - // TODO - }); - - // List arrayNullableProp (default value: const []) - test('to test the property `arrayNullableProp`', () async { - // TODO - }); - - // List arrayAndItemsNullableProp (default value: const []) - test('to test the property `arrayAndItemsNullableProp`', () async { - // TODO - }); - - // List arrayItemsNullable (default value: const []) - test('to test the property `arrayItemsNullable`', () async { - // TODO - }); - - // Map objectNullableProp (default value: const {}) - test('to test the property `objectNullableProp`', () async { - // TODO - }); - - // Map objectAndItemsNullableProp (default value: const {}) - test('to test the property `objectAndItemsNullableProp`', () async { - // TODO - }); - - // Map objectItemsNullable (default value: const {}) - test('to test the property `objectItemsNullable`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/number_only_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/number_only_test.dart deleted file mode 100644 index 3662bff150d9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/number_only_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for NumberOnly -void main() { - final instance = NumberOnly(); - - group('test NumberOnly', () { - // num justNumber - test('to test the property `justNumber`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/object_with_deprecated_fields_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/object_with_deprecated_fields_test.dart deleted file mode 100644 index b5769dc67490..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/object_with_deprecated_fields_test.dart +++ /dev/null @@ -1,41 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ObjectWithDeprecatedFields -void main() { - final instance = ObjectWithDeprecatedFields(); - - group('test ObjectWithDeprecatedFields', () { - // String uuid - test('to test the property `uuid`', () async { - // TODO - }); - - // num id - test('to test the property `id`', () async { - // TODO - }); - - // DeprecatedObject deprecatedRef - test('to test the property `deprecatedRef`', () async { - // TODO - }); - - // List bars (default value: const []) - test('to test the property `bars`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/order_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/order_test.dart deleted file mode 100644 index 614a14e42bb9..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/order_test.dart +++ /dev/null @@ -1,52 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Order -void main() { - final instance = Order(); - - group('test Order', () { - // int id - test('to test the property `id`', () async { - // TODO - }); - - // int petId - test('to test the property `petId`', () async { - // TODO - }); - - // int quantity - test('to test the property `quantity`', () async { - // TODO - }); - - // DateTime shipDate - test('to test the property `shipDate`', () async { - // TODO - }); - - // Order Status - // String status - test('to test the property `status`', () async { - // TODO - }); - - // bool complete (default value: false) - test('to test the property `complete`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_composite_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_composite_test.dart deleted file mode 100644 index 294c823443c3..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_composite_test.dart +++ /dev/null @@ -1,36 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterComposite -void main() { - final instance = OuterComposite(); - - group('test OuterComposite', () { - // num myNumber - test('to test the property `myNumber`', () async { - // TODO - }); - - // String myString - test('to test the property `myString`', () async { - // TODO - }); - - // bool myBoolean - test('to test the property `myBoolean`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_default_value_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_default_value_test.dart deleted file mode 100644 index 84ae975ef189..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_default_value_test.dart +++ /dev/null @@ -1,20 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterEnumDefaultValue -void main() { - - group('test OuterEnumDefaultValue', () { - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_default_value_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_default_value_test.dart deleted file mode 100644 index bf3399ba4281..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_default_value_test.dart +++ /dev/null @@ -1,20 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterEnumIntegerDefaultValue -void main() { - - group('test OuterEnumIntegerDefaultValue', () { - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_test.dart deleted file mode 100644 index d807f03227ff..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_integer_test.dart +++ /dev/null @@ -1,20 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterEnumInteger -void main() { - - group('test OuterEnumInteger', () { - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_test.dart deleted file mode 100644 index a2b79ce0c1c6..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_enum_test.dart +++ /dev/null @@ -1,20 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterEnum -void main() { - - group('test OuterEnum', () { - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_object_with_enum_property_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_object_with_enum_property_test.dart deleted file mode 100644 index 6995c37ebb4c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/outer_object_with_enum_property_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for OuterObjectWithEnumProperty -void main() { - final instance = OuterObjectWithEnumProperty(); - - group('test OuterObjectWithEnumProperty', () { - // OuterEnumInteger value - test('to test the property `value`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_api_test.dart deleted file mode 100644 index 5f4c994acefa..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_api_test.dart +++ /dev/null @@ -1,89 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for PetApi -void main() { - final instance = PetApi(); - - group('tests for PetApi', () { - // Add a new pet to the store - // - //Future addPet(Pet pet) async - test('test addPet', () async { - // TODO - }); - - // Deletes a pet - // - //Future deletePet(int petId, { String apiKey }) async - test('test deletePet', () async { - // TODO - }); - - // Finds Pets by status - // - // Multiple status values can be provided with comma separated strings - // - //Future> findPetsByStatus(List status) async - test('test findPetsByStatus', () async { - // TODO - }); - - // Finds Pets by tags - // - // Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing. - // - //Future> findPetsByTags(Set tags) async - test('test findPetsByTags', () async { - // TODO - }); - - // Find pet by ID - // - // Returns a single pet - // - //Future getPetById(int petId) async - test('test getPetById', () async { - // TODO - }); - - // Update an existing pet - // - //Future updatePet(Pet pet) async - test('test updatePet', () async { - // TODO - }); - - // Updates a pet in the store with form data - // - //Future updatePetWithForm(int petId, { String name, String status }) async - test('test updatePetWithForm', () async { - // TODO - }); - - // uploads an image - // - //Future uploadFile(int petId, { String additionalMetadata, MultipartFile file }) async - test('test uploadFile', () async { - // TODO - }); - - // uploads an image (required) - // - //Future uploadFileWithRequiredFile(int petId, MultipartFile requiredFile, { String additionalMetadata }) async - test('test uploadFileWithRequiredFile', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_test.dart deleted file mode 100644 index 23c26595c85c..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/pet_test.dart +++ /dev/null @@ -1,52 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Pet -void main() { - final instance = Pet(); - - group('test Pet', () { - // int id - test('to test the property `id`', () async { - // TODO - }); - - // Category category - test('to test the property `category`', () async { - // TODO - }); - - // String name - test('to test the property `name`', () async { - // TODO - }); - - // Set photoUrls (default value: const {}) - test('to test the property `photoUrls`', () async { - // TODO - }); - - // List tags (default value: const []) - test('to test the property `tags`', () async { - // TODO - }); - - // pet status in the store - // String status - test('to test the property `status`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/read_only_first_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/read_only_first_test.dart deleted file mode 100644 index d3326fd494d0..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/read_only_first_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for ReadOnlyFirst -void main() { - final instance = ReadOnlyFirst(); - - group('test ReadOnlyFirst', () { - // String bar - test('to test the property `bar`', () async { - // TODO - }); - - // String baz - test('to test the property `baz`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/special_model_name_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/special_model_name_test.dart deleted file mode 100644 index f3b461364fbe..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/special_model_name_test.dart +++ /dev/null @@ -1,26 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for SpecialModelName -void main() { - final instance = SpecialModelName(); - - group('test SpecialModelName', () { - // int dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket - test('to test the property `dollarSpecialLeftSquareBracketPropertyPeriodNameRightSquareBracket`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/store_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/store_api_test.dart deleted file mode 100644 index 4a7ed54abbbc..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/store_api_test.dart +++ /dev/null @@ -1,54 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for StoreApi -void main() { - final instance = StoreApi(); - - group('tests for StoreApi', () { - // Delete purchase order by ID - // - // For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors - // - //Future deleteOrder(String orderId) async - test('test deleteOrder', () async { - // TODO - }); - - // Returns pet inventories by status - // - // Returns a map of status codes to quantities - // - //Future> getInventory() async - test('test getInventory', () async { - // TODO - }); - - // Find purchase order by ID - // - // For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions - // - //Future getOrderById(int orderId) async - test('test getOrderById', () async { - // TODO - }); - - // Place an order for a pet - // - //Future placeOrder(Order order) async - test('test placeOrder', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/tag_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/tag_test.dart deleted file mode 100644 index 66ecdfe488dc..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/tag_test.dart +++ /dev/null @@ -1,31 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for Tag -void main() { - final instance = Tag(); - - group('test Tag', () { - // int id - test('to test the property `id`', () async { - // TODO - }); - - // String name - test('to test the property `name`', () async { - // TODO - }); - - - }); - -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_api_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_api_test.dart deleted file mode 100644 index 73ee89a29451..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_api_test.dart +++ /dev/null @@ -1,82 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - - -/// tests for UserApi -void main() { - final instance = UserApi(); - - group('tests for UserApi', () { - // Create user - // - // This can only be done by the logged in user. - // - //Future createUser(User user) async - test('test createUser', () async { - // TODO - }); - - // Creates list of users with given input array - // - //Future createUsersWithArrayInput(List user) async - test('test createUsersWithArrayInput', () async { - // TODO - }); - - // Creates list of users with given input array - // - //Future createUsersWithListInput(List user) async - test('test createUsersWithListInput', () async { - // TODO - }); - - // Delete user - // - // This can only be done by the logged in user. - // - //Future deleteUser(String username) async - test('test deleteUser', () async { - // TODO - }); - - // Get user by user name - // - //Future getUserByName(String username) async - test('test getUserByName', () async { - // TODO - }); - - // Logs user into the system - // - //Future loginUser(String username, String password) async - test('test loginUser', () async { - // TODO - }); - - // Logs out current logged in user session - // - //Future logoutUser() async - test('test logoutUser', () async { - // TODO - }); - - // Updated user - // - // This can only be done by the logged in user. - // - //Future updateUser(String username, User user) async - test('test updateUser', () async { - // TODO - }); - - }); -} diff --git a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_test.dart b/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_test.dart deleted file mode 100644 index b89cd360489d..000000000000 --- a/samples/openapi3/client/petstore/dart2/petstore_json_serializable_client_lib_fake/test/user_test.dart +++ /dev/null @@ -1,62 +0,0 @@ -// -// AUTO-GENERATED FILE, DO NOT MODIFY! -// -// @dart=2.0 - -// ignore_for_file: unused_element, unused_import -// ignore_for_file: always_put_required_named_parameters_first -// ignore_for_file: lines_longer_than_80_chars - -import 'package:openapi/api.dart'; -import 'package:test/test.dart'; - -// tests for User -void main() { - final instance = User(); - - group('test User', () { - // int id - test('to test the property `id`', () async { - // TODO - }); - - // String username - test('to test the property `username`', () async { - // TODO - }); - - // String firstName - test('to test the property `firstName`', () async { - // TODO - }); - - // String lastName - test('to test the property `lastName`', () async { - // TODO - }); - - // String email - test('to test the property `email`', () async { - // TODO - }); - - // String password - test('to test the property `password`', () async { - // TODO - }); - - // String phone - test('to test the property `phone`', () async { - // TODO - }); - - // User Status - // int userStatus - test('to test the property `userStatus`', () async { - // TODO - }); - - - }); - -}