VTFLib
A C and C++ API that, with a few simple functions, can open and save .vtf and .vmt files.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Pages
FileReader.h
1 /*
2  * VTFLib
3  * Copyright (C) 2005-2010 Neil Jedrzejewski & Ryan Gregg
4 
5  * This library is free software; you can redistribute it and/or
6  * modify it under the terms of the GNU Lesser General Public
7  * License as published by the Free Software Foundation; either
8  * version 2.1 of the License, or (at your option) any later
9  * version.
10  */
11 
12 #ifndef VTFLIB_FILEREADER_H
13 #define VTFLIB_FILEREADER_H
14 
15 #include "stdafx.h"
16 #include "Reader.h"
17 
18 namespace VTFLib
19 {
20  namespace IO
21  {
22  namespace Readers
23  {
24  class CFileReader : public IReader
25  {
26  private:
27  vlFile hFile;
28  vlChar *cFileName;
29 
30  public:
31  CFileReader(const vlChar *cFileName);
32  ~CFileReader();
33 
34  public:
35  virtual vlBool Opened() const;
36 
37  virtual vlBool Open();
38  virtual vlVoid Close();
39 
40  virtual vlSSize GetStreamSize() const;
41  virtual vlSSize GetStreamPointer() const;
42 
43  virtual vlSSize Seek(vlOffset lOffset, VLSeekMode uiMode);
44 
45  virtual vlBool Read(vlChar &cChar);
46  virtual vlSize Read(vlVoid *vData, vlSize uiBytes);
47  };
48  }
49  }
50 }
51 
52 #endif
char vlChar
Single signed character.
Definition: stdafx.h:51
Application framework header plus VTFLib custom data types.
void vlVoid
Void value.
Definition: stdafx.h:61
unsigned char vlBool
Boolean value 0/1.
Definition: stdafx.h:50