Skip to content

Commit

Permalink
Merge pull request #270 from digipost/add-xml-comments-for-proxy-in-c…
Browse files Browse the repository at this point in the history
…lient-config

Adds description for proxy and credential args in client config.
  • Loading branch information
Simen Støa authored Feb 21, 2020
2 parents 71b8e88 + bf219d5 commit 5b346f8
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions Digipost.Signature.Api.Client.Core/ClientConfiguration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@ public class ClientConfiguration : IAsiceConfiguration
/// If set, it will be used for all <see cref="ISignatureJob">SignatureJobs</see> created without
/// a <see cref="Sender" />.
/// </param>
/// <param name="proxy">
/// If set, the proxy will be used for all requests. Remember to set <see cref="Credential" /> as well.
/// </param>
/// <param name="credential">
/// Will be used if both this and <see cref="WebProxy" /> is set.
/// </param>
public ClientConfiguration(Environment environment, string certificateThumbprint, Sender globalSender = null, WebProxy proxy = null, NetworkCredential credential = null)
: this(environment, CertificateUtility.SenderCertificate(certificateThumbprint), globalSender, proxy, credential)
{
Expand All @@ -31,6 +37,12 @@ public ClientConfiguration(Environment environment, string certificateThumbprint
/// If set, it will be used for all <see cref="ISignatureJob">SignatureJobs</see> created without a
/// <see cref="Sender" />.
/// </param>
/// <param name="proxy">
/// If set, the proxy will be used for all requests. Remember to set <see cref="Credential" /> as well.
/// </param>
/// <param name="credential">
/// Will be used if both this and <see cref="WebProxy" /> is set.
/// </param>
public ClientConfiguration(Environment environment, X509Certificate2 certificate, Sender globalSender = null, WebProxy proxy = null, NetworkCredential credential = null)
{
Environment = environment;
Expand All @@ -50,8 +62,14 @@ public ClientConfiguration(Environment environment, X509Certificate2 certificate

public X509Certificate2 Certificate { get; set; }

/// <summary>
/// If set, the proxy will be used for all requests. Remember to set <see cref="Credential" /> as well.
/// </summary>
public WebProxy WebProxy { get; set; }

/// <summary>
/// Will be used if both this and <see cref="WebProxy" /> is set.
/// </summary>
public NetworkCredential Credential { get; set; }

public int HttpClientTimeoutInMilliseconds { get; set; } = 10000;
Expand Down

0 comments on commit 5b346f8

Please sign in to comment.