public void performAction(ProseRuntime runtime) { // Look up the type. MethodInfo methodInfo = typeWord.TypeObject.GetMethod(methodName, BindingFlags.Public | BindingFlags.Static); ProseLanguage.ActionDelegate delegateMethod = (ProseLanguage.ActionDelegate)Delegate.CreateDelegate(typeof(ProseLanguage.ActionDelegate), methodInfo); MethodNameWord methodNameWord = new MethodNameWord(rawWords, runtime, delegateMethod); runtime.addWord(methodNameWord); }
public MethodDelegateAction(MethodNameWord methodName, List <ProseObject> args) { this.methodName = methodName; this.args = args; this.method = methodName.DelegateMethod; }
public MethodNameWord(RawWord[] words, ProseRuntime runtime, ProseLanguage.ActionDelegate delegateMethod ) : base(words) { this.delegateMethod = delegateMethod; isa = new Word[] { runtime.word("@method") }; }
public MethodDelegateAction(MethodNameWord methodName, List<ProseObject> args) { this.methodName = methodName; this.args = args; this.method = methodName.DelegateMethod; }
public MethodNameWord(RawWord[] words, ProseRuntime runtime, ProseLanguage.ActionDelegate delegateMethod) : base(words) { this.delegateMethod = delegateMethod; isa = new Word[] { runtime.word("@method") }; }