push

package
v0.0.12 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var PushRpcService_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "push.PushRpcService",
	HandlerType: (*PushRpcServiceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "IosPush",
			Handler:    _PushRpcService_IosPush_Handler,
		},
		{
			MethodName: "HuaweiPush",
			Handler:    _PushRpcService_HuaweiPush_Handler,
		},
		{
			MethodName: "XiaomiPush",
			Handler:    _PushRpcService_XiaomiPush_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "push.proto",
}

PushRpcService_ServiceDesc is the grpc.ServiceDesc for PushRpcService service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterPushRpcServiceServer

func RegisterPushRpcServiceServer(s grpc.ServiceRegistrar, srv PushRpcServiceServer)

Types

type AndroidPushReq added in v0.0.9

type AndroidPushReq struct {
	Key     string   `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	IsDebug bool     `protobuf:"varint,2,opt,name=IsDebug,proto3" json:"IsDebug,omitempty"`
	Msg     string   `protobuf:"bytes,3,opt,name=Msg,proto3" json:"Msg,omitempty"`
	Token   []string `protobuf:"bytes,4,rep,name=Token,proto3" json:"Token,omitempty"`
	MsgType string   `protobuf:"bytes,5,opt,name=msgType,proto3" json:"msgType,omitempty"` //推送类型
	Type    string   `protobuf:"bytes,6,opt,name=type,proto3" json:"type,omitempty"`       //消息类型:launcher->首页 web->跳转web intent->跳转内部指定页面
	Action  string   `protobuf:"bytes,7,opt,name=action,proto3" json:"action,omitempty"`
	Scheme  string   `protobuf:"bytes,8,opt,name=scheme,proto3" json:"scheme,omitempty"`
	Extra   string   `protobuf:"bytes,9,opt,name=extra,proto3" json:"extra,omitempty"`
	// contains filtered or unexported fields
}

func (*AndroidPushReq) Descriptor deprecated added in v0.0.9

func (*AndroidPushReq) Descriptor() ([]byte, []int)

Deprecated: Use AndroidPushReq.ProtoReflect.Descriptor instead.

func (*AndroidPushReq) GetAction added in v0.0.9

func (x *AndroidPushReq) GetAction() string

func (*AndroidPushReq) GetExtra added in v0.0.9

func (x *AndroidPushReq) GetExtra() string

func (*AndroidPushReq) GetIsDebug added in v0.0.9

func (x *AndroidPushReq) GetIsDebug() bool

func (*AndroidPushReq) GetKey added in v0.0.9

func (x *AndroidPushReq) GetKey() string

func (*AndroidPushReq) GetMsg added in v0.0.9

func (x *AndroidPushReq) GetMsg() string

func (*AndroidPushReq) GetMsgType added in v0.0.9

func (x *AndroidPushReq) GetMsgType() string

func (*AndroidPushReq) GetScheme added in v0.0.9

func (x *AndroidPushReq) GetScheme() string

func (*AndroidPushReq) GetToken added in v0.0.9

func (x *AndroidPushReq) GetToken() []string

func (*AndroidPushReq) GetType added in v0.0.9

func (x *AndroidPushReq) GetType() string

func (*AndroidPushReq) ProtoMessage added in v0.0.9

func (*AndroidPushReq) ProtoMessage()

func (*AndroidPushReq) ProtoReflect added in v0.0.9

func (x *AndroidPushReq) ProtoReflect() protoreflect.Message

func (*AndroidPushReq) Reset added in v0.0.9

func (x *AndroidPushReq) Reset()

func (*AndroidPushReq) String added in v0.0.9

func (x *AndroidPushReq) String() string

type IosPushReq

type IosPushReq struct {
	Key     string   `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	Msg     string   `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	IsDebug bool     `protobuf:"varint,3,opt,name=IsDebug,proto3" json:"IsDebug,omitempty"`
	Token   []string `protobuf:"bytes,4,rep,name=Token,proto3" json:"Token,omitempty"`
	MsgType string   `protobuf:"bytes,5,opt,name=msgType,proto3" json:"msgType,omitempty"` // 推送类型
	Scheme  string   `protobuf:"bytes,6,opt,name=scheme,proto3" json:"scheme,omitempty"`
	Extra   string   `protobuf:"bytes,7,opt,name=extra,proto3" json:"extra,omitempty"`
	// contains filtered or unexported fields
}

func (*IosPushReq) Descriptor deprecated

func (*IosPushReq) Descriptor() ([]byte, []int)

Deprecated: Use IosPushReq.ProtoReflect.Descriptor instead.

func (*IosPushReq) GetExtra added in v0.0.9

func (x *IosPushReq) GetExtra() string

func (*IosPushReq) GetIsDebug

func (x *IosPushReq) GetIsDebug() bool

func (*IosPushReq) GetKey

func (x *IosPushReq) GetKey() string

func (*IosPushReq) GetMsg

func (x *IosPushReq) GetMsg() string

func (*IosPushReq) GetMsgType added in v0.0.9

func (x *IosPushReq) GetMsgType() string

func (*IosPushReq) GetScheme added in v0.0.9

func (x *IosPushReq) GetScheme() string

func (*IosPushReq) GetToken

func (x *IosPushReq) GetToken() []string

func (*IosPushReq) ProtoMessage

func (*IosPushReq) ProtoMessage()

func (*IosPushReq) ProtoReflect

func (x *IosPushReq) ProtoReflect() protoreflect.Message

func (*IosPushReq) Reset

func (x *IosPushReq) Reset()

func (*IosPushReq) String

func (x *IosPushReq) String() string

type PushResp

type PushResp struct {
	Code      int32         `protobuf:"varint,1,opt,name=code,proto3" json:"code,omitempty"`
	Msg       string        `protobuf:"bytes,2,opt,name=msg,proto3" json:"msg,omitempty"`
	RequestID string        `protobuf:"bytes,3,opt,name=requestID,proto3" json:"requestID,omitempty"`
	Path      string        `protobuf:"bytes,4,opt,name=path,proto3" json:"path,omitempty"`
	Data      *PushRespData `protobuf:"bytes,5,opt,name=data,proto3" json:"data,omitempty"`
	// contains filtered or unexported fields
}

func (*PushResp) Descriptor deprecated

func (*PushResp) Descriptor() ([]byte, []int)

Deprecated: Use PushResp.ProtoReflect.Descriptor instead.

func (*PushResp) GetCode

func (x *PushResp) GetCode() int32

func (*PushResp) GetData

func (x *PushResp) GetData() *PushRespData

func (*PushResp) GetMsg

func (x *PushResp) GetMsg() string

func (*PushResp) GetPath

func (x *PushResp) GetPath() string

func (*PushResp) GetRequestID

func (x *PushResp) GetRequestID() string

func (*PushResp) ProtoMessage

func (*PushResp) ProtoMessage()

func (*PushResp) ProtoReflect

func (x *PushResp) ProtoReflect() protoreflect.Message

func (*PushResp) Reset

func (x *PushResp) Reset()

func (*PushResp) String

func (x *PushResp) String() string

type PushRespData

type PushRespData struct {
	Key          string   `protobuf:"bytes,1,opt,name=Key,proto3" json:"Key,omitempty"`
	Total        int64    `protobuf:"varint,2,opt,name=Total,proto3" json:"Total,omitempty"`
	Success      int64    `protobuf:"varint,3,opt,name=Success,proto3" json:"Success,omitempty"`
	Fail         int64    `protobuf:"varint,4,opt,name=Fail,proto3" json:"Fail,omitempty"`
	IsDebug      bool     `protobuf:"varint,5,opt,name=IsDebug,proto3" json:"IsDebug,omitempty"`
	SuccessToken []string `protobuf:"bytes,6,rep,name=SuccessToken,proto3" json:"SuccessToken,omitempty"`
	FailToken    []string `protobuf:"bytes,7,rep,name=FailToken,proto3" json:"FailToken,omitempty"`
	// contains filtered or unexported fields
}

func (*PushRespData) Descriptor deprecated

func (*PushRespData) Descriptor() ([]byte, []int)

Deprecated: Use PushRespData.ProtoReflect.Descriptor instead.

func (*PushRespData) GetFail

func (x *PushRespData) GetFail() int64

func (*PushRespData) GetFailToken

func (x *PushRespData) GetFailToken() []string

func (*PushRespData) GetIsDebug

func (x *PushRespData) GetIsDebug() bool

func (*PushRespData) GetKey

func (x *PushRespData) GetKey() string

func (*PushRespData) GetSuccess

func (x *PushRespData) GetSuccess() int64

func (*PushRespData) GetSuccessToken

func (x *PushRespData) GetSuccessToken() []string

func (*PushRespData) GetTotal

func (x *PushRespData) GetTotal() int64

func (*PushRespData) ProtoMessage

func (*PushRespData) ProtoMessage()

func (*PushRespData) ProtoReflect

func (x *PushRespData) ProtoReflect() protoreflect.Message

func (*PushRespData) Reset

func (x *PushRespData) Reset()

func (*PushRespData) String

func (x *PushRespData) String() string

type PushRpcServiceClient

type PushRpcServiceClient interface {
	IosPush(ctx context.Context, in *IosPushReq, opts ...grpc.CallOption) (*PushResp, error)
	HuaweiPush(ctx context.Context, in *AndroidPushReq, opts ...grpc.CallOption) (*PushResp, error)
	XiaomiPush(ctx context.Context, in *AndroidPushReq, opts ...grpc.CallOption) (*PushResp, error)
}

PushRpcServiceClient is the client API for PushRpcService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

type PushRpcServiceServer

type PushRpcServiceServer interface {
	IosPush(context.Context, *IosPushReq) (*PushResp, error)
	HuaweiPush(context.Context, *AndroidPushReq) (*PushResp, error)
	XiaomiPush(context.Context, *AndroidPushReq) (*PushResp, error)
	// contains filtered or unexported methods
}

PushRpcServiceServer is the server API for PushRpcService service. All implementations must embed UnimplementedPushRpcServiceServer for forward compatibility

type UnimplementedPushRpcServiceServer

type UnimplementedPushRpcServiceServer struct {
}

UnimplementedPushRpcServiceServer must be embedded to have forward compatible implementations.

func (UnimplementedPushRpcServiceServer) HuaweiPush

func (UnimplementedPushRpcServiceServer) IosPush

func (UnimplementedPushRpcServiceServer) XiaomiPush

type UnsafePushRpcServiceServer

type UnsafePushRpcServiceServer interface {
	// contains filtered or unexported methods
}

UnsafePushRpcServiceServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PushRpcServiceServer will result in compilation errors.

Jump to

Keyboard shortcuts

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