/* This function creates an alias for a shell command or if Alias is NULL it will delete an existing alias. */
EFI_STATUS EFIAPI EfiShellSetAlias(IN CONST CHAR16 *Command, IN CONST CHAR16 *Alias, IN BOOLEAN Replace, IN BOOLEAN Volatile)
/* This function creates an alias for a shell command or if Alias is NULL it will delete an existing alias. */
EFI_STATUS EFIAPI EfiShellSetAlias(IN CONST CHAR16 *Command, IN CONST CHAR16 *Alias, IN BOOLEAN Replace, IN BOOLEAN Volatile)
{
  if (ShellCommandIsOnAliasList ((Alias == NULL) ? Command : Alias)) {
    return (EFI_ACCESS_DENIED);
  } else if ((Command == NULL) || (*Command == CHAR_NULL) || (StrLen (Command) == 0)) {
    return (EFI_INVALID_PARAMETER);
  } else if ((EfiShellGetAlias (Command, NULL) != NULL) && !Replace) {
    return (EFI_ACCESS_DENIED);
  } else {
    return (InternalSetAlias (Command, Alias, Volatile));
  }
}