diff options
author | Matthias Huetsch <mhu@openoffice.org> | 2001-11-03 18:21:04 +0000 |
---|---|---|
committer | Matthias Huetsch <mhu@openoffice.org> | 2001-11-03 18:21:04 +0000 |
commit | 2e33216689629b1d78d9b26715bb0571c075c20d (patch) | |
tree | bce04ff2b042e491d27432292416325aee34dc20 /store/inc/store/store.hxx | |
parent | c99a2daa423d2a434e5c23b3b2dc1ba4aeea9a48 (diff) |
#88337# Reviewed and updated documentation.
Diffstat (limited to 'store/inc/store/store.hxx')
-rw-r--r-- | store/inc/store/store.hxx | 162 |
1 files changed, 150 insertions, 12 deletions
diff --git a/store/inc/store/store.hxx b/store/inc/store/store.hxx index e43b9869c5ff..78f60386806f 100644 --- a/store/inc/store/store.hxx +++ b/store/inc/store/store.hxx @@ -2,9 +2,9 @@ * * $RCSfile: store.hxx,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change: $Author: mhu $ $Date: 2001-03-13 20:28:07 $ + * last change: $Author: mhu $ $Date: 2001-11-03 19:21:04 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -60,7 +60,7 @@ ************************************************************************/ #ifndef _STORE_STORE_HXX_ -#define _STORE_STORE_HXX_ "$Revision: 1.2 $" +#define _STORE_STORE_HXX_ "$Revision: 1.3 $" #ifndef _SAL_TYPES_H_ #include <sal/types.h> @@ -85,19 +85,42 @@ namespace store class OStoreStream { public: + /** Construction. + */ inline OStoreStream (void) SAL_THROW(()); + + /** Destruction. + */ inline ~OStoreStream (void) SAL_THROW(()); + /** Copy construction. + */ inline OStoreStream ( const OStoreStream& rOther) SAL_THROW(()); + + /** Assignment. + */ inline OStoreStream& operator= ( const OStoreStream& rOther) SAL_THROW(()); + + /** Construction from Stream Handle. + */ inline OStoreStream (storeStreamHandle Handle) SAL_THROW(()); + + /** Conversion into Stream Handle. + */ inline operator storeStreamHandle (void) const SAL_THROW(()); + /** Check for a valid Stream Handle. + @return sal_True if valid, sal_False otherwise. + */ inline sal_Bool isValid (void) const SAL_THROW(()); + + /** Open the stream. + @see store_openStream() + */ inline storeError create ( storeFileHandle hFile, const rtl::OUString &rPath, @@ -105,8 +128,14 @@ public: storeAccessMode eMode ) SAL_THROW(()); + /** Close the stream. + @see store_closeStream() + */ inline void close (void) SAL_THROW(()); + /** Read from the stream. + @see store_readStream() + */ inline storeError readAt ( sal_uInt32 nOffset, void *pBuffer, @@ -114,6 +143,9 @@ public: sal_uInt32 &rnDone ) SAL_THROW(()); + /** Write to the stream. + @see store_writeStream() + */ inline storeError writeAt ( sal_uInt32 nOffset, const void *pBuffer, @@ -121,10 +153,19 @@ public: sal_uInt32 &rnDone ) SAL_THROW(()); + /** Flush the stream. + @see store_flushStream() + */ inline storeError flush (void) const SAL_THROW(()); + /** Get the stream size. + @see store_getStreamSize() + */ inline storeError getSize (sal_uInt32 &rnSize) const SAL_THROW(()); + /** Set the stream size. + @see store_setStreamSize() + */ inline storeError setSize (sal_uInt32 nSize) SAL_THROW(()); private: @@ -141,20 +182,41 @@ private: class OStoreDirectory { public: + /** Construction. + */ inline OStoreDirectory (void) SAL_THROW(()); + + /** Destruction. + */ inline ~OStoreDirectory (void) SAL_THROW(()); + /** Copy construction. + */ inline OStoreDirectory ( const OStoreDirectory& rOther) SAL_THROW(()); + + /** Assignment. + */ inline OStoreDirectory& operator= ( const OStoreDirectory& rOther) SAL_THROW(()); + + /** Construction from Directory Handle. + */ inline OStoreDirectory (storeDirectoryHandle Handle) SAL_THROW(()); + + /** Conversion into Directory Handle. + */ inline operator storeDirectoryHandle (void) const SAL_THROW(()); + /** Check for a valid Directory Handle. + @return sal_True if valid, sal_False otherwise. + */ inline sal_Bool isValid (void) const SAL_THROW(()); - /** create. + + /** Open the directory. + @see store_openDirectory() */ inline storeError create ( storeFileHandle hFile, @@ -163,25 +225,48 @@ public: storeAccessMode eMode ) SAL_THROW(()); - /** close. + /** Close the directory. + @see store_closeDirectory() */ inline void close (void) SAL_THROW(()); - /** Iteration. + + /** Directory iterator type. + @see first() + @see next() */ typedef storeFindData iterator; + /** Find first directory entry. + @see store_findFirst() + */ inline storeError first (iterator& it) SAL_THROW(()); + + /** Find next directory entry. + @see store_findNext() + */ inline storeError next (iterator& it) SAL_THROW(()); - /** Traversal. + /** Directory traversal helper. + @see travel() */ class traveller { public: + /** Directory traversal callback. + @param it [in] current directory entry. + @return sal_True to continue iteration, sal_False to stop. + */ virtual sal_Bool visit (const iterator& it) = 0; }; + /** Directory traversal. + @see store_findFirst() + @see store_findNext() + + @param rTraveller [in] the traversal callback. + @return store_E_NoMoreFiles upon end of iteration. + */ inline storeError travel (traveller& rTraveller) const; private: @@ -198,40 +283,78 @@ private: class OStoreFile { public: + /** Construction. + */ inline OStoreFile (void) SAL_THROW(()); + + /** Destruction. + */ inline ~OStoreFile (void) SAL_THROW(()); - inline OStoreFile ( - const OStoreFile& rOther) SAL_THROW(()); - inline OStoreFile& operator= ( - const OStoreFile& rOther) SAL_THROW(()); + /** Copy construction. + */ + inline OStoreFile (const OStoreFile& rOther) SAL_THROW(()); + + /** Assignment. + */ + inline OStoreFile& operator= (const OStoreFile& rOther) SAL_THROW(()); + + /** Construction from File Handle. + */ inline OStoreFile (storeFileHandle Handle) SAL_THROW(()); + + /** Conversion into File Handle. + */ inline operator storeFileHandle (void) const SAL_THROW(()); + /** Check for a valid File Handle. + @return sal_True if valid, sal_False otherwise. + */ inline sal_Bool isValid (void) const SAL_THROW(()); + + /** Open the file. + @see store_openFile() + */ inline storeError create ( const rtl::OUString &rFilename, storeAccessMode eAccessMode, sal_uInt16 nPageSize = STORE_DEFAULT_PAGESIZE ) SAL_THROW(()); + /** Open the temporary file in memory. + @see store_createMemoryFile() + */ inline storeError createInMemory ( sal_uInt16 nPageSize = STORE_DEFAULT_PAGESIZE ) SAL_THROW(()); + /** Close the file. + @see store_closeFile() + */ inline void close (void) SAL_THROW(()); + /** Flush the file. + @see store_flushFile() + */ inline storeError flush (void) const SAL_THROW(()); + /** Get the number of referers to the file. + @see store_getFileRefererCount() + */ inline storeError getRefererCount ( sal_uInt32 &rnRefCount) const SAL_THROW(()); + /** Get the file size. + @see store_getFileSize() + */ inline storeError getSize ( sal_uInt32 &rnSize) const SAL_THROW(()); - /** Directory and Stream Manipulation. + + /** Set attributes of a file entry. + @see store_attrib() */ inline storeError attrib ( const rtl::OUString &rPath, @@ -241,6 +364,9 @@ public: sal_uInt32 &rnAttrib ) SAL_THROW(()); + /** Set attributes of a file entry. + @see store_attrib() + */ inline storeError attrib ( const rtl::OUString &rPath, const rtl::OUString &rName, @@ -248,21 +374,33 @@ public: sal_uInt32 nMask2 ) SAL_THROW(()); + /** Insert a file entry as 'hard link' to another file entry. + @see store_link() + */ inline storeError link ( const rtl::OUString &rSrcPath, const rtl::OUString &rSrcName, const rtl::OUString &rDstPath, const rtl::OUString &rDstName ) SAL_THROW(()); + /** Insert a file entry as 'symbolic link' to another file entry. + @see store_symlink() + */ inline storeError symlink ( const rtl::OUString &rSrcPath, const rtl::OUString &rSrcName, const rtl::OUString &rDstPath, const rtl::OUString &rDstName ) SAL_THROW(()); + /** Rename a file entry. + @see store_rename() + */ inline storeError rename ( const rtl::OUString &rSrcPath, const rtl::OUString &rSrcName, const rtl::OUString &rDstPath, const rtl::OUString &rDstName ) SAL_THROW(()); + /** Remove a file entry. + @see store_remove() + */ inline storeError remove ( const rtl::OUString &rPath, const rtl::OUString &rName |