Development Environment    

Using the MATLAB HDF Utility API

In addition to the standard HDF APIs, listed in HDF APIs Supported by MATLAB, MATLAB supports utility functions that are designed to make using HDF in the MATLAB environment easier.

For example, the MATLAB utility API includes a function, MLlistinfo, that you can use to view all types of open HDF identifiers, such as HDF SD file identifiers. MATLAB updates these lists whenever HDF identifiers are created or closed.

This code obtains a list of all open HDF file and data set identifiers, using the MLlistinfo function. In this example, only two identifiers are open:

Closing All Open HDF Identifiers

To close all open HDF identifiers in a single call, use the MLcloseall function. This call closes all open HDF identifiers:


  Including Metadata in an HDF File Getting More Information About HDF