package com.eactive.httpmockserver.user.entity;

import javax.persistence.*;
import java.io.Serializable;
import java.util.List;

@Entity
@Table(name = "PT_USER_GROUP")
public class UserGroup implements Serializable {

    private static final long serialVersionUID = 1L;

    @Id
    private String id;

    private String name;

    private String description;

    @OneToMany(mappedBy = "group", fetch = FetchType.LAZY)
    private List<StaffUser> users;

    public String getId() {
        return id;
    }

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

    public String getName() {
        return name;
    }

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

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public List<StaffUser> getUsers() {
        return users;
    }

    public void setUsers(List<StaffUser> users) {
        this.users = users;
    }
}
