65 lines
1.4 KiB
Java
65 lines
1.4 KiB
Java
package gr.cite.notification.data;
|
|
|
|
|
|
import gr.cite.notification.data.tenant.TenantScopedBaseEntity;
|
|
|
|
import jakarta.persistence.*;
|
|
import java.time.Instant;
|
|
import java.util.UUID;
|
|
|
|
@Entity
|
|
@Table(name = "\"ntf_UserCredential\"")
|
|
public class UserCredentialEntity extends TenantScopedBaseEntity {
|
|
|
|
@Id
|
|
@Column(name = "id", columnDefinition = "uuid", updatable = false, nullable = false)
|
|
private UUID id;
|
|
public static final String _id = "id";
|
|
|
|
@Column(name = "\"user\"", columnDefinition = "uuid", nullable = false)
|
|
private UUID userId;
|
|
public static final String _userId = "userId";
|
|
|
|
@Column(name = "\"external_id\"", length = UserCredentialEntity._externalIdLength, nullable = false)
|
|
private String externalId;
|
|
public static final String _externalId = "externalId";
|
|
public static final int _externalIdLength = 512;
|
|
|
|
@Column(name = "created_at", nullable = false)
|
|
private Instant createdAt;
|
|
|
|
public static final String _createdAt = "createdAt";
|
|
|
|
public UUID getId() {
|
|
return id;
|
|
}
|
|
|
|
public void setId(UUID id) {
|
|
this.id = id;
|
|
}
|
|
|
|
public UUID getUserId() {
|
|
return userId;
|
|
}
|
|
|
|
public void setUserId(UUID userId) {
|
|
this.userId = userId;
|
|
}
|
|
|
|
public String getExternalId() {
|
|
return externalId;
|
|
}
|
|
|
|
public void setExternalId(String externalId) {
|
|
this.externalId = externalId;
|
|
}
|
|
|
|
public Instant getCreatedAt() {
|
|
return createdAt;
|
|
}
|
|
|
|
public void setCreatedAt(Instant createdAt) {
|
|
this.createdAt = createdAt;
|
|
}
|
|
}
|