當前位置: 首頁>>代碼示例>>C#>>正文


C# WrenVM.FindVariable方法代碼示例

本文整理匯總了C#中Wren.Core.VM.WrenVM.FindVariable方法的典型用法代碼示例。如果您正苦於以下問題:C# WrenVM.FindVariable方法的具體用法?C# WrenVM.FindVariable怎麽用?C# WrenVM.FindVariable使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Wren.Core.VM.WrenVM的用法示例。


在下文中一共展示了WrenVM.FindVariable方法的5個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的C#代碼示例。

示例1: LoadLibrary

        public static void LoadLibrary(WrenVM vm)
        {
            vm.Interpret("", "", MetaLibSource);

            ObjClass meta = (ObjClass)vm.FindVariable("Meta");
            vm.Primitive(meta.ClassObj, "eval(_)", Eval);
        }
開發者ID:robotii,項目名稱:Wren.NET,代碼行數:7,代碼來源:Meta.cs

示例2: LoadLibrary

 public static void LoadLibrary(WrenVM vm)
 {
     vm.Interpret("scheduler", "scheduler", _schedulerSource);
     ObjClass scheduler = (ObjClass)vm.FindVariable("scheduler", "Scheduler");
     vm.Primitive(scheduler.ClassObj, "captureMethods_()", CaptureMethods);
     vm.Interpret("scheduler", "scheduler", "Scheduler.captureMethods_()");
 }
開發者ID:robotii,項目名稱:Wren.NET,代碼行數:7,代碼來源:Scheduler.cs

示例3: LoadLibrary

        public static void LoadLibrary(WrenVM vm)
        {
            vm.Interpret("io", "io", IoSource);
            ObjClass file = (ObjClass)vm.FindVariable("io", "File");
            vm.Primitive(file.ClassObj, "open_(_,_)", Open);
            vm.Primitive(file.ClassObj, "sizePath_(_,_)", SizePath);

            vm.Primitive(file, "close_(_)", Close);
            vm.Primitive(file, "descriptor", Descriptor);
            vm.Primitive(file, "readBytes_(_,_)", ReadBytes);
            vm.Primitive(file, "size_(_)", Size);
        }
開發者ID:robotii,項目名稱:Wren.NET,代碼行數:12,代碼來源:io.cs

示例4: LoadIOLibrary

 public static void LoadIOLibrary(WrenVM vm)
 {
     vm.Interpret("", IOLibSource);
     ObjClass IO = (ObjClass)vm.FindVariable("IO").Obj;
     vm.Primitive(IO.ClassObj, "writeString_(_)", WriteString);
     vm.Primitive(IO.ClassObj, "read", Read);
     vm.Primitive(IO.ClassObj, "clock", Clock);
     vm.Primitive(IO.ClassObj, "time", Time);
 }
開發者ID:minirop,項目名稱:Wren.NET,代碼行數:9,代碼來源:System.cs

示例5: LoadLibrary

 public static void LoadLibrary(WrenVM vm)
 {
     vm.Interpret("timer", "timer", _timerSource);
     ObjClass timer = (ObjClass)vm.FindVariable("timer", "Timer");
     vm.Primitive(timer.ClassObj, "startTimer_(_,_)", StartTimer);
 }
開發者ID:robotii,項目名稱:Wren.NET,代碼行數:6,代碼來源:Timer.cs


注:本文中的Wren.Core.VM.WrenVM.FindVariable方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。