示例#1
0
 def __init__(self,
              repository: Repository,
              p2p_interface: P2PInterface,
              async_block_factory=get_block_factory()):
     self.repository = repository
     self.p2p = p2p_interface
     self.block_factory = async_block_factory
     self.loop = asyncio.get_event_loop()
     self.delayer = async_delayed_task
示例#2
0
 def __init__(self, electrod, p2p, cache: CacheAgent=None, repository=None,
              loop=asyncio.get_event_loop(), context=None):
     self.cache = cache
     self.p2p = p2p
     self.electrod = electrod
     self.repository = repository
     self.loop = loop
     self._last_estimatefee = None
     self.block_factory = get_block_factory()
     self.context = context
 def __init__(
         self,
         repository: Repository,
         p2p_interface: P2PInterface,
         async_block_factory=get_block_factory(),
 ):
     self.repository = repository
     self.p2p = p2p_interface
     self.block_factory = async_block_factory
     self.loop = asyncio.get_event_loop()
     self.delayer = async_delayed_task
     self.on_transaction_callbacks = []
     self.on_transaction_hash_callbacks = []
     self.on_new_block_callbacks = []
示例#4
0
 def __init__(self,
              electrod,
              p2p,
              cache_agent: CacheAgent = None,
              repository=None,
              loop=asyncio.get_event_loop(),
              context=None,
              fallback_non_segwit_blocks=False):
     self.cache_agent = cache_agent
     self.p2p = p2p
     self.electrod = electrod
     self.repository = repository
     self.loop = loop
     self._last_estimatefee = None
     self.block_factory = get_block_factory()
     self.context = context
     self._fallback_non_segwit_blocks = fallback_non_segwit_blocks
     self._expected_data = {'txids': []}