service

package
v0.0.0-...-83adff0 Latest Latest
Warning

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

Go to latest
Published: Jul 6, 2020 License: GPL-3.0 Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

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

Service push service.

func New

func New(c *conf.Config) *Service

New creates a push service instance.

func (*Service) CallbackClick

func (s *Service) CallbackClick(c context.Context, cb *pushmdl.Callback) error

CallbackClick click callback.

func (*Service) CallbackHuawei

func (s *Service) CallbackHuawei(c context.Context, hcb *huawei.Callback) (err error)

CallbackHuawei huawei callback.

func (*Service) CallbackIOS

func (s *Service) CallbackIOS(c context.Context, task, token string, pid int) (err error)

CallbackIOS ios arrived callback.

func (*Service) CallbackJpush

func (s *Service) CallbackJpush(c context.Context, cbs []*jpush.CallbackReply) (err error)

CallbackJpush jpush callback batch.

func (*Service) CallbackOppo

func (s *Service) CallbackOppo(c context.Context, task string, cbs []*oppo.Callback) (err error)

CallbackOppo oppo callback.

func (*Service) CallbackXiaomi

func (s *Service) CallbackXiaomi(c context.Context, m map[string]*mi.Callback) (err error)

CallbackXiaomi xiaomi callback.

func (*Service) CallbackXiaomiRegid

func (s *Service) CallbackXiaomiRegid(c context.Context, cb *mi.RegidCallback) (err error)

CallbackXiaomiRegid xiaomi regid callback.

func (*Service) Close

func (s *Service) Close()

Close closes service.

func (*Service) Ping

func (s *Service) Ping(c context.Context) (err error)

Ping checks service.

func (*Service) PubReport

func (s *Service) PubReport(c context.Context, r *pushmdl.Report) (err error)

PubReport pub report.

func (*Service) ReportOld

func (s *Service) ReportOld(ctx context.Context, token, buvid, version string, mid int64, pid, timezone int) (err error)

ReportOld report old version app

func (*Service) SetSetting

func (s *Service) SetSetting(ctx context.Context, mid int64, typ, val int) (err error)

SetSetting saves setting.

func (*Service) Setting

func (s *Service) Setting(ctx context.Context, mid int64) (st map[int32]int32, err error)

Setting gets user notify setting.

func (*Service) TestToken

func (s *Service) TestToken(ctx context.Context, info *pushmdl.PushInfo, token string) (err error)

TestToken for test via push token.

Jump to

Keyboard shortcuts

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