1 |
#ifndef ASCXX_TYPE_H |
2 |
#define ASCXX_TYPE_H |
3 |
|
4 |
#include <vector> |
5 |
|
6 |
#include "config.h" |
7 |
extern "C"{ |
8 |
#include <utilities/ascConfig.h> |
9 |
#include <compiler/fractions.h> |
10 |
#include <compiler/compiler.h> |
11 |
#include <compiler/dimen.h> |
12 |
#include <compiler/child.h> |
13 |
#include <general/list.h> |
14 |
#include <compiler/module.h> |
15 |
#include <compiler/childinfo.h> |
16 |
#include <compiler/slist.h> |
17 |
#include <compiler/type_desc.h> |
18 |
} |
19 |
|
20 |
class Simulation; |
21 |
|
22 |
#include "symchar.h" |
23 |
#include "method.h" |
24 |
#include "dimensions.h" |
25 |
|
26 |
/** |
27 |
A model type as loaded from an ASCEND a4c file. For example, a type |
28 |
might be a 'test_controller' from the simple_fs.a4l example file. |
29 |
|
30 |
Once you have a type, you can create an instance of it (getInstance) |
31 |
which will then allow you to start on solving it. |
32 |
*/ |
33 |
class Type{ |
34 |
private: |
35 |
const TypeDescription *t; |
36 |
|
37 |
public: |
38 |
Type(); |
39 |
Type(const TypeDescription *t); |
40 |
const SymChar getName() const; |
41 |
const int getParameterCount() const; |
42 |
const TypeDescription *getInternalType() const; |
43 |
Simulation getSimulation(SymChar name); |
44 |
const Dimensions getDimensions() const; |
45 |
std::vector<Method> getMethods() const; |
46 |
const bool isRefinedSolverVar() const; ///< is this type a refinement of solver_var? |
47 |
const bool isRefinedAtom() const; |
48 |
const bool isRefinedReal() const; |
49 |
const bool isRefinedConstant() const; |
50 |
const bool isModel() const; |
51 |
const bool hasParameters() const; |
52 |
}; |
53 |
|
54 |
#endif |