Package opendap.dap
Interface ClientIO
-
- All Known Implementing Classes:
BaseTypePrimitiveVector
,BooleanPrimitiveVector
,BytePrimitiveVector
,DArray
,DataDDS
,DByte
,DDS
,DFloat32
,DFloat64
,DGrid
,DInt16
,DInt32
,DList
,DSequence
,DString
,DStructure
,DUInt16
,DUInt32
,DURL
,DVector
,Float32PrimitiveVector
,Float64PrimitiveVector
,Int16PrimitiveVector
,Int32PrimitiveVector
,PrimitiveVector
,UInt16PrimitiveVector
,UInt32PrimitiveVector
public interface ClientIO
Client-side serialization for OPeNDAP variables (sub-classes ofBaseType
). This does not send the entire class as the JavaSerializable
interface does, rather it sends only the binary data values. Other software is responsible for sending variable type information (seeDDS
).
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
deserialize(DataInputStream source, ServerVersion sv, StatusUI statusUI)
Reads data from aDataInputStream
.void
externalize(DataOutputStream sink)
Writes data to aDataOutputStream
.
-
-
-
Method Detail
-
deserialize
void deserialize(DataInputStream source, ServerVersion sv, StatusUI statusUI) throws IOException, EOFException, DataReadException
Reads data from aDataInputStream
. This method is only used on the client side of the OPeNDAP client/server connection.- Parameters:
source
- aDataInputStream
to read from.sv
- TheServerVersion
returned by the server. (used byDSequence
to determine which protocol version was used).statusUI
- TheStatusUI
object to use for GUI updates and user cancellation notification (may be null).- Throws:
DataReadException
- when invalid data is read, or if the user cancels the download.EOFException
- if EOF is found before the variable is completely deserialized.IOException
- thrown on any other InputStream exception.- See Also:
DataDDS
-
externalize
void externalize(DataOutputStream sink) throws IOException
Writes data to aDataOutputStream
. This method is used primarily by GUI clients which need to download OPeNDAP data, manipulate it, and then re-save it as a binary file.- Parameters:
sink
- aDataOutputStream
to write to.- Throws:
IOException
- thrown on anyOutputStream
exception.
-
-