56 XDRFileUnMarshaller::XDRFileUnMarshaller( FILE *out )
62 XDRFileUnMarshaller::XDRFileUnMarshaller()
65 throw InternalErr( __FILE__, __LINE__,
"Default constructor not implemented." ) ;
68 XDRFileUnMarshaller::XDRFileUnMarshaller(
const XDRFileUnMarshaller &um )
69 : UnMarshaller( um ), _source( 0 )
71 throw InternalErr( __FILE__, __LINE__,
"Copy constructor not implemented." ) ;
75 XDRFileUnMarshaller::operator=(
const XDRFileUnMarshaller & )
77 throw InternalErr( __FILE__, __LINE__,
"Copy operator not implemented." ) ;
94 if( !xdr_char( _source, (
char *)&val ) )
95 throw Error(
"Network I/O Error. Could not read byte data. This may be due to a\nbug in DODS or a problem with the network connection.");
102 throw Error(
"Network I/O Error. Could not read int 16 data. This may be due to a\nbug in libdap or a problem with the network connection.");
109 throw Error(
"Network I/O Error. Could not read int 32 data. This may be due to a\nbug in libdap or a problem with the network connection.");
115 if( !xdr_float( _source, &val ) )
116 throw Error(
"Network I/O Error. Could not read float 32 data. This may be due to a\nbug in libdap or a problem with the network connection.");
122 if( !xdr_double( _source, &val ) )
123 throw Error(
"Network I/O Error. Could not read float 64 data. This may be due to a\nbug in libdap or a problem with the network connection.");
130 throw Error(
"Network I/O Error. Could not read uint 16 data. This may be due to a\nbug in libdap or a problem with the network connection.");
137 throw Error(
"Network I/O Error. Could not read uint 32 data. This may be due to a\nbug in libdap or a problem with the network connection.");
143 char *in_tmp = NULL ;
146 throw Error(
"Network I/O Error. Could not read string data.\nThis may be due to a bug in libdap, on the server or a\nproblem with the network connection.");
162 xdr_opaque( _source, val, len ) ;
168 if( !xdr_int( _source, &val ) )
169 throw Error(
"Network I/O Error(1). This may be due to a bug in libdap or a\nproblem with the network connection.");
176 throw Error(
"Network I/O error. Could not read packed array data.\nThis may be due to a bug in libdap or a problem with\nthe network connection.");
187 throw Error(
"Network I/O error. Could not read packed array data.\nThis may be due to a bug in libdap or a problem with\nthe network connection.");
195 << (
void *)
this <<
")" << endl ;
virtual ~XDRFileUnMarshaller()
virtual void get_byte(dods_byte &val)
abstract base class used to unmarshall/deserialize dap data objects
virtual void dump(ostream &strm) const
dump the contents of this object to the specified ostream
virtual void get_float64(dods_float64 &val)
Holds a one-dimensional collection of DAP2 data types.
virtual void get_int16(dods_int16 &val)
virtual void get_uint32(dods_uint32 &val)
virtual void get_str(string &val)
XDR * new_xdrstdio(FILE *stream, enum xdr_op xop)
virtual void get_url(string &val)
Type type() const
Returns the type of the class instance.
A class for software fault reporting.
virtual void get_int(int &val)
virtual BaseType * var(const string &name="", bool exact_match=true, btp_stack *s=0)
const unsigned int max_str_len
void delete_xdrstdio(XDR *xdr)
virtual void get_int32(dods_int32 &val)
static ostream & LMarg(ostream &strm)
virtual void get_uint16(dods_uint16 &val)
The basic data type for the DODS DAP types.
virtual void get_float32(dods_float32 &val)
virtual void get_vector(char **val, unsigned int &num, Vector &vec)
static xdrproc_t xdr_coder(const Type &t)
Returns a function used to encode elements of an array.
A class for error processing.
virtual void get_opaque(char *val, unsigned int len)