[csharp] Delete and build samples (#13641)

* delete and build samples

* how did this not get committed?

* how did this not get committed?

* how did this not get committed?

* fixed csharp netcore functions

* reverted two files

* restored manually created tests

* reverted some unintentional changes

* restored unintended changes
This commit is contained in:
devhl-labs 2022-10-15 22:18:48 -04:00 committed by GitHub
parent cafdf64ca5
commit f11cb7f17d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
379 changed files with 1980 additions and 16312 deletions

View File

@ -2,5 +2,6 @@ generatorName: csharp-netcore-functions
outputDir: samples/client/petstore/csharp-netcore-functions outputDir: samples/client/petstore/csharp-netcore-functions
inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore.yaml inputSpec: modules/openapi-generator/src/test/resources/3_0/petstore.yaml
templateDir: modules/openapi-generator/src/main/resources/csharp-netcore-functions templateDir: modules/openapi-generator/src/main/resources/csharp-netcore-functions
#additionalProperties: additionalProperties:
# packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}' packageGuid: '{321C8C3F-0156-40C1-AE42-D59761FB9B6C}'
userSecretsGuid: "76e9e993-9159-441c-9c5b-fe95e7f4f020"

View File

@ -304,7 +304,12 @@ public class CsharpNetcoreFunctionsServerCodegen extends AbstractCSharpCodegen {
setPackageGuid((String) additionalProperties.get(CodegenConstants.OPTIONAL_PROJECT_GUID)); setPackageGuid((String) additionalProperties.get(CodegenConstants.OPTIONAL_PROJECT_GUID));
} }
additionalProperties.put("packageGuid", packageGuid); additionalProperties.put("packageGuid", packageGuid);
additionalProperties.put("userSecretsGuid", userSecretsGuid);
if (!additionalProperties.containsKey("userSecretsGuid")) {
additionalProperties.put("userSecretsGuid", userSecretsGuid);
} else {
userSecretsGuid = (String) additionalProperties.get("userSecretsGuid");
}
if (!additionalProperties.containsKey(NEWTONSOFT_VERSION)) { if (!additionalProperties.containsKey(NEWTONSOFT_VERSION)) {
additionalProperties.put(NEWTONSOFT_VERSION, newtonsoftVersion); additionalProperties.put(NEWTONSOFT_VERSION, newtonsoftVersion);

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Files** | **List<System.IO.Stream>** | Many files | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject1
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**File** | **System.IO.Stream** | One file | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,12 +0,0 @@
# Org.OpenAPITools.Model.InlineObject2
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Status** | **MultipartMixedStatus** | |
**Marker** | [**MultipartMixedMarker**](MultipartMixedMarker.md) | | [optional]
**File** | **System.IO.Stream** | a file |
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,11 +0,0 @@
# Org.OpenAPITools.Model.MultipartMixedMarker
additional object
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Name** | **string** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -72,9 +72,10 @@ namespace Org.OpenAPITools.Test.Api
public void MultipartMixedTest() public void MultipartMixedTest()
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//MultipartMixedStatus status = null;
//System.IO.Stream file = null; //System.IO.Stream file = null;
//MultipartMixedMarker marker = null; //MultipartMixedRequestMarker marker = null;
//instance.MultipartMixed(file, marker); //instance.MultipartMixed(status, file, marker);
} }
/// <summary> /// <summary>

View File

@ -1,70 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject1
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject1Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject1
//private InlineObject1 instance;
public InlineObject1Tests()
{
// TODO uncomment below to create an instance of InlineObject1
//instance = new InlineObject1();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject1
/// </summary>
[Fact]
public void InlineObject1InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject1
//Assert.IsType<InlineObject1>(instance);
}
/// <summary>
/// Test the property 'File'
/// </summary>
[Fact]
public void FileTest()
{
// TODO unit test for the property 'File'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject2
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject2Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject2
//private InlineObject2 instance;
public InlineObject2Tests()
{
// TODO uncomment below to create an instance of InlineObject2
//instance = new InlineObject2();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject2
/// </summary>
[Fact]
public void InlineObject2InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject2
//Assert.IsType<InlineObject2>(instance);
}
/// <summary>
/// Test the property 'Marker'
/// </summary>
[Fact]
public void MarkerTest()
{
// TODO unit test for the property 'Marker'
}
/// <summary>
/// Test the property 'File'
/// </summary>
[Fact]
public void FileTest()
{
// TODO unit test for the property 'File'
}
}
}

View File

@ -1,70 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObjectTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject
//private InlineObject instance;
public InlineObjectTests()
{
// TODO uncomment below to create an instance of InlineObject
//instance = new InlineObject();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject
/// </summary>
[Fact]
public void InlineObjectInstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject
//Assert.IsType<InlineObject>(instance);
}
/// <summary>
/// Test the property 'Files'
/// </summary>
[Fact]
public void FilesTest()
{
// TODO unit test for the property 'Files'
}
}
}

View File

@ -1,70 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing MultipartMixedMarker
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class MultipartMixedMarkerTests : IDisposable
{
// TODO uncomment below to declare an instance variable for MultipartMixedMarker
//private MultipartMixedMarker instance;
public MultipartMixedMarkerTests()
{
// TODO uncomment below to create an instance of MultipartMixedMarker
//instance = new MultipartMixedMarker();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of MultipartMixedMarker
/// </summary>
[Fact]
public void MultipartMixedMarkerInstanceTest()
{
// TODO uncomment below to test "IsType" MultipartMixedMarker
//Assert.IsType<MultipartMixedMarker>(instance);
}
/// <summary>
/// Test the property 'Name'
/// </summary>
[Fact]
public void NameTest()
{
// TODO unit test for the property 'Name'
}
}
}

View File

@ -1,121 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject
/// </summary>
[DataContract(Name = "inline_object")]
public partial class InlineObject : IEquatable<InlineObject>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject" /> class.
/// </summary>
/// <param name="files">Many files.</param>
public InlineObject(List<System.IO.Stream> files = default(List<System.IO.Stream>))
{
this.Files = files;
}
/// <summary>
/// Many files
/// </summary>
/// <value>Many files</value>
[DataMember(Name = "files", EmitDefaultValue = false)]
public List<System.IO.Stream> Files { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineObject {\n");
sb.Append(" Files: ").Append(Files).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject).AreEqual;
}
/// <summary>
/// Returns true if InlineObject instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.Files != null)
{
hashCode = (hashCode * 59) + this.Files.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,121 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject1
/// </summary>
[DataContract(Name = "inline_object_1")]
public partial class InlineObject1 : IEquatable<InlineObject1>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject1" /> class.
/// </summary>
/// <param name="file">One file.</param>
public InlineObject1(System.IO.Stream file = default(System.IO.Stream))
{
this.File = file;
}
/// <summary>
/// One file
/// </summary>
/// <value>One file</value>
[DataMember(Name = "file", EmitDefaultValue = false)]
public System.IO.Stream File { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineObject1 {\n");
sb.Append(" File: ").Append(File).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject1).AreEqual;
}
/// <summary>
/// Returns true if InlineObject1 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject1 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject1 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.File != null)
{
hashCode = (hashCode * 59) + this.File.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,154 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject2
/// </summary>
[DataContract(Name = "inline_object_2")]
public partial class InlineObject2 : IEquatable<InlineObject2>, IValidatableObject
{
/// <summary>
/// Gets or Sets Status
/// </summary>
[DataMember(Name = "status", IsRequired = true, EmitDefaultValue = false)]
public MultipartMixedStatus Status { get; set; }
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject2" /> class.
/// </summary>
[JsonConstructorAttribute]
protected InlineObject2() { }
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject2" /> class.
/// </summary>
/// <param name="status">status (required).</param>
/// <param name="marker">marker.</param>
/// <param name="file">a file (required).</param>
public InlineObject2(MultipartMixedStatus status = default(MultipartMixedStatus), MultipartMixedMarker marker = default(MultipartMixedMarker), System.IO.Stream file = default(System.IO.Stream))
{
this.Status = status;
// to ensure "file" is required (not null)
if (file == null)
{
throw new ArgumentNullException("file is a required property for InlineObject2 and cannot be null");
}
this.File = file;
this.Marker = marker;
}
/// <summary>
/// Gets or Sets Marker
/// </summary>
[DataMember(Name = "marker", EmitDefaultValue = false)]
public MultipartMixedMarker Marker { get; set; }
/// <summary>
/// a file
/// </summary>
/// <value>a file</value>
[DataMember(Name = "file", IsRequired = true, EmitDefaultValue = false)]
public System.IO.Stream File { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineObject2 {\n");
sb.Append(" Status: ").Append(Status).Append("\n");
sb.Append(" Marker: ").Append(Marker).Append("\n");
sb.Append(" File: ").Append(File).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject2).AreEqual;
}
/// <summary>
/// Returns true if InlineObject2 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject2 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject2 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
hashCode = (hashCode * 59) + this.Status.GetHashCode();
if (this.Marker != null)
{
hashCode = (hashCode * 59) + this.Marker.GetHashCode();
}
if (this.File != null)
{
hashCode = (hashCode * 59) + this.File.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,120 +0,0 @@
/*
* MultipartFile test
*
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// additional object
/// </summary>
[DataContract(Name = "_multipart_mixed_marker")]
public partial class MultipartMixedMarker : IEquatable<MultipartMixedMarker>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="MultipartMixedMarker" /> class.
/// </summary>
/// <param name="name">name.</param>
public MultipartMixedMarker(string name = default(string))
{
this.Name = name;
}
/// <summary>
/// Gets or Sets Name
/// </summary>
[DataMember(Name = "name", EmitDefaultValue = false)]
public string Name { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class MultipartMixedMarker {\n");
sb.Append(" Name: ").Append(Name).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as MultipartMixedMarker).AreEqual;
}
/// <summary>
/// Returns true if MultipartMixedMarker instances are equal
/// </summary>
/// <param name="input">Instance of MultipartMixedMarker to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(MultipartMixedMarker input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.Name != null)
{
hashCode = (hashCode * 59) + this.Name.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,156 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.IO;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Reflection;
using RestSharp;
using Xunit;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Apis;
// uncomment below to import models
//using Org.OpenAPITools.Models;
namespace Org.OpenAPITools.Test.Api
{
/// <summary>
/// Class for testing PetApi
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the API endpoint.
/// </remarks>
public class PetApiTests : IDisposable
{
private PetApi instance;
public PetApiTests()
{
instance = new PetApi();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of PetApi
/// </summary>
[Fact]
public void InstanceTest()
{
// TODO uncomment below to test 'IsType' PetApi
//Assert.IsType<PetApi>(instance);
}
/// <summary>
/// Test AddPet
/// </summary>
[Fact]
public void AddPetTest()
{
// TODO uncomment below to test the method and replace null with proper value
//Pet pet = null;
//var response = instance.AddPet(pet);
//Assert.IsType<Pet>(response);
}
/// <summary>
/// Test DeletePet
/// </summary>
[Fact]
public void DeletePetTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long petId = null;
//string apiKey = null;
//instance.DeletePet(petId, apiKey);
}
/// <summary>
/// Test FindPetsByStatus
/// </summary>
[Fact]
public void FindPetsByStatusTest()
{
// TODO uncomment below to test the method and replace null with proper value
//List<string> status = null;
//var response = instance.FindPetsByStatus(status);
//Assert.IsType<List<Pet>>(response);
}
/// <summary>
/// Test FindPetsByTags
/// </summary>
[Fact]
public void FindPetsByTagsTest()
{
// TODO uncomment below to test the method and replace null with proper value
//List<string> tags = null;
//var response = instance.FindPetsByTags(tags);
//Assert.IsType<List<Pet>>(response);
}
/// <summary>
/// Test GetPetById
/// </summary>
[Fact]
public void GetPetByIdTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long petId = null;
//var response = instance.GetPetById(petId);
//Assert.IsType<Pet>(response);
}
/// <summary>
/// Test UpdatePet
/// </summary>
[Fact]
public void UpdatePetTest()
{
// TODO uncomment below to test the method and replace null with proper value
//Pet pet = null;
//var response = instance.UpdatePet(pet);
//Assert.IsType<Pet>(response);
}
/// <summary>
/// Test UpdatePetWithForm
/// </summary>
[Fact]
public void UpdatePetWithFormTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long petId = null;
//string name = null;
//string status = null;
//instance.UpdatePetWithForm(petId, name, status);
}
/// <summary>
/// Test UploadFile
/// </summary>
[Fact]
public void UploadFileTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long petId = null;
//string additionalMetadata = null;
//System.IO.Stream file = null;
//var response = instance.UploadFile(petId, additionalMetadata, file);
//Assert.IsType<ApiResponse>(response);
}
}
}

View File

@ -1,103 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.IO;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Reflection;
using RestSharp;
using Xunit;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Apis;
// uncomment below to import models
//using Org.OpenAPITools.Models;
namespace Org.OpenAPITools.Test.Api
{
/// <summary>
/// Class for testing StoreApi
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the API endpoint.
/// </remarks>
public class StoreApiTests : IDisposable
{
private StoreApi instance;
public StoreApiTests()
{
instance = new StoreApi();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of StoreApi
/// </summary>
[Fact]
public void InstanceTest()
{
// TODO uncomment below to test 'IsType' StoreApi
//Assert.IsType<StoreApi>(instance);
}
/// <summary>
/// Test DeleteOrder
/// </summary>
[Fact]
public void DeleteOrderTest()
{
// TODO uncomment below to test the method and replace null with proper value
//string orderId = null;
//instance.DeleteOrder(orderId);
}
/// <summary>
/// Test GetInventory
/// </summary>
[Fact]
public void GetInventoryTest()
{
// TODO uncomment below to test the method and replace null with proper value
//var response = instance.GetInventory();
//Assert.IsType<Dictionary<string, int>>(response);
}
/// <summary>
/// Test GetOrderById
/// </summary>
[Fact]
public void GetOrderByIdTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long orderId = null;
//var response = instance.GetOrderById(orderId);
//Assert.IsType<Order>(response);
}
/// <summary>
/// Test PlaceOrder
/// </summary>
[Fact]
public void PlaceOrderTest()
{
// TODO uncomment below to test the method and replace null with proper value
//Order order = null;
//var response = instance.PlaceOrder(order);
//Assert.IsType<Order>(response);
}
}
}

View File

@ -1,148 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.IO;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.Reflection;
using RestSharp;
using Xunit;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Apis;
// uncomment below to import models
//using Org.OpenAPITools.Models;
namespace Org.OpenAPITools.Test.Api
{
/// <summary>
/// Class for testing UserApi
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the API endpoint.
/// </remarks>
public class UserApiTests : IDisposable
{
private UserApi instance;
public UserApiTests()
{
instance = new UserApi();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of UserApi
/// </summary>
[Fact]
public void InstanceTest()
{
// TODO uncomment below to test 'IsType' UserApi
//Assert.IsType<UserApi>(instance);
}
/// <summary>
/// Test CreateUser
/// </summary>
[Fact]
public void CreateUserTest()
{
// TODO uncomment below to test the method and replace null with proper value
//User user = null;
//instance.CreateUser(user);
}
/// <summary>
/// Test CreateUsersWithArrayInput
/// </summary>
[Fact]
public void CreateUsersWithArrayInputTest()
{
// TODO uncomment below to test the method and replace null with proper value
//List<User> user = null;
//instance.CreateUsersWithArrayInput(user);
}
/// <summary>
/// Test CreateUsersWithListInput
/// </summary>
[Fact]
public void CreateUsersWithListInputTest()
{
// TODO uncomment below to test the method and replace null with proper value
//List<User> user = null;
//instance.CreateUsersWithListInput(user);
}
/// <summary>
/// Test DeleteUser
/// </summary>
[Fact]
public void DeleteUserTest()
{
// TODO uncomment below to test the method and replace null with proper value
//string username = null;
//instance.DeleteUser(username);
}
/// <summary>
/// Test GetUserByName
/// </summary>
[Fact]
public void GetUserByNameTest()
{
// TODO uncomment below to test the method and replace null with proper value
//string username = null;
//var response = instance.GetUserByName(username);
//Assert.IsType<User>(response);
}
/// <summary>
/// Test LoginUser
/// </summary>
[Fact]
public void LoginUserTest()
{
// TODO uncomment below to test the method and replace null with proper value
//string username = null;
//string password = null;
//var response = instance.LoginUser(username, password);
//Assert.IsType<string>(response);
}
/// <summary>
/// Test LogoutUser
/// </summary>
[Fact]
public void LogoutUserTest()
{
// TODO uncomment below to test the method and replace null with proper value
//instance.LogoutUser();
}
/// <summary>
/// Test UpdateUser
/// </summary>
[Fact]
public void UpdateUserTest()
{
// TODO uncomment below to test the method and replace null with proper value
//string username = null;
//User user = null;
//instance.UpdateUser(username, user);
}
}
}

View File

@ -1,13 +0,0 @@
# Org.OpenAPITools.Models.ApiResponse
Describes the result of uploading an image resource
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Code** | **int** | | [optional]
**Type** | **string** | | [optional]
**Message** | **string** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,12 +0,0 @@
# Org.OpenAPITools.Models.Category
A category for a pet
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **long** | | [optional]
**Name** | **string** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,16 +0,0 @@
# Org.OpenAPITools.Models.Order
An order for a pets from the pet store
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **long** | | [optional]
**PetId** | **long** | | [optional]
**Quantity** | **int** | | [optional]
**ShipDate** | **DateTime** | | [optional]
**Status** | **string** | Order Status | [optional]
**Complete** | **bool** | | [optional] [default to false]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,16 +0,0 @@
# Org.OpenAPITools.Models.Pet
A pet for sale in the pet store
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **long** | | [optional]
**Category** | [**Category**](Category.md) | | [optional]
**Name** | **string** | |
**PhotoUrls** | **List&lt;string&gt;** | |
**Tags** | [**List&lt;Tag&gt;**](Tag.md) | | [optional]
**Status** | **string** | pet status in the store | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,616 +0,0 @@
# Org.OpenAPITools.Apis.PetApi
All URIs are relative to *http://petstore.swagger.io/v2*
Method | HTTP request | Description
------------- | ------------- | -------------
[**AddPet**](PetApi.md#addpet) | **POST** /pet | Add a new pet to the store
[**DeletePet**](PetApi.md#deletepet) | **DELETE** /pet/{petId} | Deletes a pet
[**FindPetsByStatus**](PetApi.md#findpetsbystatus) | **GET** /pet/findByStatus | Finds Pets by status
[**FindPetsByTags**](PetApi.md#findpetsbytags) | **GET** /pet/findByTags | Finds Pets by tags
[**GetPetById**](PetApi.md#getpetbyid) | **GET** /pet/{petId} | Find pet by ID
[**UpdatePet**](PetApi.md#updatepet) | **PUT** /pet | Update an existing pet
[**UpdatePetWithForm**](PetApi.md#updatepetwithform) | **POST** /pet/{petId} | Updates a pet in the store with form data
[**UploadFile**](PetApi.md#uploadfile) | **POST** /pet/{petId}/uploadImage | uploads an image
<a name="addpet"></a>
# **AddPet**
> Pet AddPet (Pet pet)
Add a new pet to the store
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class AddPetExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var pet = new Pet(); // Pet | Pet object that needs to be added to the store
try
{
// Add a new pet to the store
Pet result = apiInstance.AddPet(pet);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.AddPet: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
### Return type
[**Pet**](Pet.md)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: application/json, application/xml
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **405** | Invalid input | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="deletepet"></a>
# **DeletePet**
> void DeletePet (long petId, string apiKey = null)
Deletes a pet
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class DeletePetExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var petId = 789; // long | Pet id to delete
var apiKey = apiKey_example; // string | (optional)
try
{
// Deletes a pet
apiInstance.DeletePet(petId, apiKey);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.DeletePet: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**petId** | **long**| Pet id to delete |
**apiKey** | **string**| | [optional]
### Return type
void (empty response body)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **400** | Invalid pet value | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="findpetsbystatus"></a>
# **FindPetsByStatus**
> List&lt;Pet&gt; FindPetsByStatus (List<string> status)
Finds Pets by status
Multiple status values can be provided with comma separated strings
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class FindPetsByStatusExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var status = new List<string>(); // List<string> | Status values that need to be considered for filter
try
{
// Finds Pets by status
List<Pet> result = apiInstance.FindPetsByStatus(status);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.FindPetsByStatus: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**status** | [**List&lt;string&gt;**](string.md)| Status values that need to be considered for filter |
### Return type
[**List&lt;Pet&gt;**](Pet.md)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid status value | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="findpetsbytags"></a>
# **FindPetsByTags**
> List&lt;Pet&gt; FindPetsByTags (List<string> tags)
Finds Pets by tags
Multiple tags can be provided with comma separated strings. Use tag1, tag2, tag3 for testing.
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class FindPetsByTagsExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var tags = new List<string>(); // List<string> | Tags to filter by
try
{
// Finds Pets by tags
List<Pet> result = apiInstance.FindPetsByTags(tags);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.FindPetsByTags: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**tags** | [**List&lt;string&gt;**](string.md)| Tags to filter by |
### Return type
[**List&lt;Pet&gt;**](Pet.md)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid tag value | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="getpetbyid"></a>
# **GetPetById**
> Pet GetPetById (long petId)
Find pet by ID
Returns a single pet
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class GetPetByIdExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new PetApi(config);
var petId = 789; // long | ID of pet to return
try
{
// Find pet by ID
Pet result = apiInstance.GetPetById(petId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.GetPetById: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**petId** | **long**| ID of pet to return |
### Return type
[**Pet**](Pet.md)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid ID supplied | - |
| **404** | Pet not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="updatepet"></a>
# **UpdatePet**
> Pet UpdatePet (Pet pet)
Update an existing pet
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class UpdatePetExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var pet = new Pet(); // Pet | Pet object that needs to be added to the store
try
{
// Update an existing pet
Pet result = apiInstance.UpdatePet(pet);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.UpdatePet: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**pet** | [**Pet**](Pet.md)| Pet object that needs to be added to the store |
### Return type
[**Pet**](Pet.md)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: application/json, application/xml
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid ID supplied | - |
| **404** | Pet not found | - |
| **405** | Validation exception | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="updatepetwithform"></a>
# **UpdatePetWithForm**
> void UpdatePetWithForm (long petId, string name = null, string status = null)
Updates a pet in the store with form data
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class UpdatePetWithFormExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var petId = 789; // long | ID of pet that needs to be updated
var name = name_example; // string | Updated name of the pet (optional)
var status = status_example; // string | Updated status of the pet (optional)
try
{
// Updates a pet in the store with form data
apiInstance.UpdatePetWithForm(petId, name, status);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.UpdatePetWithForm: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**petId** | **long**| ID of pet that needs to be updated |
**name** | **string**| Updated name of the pet | [optional]
**status** | **string**| Updated status of the pet | [optional]
### Return type
void (empty response body)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: application/x-www-form-urlencoded
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **405** | Invalid input | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="uploadfile"></a>
# **UploadFile**
> ApiResponse UploadFile (long petId, string additionalMetadata = null, System.IO.Stream file = null)
uploads an image
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class UploadFileExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure OAuth2 access token for authorization: petstore_auth
config.AccessToken = "YOUR_ACCESS_TOKEN";
var apiInstance = new PetApi(config);
var petId = 789; // long | ID of pet to update
var additionalMetadata = additionalMetadata_example; // string | Additional data to pass to server (optional)
var file = BINARY_DATA_HERE; // System.IO.Stream | file to upload (optional)
try
{
// uploads an image
ApiResponse result = apiInstance.UploadFile(petId, additionalMetadata, file);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling PetApi.UploadFile: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**petId** | **long**| ID of pet to update |
**additionalMetadata** | **string**| Additional data to pass to server | [optional]
**file** | **System.IO.Stream****System.IO.Stream**| file to upload | [optional]
### Return type
[**ApiResponse**](ApiResponse.md)
### Authorization
[petstore_auth](../README.md#petstore_auth)
### HTTP request headers
- **Content-Type**: multipart/form-data
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@ -1,298 +0,0 @@
# Org.OpenAPITools.Apis.StoreApi
All URIs are relative to *http://petstore.swagger.io/v2*
Method | HTTP request | Description
------------- | ------------- | -------------
[**DeleteOrder**](StoreApi.md#deleteorder) | **DELETE** /store/order/{orderId} | Delete purchase order by ID
[**GetInventory**](StoreApi.md#getinventory) | **GET** /store/inventory | Returns pet inventories by status
[**GetOrderById**](StoreApi.md#getorderbyid) | **GET** /store/order/{orderId} | Find purchase order by ID
[**PlaceOrder**](StoreApi.md#placeorder) | **POST** /store/order | Place an order for a pet
<a name="deleteorder"></a>
# **DeleteOrder**
> void DeleteOrder (string orderId)
Delete purchase order by ID
For valid response try integer IDs with value < 1000. Anything above 1000 or nonintegers will generate API errors
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class DeleteOrderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
var apiInstance = new StoreApi(config);
var orderId = orderId_example; // string | ID of the order that needs to be deleted
try
{
// Delete purchase order by ID
apiInstance.DeleteOrder(orderId);
}
catch (ApiException e)
{
Debug.Print("Exception when calling StoreApi.DeleteOrder: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**orderId** | **string**| ID of the order that needs to be deleted |
### Return type
void (empty response body)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **400** | Invalid ID supplied | - |
| **404** | Order not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="getinventory"></a>
# **GetInventory**
> Dictionary&lt;string, int&gt; GetInventory ()
Returns pet inventories by status
Returns a map of status codes to quantities
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class GetInventoryExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new StoreApi(config);
try
{
// Returns pet inventories by status
Dictionary<string, int> result = apiInstance.GetInventory();
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling StoreApi.GetInventory: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
**Dictionary<string, int>**
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="getorderbyid"></a>
# **GetOrderById**
> Order GetOrderById (long orderId)
Find purchase order by ID
For valid response try integer IDs with value <= 5 or > 10. Other values will generated exceptions
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class GetOrderByIdExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
var apiInstance = new StoreApi(config);
var orderId = 789; // long | ID of pet that needs to be fetched
try
{
// Find purchase order by ID
Order result = apiInstance.GetOrderById(orderId);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling StoreApi.GetOrderById: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**orderId** | **long**| ID of pet that needs to be fetched |
### Return type
[**Order**](Order.md)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid ID supplied | - |
| **404** | Order not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="placeorder"></a>
# **PlaceOrder**
> Order PlaceOrder (Order order)
Place an order for a pet
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class PlaceOrderExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
var apiInstance = new StoreApi(config);
var order = new Order(); // Order | order placed for purchasing the pet
try
{
// Place an order for a pet
Order result = apiInstance.PlaceOrder(order);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling StoreApi.PlaceOrder: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**order** | [**Order**](Order.md)| order placed for purchasing the pet |
### Return type
[**Order**](Order.md)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid Order | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@ -1,12 +0,0 @@
# Org.OpenAPITools.Models.Tag
A tag for a pet
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **long** | | [optional]
**Name** | **string** | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,18 +0,0 @@
# Org.OpenAPITools.Models.User
A User who is purchasing from the pet store
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Id** | **long** | | [optional]
**Username** | **string** | | [optional]
**FirstName** | **string** | | [optional]
**LastName** | **string** | | [optional]
**Email** | **string** | | [optional]
**Password** | **string** | | [optional]
**Phone** | **string** | | [optional]
**UserStatus** | **int** | User Status | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,603 +0,0 @@
# Org.OpenAPITools.Apis.UserApi
All URIs are relative to *http://petstore.swagger.io/v2*
Method | HTTP request | Description
------------- | ------------- | -------------
[**CreateUser**](UserApi.md#createuser) | **POST** /user | Create user
[**CreateUsersWithArrayInput**](UserApi.md#createuserswitharrayinput) | **POST** /user/createWithArray | Creates list of users with given input array
[**CreateUsersWithListInput**](UserApi.md#createuserswithlistinput) | **POST** /user/createWithList | Creates list of users with given input array
[**DeleteUser**](UserApi.md#deleteuser) | **DELETE** /user/{username} | Delete user
[**GetUserByName**](UserApi.md#getuserbyname) | **GET** /user/{username} | Get user by user name
[**LoginUser**](UserApi.md#loginuser) | **GET** /user/login | Logs user into the system
[**LogoutUser**](UserApi.md#logoutuser) | **GET** /user/logout | Logs out current logged in user session
[**UpdateUser**](UserApi.md#updateuser) | **PUT** /user/{username} | Updated user
<a name="createuser"></a>
# **CreateUser**
> void CreateUser (User user)
Create user
This can only be done by the logged in user.
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class CreateUserExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
var user = new User(); // User | Created user object
try
{
// Create user
apiInstance.CreateUser(user);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.CreateUser: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**User**](User.md)| Created user object |
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **0** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="createuserswitharrayinput"></a>
# **CreateUsersWithArrayInput**
> void CreateUsersWithArrayInput (List<User> user)
Creates list of users with given input array
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class CreateUsersWithArrayInputExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
var user = new List<User>(); // List<User> | List of user object
try
{
// Creates list of users with given input array
apiInstance.CreateUsersWithArrayInput(user);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.CreateUsersWithArrayInput: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**List&lt;User&gt;**](User.md)| List of user object |
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **0** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="createuserswithlistinput"></a>
# **CreateUsersWithListInput**
> void CreateUsersWithListInput (List<User> user)
Creates list of users with given input array
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class CreateUsersWithListInputExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
var user = new List<User>(); // List<User> | List of user object
try
{
// Creates list of users with given input array
apiInstance.CreateUsersWithListInput(user);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.CreateUsersWithListInput: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**user** | [**List&lt;User&gt;**](User.md)| List of user object |
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **0** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="deleteuser"></a>
# **DeleteUser**
> void DeleteUser (string username)
Delete user
This can only be done by the logged in user.
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class DeleteUserExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
var username = username_example; // string | The name that needs to be deleted
try
{
// Delete user
apiInstance.DeleteUser(username);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.DeleteUser: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **string**| The name that needs to be deleted |
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **400** | Invalid username supplied | - |
| **404** | User not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="getuserbyname"></a>
# **GetUserByName**
> User GetUserByName (string username)
Get user by user name
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class GetUserByNameExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
var apiInstance = new UserApi(config);
var username = username_example; // string | The name that needs to be fetched. Use user1 for testing.
try
{
// Get user by user name
User result = apiInstance.GetUserByName(username);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.GetUserByName: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **string**| The name that needs to be fetched. Use user1 for testing. |
### Return type
[**User**](User.md)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | - |
| **400** | Invalid username supplied | - |
| **404** | User not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="loginuser"></a>
# **LoginUser**
> string LoginUser (string username, string password)
Logs user into the system
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class LoginUserExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
var apiInstance = new UserApi(config);
var username = username_example; // string | The user name for login
var password = password_example; // string | The password for login in clear text
try
{
// Logs user into the system
string result = apiInstance.LoginUser(username, password);
Debug.WriteLine(result);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.LoginUser: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **string**| The user name for login |
**password** | **string**| The password for login in clear text |
### Return type
**string**
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: application/xml, application/json
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **200** | successful operation | * Set-Cookie - Cookie authentication key for use with the &#x60;api_key&#x60; apiKey authentication. <br> * X-Rate-Limit - calls per hour allowed by the user <br> * X-Expires-After - date in UTC when token expires <br> |
| **400** | Invalid username/password supplied | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="logoutuser"></a>
# **LogoutUser**
> void LogoutUser ()
Logs out current logged in user session
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class LogoutUserExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
try
{
// Logs out current logged in user session
apiInstance.LogoutUser();
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.LogoutUser: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
This endpoint does not need any parameter.
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: Not defined
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **0** | successful operation | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)
<a name="updateuser"></a>
# **UpdateUser**
> void UpdateUser (string username, User user)
Updated user
This can only be done by the logged in user.
### Example
```csharp
using System.Collections.Generic;
using System.Diagnostics;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Client;
using Org.OpenAPITools.Models;
namespace Example
{
public class UpdateUserExample
{
public static void Main()
{
Configuration config = new Configuration();
config.BasePath = "http://petstore.swagger.io/v2";
// Configure API key authorization: api_key
config.AddApiKey("api_key", "YOUR_API_KEY");
// Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
// config.AddApiKeyPrefix("api_key", "Bearer");
var apiInstance = new UserApi(config);
var username = username_example; // string | name that need to be deleted
var user = new User(); // User | Updated user object
try
{
// Updated user
apiInstance.UpdateUser(username, user);
}
catch (ApiException e)
{
Debug.Print("Exception when calling UserApi.UpdateUser: " + e.Message );
Debug.Print("Status Code: "+ e.ErrorCode);
Debug.Print(e.StackTrace);
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**username** | **string**| name that need to be deleted |
**user** | [**User**](User.md)| Updated user object |
### Return type
void (empty response body)
### Authorization
[api_key](../README.md#api_key)
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: Not defined
### HTTP response details
| Status code | Description | Response headers |
|-------------|-------------|------------------|
| **400** | Invalid user supplied | - |
| **404** | User not found | - |
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@ -1,86 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing ApiResponse
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class ApiResponseTests : IDisposable
{
// TODO uncomment below to declare an instance variable for ApiResponse
//private ApiResponse instance;
public ApiResponseTests()
{
// TODO uncomment below to create an instance of ApiResponse
//instance = new ApiResponse();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of ApiResponse
/// </summary>
[Fact]
public void ApiResponseInstanceTest()
{
// TODO uncomment below to test "IsType" ApiResponse
//Assert.IsType<ApiResponse>(instance);
}
/// <summary>
/// Test the property 'Code'
/// </summary>
[Fact]
public void CodeTest()
{
// TODO unit test for the property 'Code'
}
/// <summary>
/// Test the property 'Type'
/// </summary>
[Fact]
public void TypeTest()
{
// TODO unit test for the property 'Type'
}
/// <summary>
/// Test the property 'Message'
/// </summary>
[Fact]
public void MessageTest()
{
// TODO unit test for the property 'Message'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing Category
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class CategoryTests : IDisposable
{
// TODO uncomment below to declare an instance variable for Category
//private Category instance;
public CategoryTests()
{
// TODO uncomment below to create an instance of Category
//instance = new Category();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of Category
/// </summary>
[Fact]
public void CategoryInstanceTest()
{
// TODO uncomment below to test "IsType" Category
//Assert.IsType<Category>(instance);
}
/// <summary>
/// Test the property 'Id'
/// </summary>
[Fact]
public void IdTest()
{
// TODO unit test for the property 'Id'
}
/// <summary>
/// Test the property 'Name'
/// </summary>
[Fact]
public void NameTest()
{
// TODO unit test for the property 'Name'
}
}
}

View File

@ -1,110 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing Order
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class OrderTests : IDisposable
{
// TODO uncomment below to declare an instance variable for Order
//private Order instance;
public OrderTests()
{
// TODO uncomment below to create an instance of Order
//instance = new Order();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of Order
/// </summary>
[Fact]
public void OrderInstanceTest()
{
// TODO uncomment below to test "IsType" Order
//Assert.IsType<Order>(instance);
}
/// <summary>
/// Test the property 'Id'
/// </summary>
[Fact]
public void IdTest()
{
// TODO unit test for the property 'Id'
}
/// <summary>
/// Test the property 'PetId'
/// </summary>
[Fact]
public void PetIdTest()
{
// TODO unit test for the property 'PetId'
}
/// <summary>
/// Test the property 'Quantity'
/// </summary>
[Fact]
public void QuantityTest()
{
// TODO unit test for the property 'Quantity'
}
/// <summary>
/// Test the property 'ShipDate'
/// </summary>
[Fact]
public void ShipDateTest()
{
// TODO unit test for the property 'ShipDate'
}
/// <summary>
/// Test the property 'Status'
/// </summary>
[Fact]
public void StatusTest()
{
// TODO unit test for the property 'Status'
}
/// <summary>
/// Test the property 'Complete'
/// </summary>
[Fact]
public void CompleteTest()
{
// TODO unit test for the property 'Complete'
}
}
}

View File

@ -1,110 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing Pet
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class PetTests : IDisposable
{
// TODO uncomment below to declare an instance variable for Pet
//private Pet instance;
public PetTests()
{
// TODO uncomment below to create an instance of Pet
//instance = new Pet();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of Pet
/// </summary>
[Fact]
public void PetInstanceTest()
{
// TODO uncomment below to test "IsType" Pet
//Assert.IsType<Pet>(instance);
}
/// <summary>
/// Test the property 'Id'
/// </summary>
[Fact]
public void IdTest()
{
// TODO unit test for the property 'Id'
}
/// <summary>
/// Test the property 'Category'
/// </summary>
[Fact]
public void CategoryTest()
{
// TODO unit test for the property 'Category'
}
/// <summary>
/// Test the property 'Name'
/// </summary>
[Fact]
public void NameTest()
{
// TODO unit test for the property 'Name'
}
/// <summary>
/// Test the property 'PhotoUrls'
/// </summary>
[Fact]
public void PhotoUrlsTest()
{
// TODO unit test for the property 'PhotoUrls'
}
/// <summary>
/// Test the property 'Tags'
/// </summary>
[Fact]
public void TagsTest()
{
// TODO unit test for the property 'Tags'
}
/// <summary>
/// Test the property 'Status'
/// </summary>
[Fact]
public void StatusTest()
{
// TODO unit test for the property 'Status'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing Tag
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class TagTests : IDisposable
{
// TODO uncomment below to declare an instance variable for Tag
//private Tag instance;
public TagTests()
{
// TODO uncomment below to create an instance of Tag
//instance = new Tag();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of Tag
/// </summary>
[Fact]
public void TagInstanceTest()
{
// TODO uncomment below to test "IsType" Tag
//Assert.IsType<Tag>(instance);
}
/// <summary>
/// Test the property 'Id'
/// </summary>
[Fact]
public void IdTest()
{
// TODO unit test for the property 'Id'
}
/// <summary>
/// Test the property 'Name'
/// </summary>
[Fact]
public void NameTest()
{
// TODO unit test for the property 'Name'
}
}
}

View File

@ -1,126 +0,0 @@
/*
* OpenAPI Petstore
*
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters.
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Apis;
using Org.OpenAPITools.Models;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing User
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class UserTests : IDisposable
{
// TODO uncomment below to declare an instance variable for User
//private User instance;
public UserTests()
{
// TODO uncomment below to create an instance of User
//instance = new User();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of User
/// </summary>
[Fact]
public void UserInstanceTest()
{
// TODO uncomment below to test "IsType" User
//Assert.IsType<User>(instance);
}
/// <summary>
/// Test the property 'Id'
/// </summary>
[Fact]
public void IdTest()
{
// TODO unit test for the property 'Id'
}
/// <summary>
/// Test the property 'Username'
/// </summary>
[Fact]
public void UsernameTest()
{
// TODO unit test for the property 'Username'
}
/// <summary>
/// Test the property 'FirstName'
/// </summary>
[Fact]
public void FirstNameTest()
{
// TODO unit test for the property 'FirstName'
}
/// <summary>
/// Test the property 'LastName'
/// </summary>
[Fact]
public void LastNameTest()
{
// TODO unit test for the property 'LastName'
}
/// <summary>
/// Test the property 'Email'
/// </summary>
[Fact]
public void EmailTest()
{
// TODO unit test for the property 'Email'
}
/// <summary>
/// Test the property 'Password'
/// </summary>
[Fact]
public void PasswordTest()
{
// TODO unit test for the property 'Password'
}
/// <summary>
/// Test the property 'Phone'
/// </summary>
[Fact]
public void PhoneTest()
{
// TODO unit test for the property 'Phone'
}
/// <summary>
/// Test the property 'UserStatus'
/// </summary>
[Fact]
public void UserStatusTest()
{
// TODO unit test for the property 'UserStatus'
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -62,7 +62,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//var response = instance.FooGet(); //var response = instance.FooGet();
//Assert.IsType<InlineResponseDefault>(response); //Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -1,4 +1,4 @@
using Org.OpenAPITools.Model; using Org.OpenAPITools.Model;
using System; using System;
using System.Collections.Generic; using System.Collections.Generic;
using System.Text; using System.Text;

View File

@ -1,154 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
[DataContract(Name = "inline_response_default")]
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string.</param>
public InlineResponseDefault(Foo _string = default(Foo))
{
this._String = _string;
if (this.String != null)
{
this._flagString = true;
}
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Gets or Sets String
/// </summary>
[DataMember(Name = "string", EmitDefaultValue = false)]
public Foo String
{
get{ return _String;}
set
{
_String = value;
_flagString = true;
}
}
private Foo _String;
private bool _flagString;
/// <summary>
/// Returns false as String should not be serialized given that it's read-only.
/// </summary>
/// <returns>false (boolean)</returns>
public bool ShouldSerializeString()
{
return _flagString;
}
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../../README.md#documentation-for-models) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to README]](../../README.md)

View File

@ -58,7 +58,7 @@ namespace Org.OpenAPITools.Test.Api
public async Task FooGetAsyncTest() public async Task FooGetAsyncTest()
{ {
var response = await _instance.FooGetAsync(); var response = await _instance.FooGetAsync();
Assert.IsType<InlineResponseDefault>(response); Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -1,121 +0,0 @@
// <auto-generated>
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
#nullable enable
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.ComponentModel.DataAnnotations;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string</param>
public InlineResponseDefault(Foo? _string = default)
{
String = _string;
}
/// <summary>
/// Gets or Sets String
/// </summary>
[JsonPropertyName("string")]
public Foo? String { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public Dictionary<string, JsonElement> AdditionalProperties { get; set; } = new Dictionary<string, JsonElement>();
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object? input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault? input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../../README.md#documentation-for-models) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to README]](../../README.md)

View File

@ -58,7 +58,7 @@ namespace Org.OpenAPITools.Test.Api
public async Task FooGetAsyncTest() public async Task FooGetAsyncTest()
{ {
var response = await _instance.FooGetAsync(); var response = await _instance.FooGetAsync();
Assert.IsType<InlineResponseDefault>(response); Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -1,119 +0,0 @@
// <auto-generated>
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.ComponentModel.DataAnnotations;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string</param>
public InlineResponseDefault(Foo _string = default)
{
String = _string;
}
/// <summary>
/// Gets or Sets String
/// </summary>
[JsonPropertyName("string")]
public Foo String { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public Dictionary<string, JsonElement> AdditionalProperties { get; set; } = new Dictionary<string, JsonElement>();
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../../README.md#documentation-for-models) [[Back to API list]](../../README.md#documentation-for-api-endpoints) [[Back to README]](../../README.md)

View File

@ -58,7 +58,7 @@ namespace Org.OpenAPITools.Test.Api
public async Task FooGetAsyncTest() public async Task FooGetAsyncTest()
{ {
var response = await _instance.FooGetAsync(); var response = await _instance.FooGetAsync();
Assert.IsType<InlineResponseDefault>(response); Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -1,119 +0,0 @@
// <auto-generated>
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using System.Text.Json;
using System.Text.Json.Serialization;
using System.ComponentModel.DataAnnotations;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string</param>
public InlineResponseDefault(Foo _string = default)
{
String = _string;
}
/// <summary>
/// Gets or Sets String
/// </summary>
[JsonPropertyName("string")]
public Foo String { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public Dictionary<string, JsonElement> AdditionalProperties { get; set; } = new Dictionary<string, JsonElement>();
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -61,7 +61,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//var response = instance.FooGet(); //var response = instance.FooGet();
//Assert.IsType<InlineResponseDefault>(response); //Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -174,7 +174,7 @@ namespace Org.OpenAPITools.Test.Api
//long? int64 = null; //long? int64 = null;
//float? _float = null; //float? _float = null;
//string _string = null; //string _string = null;
//System.IO.Stream binary = null; //FileParameter binary = null;
//DateTime? date = null; //DateTime? date = null;
//DateTime? dateTime = null; //DateTime? dateTime = null;
//string password = null; //string password = null;

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -81,6 +81,14 @@ namespace Org.OpenAPITools.Test.Model
// TODO unit test for the property 'EnumInteger' // TODO unit test for the property 'EnumInteger'
} }
/// <summary> /// <summary>
/// Test the property 'EnumIntegerOnly'
/// </summary>
[Fact]
public void EnumIntegerOnlyTest()
{
// TODO unit test for the property 'EnumIntegerOnly'
}
/// <summary>
/// Test the property 'EnumNumber' /// Test the property 'EnumNumber'
/// </summary> /// </summary>
[Fact] [Fact]

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -57,12 +57,12 @@ namespace Org.OpenAPITools.Test.Model
/// <summary> /// <summary>
/// Test the property '__Client' /// Test the property '_Client'
/// </summary> /// </summary>
[Fact] [Fact]
public void __ClientTest() public void _ClientTest()
{ {
// TODO unit test for the property '__Client' // TODO unit test for the property '_Client'
} }
} }

View File

@ -64,6 +64,14 @@ namespace Org.OpenAPITools.Test.Model
{ {
// TODO unit test for the property 'SpecialPropertyName' // TODO unit test for the property 'SpecialPropertyName'
} }
/// <summary>
/// Test the property '_SpecialModelName'
/// </summary>
[Fact]
public void _SpecialModelNameTest()
{
// TODO unit test for the property '_SpecialModelName'
}
} }

View File

@ -1,133 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using FileParameter = Org.OpenAPITools.Client.FileParameter;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
[DataContract(Name = "inline_response_default")]
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string.</param>
public InlineResponseDefault(Foo _string = default(Foo))
{
this.String = _string;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Gets or Sets String
/// </summary>
[DataMember(Name = "string", EmitDefaultValue = false)]
public Foo String { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Name** | **string** | Updated name of the pet | [optional]
**Status** | **string** | Updated status of the pet | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject1
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**AdditionalMetadata** | **string** | Additional data to pass to server | [optional]
**File** | **System.IO.Stream** | file to upload | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject2
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**EnumFormStringArray** | **List&lt;string&gt;** | Form parameter enum test (string array) | [optional]
**EnumFormString** | **string** | Form parameter enum test (string) | [optional] [default to EnumFormStringEnum.Efg]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,22 +0,0 @@
# Org.OpenAPITools.Model.InlineObject3
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Integer** | **int** | None | [optional]
**Int32** | **int** | None | [optional]
**Int64** | **long** | None | [optional]
**Number** | **decimal** | None |
**Float** | **float** | None | [optional]
**Double** | **double** | None |
**String** | **string** | None | [optional]
**PatternWithoutDelimiter** | **string** | None |
**Byte** | **byte[]** | None |
**Binary** | **System.IO.Stream** | None | [optional]
**Date** | **DateTime** | None | [optional]
**DateTime** | **DateTime** | None | [optional] [default to "2010-02-01T10:20:10.111110+01:00"]
**Password** | **string** | None | [optional]
**Callback** | **string** | None | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject4
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Param** | **string** | field1 |
**Param2** | **string** | field2 |
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineObject5
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**AdditionalMetadata** | **string** | Additional data to pass to server | [optional]
**RequiredFile** | **System.IO.Stream** | file to upload |
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -62,7 +62,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//var response = instance.FooGet(); //var response = instance.FooGet();
//Assert.IsType<InlineResponseDefault>(response); //Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<Animal>(instance); //Assert.IsType<Animal>(instance);
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a Cat from type Animal /// Test deserialize a Cat from type Animal
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a Cat from type Animal // TODO uncomment below to test deserialize a Cat from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson())); //Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Cat().ToJson()));
} }
/// <summary>
/// Test deserialize a Dog from type Animal
/// </summary>
[Fact]
public void DogDeserializeFromAnimalTest()
{
// TODO uncomment below to test deserialize a Dog from type Animal
//Assert.IsType<Animal>(JsonConvert.DeserializeObject<Animal>(new Dog().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'ClassName' /// Test the property 'ClassName'

View File

@ -81,6 +81,14 @@ namespace Org.OpenAPITools.Test.Model
// TODO unit test for the property 'EnumInteger' // TODO unit test for the property 'EnumInteger'
} }
/// <summary> /// <summary>
/// Test the property 'EnumIntegerOnly'
/// </summary>
[Fact]
public void EnumIntegerOnlyTest()
{
// TODO unit test for the property 'EnumIntegerOnly'
}
/// <summary>
/// Test the property 'EnumNumber' /// Test the property 'EnumNumber'
/// </summary> /// </summary>
[Fact] [Fact]

View File

@ -105,6 +105,14 @@ namespace Org.OpenAPITools.Test.Model
// TODO unit test for the property 'Double' // TODO unit test for the property 'Double'
} }
/// <summary> /// <summary>
/// Test the property 'Decimal'
/// </summary>
[Fact]
public void DecimalTest()
{
// TODO unit test for the property 'Decimal'
}
/// <summary>
/// Test the property 'String' /// Test the property 'String'
/// </summary> /// </summary>
[Fact] [Fact]

View File

@ -55,15 +55,6 @@ namespace Org.OpenAPITools.Test.Model
//Assert.IsType<GrandparentAnimal>(instance); //Assert.IsType<GrandparentAnimal>(instance);
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test deserialize a ChildCat from type ParentPet /// Test deserialize a ChildCat from type ParentPet
/// </summary> /// </summary>
@ -73,6 +64,15 @@ namespace Org.OpenAPITools.Test.Model
// TODO uncomment below to test deserialize a ChildCat from type ParentPet // TODO uncomment below to test deserialize a ChildCat from type ParentPet
//Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson())); //Assert.IsType<ParentPet>(JsonConvert.DeserializeObject<ParentPet>(new ChildCat().ToJson()));
} }
/// <summary>
/// Test deserialize a ParentPet from type GrandparentAnimal
/// </summary>
[Fact]
public void ParentPetDeserializeFromGrandparentAnimalTest()
{
// TODO uncomment below to test deserialize a ParentPet from type GrandparentAnimal
//Assert.IsType<GrandparentAnimal>(JsonConvert.DeserializeObject<GrandparentAnimal>(new ParentPet().ToJson()));
}
/// <summary> /// <summary>
/// Test the property 'PetType' /// Test the property 'PetType'

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject1
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject1Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject1
//private InlineObject1 instance;
public InlineObject1Tests()
{
// TODO uncomment below to create an instance of InlineObject1
//instance = new InlineObject1();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject1
/// </summary>
[Fact]
public void InlineObject1InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject1
//Assert.IsType<InlineObject1>(instance);
}
/// <summary>
/// Test the property 'AdditionalMetadata'
/// </summary>
[Fact]
public void AdditionalMetadataTest()
{
// TODO unit test for the property 'AdditionalMetadata'
}
/// <summary>
/// Test the property 'File'
/// </summary>
[Fact]
public void FileTest()
{
// TODO unit test for the property 'File'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject2
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject2Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject2
//private InlineObject2 instance;
public InlineObject2Tests()
{
// TODO uncomment below to create an instance of InlineObject2
//instance = new InlineObject2();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject2
/// </summary>
[Fact]
public void InlineObject2InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject2
//Assert.IsType<InlineObject2>(instance);
}
/// <summary>
/// Test the property 'EnumFormStringArray'
/// </summary>
[Fact]
public void EnumFormStringArrayTest()
{
// TODO unit test for the property 'EnumFormStringArray'
}
/// <summary>
/// Test the property 'EnumFormString'
/// </summary>
[Fact]
public void EnumFormStringTest()
{
// TODO unit test for the property 'EnumFormString'
}
}
}

View File

@ -1,174 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject3
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject3Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject3
//private InlineObject3 instance;
public InlineObject3Tests()
{
// TODO uncomment below to create an instance of InlineObject3
//instance = new InlineObject3();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject3
/// </summary>
[Fact]
public void InlineObject3InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject3
//Assert.IsType<InlineObject3>(instance);
}
/// <summary>
/// Test the property 'Integer'
/// </summary>
[Fact]
public void IntegerTest()
{
// TODO unit test for the property 'Integer'
}
/// <summary>
/// Test the property 'Int32'
/// </summary>
[Fact]
public void Int32Test()
{
// TODO unit test for the property 'Int32'
}
/// <summary>
/// Test the property 'Int64'
/// </summary>
[Fact]
public void Int64Test()
{
// TODO unit test for the property 'Int64'
}
/// <summary>
/// Test the property 'Number'
/// </summary>
[Fact]
public void NumberTest()
{
// TODO unit test for the property 'Number'
}
/// <summary>
/// Test the property 'Float'
/// </summary>
[Fact]
public void FloatTest()
{
// TODO unit test for the property 'Float'
}
/// <summary>
/// Test the property 'Double'
/// </summary>
[Fact]
public void DoubleTest()
{
// TODO unit test for the property 'Double'
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
/// <summary>
/// Test the property 'PatternWithoutDelimiter'
/// </summary>
[Fact]
public void PatternWithoutDelimiterTest()
{
// TODO unit test for the property 'PatternWithoutDelimiter'
}
/// <summary>
/// Test the property 'Byte'
/// </summary>
[Fact]
public void ByteTest()
{
// TODO unit test for the property 'Byte'
}
/// <summary>
/// Test the property 'Binary'
/// </summary>
[Fact]
public void BinaryTest()
{
// TODO unit test for the property 'Binary'
}
/// <summary>
/// Test the property 'Date'
/// </summary>
[Fact]
public void DateTest()
{
// TODO unit test for the property 'Date'
}
/// <summary>
/// Test the property 'DateTime'
/// </summary>
[Fact]
public void DateTimeTest()
{
// TODO unit test for the property 'DateTime'
}
/// <summary>
/// Test the property 'Password'
/// </summary>
[Fact]
public void PasswordTest()
{
// TODO unit test for the property 'Password'
}
/// <summary>
/// Test the property 'Callback'
/// </summary>
[Fact]
public void CallbackTest()
{
// TODO unit test for the property 'Callback'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject4
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject4Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject4
//private InlineObject4 instance;
public InlineObject4Tests()
{
// TODO uncomment below to create an instance of InlineObject4
//instance = new InlineObject4();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject4
/// </summary>
[Fact]
public void InlineObject4InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject4
//Assert.IsType<InlineObject4>(instance);
}
/// <summary>
/// Test the property 'Param'
/// </summary>
[Fact]
public void ParamTest()
{
// TODO unit test for the property 'Param'
}
/// <summary>
/// Test the property 'Param2'
/// </summary>
[Fact]
public void Param2Test()
{
// TODO unit test for the property 'Param2'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject5
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObject5Tests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject5
//private InlineObject5 instance;
public InlineObject5Tests()
{
// TODO uncomment below to create an instance of InlineObject5
//instance = new InlineObject5();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject5
/// </summary>
[Fact]
public void InlineObject5InstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject5
//Assert.IsType<InlineObject5>(instance);
}
/// <summary>
/// Test the property 'AdditionalMetadata'
/// </summary>
[Fact]
public void AdditionalMetadataTest()
{
// TODO unit test for the property 'AdditionalMetadata'
}
/// <summary>
/// Test the property 'RequiredFile'
/// </summary>
[Fact]
public void RequiredFileTest()
{
// TODO unit test for the property 'RequiredFile'
}
}
}

View File

@ -1,78 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineObject
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineObjectTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineObject
//private InlineObject instance;
public InlineObjectTests()
{
// TODO uncomment below to create an instance of InlineObject
//instance = new InlineObject();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineObject
/// </summary>
[Fact]
public void InlineObjectInstanceTest()
{
// TODO uncomment below to test "IsType" InlineObject
//Assert.IsType<InlineObject>(instance);
}
/// <summary>
/// Test the property 'Name'
/// </summary>
[Fact]
public void NameTest()
{
// TODO unit test for the property 'Name'
}
/// <summary>
/// Test the property 'Status'
/// </summary>
[Fact]
public void StatusTest()
{
// TODO unit test for the property 'Status'
}
}
}

View File

@ -1,70 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using Xunit;
using System;
using System.Linq;
using System.IO;
using System.Collections.Generic;
using Org.OpenAPITools.Api;
using Org.OpenAPITools.Model;
using Org.OpenAPITools.Client;
using System.Reflection;
using Newtonsoft.Json;
namespace Org.OpenAPITools.Test.Model
{
/// <summary>
/// Class for testing InlineResponseDefault
/// </summary>
/// <remarks>
/// This file is automatically generated by OpenAPI Generator (https://openapi-generator.tech).
/// Please update the test case below to test the model.
/// </remarks>
public class InlineResponseDefaultTests : IDisposable
{
// TODO uncomment below to declare an instance variable for InlineResponseDefault
//private InlineResponseDefault instance;
public InlineResponseDefaultTests()
{
// TODO uncomment below to create an instance of InlineResponseDefault
//instance = new InlineResponseDefault();
}
public void Dispose()
{
// Cleanup when everything is done.
}
/// <summary>
/// Test an instance of InlineResponseDefault
/// </summary>
[Fact]
public void InlineResponseDefaultInstanceTest()
{
// TODO uncomment below to test "IsType" InlineResponseDefault
//Assert.IsType<InlineResponseDefault>(instance);
}
/// <summary>
/// Test the property 'String'
/// </summary>
[Fact]
public void StringTest()
{
// TODO unit test for the property 'String'
}
}
}

View File

@ -57,12 +57,12 @@ namespace Org.OpenAPITools.Test.Model
/// <summary> /// <summary>
/// Test the property '__Client' /// Test the property '_Client'
/// </summary> /// </summary>
[Fact] [Fact]
public void __ClientTest() public void _ClientTest()
{ {
// TODO unit test for the property '__Client' // TODO unit test for the property '_Client'
} }
} }

View File

@ -64,6 +64,14 @@ namespace Org.OpenAPITools.Test.Model
{ {
// TODO unit test for the property 'SpecialPropertyName' // TODO unit test for the property 'SpecialPropertyName'
} }
/// <summary>
/// Test the property '_SpecialModelName'
/// </summary>
[Fact]
public void _SpecialModelNameTest()
{
// TODO unit test for the property '_SpecialModelName'
}
} }

View File

@ -1,141 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject
/// </summary>
[DataContract(Name = "inline_object")]
public partial class InlineObject : IEquatable<InlineObject>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject" /> class.
/// </summary>
/// <param name="name">Updated name of the pet.</param>
/// <param name="status">Updated status of the pet.</param>
public InlineObject(string name = default(string), string status = default(string))
{
this.Name = name;
this.Status = status;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Updated name of the pet
/// </summary>
/// <value>Updated name of the pet</value>
[DataMember(Name = "name", EmitDefaultValue = false)]
public string Name { get; set; }
/// <summary>
/// Updated status of the pet
/// </summary>
/// <value>Updated status of the pet</value>
[DataMember(Name = "status", EmitDefaultValue = false)]
public string Status { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject {\n");
sb.Append(" Name: ").Append(Name).Append("\n");
sb.Append(" Status: ").Append(Status).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject).AreEqual;
}
/// <summary>
/// Returns true if InlineObject instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.Name != null)
hashCode = hashCode * 59 + this.Name.GetHashCode();
if (this.Status != null)
hashCode = hashCode * 59 + this.Status.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,141 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject1
/// </summary>
[DataContract(Name = "inline_object_1")]
public partial class InlineObject1 : IEquatable<InlineObject1>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject1" /> class.
/// </summary>
/// <param name="additionalMetadata">Additional data to pass to server.</param>
/// <param name="file">file to upload.</param>
public InlineObject1(string additionalMetadata = default(string), System.IO.Stream file = default(System.IO.Stream))
{
this.AdditionalMetadata = additionalMetadata;
this.File = file;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Additional data to pass to server
/// </summary>
/// <value>Additional data to pass to server</value>
[DataMember(Name = "additionalMetadata", EmitDefaultValue = false)]
public string AdditionalMetadata { get; set; }
/// <summary>
/// file to upload
/// </summary>
/// <value>file to upload</value>
[DataMember(Name = "file", EmitDefaultValue = false)]
public System.IO.Stream File { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject1 {\n");
sb.Append(" AdditionalMetadata: ").Append(AdditionalMetadata).Append("\n");
sb.Append(" File: ").Append(File).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject1).AreEqual;
}
/// <summary>
/// Returns true if InlineObject1 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject1 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject1 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.AdditionalMetadata != null)
hashCode = hashCode * 59 + this.AdditionalMetadata.GetHashCode();
if (this.File != null)
hashCode = hashCode * 59 + this.File.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,185 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject2
/// </summary>
[DataContract(Name = "inline_object_2")]
public partial class InlineObject2 : IEquatable<InlineObject2>, IValidatableObject
{
/// <summary>
/// Defines EnumFormStringArray
/// </summary>
[JsonConverter(typeof(StringEnumConverter))]
public enum EnumFormStringArrayEnum
{
/// <summary>
/// Enum GreaterThan for value: >
/// </summary>
[EnumMember(Value = ">")]
GreaterThan = 1,
/// <summary>
/// Enum Dollar for value: $
/// </summary>
[EnumMember(Value = "$")]
Dollar = 2
}
/// <summary>
/// Form parameter enum test (string array)
/// </summary>
/// <value>Form parameter enum test (string array)</value>
[DataMember(Name = "enum_form_string_array", EmitDefaultValue = false)]
public List<EnumFormStringArrayEnum> EnumFormStringArray { get; set; }
/// <summary>
/// Form parameter enum test (string)
/// </summary>
/// <value>Form parameter enum test (string)</value>
[JsonConverter(typeof(StringEnumConverter))]
public enum EnumFormStringEnum
{
/// <summary>
/// Enum Abc for value: _abc
/// </summary>
[EnumMember(Value = "_abc")]
Abc = 1,
/// <summary>
/// Enum Efg for value: -efg
/// </summary>
[EnumMember(Value = "-efg")]
Efg = 2,
/// <summary>
/// Enum Xyz for value: (xyz)
/// </summary>
[EnumMember(Value = "(xyz)")]
Xyz = 3
}
/// <summary>
/// Form parameter enum test (string)
/// </summary>
/// <value>Form parameter enum test (string)</value>
[DataMember(Name = "enum_form_string", EmitDefaultValue = false)]
public EnumFormStringEnum? EnumFormString { get; set; }
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject2" /> class.
/// </summary>
/// <param name="enumFormStringArray">Form parameter enum test (string array).</param>
/// <param name="enumFormString">Form parameter enum test (string) (default to EnumFormStringEnum.Efg).</param>
public InlineObject2(List<EnumFormStringArrayEnum> enumFormStringArray = default(List<EnumFormStringArrayEnum>), EnumFormStringEnum? enumFormString = EnumFormStringEnum.Efg)
{
this.EnumFormStringArray = enumFormStringArray;
this.EnumFormString = enumFormString;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject2 {\n");
sb.Append(" EnumFormStringArray: ").Append(EnumFormStringArray).Append("\n");
sb.Append(" EnumFormString: ").Append(EnumFormString).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject2).AreEqual;
}
/// <summary>
/// Returns true if InlineObject2 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject2 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject2 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
hashCode = hashCode * 59 + this.EnumFormStringArray.GetHashCode();
hashCode = hashCode * 59 + this.EnumFormString.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,370 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject3
/// </summary>
[DataContract(Name = "inline_object_3")]
public partial class InlineObject3 : IEquatable<InlineObject3>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject3" /> class.
/// </summary>
[JsonConstructorAttribute]
protected InlineObject3()
{
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject3" /> class.
/// </summary>
/// <param name="integer">None.</param>
/// <param name="int32">None.</param>
/// <param name="int64">None.</param>
/// <param name="number">None (required).</param>
/// <param name="_float">None.</param>
/// <param name="_double">None (required).</param>
/// <param name="_string">None.</param>
/// <param name="patternWithoutDelimiter">None (required).</param>
/// <param name="_byte">None (required).</param>
/// <param name="binary">None.</param>
/// <param name="date">None.</param>
/// <param name="dateTime">None (default to &quot;2010-02-01T10:20:10.111110+01:00&quot;).</param>
/// <param name="password">None.</param>
/// <param name="callback">None.</param>
public InlineObject3(int integer = default(int), int int32 = default(int), long int64 = default(long), decimal number = default(decimal), float _float = default(float), double _double = default(double), string _string = default(string), string patternWithoutDelimiter = default(string), byte[] _byte = default(byte[]), System.IO.Stream binary = default(System.IO.Stream), DateTime date = default(DateTime), DateTime dateTime = default(DateTime), string password = default(string), string callback = default(string))
{
this.Number = number;
this.Double = _double;
// to ensure "patternWithoutDelimiter" is required (not null)
this.PatternWithoutDelimiter = patternWithoutDelimiter ?? throw new ArgumentNullException("patternWithoutDelimiter is a required property for InlineObject3 and cannot be null");
// to ensure "_byte" is required (not null)
this.Byte = _byte ?? throw new ArgumentNullException("_byte is a required property for InlineObject3 and cannot be null");
this.Integer = integer;
this.Int32 = int32;
this.Int64 = int64;
this.Float = _float;
this.String = _string;
this.Binary = binary;
this.Date = date;
this.DateTime = dateTime;
this.Password = password;
this.Callback = callback;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "integer", EmitDefaultValue = false)]
public int Integer { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "int32", EmitDefaultValue = false)]
public int Int32 { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "int64", EmitDefaultValue = false)]
public long Int64 { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "number", IsRequired = true, EmitDefaultValue = false)]
public decimal Number { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "float", EmitDefaultValue = false)]
public float Float { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "double", IsRequired = true, EmitDefaultValue = false)]
public double Double { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "string", EmitDefaultValue = false)]
public string String { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "pattern_without_delimiter", IsRequired = true, EmitDefaultValue = false)]
public string PatternWithoutDelimiter { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "byte", IsRequired = true, EmitDefaultValue = false)]
public byte[] Byte { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "binary", EmitDefaultValue = false)]
public System.IO.Stream Binary { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "date", EmitDefaultValue = false)]
[JsonConverter(typeof(OpenAPIDateConverter))]
public DateTime Date { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "dateTime", EmitDefaultValue = false)]
public DateTime DateTime { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "password", EmitDefaultValue = false)]
public string Password { get; set; }
/// <summary>
/// None
/// </summary>
/// <value>None</value>
[DataMember(Name = "callback", EmitDefaultValue = false)]
public string Callback { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject3 {\n");
sb.Append(" Integer: ").Append(Integer).Append("\n");
sb.Append(" Int32: ").Append(Int32).Append("\n");
sb.Append(" Int64: ").Append(Int64).Append("\n");
sb.Append(" Number: ").Append(Number).Append("\n");
sb.Append(" Float: ").Append(Float).Append("\n");
sb.Append(" Double: ").Append(Double).Append("\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" PatternWithoutDelimiter: ").Append(PatternWithoutDelimiter).Append("\n");
sb.Append(" Byte: ").Append(Byte).Append("\n");
sb.Append(" Binary: ").Append(Binary).Append("\n");
sb.Append(" Date: ").Append(Date).Append("\n");
sb.Append(" DateTime: ").Append(DateTime).Append("\n");
sb.Append(" Password: ").Append(Password).Append("\n");
sb.Append(" Callback: ").Append(Callback).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject3).AreEqual;
}
/// <summary>
/// Returns true if InlineObject3 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject3 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject3 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
hashCode = hashCode * 59 + this.Integer.GetHashCode();
hashCode = hashCode * 59 + this.Int32.GetHashCode();
hashCode = hashCode * 59 + this.Int64.GetHashCode();
hashCode = hashCode * 59 + this.Number.GetHashCode();
hashCode = hashCode * 59 + this.Float.GetHashCode();
hashCode = hashCode * 59 + this.Double.GetHashCode();
if (this.String != null)
hashCode = hashCode * 59 + this.String.GetHashCode();
if (this.PatternWithoutDelimiter != null)
hashCode = hashCode * 59 + this.PatternWithoutDelimiter.GetHashCode();
if (this.Byte != null)
hashCode = hashCode * 59 + this.Byte.GetHashCode();
if (this.Binary != null)
hashCode = hashCode * 59 + this.Binary.GetHashCode();
if (this.Date != null)
hashCode = hashCode * 59 + this.Date.GetHashCode();
if (this.DateTime != null)
hashCode = hashCode * 59 + this.DateTime.GetHashCode();
if (this.Password != null)
hashCode = hashCode * 59 + this.Password.GetHashCode();
if (this.Callback != null)
hashCode = hashCode * 59 + this.Callback.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
// Integer (int) maximum
if(this.Integer > (int)100)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value less than or equal to 100.", new [] { "Integer" });
}
// Integer (int) minimum
if(this.Integer < (int)10)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Integer, must be a value greater than or equal to 10.", new [] { "Integer" });
}
// Int32 (int) maximum
if(this.Int32 > (int)200)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value less than or equal to 200.", new [] { "Int32" });
}
// Int32 (int) minimum
if(this.Int32 < (int)20)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Int32, must be a value greater than or equal to 20.", new [] { "Int32" });
}
// Number (decimal) maximum
if(this.Number > (decimal)543.2)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value less than or equal to 543.2.", new [] { "Number" });
}
// Number (decimal) minimum
if(this.Number < (decimal)32.1)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Number, must be a value greater than or equal to 32.1.", new [] { "Number" });
}
// Float (float) maximum
if(this.Float > (float)987.6)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Float, must be a value less than or equal to 987.6.", new [] { "Float" });
}
// Double (double) maximum
if(this.Double > (double)123.4)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value less than or equal to 123.4.", new [] { "Double" });
}
// Double (double) minimum
if(this.Double < (double)67.8)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Double, must be a value greater than or equal to 67.8.", new [] { "Double" });
}
// String (string) pattern
Regex regexString = new Regex(@"[a-z]", RegexOptions.CultureInvariant | RegexOptions.IgnoreCase);
if (false == regexString.Match(this.String).Success)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for String, must match a pattern of " + regexString, new [] { "String" });
}
// PatternWithoutDelimiter (string) pattern
Regex regexPatternWithoutDelimiter = new Regex(@"^[A-Z].*", RegexOptions.CultureInvariant);
if (false == regexPatternWithoutDelimiter.Match(this.PatternWithoutDelimiter).Success)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for PatternWithoutDelimiter, must match a pattern of " + regexPatternWithoutDelimiter, new [] { "PatternWithoutDelimiter" });
}
// Password (string) maxLength
if(this.Password != null && this.Password.Length > 64)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be less than 64.", new [] { "Password" });
}
// Password (string) minLength
if(this.Password != null && this.Password.Length < 10)
{
yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for Password, length must be greater than 10.", new [] { "Password" });
}
yield break;
}
}
}

View File

@ -1,151 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject4
/// </summary>
[DataContract(Name = "inline_object_4")]
public partial class InlineObject4 : IEquatable<InlineObject4>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject4" /> class.
/// </summary>
[JsonConstructorAttribute]
protected InlineObject4()
{
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject4" /> class.
/// </summary>
/// <param name="param">field1 (required).</param>
/// <param name="param2">field2 (required).</param>
public InlineObject4(string param = default(string), string param2 = default(string))
{
// to ensure "param" is required (not null)
this.Param = param ?? throw new ArgumentNullException("param is a required property for InlineObject4 and cannot be null");
// to ensure "param2" is required (not null)
this.Param2 = param2 ?? throw new ArgumentNullException("param2 is a required property for InlineObject4 and cannot be null");
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// field1
/// </summary>
/// <value>field1</value>
[DataMember(Name = "param", IsRequired = true, EmitDefaultValue = false)]
public string Param { get; set; }
/// <summary>
/// field2
/// </summary>
/// <value>field2</value>
[DataMember(Name = "param2", IsRequired = true, EmitDefaultValue = false)]
public string Param2 { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject4 {\n");
sb.Append(" Param: ").Append(Param).Append("\n");
sb.Append(" Param2: ").Append(Param2).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject4).AreEqual;
}
/// <summary>
/// Returns true if InlineObject4 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject4 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject4 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.Param != null)
hashCode = hashCode * 59 + this.Param.GetHashCode();
if (this.Param2 != null)
hashCode = hashCode * 59 + this.Param2.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,150 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineObject5
/// </summary>
[DataContract(Name = "inline_object_5")]
public partial class InlineObject5 : IEquatable<InlineObject5>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject5" /> class.
/// </summary>
[JsonConstructorAttribute]
protected InlineObject5()
{
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Initializes a new instance of the <see cref="InlineObject5" /> class.
/// </summary>
/// <param name="additionalMetadata">Additional data to pass to server.</param>
/// <param name="requiredFile">file to upload (required).</param>
public InlineObject5(string additionalMetadata = default(string), System.IO.Stream requiredFile = default(System.IO.Stream))
{
// to ensure "requiredFile" is required (not null)
this.RequiredFile = requiredFile ?? throw new ArgumentNullException("requiredFile is a required property for InlineObject5 and cannot be null");
this.AdditionalMetadata = additionalMetadata;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Additional data to pass to server
/// </summary>
/// <value>Additional data to pass to server</value>
[DataMember(Name = "additionalMetadata", EmitDefaultValue = false)]
public string AdditionalMetadata { get; set; }
/// <summary>
/// file to upload
/// </summary>
/// <value>file to upload</value>
[DataMember(Name = "requiredFile", IsRequired = true, EmitDefaultValue = false)]
public System.IO.Stream RequiredFile { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
var sb = new StringBuilder();
sb.Append("class InlineObject5 {\n");
sb.Append(" AdditionalMetadata: ").Append(AdditionalMetadata).Append("\n");
sb.Append(" RequiredFile: ").Append(RequiredFile).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineObject5).AreEqual;
}
/// <summary>
/// Returns true if InlineObject5 instances are equal
/// </summary>
/// <param name="input">Instance of InlineObject5 to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineObject5 input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.AdditionalMetadata != null)
hashCode = hashCode * 59 + this.AdditionalMetadata.GetHashCode();
if (this.RequiredFile != null)
hashCode = hashCode * 59 + this.RequiredFile.GetHashCode();
if (this.AdditionalProperties != null)
hashCode = hashCode * 59 + this.AdditionalProperties.GetHashCode();
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> IValidatableObject.Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,132 +0,0 @@
/*
* OpenAPI Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git
*/
using System;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using System.IO;
using System.Runtime.Serialization;
using System.Text;
using System.Text.RegularExpressions;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using Newtonsoft.Json.Linq;
using System.ComponentModel.DataAnnotations;
using OpenAPIDateConverter = Org.OpenAPITools.Client.OpenAPIDateConverter;
using OpenAPIClientUtils = Org.OpenAPITools.Client.ClientUtils;
namespace Org.OpenAPITools.Model
{
/// <summary>
/// InlineResponseDefault
/// </summary>
[DataContract(Name = "inline_response_default")]
public partial class InlineResponseDefault : IEquatable<InlineResponseDefault>, IValidatableObject
{
/// <summary>
/// Initializes a new instance of the <see cref="InlineResponseDefault" /> class.
/// </summary>
/// <param name="_string">_string.</param>
public InlineResponseDefault(Foo _string = default(Foo))
{
this.String = _string;
this.AdditionalProperties = new Dictionary<string, object>();
}
/// <summary>
/// Gets or Sets String
/// </summary>
[DataMember(Name = "string", EmitDefaultValue = false)]
public Foo String { get; set; }
/// <summary>
/// Gets or Sets additional properties
/// </summary>
[JsonExtensionData]
public IDictionary<string, object> AdditionalProperties { get; set; }
/// <summary>
/// Returns the string presentation of the object
/// </summary>
/// <returns>String presentation of the object</returns>
public override string ToString()
{
StringBuilder sb = new StringBuilder();
sb.Append("class InlineResponseDefault {\n");
sb.Append(" String: ").Append(String).Append("\n");
sb.Append(" AdditionalProperties: ").Append(AdditionalProperties).Append("\n");
sb.Append("}\n");
return sb.ToString();
}
/// <summary>
/// Returns the JSON string presentation of the object
/// </summary>
/// <returns>JSON string presentation of the object</returns>
public virtual string ToJson()
{
return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="input">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input as InlineResponseDefault).AreEqual;
}
/// <summary>
/// Returns true if InlineResponseDefault instances are equal
/// </summary>
/// <param name="input">Instance of InlineResponseDefault to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(InlineResponseDefault input)
{
return OpenAPIClientUtils.compareLogic.Compare(this, input).AreEqual;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
unchecked // Overflow is fine, just wrap
{
int hashCode = 41;
if (this.String != null)
{
hashCode = (hashCode * 59) + this.String.GetHashCode();
}
if (this.AdditionalProperties != null)
{
hashCode = (hashCode * 59) + this.AdditionalProperties.GetHashCode();
}
return hashCode;
}
}
/// <summary>
/// To validate all properties of the instance
/// </summary>
/// <param name="validationContext">Validation context</param>
/// <returns>Validation Result</returns>
public IEnumerable<System.ComponentModel.DataAnnotations.ValidationResult> Validate(ValidationContext validationContext)
{
yield break;
}
}
}

View File

@ -1,10 +0,0 @@
# Org.OpenAPITools.Model.InlineResponseDefault
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**String** | [**Foo**](Foo.md) | | [optional]
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -62,7 +62,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//var response = instance.FooGet(); //var response = instance.FooGet();
//Assert.IsType<InlineResponseDefault>(response); //Assert.IsType<FooGetDefaultResponse>(response);
} }
} }
} }

View File

@ -1,7 +1,7 @@
/* /*
* OpenAPI Petstore * OpenAPI Petstore
* *
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
* *
* The version of the OpenAPI document: 1.0.0 * The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git * Generated by: https://github.com/openapitools/openapi-generator.git
@ -62,8 +62,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//Pet pet = null; //Pet pet = null;
//var response = instance.AddPet(pet); //instance.AddPet(pet);
//Assert.IsType<Pet>(response);
} }
/// <summary> /// <summary>
@ -122,8 +121,7 @@ namespace Org.OpenAPITools.Test.Api
{ {
// TODO uncomment below to test the method and replace null with proper value // TODO uncomment below to test the method and replace null with proper value
//Pet pet = null; //Pet pet = null;
//var response = instance.UpdatePet(pet); //instance.UpdatePet(pet);
//Assert.IsType<Pet>(response);
} }
/// <summary> /// <summary>
@ -152,5 +150,19 @@ namespace Org.OpenAPITools.Test.Api
//var response = instance.UploadFile(petId, additionalMetadata, file); //var response = instance.UploadFile(petId, additionalMetadata, file);
//Assert.IsType<ApiResponse>(response); //Assert.IsType<ApiResponse>(response);
} }
/// <summary>
/// Test UploadFileWithRequiredFile
/// </summary>
[Fact]
public void UploadFileWithRequiredFileTest()
{
// TODO uncomment below to test the method and replace null with proper value
//long petId = null;
//System.IO.Stream requiredFile = null;
//string additionalMetadata = null;
//var response = instance.UploadFileWithRequiredFile(petId, requiredFile, additionalMetadata);
//Assert.IsType<ApiResponse>(response);
}
} }
} }

View File

@ -1,7 +1,7 @@
/* /*
* OpenAPI Petstore * OpenAPI Petstore
* *
* This is a sample server Petstore server. For this sample, you can use the api key `special-key` to test the authorization filters. * This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
* *
* The version of the OpenAPI document: 1.0.0 * The version of the OpenAPI document: 1.0.0
* Generated by: https://github.com/openapitools/openapi-generator.git * Generated by: https://github.com/openapitools/openapi-generator.git

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