Skip to content

Commit

Permalink
false[adyen-sdk-automation] automated change
Browse files Browse the repository at this point in the history
  • Loading branch information
AdyenAutomationBot committed Nov 27, 2024
1 parent deb6ebb commit 73394a1
Show file tree
Hide file tree
Showing 17 changed files with 858 additions and 231 deletions.
17 changes: 17 additions & 0 deletions Adyen/Model/BalancePlatform/CreateSweepConfigurationV2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -395,6 +395,13 @@ protected CreateSweepConfigurationV2() { }
[DataMember(Name = "description", EmitDefaultValue = false)]
public string Description { get; set; }

/// <summary>
/// The human readable reason for disabling the sweep.
/// </summary>
/// <value>The human readable reason for disabling the sweep.</value>
[DataMember(Name = "reasonDetail", EmitDefaultValue = false)]
public string ReasonDetail { get; private set; }

/// <summary>
/// Your reference for the sweep configuration.
/// </summary>
Expand Down Expand Up @@ -447,6 +454,7 @@ public override string ToString()
sb.Append(" Description: ").Append(Description).Append("\n");
sb.Append(" Priorities: ").Append(Priorities).Append("\n");
sb.Append(" Reason: ").Append(Reason).Append("\n");
sb.Append(" ReasonDetail: ").Append(ReasonDetail).Append("\n");
sb.Append(" Reference: ").Append(Reference).Append("\n");
sb.Append(" ReferenceForBeneficiary: ").Append(ReferenceForBeneficiary).Append("\n");
sb.Append(" Schedule: ").Append(Schedule).Append("\n");
Expand Down Expand Up @@ -517,6 +525,11 @@ public bool Equals(CreateSweepConfigurationV2 input)
this.Reason == input.Reason ||
this.Reason.Equals(input.Reason)
) &&
(
this.ReasonDetail == input.ReasonDetail ||
(this.ReasonDetail != null &&
this.ReasonDetail.Equals(input.ReasonDetail))
) &&
(
this.Reference == input.Reference ||
(this.Reference != null &&
Expand Down Expand Up @@ -581,6 +594,10 @@ public override int GetHashCode()
}
hashCode = (hashCode * 59) + this.Priorities.GetHashCode();
hashCode = (hashCode * 59) + this.Reason.GetHashCode();
if (this.ReasonDetail != null)
{
hashCode = (hashCode * 59) + this.ReasonDetail.GetHashCode();
}
if (this.Reference != null)
{
hashCode = (hashCode * 59) + this.Reference.GetHashCode();
Expand Down
17 changes: 17 additions & 0 deletions Adyen/Model/BalancePlatform/SweepConfigurationV2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -402,6 +402,13 @@ protected SweepConfigurationV2() { }
[DataMember(Name = "id", IsRequired = false, EmitDefaultValue = false)]
public string Id { get; private set; }

/// <summary>
/// The human readable reason for disabling the sweep.
/// </summary>
/// <value>The human readable reason for disabling the sweep.</value>
[DataMember(Name = "reasonDetail", EmitDefaultValue = false)]
public string ReasonDetail { get; private set; }

/// <summary>
/// Your reference for the sweep configuration.
/// </summary>
Expand Down Expand Up @@ -455,6 +462,7 @@ public override string ToString()
sb.Append(" Id: ").Append(Id).Append("\n");
sb.Append(" Priorities: ").Append(Priorities).Append("\n");
sb.Append(" Reason: ").Append(Reason).Append("\n");
sb.Append(" ReasonDetail: ").Append(ReasonDetail).Append("\n");
sb.Append(" Reference: ").Append(Reference).Append("\n");
sb.Append(" ReferenceForBeneficiary: ").Append(ReferenceForBeneficiary).Append("\n");
sb.Append(" Schedule: ").Append(Schedule).Append("\n");
Expand Down Expand Up @@ -530,6 +538,11 @@ public bool Equals(SweepConfigurationV2 input)
this.Reason == input.Reason ||
this.Reason.Equals(input.Reason)
) &&
(
this.ReasonDetail == input.ReasonDetail ||
(this.ReasonDetail != null &&
this.ReasonDetail.Equals(input.ReasonDetail))
) &&
(
this.Reference == input.Reference ||
(this.Reference != null &&
Expand Down Expand Up @@ -598,6 +611,10 @@ public override int GetHashCode()
}
hashCode = (hashCode * 59) + this.Priorities.GetHashCode();
hashCode = (hashCode * 59) + this.Reason.GetHashCode();
if (this.ReasonDetail != null)
{
hashCode = (hashCode * 59) + this.ReasonDetail.GetHashCode();
}
if (this.Reference != null)
{
hashCode = (hashCode * 59) + this.Reference.GetHashCode();
Expand Down
17 changes: 17 additions & 0 deletions Adyen/Model/BalancePlatform/UpdateSweepConfigurationV2.cs
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,13 @@ public enum TypeEnum
[DataMember(Name = "id", EmitDefaultValue = false)]
public string Id { get; private set; }

/// <summary>
/// The human readable reason for disabling the sweep.
/// </summary>
/// <value>The human readable reason for disabling the sweep.</value>
[DataMember(Name = "reasonDetail", EmitDefaultValue = false)]
public string ReasonDetail { get; private set; }

/// <summary>
/// Your reference for the sweep configuration.
/// </summary>
Expand Down Expand Up @@ -450,6 +457,7 @@ public override string ToString()
sb.Append(" Id: ").Append(Id).Append("\n");
sb.Append(" Priorities: ").Append(Priorities).Append("\n");
sb.Append(" Reason: ").Append(Reason).Append("\n");
sb.Append(" ReasonDetail: ").Append(ReasonDetail).Append("\n");
sb.Append(" Reference: ").Append(Reference).Append("\n");
sb.Append(" ReferenceForBeneficiary: ").Append(ReferenceForBeneficiary).Append("\n");
sb.Append(" Schedule: ").Append(Schedule).Append("\n");
Expand Down Expand Up @@ -525,6 +533,11 @@ public bool Equals(UpdateSweepConfigurationV2 input)
this.Reason == input.Reason ||
this.Reason.Equals(input.Reason)
) &&
(
this.ReasonDetail == input.ReasonDetail ||
(this.ReasonDetail != null &&
this.ReasonDetail.Equals(input.ReasonDetail))
) &&
(
this.Reference == input.Reference ||
(this.Reference != null &&
Expand Down Expand Up @@ -593,6 +606,10 @@ public override int GetHashCode()
}
hashCode = (hashCode * 59) + this.Priorities.GetHashCode();
hashCode = (hashCode * 59) + this.Reason.GetHashCode();
if (this.ReasonDetail != null)
{
hashCode = (hashCode * 59) + this.ReasonDetail.GetHashCode();
}
if (this.Reference != null)
{
hashCode = (hashCode * 59) + this.Reference.GetHashCode();
Expand Down
12 changes: 6 additions & 6 deletions Adyen/Model/Checkout/Amount.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,25 +40,25 @@ protected Amount() { }
/// <summary>
/// Initializes a new instance of the <see cref="Amount" /> class.
/// </summary>
/// <param name="currency">The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes). (required).</param>
/// <param name="value">The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes). (required).</param>
/// <param name="currency">The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes#currency-codes). (required).</param>
/// <param name="value">The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes#minor-units). (required).</param>
public Amount(string currency = default(string), long? value = default(long?))
{
this.Currency = currency;
this.Value = value;
}

/// <summary>
/// The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes).
/// The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes#currency-codes).
/// </summary>
/// <value>The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes).</value>
/// <value>The three-character [ISO currency code](https://docs.adyen.com/development-resources/currency-codes#currency-codes).</value>
[DataMember(Name = "currency", IsRequired = false, EmitDefaultValue = false)]
public string Currency { get; set; }

/// <summary>
/// The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes).
/// The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes#minor-units).
/// </summary>
/// <value>The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes).</value>
/// <value>The amount of the transaction, in [minor units](https://docs.adyen.com/development-resources/currency-codes#minor-units).</value>
[DataMember(Name = "value", IsRequired = false, EmitDefaultValue = false)]
public long? Value { get; set; }

Expand Down
35 changes: 34 additions & 1 deletion Adyen/Model/Checkout/CheckoutPaymentMethod.cs
Original file line number Diff line number Diff line change
Expand Up @@ -454,6 +454,18 @@ public CheckoutPaymentMethod(PaymentDetails actualInstance)
this.ActualInstance = actualInstance ?? throw new ArgumentException("Invalid instance found. Must not be null.");
}

/// <summary>
/// Initializes a new instance of the <see cref="CheckoutPaymentMethod" /> class
/// with the <see cref="PseDetails" /> class
/// </summary>
/// <param name="actualInstance">An instance of PseDetails.</param>
public CheckoutPaymentMethod(PseDetails actualInstance)
{
this.IsNullable = false;
this.SchemaType= "oneOf";
this.ActualInstance = actualInstance ?? throw new ArgumentException("Invalid instance found. Must not be null.");
}

/// <summary>
/// Initializes a new instance of the <see cref="CheckoutPaymentMethod" /> class
/// with the <see cref="RatepayDetails" /> class
Expand Down Expand Up @@ -764,6 +776,10 @@ public override Object ActualInstance
{
this._actualInstance = value;
}
else if (value.GetType() == typeof(PseDetails))
{
this._actualInstance = value;
}
else if (value.GetType() == typeof(RatepayDetails))
{
this._actualInstance = value;
Expand Down Expand Up @@ -818,7 +834,7 @@ public override Object ActualInstance
}
else
{
throw new ArgumentException("Invalid instance found. Must be the following types: AchDetails, AfterpayDetails, AmazonPayDetails, AncvDetails, AndroidPayDetails, ApplePayDetails, BacsDirectDebitDetails, BillDeskDetails, BlikDetails, CardDetails, CashAppDetails, CellulantDetails, DokuDetails, DotpayDetails, DragonpayDetails, EBankingFinlandDetails, EcontextVoucherDetails, EftDetails, GenericIssuerPaymentMethodDetails, GiropayDetails, GooglePayDetails, IdealDetails, KlarnaDetails, MasterpassDetails, MbwayDetails, MobilePayDetails, MolPayDetails, OpenInvoiceDetails, PayByBankAISDirectDebitDetails, PayByBankDetails, PayPalDetails, PayToDetails, PayUUpiDetails, PayWithGoogleDetails, PaymentDetails, RatepayDetails, RivertyDetails, SamsungPayDetails, SepaDirectDebitDetails, StoredPaymentMethodDetails, TwintDetails, UpiCollectDetails, UpiIntentDetails, VippsDetails, VisaCheckoutDetails, WeChatPayDetails, WeChatPayMiniProgramDetails, ZipDetails");
throw new ArgumentException("Invalid instance found. Must be the following types: AchDetails, AfterpayDetails, AmazonPayDetails, AncvDetails, AndroidPayDetails, ApplePayDetails, BacsDirectDebitDetails, BillDeskDetails, BlikDetails, CardDetails, CashAppDetails, CellulantDetails, DokuDetails, DotpayDetails, DragonpayDetails, EBankingFinlandDetails, EcontextVoucherDetails, EftDetails, GenericIssuerPaymentMethodDetails, GiropayDetails, GooglePayDetails, IdealDetails, KlarnaDetails, MasterpassDetails, MbwayDetails, MobilePayDetails, MolPayDetails, OpenInvoiceDetails, PayByBankAISDirectDebitDetails, PayByBankDetails, PayPalDetails, PayToDetails, PayUUpiDetails, PayWithGoogleDetails, PaymentDetails, PseDetails, RatepayDetails, RivertyDetails, SamsungPayDetails, SepaDirectDebitDetails, StoredPaymentMethodDetails, TwintDetails, UpiCollectDetails, UpiIntentDetails, VippsDetails, VisaCheckoutDetails, WeChatPayDetails, WeChatPayMiniProgramDetails, ZipDetails");
}
}
}
Expand Down Expand Up @@ -1173,6 +1189,16 @@ public PaymentDetails GetPaymentDetails()
return (PaymentDetails)this.ActualInstance;
}

/// <summary>
/// Get the actual instance of `PseDetails`. If the actual instance is not `PseDetails`,
/// the InvalidClassException will be thrown
/// </summary>
/// <returns>An instance of PseDetails</returns>
public PseDetails GetPseDetails()
{
return (PseDetails)this.ActualInstance;
}

/// <summary>
/// Get the actual instance of `RatepayDetails`. If the actual instance is not `RatepayDetails`,
/// the InvalidClassException will be thrown
Expand Down Expand Up @@ -1594,6 +1620,13 @@ public static CheckoutPaymentMethod FromJson(string jsonString)
matchedTypes.Add("PaymentDetails");
match++;
}
// Check if the jsonString type enum matches the PseDetails type enums
if (ContainsValue<PseDetails.TypeEnum>(type))
{
newCheckoutPaymentMethod = new CheckoutPaymentMethod(JsonConvert.DeserializeObject<PseDetails>(jsonString, CheckoutPaymentMethod.SerializerSettings));
matchedTypes.Add("PseDetails");
match++;
}
// Check if the jsonString type enum matches the RatepayDetails type enums
if (ContainsValue<RatepayDetails.TypeEnum>(type))
{
Expand Down
Loading

0 comments on commit 73394a1

Please sign in to comment.