Max Horn
8b1d7b9166
When including files from common/, explicitly use the common/ prefix
...
svn-id: r18444
2005-06-24 15:23:51 +00:00
Max Horn
b75c969e66
Moved class File and the MD5 stuff to namespace Common
...
svn-id: r18037
2005-05-10 22:56:25 +00:00
Max Horn
83d8166696
Fix another doyxgen warning
...
svn-id: r17933
2005-05-06 13:10:58 +00:00
Max Horn
54bf9bf1ad
Turned File::exists into a static method (as it should have been from the start, silly copy&paste mistake
...
svn-id: r17915
2005-05-05 11:53:43 +00:00
Max Horn
969ef3dac9
* Added new virtual base class 'Stream', ReadStream and
...
WriteStream are now subclasses of it.
* Added new methods eos(), ioFailed(), clearIOFailed() to
all streams. This allows better error checking.
* SaveFile classes take advantage of these new standard
stream APIS
* Removed File::gets()
* Added SeekableReadStream::readLine() (replaces File::gets)
* Added WriteStream::writeString, for convenience
svn-id: r17752
2005-04-22 17:40:09 +00:00
Max Horn
bc44b5ec15
Added new interface SeekableReadStream
...
svn-id: r16493
2005-01-09 01:41:43 +00:00
Max Horn
47280d9433
Updated copyright
...
svn-id: r16398
2005-01-01 16:09:25 +00:00
Max Horn
b78ac6a18b
Make use of our String class instead of juggling with char pointers; added File::exists method
...
svn-id: r15913
2004-11-27 15:09:53 +00:00
Eugene Sandulenko
54dc902ae4
Add gets() method to File class.
...
svn-id: r15572
2004-10-16 13:09:52 +00:00
Max Horn
17ec7c5d6a
Turn various File class methods into virtual methods, to allow overloading
...
svn-id: r14341
2004-07-26 17:06:39 +00:00
Max Horn
3381b831eb
Allow subclasses to modify File class members (e.g. to set _ioFailed); change some warnings into errors
...
svn-id: r14302
2004-07-23 01:39:05 +00:00
Max Horn
a5df4fba77
Added simple ref-counting to the File class
...
svn-id: r14106
2004-06-28 22:34:22 +00:00
Max Horn
53af3dc670
Enhanced default directory support in the File class; now one can specify arbitrary many default search directories
...
svn-id: r14095
2004-06-28 00:06:31 +00:00
Max Horn
b8ad54b3af
Reversed param order of File::open() -- this allowed me to get rid of a few more getGameDataPath() calls
...
svn-id: r14090
2004-06-27 22:14:35 +00:00
Max Horn
9defe4fc18
Removed XOR encoding stuff from File class; instead the new Scumm::XORFile class provides this functionality now
...
svn-id: r13597
2004-04-17 16:29:03 +00:00
Max Horn
e17a15d96e
Introduce ReadStream and WriteStream (as explained in my File class design mails on scummvm-devel)
...
svn-id: r13595
2004-04-17 09:57:15 +00:00
Max Horn
033ff78ae9
updated copyright notice
...
svn-id: r12176
2004-01-06 12:45:34 +00:00
Max Horn
88873d5b31
be stricter about File::open params
...
svn-id: r11919
2003-12-25 17:52:25 +00:00
Max Horn
81f210544a
cleanup
...
svn-id: r11432
2003-11-30 00:06:27 +00:00
Jonathan Gray
db716d5fb1
add method to set the xor byte in the file class. Needed as the combined mac data files are only xor'd in the resource files, not the parts of the combined file
...
svn-id: r10825
2003-10-16 10:23:01 +00:00
Max Horn
5301edc383
some cleanup
...
svn-id: r10720
2003-10-10 13:55:08 +00:00
Max Horn
468275bb94
added a static method setDefaultDirectory to class File; used this to simplify some code; added a global g_sound pointer in bs2, this cuts down on uses of g_sword2 (of course both should be removed on the long run); some other minor tweaks/fixes
...
svn-id: r10278
2003-09-17 21:06:16 +00:00
Max Horn
0df319e952
#include cleanup (explicityl specify the location for headers from common/, so that we at some point can get rid of -Icommon; exception is made for stdafx.h, since a) we might want to rename it and b) might want to move it to the top level)
...
svn-id: r9359
2003-08-01 12:21:04 +00:00
Max Horn
2db275b109
make File constructor virtual to allow subclassing; made seek default to SEEK_SET mode for conveniance
...
svn-id: r8587
2003-06-21 20:21:40 +00:00
Max Horn
2dd2e99cab
the _encbyte code was evil, because it modified the memory passed to write(); worse, though, it incremented ptr2, which then was later passed to fwrite - hence if used to write something while _encbyte != 0, write() resulted in wrong data being written
...
svn-id: r8055
2003-05-28 19:03:12 +00:00
Paweł Kołodziejski
aa3766018f
updated copyrights headers
...
svn-id: r6726
2003-03-06 21:46:56 +00:00
Max Horn
7692091a9c
File object stores file name (useful for debugging)
...
svn-id: r6089
2002-12-24 02:02:53 +00:00
Max Horn
ca5a230d33
indention fix :-)
...
svn-id: r5492
2002-11-10 14:54:21 +00:00
Max Horn
8af300fec3
The terms Word and DWord are somewhat Windows centric; in fact there are systems on which word is 32bit, as opposed to our 16 bits. Hence, use the uin16/uint32 naming scheme, which is not ambigious
...
svn-id: r5216
2002-10-21 13:23:25 +00:00
Paweł Kołodziejski
f7ff5c67fa
improved open function in File class
...
svn-id: r4945
2002-09-15 19:28:34 +00:00
Max Horn
f2da602963
factored out the case-insensitive fopen into its own function - makes it easier to adapt all the code to use it. TODO: improve it to work like in exult, i.e. sometimes other parts of the path have to be changed to upper/lower case (e.g. video vs. VIDEO)
...
svn-id: r4935
2002-09-13 18:02:34 +00:00
Max Horn
fd91bb67dc
ugh! yes, negative offsets for seek do occur! Thus using an unsigned isn't such a good choice for the offset parameter
...
svn-id: r4927
2002-09-13 12:16:03 +00:00
Max Horn
523d8e64c0
rewrote config class; cleanup; code restructuring
...
svn-id: r4903
2002-09-08 01:08:12 +00:00
Paweł Kołodziejski
5b4f2cefef
added write support to File
...
svn-id: r4900
2002-09-02 22:06:26 +00:00
Paweł Kołodziejski
ca03c9b5fc
changed file io in sounds to class File
...
svn-id: r4896
2002-09-02 07:53:43 +00:00
Paweł Kołodziejski
e8c4f2099c
updated
...
svn-id: r4875
2002-08-31 09:55:58 +00:00
Paweł Kołodziejski
bd7b93061b
added class File
...
svn-id: r4873
2002-08-31 07:43:34 +00:00