annotate engine/core/model/metamodel/object.i @ 285:37d2b163ef5a

* Replaced preprocessor variable __linux__ with __unix__ * Wrapped entire content of setNativeCursor() within preprocessor directives (should fix #354)
author cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
date Fri, 19 Jun 2009 17:36:16 +0000
parents 8eec4c078223
children 6177cdf72489
rev   line source
46
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
1 /***************************************************************************
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
2 * Copyright (C) 2005-2008 by the FIFE team *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
3 * http://www.fifengine.de *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
4 * This file is part of FIFE. *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
5 * *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
6 * FIFE is free software; you can redistribute it and/or *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
7 * modify it under the terms of the GNU Lesser General Public *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
8 * License as published by the Free Software Foundation; either *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
9 * version 2.1 of the License, or (at your option) any later version. *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
10 * *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
11 * This library is distributed in the hope that it will be useful, *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
14 * Lesser General Public License for more details. *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
15 * *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
16 * You should have received a copy of the GNU Lesser General Public *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
17 * License along with this library; if not, write to the *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
18 * Free Software Foundation, Inc., *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
19 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA *
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
20 ***************************************************************************/
90005975cdbb * Final LGPL switch step by adjusting the file headers
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 0
diff changeset
21
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
22 %module fife
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
23 %{
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
24 #include "model/metamodel/object.h"
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
25 %}
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
26
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
27 %include "util/base/utilbase.i"
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
28 %include "model/metamodel/abstractvisual.i"
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
29
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
30 namespace FIFE {
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
31
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
32 class Action;
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
33 class AbstractPather;
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
34
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
35 class Object : public ResourceClass {
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
36 public:
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
37 Object(const std::string& identifier, const std::string& name_space, Object* inherited=NULL);
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
38 ~Object();
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
39
267
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
40 const std::string& getId() const { return m_id; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
41 const std::string& getNamespace() const { return m_namespace; }
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
42
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
43 Action* createAction(const std::string& identifier, bool is_default=false);
267
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
44 Action* getAction(const std::string& identifier) const;
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
45 Action* getDefaultAction() const { return m_defaultaction; }
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
46
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
47 void setPather(AbstractPather* pather);
267
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
48 AbstractPather* getPather() const { return m_pather; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
49
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
50 Object* getInherited() const { return m_inherited; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
51 void adoptVisual(AbstractVisual* visual) { m_visual = visual; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
52 template<typename T> T* getVisual() const { return reinterpret_cast<T*>(m_visual); }
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
53
267
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
54 void setBlocking(bool blocking) { m_blocking = blocking; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
55 bool isBlocking() const;
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
56
267
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
57 void setStatic(bool stat) { m_static = stat; }
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
58 bool isStatic() const;
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
59
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
60 bool operator==(const Object& obj) const;
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
61 bool operator!=(const Object& obj) const;
8eec4c078223 * Removed ObjectLoader as it was both unused and unusable (Closes #353)
cheesesucker@33b003aa-7bff-0310-803a-e67f0ece8222
parents: 46
diff changeset
62
0
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
63 };
4a0efb7baf70 * Datasets becomes the new trunk and retires after that :-)
mvbarracuda@33b003aa-7bff-0310-803a-e67f0ece8222
parents:
diff changeset
64 }