Exemplo n.º 1
0
        /// <summary>
        /// Gets the name of the command from the list
        /// </summary>
        /// <param name="command">The ServiceCommand</param>
        /// <returns>The "name" of the command within the Service Management API</returns>
        public string GetCommandName(ServiceCommand command)
        {
            if (CommandNameMapContainer.ContainsKey(command.GetType()))
            {
                return CommandNameMapContainer[command.GetType()];
            }

            return command.GetType().Name;
        }
 /// <summary>
 /// Gets the name of the command from the list
 /// </summary>
 /// <param name="command">The ServiceCommand</param>
 /// <returns>The "name" of the command within the Service Management API</returns>
 public string GetCommandName(ServiceCommand command)
 {
     string commandType = CommandNameMapContainer[command.GetType()];
     if (commandType == null)
         return command.ToString();
     return commandType;
 }