1 package org
.asamk
.signal
.manager
.storage
.contacts
;
3 import com
.fasterxml
.jackson
.annotation
.JsonIgnore
;
4 import com
.fasterxml
.jackson
.annotation
.JsonProperty
;
6 import org
.whispersystems
.signalservice
.api
.push
.SignalServiceAddress
;
10 import static com
.fasterxml
.jackson
.annotation
.JsonProperty
.Access
.WRITE_ONLY
;
12 public class ContactInfo
{
26 @JsonProperty(defaultValue
= "0")
27 public int messageExpirationTime
;
29 @JsonProperty(access
= WRITE_ONLY
)
30 public String profileKey
;
32 @JsonProperty(defaultValue
= "false")
33 public boolean blocked
;
36 public Integer inboxPosition
;
38 @JsonProperty(defaultValue
= "false")
39 public boolean archived
;
41 public ContactInfo() {
44 public ContactInfo(SignalServiceAddress address
) {
45 this.number
= address
.getNumber().orNull();
46 this.uuid
= address
.getUuid().orNull();
50 public SignalServiceAddress
getAddress() {
51 return new SignalServiceAddress(uuid
, number
);