mirror of
https://github.com/AsamK/signal-cli
synced 2025-08-31 11:30:39 +00:00
Store group info in json
This commit is contained in:
parent
d0dae4e064
commit
c41ac8e7a3
4 changed files with 121 additions and 10 deletions
28
src/main/java/cli/GroupInfo.java
Normal file
28
src/main/java/cli/GroupInfo.java
Normal file
|
@ -0,0 +1,28 @@
|
|||
package cli;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonProperty;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Collection;
|
||||
import java.util.List;
|
||||
|
||||
public class GroupInfo {
|
||||
@JsonProperty
|
||||
public final byte[] groupId;
|
||||
|
||||
@JsonProperty
|
||||
public String name;
|
||||
|
||||
@JsonProperty
|
||||
public List<String> members = new ArrayList<>();
|
||||
|
||||
@JsonProperty
|
||||
public long avatarId;
|
||||
|
||||
public GroupInfo(@JsonProperty("groupId") byte[] groupId, @JsonProperty("name") String name, @JsonProperty("members") Collection<String> members, @JsonProperty("avatarId") long avatarId) {
|
||||
this.groupId = groupId;
|
||||
this.name = name;
|
||||
this.members.addAll(members);
|
||||
this.avatarId = avatarId;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue