HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
GD_IOClassic.h
Go to the documentation of this file.
1 /*
2  * PROPRIETARY INFORMATION. This software is proprietary to
3  * Side Effects Software Inc., and is not to be reproduced,
4  * transmitted, or disclosed in any way without written permission.
5  *
6  * NAME: GD_IOClassic.h ( GA Library, C++)
7  *
8  * COMMENTS:
9  */
10 
11 #ifndef __GD_IOClassic__
12 #define __GD_IOClassic__
13 
14 #include "GD_API.h"
15 #include <GA/GA_IO.h>
16 
17 /// GU implementation of I/O
18 class GD_API GD_IOClassic : public GA_IO
19 {
20 public:
21  GD_IOClassic();
22  ~GD_IOClassic() override;
23 
24  /// @{
25  /// Methods required to implement GA_IO interface
26  const char *getToken() const override;
27  const char *getLabel() const override;
28  bool checkFilename(const char *filename,
29  const GA_SaveOptions *opts) const override;
30  bool checkFilename(const char *filename,
31  const GA_LoadOptions *opts) const override;
32  bool checkByteMagic(uint8 first_byte,
33  const GA_LoadOptions *opts) const override;
34  bool statStream(UT_IStream &is,
35  GA_Stat &stat, uint stat_level) const override;
36  bool readStream(GA_Detail &g,
37  UT_IStream &is,
38  const GA_LoadOptions *opts,
39  UT_StringArray *errors) const override;
40  bool writeFile(const GA_Detail &g,
41  const char *filename,
42  const GA_SaveOptions *opts,
43  UT_StringArray *errors) const override;
44  bool writeStream(const GA_Detail &g,
45  std::ostream &os,
46  bool binary,
47  const GA_SaveOptions *opts,
48  UT_StringArray *errors) const override;
49  /// @}
50 
51 protected:
52  /// @{
53  /// Configuration from GA_IO
54  bool readCheckStdin() const override { return true; }
55  bool readCheckCompressed() const override { return true; }
56  bool writeCheckStdout() const override { return true; }
57  /// @}
58 };
59 
60 #endif
61 
bool readCheckStdin() const override
Definition: GD_IOClassic.h:54
GT_API const UT_StringHolder filename
const GLuint GLenum const void * binary
Definition: glcorearb.h:1924
GLboolean GLboolean g
Definition: glcorearb.h:1222
virtual bool writeStream(const GA_Detail &g, std::ostream &os, bool binary, const GA_SaveOptions *opts, UT_StringArray *errors) const =0
Write geometry to an output stream.
bool readCheckCompressed() const override
Definition: GD_IOClassic.h:55
unsigned char uint8
Definition: SYS_Types.h:36
GU implementation of I/O.
Definition: GD_IOClassic.h:18
virtual bool writeFile(const GA_Detail &g, const char *filename, const GA_SaveOptions *opts, UT_StringArray *errors) const
virtual bool readStream(GA_Detail &g, UT_IStream &is, const GA_LoadOptions *opts, UT_StringArray *errors) const =0
Load geometry from an input stream.
Class to return information about a GA_Detail.
Definition: GA_Stat.h:50
bool writeCheckStdout() const override
Definition: GD_IOClassic.h:56
#define GD_API
Definition: GD_API.h:10
Container class for all geometry.
Definition: GA_Detail.h:96
Class to specify options for loading geometry.
unsigned int uint
Definition: SYS_Types.h:45