/[ascend]/trunk/pygtk/method.cpp
ViewVC logotype

Contents of /trunk/pygtk/method.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 932 - (show annotations) (download) (as text)
Thu Nov 23 13:23:33 2006 UTC (13 years, 3 months ago) by johnpye
File MIME type: text/x-c++src
File size: 947 byte(s)
Working on bugs in the 'error_reporter_tree' stuff.
Removed binary files from base/generic/utilities/test (these are built as needed by SCons now)
1 #include <iostream>
2 #include <stdexcept>
3 using namespace std;
4
5 #include "method.h"
6
7 Method::Method() : initproc(NULL){
8 cerr << "EMPTY METHOD CREATED" << endl;
9 }
10
11 Method::Method(const Method &old) : initproc(old.initproc){
12 // nothing else
13 }
14
15 Method::Method(struct InitProcedure *initproc) : initproc(initproc){
16 //cerr << "CREATED METHOD, name = " << SCP( initproc->name ) << "..."<< endl;
17 }
18
19 Method::~Method(){
20 //cerr << "DESTROYED METHOD" << endl;
21 }
22
23 struct InitProcedure *
24 Method::getInternalType() const{
25 if(initproc==NULL)throw runtime_error("NULL initproc value");
26 return initproc;
27 }
28
29 const char*
30 Method::getName() const{
31 if(initproc==NULL)throw runtime_error("NULL initproc value");
32 return SCP( initproc->name );
33 }
34
35 SymChar
36 Method::getSym() const{
37 /// @TODO this is not efficient. couldn't make it work the right way though...
38 if(initproc==NULL)throw runtime_error("NULL initproc value");
39 return SymChar( SCP( initproc->name ));
40 }

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22