Сообщения, доставка сообщений, фикс хэндшейков, буферная зона (для синхронмзации)
This commit is contained in:
67
src/main/java/com/rosetta/im/database/entity/Group.java
Normal file
67
src/main/java/com/rosetta/im/database/entity/Group.java
Normal file
@@ -0,0 +1,67 @@
|
||||
package com.rosetta.im.database.entity;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
import com.rosetta.im.database.CreateUpdateEntity;
|
||||
import com.rosetta.im.database.converters.StringListConverter;
|
||||
|
||||
import jakarta.persistence.Column;
|
||||
import jakarta.persistence.Convert;
|
||||
import jakarta.persistence.Entity;
|
||||
import jakarta.persistence.GeneratedValue;
|
||||
import jakarta.persistence.GenerationType;
|
||||
import jakarta.persistence.Id;
|
||||
import jakarta.persistence.Table;
|
||||
|
||||
/**
|
||||
* Сущность для групповых чатов.
|
||||
*/
|
||||
@Entity
|
||||
@Table(name = "groups")
|
||||
public class Group extends CreateUpdateEntity {
|
||||
|
||||
@Id
|
||||
@GeneratedValue(strategy = GenerationType.IDENTITY)
|
||||
private Long id;
|
||||
|
||||
@Column(name = "groupId")
|
||||
private String groupId;
|
||||
|
||||
@Convert(converter = StringListConverter.class)
|
||||
@Column(name = "membersPublicKeys", nullable = false)
|
||||
private List<String> membersPublicKeys = new ArrayList<>();
|
||||
|
||||
@Convert(converter = StringListConverter.class)
|
||||
@Column(name = "bannedPublicKeys", nullable = false)
|
||||
private List<String> bannedPublicKeys = new ArrayList<>();
|
||||
|
||||
public Long getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public String getGroupId() {
|
||||
return groupId;
|
||||
}
|
||||
|
||||
public void setGroupId(String groupId) {
|
||||
this.groupId = groupId;
|
||||
}
|
||||
|
||||
public List<String> getMembersPublicKeys() {
|
||||
return membersPublicKeys;
|
||||
}
|
||||
|
||||
public void setMembersPublicKeys(List<String> membersPublicKeys) {
|
||||
this.membersPublicKeys = membersPublicKeys;
|
||||
}
|
||||
|
||||
public List<String> getBannedPublicKeys() {
|
||||
return bannedPublicKeys;
|
||||
}
|
||||
|
||||
public void setBannedPublicKeys(List<String> bannedPublicKeys) {
|
||||
this.bannedPublicKeys = bannedPublicKeys;
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user