예제 #1
0
파일: Rpc.cs 프로젝트: wujun4code/Slark
        public static TMLobby RecallRpc(this IRpc host, TMLobby lobby)
        {
            var tupple = host.ReflectRpcFunctions();

            tupple.ForEach(t =>
            {
                lobby.Unregister(t.Item1);
            });
            return(lobby);
        }
예제 #2
0
        public static RpcServer UseRpc(this IRpc host, RpcServer server)
        {
            var tupple = host.ReflectRpcFunctions();

            tupple.ForEach(t =>
            {
                server.Register(t.Item1, t.Item2);
            });
            return(server);
        }