package cn.estsh.i3plus.pojo.platform.platbean;

import cn.estsh.i3plus.pojo.base.annotation.AnnoOutputColumn;
import cn.estsh.i3plus.pojo.base.bean.BaseBean;
import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiParam;
import lombok.Data;
import lombok.EqualsAndHashCode;

import javax.persistence.Column;

/**
 * @Description : 系统异常
 * @Reference   :
 * @Author      : Frin
 * @Date        : 2018-11-8 12:30:00
 * @Modify      :
 **/
@Data
@EqualsAndHashCode(callSuper = true)
@Api(value="系统异常表",description = "记录系统出现的异常")
public class SysLogException extends BaseBean {

    private static final long serialVersionUID = -2844455884020022321L;
    //CommonEnumUtil.SOFT_TYPE

    @ApiParam(value ="系统模块（枚举）", example = "1")
    @AnnoOutputColumn(refClass = CommonEnumUtil.SOFT_TYPE.class,refForeignKey = "value",value = "description")
    private Integer softType;
    public String getSoftTypeTxt() {
        return softType == null ? null : CommonEnumUtil.SOFT_TYPE.valueOfDescription(softType);
    }

    @ApiParam(value ="异常类名")
    private String excClassName;

    @ApiParam(value ="异常信息")
    private String excMessage;

    @ApiParam(value ="堆栈信息")
    private String excStack;
}
