interaction

package
v0.0.0-...-3141384 Latest Latest
Warning

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

Go to latest
Published: Dec 2, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Comment

type Comment struct {
	Interaction
	Uri     string // The URI of the comment
	ReplyTo string // The URI of the post being replied to
	Text    string // The content of the comment
}

Comment represents a comment interaction

type CommentFilter

type CommentFilter func(*Comment) bool

type CommentHandler

type CommentHandler func(*Comment) error

type CommentHandlerWithFilter

type CommentHandlerWithFilter struct {
	Handler CommentHandler
	Filters []CommentFilter
}

type Follow

type Follow struct {
	Interaction
}

Follow represents a follow interaction

type FollowFilter

type FollowFilter func(*Follow) bool

Filter functions for each interaction type

type FollowHandler

type FollowHandler func(*Follow) error

Handler functions for each interaction type

type FollowHandlerWithFilter

type FollowHandlerWithFilter struct {
	Handler FollowHandler
	Filters []FollowFilter
}

HandlerWithFilter combines a handler with its filters

type Interaction

type Interaction struct {
	Actor     string    // The DID of the user performing the action
	Subject   string    // The DID or URI being acted upon
	CreatedAt time.Time // When the interaction occurred
}

Interaction represents a base interaction type

type Like

type Like struct {
	Interaction
	Uri string // The URI of the post being liked
}

Like represents a like interaction

type LikeFilter

type LikeFilter func(*Like) bool

type LikeHandler

type LikeHandler func(*Like) error

type LikeHandlerWithFilter

type LikeHandlerWithFilter struct {
	Handler LikeHandler
	Filters []LikeFilter
}

type Repost

type Repost struct {
	Interaction
	Uri string // The URI of the post being reposted
}

Repost represents a repost interaction

type RepostFilter

type RepostFilter func(*Repost) bool

type RepostHandler

type RepostHandler func(*Repost) error

type RepostHandlerWithFilter

type RepostHandlerWithFilter struct {
	Handler RepostHandler
	Filters []RepostFilter
}

Jump to

Keyboard shortcuts

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