OpenTwin 0.1
OpenTwin
 
Loading...
Searching...
No Matches
EntityBlockPython.h
Go to the documentation of this file.
1#pragma once
2
3#include "EntityBlock.h"
4
5class __declspec(dllexport) EntityBlockPython : public EntityBlock
6{
7public:
8 EntityBlockPython(ot::UID ID, EntityBase* parent, EntityObserver* obs, ModelState* ms, ClassFactoryHandler* factory, const std::string& owner);
9 virtual std::string getClassName(void) override { return "EntityBlockPython"; };
10 virtual entityType getEntityType(void) override { return TOPOLOGY; }
11 void createProperties(const std::string& scriptFolder, ot::UID scriptFolderID);
12 std::string getSelectedScript();
13 virtual ot::GraphicsItemCfg* CreateBlockCfg() override;
14 virtual bool updateFromProperties() override;
15
16 static const std::string getIconName() { return "Script.svg"; }
17private:
18 const std::string _propertyNameScripts = "Scripts";
19
20 void updateBlockAccordingToScriptHeader();
21 void resetBlockRelatedAttributes();
22};
The GraphicsItemCfg is the base class for all graphics item configurations.
Definition GraphicsItemCfg.h:33
unsigned long UID
Unique identifier (32 bit unsigned integer)
Definition CoreTypes.h:27