Package com.exsol.errorcodemodel
Class ErrorMessageDeclaration
- java.lang.Object
-
- com.exsol.errorcodemodel.ErrorMessageDeclaration
-
public final class ErrorMessageDeclaration extends Object
This class represents an error message declaration as you would find it in the Java code.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classErrorMessageDeclaration.BuilderBuilder forErrorMessageDeclaration.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ErrorMessageDeclaration.Builderbuilder()Create a builder forErrorMessageDeclaration.booleanequals(Object other)StringgetDeclaringPackage()Get the package in which the error code is defined.StringgetIdentifier()Get the error code identifier.intgetLine()Get the line on which the error code is defined.StringgetMessage()Get the error message.List<String>getMitigations()Get the mitigations that users can try to solve this error.List<NamedParameter>getNamedParameters()Get the list of named parameters.StringgetSourceFile()Get the file this error code is defined in.inthashCode()ErrorMessageDeclarationwithoutSourcePosition()Get a copy of this error message declaration without source position (file and line).
-
-
-
Method Detail
-
getIdentifier
public String getIdentifier()
Get the error code identifier.- Returns:
- error code identifier
-
getMessage
public String getMessage()
Get the error message.- Returns:
- error message
-
getSourceFile
public String getSourceFile()
Get the file this error code is defined in.- Returns:
- file in which the error code is defined
-
getLine
public int getLine()
Get the line on which the error code is defined.- Returns:
- line on which the error code is defined
-
getDeclaringPackage
public String getDeclaringPackage()
Get the package in which the error code is defined.- Returns:
- package in which the error code is defined
-
getMitigations
public List<String> getMitigations()
Get the mitigations that users can try to solve this error.- Returns:
- mitigation for this error
-
getNamedParameters
public List<NamedParameter> getNamedParameters()
Get the list of named parameters.- Returns:
- list of named parameters
-
withoutSourcePosition
public ErrorMessageDeclaration withoutSourcePosition()
Get a copy of this error message declaration without source position (file and line).- Returns:
- copy without source position
-
builder
public static ErrorMessageDeclaration.Builder builder()
Create a builder forErrorMessageDeclaration.- Returns:
- builder
-
-