コード例 #1
0
 public BlockReceiver(Context context, NodeConnectionService nodeConnectionService,
                      BlockSyncHub blockSyncHub, ChainService chainSyncService, ILoggerFactory loggerFactory, WalletWorker walletWorker)
     : base(context)
 {
     this.nodeConnectionService = nodeConnectionService;
     this.chainIndex            = context.ChainIndex;
     this.chainSyncService      = chainSyncService;
     this.walletWorker          = walletWorker;
     this.logger       = loggerFactory.CreateLogger <BlockReceiver>();
     this.orphanBlocks = new Dictionary <uint256, OrphanBlock>();
     this.BlockSyncHub = blockSyncHub;
 }
コード例 #2
0
 public BlockMiner(Context context, NodeConnectionService nodeConnectionService,
                   BlockSyncHub blockSyncHub, ChainService chainSyncService, WalletService walletService, WalletWorker walletWorker,
                   BlockReceiver blockReceiver, MinerService minerService) : base(context)
 {
     this.nodeConnectionService       = nodeConnectionService;
     this.chainIndex                  = context.ChainIndex;
     this.chainSyncService            = chainSyncService;
     this.walletService               = walletService;
     this.walletWorker                = walletWorker;
     this.blockReceiver               = blockReceiver;
     this.minerService                = minerService;
     this.BlockSyncHub                = blockSyncHub;
     this.minerSleep                  = 500; // GetArg("-minersleep", 500);
     this.LastCoinStakeSearchInterval = 0;
     this.LastCoinStakeSearchTime     = DateTime.UtcNow.ToUnixTimestamp();
 }
コード例 #3
0
ファイル: BlockSender.cs プロジェクト: nsavga/NStaker
 public BlockSender(Context context, BlockSyncHub blockSyncHub) : base(context)
 {
     this.BlockSyncHub = blockSyncHub;
 }
コード例 #4
0
 public MinerService(Context context, BlockSyncHub blockSyncHub) : base(context)
 {
     this.blockSyncHub = blockSyncHub;
     this.MinedBlocks  = new ConcurrentDictionary <ChainedBlock, Block>();
 }
コード例 #5
0
 public GetDataReceiver(Context context, BlockSyncHub blockSyncHub, MinerService minerService) : base(context)
 {
     this.minerService = minerService;
     this.BlockSyncHub = blockSyncHub;
     this.chainIndex   = context.ChainIndex;
 }