In file No file:

void set_mime_text (ostream &os, ObjectType type = unknown_type, const string &version = DVR, EncodingType enc = x_plain)

Set the MIME type to text.

Documentation

The reply to a DODS client is in the form of a multi-part MIME message. You can use this function to create a MIME header for a text message. Here is an example of its use. This is the DAS filter program from the Matlab server. (Simplified to show off its structure.) \begin{verbatim} extern DAS *read_attributes(const char *filename); int main(int argc, char * argv[]) { set_mime_text(dods_das); string dataset = argv[1]; // Read the matlab string variables for attributes DAS *das_table = read_attributes(dataset); // Forward the DAS class over the network das_table->print(); return 0; } \end{verbatim} The #ObjectType# and #EncodingType# enums are defined in #Connect.h#.
Parameters:
os - A Stream object to which the MIME header is written.
type - An #ObjectType# enum indicating the DODS type of the object.
enc - An #EncodingType# switch indicating whether the data is to be compressed or not.
See Also:
ObjectType
EncodingType
Connect

alphabetic index hierarchy of classes


generated by doc++