TypedPointer: An instance of a native pointer and its data type

TypedPointerR Documentation

An instance of a native pointer and its data type

Description

This represents an instance of a pointer (not a generic, reusable type). We have the address in memory for the pointer value and also the type of data structure to which it points.

Usage

typedPointer(ptr, elType, obj = new("TypedPointer"))

Arguments

ptr

the value of this pointer, i.e. the location in memory to which it points. This must be an externalptr.

elType

the type of the data to which the pointer ptr points. This must be an instance of FFIType-class

obj

an instance of the class to return. Generally this will not be specified by the caller. It is provided as a parameter so that one can create subclasses and then use this contructor for these.

Value

The function typedPointer returns the updated obj, typically the default class TypedPointer.

Author(s)

Duncan Temple Lang

See Also

FFIType-class for other classes and types.


omegahat/Rffi documentation built on Nov. 29, 2023, 12:48 a.m.