Language

The Free and Open Productivity Suite
Released: Apache OpenOffice 4.1.15

API

SDK

Tips ‘n’ Tricks

Miscellaneous


:: com :: sun :: star :: embed ::

unpublished interface XStorage2
Base Interfaces
XStorage2XStorage
   ┣ ::com::sun::star::container::XNameAccess
   ┃ ┗ ::com::sun::star::container::XElementAccess
   ┗ ::com::sun::star::lang::XComponent

XStorage
(referenced interface's summary:)
This interface represents main storage functionality.
Usage Restrictions
not published
Description
This interface extends the base XStorage interface.

Methods' Summary
openEncryptedStream allows to get access to a child encrypted stream with EncryptionData.  
cloneEncryptedStream allows to get readonly copy of a child encrypted stream with encryption data.  
Methods' Details
openEncryptedStream
::com::sun::star::io::XStream
openEncryptedStream( [in] string  sStreamName,
[in] long  nOpenMode,
[in] sequence< ::com::sun::star::beans::NamedValue >  aEncryptionData )
raises( InvalidStorageException,
::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::packages::NoEncryptionException,
::com::sun::star::packages::WrongPasswordException,
::com::sun::star::io::IOException,
StorageWrappedTargetException );

Description
allows to get access to a child encrypted stream with EncryptionData.

If storage does not allow any encryption this method will always throw ::com::sun::star::packages::NoEncryptionException.

In case the stream is open in readonly mode the XStream::getOutputStream method will return an empty reference.

Parameter sStreamName
the name of the substream that should be open
Parameter nOpenMode
a mode the stream should be open in, can be a combination of ElementModes values
Parameter aEncryptionData
this parameter allowes to specify an encryption data to decrypt the stream, the encryption data must be correct, otherwise an exception will be thrown
Throws
::com::sun::star::embed::InvalidStorageException this storage is in invalid state for any reason
Throws
::com::sun::star::lang::IllegalArgumentException one of provided arguments is illegal
Throws
::com::sun::star::packages::NoEncryptionException the stream is not encrypted
Throws
::com::sun::star::packages::WrongPasswordException the provided encryption data is wrong
Throws
::com::sun::star::io::IOException in case of io errors during stream opening
Throws
::com::sun::star::embed::StorageWrappedTargetException wraps other exceptions
cloneEncryptedStream
::com::sun::star::io::XStream
cloneEncryptedStream( [in] string  sStreamName,
[in] sequence< ::com::sun::star::beans::NamedValue >  aEncryptionData )
raises( InvalidStorageException,
::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::packages::NoEncryptionException,
::com::sun::star::packages::WrongPasswordException,
::com::sun::star::io::IOException,
StorageWrappedTargetException );

Description
allows to get readonly copy of a child encrypted stream with encryption data.

If storage does not allow any encryption this method will always throw ::com::sun::star::packages::NoEncryptionException.

The stream is open in readonly mode so the XStream::getOutputStream method will return an empty reference.

This method allows to specify encryption data for the child stream explicitly.

Parameter sStreamName
the name of the substream that should be copied
Parameter aEncryptionData
this parameter allowes to specify an encryption data for the stream, the encryption data must be correct, otherwise an exception will be thrown
Throws
::com::sun::star::embed::InvalidStorageException this storage is in invalid state for any reason
Throws
::com::sun::star::lang::IllegalArgumentException one of provided arguments is illegal
Throws
::com::sun::star::packages::NoEncryptionException the stream is not encrypted
Throws
::com::sun::star::packages::WrongPasswordException the provided encryption data is wrong
Throws
::com::sun::star::io::IOException in case of io errors during stream opening
Throws
::com::sun::star::embed::StorageWrappedTargetException wraps other exceptions
Top of Page

Apache Software Foundation

Copyright & License | Privacy | Contact Us | Donate | Thanks

Apache, OpenOffice, OpenOffice.org and the seagull logo are registered trademarks of The Apache Software Foundation. The Apache feather logo is a trademark of The Apache Software Foundation. Other names appearing on the site may be trademarks of their respective owners.