コード例 #1
0
 /// <summary>Sets the api key for further use.</summary>
 /// <param name="apiKey">The api key.</param>
 public void SetApiKey(string apiKey)
 {
     if (KeyUtilities.IsValid(apiKey))
     {
         this.V2Authorized = new FactoryForV2Authorized(this.CreateAuthorizedServiceClient(apiKey));
     }
     else
     {
         throw new ArgumentException("The api key didn't have the required format.", "apiKey");
     }
 }
コード例 #2
0
ファイル: GW2Bootstrapper.cs プロジェクト: tigerbytes/GW2.NET
 /// <summary>Sets the api key for further use.</summary>
 /// <param name="apiKey">The api key.</param>
 public void SetApiKey(string apiKey)
 {
     if (KeyUtilities.IsValid(apiKey))
     {
         this.V2Authorized = new FactoryForV2Authorized(this.CreateAuthorizedServiceClient(apiKey));
     }
     else
     {
         throw new ArgumentException("The api key didn't have the required format.", "apiKey");
     }
 }