package org.egl_cepgl.pm.exception;

import lombok.Getter;

import java.util.List;
import java.util.Map;

public class InvalidEntityException extends RuntimeException
{
    @Getter
    private ErrorCodes errorCode;

    @Getter
    Map<String, List<String>> errors;

    public InvalidEntityException(String msg){
        super(msg);
    }

    public InvalidEntityException(String msg, Throwable cause){
        super(msg, cause);
    }

    public InvalidEntityException(String msg, Throwable cause, ErrorCodes errorCode){
        super(msg, cause);
        this.errorCode= errorCode;
    }

    public InvalidEntityException(String msg, ErrorCodes errorCode){
        super(msg);
        this.errorCode= errorCode;
    }

    public InvalidEntityException(String msg, ErrorCodes errorCode, Map<String, List<String>> errors){
        super(msg);
        this.errorCode= errorCode;
        this.errors= errors;
    }
}
