Array header information only
Pointer to a newly allocated mxArray structure representing header information for the next mxArray from the MAT-file pointed to by mfp. The function returns the name of the mxArray in name.
matGetNextVariableInfo returns NULL in C (0 in Fortran) when the end-of-file is reached or if there is an error condition. In C, use feof and ferror from the Standard C Library to determine status.
matGetNextVariableInfo loads only the array header information, including everything except pr, pi, ir, and jc, from the current file offset.
If pr, pi, ir, and jc are nonzero values when loaded with matGetVariable, matGetNextVariableInfo sets them to -1 instead. These headers are for informational use only. Never pass this data back to the MATLAB® workspace or save it to MAT-files.
Use mxDestroyArray to destroy the mxArray created by this routine when you are finished with it.
The order of variables returned from successive calls to matGetNextVariableInfo is not guaranteed to be the same order in which the variables were written.