18 lines
437 B
Java
18 lines
437 B
Java
package app.mealsmadeeasy.api.util;
|
|
|
|
import lombok.Getter;
|
|
|
|
@Getter
|
|
public class NoSuchEntityWithIdException extends RuntimeException {
|
|
|
|
private final Class<?> entityType;
|
|
private final Object id;
|
|
|
|
public NoSuchEntityWithIdException(Class<?> entityType, Object id) {
|
|
super("Could not find entity " + entityType.getSimpleName() + " with id " + id);
|
|
this.entityType = entityType;
|
|
this.id = id;
|
|
}
|
|
|
|
}
|