Blender  V2.93
Interpreter.h
Go to the documentation of this file.
1 /*
2  * This program is free software; you can redistribute it and/or
3  * modify it under the terms of the GNU General Public License
4  * as published by the Free Software Foundation; either version 2
5  * of the License, or (at your option) any later version.
6  *
7  * This program is distributed in the hope that it will be useful,
8  * but WITHOUT ANY WARRANTY; without even the implied warranty of
9  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
10  * GNU General Public License for more details.
11  *
12  * You should have received a copy of the GNU General Public License
13  * along with this program; if not, write to the Free Software Foundation,
14  * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
15  */
16 
17 #pragma once
18 
24 #include <string>
25 
26 #ifdef WITH_CXX_GUARDEDALLOC
27 # include "MEM_guardedalloc.h"
28 #endif
29 
30 using namespace std;
31 
32 namespace Freestyle {
33 
34 class Interpreter {
35  public:
37  {
38  _language = "Unknown";
39  }
40 
41  virtual ~Interpreter()
42  {
43  }
44 
45  virtual int interpretFile(const string &filename) = 0;
46 
47  virtual string getLanguage() const
48  {
49  return _language;
50  }
51 
52  virtual void reset() = 0;
53 
54  protected:
55  string _language;
56 
57 #ifdef WITH_CXX_GUARDEDALLOC
58  MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Interpreter")
59 #endif
60 };
61 
62 } /* namespace Freestyle */
Read Guarded memory(de)allocation.
virtual int interpretFile(const string &filename)=0
virtual string getLanguage() const
Definition: Interpreter.h:47
virtual void reset()=0
inherits from class Rep
Definition: AppCanvas.cpp:32