static PWOrder() { // 2. Register a ACMethod-Template for this Workflow-Class ACMethod method = new ACMethod(ACStateConst.SMStarting); Dictionary <string, string> paramTranslation = new Dictionary <string, string>(); method.ParameterValueList.Add(new ACValue("SkipIfNoLines", typeof(bool), false, Global.ParamOption.Required)); paramTranslation.Add("SkipIfNoLines", "en{'Skip if no lines'}de{'Überspringe wenn keine Positionen'}"); var wrapper = new ACMethodWrapper(method, "en{'Configuration'}de{'Konfiguration'}", typeof(PWOrder), paramTranslation, null); ACMethod.RegisterVirtualMethod(typeof(PWOrder), ACStateConst.SMStarting, wrapper); // 3. Register static Method-Invocation-Handler for Client/Proxy-Side RegisterExecuteHandler(typeof(PWOrder), HandleExecuteACMethod_PWOrder); }
static PAFOrder() { // 2. Register a ACMethod-Template for this Function ACMethod method = new ACMethod("WriteOrder"); Dictionary <string, string> paramTranslation = new Dictionary <string, string>(); method.ParameterValueList.Add(new ACValue("Path", typeof(string), null, Global.ParamOption.Optional)); paramTranslation.Add("Path", "en{'Path'}de{'Path'}"); method.ParameterValueList.Add(new ACValue("FileName", typeof(string), null, Global.ParamOption.Optional)); paramTranslation.Add("FileName", "en{'FileName'}de{'FileName'}"); method.ParameterValueList.Add(new ACValue("Content", typeof(string), 0, Global.ParamOption.Required)); paramTranslation.Add("Content", "en{'Content'}de{'Content'}"); Dictionary <string, string> resultTranslation = new Dictionary <string, string>(); method.ResultValueList.Add(new ACValue("Duration", typeof(double), 0.0, Global.ParamOption.Required)); resultTranslation.Add("Duration", "en{'Duration[ms]'}de{'Duration[ms]'}"); var wrapper = new ACMethodWrapper(method, "en{'Write order'}de{'Auftrag schreiben'}", typeof(PWOrder), paramTranslation, resultTranslation); ACMethod.RegisterVirtualMethod(typeof(PAFOrder), ACStateConst.TMStart, wrapper); // 3. Register static Method-Invocation-Handler for Client/Proxy-Side RegisterExecuteHandler(typeof(PAFOrder), HandleExecuteACMethod_PAFOrder); }