compare_memory_blockT_compare_memory_blockCompareMemoryBlockCompareMemoryBlockcompare_memory_block (Operator)

Name

compare_memory_blockT_compare_memory_blockCompareMemoryBlockCompareMemoryBlockcompare_memory_block — Compare contents of memory blocks regarding equality.

Signature

compare_memory_block( : : MemoryBlocks1, MemoryBlocks2 : IsEqual)

Herror T_compare_memory_block(const Htuple MemoryBlocks1, const Htuple MemoryBlocks2, Htuple* IsEqual)

void CompareMemoryBlock(const HTuple& MemoryBlocks1, const HTuple& MemoryBlocks2, HTuple* IsEqual)

static void HOperatorSet.CompareMemoryBlock(HTuple memoryBlocks1, HTuple memoryBlocks2, out HTuple isEqual)

def compare_memory_block(memory_blocks_1: MaybeSequence[HHandle], memory_blocks_2: MaybeSequence[HHandle]) -> int

Description

The operator compare_memory_blockcompare_memory_blockCompareMemoryBlockCompareMemoryBlockcompare_memory_block compares the contents of two memory block tuples and returns the comparison result in IsEqualIsEqualIsEqualisEqualis_equal. Therefore, each memory block in the tuple MemoryBlocks1MemoryBlocks1MemoryBlocks1memoryBlocks1memory_blocks_1 is compared to the respective block in the tuple MemoryBlocks2MemoryBlocks2MemoryBlocks2memoryBlocks2memory_blocks_2 with the same index. IsEqualIsEqualIsEqualisEqualis_equal is set to TRUE if the number of elements of the two tuples matches and if the length and byte content of each pair of memory blocks coincides, otherwise to FALSE.

Attention

Note that compare_memory_blockcompare_memory_blockCompareMemoryBlockCompareMemoryBlockcompare_memory_block compares the memory blocks regarding their actual byte content, not their location in memory.

Execution Information

Parameters

MemoryBlocks1MemoryBlocks1MemoryBlocks1memoryBlocks1memory_blocks_1 (input_control)  memory_block(-array) HMemoryBlock, HTupleMaybeSequence[HHandle]HTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Tuple of reference memory blocks.

MemoryBlocks2MemoryBlocks2MemoryBlocks2memoryBlocks2memory_blocks_2 (input_control)  memory_block(-array) HMemoryBlock, HTupleMaybeSequence[HHandle]HTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Tuple of test memory blocks.

IsEqualIsEqualIsEqualisEqualis_equal (output_control)  integer HTupleintHTupleHtuple (integer) (int / long) (Hlong) (Hlong)

Boolean result value.

Result

The operator compare_memory_blockcompare_memory_blockCompareMemoryBlockCompareMemoryBlockcompare_memory_block returns the value 2 ( H_MSG_TRUE) if the passed handles are valid. Otherwise, an exception is raised.

Possible Predecessors

create_memory_block_externcreate_memory_block_externCreateMemoryBlockExternCreateMemoryBlockExterncreate_memory_block_extern, create_memory_block_extern_copycreate_memory_block_extern_copyCreateMemoryBlockExternCopyCreateMemoryBlockExternCopycreate_memory_block_extern_copy, image_to_memory_blockimage_to_memory_blockImageToMemoryBlockImageToMemoryBlockimage_to_memory_block, read_memory_blockread_memory_blockReadMemoryBlockReadMemoryBlockread_memory_block

Module

Foundation