Example #1
0
        public RestApiService(IClient client, IContentConverterService contentConverterService)
        {
            if (client is null)
            {
                throw new ArgumentNullException(nameof(client));
            }

            Converter  = contentConverterService ?? throw new ArgumentNullException(nameof(contentConverterService));
            RestClient = new RestClient()
            {
                BaseUrl       = client.BaseUri,
                Authenticator = client.Authenticator,
            };
        }
Example #2
0
 public AuthenticationService(IRestApiService apiService, IContentConverterService converter)
 {
     Converter  = converter ?? throw new ArgumentNullException(nameof(converter));
     ApiService = apiService ?? throw new ArgumentNullException(nameof(apiService));
 }
 public RepositoryService(IRestApiService apiService, IContentConverterService converter, GuardService guard)
 {
     Converter  = converter ?? throw new ArgumentNullException(nameof(converter));
     ApiService = apiService ?? throw new ArgumentNullException(nameof(apiService));
     Guard      = guard ?? throw new ArgumentNullException(nameof(guard));
 }