package com.liangjian.dataplatform.member.entity.vo.datanodes;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.util.Date;

/**
 * @Author: 黄子奇
 * @Date: 2019/8/26 14:56
 * 数据节点，用于封装MetaCore、前后端交互的结构
 */
@ApiModel("数据节点")
public abstract class DataNode implements Serializable {

    private static final long serialVersionUID = 1019307654110298956L;

    /** 数据节点Id */
    @ApiModelProperty("数据节点Id")
    protected String id;

    /** 数据节点父Id */
    @ApiModelProperty("数据节点父Id")
    protected String prtId;

    /** 数据节点名称 */
    @ApiModelProperty("数据节点名称")
    protected String name;

    /** 业务分域 */
    @ApiModelProperty("业务分域")
    protected String bizDomain;

    /** 数据节点类型 */
    @ApiModelProperty("数据节点类型")
    protected String nodeType;

    /** 数据节点是否为父节点 */
    @ApiModelProperty("数据节点是否为父节点")
    protected Boolean isParent;

    /** 描述 */
    @ApiModelProperty("描述")
    protected String comment;

    /** 备注 */
    @ApiModelProperty("备注")
    protected String remark;

    /** 创建日期 */
    @ApiModelProperty("创建日期")
    protected Date crtDate;

    /** 最后更新日期 */
    @ApiModelProperty("最后更新日期")
    protected Date lastUpdate;

    /** 创建用户 */
    @ApiModelProperty("创建用户")
    protected String crtUser;

    @ApiModelProperty("命名空间")
    protected String namespace;

    public DataNode() {
    }

    public DataNode(String id, String prtId, String name, String bizDomain, String nodeType, Boolean isParent, String comment, String remark, Date crtDate, Date lastUpdate, String crtUser, String namespace) {
        this.id = id;
        this.prtId = prtId;
        this.name = name;
        this.bizDomain = bizDomain;
        this.nodeType = nodeType;
        this.isParent = isParent;
        this.comment = comment;
        this.remark = remark;
        this.crtDate = crtDate;
        this.lastUpdate = lastUpdate;
        this.crtUser = crtUser;
        this.namespace = namespace;
    }

    /** 数据节点的种类
     *  如：根节点，数据节点，模型，目录等
     * */
    public abstract String getDataKind();

    public String getId() {
        return id;
    }

    public void setId(String id) {
        this.id = id;
    }

    public String getPrtId() {
        return prtId;
    }

    public void setPrtId(String prtId) {
        this.prtId = prtId;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getNodeType() {
        return nodeType;
    }

    public void setNodeType(String nodeType) {
        this.nodeType = nodeType;
    }

    public Boolean getParent() {
        return isParent;
    }

    public void setParent(Boolean parent) {
        isParent = parent;
    }

    public String getComment() {
        return comment;
    }

    public void setComment(String comment) {
        this.comment = comment;
    }

    public Date getCrtDate() {
        return crtDate;
    }

    public void setCrtDate(Date crtDate) {
        this.crtDate = crtDate;
    }

    public Date getLastUpdate() {
        return lastUpdate;
    }

    public void setLastUpdate(Date lastUpdate) {
        this.lastUpdate = lastUpdate;
    }

    public String getBizDomain() {
        return bizDomain;
    }

    public void setBizDomain(String bizDomain) {
        this.bizDomain = bizDomain;
    }

    public String getCrtUser() {
        return crtUser;
    }

    public void setCrtUser(String crtUser) {
        this.crtUser = crtUser;
    }

    public String getNamespace() {
        return namespace;
    }

    public void setNamespace(String namespace) {
        this.namespace = namespace;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }
}
