public string SetServerParameter(ServerParameterType ServerParameter) { string message = ""; if (ServerParameter.maxServerNotifications > 0) { maxServerNotifications = ServerParameter.maxServerNotifications; message += string.Format("Max Server Notifications set to {0}\n", maxServerNotifications); int removedItems = 0; lock (notificationListLock) { removedItems = CleanUpNotificationList(); } if (removedItems > 0) { message += string.Format("{0} Notifications removed from Server!\n", removedItems); } } else { message += string.Format("Max Server Notifications: no change ({0})\n", maxServerNotifications); } if (ServerParameter.maxTransferNotifications > 0) { maxTransferNotifications = ServerParameter.maxTransferNotifications; message += string.Format("Max Transfer Notifications set to {0}", maxTransferNotifications); } else { message += string.Format("Max Transfer Notifications: no change ({0})", maxTransferNotifications); } return(message); }
public ServerParameterType GetServerParameter(ServerParameterRequestType ServerParameterRequest) { ServerParameterType serverParameter = new ServerParameterType(); serverParameter.maxServerNotifications = maxServerNotifications; serverParameter.maxTransferNotifications = maxTransferNotifications; serverParameter.logFilePath = GetLogFilePath(); serverParameter.logFileSize = GetLogFileSize(); return(serverParameter); }