model

package
v1.2.5 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2023 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// MaximumContentLength is the upper limit on one post.
	MaximumContentLength = 500
	// MinimumContentLength is the lower limit on one post.
	MinimumContentLength = 50
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Account

type Account struct {
	*gorm.Model
	Name      string
	BaseURL   string
	Publisher string
	APIToken  string
}

Account database model.

type Entry

type Entry struct {
	*gorm.Model
	FeedID   uint
	Link     string
	Title    string
	EntryID  string
	Content  string
	Image    string
	PostedAt *time.Time
}

Entry database model.

func (Entry) Excerpt

func (e Entry) Excerpt() string

Excerpt generates an except for an entry.

type Feed

type Feed struct {
	*gorm.Model
	Name     string
	User     string
	URL      string
	Provider string
	HashTags []HashTag
}

Feed database model.

type HashTag added in v1.2.0

type HashTag struct {
	*gorm.Model
	FeedID uint
	Value  string
}

HashTag database model.

func (HashTag) PrefixedValue added in v1.2.0

func (ht HashTag) PrefixedValue() string

PrefixedValue return with the value with # at the beginning.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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