Ejemplo n.º 1
0
    public void AddOneHttpCallBack(Action <SnapRpcDataVO> action, SnapRpcDataVO data)
    {
        SnapHttpCallBack http = new SnapHttpCallBack();

        http.actionCallBack = action;
        http.dataVO         = data;
        callBackList.Add(http);
    }
Ejemplo n.º 2
0
    public void update()
    {
        double current_time = SystemTime.timeSinceLaunch;

        if (current_time - last_time < 0.15)
        {
            return;
        }
        last_time = current_time;
        if (callBackList.Count > 0)
        {
            SnapHttpCallBack callBack = callBackList[0];
            callBackList.RemoveAt(0);
            if (callBack != null)
            {
                callBack.SendAction();
            }
        }
    }