/// <summary> /// Initializes a new instance of the <see cref="QueryApi"/> class /// using Configuration object /// </summary> /// <param name="configuration">An instance of Configuration</param> /// <returns></returns> public QueryApi(Foobar2000.RESTClient.Client.Configuration configuration = null) { if (configuration == null) // use the default one in Configuration { this.Configuration = Foobar2000.RESTClient.Client.Configuration.Default; } else { this.Configuration = configuration; } ExceptionFactory = Foobar2000.RESTClient.Client.Configuration.DefaultExceptionFactory; }
/// <summary> /// Initializes a new instance of the <see cref="ApiClient" /> class /// with default base path (http://localhost:8880/api). /// </summary> /// <param name="config">An instance of Configuration.</param> public ApiClient(Configuration config) { Configuration = config ?? Foobar2000.RESTClient.Client.Configuration.Default; RestClient = new RestClient(Configuration.BasePath); }