| ||
Home | Modules | Examples |
CCMIOBuffer | |
Buffers reading and writing. | |
void | CCMIOSetBufferSize (int n) |
Sets the buffer size (in elements) for new buffers. | |
CCMIOError | CCMIOCreateBuffer (CCMIOError *err, CCMIONode node, CCMIOBufferType which, CCMIOBuffer *buff) |
Creates a buffer. | |
CCMIOError | CCMIODestroyBuffer (CCMIOError *err, CCMIOBuffer buff) |
Destroys the buffer (even if an err is not kCCMIONoErr). | |
CCMIOError | CCMIOBufferReadDataPoint (CCMIOError *err, CCMIOBuffer buff, void *data,...) |
Reads one data point. | |
CCMIOError | CCMIOvBufferReadDataPoint (CCMIOError *err, CCMIOBuffer buff, void *data, va_list args) |
Sets the buffer size (in elements) for new buffers. | |
CCMIOError | CCMIOBufferWriteNextDataPoint (CCMIOError *err, CCMIOBuffer buff, int n, void *data) |
Reads one data point. | |
CCMIOError | CCMIOBufferWriteDataPoint (CCMIOError *err, CCMIOBuffer buff, void *data,...) |
Writes one data point to the buffer, which is written when the buffer is closed. | |
CCMIOError | CCMIOvBufferWriteDataPoint (CCMIOError *err, CCMIOBuffer buff, void *data, va_list args) |
Sets the buffer size (in elements) for new buffers. | |
CCMIOError | CCMIOBufferGetNode (CCMIOError *err, CCMIOBuffer buff, CCMIONode *node) |
Returns the node associated with the buffer. | |
Core functions | |
The minimal set of functions. | |
CCMIOError | CCMIOOpen (const char *filename, CCMIOIOType mode, CCMIONode *root) |
Opens the data file. | |
CCMIOError | CCMIOClose (CCMIONode root) |
Closes the data file. | |
CCMIOError | CCMIOGetNode (CCMIOError *err, CCMIONode parent, const char *path, CCMIONode *node) |
Finds a node, given a node path. | |
CCMIOError | CCMIOGetNumberOfChildren (CCMIOError *err, CCMIONode parent, int *n) |
Returns the number of children in the parent node. | |
CCMIOError | CCMIOGetNextChild (CCMIOError *err, CCMIONode parent, int *n, CCMIONode *child) |
Returns the next child node. | |
CCMIOError | CCMIOGetName (CCMIOError *err, CCMIONode node, char *name) |
Returns the name of the node. | |
CCMIOError | CCMIOSetName (CCMIOError *err, CCMIONode node, const char *name) |
Sets the name of an existing node. | |
CCMIOError | CCMIOGetLabel (CCMIOError *err, CCMIONode node, char *label) |
Returns the label of the node. | |
CCMIOError | CCMIOSetLabel (CCMIOError *err, CCMIONode node, const char *label) |
Sets the label of an existing node. | |
CCMIOError | CCMIOCreateNode (CCMIOError *err, CCMIONode parent, int openDup, const char *name, const char *label, CCMIONode *node) |
Creates a new node. | |
CCMIOError | CCMIOCreateLink (CCMIOError *err, CCMIONode parent, const char *name, const char *filename, const char *destName, CCMIONode *node) |
Creates a new link. | |
CCMIOError | CCMIODeleteNode (CCMIOError *err, CCMIONode node) |
Deletes the node. | |
CCMIOError | CCMIODeleteAllChildren (CCMIOError *err, CCMIONode node) |
Deletes all children of the node, but not the node itself. | |
CCMIOError | CCMIOMoveNode (CCMIOError *err, CCMIONode node, CCMIONode newParent) |
Moves the node underneath newParent. | |
CCMIOError | CCMIOGetDimensions (CCMIOError *err, CCMIONode node, int *nDims, int **dims) |
Returns the number of items in the node's data. | |
CCMIOError | CCMIOGetDataSize (CCMIOError *err, CCMIONode node, unsigned int *bytes) |
Returns the number of bytes of the data. | |
CCMIOError | CCMIOGetDataType (CCMIOError *err, CCMIONode node, CCMIODataType *type) |
Returns the data type for the node. | |
CCMIOError | CCMIOSetDataType (CCMIOError *err, CCMIONode node, CCMIODataType type,...) |
Sets the datatype of the node. | |
CCMIOError | CCMIOvSetDataType (CCMIOError *err, CCMIONode node, CCMIODataType type, va_list args) |
Opens the data file. | |
CCMIOError | CCMIOSetDataTypev (CCMIOError *err, CCMIONode node, CCMIODataType type, int nDims, const int *dims) |
Opens the data file. | |
CCMIOError | CCMIOReadData (CCMIOError *err, CCMIONode node, void *data, CCMIODataType expected, int dimsExpected) |
Returns all the data in the node. | |
CCMIOError | CCMIOReadDataPoint (CCMIOError *err, CCMIONode node, void *data,...) |
Returns one element of data. | |
CCMIOError | CCMIOWriteDataPoint (CCMIOError *err, CCMIONode node, void *data,...) |
Write one element of data. | |
CCMIOError | CCMIOWriteData (CCMIOError *err, CCMIONode node, const void *data) |
Writes the entire node's data. | |
int | CCMIOAreNodesEqual (CCMIONode node1, CCMIONode node2) |
Returns TRUE if node1 == node2, FALSE otherwise. | |
CCMIOError | CCMIOGetRootNode (CCMIOError *err, CCMIONode node, CCMIONode *root) |
Returns the root node, or kCCMIOBadParameterErr if 'node' is not valid. | |
Utility functions | |
Condenses common tasks | |
CCMIOError | CCMIOWriteNodei (CCMIOError *err, CCMIONode parent, const char *name, int value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWriteNodef (CCMIOError *err, CCMIONode parent, const char *name, float value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWriteNoded (CCMIOError *err, CCMIONode parent, const char *name, double value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWriteNodestr (CCMIOError *err, CCMIONode parent, const char *name, const char *value) |
Creates a child node of parent with given name and string value. | |
CCMIOError | CCMIOReadNodei (CCMIOError *err, CCMIONode parent, const char *name, int *value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOReadNodef (CCMIOError *err, CCMIONode parent, const char *name, float *value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOReadNoded (CCMIOError *err, CCMIONode parent, const char *name, double *value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOReadNodestr (CCMIOError *err, CCMIONode parent, const char *name, char **value) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead1i (CCMIOError *err, CCMIONode node, int *data, unsigned int start, unsigned int end) |
Reads the entire contents of the node into the array provided. | |
CCMIOError | CCMIORead1f (CCMIOError *err, CCMIONode node, float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead1d (CCMIOError *err, CCMIONode node, double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead2i (CCMIOError *err, CCMIONode node, int *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead2f (CCMIOError *err, CCMIONode node, float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead2d (CCMIOError *err, CCMIONode node, double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead3i (CCMIOError *err, CCMIONode node, int *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead3f (CCMIOError *err, CCMIONode node, float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIORead3d (CCMIOError *err, CCMIONode node, double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite1i (CCMIOError *err, CCMIONode node, int n, const int *data, unsigned int start, unsigned int end) |
Writes the entire array to the node. | |
CCMIOError | CCMIOWrite1f (CCMIOError *err, CCMIONode node, int n, const float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite1d (CCMIOError *err, CCMIONode node, int n, const double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite2i (CCMIOError *err, CCMIONode node, int x, int y, const int *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite2f (CCMIOError *err, CCMIONode node, int x, int y, const float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite2d (CCMIOError *err, CCMIONode node, int x, int y, const double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite3i (CCMIOError *err, CCMIONode node, int x, int y, int z, const int *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite3f (CCMIOError *err, CCMIONode node, int x, int y, int z, const float *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOWrite3d (CCMIOError *err, CCMIONode node, int x, int y, int z, const double *data, unsigned int start, unsigned int end) |
Creates a child node of parent with given name and value. | |
CCMIOError | CCMIOOldReadf (CCMIOError *err, CCMIONode node, int dimension, int swapDims, float *data, unsigned int start, unsigned int end) |
CCMIOError | CCMIOOldReadd (CCMIOError *err, CCMIONode node, int dimension, int swapDims, double *data, unsigned int start, unsigned int end) |
CCMIOError | CCMIOOldReadi (CCMIOError *err, CCMIONode node, int dimension, int swapDims, int *data, unsigned int start, unsigned int end) |
CCMIOError | CCMIOCopyNode (CCMIOError *err, CCMIONode origNode, CCMIONode copyNode, int copyExists) |
Recursively copies a node. | |
CCMIOError | CCMIOGetNextChildWithLabel (CCMIOError *err, CCMIONode parent, const char *label, int *n, CCMIONode *child) |
Same as CCMIOGetNextChild() (particularly with respect to the parameter n) except that it only returns children with the specified label. | |
CCMIOError | CCMIOCompress (CCMIOError *err, char *filename) |
Compresses the CCMIO file specified. |
In general this API is not necessary as the Intermediate API provides a more useful interface.
|
Returns TRUE if node1 == node2, FALSE otherwise.
|
|
Returns the node associated with the buffer.
|
|
Reads one data point.
|
|
Writes one data point to the buffer, which is written when the buffer is closed. Note that the buffer must be opened as a write buffer. |
|
Reads one data point.
|
|
Closes the data file.
|
|
Compresses the CCMIO file specified. This is occasionally necessary becase ADF (the underlying storage format) leaks disk space; ADF does not completely recover the space when a node is delete or is rewritten with less information. The compression is performed by copying the data to a new ADF file, which is then renamed to the original name. This function will correctly compress CCMIO files, and will probably, but not necessarily, correctly compress ADF files. Also note that this function requires temporary storage equal to the size of the original file in the same filesystem as the original file and should not be called frequently, as it may take a some time.
|
|
Recursively copies a node. origNode and copyNode need not be from the same file.
|
|
Creates a buffer.
|
|
Creates a new link.
|
|
Creates a new node.
|
|
Deletes all children of the node, but not the node itself.
|
|
Deletes the node.
|
|
Destroys the buffer (even if an err is not kCCMIONoErr).
|
|
Returns the number of bytes of the data.
|
|
Returns the data type for the node.
|
|
Returns the number of items in the node's data.
|
|
Returns the label of the node.
|
|
Returns the name of the node.
|
|
Returns the next child node. Note that there is no guarantee that the order of the children will always be the same.
|
|
Same as CCMIOGetNextChild() (particularly with respect to the parameter n) except that it only returns children with the specified label.
|
|
Finds a node, given a node path.
|
|
Returns the number of children in the parent node.
|
|
Returns the root node, or kCCMIOBadParameterErr if 'node' is not valid.
|
|
Moves the node underneath newParent.
|
|
For internal use only.
|
|
For internal use only.
|
|
For internal use only.
|
|
Opens the data file. The file will be created if it does not already exist.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Reads the entire contents of the node into the array provided. The array must be the proper size (which can be determined with CCMIOGetDimensions()). If actual node data is stored in a different format than requested, it will be converted. For multidimensional arrays, the parameter isC specifies whether the data should be returned in Fortran or C order. Since data is stored in Fortran order on disk, returning C order involves an extra copy. |
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Returns all the data in the node.
|
|
Returns one element of data. No datatype checking is performed.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Sets the buffer size (in elements) for new buffers. If n is kCCMIOInfinite, a buffer as big as the node's data will be allocated. |
|
Sets the datatype of the node.
|
|
Opens the data file. The file will be created if it does not already exist.
|
|
Sets the label of an existing node.
|
|
Sets the name of an existing node.
|
|
Sets the buffer size (in elements) for new buffers. If n is kCCMIOInfinite, a buffer as big as the node's data will be allocated. |
|
Sets the buffer size (in elements) for new buffers. If n is kCCMIOInfinite, a buffer as big as the node's data will be allocated. |
|
Opens the data file. The file will be created if it does not already exist.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Writes the entire array to the node. The node's size and data type will be automatically set to the proper values. See CCMIORead*() for comments on the isC parameter. |
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Writes the entire node's data. Requires that the node's datatype and size were correctly set with CCMIOSetDataType(). |
|
Write one element of data. No datatype checking is performed. See CCMIOReadDataPoint() for a discussion of the parameters. The var-arg list must be terminated with kCCMIOEndArgs. Note: for performance reasons, the datatype of 'data' is unknown to the function, so CCMIOWriteDataPoint() cannot be used to write strings, as it does not know when 'data' is a string. For string data use CCMIOWriteData. Note: When writing scalar data with CCMIOWriteDataPoint(), a dimension of 0 should be used: "CCMIOWriteDataPoint(err, node, data, 0, kCCMIOEndArgs)", although CCMIOWriteData() is preferred. |
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and value.
|
|
Creates a child node of parent with given name and string value.
|