Newer
Older
package mi.hdm.exceptions;
import java.lang.reflect.Type;
/**
* This exception is thrown when no object is found for a code.
*/
public class MissingContentException extends Exception {
private final Type type;
private final String code;
public MissingContentException(String code, Type type) {
super("Missing content exception: no instance of " + type + " was found with code '" + code + "'");
this.type = type;
this.code = code;
}
public Type getType() {
return type;
}
public String getCode() {
return code;
}
}