org.hpccsystems.commons.errors.HpccErrorLevel Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of commons-hpcc Show documentation
Show all versions of commons-hpcc Show documentation
Common library for HPCC functionality
package org.hpccsystems.commons.errors;
/**
* The severity of an error.
*/
public enum HpccErrorLevel
{
FATAL, ERROR, WARNING, INFO;
/**
* Gets the error level.
*
* @param eclenum
* the eclenum
* @return the error level
*/
public static HpccErrorLevel getErrorLevel(int eclenum)
{
if (eclenum == 0)
{
return null;
}
switch (eclenum)
{
case 1:
case 2:
return HpccErrorLevel.WARNING;
case 3:
case 4:
return HpccErrorLevel.ERROR;
case 5:
return HpccErrorLevel.FATAL;
case 6:
return HpccErrorLevel.INFO;
default:
return HpccErrorLevel.ERROR;
}
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy