Class ValidationMessage
- java.lang.Object
-
- org.apache.jackrabbit.vault.validation.spi.ValidationMessage
-
- Direct Known Subclasses:
ValidationViolation
public class ValidationMessage extends Object
Class encapsulating the actual message together with aValidationMessageSeverity.
-
-
Constructor Summary
Constructors Constructor Description ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, int line, int column, Throwable throwable)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, @NotNull String nodePath, @NotNull Path filePath, @NotNull Path basePath, Throwable throwable)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, @NotNull NodeContext nodeContext)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, @NotNull NodeContext nodeContext, Throwable throwable)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, String nodePath, Path filePath, Path basePath, int line, int column, Throwable throwable)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, Throwable throwable)ValidationMessage(@NotNull ValidationMessageSeverity severity, @NotNull String message, Path filePath, Path basePath, int line, int column, Throwable throwable)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object obj)@Nullable PathgetBasePath()intgetColumn()Returns the column number.@Nullable PathgetFilePath()intgetLine()Returns the line number.@NotNull StringgetMessage()Returns the message text.@Nullable StringgetNodePath()Returns the node path bound to this message.@NotNull ValidationMessageSeveritygetSeverity()Returns the severity of this message.@Nullable ThrowablegetThrowable()Returns the underlying throwable.inthashCode()StringtoString()
-
-
-
Constructor Detail
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, Throwable throwable)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, int line, int column, Throwable throwable)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, @NotNull @NotNull String nodePath, @NotNull @NotNull Path filePath, @NotNull @NotNull Path basePath, Throwable throwable)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, @NotNull @NotNull NodeContext nodeContext)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, @NotNull @NotNull NodeContext nodeContext, Throwable throwable)
-
ValidationMessage
public ValidationMessage(@NotNull @NotNull ValidationMessageSeverity severity, @NotNull @NotNull String message, Path filePath, Path basePath, int line, int column, Throwable throwable)
-
-
Method Detail
-
getSeverity
@NotNull public @NotNull ValidationMessageSeverity getSeverity()
Returns the severity of this message.- Returns:
- the severity of this message
-
getMessage
@NotNull public @NotNull String getMessage()
Returns the message text.- Returns:
- the message text
-
getLine
public int getLine()
Returns the line number.- Returns:
- the line number of this violation (1-based) or 0 if not bound to any specific line number
-
getColumn
public int getColumn()
Returns the column number.- Returns:
- the column number of this violation (1-based) or 0 if not bound to any specific column number
-
getThrowable
@Nullable public @Nullable Throwable getThrowable()
Returns the underlying throwable.- Returns:
- the throwable bound to this message or
nullif the message has no underlying throwable
-
getFilePath
@Nullable public @Nullable Path getFilePath()
-
getBasePath
@Nullable public @Nullable Path getBasePath()
-
getNodePath
@Nullable public @Nullable String getNodePath()
Returns the node path bound to this message.- Returns:
- the node path or
nullif the message does not belong to a specific node
-
-