Package sop.exception
Class SOPGPException.UnsupportedProfile
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
sop.exception.SOPGPException
sop.exception.SOPGPException.UnsupportedProfile
- All Implemented Interfaces:
Serializable
- Enclosing class:
SOPGPException
The user provided a subcommand with an unsupported profile ("--profile=XYZ"),
or the user tried to list profiles of a subcommand that does not support profiles at all.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class sop.exception.SOPGPException
SOPGPException.AmbiguousInput, SOPGPException.BadData, SOPGPException.CannotDecrypt, SOPGPException.CertCannotEncrypt, SOPGPException.ExpectedText, SOPGPException.IncompatibleOptions, SOPGPException.IncompleteVerification, SOPGPException.KeyCannotSign, SOPGPException.KeyIsProtected, SOPGPException.MissingArg, SOPGPException.MissingInput, SOPGPException.NoSignature, SOPGPException.OutputExists, SOPGPException.PasswordNotHumanReadable, SOPGPException.UnsupportedAsymmetricAlgo, SOPGPException.UnsupportedOption, SOPGPException.UnsupportedProfile, SOPGPException.UnsupportedSpecialPrefix, SOPGPException.UnsupportedSubcommand -
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionUnsupportedProfile(String subcommand) Create an exception signalling a subcommand that does not support any profiles.UnsupportedProfile(String subcommand, String profile) Create an exception signalling a subcommand does not support a specific profile.UnsupportedProfile(String errorMsg, SOPGPException.UnsupportedProfile e) Wrap an exception into another instance with a possibly translated error message. -
Method Summary
Modifier and TypeMethodDescriptionintReturn the profile name.Return the subcommand name.Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
Field Details
-
EXIT_CODE
public static final int EXIT_CODE- See Also:
-
-
Constructor Details
-
UnsupportedProfile
Create an exception signalling a subcommand that does not support any profiles.- Parameters:
subcommand- subcommand
-
UnsupportedProfile
Create an exception signalling a subcommand does not support a specific profile.- Parameters:
subcommand- subcommandprofile- unsupported profile
-
UnsupportedProfile
Wrap an exception into another instance with a possibly translated error message.- Parameters:
errorMsg- error messagee- exception
-
-
Method Details
-
getSubcommand
Return the subcommand name.- Returns:
- subcommand
-
getProfile
Return the profile name. May returnnull
.- Returns:
- profile name
-
getExitCode
public int getExitCode()- Specified by:
getExitCodein classSOPGPException
-