forked from loafle/openapi-generator-original
remove-more-null-warnings (#15664)
This commit is contained in:
parent
0350d0e313
commit
9e8805d712
@ -43,13 +43,6 @@
|
||||
|
||||
{{/vendorExtensions.x-duplicated-data-type}}
|
||||
{{/composedSchemas.anyOf}}
|
||||
{{#composedSchemas.oneOf}}
|
||||
{{^vendorExtensions.x-duplicated-data-type}}
|
||||
Utf8JsonReader {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Reader = utf8JsonReader;
|
||||
bool {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Deserialized = Client.ClientUtils.TryDeserialize<{{{dataType}}}>(ref {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Reader, jsonSerializerOptions, out {{{dataType}}}{{^isBoolean}}{{nrt?}}{{/isBoolean}} {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}});
|
||||
|
||||
{{/vendorExtensions.x-duplicated-data-type}}
|
||||
{{/composedSchemas.oneOf}}
|
||||
{{#composedSchemas.allOf}}
|
||||
{{^isInherited}}
|
||||
Utf8JsonReader {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Reader = utf8JsonReader;
|
||||
@ -59,8 +52,10 @@
|
||||
{{/composedSchemas.allOf}}
|
||||
{{#allVars}}
|
||||
{{#isInnerEnum}}{{^isMap}}{{classname}}.{{/isMap}}{{/isInnerEnum}}{{#nrt}}{{#lambda.optional}}{{{datatypeWithEnum}}}{{/lambda.optional}}{{/nrt}}{{^nrt}}{{{datatypeWithEnum}}}{{#vendorExtensions.x-csharp-value-type}}?{{/vendorExtensions.x-csharp-value-type}}{{/nrt}} {{#lambda.camelcase_param}}{{name}}{{/lambda.camelcase_param}} = default;
|
||||
{{/allVars}}
|
||||
{{#-last}}
|
||||
|
||||
{{/-last}}
|
||||
{{/allVars}}
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -175,23 +170,14 @@
|
||||
}
|
||||
|
||||
{{#nonNullableVars}}
|
||||
{{#-first}}
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
{{/-first}}
|
||||
if ({{#lambda.camelcase_param}}{{name}}{{/lambda.camelcase_param}} == null)
|
||||
throw new ArgumentNullException(nameof({{#lambda.camelcase_param}}{{name}}{{/lambda.camelcase_param}}), "Property is required for class {{classname}}.");
|
||||
|
||||
{{#-last}}
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
{{/-last}}
|
||||
{{/nonNullableVars}}
|
||||
{{#composedSchemas.oneOf}}
|
||||
{{^vendorExtensions.x-duplicated-data-type}}
|
||||
if ({{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Deserialized)
|
||||
Utf8JsonReader {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Reader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<{{{dataType}}}>(ref {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}Reader, jsonSerializerOptions, out {{{dataType}}}{{^isBoolean}}{{nrt?}}{{/isBoolean}} {{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}))
|
||||
return new {{classname}}({{#lambda.joinWithComma}}{{#lambda.camelcase_param}}{{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}{{/lambda.camelcase_param}}{{#vendorExtensions.x-csharp-value-type}}.Value{{/vendorExtensions.x-csharp-value-type}} {{#model.composedSchemas.allOf}}{{^isInherited}}{{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}{{/isInherited}}{{/model.composedSchemas.allOf}}{{#model.composedSchemas.anyOf}}{{#lambda.camelcase_param}}{{baseType}}{{#isArray}}{{{dataFormat}}}{{/isArray}}{{/lambda.camelcase_param}}{{#vendorExtensions.x-csharp-value-type}}.Value{{/vendorExtensions.x-csharp-value-type}} {{/model.composedSchemas.anyOf}}{{#allVars}}{{#lambda.camelcase_param}}{{name}}{{/lambda.camelcase_param}}{{#vendorExtensions.x-csharp-value-type}}.Value{{/vendorExtensions.x-csharp-value-type}} {{/allVars}}{{/lambda.joinWithComma}});
|
||||
|
||||
{{/vendorExtensions.x-duplicated-data-type}}
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (activityOutputs == null)
|
||||
throw new ArgumentNullException(nameof(activityOutputs), "Property is required for class Activity.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Activity(activityOutputs);
|
||||
}
|
||||
|
||||
|
@ -142,18 +142,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (prop1 == null)
|
||||
throw new ArgumentNullException(nameof(prop1), "Property is required for class ActivityOutputElementRepresentation.");
|
||||
|
||||
if (prop2 == null)
|
||||
throw new ArgumentNullException(nameof(prop2), "Property is required for class ActivityOutputElementRepresentation.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ActivityOutputElementRepresentation(prop1, prop2);
|
||||
}
|
||||
|
||||
|
@ -228,9 +228,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (mapProperty == null)
|
||||
throw new ArgumentNullException(nameof(mapProperty), "Property is required for class AdditionalPropertiesClass.");
|
||||
|
||||
@ -252,9 +249,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (mapWithUndeclaredPropertiesString == null)
|
||||
throw new ArgumentNullException(nameof(mapWithUndeclaredPropertiesString), "Property is required for class AdditionalPropertiesClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new AdditionalPropertiesClass(emptyMap, mapOfMapProperty, mapProperty, mapWithUndeclaredPropertiesAnytype1, mapWithUndeclaredPropertiesAnytype2, mapWithUndeclaredPropertiesAnytype3, mapWithUndeclaredPropertiesString, anytype1);
|
||||
}
|
||||
|
||||
|
@ -151,18 +151,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class Animal.");
|
||||
|
||||
if (color == null)
|
||||
throw new ArgumentNullException(nameof(color), "Property is required for class Animal.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Animal(className, color);
|
||||
}
|
||||
|
||||
|
@ -155,9 +155,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (code == null)
|
||||
throw new ArgumentNullException(nameof(code), "Property is required for class ApiResponse.");
|
||||
|
||||
@ -167,9 +164,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (message == null)
|
||||
throw new ArgumentNullException(nameof(message), "Property is required for class ApiResponse.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ApiResponse(code.Value, message, type);
|
||||
}
|
||||
|
||||
|
@ -155,18 +155,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (cultivar == null)
|
||||
throw new ArgumentNullException(nameof(cultivar), "Property is required for class Apple.");
|
||||
|
||||
if (origin == null)
|
||||
throw new ArgumentNullException(nameof(origin), "Property is required for class Apple.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Apple(cultivar, origin);
|
||||
}
|
||||
|
||||
|
@ -135,18 +135,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (cultivar == null)
|
||||
throw new ArgumentNullException(nameof(cultivar), "Property is required for class AppleReq.");
|
||||
|
||||
if (mealy == null)
|
||||
throw new ArgumentNullException(nameof(mealy), "Property is required for class AppleReq.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new AppleReq(cultivar, mealy.Value);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayArrayNumber == null)
|
||||
throw new ArgumentNullException(nameof(arrayArrayNumber), "Property is required for class ArrayOfArrayOfNumberOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayOfArrayOfNumberOnly(arrayArrayNumber);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayNumber == null)
|
||||
throw new ArgumentNullException(nameof(arrayNumber), "Property is required for class ArrayOfNumberOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayOfNumberOnly(arrayNumber);
|
||||
}
|
||||
|
||||
|
@ -157,9 +157,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayOfString == null)
|
||||
throw new ArgumentNullException(nameof(arrayOfString), "Property is required for class ArrayTest.");
|
||||
|
||||
@ -169,9 +166,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (arrayArrayOfModel == null)
|
||||
throw new ArgumentNullException(nameof(arrayArrayOfModel), "Property is required for class ArrayTest.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayTest(arrayArrayOfInteger, arrayArrayOfModel, arrayOfString);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (lengthCm == null)
|
||||
throw new ArgumentNullException(nameof(lengthCm), "Property is required for class Banana.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Banana(lengthCm.Value);
|
||||
}
|
||||
|
||||
|
@ -136,18 +136,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (lengthCm == null)
|
||||
throw new ArgumentNullException(nameof(lengthCm), "Property is required for class BananaReq.");
|
||||
|
||||
if (sweet == null)
|
||||
throw new ArgumentNullException(nameof(sweet), "Property is required for class BananaReq.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new BananaReq(lengthCm.Value, sweet.Value);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class BasquePig.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new BasquePig(className);
|
||||
}
|
||||
|
||||
|
@ -194,9 +194,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (smallCamel == null)
|
||||
throw new ArgumentNullException(nameof(smallCamel), "Property is required for class Capitalization.");
|
||||
|
||||
@ -215,9 +212,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (aTTNAME == null)
|
||||
throw new ArgumentNullException(nameof(aTTNAME), "Property is required for class Capitalization.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Capitalization(aTTNAME, capitalCamel, capitalSnake, sCAETHFlowPoints, smallCamel, smallSnake);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (declawed == null)
|
||||
throw new ArgumentNullException(nameof(declawed), "Property is required for class CatAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new CatAllOf(declawed.Value);
|
||||
}
|
||||
|
||||
|
@ -142,18 +142,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class Category.");
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class Category.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Category(id.Value, name);
|
||||
}
|
||||
|
||||
|
@ -180,18 +180,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class ChildCatAllOf.");
|
||||
|
||||
if (petType == null)
|
||||
throw new ArgumentNullException(nameof(petType), "Property is required for class ChildCatAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ChildCatAllOf(name, petType.Value);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (classProperty == null)
|
||||
throw new ArgumentNullException(nameof(classProperty), "Property is required for class ClassModel.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ClassModel(classProperty);
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader quadrilateralInterfaceReader = utf8JsonReader;
|
||||
bool quadrilateralInterfaceDeserialized = Client.ClientUtils.TryDeserialize<QuadrilateralInterface>(ref utf8JsonReader, jsonSerializerOptions, out QuadrilateralInterface? quadrilateralInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class DanishPig.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DanishPig(className);
|
||||
}
|
||||
|
||||
|
@ -135,15 +135,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (dateOnlyProperty == null)
|
||||
throw new ArgumentNullException(nameof(dateOnlyProperty), "Property is required for class DateOnlyClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DateOnlyClass(dateOnlyProperty.Value);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class DeprecatedObject.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DeprecatedObject(name);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (breed == null)
|
||||
throw new ArgumentNullException(nameof(breed), "Property is required for class DogAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DogAllOf(breed);
|
||||
}
|
||||
|
||||
|
@ -165,9 +165,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (mainShape == null)
|
||||
throw new ArgumentNullException(nameof(mainShape), "Property is required for class Drawing.");
|
||||
|
||||
@ -177,9 +174,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (shapes == null)
|
||||
throw new ArgumentNullException(nameof(shapes), "Property is required for class Drawing.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Drawing(mainShape, shapeOrNull, shapes, nullableShape);
|
||||
}
|
||||
|
||||
|
@ -241,18 +241,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (justSymbol == null)
|
||||
throw new ArgumentNullException(nameof(justSymbol), "Property is required for class EnumArrays.");
|
||||
|
||||
if (arrayEnum == null)
|
||||
throw new ArgumentNullException(nameof(arrayEnum), "Property is required for class EnumArrays.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new EnumArrays(arrayEnum, justSymbol.Value);
|
||||
}
|
||||
|
||||
|
@ -496,9 +496,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (enumString == null)
|
||||
throw new ArgumentNullException(nameof(enumString), "Property is required for class EnumTest.");
|
||||
|
||||
@ -523,9 +520,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (outerEnumIntegerDefaultValue == null)
|
||||
throw new ArgumentNullException(nameof(outerEnumIntegerDefaultValue), "Property is required for class EnumTest.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new EnumTest(enumInteger.Value, enumIntegerOnly.Value, enumNumber.Value, enumString.Value, enumStringRequired.Value, outerEnumDefaultValue.Value, outerEnumInteger.Value, outerEnumIntegerDefaultValue.Value, outerEnum.Value);
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader triangleInterfaceReader = utf8JsonReader;
|
||||
bool triangleInterfaceDeserialized = Client.ClientUtils.TryDeserialize<TriangleInterface>(ref utf8JsonReader, jsonSerializerOptions, out TriangleInterface? triangleInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (sourceURI == null)
|
||||
throw new ArgumentNullException(nameof(sourceURI), "Property is required for class File.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new File(sourceURI);
|
||||
}
|
||||
|
||||
|
@ -143,18 +143,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (file == null)
|
||||
throw new ArgumentNullException(nameof(file), "Property is required for class FileSchemaTestClass.");
|
||||
|
||||
if (files == null)
|
||||
throw new ArgumentNullException(nameof(files), "Property is required for class FileSchemaTestClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new FileSchemaTestClass(file, files);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (bar == null)
|
||||
throw new ArgumentNullException(nameof(bar), "Property is required for class Foo.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Foo(bar);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (stringProperty == null)
|
||||
throw new ArgumentNullException(nameof(stringProperty), "Property is required for class FooGetDefaultResponse.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new FooGetDefaultResponse(stringProperty);
|
||||
}
|
||||
|
||||
|
@ -504,9 +504,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (integer == null)
|
||||
throw new ArgumentNullException(nameof(integer), "Property is required for class FormatTest.");
|
||||
|
||||
@ -564,9 +561,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (patternWithBackslash == null)
|
||||
throw new ArgumentNullException(nameof(patternWithBackslash), "Property is required for class FormatTest.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new FormatTest(binary, byteProperty, date.Value, dateTime.Value, decimalProperty.Value, doubleProperty.Value, floatProperty.Value, int32.Value, int64.Value, integer.Value, number.Value, password, patternWithBackslash, patternWithDigits, patternWithDigitsAndDelimiter, stringProperty, unsignedInteger.Value, unsignedLong.Value, uuid.Value);
|
||||
}
|
||||
|
||||
|
@ -120,12 +120,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader appleReader = utf8JsonReader;
|
||||
bool appleDeserialized = Client.ClientUtils.TryDeserialize<Apple>(ref appleReader, jsonSerializerOptions, out Apple? apple);
|
||||
|
||||
Utf8JsonReader bananaReader = utf8JsonReader;
|
||||
bool bananaDeserialized = Client.ClientUtils.TryDeserialize<Banana>(ref bananaReader, jsonSerializerOptions, out Banana? banana);
|
||||
|
||||
string? color = default;
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
@ -152,19 +146,15 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (color == null)
|
||||
throw new ArgumentNullException(nameof(color), "Property is required for class Fruit.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (appleDeserialized)
|
||||
Utf8JsonReader appleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Apple>(ref appleReader, jsonSerializerOptions, out Apple? apple))
|
||||
return new Fruit(apple, color);
|
||||
|
||||
if (bananaDeserialized)
|
||||
Utf8JsonReader bananaReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Banana>(ref bananaReader, jsonSerializerOptions, out Banana? banana))
|
||||
return new Fruit(banana, color);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -109,13 +109,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader appleReqReader = utf8JsonReader;
|
||||
bool appleReqDeserialized = Client.ClientUtils.TryDeserialize<AppleReq>(ref appleReqReader, jsonSerializerOptions, out AppleReq? appleReq);
|
||||
|
||||
Utf8JsonReader bananaReqReader = utf8JsonReader;
|
||||
bool bananaReqDeserialized = Client.ClientUtils.TryDeserialize<BananaReq>(ref bananaReqReader, jsonSerializerOptions, out BananaReq? bananaReq);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -137,10 +130,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (appleReqDeserialized)
|
||||
Utf8JsonReader appleReqReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<AppleReq>(ref appleReqReader, jsonSerializerOptions, out AppleReq? appleReq))
|
||||
return new FruitReq(appleReq);
|
||||
|
||||
if (bananaReqDeserialized)
|
||||
Utf8JsonReader bananaReqReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<BananaReq>(ref bananaReqReader, jsonSerializerOptions, out BananaReq? bananaReq))
|
||||
return new FruitReq(bananaReq);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -141,15 +141,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (color == null)
|
||||
throw new ArgumentNullException(nameof(color), "Property is required for class GmFruit.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new GmFruit(apple, banana, color);
|
||||
}
|
||||
|
||||
|
@ -138,15 +138,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (petType == null)
|
||||
throw new ArgumentNullException(nameof(petType), "Property is required for class GrandparentAnimal.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new GrandparentAnimal(petType);
|
||||
}
|
||||
|
||||
|
@ -178,18 +178,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (bar == null)
|
||||
throw new ArgumentNullException(nameof(bar), "Property is required for class HasOnlyReadOnly.");
|
||||
|
||||
if (foo == null)
|
||||
throw new ArgumentNullException(nameof(foo), "Property is required for class HasOnlyReadOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new HasOnlyReadOnly(bar, foo);
|
||||
}
|
||||
|
||||
|
@ -106,7 +106,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader triangleInterfaceReader = utf8JsonReader;
|
||||
bool triangleInterfaceDeserialized = Client.ClientUtils.TryDeserialize<TriangleInterface>(ref utf8JsonReader, jsonSerializerOptions, out TriangleInterface? triangleInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (_123list == null)
|
||||
throw new ArgumentNullException(nameof(_123list), "Property is required for class List.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new List(_123list);
|
||||
}
|
||||
|
||||
|
@ -141,18 +141,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (escapedLiteralString == null)
|
||||
throw new ArgumentNullException(nameof(escapedLiteralString), "Property is required for class LiteralStringClass.");
|
||||
|
||||
if (unescapedLiteralString == null)
|
||||
throw new ArgumentNullException(nameof(unescapedLiteralString), "Property is required for class LiteralStringClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new LiteralStringClass(escapedLiteralString, unescapedLiteralString);
|
||||
}
|
||||
|
||||
|
@ -142,16 +142,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader whaleReader = utf8JsonReader;
|
||||
bool whaleDeserialized = Client.ClientUtils.TryDeserialize<Whale>(ref whaleReader, jsonSerializerOptions, out Whale? whale);
|
||||
|
||||
Utf8JsonReader zebraReader = utf8JsonReader;
|
||||
bool zebraDeserialized = Client.ClientUtils.TryDeserialize<Zebra>(ref zebraReader, jsonSerializerOptions, out Zebra? zebra);
|
||||
|
||||
Utf8JsonReader pigReader = utf8JsonReader;
|
||||
bool pigDeserialized = Client.ClientUtils.TryDeserialize<Pig>(ref pigReader, jsonSerializerOptions, out Pig? pig);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -173,13 +163,16 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (whaleDeserialized)
|
||||
Utf8JsonReader whaleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Whale>(ref whaleReader, jsonSerializerOptions, out Whale? whale))
|
||||
return new Mammal(whale);
|
||||
|
||||
if (zebraDeserialized)
|
||||
Utf8JsonReader zebraReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Zebra>(ref zebraReader, jsonSerializerOptions, out Zebra? zebra))
|
||||
return new Mammal(zebra);
|
||||
|
||||
if (pigDeserialized)
|
||||
Utf8JsonReader pigReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Pig>(ref pigReader, jsonSerializerOptions, out Pig? pig))
|
||||
return new Mammal(pig);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -220,9 +220,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (mapMapOfString == null)
|
||||
throw new ArgumentNullException(nameof(mapMapOfString), "Property is required for class MapTest.");
|
||||
|
||||
@ -235,9 +232,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (indirectMap == null)
|
||||
throw new ArgumentNullException(nameof(indirectMap), "Property is required for class MapTest.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new MapTest(directMap, indirectMap, mapMapOfString, mapOfEnumString);
|
||||
}
|
||||
|
||||
|
@ -183,9 +183,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (uuidWithPattern == null)
|
||||
throw new ArgumentNullException(nameof(uuidWithPattern), "Property is required for class MixedPropertiesAndAdditionalPropertiesClass.");
|
||||
|
||||
@ -198,9 +195,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (map == null)
|
||||
throw new ArgumentNullException(nameof(map), "Property is required for class MixedPropertiesAndAdditionalPropertiesClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new MixedPropertiesAndAdditionalPropertiesClass(dateTime.Value, map, uuid.Value, uuidWithPattern.Value);
|
||||
}
|
||||
|
||||
|
@ -142,18 +142,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class Model200Response.");
|
||||
|
||||
if (classProperty == null)
|
||||
throw new ArgumentNullException(nameof(classProperty), "Property is required for class Model200Response.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Model200Response(classProperty, name.Value);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (clientProperty == null)
|
||||
throw new ArgumentNullException(nameof(clientProperty), "Property is required for class ModelClient.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ModelClient(clientProperty);
|
||||
}
|
||||
|
||||
|
@ -207,9 +207,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (nameProperty == null)
|
||||
throw new ArgumentNullException(nameof(nameProperty), "Property is required for class Name.");
|
||||
|
||||
@ -222,9 +219,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (_123number == null)
|
||||
throw new ArgumentNullException(nameof(_123number), "Property is required for class Name.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Name(nameProperty.Value, property, snakeCase.Value, _123number.Value);
|
||||
}
|
||||
|
||||
|
@ -286,18 +286,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayItemsNullable == null)
|
||||
throw new ArgumentNullException(nameof(arrayItemsNullable), "Property is required for class NullableClass.");
|
||||
|
||||
if (objectItemsNullable == null)
|
||||
throw new ArgumentNullException(nameof(objectItemsNullable), "Property is required for class NullableClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new NullableClass(arrayItemsNullable, objectItemsNullable, arrayAndItemsNullableProp, arrayNullableProp, booleanProp, dateProp, datetimeProp, integerProp, numberProp, objectAndItemsNullableProp, objectNullableProp, stringProp);
|
||||
}
|
||||
|
||||
|
@ -126,13 +126,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
bool triangleDeserialized = Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle);
|
||||
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
bool quadrilateralDeserialized = Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -154,10 +147,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (triangleDeserialized)
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle))
|
||||
return new NullableShape(triangle);
|
||||
|
||||
if (quadrilateralDeserialized)
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral))
|
||||
return new NullableShape(quadrilateral);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (justNumber == null)
|
||||
throw new ArgumentNullException(nameof(justNumber), "Property is required for class NumberOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new NumberOnly(justNumber.Value);
|
||||
}
|
||||
|
||||
|
@ -173,9 +173,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (uuid == null)
|
||||
throw new ArgumentNullException(nameof(uuid), "Property is required for class ObjectWithDeprecatedFields.");
|
||||
|
||||
@ -188,9 +185,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (bars == null)
|
||||
throw new ArgumentNullException(nameof(bars), "Property is required for class ObjectWithDeprecatedFields.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ObjectWithDeprecatedFields(bars, deprecatedRef, id.Value, uuid);
|
||||
}
|
||||
|
||||
|
@ -100,10 +100,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader _stringReader = utf8JsonReader;
|
||||
bool _stringDeserialized = Client.ClientUtils.TryDeserialize<string>(ref _stringReader, jsonSerializerOptions, out string? _string);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -125,7 +121,8 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (_stringDeserialized)
|
||||
Utf8JsonReader _stringReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<string>(ref _stringReader, jsonSerializerOptions, out string? _string))
|
||||
return new OneOfString(_string);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -267,9 +267,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class Order.");
|
||||
|
||||
@ -288,9 +285,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (complete == null)
|
||||
throw new ArgumentNullException(nameof(complete), "Property is required for class Order.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Order(id.Value, petId.Value, quantity.Value, shipDate.Value, status.Value, complete.Value);
|
||||
}
|
||||
|
||||
|
@ -156,9 +156,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (myNumber == null)
|
||||
throw new ArgumentNullException(nameof(myNumber), "Property is required for class OuterComposite.");
|
||||
|
||||
@ -168,9 +165,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (myBoolean == null)
|
||||
throw new ArgumentNullException(nameof(myBoolean), "Property is required for class OuterComposite.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new OuterComposite(myBoolean.Value, myNumber.Value, myString);
|
||||
}
|
||||
|
||||
|
@ -261,9 +261,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class Pet.");
|
||||
|
||||
@ -282,9 +279,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (status == null)
|
||||
throw new ArgumentNullException(nameof(status), "Property is required for class Pet.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Pet(category, id.Value, name, photoUrls, status.Value, tags);
|
||||
}
|
||||
|
||||
|
@ -126,13 +126,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader basquePigReader = utf8JsonReader;
|
||||
bool basquePigDeserialized = Client.ClientUtils.TryDeserialize<BasquePig>(ref basquePigReader, jsonSerializerOptions, out BasquePig? basquePig);
|
||||
|
||||
Utf8JsonReader danishPigReader = utf8JsonReader;
|
||||
bool danishPigDeserialized = Client.ClientUtils.TryDeserialize<DanishPig>(ref danishPigReader, jsonSerializerOptions, out DanishPig? danishPig);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -154,10 +147,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (basquePigDeserialized)
|
||||
Utf8JsonReader basquePigReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<BasquePig>(ref basquePigReader, jsonSerializerOptions, out BasquePig? basquePig))
|
||||
return new Pig(basquePig);
|
||||
|
||||
if (danishPigDeserialized)
|
||||
Utf8JsonReader danishPigReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<DanishPig>(ref danishPigReader, jsonSerializerOptions, out DanishPig? danishPig))
|
||||
return new Pig(danishPig);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -148,19 +148,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader _boolReader = utf8JsonReader;
|
||||
bool _boolDeserialized = Client.ClientUtils.TryDeserialize<bool>(ref _boolReader, jsonSerializerOptions, out bool _bool);
|
||||
|
||||
Utf8JsonReader _stringReader = utf8JsonReader;
|
||||
bool _stringDeserialized = Client.ClientUtils.TryDeserialize<string>(ref _stringReader, jsonSerializerOptions, out string? _string);
|
||||
|
||||
Utf8JsonReader _objectReader = utf8JsonReader;
|
||||
bool _objectDeserialized = Client.ClientUtils.TryDeserialize<Object>(ref _objectReader, jsonSerializerOptions, out Object? _object);
|
||||
|
||||
Utf8JsonReader liststringReader = utf8JsonReader;
|
||||
bool liststringDeserialized = Client.ClientUtils.TryDeserialize<List<string>>(ref liststringReader, jsonSerializerOptions, out List<string>? liststring);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -182,16 +169,20 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (_boolDeserialized)
|
||||
Utf8JsonReader _boolReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<bool>(ref _boolReader, jsonSerializerOptions, out bool _bool))
|
||||
return new PolymorphicProperty(_bool);
|
||||
|
||||
if (_stringDeserialized)
|
||||
Utf8JsonReader _stringReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<string>(ref _stringReader, jsonSerializerOptions, out string? _string))
|
||||
return new PolymorphicProperty(_string);
|
||||
|
||||
if (_objectDeserialized)
|
||||
Utf8JsonReader _objectReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Object>(ref _objectReader, jsonSerializerOptions, out Object? _object))
|
||||
return new PolymorphicProperty(_object);
|
||||
|
||||
if (liststringDeserialized)
|
||||
Utf8JsonReader liststringReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<List<string>>(ref liststringReader, jsonSerializerOptions, out List<string>? liststring))
|
||||
return new PolymorphicProperty(liststring);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -126,13 +126,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader simpleQuadrilateralReader = utf8JsonReader;
|
||||
bool simpleQuadrilateralDeserialized = Client.ClientUtils.TryDeserialize<SimpleQuadrilateral>(ref simpleQuadrilateralReader, jsonSerializerOptions, out SimpleQuadrilateral? simpleQuadrilateral);
|
||||
|
||||
Utf8JsonReader complexQuadrilateralReader = utf8JsonReader;
|
||||
bool complexQuadrilateralDeserialized = Client.ClientUtils.TryDeserialize<ComplexQuadrilateral>(ref complexQuadrilateralReader, jsonSerializerOptions, out ComplexQuadrilateral? complexQuadrilateral);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
@ -154,10 +147,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
if (simpleQuadrilateralDeserialized)
|
||||
Utf8JsonReader simpleQuadrilateralReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<SimpleQuadrilateral>(ref simpleQuadrilateralReader, jsonSerializerOptions, out SimpleQuadrilateral? simpleQuadrilateral))
|
||||
return new Quadrilateral(simpleQuadrilateral);
|
||||
|
||||
if (complexQuadrilateralDeserialized)
|
||||
Utf8JsonReader complexQuadrilateralReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<ComplexQuadrilateral>(ref complexQuadrilateralReader, jsonSerializerOptions, out ComplexQuadrilateral? complexQuadrilateral))
|
||||
return new Quadrilateral(complexQuadrilateral);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (quadrilateralType == null)
|
||||
throw new ArgumentNullException(nameof(quadrilateralType), "Property is required for class QuadrilateralInterface.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new QuadrilateralInterface(quadrilateralType);
|
||||
}
|
||||
|
||||
|
@ -177,18 +177,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (bar == null)
|
||||
throw new ArgumentNullException(nameof(bar), "Property is required for class ReadOnlyFirst.");
|
||||
|
||||
if (baz == null)
|
||||
throw new ArgumentNullException(nameof(baz), "Property is required for class ReadOnlyFirst.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ReadOnlyFirst(bar, baz);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (returnProperty == null)
|
||||
throw new ArgumentNullException(nameof(returnProperty), "Property is required for class Return.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Return(returnProperty.Value);
|
||||
}
|
||||
|
||||
|
@ -113,7 +113,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader triangleInterfaceReader = utf8JsonReader;
|
||||
bool triangleInterfaceDeserialized = Client.ClientUtils.TryDeserialize<TriangleInterface>(ref utf8JsonReader, jsonSerializerOptions, out TriangleInterface? triangleInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -137,12 +137,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
bool triangleDeserialized = Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle);
|
||||
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
bool quadrilateralDeserialized = Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral);
|
||||
|
||||
string? quadrilateralType = default;
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
@ -169,19 +163,15 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (quadrilateralType == null)
|
||||
throw new ArgumentNullException(nameof(quadrilateralType), "Property is required for class Shape.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (triangleDeserialized)
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle))
|
||||
return new Shape(triangle, quadrilateralType);
|
||||
|
||||
if (quadrilateralDeserialized)
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral))
|
||||
return new Shape(quadrilateral, quadrilateralType);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (shapeType == null)
|
||||
throw new ArgumentNullException(nameof(shapeType), "Property is required for class ShapeInterface.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ShapeInterface(shapeType);
|
||||
}
|
||||
|
||||
|
@ -137,12 +137,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
bool triangleDeserialized = Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle);
|
||||
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
bool quadrilateralDeserialized = Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral);
|
||||
|
||||
string? quadrilateralType = default;
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
@ -169,19 +163,15 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (quadrilateralType == null)
|
||||
throw new ArgumentNullException(nameof(quadrilateralType), "Property is required for class ShapeOrNull.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (triangleDeserialized)
|
||||
Utf8JsonReader triangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Triangle>(ref triangleReader, jsonSerializerOptions, out Triangle? triangle))
|
||||
return new ShapeOrNull(triangle, quadrilateralType);
|
||||
|
||||
if (quadrilateralDeserialized)
|
||||
Utf8JsonReader quadrilateralReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<Quadrilateral>(ref quadrilateralReader, jsonSerializerOptions, out Quadrilateral? quadrilateral))
|
||||
return new ShapeOrNull(quadrilateral, quadrilateralType);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -113,7 +113,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader quadrilateralInterfaceReader = utf8JsonReader;
|
||||
bool quadrilateralInterfaceDeserialized = Client.ClientUtils.TryDeserialize<QuadrilateralInterface>(ref utf8JsonReader, jsonSerializerOptions, out QuadrilateralInterface? quadrilateralInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -142,18 +142,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (specialPropertyName == null)
|
||||
throw new ArgumentNullException(nameof(specialPropertyName), "Property is required for class SpecialModelName.");
|
||||
|
||||
if (specialModelNameProperty == null)
|
||||
throw new ArgumentNullException(nameof(specialModelNameProperty), "Property is required for class SpecialModelName.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new SpecialModelName(specialModelNameProperty, specialPropertyName.Value);
|
||||
}
|
||||
|
||||
|
@ -142,18 +142,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class Tag.");
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class Tag.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Tag(id.Value, name);
|
||||
}
|
||||
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (value == null)
|
||||
throw new ArgumentNullException(nameof(value), "Property is required for class TestCollectionEndingWithWordList.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new TestCollectionEndingWithWordList(value);
|
||||
}
|
||||
|
||||
|
@ -129,15 +129,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (testCollectionEndingWithWordList == null)
|
||||
throw new ArgumentNullException(nameof(testCollectionEndingWithWordList), "Property is required for class TestCollectionEndingWithWordListObject.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new TestCollectionEndingWithWordListObject(testCollectionEndingWithWordList);
|
||||
}
|
||||
|
||||
|
@ -168,15 +168,6 @@ namespace Org.OpenAPITools.Model
|
||||
|
||||
JsonTokenType startingTokenType = utf8JsonReader.TokenType;
|
||||
|
||||
Utf8JsonReader equilateralTriangleReader = utf8JsonReader;
|
||||
bool equilateralTriangleDeserialized = Client.ClientUtils.TryDeserialize<EquilateralTriangle>(ref equilateralTriangleReader, jsonSerializerOptions, out EquilateralTriangle? equilateralTriangle);
|
||||
|
||||
Utf8JsonReader isoscelesTriangleReader = utf8JsonReader;
|
||||
bool isoscelesTriangleDeserialized = Client.ClientUtils.TryDeserialize<IsoscelesTriangle>(ref isoscelesTriangleReader, jsonSerializerOptions, out IsoscelesTriangle? isoscelesTriangle);
|
||||
|
||||
Utf8JsonReader scaleneTriangleReader = utf8JsonReader;
|
||||
bool scaleneTriangleDeserialized = Client.ClientUtils.TryDeserialize<ScaleneTriangle>(ref scaleneTriangleReader, jsonSerializerOptions, out ScaleneTriangle? scaleneTriangle);
|
||||
|
||||
string? shapeType = default;
|
||||
string? triangleType = default;
|
||||
|
||||
@ -207,25 +198,22 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (shapeType == null)
|
||||
throw new ArgumentNullException(nameof(shapeType), "Property is required for class Triangle.");
|
||||
|
||||
if (triangleType == null)
|
||||
throw new ArgumentNullException(nameof(triangleType), "Property is required for class Triangle.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (equilateralTriangleDeserialized)
|
||||
Utf8JsonReader equilateralTriangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<EquilateralTriangle>(ref equilateralTriangleReader, jsonSerializerOptions, out EquilateralTriangle? equilateralTriangle))
|
||||
return new Triangle(equilateralTriangle, shapeType, triangleType);
|
||||
|
||||
if (isoscelesTriangleDeserialized)
|
||||
Utf8JsonReader isoscelesTriangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<IsoscelesTriangle>(ref isoscelesTriangleReader, jsonSerializerOptions, out IsoscelesTriangle? isoscelesTriangle))
|
||||
return new Triangle(isoscelesTriangle, shapeType, triangleType);
|
||||
|
||||
if (scaleneTriangleDeserialized)
|
||||
Utf8JsonReader scaleneTriangleReader = utf8JsonReader;
|
||||
if (Client.ClientUtils.TryDeserialize<ScaleneTriangle>(ref scaleneTriangleReader, jsonSerializerOptions, out ScaleneTriangle? scaleneTriangle))
|
||||
return new Triangle(scaleneTriangle, shapeType, triangleType);
|
||||
|
||||
throw new JsonException();
|
||||
|
@ -128,15 +128,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (triangleType == null)
|
||||
throw new ArgumentNullException(nameof(triangleType), "Property is required for class TriangleInterface.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new TriangleInterface(triangleType);
|
||||
}
|
||||
|
||||
|
@ -282,9 +282,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class User.");
|
||||
|
||||
@ -312,9 +309,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (objectWithNoDeclaredProps == null)
|
||||
throw new ArgumentNullException(nameof(objectWithNoDeclaredProps), "Property is required for class User.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new User(email, firstName, id.Value, lastName, objectWithNoDeclaredProps, password, phone, userStatus.Value, username, anyTypeProp, anyTypePropNullable, objectWithNoDeclaredPropsNullable);
|
||||
}
|
||||
|
||||
|
@ -156,9 +156,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (hasBaleen == null)
|
||||
throw new ArgumentNullException(nameof(hasBaleen), "Property is required for class Whale.");
|
||||
|
||||
@ -168,9 +165,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class Whale.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Whale(className, hasBaleen.Value, hasTeeth.Value);
|
||||
}
|
||||
|
||||
|
@ -203,18 +203,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (type == null)
|
||||
throw new ArgumentNullException(nameof(type), "Property is required for class Zebra.");
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class Zebra.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Zebra(className, type.Value);
|
||||
}
|
||||
|
||||
|
@ -178,15 +178,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (zeroBasedEnum == null)
|
||||
throw new ArgumentNullException(nameof(zeroBasedEnum), "Property is required for class ZeroBasedEnumClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ZeroBasedEnumClass(zeroBasedEnum.Value);
|
||||
}
|
||||
|
||||
|
@ -127,15 +127,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (activityOutputs == null)
|
||||
throw new ArgumentNullException(nameof(activityOutputs), "Property is required for class Activity.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Activity(activityOutputs);
|
||||
}
|
||||
|
||||
|
@ -140,18 +140,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (prop1 == null)
|
||||
throw new ArgumentNullException(nameof(prop1), "Property is required for class ActivityOutputElementRepresentation.");
|
||||
|
||||
if (prop2 == null)
|
||||
throw new ArgumentNullException(nameof(prop2), "Property is required for class ActivityOutputElementRepresentation.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ActivityOutputElementRepresentation(prop1, prop2);
|
||||
}
|
||||
|
||||
|
@ -226,9 +226,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (mapProperty == null)
|
||||
throw new ArgumentNullException(nameof(mapProperty), "Property is required for class AdditionalPropertiesClass.");
|
||||
|
||||
@ -250,9 +247,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (mapWithUndeclaredPropertiesString == null)
|
||||
throw new ArgumentNullException(nameof(mapWithUndeclaredPropertiesString), "Property is required for class AdditionalPropertiesClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new AdditionalPropertiesClass(emptyMap, mapOfMapProperty, mapProperty, mapWithUndeclaredPropertiesAnytype1, mapWithUndeclaredPropertiesAnytype2, mapWithUndeclaredPropertiesAnytype3, mapWithUndeclaredPropertiesString, anytype1);
|
||||
}
|
||||
|
||||
|
@ -149,18 +149,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class Animal.");
|
||||
|
||||
if (color == null)
|
||||
throw new ArgumentNullException(nameof(color), "Property is required for class Animal.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Animal(className, color);
|
||||
}
|
||||
|
||||
|
@ -153,9 +153,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (code == null)
|
||||
throw new ArgumentNullException(nameof(code), "Property is required for class ApiResponse.");
|
||||
|
||||
@ -165,9 +162,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (message == null)
|
||||
throw new ArgumentNullException(nameof(message), "Property is required for class ApiResponse.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ApiResponse(code.Value, message, type);
|
||||
}
|
||||
|
||||
|
@ -153,18 +153,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (cultivar == null)
|
||||
throw new ArgumentNullException(nameof(cultivar), "Property is required for class Apple.");
|
||||
|
||||
if (origin == null)
|
||||
throw new ArgumentNullException(nameof(origin), "Property is required for class Apple.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Apple(cultivar, origin);
|
||||
}
|
||||
|
||||
|
@ -133,18 +133,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (cultivar == null)
|
||||
throw new ArgumentNullException(nameof(cultivar), "Property is required for class AppleReq.");
|
||||
|
||||
if (mealy == null)
|
||||
throw new ArgumentNullException(nameof(mealy), "Property is required for class AppleReq.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new AppleReq(cultivar, mealy.Value);
|
||||
}
|
||||
|
||||
|
@ -127,15 +127,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayArrayNumber == null)
|
||||
throw new ArgumentNullException(nameof(arrayArrayNumber), "Property is required for class ArrayOfArrayOfNumberOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayOfArrayOfNumberOnly(arrayArrayNumber);
|
||||
}
|
||||
|
||||
|
@ -127,15 +127,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayNumber == null)
|
||||
throw new ArgumentNullException(nameof(arrayNumber), "Property is required for class ArrayOfNumberOnly.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayOfNumberOnly(arrayNumber);
|
||||
}
|
||||
|
||||
|
@ -155,9 +155,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (arrayOfString == null)
|
||||
throw new ArgumentNullException(nameof(arrayOfString), "Property is required for class ArrayTest.");
|
||||
|
||||
@ -167,9 +164,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (arrayArrayOfModel == null)
|
||||
throw new ArgumentNullException(nameof(arrayArrayOfModel), "Property is required for class ArrayTest.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ArrayTest(arrayArrayOfInteger, arrayArrayOfModel, arrayOfString);
|
||||
}
|
||||
|
||||
|
@ -127,15 +127,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (lengthCm == null)
|
||||
throw new ArgumentNullException(nameof(lengthCm), "Property is required for class Banana.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Banana(lengthCm.Value);
|
||||
}
|
||||
|
||||
|
@ -134,18 +134,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (lengthCm == null)
|
||||
throw new ArgumentNullException(nameof(lengthCm), "Property is required for class BananaReq.");
|
||||
|
||||
if (sweet == null)
|
||||
throw new ArgumentNullException(nameof(sweet), "Property is required for class BananaReq.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new BananaReq(lengthCm.Value, sweet.Value);
|
||||
}
|
||||
|
||||
|
@ -126,15 +126,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class BasquePig.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new BasquePig(className);
|
||||
}
|
||||
|
||||
|
@ -192,9 +192,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (smallCamel == null)
|
||||
throw new ArgumentNullException(nameof(smallCamel), "Property is required for class Capitalization.");
|
||||
|
||||
@ -213,9 +210,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (aTTNAME == null)
|
||||
throw new ArgumentNullException(nameof(aTTNAME), "Property is required for class Capitalization.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Capitalization(aTTNAME, capitalCamel, capitalSnake, sCAETHFlowPoints, smallCamel, smallSnake);
|
||||
}
|
||||
|
||||
|
@ -127,15 +127,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (declawed == null)
|
||||
throw new ArgumentNullException(nameof(declawed), "Property is required for class CatAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new CatAllOf(declawed.Value);
|
||||
}
|
||||
|
||||
|
@ -140,18 +140,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (id == null)
|
||||
throw new ArgumentNullException(nameof(id), "Property is required for class Category.");
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class Category.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Category(id.Value, name);
|
||||
}
|
||||
|
||||
|
@ -178,18 +178,12 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class ChildCatAllOf.");
|
||||
|
||||
if (petType == null)
|
||||
throw new ArgumentNullException(nameof(petType), "Property is required for class ChildCatAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ChildCatAllOf(name, petType.Value);
|
||||
}
|
||||
|
||||
|
@ -126,15 +126,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (classProperty == null)
|
||||
throw new ArgumentNullException(nameof(classProperty), "Property is required for class ClassModel.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new ClassModel(classProperty);
|
||||
}
|
||||
|
||||
|
@ -111,7 +111,6 @@ namespace Org.OpenAPITools.Model
|
||||
Utf8JsonReader quadrilateralInterfaceReader = utf8JsonReader;
|
||||
bool quadrilateralInterfaceDeserialized = Client.ClientUtils.TryDeserialize<QuadrilateralInterface>(ref utf8JsonReader, jsonSerializerOptions, out QuadrilateralInterface quadrilateralInterface);
|
||||
|
||||
|
||||
while (utf8JsonReader.Read())
|
||||
{
|
||||
if (startingTokenType == JsonTokenType.StartObject && utf8JsonReader.TokenType == JsonTokenType.EndObject && currentDepth == utf8JsonReader.CurrentDepth)
|
||||
|
@ -126,15 +126,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (className == null)
|
||||
throw new ArgumentNullException(nameof(className), "Property is required for class DanishPig.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DanishPig(className);
|
||||
}
|
||||
|
||||
|
@ -133,15 +133,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (dateOnlyProperty == null)
|
||||
throw new ArgumentNullException(nameof(dateOnlyProperty), "Property is required for class DateOnlyClass.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DateOnlyClass(dateOnlyProperty.Value);
|
||||
}
|
||||
|
||||
|
@ -126,15 +126,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (name == null)
|
||||
throw new ArgumentNullException(nameof(name), "Property is required for class DeprecatedObject.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DeprecatedObject(name);
|
||||
}
|
||||
|
||||
|
@ -126,15 +126,9 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (breed == null)
|
||||
throw new ArgumentNullException(nameof(breed), "Property is required for class DogAllOf.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new DogAllOf(breed);
|
||||
}
|
||||
|
||||
|
@ -163,9 +163,6 @@ namespace Org.OpenAPITools.Model
|
||||
}
|
||||
}
|
||||
|
||||
#pragma warning disable CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning disable CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
if (mainShape == null)
|
||||
throw new ArgumentNullException(nameof(mainShape), "Property is required for class Drawing.");
|
||||
|
||||
@ -175,9 +172,6 @@ namespace Org.OpenAPITools.Model
|
||||
if (shapes == null)
|
||||
throw new ArgumentNullException(nameof(shapes), "Property is required for class Drawing.");
|
||||
|
||||
#pragma warning restore CS0472 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
#pragma warning restore CS8073 // The result of the expression is always the same since a value of this type is never equal to 'null'
|
||||
|
||||
return new Drawing(mainShape, shapeOrNull, shapes, nullableShape);
|
||||
}
|
||||
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user