25 bool Open(
const std::string& aFilename );
30 template<
class XType >
31 bool Write( XType* aDatum );
32 template<
class XType >
33 bool Write( XType* aDatum,
size_t aCount );
36 bool Seek(
long int aCount );
41 template<
class XType >
42 bool Read( XType* aDatum );
43 template<
class XType >
44 bool Read( XType* aDatum,
size_t aCount );
55 size_t written = fwrite( anArray,
sizeof(
byte_type), aCount,
fFile );
56 return (written ==
sizeof(
byte_type) * aCount);
58 template<
class XType >
61 size_t written = fwrite( aDatum,
sizeof(XType), 1,
fFile );
62 return (written == 1);
64 template<
class XType >
67 size_t written = fwrite( aDatum,
sizeof(XType), aCount,
fFile );
68 return (written == aCount);
73 size_t success = fseek(
fFile, aCount, SEEK_CUR );
74 return( success == 0 );
80 return (read ==
sizeof(
byte_type) * aCount);
82 template<
class XType >
85 size_t read = fread( aDatum,
sizeof(XType), 1,
fFile );
88 template<
class XType >
91 size_t read = fread( aDatum,
sizeof(XType), aCount,
fFile );
92 return (read == aCount);
bool Seek(long int aCount)
bool Write(byte_type *anArray, size_t aCount)
bool Open(const std::string &aFilename)
bool Read(byte_type *anArray, size_t aCount)
M2IO(AccessModeType aMode)