forked from laniatech/Checkout-NET-SDK
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
67 changed files
with
209 additions
and
271 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
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,26 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
|
||
<configuration> | ||
<packageSources> | ||
<clear /> | ||
<add key="nuget" | ||
value="https://api.nuget.org/v3/index.json" | ||
protocolVersion="3" /> | ||
<add key="json-converter-source-generator" | ||
value="https://f.feedz.io/aviationexam/json-converter-source-generator/nuget/index.json" | ||
protocolVersion="3" /> | ||
</packageSources> | ||
<packageSourceMapping> | ||
<!-- key value for <packageSource> should match key values from <packageSources> element --> | ||
|
||
<!-- | ||
<packageSource key="json-converter-source-generator"> | ||
<package pattern="Aviationexam.GeneratedJsonConverters.SourceGenerator" /> | ||
</packageSource> | ||
--> | ||
|
||
<packageSource key="nuget"> | ||
<package pattern="*" /> | ||
</packageSource> | ||
</packageSourceMapping> | ||
</configuration> |
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
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
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
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
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
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
61 changes: 0 additions & 61 deletions
61
src/PayPal.Sdk.Checkout/Core/Converters/JsonStringEnumConverter.cs
This file was deleted.
Oops, something went wrong.
23 changes: 0 additions & 23 deletions
23
src/PayPal.Sdk.Checkout/Core/Converters/JsonStringEnumConverterFactory.cs
This file was deleted.
Oops, something went wrong.
22 changes: 0 additions & 22 deletions
22
...Pal.Sdk.Checkout/Core/MessageSerializers/JsonSerializerOptionsForJsonSerializerContext.cs
This file was deleted.
Oops, something went wrong.
25 changes: 0 additions & 25 deletions
25
src/PayPal.Sdk.Checkout/Core/MessageSerializers/PayPalAuthenticationJsonSerializerContext.cs
This file was deleted.
Oops, something went wrong.
39 changes: 39 additions & 0 deletions
39
src/PayPal.Sdk.Checkout/Core/MessageSerializers/PayPalJsonSerializerContext.cs
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,39 @@ | ||
using System.Collections.Generic; | ||
using System.Text.Json.Serialization; | ||
using PayPalAuthentication = PayPal.Sdk.Checkout.Authentication; | ||
using PayPalOrders = PayPal.Sdk.Checkout.Orders; | ||
using PayPalPayments = PayPal.Sdk.Checkout.Payments; | ||
|
||
namespace PayPal.Sdk.Checkout.Core.MessageSerializers; | ||
|
||
[JsonSourceGenerationOptions( | ||
WriteIndented = true, | ||
PropertyNamingPolicy = JsonKnownNamingPolicy.CamelCase, | ||
GenerationMode = JsonSourceGenerationMode.Default | ||
)] | ||
[JsonSerializable(typeof(PayPalAuthentication.AccessToken))] | ||
[JsonSerializable(typeof(PayPalAuthentication.RefreshToken))] | ||
[JsonSerializable(typeof(PayPalOrders.AuthorizeRequest))] | ||
[JsonSerializable(typeof(IReadOnlyCollection<PayPalOrders.StringPatch>))] | ||
[JsonSerializable(typeof(PayPalOrders.Order))] | ||
[JsonSerializable(typeof(PayPalOrders.OrderActionRequest))] | ||
[JsonSerializable(typeof(PayPalOrders.OrderCaptureRequest))] | ||
[JsonSerializable(typeof(PayPalOrders.OrderRequest))] | ||
[JsonSerializable(typeof(PayPalPayments.CaptureRequest))] | ||
[JsonSerializable(typeof(PayPalPayments.PaymentAuthorization))] | ||
[JsonSerializable(typeof(PayPalPayments.PaymentCapture))] | ||
[JsonSerializable(typeof(PayPalPayments.PaymentRefund))] | ||
[JsonSerializable(typeof(PayPalPayments.ReauthorizeRequest))] | ||
[JsonSerializable(typeof(PayPalPayments.RefundRequest))] | ||
internal partial class PayPalJsonSerializerContext : JsonSerializerContext | ||
{ | ||
static PayPalJsonSerializerContext() | ||
{ | ||
// register generated converters to options | ||
UseEnumConverters(s_defaultOptions.Converters); | ||
|
||
#if NET8_0_OR_GREATER | ||
Default = new PayPalJsonSerializerContext(new System.Text.Json.JsonSerializerOptions(s_defaultOptions)); | ||
#endif | ||
} | ||
} |
30 changes: 0 additions & 30 deletions
30
src/PayPal.Sdk.Checkout/Core/MessageSerializers/PayPalOrderJsonSerializerContext.cs
This file was deleted.
Oops, something went wrong.
29 changes: 0 additions & 29 deletions
29
src/PayPal.Sdk.Checkout/Core/MessageSerializers/PayPalPaymentsJsonSerializerContext.cs
This file was deleted.
Oops, something went wrong.
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
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
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
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.