package com.purui.prims.headless.server.persistence.dataobject;

import com.baomidou.mybatisplus.annotation.TableName;

/**
 * 应用权限表
 *
 * @author charlie
 * @date 2024-06-14
 */
@TableName("pr_app_auth")
public class AppAuthDO {
    /**
     * 主键
     */
    private Long id;

    /**
     * 应用ID
     */
    private Long appId;

    /**
     * 指标ID
     */
    private Long dataId;

    /**
     * 权限类型(metric,dataset)
     */
    private String authType;

    public String getConfig() {
        return config;
    }

    public void setConfig(String config) {
        this.config = config;
    }

    /**
     * 配置信息
     */
    private String config;

    public Long getId() {
        return id;
    }

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

    public Long getAppId() {
        return appId;
    }

    public void setAppId(Long appId) {
        this.appId = appId;
    }

    public Long getDataId() {
        return dataId;
    }

    public void setDataId(Long dataId) {
        this.dataId = dataId;
    }

    public String getAuthType() {
        return authType;
    }

    public void setAuthType(String authType) {
        this.authType = authType == null ? null : authType.trim();
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", id=").append(id);
        sb.append(", appId=").append(appId);
        sb.append(", dataId=").append(dataId);
        sb.append(", authType=").append(authType);
        sb.append("]");
        return sb.toString();
    }
}