omero::grid::monitors::FileServer
Overview
interface FileServer
Operation Index
- getDirectory
-
Get an absolute directory from an OMERO.fs server.
- getBulkDirectory
-
Get an absolute directory from an OMERO.fs server.
- fileExists
-
Query the existence of a file
An exception will be raised if the method fails to determine the existence.
- getBaseName
-
Get base name of a file, this is the name
stripped of any path, e.g.
- getStats
-
Get all FileStats of a file
An exception will be raised if the file no longer exists or is inaccessible.
- getSize
-
Get size of a file in bytes
An exception will be raised if the file no longer exists or is inaccessible.
- getOwner
-
Get owner of a file
An exception will be raised if the file no longer exists or is inaccessible.
- getCTime
-
Get ctime of a file
An exception will be raised if the file no longer exists or is inaccessible.
- getMTime
-
Get mtime of a file
An exception will be raised if the file no longer exists or is inaccessible.
- getATime
-
Get atime of a file
An exception will be raised if the file no longer exists or is inaccessible.
- isDir
-
Query whether file is a directory
An exception will be raised if the file no longer exists or is inaccessible.
- isFile
-
Query whether file is a file
An exception will be raised if the file no longer exists or is inaccessible.
- getSHA1
-
Get SHA1 of a file
An exception will be raised if the file no longer exists or is inaccessible.
- readBlock
-
readBlock should open, read size bytes from offset
and then close the file.
Operations
::Ice::StringSeq getDirectory(string absPath, string filter) throws OmeroFSError
Get an absolute directory from an OMERO.fs server.
The returned list will contain just the file names for each directory entry.
An exception will be raised if the path does not exist or is inaccessible to the
OMERO.fs server. An exception will be raised if directory list cannot be
returned for any other reason.
Parameters
- absPath,
-
an absolute path on the monitor's watch path (string).
- filter,
-
a filter to apply to the listing, cf. ls (string).
Return Value
, a directory listing (Ice::StringSeq).
Exceptions
-
Get an absolute directory from an OMERO.fs server.
The returned list will contain the file stats for each directory entry.
An exception will be raised if the path does not exist or is inaccessible to the
OMERO.fs server. An exception will be raised if directory list cannot be
returned for any other reason.
Parameters
- absPath,
-
an absolute path on the monitor's watch path (string).
- filter,
-
a filter to apply to the listing, cf. ls (string).
Return Value
, a directory listing (FileStatsList).
Exceptions
-
Query the existence of a file
An exception will be raised if the method fails to determine the existence.
Parameters
- fileId,
-
see above.
Return Value
existence of file.
Exceptions
-
Get base name of a file, this is the name
stripped of any path, e.g. file.ext
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
base name.
Exceptions
-
Get all FileStats of a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
file stats (FileStats).
Exceptions
-
Get size of a file in bytes
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
byte size of file (long).
Exceptions
-
Get owner of a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
owner of file (string).
Exceptions
-
Get ctime of a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
ctime of file (float).
Exceptions
-
Get mtime of a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
mtime of file (float).
Exceptions
-
Get atime of a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
atime of file (float).
Exceptions
-
Query whether file is a directory
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
true is directory (bool).
Exceptions
-
Query whether file is a file
An exception will be raised if the file no longer exists or is inaccessible.
Parameters
- fileId,
-
see above.
Return Value
true if file (bool).
Exceptions
-
Get SHA1 of a file
An exception will be raised if the file no longer exists or is inaccessible.
An exception will be raised if the SHA1 cannot be generated for any reason.
Parameters
- fileId,
-
see above.
Return Value
SHA1 hex hash digest of file (string).
Exceptions
-
::Ice::ByteSeq readBlock(string fileId, long offset, int size) throws OmeroFSError
readBlock should open, read size bytes from offset
and then close the file.
An exception will be raised if the file no longer exists or is inaccessible.
An exception will be raised if the file read fails for any other reason.
Parameters
- fileId,
-
see above.
- offset,
-
byte offset into file from where read should begin (long).
- size,
-
number of bytes that should be read (int).
Return Value
byte sequence of upto size bytes.
Exceptions
-