domain

package
v0.1.34 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 14, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Overview

Deprecated: This service is deprecated and will be removed in a future version. Please use the new module instead.

Deprecated: This service is deprecated and will be removed in a future version. Please use the new module instead.

Deprecated: This service is deprecated and will be removed in a future version. Please use the new module instead.

Deprecated: This service is deprecated and will be removed in a future version. Please use the new module instead.

Index

Constants

View Source
const (
	ContentStatusCreated  = "created"
	ContentStatusUploaded = "uploaded"
)
View Source
const (
	ContentDerivationTypeOriginal = "original"
	ContentDerivationTypeDerived  = "derived"
)

content derivation_type

View Source
const (
	ContentDerivedTHUMBNAIL720 = "THUMBNAIL_720"
	ContentDerivedTHUMBNAIL480 = "THUMBNAIL_480"
	ContentDerivedTHUMBNAIL256 = "THUMBNAIL_256"
	ContentDerivedTHUMBNAIL128 = "THUMBNAIL_128"
	ContentDerivedConversion   = "CONVERSION"
)

content_derived derivation_typ

View Source
const (
	ObjectStatusCreated    = "created"
	ObjectStatusUploading  = "uploading"
	ObjectStatusUploaded   = "uploaded"
	ObjectStatusProcessing = "processing"
	ObjectStatusProcessed  = "processed"
	ObjectStatusFailed     = "failed"
	ObjectStatusDeleted    = "deleted"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type AccessLog

type AccessLog struct {
	ID             uuid.UUID `json:"id"`
	ContentID      uuid.UUID `json:"content_id"`
	ActorID        uuid.UUID `json:"actor_id"`
	Method         string    `json:"method"`
	StorageBackend string    `json:"storage_backend"`
	CreatedAt      time.Time `json:"created_at"`
}

AccessLog represents an optional access log

type AuditEvent

type AuditEvent struct {
	ID        uuid.UUID              `json:"id"`
	ContentID uuid.UUID              `json:"content_id"`
	ObjectID  uuid.UUID              `json:"object_id"`
	ActorID   uuid.UUID              `json:"actor_id"`
	Action    string                 `json:"action"`
	Metadata  map[string]interface{} `json:"metadata"`
	CreatedAt time.Time              `json:"created_at"`
}

AuditEvent represents an event log for audits

type Content

type Content struct {
	ID             uuid.UUID `json:"id"`
	TenantID       uuid.UUID `json:"tenant_id"`
	OwnerID        uuid.UUID `json:"owner_id"`
	OwnerType      string    `json:"owner_type,omitempty"`
	Name           string    `json:"name,omitempty"`
	Description    string    `json:"description,omitempty"`
	DocumentType   string    `json:"document_type,omitempty"`
	Status         string    `json:"status"`
	DerivationType string    `json:"derivation_type,omitempty"`
	CreatedAt      time.Time `json:"created_at"`
	UpdatedAt      time.Time `json:"updated_at"`
}

Content represents a logical content entity

type ContentMetadata

type ContentMetadata struct {
	ContentID         uuid.UUID              `json:"content_id"`
	Tags              []string               `json:"tags,omitempty"`
	FileSize          int64                  `json:"file_size,omitempty"`
	FileName          string                 `json:"file_name,omitempty"`
	MimeType          string                 `json:"mime_type"` // MIME type
	Checksum          string                 `json:"checksum,omitempty"`
	ChecksumAlgorithm string                 `json:"checksum_algorithm,omitempty"`
	Metadata          map[string]interface{} `json:"metadata"` // For other custom metadata
	CreatedAt         time.Time              `json:"created_at"`
	UpdatedAt         time.Time              `json:"updated_at"`
}

ContentMetadata represents metadata for a content

type DerivedContent added in v0.0.12

type DerivedContent struct {
	ParentID           uuid.UUID              `json:"parent_id"`
	ContentID          uuid.UUID              `json:"content_id"`
	DerivationType     string                 `json:"derivation_type"`
	DerivationParams   map[string]interface{} `json:"derivation_params"`
	ProcessingMetadata map[string]interface{} `json:"processing_metadata"`
	CreatedAt          time.Time              `json:"created_at"`
	UpdatedAt          time.Time              `json:"updated_at"`
	DocumentType       string                 `json:"document_type"`
	Status             string                 `json:"status"`
}

type Object

type Object struct {
	ID                 uuid.UUID `json:"id"`
	ContentID          uuid.UUID `json:"content_id"`
	StorageBackendName string    `json:"storage_backend_name"`
	StorageClass       string    `json:"storage_class,omitempty"`
	ObjectKey          string    `json:"object_key"`
	FileName           string    `json:"file_name,omitempty"`
	Version            int       `json:"version"` // Used for compatibility with version_id field
	ObjectType         string    `json:"object_type,omitempty"`
	Status             string    `json:"status"`
	CreatedAt          time.Time `json:"created_at"`
	UpdatedAt          time.Time `json:"updated_at"`
}

Object represents a physical object stored in a storage backend

type ObjectMetadata

type ObjectMetadata struct {
	ObjectID  uuid.UUID              `json:"object_id"`
	SizeBytes int64                  `json:"size_bytes"`
	MimeType  string                 `json:"mime_type"`
	ETag      string                 `json:"etag,omitempty"`
	Metadata  map[string]interface{} `json:"metadata"`
	CreatedAt time.Time              `json:"created_at"`
	UpdatedAt time.Time              `json:"updated_at"`
}

ObjectMetadata represents metadata about an object

type ObjectPreview

type ObjectPreview struct {
	ID          uuid.UUID `json:"id"`
	ObjectID    uuid.UUID `json:"object_id"`
	PreviewType string    `json:"preview_type"`
	PreviewURL  string    `json:"preview_url"`
	Status      string    `json:"status"`
	CreatedAt   time.Time `json:"created_at"`
}

ObjectPreview represents a preview generated from an object

type StorageBackend

type StorageBackend struct {
	Name      string                 `json:"name"` // Primary identifier
	Type      string                 `json:"type"` // "memory", "fs", "s3", etc.
	Config    map[string]interface{} `json:"config"`
	IsActive  bool                   `json:"is_active"`
	CreatedAt time.Time              `json:"created_at"`
	UpdatedAt time.Time              `json:"updated_at"`
}

StorageBackend represents a configurable storage backend

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL