Package com.helger.commons.error.level
Class ErrorLevel
- java.lang.Object
-
- com.helger.commons.error.level.ErrorLevel
-
- All Implemented Interfaces:
IErrorLevel,IHasID<String>,ISeverityComparable<IErrorLevel>,IErrorIndicator,ISuccessIndicator
@Immutable public class ErrorLevel extends Object implements IErrorLevel
A standalone implementation of theIErrorLevelinterface.- Author:
- Philip Helger
-
-
Constructor Summary
Constructors Constructor Description ErrorLevel(String sID, int nNumericLevel)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanequals(Object o)StringgetID()Get the unique ID of this object.intgetNumericLevel()inthashCode()StringtoString()-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface com.helger.commons.error.level.IErrorLevel
compareTo, isEQ, isError, isFailure, isGE, isGT, isHighest, isLE, isLT, isNE, isNoError, isSuccess
-
Methods inherited from interface com.helger.commons.state.ISuccessIndicator
and, or
-
-
-
-
Constructor Detail
-
ErrorLevel
public ErrorLevel(@Nonnull @Nonempty String sID, @Nonnegative int nNumericLevel)
-
-
Method Detail
-
getID
@Nonnull @Nonempty public String getID()
Description copied from interface:IHasIDGet the unique ID of this object. If the type isStringthan the returned value must match an XML NMToken expression (so e.g. no ':' in the ID)!
-
getNumericLevel
@Nonnegative public int getNumericLevel()
- Specified by:
getNumericLevelin interfaceIErrorLevel- Returns:
- The numeric level of this error level. Must be ≥ 0. The higher the numeric level, the higher the priority of the error level. So e.g. ERROR has a higher/larger/greater numerical level than WARNING.
-
-