fa

package
v0.0.0-...-e164885 Latest Latest
Warning

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

Go to latest
Published: Feb 16, 2025 License: BSD-3-Clause Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FurAffinityUrl

func FurAffinityUrl() *url.URL

Types

type CommentContent

type CommentContent struct {
	// contains filtered or unexported fields
}

func (*CommentContent) ID

func (cc *CommentContent) ID() uint

func (*CommentContent) Text

func (cc *CommentContent) Text() string

type CommentEntry

type CommentEntry struct {
	// contains filtered or unexported fields
}

func (*CommentEntry) Content

func (ce *CommentEntry) Content() EntryContent

func (*CommentEntry) Date

func (ce *CommentEntry) Date() time.Time

func (*CommentEntry) EntryType

func (ce *CommentEntry) EntryType() entries.EntryType

func (*CommentEntry) From

func (ce *CommentEntry) From() FurAffinityUser

func (*CommentEntry) HasContent

func (ce *CommentEntry) HasContent() bool

func (*CommentEntry) ID

func (ce *CommentEntry) ID() uint
func (ce *CommentEntry) Link() *url.URL

func (*CommentEntry) SetContent

func (ce *CommentEntry) SetContent(ec EntryContent)

func (*CommentEntry) Title

func (ce *CommentEntry) Title() string

type Entry

type Entry interface {
	EntryType() entries.EntryType
	Date() time.Time
	Link() *url.URL
	ID() uint
	From() FurAffinityUser
	Title() string
	Content() EntryContent
	SetContent(EntryContent)
	HasContent() bool
}

type EntryContent

type EntryContent interface {
	ID() uint
	Text() string
}

type EntrySubmissionContent

type EntrySubmissionContent interface {
	ID() uint
	Text() string
	ImageURL() *url.URL
}

type FurAffinityCollector

type FurAffinityCollector struct {
	LimitConcurrency      int
	OnlyUnreadNotes       bool
	OnlySinceRegistration bool
	UserID                uint
}

func NewCollector

func NewCollector(userId uint) *FurAffinityCollector

func (*FurAffinityCollector) GetNewNotes

func (fc *FurAffinityCollector) GetNewNotes() <-chan *NoteEntry

func (*FurAffinityCollector) GetNewNotesWithContent

func (fc *FurAffinityCollector) GetNewNotesWithContent() <-chan *NoteEntry

func (*FurAffinityCollector) GetNewOtherEntries

func (fc *FurAffinityCollector) GetNewOtherEntries(entryTypes ...entries.EntryType) <-chan Entry

func (*FurAffinityCollector) GetNewOtherEntriesWithContent

func (fc *FurAffinityCollector) GetNewOtherEntriesWithContent(entryTypes ...entries.EntryType) <-chan Entry

func (*FurAffinityCollector) GetNoteContent

func (fc *FurAffinityCollector) GetNoteContent(note uint, markUnread bool) *NoteContent

func (*FurAffinityCollector) GetNoteContents

func (fc *FurAffinityCollector) GetNoteContents(notes []uint, markUnread bool) map[uint]*NoteContent

func (*FurAffinityCollector) GetNotes

func (fc *FurAffinityCollector) GetNotes(page uint) <-chan *NoteEntry

func (*FurAffinityCollector) GetOtherEntries

func (fc *FurAffinityCollector) GetOtherEntries(entryTypes ...entries.EntryType) <-chan Entry

func (*FurAffinityCollector) GetOtherEntryContent

func (fc *FurAffinityCollector) GetOtherEntryContent(entry Entry) EntryContent

func (*FurAffinityCollector) MarkUnread

func (fc *FurAffinityCollector) MarkUnread(noteId ...uint) error

type FurAffinityUser

type FurAffinityUser struct {
	Name       string
	ProfileUrl *url.URL
}

type NoteContent

type NoteContent struct {
	// contains filtered or unexported fields
}

func (*NoteContent) ID

func (nc *NoteContent) ID() uint

func (*NoteContent) Text

func (nc *NoteContent) Text() string

type NoteEntry

type NoteEntry struct {
	WasUnread bool
	// contains filtered or unexported fields
}

func (*NoteEntry) Content

func (ne *NoteEntry) Content() EntryContent

func (*NoteEntry) Date

func (ne *NoteEntry) Date() time.Time

func (*NoteEntry) EntryType

func (ne *NoteEntry) EntryType() entries.EntryType

func (*NoteEntry) From

func (ne *NoteEntry) From() FurAffinityUser

func (*NoteEntry) HasContent

func (ne *NoteEntry) HasContent() bool

func (*NoteEntry) ID

func (ne *NoteEntry) ID() uint
func (ne *NoteEntry) Link() *url.URL

func (*NoteEntry) SetContent

func (ne *NoteEntry) SetContent(ec EntryContent)

func (*NoteEntry) Title

func (ne *NoteEntry) Title() string

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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