model

package
v0.3.9 Latest Latest
Warning

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

Go to latest
Published: May 23, 2023 License: MIT Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Document

type Document struct {
	ID          string `json:"id,omitempty"`
	Filename    string `json:"filename" validate:"required"`
	ContentType string `json:"contentType" validate:"required"`
	FileBase64  string `json:"fileBase64,omitempty" validate:"required"`
	URL         string `json:"url,omitempty"`
	ShortLink   string `json:"shortLink,omitempty"`
}

Document represents the document file and its metadata.

type File

type File struct {
	Filename string            `bson:"filename" json:"filename"`
	Content  []byte            `bson:"-" json:"-"`
	Metadata map[string]string `bson:"metadata,omitempty" json:"metadata,omitempty"`
	Size     int64             `bson:"length,omitempty" json:"size,omitempty"`
}

File represents the document as retrieved from the repository.

Jump to

Keyboard shortcuts

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