Class AzureModule
java.lang.Object
ecmwf.common.ectrans.TransferModule
ecmwf.common.ectrans.module.AzureModule
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidCheck if the last put was successful comparing the number of bytes sent and the checksum provided to the one calculated.voidclose()Close.voidconnect(String location, ECtransSetup setup) Connect.voidDelete by name.Gets the input stream to read the file given by name starting at posn.intgetPort(ECtransSetup setup) Gets the port from the setup.Gets the current status of the transfer module.getValue(byte[] digest) Gets the value.byte[]listAsByteArray(String directory, String pattern) Default implementation to provide the list as a GZIPed byte array.String[]listAsStringArray(String directory, String pattern) List as a string array.voidMake directory by name.booleanput(InputStream in, String name, long posn, long size) Write the content of the file given by its name, starting at position posn and writing to the provided input stream.Provide an output stream to write the content of the file given by its name starting at position posn.voidRemove directory by name.longGive the size of the file given by its name.Methods inherited from class ecmwf.common.ectrans.TransferModule
containsAttribute, copy, delegateChecksum, get, getAttribute, getAttribute, getAvailable, getClearPassword, getClosedOnError, getCookie, getDebug, getECtransDestination, getECtransModule, getECUser, getMSUser, getRemoteProvider, list, move, preGet, prePut, setAttribute, setAttribute, setAvailable, setClosedOnError, setDebug, setInputFilter, setInputMd5, setInputSize, setOutputFilter, updateSocketStatistics
-
Constructor Details
-
AzureModule
public AzureModule()
-
-
Method Details
-
getStatus
Gets the current status of the transfer module. Gets the status.- Overrides:
getStatusin classTransferModule- Returns:
- the status
-
getPort
Gets the port from the setup. Gets the port.- Overrides:
getPortin classTransferModule- Parameters:
setup- the setup- Returns:
- the port
-
connect
Connect. Connect.- Specified by:
connectin classTransferModule- Parameters:
location- the locationsetup- the setup- Throws:
IOExceptionURISyntaxException
-
del
Delete by name. Del.- Specified by:
delin classTransferModule- Parameters:
name- the name- Throws:
IOException- Signals that an I/O exception has occurred.
-
put
Write the content of the file given by its name, starting at position posn and writing to the provided input stream. By default, doing nothing and returning false. Put.- Overrides:
putin classTransferModule- Parameters:
in- the inname- the nameposn- the posnsize- the size- Returns:
- true, if successful
- Throws:
IOException- Signals that an I/O exception has occurred.
-
put
Provide an output stream to write the content of the file given by its name starting at position posn. Put.- Specified by:
putin 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 input stream to read the file given by name starting at posn. Gets the.- Specified by:
getin classTransferModule- Parameters:
name- the nameposn- the posn- Returns:
- the input stream
- Throws:
IOException- Signals that an I/O exception has occurred.
-
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:
checkin classTransferModule- Parameters:
sent- the sentchecksum- the checksum- Throws:
IOException- Signals that an I/O exception has occurred.
-
getValue
Gets the value.- Parameters:
digest- the digest- Returns:
- the value
-
size
Give the size of the file given by its name. Size.- Specified by:
sizein classTransferModule- Parameters:
name- the name- Returns:
- the long
- Throws:
IOException- Signals that an I/O exception has occurred.
-
mkdir
Make directory by name. Mkdir.- Overrides:
mkdirin classTransferModule- Parameters:
directory- the dir- Throws:
IOException- Signals that an I/O exception has occurred.
-
rmdir
Remove directory by name. Rmdir.- Overrides:
rmdirin classTransferModule- Parameters:
directory- the dir- Throws:
IOException- Signals that an I/O exception has occurred.
-
listAsStringArray
List as a string array. List as string array.- Overrides:
listAsStringArrayin classTransferModule- Parameters:
directory- the directorypattern- the pattern- Returns:
- the string[]
- Throws:
IOException- Signals that an I/O exception has occurred.
-
listAsByteArray
Default implementation to provide the list as a GZIPed byte array. The implementation should give a better implementation as this one is relying on the non optimal listAsStringArray method by default. List as byte array.- Overrides:
listAsByteArrayin classTransferModule- Parameters:
directory- the directorypattern- the pattern- Returns:
- the bytes
- Throws:
IOException- Signals that an I/O exception has occurred.
-
close
-