Files
mtusi2026lab4/internal/storage/postgres/internal/sqlcgen/models.go
T

84 lines
1.3 KiB
Go

// Code generated by sqlc. DO NOT EDIT.
// versions:
// sqlc v1.31.1
package sqlcgen
import (
"time"
"github.com/google/uuid"
"github.com/jackc/pgx/v5/pgtype"
)
type Attachment struct {
ID uuid.UUID
ChatID uuid.UUID
OwnerID uuid.UUID
ObjectKey string
Filename string
ContentType string
SizeBytes int64
Sha256 string
Status string
ErrorCode pgtype.Text
CreatedAt time.Time
UpdatedAt time.Time
}
type Chat struct {
ID uuid.UUID
Title string
CreatedAt time.Time
}
type ChatMember struct {
ChatID uuid.UUID
UserID uuid.UUID
CreatedAt time.Time
}
type Message struct {
ID uuid.UUID
ChatID uuid.UUID
SenderID uuid.UUID
Text string
CreatedAt time.Time
}
type MessageAttachment struct {
MessageID uuid.UUID
AttachmentID uuid.UUID
Position int16
}
type MessageIdempotency struct {
ActorID uuid.UUID
ChatID uuid.UUID
Key string
RequestHash []byte
MessageID pgtype.UUID
CreatedAt time.Time
ExpiresAt time.Time
}
type Session struct {
TokenHash []byte
UserID uuid.UUID
ExpiresAt time.Time
CreatedAt time.Time
}
type User struct {
ID uuid.UUID
Username string
PasswordHash string
DisplayName string
CreatedAt time.Time
}
type UserChatVersion struct {
UserID uuid.UUID
Version int64
}