Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: orxonox.OLD/trunk/src/lib/script_engine/script_method.cc @ 8770

Last change on this file since 8770 was 8711, checked in by bensch, 18 years ago

merged the script_engine back here

File size: 1.1 KB
RevLine 
[8413]1/*
2   orxonox - the future of 3D-vertical-scrollers
3
4   Copyright (C) 2004 orx
5
6   This program is free software; you can redistribute it and/or modify
7   it under the terms of the GNU General Public License as published by
8   the Free Software Foundation; either version 2, or (at your option)
9   any later version.
10
11   ### File Specific:
[8711]12   main-programmer: Benjamin Grauer
[8413]13   co-programmer: ...
14*/
15
16//#define DEBUG_SPECIAL_MODULE DEBUG_MODULE_
17
18#include "script_method.h"
19
20/**
21 * @param standard constructor
22 * @todo this constructor is not jet implemented - do it
23*/
24ScriptMethod::ScriptMethod()
25{ }
26
27ScriptMethod* ScriptMethod::addMethod(const std::string& methodName, const Executor& executor)
28{
29  this->methods.push_back(ScriptMethod::Method(methodName, executor));
30
31  return this;
32}
33
34ScriptMethod::Method::Method(const std::string& name, const Executor& executor)
35{
36  this->name = name;
37  this->executor = executor.clone();
38}
39
40/**
41 * standard deconstructor
42*/
43ScriptMethod::~ScriptMethod()
44{
45  for (unsigned int i = 0; i < methods.size(); i ++)
46  {
47    delete methods[i].executor;
48  };
49}
Note: See TracBrowser for help on using the repository browser.