Documentation for Ice 3.5. The latest release is Ice 3.7. Refer to the space directory for other releases.


IcePatch2::FileServer

Overview

interface FileServer

The interface that provides access to files.

Operation Index

getFileInfoSeq — Return the IcePatch2::FileInfoSeq for the specified partition.
getChecksumSeq — Return the checksums for all partitions.
getChecksum — Return the master checksum for all partitions.
getFileCompressed — Read the specified file.

Operations

[ "nonmutating" ] IcePatch2::FileInfoSeq getFileInfoSeq(int partition) throws IcePatch2::PartitionOutOfRangeException

Return the IcePatch2::FileInfoSeq for the specified partition. If the partion number is out of range, the operation throws PartitionOutOfRangException.

Parameters

partition — The partition number in the range 0-255.

Return Value

A sequence containing the IcePatch2::FileInfo structures for files in the specified partition.

[ "nonmutating" ] IcePatch2::ByteSeqSeq getChecksumSeq()

Return the checksums for all partitions.

Return Value

A sequence containing 256 checksums. Partitions with a checksum that differs from the previous checksum for the same partition contain updated files. Partitions with a checksum that is identical to the previous checksum do not contain updated files.

[ "nonmutating" ] Ice::ByteSeq getChecksum()

Return the master checksum for all partitions. If this checksum is the same as for a previous run, the entire file set is up-to-date.

Return Value

The master checksum for the file set.

[ "amd", "nonmutating", "cpp:array" ] Ice::ByteSeq getFileCompressed(string path, int pos, int num) throws IcePatch2::FileAccessException

Read the specified file. If the read operation fails, the operation throws IcePatch2::FileAccessException. This operation may only return fewer bytes than requested in case there was an end-of-file condition.

Parameters

path — The pathname (relative to the data directory) for the file to be read.
pos — The file offset at which to begin reading.
num — The number of bytes to be read.

Return Value

A sequence containing the compressed file contents.


  • No labels