// IDL schema definition for Web server interface. module Web_Server { typedef sequence Chunk_Type; interface Content_Iterator { boolean next_chunk (in unsigned long long offset, out Chunk_Type chunk); // This operation returns the next of the // file starting at . If there are // no more bindings, false is returned. void destroy (); // This operation destroys the iterator. }; exception Error_Result { // Status of the operation. These // values should map onto the normal HTTP // status values, e.g., 200 means success, 404 // means "file not found," etc. short status; }; struct Metadata_Type { string modification_date; // Modification date. string content_type; // Type of content. }; interface Iterator_Factory { void get_iterator (in string pathname, out Content_Iterator contents, out Metadata_Type metadata) raises (Error_Result); // This factory method returns a that // can be used to read the associated with // one ``chunk'' at a time. The // reports information about the . }; };