Skip to content

Commit

Permalink
Release 3.0.9
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewrowanwallee committed Dec 6, 2021
1 parent e4bc159 commit fd0cbd5
Show file tree
Hide file tree
Showing 25 changed files with 3,538 additions and 18 deletions.
28 changes: 23 additions & 5 deletions .github/workflows/publishing.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:

jobs:
build:
runs-on: windows-latest
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
Expand All @@ -19,14 +19,32 @@ jobs:
- name: Install dependencies
run: dotnet restore

- name: Test Nuget
run: |
nuget restore Wallee.sln
nuget install NUnit.Console -Version 3.11.1 -OutputDirectory testrunner
msbuild /t:restore Wallee.sln && msbuild Wallee.sln /t:build /p:Configuration=Release
mono testrunner/NUnit.ConsoleRunner.3.11.1/tools/nunit3-console.exe ./src/Wallee.Test/bin/Release/net452/Wallee.Test.dll --inprocess
publish:
needs: build
runs-on: windows-latest
steps:
- uses: actions/checkout@v2

- name: Setup .NET Core
uses: actions/setup-dotnet@v1
with:
dotnet-version: 3.1.101

- name: Install dependencies
run: dotnet restore

- name: Build
run: dotnet build --configuration Release --no-restore

- name: Test
run: dotnet test --configuration Release --no-restore --verbosity normal

- name: Pack
run: dotnet pack --configuration Release --no-build --output .
run: dotnet pack --configuration Release --output .

- name: Publish
uses: brandedoutcast/[email protected]
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ NOTE: RestSharp versions greater than 106.2.1 have a bug which causes file uploa
## Installation
```
# Package Manager
Install-Package Wallee -Version 3.0.8
Install-Package Wallee -Version 3.0.9
# .NET CLI
dotnet add package Wallee --version 3.0.8
dotnet add package Wallee --version 3.0.9
# Paket CLI
paket add Wallee --version 3.0.8
paket add Wallee --version 3.0.9
# PackageReference
<PackageReference Include="Wallee" Version="3.0.8" />
<PackageReference Include="Wallee" Version="3.0.9" />
```

Then include the DLL (under the `bin` folder) in the C# project, and use the namespaces:
Expand Down
8 changes: 4 additions & 4 deletions src/Wallee/Client/Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public class Configuration : IReadableConfiguration
/// Version of the package.
/// </summary>
/// <value>Version of the package.</value>
public const string Version = "3.0.8";
public const string Version = "3.0.9";

/// <summary>
/// Identifier for ISO 8601 DateTime Format
Expand Down Expand Up @@ -90,7 +90,7 @@ public Configuration(string applicationUserID, string authenticationKey)
}
_authenticationKey = authenticationKey;
_applicationUserID = applicationUserID;
UserAgent = "Wallee/3.0.8/csharp";
UserAgent = "Wallee/3.0.9/csharp";
BasePath = "https://app-wallee.com:443/api";
DefaultHeader = new ConcurrentDictionary<string, string>();
ApiKey = new ConcurrentDictionary<string, string>();
Expand Down Expand Up @@ -338,8 +338,8 @@ public static String ToDebugReport()
String report = "C# SDK (Wallee) Debug Report:\n";
report += " OS: " + System.Environment.OSVersion + "\n";
report += " .NET Framework Version: " + System.Environment.Version + "\n";
report += " Version of the API: 3.0.8\n";
report += " SDK Package Version: 3.0.8\n";
report += " Version of the API: 3.0.9\n";
report += " SDK Package Version: 3.0.9\n";

return report;
}
Expand Down
40 changes: 40 additions & 0 deletions src/Wallee/Model/PaymentAppChargeAttemptTargetState.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.ComponentModel.DataAnnotations;
using SwaggerDateConverter = Wallee.Client.SwaggerDateConverter;

namespace Wallee.Model
{
/// <summary>
/// The target state indicates the state that should be set on the charge attempt.
/// </summary>
/// <value>The target state indicates the state that should be set on the charge attempt.</value>

[JsonConverter(typeof(StringEnumConverter))]

public enum PaymentAppChargeAttemptTargetState
{

/// <summary>
/// Enum SUCCESSFUL for value: SUCCESSFUL
/// </summary>
[EnumMember(Value = "SUCCESSFUL")]
SUCCESSFUL,

/// <summary>
/// Enum FAILED for value: FAILED
/// </summary>
[EnumMember(Value = "FAILED")]
FAILED
}

}
164 changes: 164 additions & 0 deletions src/Wallee/Model/PaymentAppChargeAttemptUpdateRequest.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,164 @@
using System;
using System.Linq;
using System.IO;
using System.Text;
using System.Text.RegularExpressions;
using System.Collections;
using System.Collections.Generic;
using System.Collections.ObjectModel;
using System.Runtime.Serialization;
using Newtonsoft.Json;
using Newtonsoft.Json.Converters;
using System.ComponentModel.DataAnnotations;
using SwaggerDateConverter = Wallee.Client.SwaggerDateConverter;

namespace Wallee.Model
{
/// <summary>
/// The charge attempt update request allows to change the state of a charge attempt. The charge attempt must be linked with a processor that was created by the payment Web App that invokes the operation.
/// </summary>
[DataContract]
public partial class PaymentAppChargeAttemptUpdateRequest : IEquatable<PaymentAppChargeAttemptUpdateRequest>
{
/// <summary>
/// The target state defines the state into which the charge attempt should be switched into. Once the charge attempt changed the state it will not be possible to change it again.
/// </summary>
/// <value>The target state defines the state into which the charge attempt should be switched into. Once the charge attempt changed the state it will not be possible to change it again.</value>
[DataMember(Name="targetState", EmitDefaultValue=true)]
public PaymentAppChargeAttemptTargetState? TargetState { get; set; }
/// <summary>
/// Initializes a new instance of the <see cref="PaymentAppChargeAttemptUpdateRequest" /> class.
/// </summary>
public PaymentAppChargeAttemptUpdateRequest()
{
}

/// <summary>
/// This is the ID of the charge attempt that should be updated.
/// </summary>
/// <value>This is the ID of the charge attempt that should be updated.</value>
[DataMember(Name="chargeAttemptId", EmitDefaultValue=true)]
public long? ChargeAttemptId { get; set; }

/// <summary>
/// The end user failure message indicates to the end user (buyer) why the payment failed. The message has to be in the language of the end user. The language is provided within the payment page invocation URL.
/// </summary>
/// <value>The end user failure message indicates to the end user (buyer) why the payment failed. The message has to be in the language of the end user. The language is provided within the payment page invocation URL.</value>
[DataMember(Name="endUserFailureMessage", EmitDefaultValue=true)]
public string EndUserFailureMessage { get; set; }

/// <summary>
/// The failure reason indicates why the charge attempt failed. It is required when the target state is FAILED.
/// </summary>
/// <value>The failure reason indicates why the charge attempt failed. It is required when the target state is FAILED.</value>
[DataMember(Name="failureReasonId", EmitDefaultValue=true)]
public long? FailureReasonId { get; set; }

/// <summary>
/// The reference identifies the charge attempt within the systems of the external service provider. It is required when the target state is SUCCESSFUL.
/// </summary>
/// <value>The reference identifies the charge attempt within the systems of the external service provider. It is required when the target state is SUCCESSFUL.</value>
[DataMember(Name="reference", EmitDefaultValue=true)]
public string Reference { 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 PaymentAppChargeAttemptUpdateRequest {\n");
sb.Append(" ChargeAttemptId: ").Append(ChargeAttemptId).Append("\n");
sb.Append(" EndUserFailureMessage: ").Append(EndUserFailureMessage).Append("\n");
sb.Append(" FailureReasonId: ").Append(FailureReasonId).Append("\n");
sb.Append(" Reference: ").Append(Reference).Append("\n");
sb.Append(" TargetState: ").Append(TargetState).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 JsonConvert.SerializeObject(this, Formatting.Indented, new JsonSerializerSettings { NullValueHandling = NullValueHandling.Ignore });
}

/// <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 PaymentAppChargeAttemptUpdateRequest);
}

/// <summary>
/// Returns true if PaymentAppChargeAttemptUpdateRequest instances are equal
/// </summary>
/// <param name="input">Instance of PaymentAppChargeAttemptUpdateRequest to be compared</param>
/// <returns>Boolean</returns>
public bool Equals(PaymentAppChargeAttemptUpdateRequest input)
{
if (input == null)
return false;

return
(
this.ChargeAttemptId == input.ChargeAttemptId ||
(this.ChargeAttemptId != null &&
this.ChargeAttemptId.Equals(input.ChargeAttemptId))
) &&
(
this.EndUserFailureMessage == input.EndUserFailureMessage ||
(this.EndUserFailureMessage != null &&
this.EndUserFailureMessage.Equals(input.EndUserFailureMessage))
) &&
(
this.FailureReasonId == input.FailureReasonId ||
(this.FailureReasonId != null &&
this.FailureReasonId.Equals(input.FailureReasonId))
) &&
(
this.Reference == input.Reference ||
(this.Reference != null &&
this.Reference.Equals(input.Reference))
) &&
(
this.TargetState == input.TargetState ||
(this.TargetState != null &&
this.TargetState.Equals(input.TargetState))
);
}

/// <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.ChargeAttemptId != null)
hashCode = hashCode * 59 + this.ChargeAttemptId.GetHashCode();
if (this.EndUserFailureMessage != null)
hashCode = hashCode * 59 + this.EndUserFailureMessage.GetHashCode();
if (this.FailureReasonId != null)
hashCode = hashCode * 59 + this.FailureReasonId.GetHashCode();
if (this.Reference != null)
hashCode = hashCode * 59 + this.Reference.GetHashCode();
if (this.TargetState != null)
hashCode = hashCode * 59 + this.TargetState.GetHashCode();
return hashCode;
}
}

}

}
Loading

0 comments on commit fd0cbd5

Please sign in to comment.