示例#1
0
        public string DoAction(ServerActionType ServerAction)
        {
            string responseMessage = "";

            switch (ServerAction)
            {
            case ServerActionType.CLEAR_ALL_TASKS:
                lock (taskListLock)
                {
                    taskList.Clear();
                }
                responseMessage += "All Tasks removed from Server!";
                break;

            case ServerActionType.CLEAR_ALL_NOTIFICATIONS:
                lock (notificationListLock)
                {
                    serverNotificationList.Clear();
                }
                responseMessage += "All Notifications removed from Server!";
                break;
            }

            return(responseMessage);
        }
示例#2
0
 public void Decode(Hashtable data)
 {
     ActionType = (ServerActionType)data[(int)eServerActionKey.ActionType];
     ActionsParams = (Hashtable)data[(int)eServerActionKey.ActionParams];
 }
示例#3
0
 public NWServerAction(ServerActionType actionType, Hashtable actionParams)
 {
     ActionType = actionType;
     ActionsParams = actionParams;
 }