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

Contents of /trunk/pygtk/interface/method.cpp

Parent Directory Parent Directory | Revision Log Revision Log


Revision 132 - (show annotations) (download) (as text)
Wed Dec 21 00:14:13 2005 UTC (15 years, 11 months ago) by johnpye
File MIME type: text/x-c++src
File size: 699 byte(s)
Adding the PyGTK interface to CMU repository. Whaddyareckon?
1 #include <iostream>
2 #include <stdexcept>
3 using namespace std;
4
5 #include "method.h"
6
7 Method::Method(){
8 throw runtime_error("Can't create new Methods, use Type.getMethods instead");
9 }
10
11 Method::Method(struct InitProcedure *initproc) : initproc(initproc){
12 //cerr << "CREATED METHOD, name = " << SCP( initproc->name ) << "..."<< endl;
13 }
14
15 Method::~Method(){
16 //cerr << "DESTROYED METHOD" << endl;
17 }
18
19 struct InitProcedure *
20 Method::getInternalType() const{
21 return initproc;
22 }
23
24 const char*
25 Method::getName() const{
26 return SCP( initproc->name );
27 }
28
29 SymChar
30 Method::getSym() const{
31 /// @TODO this is not efficient. couldn't make it work the right way though...
32 return SymChar( SCP( initproc->name ));
33 }

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