示例#1
0
 public BlockStoreFeature(
     ConcurrentChain chain,
     IConnectionManager connectionManager,
     Signals.Signals signals,
     IBlockRepository blockRepository,
     IBlockStoreCache blockStoreCache,
     StoreBlockPuller blockPuller,
     BlockStoreLoop blockStoreLoop,
     BlockStoreManager blockStoreManager,
     BlockStoreSignaled blockStoreSignaled,
     INodeLifetime nodeLifetime,
     NodeSettings nodeSettings,
     ILoggerFactory loggerFactory,
     StoreSettings storeSettings,
     string name = "BlockStore")
 {
     this.name               = name;
     this.chain              = chain;
     this.signals            = signals;
     this.blockRepository    = blockRepository;
     this.blockStoreCache    = blockStoreCache;
     this.blockPuller        = blockPuller;
     this.blockStoreLoop     = blockStoreLoop;
     this.blockStoreManager  = blockStoreManager;
     this.blockStoreSignaled = blockStoreSignaled;
     this.nodeLifetime       = nodeLifetime;
     this.connectionManager  = connectionManager;
     this.nodeSettings       = nodeSettings;
     this.logger             = loggerFactory.CreateLogger(this.GetType().FullName);
     this.loggerFactory      = loggerFactory;
     this.storeSettings      = storeSettings;
 }
示例#2
0
        public BlockStoreSignaled(
            BlockStoreLoop blockStoreLoop,
            ConcurrentChain chain,
            StoreSettings storeSettings,
            IChainState chainState,
            IConnectionManager connection,
            INodeLifetime nodeLifetime,
            ILoggerFactory loggerFactory,
            IBlockStoreCache blockStoreCache)
        {
            this.blockStoreLoop  = blockStoreLoop;
            this.chain           = chain;
            this.chainState      = chainState;
            this.connection      = connection;
            this.nodeLifetime    = nodeLifetime;
            this.logger          = loggerFactory.CreateLogger(this.GetType().FullName);
            this.storeSettings   = storeSettings;
            this.blockStoreCache = blockStoreCache;

            this.blocksToAnnounce = new AsyncQueue <ChainedBlock>();
            this.dequeueLoopTask  = this.DequeueContinuouslyAsync();
        }
示例#3
0
 public BlockStoreManager(IBlockRepository blockRepository, IChainState chainState, BlockStoreLoop blockStoreLoop)
 {
     this.BlockRepository = blockRepository;
     this.ChainState      = chainState;
     this.BlockStoreLoop  = blockStoreLoop;
 }