CommandError
public enum CommandError : Error
Command Error Enum
- wrongFlagPattern: Received a wrong flag patter, such as
---f
- flagNeedsValue: Flag requires a value that was not set
- flagNotFound: Flag with name cannot be found
- requiredFlagsWasNotSet: Required flag was not set
- unexpectedFlagPassed: Parsed an unexpected flag name
- commandGeneralError: General command related error
- unknownError: Unknown error occured
- incorrectFlagValue: An incorrect value type was passed to the flag
- wrongCommandUsageString: Wrong usage string was passed to the command
- wrongFlagLongName: Wrong long name was passed for flag
- wrongFlagShortName: Wrong long name was passed for flag
-
Received a wrong flag patter, such as
---f
Declaration
Swift
case wrongFlagPattern(String)
-
Flag requires a value that was not set
Declaration
Swift
case flagNeedsValue(String, String)
-
Flag with name cannot be found
Declaration
Swift
case flagNotFound(String)
-
Required flag was not set
Declaration
Swift
case requiredFlagsWasNotSet(String, Any.Type)
-
parsed an unexpected flag name
Declaration
Swift
case unexpectedFlagPassed(String, [String])
-
general command related error
Declaration
Swift
case commandGeneralError(Command, Error)
-
unknown error occured
Declaration
Swift
case unknownError
-
an incorrect value type was passed to the flag
Declaration
Swift
case incorrectFlagValue(String, String)
-
Wrong usage string was passed to the command
Declaration
Swift
case wrongCommandUsageString(String)
-
Wrong long name was passed for flag
Declaration
Swift
case wrongFlagLongName(String)
-
Wrong short name was passed for flag
Declaration
Swift
case wrongFlagShortName(String)