add new files for C# API client

This commit is contained in:
wing328 2017-05-23 22:20:08 +08:00
parent b18121ee9c
commit f33e1d0026
16 changed files with 890 additions and 6 deletions

View File

@ -0,0 +1 @@
2.3.0-SNAPSHOT

View File

@ -133,10 +133,8 @@ Class | Method | HTTP request | Description
- [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md) - [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md)
- [Model.ArrayTest](docs/ArrayTest.md) - [Model.ArrayTest](docs/ArrayTest.md)
- [Model.Capitalization](docs/Capitalization.md) - [Model.Capitalization](docs/Capitalization.md)
- [Model.Cat](docs/Cat.md)
- [Model.Category](docs/Category.md) - [Model.Category](docs/Category.md)
- [Model.ClassModel](docs/ClassModel.md) - [Model.ClassModel](docs/ClassModel.md)
- [Model.Dog](docs/Dog.md)
- [Model.EnumArrays](docs/EnumArrays.md) - [Model.EnumArrays](docs/EnumArrays.md)
- [Model.EnumClass](docs/EnumClass.md) - [Model.EnumClass](docs/EnumClass.md)
- [Model.EnumTest](docs/EnumTest.md) - [Model.EnumTest](docs/EnumTest.md)
@ -161,6 +159,8 @@ Class | Method | HTTP request | Description
- [Model.SpecialModelName](docs/SpecialModelName.md) - [Model.SpecialModelName](docs/SpecialModelName.md)
- [Model.Tag](docs/Tag.md) - [Model.Tag](docs/Tag.md)
- [Model.User](docs/User.md) - [Model.User](docs/User.md)
- [Model.Cat](docs/Cat.md)
- [Model.Dog](docs/Dog.md)
<a name="documentation-for-authorization"></a> <a name="documentation-for-authorization"></a>

View File

@ -0,0 +1 @@
2.3.0-SNAPSHOT

View File

@ -113,10 +113,8 @@ Class | Method | HTTP request | Description
- [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md) - [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md)
- [Model.ArrayTest](docs/ArrayTest.md) - [Model.ArrayTest](docs/ArrayTest.md)
- [Model.Capitalization](docs/Capitalization.md) - [Model.Capitalization](docs/Capitalization.md)
- [Model.Cat](docs/Cat.md)
- [Model.Category](docs/Category.md) - [Model.Category](docs/Category.md)
- [Model.ClassModel](docs/ClassModel.md) - [Model.ClassModel](docs/ClassModel.md)
- [Model.Dog](docs/Dog.md)
- [Model.EnumArrays](docs/EnumArrays.md) - [Model.EnumArrays](docs/EnumArrays.md)
- [Model.EnumClass](docs/EnumClass.md) - [Model.EnumClass](docs/EnumClass.md)
- [Model.EnumTest](docs/EnumTest.md) - [Model.EnumTest](docs/EnumTest.md)
@ -141,6 +139,8 @@ Class | Method | HTTP request | Description
- [Model.SpecialModelName](docs/SpecialModelName.md) - [Model.SpecialModelName](docs/SpecialModelName.md)
- [Model.Tag](docs/Tag.md) - [Model.Tag](docs/Tag.md)
- [Model.User](docs/User.md) - [Model.User](docs/User.md)
- [Model.Cat](docs/Cat.md)
- [Model.Dog](docs/Dog.md)
<a name="documentation-for-authorization"></a> <a name="documentation-for-authorization"></a>

View File

@ -0,0 +1,69 @@
# IO.Swagger.Api.Fake_classname_tags123Api
All URIs are relative to *http://petstore.swagger.io:80/v2*
Method | HTTP request | Description
------------- | ------------- | -------------
[**TestClassname**](Fake_classname_tags123Api.md#testclassname) | **PATCH** /fake_classname_test | To test class name in snake case
<a name="testclassname"></a>
# **TestClassname**
> ModelClient TestClassname (ModelClient body)
To test class name in snake case
### Example
```csharp
using System;
using System.Diagnostics;
using IO.Swagger.Api;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace Example
{
public class TestClassnameExample
{
public void main()
{
var apiInstance = new Fake_classname_tags123Api();
var body = new ModelClient(); // ModelClient | client model
try
{
// To test class name in snake case
ModelClient result = apiInstance.TestClassname(body);
Debug.WriteLine(result);
}
catch (Exception e)
{
Debug.Print("Exception when calling Fake_classname_tags123Api.TestClassname: " + e.Message );
}
}
}
}
```
### Parameters
Name | Type | Description | Notes
------------- | ------------- | ------------- | -------------
**body** | [**ModelClient**](ModelClient.md)| client model |
### Return type
[**ModelClient**](ModelClient.md)
### Authorization
No authorization required
### HTTP request headers
- **Content-Type**: application/json
- **Accept**: application/json
[[Back to top]](#) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to Model list]](../README.md#documentation-for-models) [[Back to README]](../README.md)

View File

@ -0,0 +1,8 @@
# IO.Swagger.Model.OuterBoolean
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,11 @@
# IO.Swagger.Model.OuterComposite
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**MyNumber** | [**OuterNumber**](OuterNumber.md) | | [optional]
**MyString** | [**OuterString**](OuterString.md) | | [optional]
**MyBoolean** | [**OuterBoolean**](OuterBoolean.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

@ -0,0 +1,8 @@
# IO.Swagger.Model.OuterNumber
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,8 @@
# IO.Swagger.Model.OuterString
## Properties
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)

View File

@ -0,0 +1,333 @@
/*
* Swagger Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* OpenAPI spec version: 1.0.0
* Contact: apiteam@swagger.io
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Linq;
using RestSharp.Portable;
using IO.Swagger.Client;
using IO.Swagger.Model;
namespace IO.Swagger.Api
{
/// <summary>
/// Represents a collection of functions to interact with the API endpoints
/// </summary>
public interface IFake_classname_tags123Api : IApiAccessor
{
#region Synchronous Operations
/// <summary>
/// To test class name in snake case
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>ModelClient</returns>
ModelClient TestClassname (ModelClient body);
/// <summary>
/// To test class name in snake case
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>ApiResponse of ModelClient</returns>
ApiResponse<ModelClient> TestClassnameWithHttpInfo (ModelClient body);
#endregion Synchronous Operations
#region Asynchronous Operations
/// <summary>
/// To test class name in snake case
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>Task of ModelClient</returns>
System.Threading.Tasks.Task<ModelClient> TestClassnameAsync (ModelClient body);
/// <summary>
/// To test class name in snake case
/// </summary>
/// <remarks>
///
/// </remarks>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>Task of ApiResponse (ModelClient)</returns>
System.Threading.Tasks.Task<ApiResponse<ModelClient>> TestClassnameAsyncWithHttpInfo (ModelClient body);
#endregion Asynchronous Operations
}
/// <summary>
/// Represents a collection of functions to interact with the API endpoints
/// </summary>
public partial class Fake_classname_tags123Api : IFake_classname_tags123Api
{
private IO.Swagger.Client.ExceptionFactory _exceptionFactory = (name, response) => null;
/// <summary>
/// Initializes a new instance of the <see cref="Fake_classname_tags123Api"/> class.
/// </summary>
/// <returns></returns>
public Fake_classname_tags123Api(String basePath)
{
this.Configuration = new Configuration(new ApiClient(basePath));
ExceptionFactory = IO.Swagger.Client.Configuration.DefaultExceptionFactory;
// ensure API client has configuration ready
if (Configuration.ApiClient.Configuration == null)
{
this.Configuration.ApiClient.Configuration = this.Configuration;
}
}
/// <summary>
/// Initializes a new instance of the <see cref="Fake_classname_tags123Api"/> class
/// using Configuration object
/// </summary>
/// <param name="configuration">An instance of Configuration</param>
/// <returns></returns>
public Fake_classname_tags123Api(Configuration configuration = null)
{
if (configuration == null) // use the default one in Configuration
this.Configuration = Configuration.Default;
else
this.Configuration = configuration;
ExceptionFactory = IO.Swagger.Client.Configuration.DefaultExceptionFactory;
// ensure API client has configuration ready
if (Configuration.ApiClient.Configuration == null)
{
this.Configuration.ApiClient.Configuration = this.Configuration;
}
}
/// <summary>
/// Gets the base path of the API client.
/// </summary>
/// <value>The base path</value>
public String GetBasePath()
{
return this.Configuration.ApiClient.RestClient.BaseUrl.ToString();
}
/// <summary>
/// Sets the base path of the API client.
/// </summary>
/// <value>The base path</value>
[Obsolete("SetBasePath is deprecated, please do 'Configuration.ApiClient = new ApiClient(\"http://new-path\")' instead.")]
public void SetBasePath(String basePath)
{
// do nothing
}
/// <summary>
/// Gets or sets the configuration object
/// </summary>
/// <value>An instance of the Configuration</value>
public Configuration Configuration {get; set;}
/// <summary>
/// Provides a factory method hook for the creation of exceptions.
/// </summary>
public IO.Swagger.Client.ExceptionFactory ExceptionFactory
{
get
{
if (_exceptionFactory != null && _exceptionFactory.GetInvocationList().Length > 1)
{
throw new InvalidOperationException("Multicast delegate for ExceptionFactory is unsupported.");
}
return _exceptionFactory;
}
set { _exceptionFactory = value; }
}
/// <summary>
/// Gets the default header.
/// </summary>
/// <returns>Dictionary of HTTP header</returns>
[Obsolete("DefaultHeader is deprecated, please use Configuration.DefaultHeader instead.")]
public Dictionary<String, String> DefaultHeader()
{
return this.Configuration.DefaultHeader;
}
/// <summary>
/// Add default header.
/// </summary>
/// <param name="key">Header field name.</param>
/// <param name="value">Header field value.</param>
/// <returns></returns>
[Obsolete("AddDefaultHeader is deprecated, please use Configuration.AddDefaultHeader instead.")]
public void AddDefaultHeader(string key, string value)
{
this.Configuration.AddDefaultHeader(key, value);
}
/// <summary>
/// To test class name in snake case
/// </summary>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>ModelClient</returns>
public ModelClient TestClassname (ModelClient body)
{
ApiResponse<ModelClient> localVarResponse = TestClassnameWithHttpInfo(body);
return localVarResponse.Data;
}
/// <summary>
/// To test class name in snake case
/// </summary>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>ApiResponse of ModelClient</returns>
public ApiResponse< ModelClient > TestClassnameWithHttpInfo (ModelClient body)
{
// verify the required parameter 'body' is set
if (body == null)
throw new ApiException(400, "Missing required parameter 'body' when calling Fake_classname_tags123Api->TestClassname");
var localVarPath = "./fake_classname_test";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/json"
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/json"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (body != null && body.GetType() != typeof(byte[]))
{
localVarPostBody = Configuration.ApiClient.Serialize(body); // http body (model) parameter
}
else
{
localVarPostBody = body; // byte array
}
// make the HTTP request
IRestResponse localVarResponse = (IRestResponse) Configuration.ApiClient.CallApi(localVarPath,
Method.PATCH, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("TestClassname", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse<ModelClient>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(ModelClient) Configuration.ApiClient.Deserialize(localVarResponse, typeof(ModelClient)));
}
/// <summary>
/// To test class name in snake case
/// </summary>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>Task of ModelClient</returns>
public async System.Threading.Tasks.Task<ModelClient> TestClassnameAsync (ModelClient body)
{
ApiResponse<ModelClient> localVarResponse = await TestClassnameAsyncWithHttpInfo(body);
return localVarResponse.Data;
}
/// <summary>
/// To test class name in snake case
/// </summary>
/// <exception cref="IO.Swagger.Client.ApiException">Thrown when fails to make API call</exception>
/// <param name="body">client model</param>
/// <returns>Task of ApiResponse (ModelClient)</returns>
public async System.Threading.Tasks.Task<ApiResponse<ModelClient>> TestClassnameAsyncWithHttpInfo (ModelClient body)
{
// verify the required parameter 'body' is set
if (body == null)
throw new ApiException(400, "Missing required parameter 'body' when calling Fake_classname_tags123Api->TestClassname");
var localVarPath = "./fake_classname_test";
var localVarPathParams = new Dictionary<String, String>();
var localVarQueryParams = new List<KeyValuePair<String, String>>();
var localVarHeaderParams = new Dictionary<String, String>(Configuration.DefaultHeader);
var localVarFormParams = new Dictionary<String, String>();
var localVarFileParams = new Dictionary<String, FileParameter>();
Object localVarPostBody = null;
// to determine the Content-Type header
String[] localVarHttpContentTypes = new String[] {
"application/json"
};
String localVarHttpContentType = Configuration.ApiClient.SelectHeaderContentType(localVarHttpContentTypes);
// to determine the Accept header
String[] localVarHttpHeaderAccepts = new String[] {
"application/json"
};
String localVarHttpHeaderAccept = Configuration.ApiClient.SelectHeaderAccept(localVarHttpHeaderAccepts);
if (localVarHttpHeaderAccept != null)
localVarHeaderParams.Add("Accept", localVarHttpHeaderAccept);
if (body != null && body.GetType() != typeof(byte[]))
{
localVarPostBody = Configuration.ApiClient.Serialize(body); // http body (model) parameter
}
else
{
localVarPostBody = body; // byte array
}
// make the HTTP request
IRestResponse localVarResponse = (IRestResponse) await Configuration.ApiClient.CallApiAsync(localVarPath,
Method.PATCH, localVarQueryParams, localVarPostBody, localVarHeaderParams, localVarFormParams, localVarFileParams,
localVarPathParams, localVarHttpContentType);
int localVarStatusCode = (int) localVarResponse.StatusCode;
if (ExceptionFactory != null)
{
Exception exception = ExceptionFactory("TestClassname", localVarResponse);
if (exception != null) throw exception;
}
return new ApiResponse<ModelClient>(localVarStatusCode,
localVarResponse.Headers.ToDictionary(x => x.Key, x => x.Value.ToString()),
(ModelClient) Configuration.ApiClient.Deserialize(localVarResponse, typeof(ModelClient)));
}
}
}

View File

@ -0,0 +1,100 @@
/*
* Swagger Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* OpenAPI spec version: 1.0.0
* Contact: apiteam@swagger.io
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace IO.Swagger.Model
{
/// <summary>
/// OuterBoolean
/// </summary>
[DataContract]
public partial class OuterBoolean : IEquatable<OuterBoolean>
{
/// <summary>
/// Initializes a new instance of the <see cref="OuterBoolean" /> class.
/// </summary>
[JsonConstructorAttribute]
public OuterBoolean()
{
}
/// <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 OuterBoolean {\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 string ToJson()
{
return JsonConvert.SerializeObject(this, Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="obj">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object obj)
{
// credit: http://stackoverflow.com/a/10454552/677735
return this.Equals(obj as OuterBoolean);
}
/// <summary>
/// Returns true if OuterBoolean instances are equal
/// </summary>
/// <param name="other">Instance of OuterBoolean to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(OuterBoolean other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return false;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
// credit: http://stackoverflow.com/a/263416/677735
unchecked // Overflow is fine, just wrap
{
int hash = 41;
// Suitable nullity checks etc, of course :)
return hash;
}
}
}
}

View File

@ -0,0 +1,144 @@
/*
* Swagger Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* OpenAPI spec version: 1.0.0
* Contact: apiteam@swagger.io
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace IO.Swagger.Model
{
/// <summary>
/// OuterComposite
/// </summary>
[DataContract]
public partial class OuterComposite : IEquatable<OuterComposite>
{
/// <summary>
/// Initializes a new instance of the <see cref="OuterComposite" /> class.
/// </summary>
/// <param name="MyNumber">MyNumber.</param>
/// <param name="MyString">MyString.</param>
/// <param name="MyBoolean">MyBoolean.</param>
public OuterComposite(OuterNumber MyNumber = default(OuterNumber), OuterString MyString = default(OuterString), OuterBoolean MyBoolean = default(OuterBoolean))
{
this.MyNumber = MyNumber;
this.MyString = MyString;
this.MyBoolean = MyBoolean;
}
/// <summary>
/// Gets or Sets MyNumber
/// </summary>
[DataMember(Name="my_number", EmitDefaultValue=false)]
public OuterNumber MyNumber { get; set; }
/// <summary>
/// Gets or Sets MyString
/// </summary>
[DataMember(Name="my_string", EmitDefaultValue=false)]
public OuterString MyString { get; set; }
/// <summary>
/// Gets or Sets MyBoolean
/// </summary>
[DataMember(Name="my_boolean", EmitDefaultValue=false)]
public OuterBoolean MyBoolean { 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 OuterComposite {\n");
sb.Append(" MyNumber: ").Append(MyNumber).Append("\n");
sb.Append(" MyString: ").Append(MyString).Append("\n");
sb.Append(" MyBoolean: ").Append(MyBoolean).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 string ToJson()
{
return JsonConvert.SerializeObject(this, Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="obj">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object obj)
{
// credit: http://stackoverflow.com/a/10454552/677735
return this.Equals(obj as OuterComposite);
}
/// <summary>
/// Returns true if OuterComposite instances are equal
/// </summary>
/// <param name="other">Instance of OuterComposite to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(OuterComposite other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return
(
this.MyNumber == other.MyNumber ||
this.MyNumber != null &&
this.MyNumber.Equals(other.MyNumber)
) &&
(
this.MyString == other.MyString ||
this.MyString != null &&
this.MyString.Equals(other.MyString)
) &&
(
this.MyBoolean == other.MyBoolean ||
this.MyBoolean != null &&
this.MyBoolean.Equals(other.MyBoolean)
);
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
// credit: http://stackoverflow.com/a/263416/677735
unchecked // Overflow is fine, just wrap
{
int hash = 41;
// Suitable nullity checks etc, of course :)
if (this.MyNumber != null)
hash = hash * 59 + this.MyNumber.GetHashCode();
if (this.MyString != null)
hash = hash * 59 + this.MyString.GetHashCode();
if (this.MyBoolean != null)
hash = hash * 59 + this.MyBoolean.GetHashCode();
return hash;
}
}
}
}

View File

@ -0,0 +1,100 @@
/*
* Swagger Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* OpenAPI spec version: 1.0.0
* Contact: apiteam@swagger.io
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace IO.Swagger.Model
{
/// <summary>
/// OuterNumber
/// </summary>
[DataContract]
public partial class OuterNumber : IEquatable<OuterNumber>
{
/// <summary>
/// Initializes a new instance of the <see cref="OuterNumber" /> class.
/// </summary>
[JsonConstructorAttribute]
public OuterNumber()
{
}
/// <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 OuterNumber {\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 string ToJson()
{
return JsonConvert.SerializeObject(this, Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="obj">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object obj)
{
// credit: http://stackoverflow.com/a/10454552/677735
return this.Equals(obj as OuterNumber);
}
/// <summary>
/// Returns true if OuterNumber instances are equal
/// </summary>
/// <param name="other">Instance of OuterNumber to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(OuterNumber other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return false;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
// credit: http://stackoverflow.com/a/263416/677735
unchecked // Overflow is fine, just wrap
{
int hash = 41;
// Suitable nullity checks etc, of course :)
return hash;
}
}
}
}

View File

@ -0,0 +1,100 @@
/*
* Swagger Petstore
*
* This spec is mainly for testing Petstore server and contains fake endpoints, models. Please do not use this for any other purpose. Special characters: \" \\
*
* OpenAPI spec version: 1.0.0
* Contact: apiteam@swagger.io
* Generated by: https://github.com/swagger-api/swagger-codegen.git
*/
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
namespace IO.Swagger.Model
{
/// <summary>
/// OuterString
/// </summary>
[DataContract]
public partial class OuterString : IEquatable<OuterString>
{
/// <summary>
/// Initializes a new instance of the <see cref="OuterString" /> class.
/// </summary>
[JsonConstructorAttribute]
public OuterString()
{
}
/// <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 OuterString {\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 string ToJson()
{
return JsonConvert.SerializeObject(this, Formatting.Indented);
}
/// <summary>
/// Returns true if objects are equal
/// </summary>
/// <param name="obj">Object to be compared</param>
/// <returns>Boolean</returns>
public override bool Equals(object obj)
{
// credit: http://stackoverflow.com/a/10454552/677735
return this.Equals(obj as OuterString);
}
/// <summary>
/// Returns true if OuterString instances are equal
/// </summary>
/// <param name="other">Instance of OuterString to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(OuterString other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return false;
}
/// <summary>
/// Gets the hash code
/// </summary>
/// <returns>Hash code</returns>
public override int GetHashCode()
{
// credit: http://stackoverflow.com/a/263416/677735
unchecked // Overflow is fine, just wrap
{
int hash = 41;
// Suitable nullity checks etc, of course :)
return hash;
}
}
}
}

View File

@ -133,10 +133,8 @@ Class | Method | HTTP request | Description
- [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md) - [Model.ArrayOfNumberOnly](docs/ArrayOfNumberOnly.md)
- [Model.ArrayTest](docs/ArrayTest.md) - [Model.ArrayTest](docs/ArrayTest.md)
- [Model.Capitalization](docs/Capitalization.md) - [Model.Capitalization](docs/Capitalization.md)
- [Model.Cat](docs/Cat.md)
- [Model.Category](docs/Category.md) - [Model.Category](docs/Category.md)
- [Model.ClassModel](docs/ClassModel.md) - [Model.ClassModel](docs/ClassModel.md)
- [Model.Dog](docs/Dog.md)
- [Model.EnumArrays](docs/EnumArrays.md) - [Model.EnumArrays](docs/EnumArrays.md)
- [Model.EnumClass](docs/EnumClass.md) - [Model.EnumClass](docs/EnumClass.md)
- [Model.EnumTest](docs/EnumTest.md) - [Model.EnumTest](docs/EnumTest.md)
@ -161,6 +159,8 @@ Class | Method | HTTP request | Description
- [Model.SpecialModelName](docs/SpecialModelName.md) - [Model.SpecialModelName](docs/SpecialModelName.md)
- [Model.Tag](docs/Tag.md) - [Model.Tag](docs/Tag.md)
- [Model.User](docs/User.md) - [Model.User](docs/User.md)
- [Model.Cat](docs/Cat.md)
- [Model.Dog](docs/Dog.md)
<a name="documentation-for-authorization"></a> <a name="documentation-for-authorization"></a>