/// <summary> /// Initializes a new instance of the <see cref="StaticApi"/> class /// using Configuration object /// </summary> /// <param name="configuration">An instance of Configuration</param> /// <returns></returns> public StaticApi(BJR.Client.Configuration configuration = null) { if (configuration == null) // use the default one in Configuration { this.Configuration = BJR.Client.Configuration.Default; } else { this.Configuration = configuration; } ExceptionFactory = BJR.Client.Configuration.DefaultExceptionFactory; }
/// <summary> /// Initializes a new instance of the <see cref="UsersApi"/> class /// using Configuration object /// </summary> /// <param name="configuration">An instance of Configuration</param> /// <returns></returns> public UsersApi(BJR.Client.Configuration configuration) { if (configuration == null) { throw new ArgumentNullException("configuration"); } this.Configuration = BJR.Client.Configuration.MergeConfigurations( BJR.Client.GlobalConfiguration.Instance, configuration ); this.Client = new BJR.Client.ApiClient(this.Configuration.BasePath); this.AsynchronousClient = new BJR.Client.ApiClient(this.Configuration.BasePath); ExceptionFactory = BJR.Client.Configuration.DefaultExceptionFactory; }