/// <summary> /// Initializes a new instance of the <see cref="BlockSyncer"/> class. /// </summary> public BlockSyncer(NakoApplication application, NakoConfiguration config, ISyncOperations syncOperations, SyncConnection syncConnection, Tracer tracer) : base(application, config, tracer) { this.tracer = tracer; this.syncConnection = syncConnection; this.syncOperations = syncOperations; this.config = config; }
/// <summary> /// Initializes a new instance of the <see cref="Notifier"/> class. /// </summary> public Notifier(NakoApplication application, NakoConfiguration config, Tracer tracer, IStorage storage) : base(application, config, tracer) { this.configuration = config; this.tracer = tracer; this.storage = storage; this.client = new Lazy <HttpClient>(() => new HttpClient(new HttpClientHandler { ServerCertificateCustomValidationCallback = (sender, certificate, chain, errors) => errors == SslPolicyErrors.None || errors == SslPolicyErrors.RemoteCertificateNameMismatch })); }
//// This code configures Web API. The ApiServer class is specified as a type //// parameter in the WebApp.Start method. public ApiServer(NakoApplication nakoApplication, NakoConfiguration nakoConfiguration, Tracer tracer) { this.configuration = nakoConfiguration; this.tracer = tracer; this.application = nakoApplication; }
/// <summary> /// Initializes a new instance of the <see cref="TaskRunner{T}"/> class. /// </summary> protected TaskRunner(NakoApplication application, NakoConfiguration config, Tracer tracer) : base(application, config, tracer) { this.Queue = new ConcurrentQueue <T>(); }
/// <summary> /// Initializes a new instance of the <see cref="BlockStore"/> class. /// </summary> public BlockStore(NakoApplication application, NakoConfiguration config, Tracer tracer, IStorageOperations storageOperations) : base(application, config, tracer) { this.storageOperations = storageOperations; this.tracer = tracer; }
/// <summary> /// Initializes a new instance of the <see cref="TaskRunner"/> class. /// </summary> protected TaskRunner(NakoApplication application, NakoConfiguration configuration, Tracer tracer) { this.tracer = tracer; this.application = application; this.Delay = TimeSpan.FromSeconds(configuration.SyncInterval); }