MLGetInteger32Array (C Function)
MLGetInteger32Array has been replaced by WSGetInteger32Array.
int MLGetInteger32Array(MLINK link,int **a,int **dims,char ***heads,int *d)
gets an array of 32-bit integers from the MathLink connection specified by link, storing the array in a, its dimensions in dims and its depth in d.
Details

- The array a is laid out in memory like a C array declared as
.
- heads gives a list of character strings corresponding to the names of symbols that appear as heads at each level in the array.
- MLGetInteger32Array() allocates memory which must be disowned by calling MLReleaseInteger32Array(). If MLGetInteger32Array() fails and the function's return value indicates an error, do not call MLReleaseInteger32Array()on the contents of a.
- MLGetInteger32Array() returns immutable data.
- MLGetInteger32Array() returns 0 in the event of an error, and a nonzero value if the function succeeds.
- Use MLError() to retrieve the error code if MLGetInteger32Array() fails.
- MLGetInteger32Array() is declared in the MathLink header file mathlink.h.
Examples
Basic Examples (1)
#include "mathlink.h"
/* read an array of 32-bit integers from a link */
void f(MLINK lp)
{
int *data;
int *dims;
char **heads;
int d;
if(! MLGetInteger32Array(lp, &data, &dims, &heads, &d))
{
/* unable to read the array of integers from lp */
return;
}
/* ... */
MLReleaseInteger32Array(lp, data, dims, heads, d);
}