A class cannot be static, but for you purposes you can set the attributes and methods to be static. This way you can access it without create an instance.
public class Constant {
public static final String ERROR = "1";
public static String calculate(int number, int number) {
//
}
}
public class Test {
public static void main(String... args) {
String error = Constant.ERROR;
Constant.calculate(1, 10);
}
}