/// <summary> /// Given a position in the block, returns the corresponding transaction. /// </summary> /// <param name="n"> Zero-based index </param> /// <returns> Full transaction object </returns> public ITransaction GetNthTransaction(UInt64 n) { // return new Transaction(BlockNative.kth_chain_block_transaction_nth(nativeInstance_, (UIntPtr)n), false); var nativeTransactionList = BlockNative.kth_chain_block_transactions(nativeInstance_); return(new Transaction(TransactionListNative.kth_chain_transaction_list_nth(nativeTransactionList, n), false)); }
protected override void DestroyNativeList() { TransactionListNative.kth_chain_transaction_list_destruct(NativeInstance); }
protected override void AddElement(Transaction element) { TransactionListNative.kth_chain_transaction_list_push_back(NativeInstance, element.NativeInstance); }
protected override UInt64 GetCount() { return(TransactionListNative.kth_chain_transaction_list_count(NativeInstance)); }
protected override Transaction GetNthNativeElement(UInt64 n) { return(new Transaction(TransactionListNative.kth_chain_transaction_list_nth(NativeInstance, n), false)); }
protected override IntPtr CreateNativeList() { return(TransactionListNative.kth_chain_transaction_list_construct_default()); }