public static CommandError IncompleteComponent(string key, ComponentArgument component) { return(CommandError.InvalidChatComponent($"A {key} component needs at least {component.StringifyChildrenKeys()}")); }
public static CommandError UnknownComponent(IJsonArgument json) { return(CommandError.InvalidChatComponent($"Don't know how to turn {json.AsJson()} into a component")); }
public static CommandError EmptyComponent() { return(CommandError.InvalidChatComponent($"Empty array")); }
public static CommandError InvalidComponentArray(string key, JsonArgumentType expected, JsonArgumentType received) { return(CommandError.InvalidChatComponent($"Expected values in {key} array to be {expected.GetDisplayName()}, was {received.GetDisplayName()}")); }
public static CommandError EndOfInput() { return(CommandError.InvalidChatComponent($"End of input")); }
public static CommandError MalformedJson() { return(CommandError.InvalidChatComponent($"Malformed JSON")); }
public static CommandError ExpectedNameValueSeparator() { return(CommandError.InvalidChatComponent($"Expected '{NAME_VALUE_SEPARATOR}'")); }
public static CommandError UnterminatedString() { return(CommandError.InvalidChatComponent($"Unterminated string")); }
public static CommandError InvalidEscapeSequence() { return(CommandError.InvalidChatComponent($"Invalid escape sequence")); }
public static CommandError InvalidUnicodeCharacter(string unicode) { return(CommandError.InvalidChatComponent($"{ESCAPE_CHARACTER}{UNICODE_CHARACTER}{unicode}")); }
public static CommandError UnterminatedEscapeSequence() { return(CommandError.InvalidChatComponent($"Unterminated escape sequence")); }