![]() |
das2C
das core C utilities (v3)
|
Defines the "Out of Band" objects in a stream. More...


Go to the source code of this file.
Data Structures | |
| struct | OutOfBand |
| A container for Out-of-Band data. More... | |
| struct | OobExcept |
| describes an exception that can live in a stream. More... | |
| struct | OobComment |
| describes human-consumable messages that exist on the stream. More... | |
Functions | |
| DAS_API const char * | das_except_toStr (das_except_t nType, int nDasVer) |
| The stream name for an exception type. | |
| DAS_API das_except_t | das_except_fromStr (const char *sType) |
| The exception type for a stream name, from either stream version. | |
| DAS_API void | OutOfBand_clean (OutOfBand *pThis) |
| Clean up extra memory allocated when an out of band object is initialized. | |
| DAS_API void | OobExcept_set (OobExcept *pThis, das_except_t nType, const char *sMsg) |
| Set an exception structure to a particular exception. | |
Defines the "Out of Band" objects in a stream.
These are comments and exceptions
| DAS_API const char * das_except_toStr | ( | das_except_t | nType, |
| int | nDasVer | ||
| ) |
The stream name for an exception type.
Two of the names changed between stream versions:
| das_except_t | das2.2 | das3.0 |
|---|---|---|
| DAS_EX_UNKNOWN | Unknown | Unknown |
| DAS_EX_NO_DATA | NoDataInInterval | NoMatchingData |
| DAS_EX_SERVER_ERR | ServerError | ServerError |
| DAS_EX_QUERY_ERR | IllegalArgument | QueryError |
| nType | The exception type |
| nDasVer | The stream major version, 2 or 3. das1 streams have no exceptions. |
| DAS_API das_except_t das_except_fromStr | ( | const char * | sType | ) |
The exception type for a stream name, from either stream version.
The two vocabularies never use one name for two different types, so this needs no version. Streams may carry types outside the table, so an unrecognized name is not an error.
| DAS_API void OutOfBand_clean | ( | OutOfBand * | pThis | ) |
Clean up extra memory allocated when an out of band object is initialized.
| pThis | the out of band item to clean up. |
| DAS_API void OobExcept_set | ( | OobExcept * | pThis, |
| das_except_t | nType, | ||
| const char * | sMsg | ||
| ) |
Set an exception structure to a particular exception.
This is an initializer, it does not free a previous message. Call OutOfBand_clean() before setting the same structure again.
| pThis | A pointer to the exception to initialize |
| nType | The type of exception, one of:
|
| sMsg | The message for the exception, this is a human readable string. |