class RespModel<T> {
    @Schema(description = "状态码")
    private int code;
    @Schema(description = "状态描述")
    private String message;
    @Schema(description = "响应详情")
    private T data;

    public RespModel() {
    }

    public RespModel(int code, String message) {
        this(code, message, null);
    }

    public RespModel(int code, String message, T data) {
        this.code = code;
        this.message = message;
        this.data = data;
    }

    public RespModel(RespEnum respEnum) {
        this.code = respEnum.getCode();
        this.message = respEnum.getMessage();
    }

    public RespModel(RespEnum respEnum, T data) {
        this.code = respEnum.getCode();
        this.message = respEnum.getMessage();
        this.data = data;
    }

    public static RespModel result(RespEnum respEnum) {
        return new RespModel(respEnum);
    }

    public static <T> RespModel<T> result(RespEnum respEnum, T data) {
        return new RespModel<T>(respEnum, data);
    }

    public int getCode() {
        return code;
    }

    public void setCode(int code) {
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public RespModel<T> setMessage(String msg) {
        this.message = msg;
        return this;
    }

    public T getData() {
        return data;
    }

    public RespModel<T> setData(T data) {
        this.data = data;
        return this;
    }

    @Override
    public String toString() {<FILL_FUNCTION_BODY>}
}

        return "RespModel{" +
                "code=" + code +
                ", message='" + message + '\'' +
                ", data=" + data +
                '}';
    
<no_super_class>