push

package
v0.0.0-...-45353d3 Latest Latest
Warning

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

Go to latest
Published: May 25, 2023 License: AGPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const PushDeerName string = "push_deer"
View Source
const PushPlusName string = "push_plus"
View Source
const TelegramName string = "telegram"

Variables

This section is empty.

Functions

func InitPush

func InitPush()

InitPush bind endpoints with config file

func SetEndpoint

func SetEndpoint(endpoint util.Endpoint)

Types

type Data

type Data struct {
	Title   string
	Content string
}

Data represents data needed for push

type Push

type Push interface {
	Submit(data Data) error
}

Push contain all info needed for push action

func NewPush

func NewPush(name string) Push

type PushDeerPush

type PushDeerPush struct {
	util.Endpoint
}

PushDeer push

func (PushDeerPush) Submit

func (push PushDeerPush) Submit(pd Data) error

Submit data to endpoint and finish one task

type PushPlusPush

type PushPlusPush struct {
	util.Endpoint
}

WeChat PushPlus push

func (PushPlusPush) Submit

func (push PushPlusPush) Submit(pd Data) error

Submit data to endpoint and finish one task

type TelegramPush

type TelegramPush struct {
	util.Endpoint
}

Telegram BOT push

func (TelegramPush) Submit

func (push TelegramPush) Submit(pd Data) error

Submit data to endpoint and finish one task

Jump to

Keyboard shortcuts

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