Class EnforcerRuleException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.apache.maven.enforcer.rule.api.EnforcerRuleException
-
- All Implemented Interfaces:
Serializable
public class EnforcerRuleException extends Exception
An exception occurring during the execution of a rule. Based off of EnforcerRuleException, but separated to keep the rule dependencies to a minimum.- Author:
- Brian Fox
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected StringlongMessageThe long message.protected ObjectsourceThe source.
-
Constructor Summary
Constructors Constructor Description EnforcerRuleException(Object source, String shortMessage, String longMessage)Construct a newEnforcerRuleExceptionexception providing the source and a short and long message.EnforcerRuleException(String message)Construct a newEnforcerRuleExceptionexception providing amessage.EnforcerRuleException(String message, Exception cause)Construct a newEnforcerRuleExceptionexception wrapping an underlyingExceptionand providing amessage.EnforcerRuleException(String message, Throwable cause)Construct a newEnforcerRuleExceptionexception wrapping an underlyingThrowableand providing amessage.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetLongMessage()Gets the long message.ObjectgetSource()Gets the source.-
Methods inherited from class java.lang.Throwable
fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
EnforcerRuleException
public EnforcerRuleException(Object source, String shortMessage, String longMessage)
Construct a newEnforcerRuleExceptionexception providing the source and a short and long message.- Parameters:
source- the sourceshortMessage- the short messagelongMessage- the long message
-
EnforcerRuleException
public EnforcerRuleException(String message, Exception cause)
Construct a newEnforcerRuleExceptionexception wrapping an underlyingExceptionand providing amessage.- Parameters:
message- the messagecause- the cause
-
EnforcerRuleException
public EnforcerRuleException(String message, Throwable cause)
Construct a newEnforcerRuleExceptionexception wrapping an underlyingThrowableand providing amessage.- Parameters:
message- the messagecause- the cause
-
EnforcerRuleException
public EnforcerRuleException(String message)
Construct a newEnforcerRuleExceptionexception providing amessage.- Parameters:
message- the message
-
-