예제 #1
0
        public static void Receive(string methodProxyJson)
        {
            if (string.IsNullOrEmpty(methodProxyJson))
            {
                return;
            }

            MethodProxy resultProxy  = BridgeSerializer.Deserialize <MethodProxy>(methodProxyJson);
            var         taskToReturn = MethodDispatcher.GetTaskDispatcher(resultProxy.TaskIdentity);

            MethodDispatcher.SetTaskResult(resultProxy.TaskIdentity, resultProxy);

            if (taskToReturn == null)
            {
                return;
            }

            taskToReturn.RunSynchronously();

            MethodDispatcher.ClearTask(resultProxy.TaskIdentity);
        }
예제 #2
0
 public Task <string> GetRuntimePlatform()
 {
     return(MethodDispatcher.CallMethodAsync <string>(MethodBase.GetCurrentMethod()));
 }