Python scripting - Workmethod callbacks

PostWmInitRules

Previous  Chapter  Next

 

The callback PostWmInitRules(CENPyOlpWM_RuleInitOperator) is called just after the kernel initializes the workmethod event rules.

 

It can be used to:

- initialize workmethod event rules

- access OlpController

- output to the log

 

The callback is defined in the %WORKMETHOD_NAME%.py file that is located in the scripts folder of the plugin.

 

PostWmInitRules

 

[Example]

 

def PostTechInitAttributes(techAttribInitOperator):

 

def PostWmInitRules(wmRuleInitOperator):

   wmRuleInitOperator.AddPyEvent('myRetractRule', 'ZAxisEvent')

   wmRuleInitOperator.AddPyEvent('myRetractRule', 'GasEvent')

 


PostWmInitRules_Ex

 


Previous
Previous page
Chapter
Chapter page
Next
Next page