package com.ycwl.basic.pricing.exception;

/**
 * 优惠券无效异常
 */
public class CouponInvalidException extends RuntimeException {

    private final String errorCode;

    public CouponInvalidException(String message) {
        this(null, message, null);
    }

    public CouponInvalidException(String message, Throwable cause) {
        this(null, message, cause);
    }

    public CouponInvalidException(String errorCode, String message) {
        this(errorCode, message, null);
    }

    public CouponInvalidException(String errorCode, String message, Throwable cause) {
        super(message, cause);
        this.errorCode = errorCode;
    }

    public String getErrorCode() {
        return errorCode;
    }
}
