[csharp] header problem due to static method for adding header
This commit is contained in:
lunat
2016-07-19 12:45:52 +02:00
parent e6803aed97
commit 41bab483e0

View File

@@ -164,11 +164,23 @@ namespace {{packageName}}.Client
}
/// <summary>
/// Add Api Key.
/// Add Api Key Header.
/// </summary>
/// <param name="key">Api Key name.</param>
/// <param name="value">Api Key value.</param>
/// <returns></returns>
public void AddApiKey(string key, string value)
{
if (ApiKey.ContainsKey(key))
ApiKey.Remove(key);
ApiKey.Add(key, value);
}
/// <summary>
/// Sets the API key prefix.
/// </summary>
/// <param name="key">Api Key name.</param>
/// <param name="value">Api Key value.</param>
public void AddApiKeyPrefix(string key, string value)
{
if (ApiKeyPrefix.ContainsKey(key))
@@ -176,6 +188,7 @@ namespace {{packageName}}.Client
ApiKeyPrefix.Add(key, value);
}
/// <summary>
/// Gets or sets the HTTP user agent.
/// </summary>