System.TMarshal

From RAD Studio API Documentation
Jump to: navigation, search

System.TObjectTMarshal

Delphi

TMarshal = class(TObject)

Properties

Type Visibility Source Unit Parent
class public System.pas System System

Description

TMarshal is a class that facilitates working with memory buffers.

TMarshal is a low-level API for marshalling arguments. It copies data in and out of buffers without dealing directly with pointers.

TMarshal introduces many functions and procedures to:

  • Write a number of bytes into blocks of memory referenced by wrapped pointers.
  • Read a number of bytes from blocks of memory referenced by wrapped pointers.
  • Allocate memory of a certain size and return it as a wrapped pointer.
  • Free memory referenced by a wrapped pointer.

See Also