aboutsummaryrefslogtreecommitdiff
path: root/src/file.h
diff options
context:
space:
mode:
authorMike Buland <eichlan@xagasoft.com>2010-05-24 15:10:19 +0000
committerMike Buland <eichlan@xagasoft.com>2010-05-24 15:10:19 +0000
commitecc191f590f76584a14c9c51727412b0b7b3086e (patch)
treeb27ee434ed541ba3a386ff6a3238f66b9451ef22 /src/file.h
parent71191e311d949b1b7bdd74fc36a14306f492c181 (diff)
downloadlibbu++-ecc191f590f76584a14c9c51727412b0b7b3086e.tar.gz
libbu++-ecc191f590f76584a14c9c51727412b0b7b3086e.tar.bz2
libbu++-ecc191f590f76584a14c9c51727412b0b7b3086e.tar.xz
libbu++-ecc191f590f76584a14c9c51727412b0b7b3086e.zip
Changed the Bu::Stream API, setSize is now standard. There may be a few more
things that should be added. A few of them still need to be implemented. I know that truncate for Bu::File is possible on windows, I've used it before, but hell if I can find it. Myriad also needs the setSize function completed.
Diffstat (limited to 'src/file.h')
-rw-r--r--src/file.h12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/file.h b/src/file.h
index 5eca3c1..b2cd2a4 100644
--- a/src/file.h
+++ b/src/file.h
@@ -69,6 +69,9 @@ namespace Bu
69 WriteNew = 0x0E ///< Create a file (or truncate) for writing. 69 WriteNew = 0x0E ///< Create a file (or truncate) for writing.
70 /// Same as Write|Create|Truncate 70 /// Same as Write|Create|Truncate
71 }; 71 };
72
73 virtual void setSize( long iSize );
74
72 /** 75 /**
73 * Create a temp file and return its handle. The file is opened 76 * Create a temp file and return its handle. The file is opened
74 * Read/Write. 77 * Read/Write.
@@ -77,16 +80,9 @@ namespace Bu
77 * characters. 80 * characters.
78 *@returns (Bu::File) A file object representing your temp file. 81 *@returns (Bu::File) A file object representing your temp file.
79 */ 82 */
80#ifndef WIN32
81 static Bu::File tempFile( Bu::FString &sName ); 83 static Bu::File tempFile( Bu::FString &sName );
82 84
83 /** 85#ifndef WIN32
84 * Set the size of the file to (nSize). You can either grow or shrink
85 * the file.
86 *@param nSize (long) The new size of the file.
87 */
88 void truncate( long nSize );
89
90 /** 86 /**
91 * Change the file access permissions. 87 * Change the file access permissions.
92 *@param t (mode_t) The new file access permissions. 88 *@param t (mode_t) The new file access permissions.