Kross::Python::PythonModule Class Reference

#include <pythonmodule.h>

Inheritance diagram for Kross::Python::PythonModule:

Inheritance graph
[legend]
Collaboration diagram for Kross::Python::PythonModule:

Collaboration graph
[legend]
List of all members.

Detailed Description

The PythonModule is the __main__ python environment used as global object namespace.

The module also spends access to the whole Kross functionality and manages all the PythonExtension modules.

Definition at line 44 of file pythonmodule.h.

Public Member Functions

 PythonModule (PythonInterpreter *interpreter)
virtual ~PythonModule ()
Py::Dict getDict ()


Constructor & Destructor Documentation

PythonModule::PythonModule PythonInterpreter interpreter  ) 
 

Constructor.

Parameters:
interpreter The PythonInterpreter instance used to create this PythonModule.

Definition at line 51 of file pythonmodule.cpp.

References Kross::Python::PythonModulePrivate::m_interpreter.

00052     : Py::ExtensionModule<PythonModule>("__main__")
00053     , d(new PythonModulePrivate())
00054 {
00055 #ifdef KROSS_PYTHON_MODULE_DEBUG
00056     kdDebug() << QString("Kross::Python::PythonModule::Constructor") << endl;
00057 #endif
00058 
00059     d->m_interpreter = interpreter;
00060 
00061     add_varargs_method("_import", &PythonModule::import, "FIXME: Documentation");
00062 
00063     initialize("The PythonModule is the __main__ python environment used as global object namespace.");
00064 }

PythonModule::~PythonModule  )  [virtual]
 

Destructor.

Definition at line 66 of file pythonmodule.cpp.

00067 {
00068 #ifdef KROSS_PYTHON_MODULE_DEBUG
00069     kdDebug() << QString("Kross::Python::PythonModule::Destructor name='%1'").arg(name().c_str()) << endl;
00070 #endif
00071 
00072     delete d;
00073 }


Member Function Documentation

Py::Dict PythonModule::getDict  ) 
 

Returns:
the dictonary this PythonModule has.

Definition at line 75 of file pythonmodule.cpp.

00076 {
00077     return moduleDictionary();
00078 }


The documentation for this class was generated from the following files:
Generated on Thu Feb 9 18:01:33 2006 for Kross by  doxygen 1.4.6