pub fn load_txn_with_blockhashlookup(
        &self,
        txid: &Txid,
        blockhash: Option<BlockHash>,
    ) -> Result<Transaction> {
        if let Some(tx) = self.tracker.read().unwrap().get_txn(&txid) {
            return Ok(tx);
        }
        let hash: Option<BlockHash> = match blockhash {
            Some(hash) => Some(hash),
            None => match self.lookup_confirmed_blockhash(txid, None) {
                Ok(hash) => hash,
                Err(_) => None,
            },
        };
        self.load_txn(txid, hash)
    }
/// Load transaction by ID, attempt to lookup blockhash locally.
Load transaction by ID, attempt to lookup blockhash locally.
Load transaction by ID attempt to lookup blockhash locally .
pub fn load_txn_with_blockhashlookup(
        &self,
        txid: &Txid,
        blockhash: Option<BlockHash>,
    ) -> Result<Transaction> {
        if let Some(tx) = self.tracker.read().unwrap().get_txn(&txid) {
            return Ok(tx);
        }
        let hash: Option<BlockHash> = match blockhash {
            Some(hash) => Some(hash),
            None => match self.lookup_confirmed_blockhash(txid, None) {
                Ok(hash) => hash,
                Err(_) => None,
            },
        };
        self.load_txn(txid, hash)
    }
pub fn load_txn_with_blockhashlookup ( & self , txid : & Txid , blockhash : Option < BlockHash > , ) -> Result < Transaction > { if let Some ( tx ) = self . tracker . read ( ) . unwrap ( ) . get_txn ( & txid ) { return Ok ( tx ) ; } let hash : Option < BlockHash > = match blockhash { Some ( hash ) => Some ( hash ) , None => match self . lookup_confirmed_blockhash ( txid , None ) { Ok ( hash ) => hash , Err ( _ ) => None , } , } ; self . load_txn ( txid , hash ) }
Load transaction by ID, attempt to lookup blockhash locally.
Load transaction by ID attempt to lookup blockhash locally .
&self
txid
&Txid
blockhash
Option<BlockHash>
&self
txid
&Txid
blockhash
Option<BlockHash>