public void StopwatchTest()
        {
            StopwatchManager.Start();
            System.Threading.Thread.Sleep(2000);
            StopwatchManager.Stop();
            Int64 time = StopwatchManager.ElapsedMilliseconds;

            Console.WriteLine("Time: " + time);
        }
Esempio n. 2
0
    public static int LogAllMessage_s(IntPtr l)
    {
        int result;

        try
        {
            StopwatchManager.LogAllMessage();
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Esempio n. 3
0
    public static int constructor(IntPtr l)
    {
        int result;

        try
        {
            StopwatchManager o = new StopwatchManager();
            LuaObject.pushValue(l, true);
            LuaObject.pushValue(l, o);
            result = 2;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Esempio n. 4
0
    public static int Start_s(IntPtr l)
    {
        int result;

        try
        {
            int watchID;
            LuaObject.checkType(l, 1, out watchID);
            StopwatchManager.Start(watchID);
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
Esempio n. 5
0
    public static int Enable_s(IntPtr l)
    {
        int result;

        try
        {
            bool bEnable;
            LuaObject.checkType(l, 1, out bEnable);
            StopwatchManager.Enable(bEnable);
            LuaObject.pushValue(l, true);
            result = 1;
        }
        catch (Exception e)
        {
            result = LuaObject.error(l, e);
        }
        return(result);
    }
 private void InitializeStopwatchManager()
 {
     StopwatchManager = StopwatchManager.Instance();
     StopwatchManager.WarmupAndStart();
 }
 // Token: 0x06006B4C RID: 27468 RVA: 0x001E1920 File Offset: 0x001DFB20
 public void OnApplicationQuit()
 {
     StopwatchManager.LogAllMessage();
 }
 public void SetUp()
 {
     // System under test.
     StopwatchManager = MyGame.Manager.StopwatchManager;
     StopwatchManager.Initialize();
 }