model

package
v0.4.0 Latest Latest
Warning

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

Go to latest
Published: Feb 10, 2025 License: AGPL-3.0 Imports: 1 Imported by: 0

Documentation

Overview

Package model provides the data types used throughout the application.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type File

type File struct {
	ID          int64     `json:"id"`
	RootID      int64     `json:"root_id"`
	Path        string    `json:"path"`
	Type        string    `json:"type"`
	LastRefresh time.Time `json:"last_refresh"`
	Size        int64     `json:"size"`
	CTime       time.Time `json:"ctime"`
}

File is a ... file.

type FileMeta

type FileMeta struct {
	ID        int64             `json:"id"`
	FileID    int64             `json:"file_id"`
	Timestamp time.Time         `json:"timestamp"`
	Content   string            `json:"content"`
	Meta      map[string]string `json:"meta"`
	F         *File             `json:"-"`
}

FileMeta represents the metadata extracted from a File.

F, if non-nil, shall be a pointer to the File the metadata refers to. This is mainly intended for convenience, there probably should be a a more elegant solution.

type Root

type Root struct {
	ID       int64     `json:"id"`
	Path     string    `json:"path"`
	LastScan time.Time `json:"last_scan"`
}

Root is a directory that is scanned for files

Jump to

Keyboard shortcuts

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