Class ProxyModule
java.lang.Object
ecmwf.common.ectrans.TransferModule
ecmwf.ecpds.mover.ProxyModule
- All Implemented Interfaces:
ECpdsProxy
,Closeable
,AutoCloseable
- Direct Known Subclasses:
ECauthModule
The Class ProxyModule.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Check if the last put was successful comparing the number of bytes sent and the checksum provided to the one calculated.void
close()
Close.Gets the input stream to read the file given by name starting at posn.abstract void
get
(String name, long posn, ProxySocket socket) Gets the.Provide an output stream to write the content of the file given by its name starting at position posn.abstract void
put
(String name, long posn, long size, ProxySocket socket) Puts the.abstract void
remove
(boolean closedOnError) Removes the.void
Sets the input stream.void
Sets the output stream.Methods inherited from class ecmwf.common.ectrans.TransferModule
connect, containsAttribute, copy, del, delegateChecksum, get, getAttribute, getAttribute, getAvailable, getClearPassword, getClosedOnError, getCookie, getDebug, getECtransDestination, getECtransModule, getECUser, getMSUser, getPort, getRemoteProvider, getStatus, list, listAsByteArray, listAsStringArray, mkdir, move, preGet, prePut, put, rmdir, setAttribute, setAttribute, setAvailable, setClosedOnError, setDebug, setInputFilter, setInputMd5, setInputSize, setOutputFilter, size, updateSocketStatistics
-
Constructor Details
-
ProxyModule
public ProxyModule()
-
-
Method Details
-
setOutputStream
Sets the output stream. Sets the output stream.- Specified by:
setOutputStream
in interfaceECpdsProxy
- Parameters:
out
- the new output stream
-
setInputStream
Sets the input stream. Sets the input stream.- Specified by:
setInputStream
in interfaceECpdsProxy
- Parameters:
in
- the new input stream
-
put
Puts the.- Parameters:
name
- the nameposn
- the posnsize
- the sizesocket
- the socket- Throws:
Exception
- the exception
-
put
Provide an output stream to write the content of the file given by its name starting at position posn. Put.- Specified by:
put
in classTransferModule
- Parameters:
name
- the nameposn
- the posnsize
- the size- Returns:
- the output stream
- Throws:
IOException
- Signals that an I/O exception has occurred.
-
get
Gets the.- Parameters:
name
- the nameposn
- the posnsocket
- the socket- Throws:
Exception
- the exception
-
get
Gets the input stream to read the file given by name starting at posn. Gets the.- Specified by:
get
in classTransferModule
- Parameters:
name
- the nameposn
- the posn- Returns:
- the input stream
- Throws:
IOException
- Signals that an I/O exception has occurred.
-
remove
Removes the.- Parameters:
closedOnError
- the closed on error- Throws:
IOException
- Signals that an I/O exception has occurred.
-
close
Close.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-
check
Check if the last put was successful comparing the number of bytes sent and the checksum provided to the one calculated. By default, doing nothing. Check.- Overrides:
check
in classTransferModule
- Parameters:
sent
- the sentchecksum
- the checksum- Throws:
IOException
- Signals that an I/O exception has occurred.
-