com.crystaldecisions.sdk.occa.infostore
Interface IFile

All Known Subinterfaces:
ILocalFile, IRemoteFile, IStreamingUploadFile

public interface IFile

This interface represents a local or remote file object.

This interface serves as a base interface for the "two-phase" file operations, in other words, the operation will not happen until the IFile.commit() method is invoked. The operation can also be cancelled by invoking the IFile.abort() method if the IFile.commit() method has not been invoked yet.


Method Summary
 void abort()
           Aborts the transaction.
 void commit()
           Commits the transaction.
 java.lang.String getActualName()
           Returns the actual name as stored in the FRS (including the GUID inserted upon creation), of the file object.
 java.lang.String getDestRelativePath()
           Get's the relative path of the file from the infoObject's directory on the destination FRS.
 java.lang.String getName()
           Returns the name of the file object without the GUID which was inserted upon creation.
 long getSize()
           Returns the size of the file.
 

Method Detail

getName

java.lang.String getName()

Returns the name of the file object without the GUID which was inserted upon creation.

Returns:
The name, without GUID, of the file object as a String.

getActualName

java.lang.String getActualName()

Returns the actual name as stored in the FRS (including the GUID inserted upon creation), of the file object.

Returns:
The actual name of the file object as a String.

getDestRelativePath

java.lang.String getDestRelativePath()

Get's the relative path of the file from the infoObject's directory on the destination FRS.

Returns:
The sub directories and file name from the infoObject's file directory

getSize

long getSize()
             throws SDKException

Returns the size of the file.

Returns:
A long that indicates file's size in bytes.
Throws:
SDKException - This is thrown if the process is unsuccessful.

commit

void commit()
            throws SDKException

Commits the transaction.

Throws:
SDKException - This is thrown if the process is unsuccessful.

abort

void abort()

Aborts the transaction.