-
Notifications
You must be signed in to change notification settings - Fork 114
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
false[adyen-sdk-automation] automated change (#1009)
- Loading branch information
1 parent
60bc6a6
commit 07d740a
Showing
5 changed files
with
389 additions
and
93 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,191 @@ | ||
/* | ||
* Management API | ||
* | ||
* | ||
* The version of the OpenAPI document: 3 | ||
* | ||
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). | ||
* https://openapi-generator.tech | ||
* Do not edit the class manually. | ||
*/ | ||
|
||
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 = Adyen.ApiSerialization.OpenAPIDateConverter; | ||
|
||
namespace Adyen.Model.Management | ||
{ | ||
/// <summary> | ||
/// AmexInfo | ||
/// </summary> | ||
[DataContract(Name = "AmexInfo")] | ||
public partial class AmexInfo : IEquatable<AmexInfo>, IValidatableObject | ||
{ | ||
/// <summary> | ||
/// Specifies the service level (settlement type) of this payment method. Possible values: * **noContract** — Adyen holds the contract with American Express. * **gatewayContract** — American Express receives the settlement and handles disputes. They then pay out to the merchant directly. * **paymentDesignatorContract** — Adyen receives the settlement and handles disputes. Adyen then pays out to the merchant. | ||
/// </summary> | ||
/// <value>Specifies the service level (settlement type) of this payment method. Possible values: * **noContract** — Adyen holds the contract with American Express. * **gatewayContract** — American Express receives the settlement and handles disputes. They then pay out to the merchant directly. * **paymentDesignatorContract** — Adyen receives the settlement and handles disputes. Adyen then pays out to the merchant.</value> | ||
[JsonConverter(typeof(StringEnumConverter))] | ||
public enum ServiceLevelEnum | ||
{ | ||
/// <summary> | ||
/// Enum NoContract for value: noContract | ||
/// </summary> | ||
[EnumMember(Value = "noContract")] | ||
NoContract = 1, | ||
|
||
/// <summary> | ||
/// Enum GatewayContract for value: gatewayContract | ||
/// </summary> | ||
[EnumMember(Value = "gatewayContract")] | ||
GatewayContract = 2, | ||
|
||
/// <summary> | ||
/// Enum PaymentDesignatorContract for value: paymentDesignatorContract | ||
/// </summary> | ||
[EnumMember(Value = "paymentDesignatorContract")] | ||
PaymentDesignatorContract = 3 | ||
|
||
} | ||
|
||
|
||
/// <summary> | ||
/// Specifies the service level (settlement type) of this payment method. Possible values: * **noContract** — Adyen holds the contract with American Express. * **gatewayContract** — American Express receives the settlement and handles disputes. They then pay out to the merchant directly. * **paymentDesignatorContract** — Adyen receives the settlement and handles disputes. Adyen then pays out to the merchant. | ||
/// </summary> | ||
/// <value>Specifies the service level (settlement type) of this payment method. Possible values: * **noContract** — Adyen holds the contract with American Express. * **gatewayContract** — American Express receives the settlement and handles disputes. They then pay out to the merchant directly. * **paymentDesignatorContract** — Adyen receives the settlement and handles disputes. Adyen then pays out to the merchant.</value> | ||
[DataMember(Name = "serviceLevel", IsRequired = false, EmitDefaultValue = false)] | ||
public ServiceLevelEnum ServiceLevel { get; set; } | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="AmexInfo" /> class. | ||
/// </summary> | ||
[JsonConstructorAttribute] | ||
protected AmexInfo() { } | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="AmexInfo" /> class. | ||
/// </summary> | ||
/// <param name="midNumber">MID (Merchant ID) number. Format: 10 numeric characters. Must be provided only when requesting `gatewayContract` or `paymentDesignatorContract` service levels..</param> | ||
/// <param name="reuseMidNumber">Indicates whether the Amex Merchant ID is reused from a previously setup Amex payment method. This is only applicable for `gatewayContract` and `paymentDesignatorContract` service levels. The default value is `false`. (default to false).</param> | ||
/// <param name="serviceLevel">Specifies the service level (settlement type) of this payment method. Possible values: * **noContract** — Adyen holds the contract with American Express. * **gatewayContract** — American Express receives the settlement and handles disputes. They then pay out to the merchant directly. * **paymentDesignatorContract** — Adyen receives the settlement and handles disputes. Adyen then pays out to the merchant. (required).</param> | ||
public AmexInfo(string midNumber = default(string), bool? reuseMidNumber = false, ServiceLevelEnum serviceLevel = default(ServiceLevelEnum)) | ||
{ | ||
this.ServiceLevel = serviceLevel; | ||
this.MidNumber = midNumber; | ||
this.ReuseMidNumber = reuseMidNumber; | ||
} | ||
|
||
/// <summary> | ||
/// MID (Merchant ID) number. Format: 10 numeric characters. Must be provided only when requesting `gatewayContract` or `paymentDesignatorContract` service levels. | ||
/// </summary> | ||
/// <value>MID (Merchant ID) number. Format: 10 numeric characters. Must be provided only when requesting `gatewayContract` or `paymentDesignatorContract` service levels.</value> | ||
[DataMember(Name = "midNumber", EmitDefaultValue = false)] | ||
public string MidNumber { get; set; } | ||
|
||
/// <summary> | ||
/// Indicates whether the Amex Merchant ID is reused from a previously setup Amex payment method. This is only applicable for `gatewayContract` and `paymentDesignatorContract` service levels. The default value is `false`. | ||
/// </summary> | ||
/// <value>Indicates whether the Amex Merchant ID is reused from a previously setup Amex payment method. This is only applicable for `gatewayContract` and `paymentDesignatorContract` service levels. The default value is `false`.</value> | ||
[DataMember(Name = "reuseMidNumber", EmitDefaultValue = false)] | ||
public bool? ReuseMidNumber { 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 AmexInfo {\n"); | ||
sb.Append(" MidNumber: ").Append(MidNumber).Append("\n"); | ||
sb.Append(" ReuseMidNumber: ").Append(ReuseMidNumber).Append("\n"); | ||
sb.Append(" ServiceLevel: ").Append(ServiceLevel).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 this.Equals(input as AmexInfo); | ||
} | ||
|
||
/// <summary> | ||
/// Returns true if AmexInfo instances are equal | ||
/// </summary> | ||
/// <param name="input">Instance of AmexInfo to be compared</param> | ||
/// <returns>Boolean</returns> | ||
public bool Equals(AmexInfo input) | ||
{ | ||
if (input == null) | ||
{ | ||
return false; | ||
} | ||
return | ||
( | ||
this.MidNumber == input.MidNumber || | ||
(this.MidNumber != null && | ||
this.MidNumber.Equals(input.MidNumber)) | ||
) && | ||
( | ||
this.ReuseMidNumber == input.ReuseMidNumber || | ||
this.ReuseMidNumber.Equals(input.ReuseMidNumber) | ||
) && | ||
( | ||
this.ServiceLevel == input.ServiceLevel || | ||
this.ServiceLevel.Equals(input.ServiceLevel) | ||
); | ||
} | ||
|
||
/// <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.MidNumber != null) | ||
{ | ||
hashCode = (hashCode * 59) + this.MidNumber.GetHashCode(); | ||
} | ||
hashCode = (hashCode * 59) + this.ReuseMidNumber.GetHashCode(); | ||
hashCode = (hashCode * 59) + this.ServiceLevel.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; | ||
} | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.