0022961: Dangerous usage of 'buf' (strncpy doesn't always 0-terminate it) (cppcheck...
[occt.git] / src / VrmlData / VrmlData_ImageTexture.hxx
1 // File:      VrmlData_ImageTexture.hxx
2 // Created:   25.05.06 16:08:10
3 // Author:    Alexander GRIGORIEV
4 // Copyright: Open Cascade 2006
5
6
7 #ifndef VrmlData_ImageTexture_HeaderFile
8 #define VrmlData_ImageTexture_HeaderFile
9
10 #include <VrmlData_Texture.hxx>
11
12 /**
13  *  Implementation of the ImageTexture node
14  */
15 class VrmlData_ImageTexture : public VrmlData_Texture
16 {
17  public:
18   // ---------- PUBLIC METHODS ----------
19
20   /**
21    * Empty constructor
22    */
23   inline VrmlData_ImageTexture ()
24   {}
25
26   /**
27    * Constructor
28    */
29   Standard_EXPORT VrmlData_ImageTexture
30                             (const VrmlData_Scene&  theScene,
31                              const char             * theName,
32                              const char             * theURL = 0L,
33                              const Standard_Boolean theRepS = Standard_False,
34                              const Standard_Boolean theRepT = Standard_False);
35
36   /**
37    * Query the associated URL.
38    */
39   inline const NCollection_List<TCollection_AsciiString>&
40                         URL     () const
41   { return myURL; }
42
43   /**
44    * Create a copy of this node.
45    * If the parameter is null, a new copied node is created. Otherwise new node
46    * is not created, but rather the given one is modified.
47    */
48   Standard_EXPORT virtual Handle(VrmlData_Node)
49                         Clone   (const Handle(VrmlData_Node)& theOther)const;
50
51   /**
52    * Read the Node from input stream.
53    */
54   Standard_EXPORT virtual VrmlData_ErrorStatus
55                         Read    (VrmlData_InBuffer& theBuffer);
56
57  protected:
58   // ---------- PROTECTED METHODS ----------
59
60
61
62  private:
63   // ---------- PRIVATE FIELDS ----------
64
65   NCollection_List<TCollection_AsciiString> myURL;
66
67  public:
68 // Declaration of CASCADE RTTI
69 DEFINE_STANDARD_RTTI (VrmlData_ImageTexture)
70 };
71
72 // Definition of HANDLE object using Standard_DefineHandle.hxx
73 DEFINE_STANDARD_HANDLE (VrmlData_ImageTexture, VrmlData_Texture)
74
75
76 #endif