UserEventDo.java 3.76 KB
package com.diligrp.assistant.logging.model;

import com.diligrp.assistant.shared.domain.BaseDo;

import java.time.LocalDateTime;

public class UserEventDo extends BaseDo {
    // 事件分组ID
    private String groupId;
    // 系统模块ID
    private String moduleId;
    // 事件动作
    private String action;
    // 操作对象ID
    private String objectId;
    // 操作对象
    private String objectName;
    // 事件描述
    private String event;
    // 发生时间
    private LocalDateTime when;
    // 操作人ID
    private String userId;
    // 操作人
    private String userName;
    // 事件来源-IP/MAC
    private String source;

    public String getGroupId() {
        return groupId;
    }

    public void setGroupId(String groupId) {
        this.groupId = groupId;
    }

    public String getModuleId() {
        return moduleId;
    }

    public void setModuleId(String moduleId) {
        this.moduleId = moduleId;
    }

    public String getAction() {
        return action;
    }

    public void setAction(String action) {
        this.action = action;
    }

    public String getObjectId() {
        return objectId;
    }

    public void setObjectId(String objectId) {
        this.objectId = objectId;
    }

    public String getObjectName() {
        return objectName;
    }

    public void setObjectName(String objectName) {
        this.objectName = objectName;
    }

    public String getEvent() {
        return event;
    }

    public void setEvent(String event) {
        this.event = event;
    }

    public LocalDateTime getWhen() {
        return when;
    }

    public void setWhen(LocalDateTime when) {
        this.when = when;
    }

    public String getUserId() {
        return userId;
    }

    public void setUserId(String userId) {
        this.userId = userId;
    }

    public String getUserName() {
        return userName;
    }

    public void setUserName(String userName) {
        this.userName = userName;
    }

    public String getSource() {
        return source;
    }

    public void setSource(String source) {
        this.source = source;
    }

    public static Builder builder() {
        return new UserEventDo().new Builder();
    }

    public class Builder {
        public Builder groupId(String groupId) {
            UserEventDo.this.groupId = groupId;
            return this;
        }

        public Builder moduleId(String moduleId) {
            UserEventDo.this.moduleId = moduleId;
            return this;
        }

        public Builder action(String action) {
            UserEventDo.this.action = action;
            return this;
        }

        public Builder objectId(String objectId) {
            UserEventDo.this.objectId = objectId;
            return this;
        }

        public Builder objectName(String objectName) {
            UserEventDo.this.objectName = objectName;
            return this;
        }

        public Builder event(String event) {
            UserEventDo.this.event = event;
            return this;
        }

        public Builder when(LocalDateTime when) {
            UserEventDo.this.when = when;
            return this;
        }

        public Builder userId(String userId) {
            UserEventDo.this.userId = userId;
            return this;
        }

        public Builder userName(String userName) {
            UserEventDo.this.userName = userName;
            return this;
        }

        public Builder source(String source) {
            UserEventDo.this.source = source;
            return this;
        }

        public Builder createdTime(LocalDateTime createdTime) {
            UserEventDo.this.createdTime = createdTime;
            return this;
        }

        public UserEventDo build() {
            return UserEventDo.this;
        }
    }
}