pCon.planner Plugin SDK  Version 8.9
 All Classes Namespaces Functions Variables Typedefs Enumerations Enumerator Properties Events
Protected Attributes | Properties | List of all members
X3g::Plugin::Plugin Class Referenceabstract

The plugin interface. More...

Inheritance diagram for X3g::Plugin::Plugin:
Inheritance graph
[legend]

Public Member Functions

Required Interfaces
virtual System::String^ X3gGetGlobalIdentifier () override
 Must return a globally unique plugin identifier More...
 
virtual System::String^ X3gGetName () override
 Must return the plugin's name. More...
 
virtual System::String^ X3gGetVendor () override
 Must return the vendor the the plugin. More...
 
virtual System::String^ X3gGetDescription () override
 Must return the detailed plugin description. More...
 
virtual System::String^ X3gGetVersion () override
 Must return the version of the plugin. More...
 
virtual System::IntPtr X3gGetCustomData ()
 
Optional Notifications
virtual bool X3gInitialize (System::String^ pPluginPath)
 Notification, called once when the plugin is loaded. More...
 
virtual void X3gFinalize ()
 Notification, called once when the plugin is unloaded. More...
 
virtual void X3gActivate ()
 Notification, called when the plugin must reactivate itself. More...
 
virtual void X3gDeactivate ()
 Notification, called when the plugin must deactivate itself. More...
 
virtual void X3gEvent (EventType pEventType, Object^ pParameter)
 Called when the plugin receives an event. More...
 
Actions
virtual void X3gAction (System::String^ pActionKey, System::String^ pArguments)
 Executes an action with given optional arguments. More...
 
virtual bool X3gIsActionAvailable (System::String^ pActionKey)
 Checks if the given action is currently available. More...
 
virtual bool X3gSetWindowContent (Window^ pWindow)
 Requests plugin to set the window content. More...
 
virtual IEnumerable
< System::String^ >^ 
X3gGetContextMenuUIKeys ()
 Requests plugin to return UI keys for context menu items. More...
 
Threading
void Invoke (SendOrPostCallback^ pCallback, Object^ pParam, bool pWait)
 Invoke a function call from another thread. More...
 

Protected Attributes

IActionManagerX3gActions
 Actions.
 
IAppManagerX3gApp
 Application Services.
 
IArticleManagerX3gArticles
 Article handling.
 
IUndoManagerX3gUndo
 Undo/Redo.
 
IUtilitiesX3gUtils
 Utilities.
 

Properties

DocumentManager^  Document [get]
 Modify or change the currently open document. More...
 
GeometryManager^  Geometry [get]
 Covers various export formats and can be used for custom geometry exports. More...
 
Layout::LayoutManager^  Layouts [get]
 Manage Layout. More...
 
Logger^  Log [get]
 Logging functionality. More...
 
RendererManager^  Renderers [get]
 Manage Renderer available in the pCon.planner. More...
 
Room::RoomModule^  Rooms [get]
 Manage Rooms. More...
 
ViewManager^  Viewer [get]
 Manage the primary views and their arrangement. More...
 
WindowManager^  Windows [get]
 Create and manage dockable windows. More...
 
- Properties inherited from X3g::Plugin::IModuleProvider
DocumentManager^  Document [get]
 Modify or change the currently open document. More...
 
GeometryManager^  Geometry [get]
 Covers various export formats and can be used for custom geometry exports. More...
 
Layout::LayoutManager^  Layouts [get]
 Manage Layout. More...
 
Logger^  Log [get]
 Logging functionality. More...
 
RendererManager^  Renderers [get]
 Manage Renderer available in the pCon.planner. More...
 
Room::RoomModule^  Rooms [get]
 Manage Rooms. More...
 
ViewManager^  Viewer [get]
 Manage the primary views and their arrangement. More...
 
WindowManager^  Windows [get]
 Create and manage dockable windows. More...
 

Detailed Description

The plugin interface.

Services from the kernel are divided into several manager classes.
Each communication with the planner itself is done using one of the X3gXXX() functions of the plugin class or calling member functions
of the manager classes like DocumentManager.

A plugin processes data as a result of notification functions or events. Notification functions can be:

All geometry data classes have the Ge prefix while all database classes have a Db prefix.
There are also general geometry helper classes with Ge prefix like GeMatrix or GeVec3f.
For example, if you want to write some custom geometry export and are therefore only interested
in processing 3d geometry data regardless of the underlying database objects, use GeometryManager::GetSelectedGeometry().
On the other hand, if you are interested in the database entities, use e.g. DocumentManager::GetSelection().
You can also insert raw geometry from which database objects are created using GeometryManager::InsertGeometry().

Floating point values of database entities are stored with double precision.
The vectorization of database entities into OpenGL data uses single precision.
Therefore all GeDrawable objects are using float values, while DbEntity objects use double values.

Member Function Documentation

void X3g::Plugin::Plugin::Invoke ( SendOrPostCallback^  pCallback,
Object^  pParam,
bool  pWait 
)

Invoke a function call from another thread.

The plugin interface is not threadsafe. Direct calls are only allowed from the plugins main thread, otherwise Invoke() needs to be used.

Parameters
pCallbackThe function to be called in form of a SendOrPostCallback object.
pParamThe pParam parameter will be used as a parameter for the pCallback function.
pWaitIf pWait is true, the calling thread will wait/block until pCallback was executed.
virtual void X3g::Plugin::Plugin::X3gAction ( System::String^  pActionKey,
System::String^  pArguments 
)
virtual

Executes an action with given optional arguments.

virtual void X3g::Plugin::Plugin::X3gActivate ( )
virtual

Notification, called when the plugin must reactivate itself.

virtual void X3g::Plugin::Plugin::X3gDeactivate ( )
virtual

Notification, called when the plugin must deactivate itself.

virtual void X3g::Plugin::Plugin::X3gEvent ( EventType  pEventType,
Object^  pParameter 
)
virtual

Called when the plugin receives an event.

virtual void X3g::Plugin::Plugin::X3gFinalize ( )
virtual

Notification, called once when the plugin is unloaded.

virtual IEnumerable<System::String^> ^ X3g::Plugin::Plugin::X3gGetContextMenuUIKeys ( )
virtual

Requests plugin to return UI keys for context menu items.

This method is called before the context menu is opened. If the plugin wants to add items to the context menu it has to return the according UI keys here. UI keys may be action keys and widget keys as defined in the plugins .ui-file.

virtual System::String ^ X3g::Plugin::Plugin::X3gGetDescription ( )
pure virtual

Must return the detailed plugin description.

virtual System::String ^ X3g::Plugin::Plugin::X3gGetGlobalIdentifier ( )
pure virtual

Must return a globally unique plugin identifier

virtual System::String ^ X3g::Plugin::Plugin::X3gGetName ( )
pure virtual

Must return the plugin's name.

virtual System::String ^ X3g::Plugin::Plugin::X3gGetVendor ( )
pure virtual

Must return the vendor the the plugin.

virtual System::String ^ X3g::Plugin::Plugin::X3gGetVersion ( )
pure virtual

Must return the version of the plugin.

virtual bool X3g::Plugin::Plugin::X3gInitialize ( System::String^  pPluginPath)
virtual

Notification, called once when the plugin is loaded.

Should be used to register actions and do basic initialization. If the return value is false, the plugin will not be loaded.

No major processing should be done here. The application initialization is not finished at this point. Processing can be done after the event EventType::ApplicationReady was triggered.

virtual bool X3g::Plugin::Plugin::X3gIsActionAvailable ( System::String^  pActionKey)
virtual

Checks if the given action is currently available.

virtual bool X3g::Plugin::Plugin::X3gSetWindowContent ( Window pWindow)
virtual

Requests plugin to set the window content.

This method is called when windows are created through WindowManager and when windows are restored on application startup. Window creation will be canceled if this method returns false. This may be used in case of restore when the plugin has changed and particluar windows are no longer available.

Property Documentation

DocumentManager^ X3g::Plugin::Plugin::Document
get

Modify or change the currently open document.


Contains other manager related to the current document.
See Class reference for more information.

GeometryManager^ X3g::Plugin::Plugin::Geometry
get

Covers various export formats and can be used for custom geometry exports.

Layout:: LayoutManager^ X3g::Plugin::Plugin::Layouts
get

Manage Layout.

See Class reference for more information.

Logger^ X3g::Plugin::Plugin::Log
get

Logging functionality.

See Class reference for more information.

RendererManager^ X3g::Plugin::Plugin::Renderers
get

Manage Renderer available in the pCon.planner.

See Class reference for more information.

Room:: RoomModule^ X3g::Plugin::Plugin::Rooms
get

Manage Rooms.

See Class reference for more information.

ViewManager^ X3g::Plugin::Plugin::Viewer
get

Manage the primary views and their arrangement.

See Class reference for more information.

WindowManager^ X3g::Plugin::Plugin::Windows
get

Create and manage dockable windows.

See Class reference for more information.