4 #include "xi-Construct.h"
10 class WhenStatementEChecker
;
16 /* Member of a chare or group, i.e. entry, RO or ROM */
17 class Member
: public Construct
{
18 // friend class CParsedFile;
24 Member() : container(0), tspec(0) {}
25 inline Chare
* getContainer() const { return container
; }
26 virtual void setChare(Chare
* c
) { container
= c
; }
27 virtual void preprocessSDAG() {}
28 virtual int isSdag(void) { return 0; }
29 virtual void collectSdagCode(SdagCollection
*) { return; }
30 virtual void collectSdagCode(WhenStatementEChecker
*) { return; }
31 XStr
makeDecl(const XStr
& returnType
, int forProxy
= 0, bool isStatic
= false, XStr fwdStr
= XStr());
32 virtual void genPythonDecls(XStr
&) {}
33 virtual void genIndexDecls(XStr
&) {}
34 virtual void genPythonDefs(XStr
&) {}
35 virtual void genPythonStaticDefs(XStr
&) {}
36 virtual void genPythonStaticDocs(XStr
&) {}
37 virtual void lookforCEntry(CEntry
*) {}
38 virtual void genTramTypes() {}
39 virtual bool isTramTarget() { return false; }
42 class Readonly
: public Member
{
43 int msg
; // is it a readonly var(0) or msg(1) ?
47 XStr
qName(void) const;
50 Readonly(int l
, Type
* t
, const char* n
, ValueList
* d
, int m
= 0);
51 void print(XStr
& str
);
52 void genDecls(XStr
& str
);
53 void genIndexDecls(XStr
& str
);
54 void genDefs(XStr
& str
);
55 void genReg(XStr
& str
);
58 class InitCall
: public Member
{
59 const char* name
; // Name of subroutine to call
62 // DMK - Accel Support
66 InitCall(int l
, const char* n
, int nodeCall
);
67 void print(XStr
& str
);
68 void genReg(XStr
& str
);
70 // DMK - Accel Support
71 void genAccels_spe_c_callInits(XStr
& str
);
78 class PUPableClass
: public Member
{
80 PUPableClass
* next
; // Linked-list of PUPable classes
82 PUPableClass(int l
, NamedType
* type_
, PUPableClass
* next_
);
83 void print(XStr
& str
);
84 void genDefs(XStr
& str
);
85 void genReg(XStr
& str
);
87 // DMK - Accel Support
88 int genAccels_spe_c_funcBodies(XStr
& str
);
89 void genAccels_spe_c_regFuncs(XStr
& str
);
90 void genAccels_spe_c_callInits(XStr
& str
);
91 void genAccels_spe_h_includes(XStr
& str
);
92 void genAccels_spe_h_fiCountDefs(XStr
& str
);
93 void genAccels_ppe_c_regFuncs(XStr
& str
);
96 class IncludeFile
: public Member
{
97 const char* name
; // Name of include file
99 IncludeFile(int l
, const char* name_
);
100 void print(XStr
& str
);
101 void genDecls(XStr
& str
);
104 class ClassDeclaration
: public Member
{
105 const char* name
; // Name of class
107 ClassDeclaration(int l
, const char* name_
);
108 void print(XStr
& str
);
109 void genDecls(XStr
& str
);
114 #endif // ifndef _MEMBER_H