MOA Developer's Guide
MOA Interfaces | MOA Methods | MOA Types and Misc API

IMoaCalloc

Interface ID: IID_IMoaCalloc
Pointer type: PIMoaCalloc
Inheritance: IMoaUnknown
Header file: moaxtra.h

Description

This standard MOA callback interface is implemented by the every MOA application for the use of Xtras. It provides methods for use in allocating fixed memory. All MOA objects have an instance variable, pCalloc, that refers to this interface.

Methods

NRAlloc()
NRFree()

NRAlloc()

Syntax

NRAlloc(MoaUlong cb)

Parameters

cb
Integer representing the size of the memory block to allocate

Returns

Pointer to allocated memory

Description

Returns a fixed block of memory at least cb bytes in size. The memory is zeroed out. If the request cannot be satisfied, NULL is returned.

NRFree()

Syntax

NRFree(PMoaVoid pv)

Parameters

pv
Pointer to the allocated memory block

Returns

void

Description

Frees memory previously allocated with the NRAlloc() method.

Copyright © 1995-2008 Adobe Macromedia Software LLC, Inc.