All Frameworks Class Hierarchy This Framework Indexes
ENOVaultClientCPP Class ENOVIVaultDocument
Usage: you must use this class as is. You should never derive it.
public class ENOVIVaultDocument
This class supplies methods to manage documents.
role: This class enables to access properties and content of a document
Method Index
- o
close(ENOVIVaultError&)
- Ends the Read, Write or ReadWrite sequence.
- o
copyFromLocalFile(CATUnicodeString&,CATBoolean,ENOVIVaultError&)
- Copy the local document on server.
- o
copyToLocalFile(CATUnicodeString&,CATBoolean,ENOVIVaultError&)
- Copy the server document into a local file.
- o
getCKSum(unsigned long&,ENOVIVaultError&)
- Supplies the document cksum.
- o
getCreationTimestamp(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document creation date.
- o
getCurPos(unsigned long&,ENOVIVaultError&)
- Supplies the current position in the document you are accessing.
- o
getDescription(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document description.
- o
getEXTOId(SEQUENCE_octet&,ENOVIVaultError&)
- Supplies the document external object identifier.
- o
getFatherUserSession(ENOVIVaultUserSession**)
- Get the Father ENOVIVaultUserSession.
- o
getGMTLastModTimestamp(CATLONG64&,ENOVIVaultError&)
- Supplies the document last modification date in GMT time.
- o
getLastModTimestamp(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document last modification date.
- o
getLocationPath(CATUnicodeString&,ENOVIVaultError&)
- Supplies when possible and according to transfer protocols, the full path name of the ENOVIVault
document.
- o
getMimeType(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document mimetype.
- o
getName(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document name.
- o
getOId(SEQUENCE_octet&)
- Supplies the ENOVIVaultDocument Object Identifier.
- o
getOriginalHost(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document original host.
- o
getOriginalName(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document original name.
- o
getOriginalPath(CATUnicodeString&,ENOVIVaultError&)
- Supplies the document original path.
- o
getSize(unsigned long&,ENOVIVaultError&)
- Supplies the document size.
- o
getStatus(int&,ENOVIVaultError&)
- Supplies the ENOVIVaultDocument status.
- o
getURL(SEQUENCE_octet&)
- Supplies the ENOVIVaultDocument Unique Universal Identifier.
- o
isCached(CATBoolean&,ENOVIVaultError&)
- Specifies if the document is cached or not.
- o
openReadWrite(CATBoolean,ENOVIVaultError&)
- Initiates a document read write operation.
- o
openRead(ENOVIVaultError&)
- Initiates a document read operation.
- o
openWrite(unsigned long,CATBoolean,ENOVIVaultError&)
- Initiates a document write operation.
- o
readBlock(SEQUENCE_octet&,long,long,long&,ENOVIVaultError&)
- Read a data block beginning at the current position from the server document
into a bytes array.
- o
read(long,SEQUENCE_octet&,ENOVIVaultError&)
- Reads the whole document content into a bytes array.
- o
refresh(ENOVIVaultError&)
- Refresh this document if it is a cached document and it is not up-to-date.
- o
setCurPos(unsigned long,ENOVIVaultError&)
- Set the current position in the document you are accessing.
- o
setDescription(CATUnicodeString&,ENOVIVaultError&)
- Set the document description.
- o
setEXTOId(SEQUENCE_octet&,ENOVIVaultError&)
- Sets the document external object identifier.
- o
setMimeType(CATUnicodeString&,ENOVIVaultError&)
- Set the ENOVIVaultDocument mimetype.
- o
setName(CATUnicodeString&,ENOVIVaultError&)
- Sets the document name.
- o
setOriginalHost(CATUnicodeString&,ENOVIVaultError&)
- Sets the document original host.
- o
setOriginalName(CATUnicodeString&,ENOVIVaultError&)
- Sets the document original name.
- o
setOriginalPath(CATUnicodeString&,ENOVIVaultError&)
- Sets the document original path.
- o
writeBlock(SEQUENCE_octet&,long,long,ENOVIVaultError&)
- Write a data block on server beginning at the current position from a bytes array.
- o
write(long,SEQUENCE_octet&,ENOVIVaultError&)
- Write the whole document on server from a bytes array.
Methods
o close
| public close( | | oVaultError) |
-
Ends the Read, Write or ReadWrite sequence. Reset the current position to the document
beginning.
Delete local file if needed.
- Returns:
- S_OK, S_ALREADY_CLOSE, S_NOT_OPEN, E_FAIL
o copyFromLocalFile
| public copyFromLocalFile( | const | iLocalFullPathName, |
| const | iDeleteLocalFileAtClose, |
| | oVaultError) |
-
Copy the local document on server. The local file full path name is mandatory. The current
position
is set to the document end after this operation.
- Parameters:
-
- iLocalFullPathName
- [in] - local document to write full path name.
- iDeleteLocalFileAtClose
- [in] - if set ot true, the local file will be deleted at close time.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN_WRITE, VAULT_E_NO_LOCALFILEFULLPATHNAME, VAULT_E_MEDIUM_FULL
o copyToLocalFile
| public copyToLocalFile( | const | iLocalFullPathName, |
| const | iDeleteLocalFileAtClose, |
| | oVaultError) |
-
Copy the server document into a local file. The local file full path name is not mandatory.
You may give only the file name or even nothing. Then use the getLocationPath method to get
the local file full path name. The current position is set to the document end after this
operation.
- Parameters:
-
- iLocalFullPathName
- [in] - full path name under which the consumer application want the document to be copied.
- iDeleteLocalFileAtClose
- [in] - if set ot true, the local file will be deleted at close time.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN_READ, VAULT_E_MEDIUM_FULL
o getCKSum
| public getCKSum( | | oDocumentCKSum, |
| | oVaultError) |
-
Supplies the document cksum.
- Parameters:
-
- oDocumentCKSum
- [out] - ENOVIVaultDocument size.
- oVaultError
- [out] - Details about the error.
o getCreationTimestamp
| public getCreationTimestamp( | | oCreationTimestamp, |
| | oVaultError) |
-
Supplies the document creation date.
- Parameters:
-
- oCreationTimestamp
- [out] - ENOVIVaultDocument creation date.
- oVaultError
- [out] - Details about the error.
o getCurPos
| public getCurPos( | | oCurPos, |
| | oVaultError) |
-
Supplies the current position in the document you are accessing.
Precondition: The document must have been openned
- Parameters:
-
- oCurPos
- [out] - current position in the document.
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN
o getDescription
| public getDescription( | | oDescription, |
| | oVaultError) |
-
Supplies the document description.
- Parameters:
-
- oDescription
- [out] - ENOVIVaultDocument description.
- oVaultError
- [out] - Details about the error.
o getEXTOId
| public getEXTOId( | | oEXTOId, |
| | oVaultError) |
-
Supplies the document external object identifier.
- Parameters:
-
- oEXTOId
- [out] - ENOVIVaultDocument external object identifier.
- oVaultError
- [out] - Details about the error.
o getFatherUserSession
| public getFatherUserSession( | | oppFatherUserSession) |
-
Get the Father ENOVIVaultUserSession.
- Parameters:
-
- oFatherUserSession
- [out] - Father ENOVIVaultUserSession.
o getGMTLastModTimestamp
| public getGMTLastModTimestamp( | | onvLastTimestamp, |
| | oVaultError) |
-
Supplies the document last modification date in GMT time.
- Parameters:
-
- onvLastTimestamp
- [out] - ENOVIVaultDocument last modification date.
- oVaultError
- [out] - Details about the error.
o getLastModTimestamp
| public getLastModTimestamp( | | oLastTimestamp, |
| | oVaultError) |
-
Supplies the document last modification date.
- Parameters:
-
- oLastTimestamp
- [out] - ENOVIVaultDocument last modification date.
- oVaultError
- [out] - Details about the error.
o getLocationPath
| public getLocationPath( | | oFullPath, |
| | oVaultError) |
-
Supplies when possible and according to transfer protocols, the full path name of the ENOVIVault
document.
You will have an error if no open has been done on the document. If NFS transfer protocol is
switched
on you will have the full path name on server side under which to write or read the document.
After a CopyXXXLocalFile operation, it will return the given LocalFullPathName.
- Parameters:
-
- oFullPath
- [out] - full path name of the vault document on the ENOVIVault server
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN, VAULT_E_NO_LOCATION_AVAILABLE
o getMimeType
| public getMimeType( | | oMimetype, |
| | oVaultError) |
-
Supplies the document mimetype.
- Parameters:
-
- oMimetype
- [out] - ENOVIVaultDocument mimetype.
- oVaultError
- [out] - Details about the error.
o getName
| public getName( | | oName, |
| | oVaultError) |
-
Supplies the document name.
- Parameters:
-
- oName
- [out] - ENOVIVaultDocument name.
- oVaultError
- [out] - Details about the error.
o getOId
-
Supplies the ENOVIVaultDocument Object Identifier.
- Parameters:
-
- oOId
- [out] - ENOVIVaultDocument Object Identifier.
- Returns:
- S_OK, E_FAIL
o getOriginalHost
| public getOriginalHost( | | oOriginalHost, |
| | oVaultError) |
-
Supplies the document original host.
- Parameters:
-
- oOriginalHost
- [out] - ENOVIVaultDocument original host.
- oVaultError
- [out] - Details about the error.
o getOriginalName
| public getOriginalName( | | oOriginalName, |
| | oVaultError) |
-
Supplies the document original name.
- Parameters:
-
- oOriginalName
- [out] - ENOVIVaultDocument original name.
- oVaultError
- [out] - Details about the error.
o getOriginalPath
| public getOriginalPath( | | oOriginalPath, |
| | oVaultError) |
-
Supplies the document original path.
- Parameters:
-
- oOriginalPath
- [out] - ENOVIVaultDocument original path.
- oVaultError
- [out] - Details about the error.
o getSize
| public getSize( | | oDocumentSize, |
| | oVaultError) |
-
Supplies the document size.
- Parameters:
-
- oDocumentSize
- [out] - ENOVIVaultDocument size.
- oVaultError
- [out] - Details about the error.
o getStatus
| public getStatus( | | oStatus, |
| | oVaultError) |
-
Supplies the ENOVIVaultDocument status.
- Parameters:
-
- oStatus
- [out] - ENOVIVaultDocument status. It can be:
Legal Values: iAction may be set to:
- CREATED
- To indicate that the document have been created.
- UPDATED
- To indicate that the document has been updated.
- DELETED
- To indicate that the document has been deleted.
- COMMITTED
- To indicate that there is no ongoing modification on the document.
o getURL
-
Supplies the ENOVIVaultDocument Unique Universal Identifier.
- Parameters:
-
- oURL
- [out] - ENOVIVaultDocument Unique Universal Identifier.
o isCached
| public isCached( | | oIsDocCached, |
| | oVaultError) |
-
Specifies if the document is cached or not.
- Parameters:
-
- oIsDocCached
- [out] - true if the document is cached, false otherwise.
- Returns:
- S_OK, E_FAIL
o openReadWrite
| public openReadWrite( | const | iFullDocWritePlanned, |
| | oVaultError) |
-
Initiates a document read write operation.
To be successful, it supposes that the document
is not under modification. It give access to the last committed view.
Performance issue: Be carefull that this call trigger a document copy on server side
off.
Prefer others read or write methods than this one if possible.
- Parameters:
-
- iFullDocWritePlanned
- [in] - indicates if you are planning to write the whole document.
Legal Values:
- CATTrue
- To indicate that the whole document will be written.
- CATFalse
- To indicate that only part of the document will be written.
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_LOCKED, VAULT_E_ALREADY_OPEN
o openRead
| public openRead( | | oVaultError) |
-
Initiates a document read operation.
It gives access to the last committed view. At open time
the current position is set to the document beginning (value zero).
- Parameters:
-
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_LOCKED, VAULT_E_ALREADY_OPEN
o openWrite
| public openWrite( | const | iDocSize, |
| const | iFullDocWritePlanned, |
| | oVaultError) |
-
Initiates a document write operation.
To be successful, it supposes that the document
is not under modification. Put the size of the document to write when it is possible.
It should always be the case, else put the value zero by default. At open time the current
position is set to the document beginning (value zero).
Performance issue: Be carefull that this call trigger a document copy on ENOVIVault server side
off when the iFullDocWritePlanned parameter is set to false.
Set iFullDocWritePlanned to true each time it is possible.
- Parameters:
-
- iDocSize
- [in] - document size in bytes.
Legal Values: iDocSize setted to zero means that you do not know the document size.
- iFullDocWritePlanned
- [in] - indicates if you are planning to write the whole document.
Legal Values:
- CATTrue
- To indicate that the whole document will be written.
- CATFalse
- To indicate that only part of the document will be written.
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_LOCKED, VAULT_E_MEDIUM_FULL, VAULT_E_ALREADY_OPEN
o readBlock
| public readBlock( | | ioReadBuffer, |
| const | iOffset, |
| const | iSizeToRead, |
| | oLengthRead, |
| | oVaultError) |
-
Read a data block beginning at the current position from the server document
into a bytes array. The current position is updated after the block read operation.
You are suppose to allocate and release the data buffer oReadBuffer.
- Parameters:
-
- ioReadBuffer
- [inout] - data buffer read from server.
- iOffset
- [in] - offset in the input/output buffer.
- iSizeToRead
- [in] - data buffer to read size.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN
o read
| public read( | const | iSizeToRead, |
| | oReadBuffer, |
| | oVaultError) |
-
Reads the whole document content into a bytes array.
The current position is set to the document end after this operation.
You are supposed to allocate and release the data buffer oReadBuffer.
This service uses the above
ReadBlock method to be efficient and performe the whole read sequence by block.
- Parameters:
-
- iSizeToRead
- [in] - data buffer to read size
- oReadBuffer
- [out] - data buffer read from server.
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN_READ
o refresh
| public refresh( | | oVaultError) |
-
Refresh this document if it is a cached document and it is not up-to-date.
o setCurPos
| public setCurPos( | const | iNewCurPos, |
| | oVaultError) |
-
Set the current position in the document you are accessing.
Precondition: The document must have been openned
- Parameters:
-
- iNewCurPos
- [in] - new current position in the document.
- oVaultError
- [out] - Details about the error.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN
o setDescription
| public setDescription( | const | iDescription, |
| | oVaultError) |
-
Set the document description.
- Parameters:
-
- iDescription
- [in] - ENOVIVaultDocument description.
- oVaultError
- [out] - Details about the error.
o setEXTOId
| public setEXTOId( | const | iEXTOId, |
| | oVaultError) |
-
Sets the document external object identifier.
- Parameters:
-
- iEXTOId
- [in] - ENOVIVaultDocument external object identifier.
- oVaultError
- [out] - Details about the error.
o setMimeType
| public setMimeType( | const | iMimetype, |
| | oVaultError) |
-
Set the ENOVIVaultDocument mimetype.
- Parameters:
-
- iMimetype
- [in] - ENOVIVaultDocument mimetype.
- oVaultError
- [out] - Details about the error.
o setName
| public setName( | const | iName, |
| | oVaultError) |
-
Sets the document name.
- Parameters:
-
- iName
- [in] - ENOVIVaultDocument name.
- oVaultError
- [out] - Details about the error.
o setOriginalHost
| public setOriginalHost( | const | iOriginalHost, |
| | oVaultError) |
-
Sets the document original host.
- Parameters:
-
- iOriginalHost
- [out] - ENOVIVaultDocument original host.
- oVaultError
- [out] - Details about the error.
o setOriginalName
| public setOriginalName( | const | iOriginalName, |
| | oVaultError) |
-
Sets the document original name.
- Parameters:
-
- iOriginalName
- [in] - ENOVIVaultDocument original name.
- oVaultError
- [out] - Details about the error.
o setOriginalPath
| public setOriginalPath( | const | oOriginalPath, |
| | oVaultError) |
-
Sets the document original path.
- Parameters:
-
- iOriginalPath
- [in] - ENOVIVaultDocument original path.
- oVaultError
- [out] - Details about the error.
o writeBlock
| public writeBlock( | const | iBufferToWrite, |
| const | iOffset, |
| const | iSizeToWrite, |
| | oVaultError) |
-
Write a data block on server beginning at the current position from a bytes array. The
current
position is updated after the block write operation. You are suppose to allocate and release
the
data buffer iBufferToWrite.
- Parameters:
-
- iBufferToWrite
- [in] - data block to write on server.
- iOffset
- [in] - offset in the input buffer.
- iSizeToWrite
- [in] - number of bytes to write on server.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN_WRITE, VAULT_E_MEDIUM_FULL
o write
| public write( | const | iSizeToWrite, |
| const | iBufferToWrite, |
| | oVaultError) |
-
Write the whole document on server from a bytes array. The current position is set to the
document end
after this operation. You are suppose to allocate and release the data buffer iBufferToWrite.
This service use the above WriteBlock call to be efficient and performe the whole write sequence
by block.
- Parameters:
-
- iSizeToWrite
- [in] - number of bytes to write on server.
- iBufferToWrite
- [in] - data buffer to write on server.
- Returns:
- S_OK, E_FAIL, VAULT_E_NOT_OPEN_WRITE, VAULT_E_MEDIUM_FULL
This object is included in the file: ENOVIVaultDocument.h
If needed, your Imakefile.mk should include the module: ENOVIVaultClientAPP