Tellurium Plugins
Python ctypes wrapper documentation
Main Page
Related Pages
Modules
Examples
All
Functions
Variables
Groups
Pages
telGetPluginInformation.py
This example shows
How to create a plugin manager
Get Plugin Names
Get a handle to a plugin
Obtain some info from the plugin
1
from
teplugins
import
*
2
3
try
:
4
# Create a plugin manager
5
pm =
createPluginManager
()
6
7
# Load plugins from the plugin folder
8
result =
loadPlugins
(pm)
9
10
print
'Number of Plugins: '
+ `
getNumberOfPlugins
(pm)`
11
print
'Plugin Names: '
+ `
getPluginNames
(pm)`
12
13
#Go trough all plugins and print information
14
aPlugin =
getFirstPlugin
(pm)
15
while
True
:
16
if
aPlugin ==
None
:
17
break
18
print
'=========================================='
19
print
'Name: '
+ `
getPluginName
(aPlugin)`
20
print
'Author: '
+ `
getPluginAuthor
(aPlugin)`
21
print
'Copyright: '
+ `
getPluginCopyright
(aPlugin)`
22
print
'Version: '
+ `
getPluginVersion
(aPlugin)`
23
print
'Category: '
+ `
getPluginCategory
(aPlugin)`
24
print
'Description:'
+ `
getPluginDescription
(aPlugin)`
25
print
'Parameters: '
+ `
getListOfPluginPropertyNames
(aPlugin)`
26
27
#get next plugin
28
aPlugin =
getNextPlugin
(pm)
29
30
unLoadPlugins
(pm)
31
32
except
Exception
as
e:
33
print
'There was a problerm: '
+ `e`
Generated on Mon Mar 31 2014 14:36:34 for Tellurium Plugins by
1.8.4