BIN_TAG cdds_open(dict, format_alias, data_alias, mode);
cdds_open may update the first dictionary named by dict. This may be required to accurately describe the input or output data.
This may be done for input or output streams. This is required to fully describe the binary data associated with the binary stream. The stream is described by the dict dictionaries.
format_alias is a definition name selected by the programmer. If specified, the end user is allowed to override the format definition using this name (i.e. out_format= segy).
data_alias is a definition name selected by the programmer. If specified, the end user is allowed to override the data definition using this name (i.e. out_data= line88).
mode determines how data may be accessed within the stream.
mode access description. "r" read only open existing file. "w" write only create file or discard contents. "a" append only open existing or create. "r+" read write open existing file. "w+" read write create file or discard existing contents. "a+" read append open existing or create. "m" read write open memory resident file.
Open processing retrieves the DDS_PATH definition from the extended dictionaries. The value names paths, delimited by white space, that are searched for special dictionaries. These dictionaries describe how to create formats and map field contents.
The contents of dict may be updated during cdds_open processing to describe the binary data. dict may be scanned after returning from cdds_open. Definitions should NOT be appended to dict after the binary stream is opened.
const char *in, *out; BIN_TAG in_bin, out_bin; ... /* open an existing binary i/o stream */ in_bin = cdds_open(in, "", "", "r"); ... /* open a new binary i/o stream */ out_bin = cdds_open(out, "out_format", "out_data", "w+");
cdds_close Close binary stream