/// <summary> /// Gets the transactions that are unconfirmed using getrawmempool. /// This is efficient when many transaction ids are provided. /// </summary> public static async Task <IEnumerable <uint256> > GetUnconfirmedAsync(this IRPCClient rpc, IEnumerable <uint256> transactionHashes) { uint256[] unconfirmedTransactionHashes = await rpc.GetRawMempoolAsync(); // If there are common elements, then there's unconfirmed. return(transactionHashes.Intersect(unconfirmedTransactionHashes)); }