v1

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: 11 Imported by: 0

Documentation

Overview

Package v1 is a generated blademaster stub package. This code was generated with go-common/app/tool/bmgen/protoc-gen-bm v0.1.

It is generated from these files:

api/grpc/v1/api.proto

Index

Constants

View Source
const AppID = "live.livedm"

AppID 弹幕服务discoverID

Variables

View Source
var (
	ErrInvalidLengthApi = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowApi   = fmt.Errorf("proto: integer overflow")
)

Functions

func RegisterDMServer

func RegisterDMServer(s *grpc.Server, srv DMServer)

func RegisterV1DMService

func RegisterV1DMService(e *bm.Engine, svc DM, midMap map[string]bm.HandlerFunc)

RegisterV1DMService Register the blademaster route with middleware map midMap is the middleware map, the key is defined in proto

Types

type DM

type DM interface {
	SendMsg(ctx context.Context, req *SendMsgReq) (resp *SendMsgResp, err error)

	GetHistory(ctx context.Context, req *HistoryReq) (resp *HistoryResp, err error)
}

type DMClient

type DMClient interface {
	SendMsg(ctx context.Context, in *SendMsgReq, opts ...grpc.CallOption) (*SendMsgResp, error)
	GetHistory(ctx context.Context, in *HistoryReq, opts ...grpc.CallOption) (*HistoryResp, error)
}

DMClient is the client API for DM service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewClient

func NewClient(cfg *warden.ClientConfig, opts ...grpc.DialOption) (DMClient, error)

NewClient 弹幕服务client创建

func NewDMClient

func NewDMClient(cc *grpc.ClientConn) DMClient

type DMServer

type DMServer interface {
	SendMsg(context.Context, *SendMsgReq) (*SendMsgResp, error)
	GetHistory(context.Context, *HistoryReq) (*HistoryResp, error)
}

DMServer is the server API for DM service.

type ErrMsg

type ErrMsg struct {
	Message              string   `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*ErrMsg) Descriptor

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

func (*ErrMsg) GetMessage

func (m *ErrMsg) GetMessage() string

func (*ErrMsg) Marshal

func (m *ErrMsg) Marshal() (dAtA []byte, err error)

func (*ErrMsg) MarshalTo

func (m *ErrMsg) MarshalTo(dAtA []byte) (int, error)

func (*ErrMsg) ProtoMessage

func (*ErrMsg) ProtoMessage()

func (*ErrMsg) Reset

func (m *ErrMsg) Reset()

func (*ErrMsg) Size

func (m *ErrMsg) Size() (n int)

func (*ErrMsg) String

func (m *ErrMsg) String() string

func (*ErrMsg) Unmarshal

func (m *ErrMsg) Unmarshal(dAtA []byte) error

func (*ErrMsg) XXX_DiscardUnknown

func (m *ErrMsg) XXX_DiscardUnknown()

func (*ErrMsg) XXX_Marshal

func (m *ErrMsg) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*ErrMsg) XXX_Merge

func (dst *ErrMsg) XXX_Merge(src proto.Message)

func (*ErrMsg) XXX_Size

func (m *ErrMsg) XXX_Size() int

func (*ErrMsg) XXX_Unmarshal

func (m *ErrMsg) XXX_Unmarshal(b []byte) error

type HistoryReq

type HistoryReq struct {
	Roomid               int64    `protobuf:"varint,1,opt,name=roomid,proto3" json:"roomid,omitempty" form:"roomid" validate:"required"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HistoryReq) Descriptor

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

func (*HistoryReq) GetRoomid

func (m *HistoryReq) GetRoomid() int64

func (*HistoryReq) Marshal

func (m *HistoryReq) Marshal() (dAtA []byte, err error)

func (*HistoryReq) MarshalTo

func (m *HistoryReq) MarshalTo(dAtA []byte) (int, error)

func (*HistoryReq) ProtoMessage

func (*HistoryReq) ProtoMessage()

func (*HistoryReq) Reset

func (m *HistoryReq) Reset()

func (*HistoryReq) Size

func (m *HistoryReq) Size() (n int)

func (*HistoryReq) String

func (m *HistoryReq) String() string

func (*HistoryReq) Unmarshal

func (m *HistoryReq) Unmarshal(dAtA []byte) error

func (*HistoryReq) XXX_DiscardUnknown

func (m *HistoryReq) XXX_DiscardUnknown()

func (*HistoryReq) XXX_Marshal

func (m *HistoryReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HistoryReq) XXX_Merge

func (dst *HistoryReq) XXX_Merge(src proto.Message)

func (*HistoryReq) XXX_Size

func (m *HistoryReq) XXX_Size() int

func (*HistoryReq) XXX_Unmarshal

func (m *HistoryReq) XXX_Unmarshal(b []byte) error

type HistoryResp

type HistoryResp struct {
	Room                 []string `protobuf:"bytes,1,rep,name=room" json:"room"`
	Admin                []string `protobuf:"bytes,2,rep,name=admin" json:"admin"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HistoryResp) Descriptor

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

func (*HistoryResp) GetAdmin

func (m *HistoryResp) GetAdmin() []string

func (*HistoryResp) GetRoom

func (m *HistoryResp) GetRoom() []string

func (*HistoryResp) Marshal

func (m *HistoryResp) Marshal() (dAtA []byte, err error)

func (*HistoryResp) MarshalTo

func (m *HistoryResp) MarshalTo(dAtA []byte) (int, error)

func (*HistoryResp) ProtoMessage

func (*HistoryResp) ProtoMessage()

func (*HistoryResp) Reset

func (m *HistoryResp) Reset()

func (*HistoryResp) Size

func (m *HistoryResp) Size() (n int)

func (*HistoryResp) String

func (m *HistoryResp) String() string

func (*HistoryResp) Unmarshal

func (m *HistoryResp) Unmarshal(dAtA []byte) error

func (*HistoryResp) XXX_DiscardUnknown

func (m *HistoryResp) XXX_DiscardUnknown()

func (*HistoryResp) XXX_Marshal

func (m *HistoryResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*HistoryResp) XXX_Merge

func (dst *HistoryResp) XXX_Merge(src proto.Message)

func (*HistoryResp) XXX_Size

func (m *HistoryResp) XXX_Size() int

func (*HistoryResp) XXX_Unmarshal

func (m *HistoryResp) XXX_Unmarshal(b []byte) error

type Lancer

type Lancer struct {
	Buvid                string   `protobuf:"bytes,1,opt,name=buvid,proto3" json:"buvid,omitempty" form:"buvid"`
	UserAgent            string   `protobuf:"bytes,2,opt,name=userAgent,proto3" json:"userAgent,omitempty" form:"userAgent"`
	Refer                string   `protobuf:"bytes,3,opt,name=refer,proto3" json:"refer,omitempty" form:"refer"`
	Cookie               string   `protobuf:"bytes,4,opt,name=cookie,proto3" json:"cookie,omitempty" form:"cookie"`
	Build                int64    `protobuf:"varint,5,opt,name=build,proto3" json:"build,omitempty" form:"build"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*Lancer) Descriptor

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

func (*Lancer) GetBuild

func (m *Lancer) GetBuild() int64

func (*Lancer) GetBuvid

func (m *Lancer) GetBuvid() string

func (*Lancer) GetCookie

func (m *Lancer) GetCookie() string

func (*Lancer) GetRefer

func (m *Lancer) GetRefer() string

func (*Lancer) GetUserAgent

func (m *Lancer) GetUserAgent() string

func (*Lancer) Marshal

func (m *Lancer) Marshal() (dAtA []byte, err error)

func (*Lancer) MarshalTo

func (m *Lancer) MarshalTo(dAtA []byte) (int, error)

func (*Lancer) ProtoMessage

func (*Lancer) ProtoMessage()

func (*Lancer) Reset

func (m *Lancer) Reset()

func (*Lancer) Size

func (m *Lancer) Size() (n int)

func (*Lancer) String

func (m *Lancer) String() string

func (*Lancer) Unmarshal

func (m *Lancer) Unmarshal(dAtA []byte) error

func (*Lancer) XXX_DiscardUnknown

func (m *Lancer) XXX_DiscardUnknown()

func (*Lancer) XXX_Marshal

func (m *Lancer) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*Lancer) XXX_Merge

func (dst *Lancer) XXX_Merge(src proto.Message)

func (*Lancer) XXX_Size

func (m *Lancer) XXX_Size() int

func (*Lancer) XXX_Unmarshal

func (m *Lancer) XXX_Unmarshal(b []byte) error

type SendMsgReq

type SendMsgReq struct {
	Uid                  int64    `protobuf:"varint,1,opt,name=uid,proto3" json:"uid,omitempty" form:"uid" validate:"required"`
	Roomid               int64    `protobuf:"varint,2,opt,name=roomid,proto3" json:"roomid,omitempty" form:"roomid" validate:"required"`
	Msg                  string   `protobuf:"bytes,3,opt,name=msg,proto3" json:"msg,omitempty" form:"msg" validate:"required"`
	Rnd                  string   `protobuf:"bytes,4,opt,name=rnd,proto3" json:"rnd,omitempty" form:"rnd"`
	Ip                   string   `protobuf:"bytes,5,opt,name=ip,proto3" json:"ip,omitempty" form:"ip"`
	Fontsize             int64    `protobuf:"varint,7,opt,name=fontsize,proto3" json:"fontsize,omitempty" form:"fontsize" validate:"gte=0"`
	Mode                 int64    `protobuf:"varint,8,opt,name=mode,proto3" json:"mode,omitempty" form:"mode" validate:"gte=0"`
	Platform             string   `protobuf:"bytes,9,opt,name=platform,proto3" json:"platform,omitempty" form:"platform"`
	Msgtype              int64    `protobuf:"varint,10,opt,name=msgtype,proto3" json:"msgtype,omitempty" form:"msgtype" validate:"gte=0"`
	Bubble               int64    `protobuf:"varint,11,opt,name=bubble,proto3" json:"bubble,omitempty" form:"bubble"`
	Lancer               *Lancer  `protobuf:"bytes,12,opt,name=lancer" json:"lancer,omitempty" form:"lancer"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SendMsgReq) Descriptor

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

func (*SendMsgReq) GetBubble

func (m *SendMsgReq) GetBubble() int64

func (*SendMsgReq) GetFontsize

func (m *SendMsgReq) GetFontsize() int64

func (*SendMsgReq) GetIp

func (m *SendMsgReq) GetIp() string

func (*SendMsgReq) GetLancer

func (m *SendMsgReq) GetLancer() *Lancer

func (*SendMsgReq) GetMode

func (m *SendMsgReq) GetMode() int64

func (*SendMsgReq) GetMsg

func (m *SendMsgReq) GetMsg() string

func (*SendMsgReq) GetMsgtype

func (m *SendMsgReq) GetMsgtype() int64

func (*SendMsgReq) GetPlatform

func (m *SendMsgReq) GetPlatform() string

func (*SendMsgReq) GetRnd

func (m *SendMsgReq) GetRnd() string

func (*SendMsgReq) GetRoomid

func (m *SendMsgReq) GetRoomid() int64

func (*SendMsgReq) GetUid

func (m *SendMsgReq) GetUid() int64

func (*SendMsgReq) Marshal

func (m *SendMsgReq) Marshal() (dAtA []byte, err error)

func (*SendMsgReq) MarshalTo

func (m *SendMsgReq) MarshalTo(dAtA []byte) (int, error)

func (*SendMsgReq) ProtoMessage

func (*SendMsgReq) ProtoMessage()

func (*SendMsgReq) Reset

func (m *SendMsgReq) Reset()

func (*SendMsgReq) Size

func (m *SendMsgReq) Size() (n int)

func (*SendMsgReq) String

func (m *SendMsgReq) String() string

func (*SendMsgReq) Unmarshal

func (m *SendMsgReq) Unmarshal(dAtA []byte) error

func (*SendMsgReq) XXX_DiscardUnknown

func (m *SendMsgReq) XXX_DiscardUnknown()

func (*SendMsgReq) XXX_Marshal

func (m *SendMsgReq) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SendMsgReq) XXX_Merge

func (dst *SendMsgReq) XXX_Merge(src proto.Message)

func (*SendMsgReq) XXX_Size

func (m *SendMsgReq) XXX_Size() int

func (*SendMsgReq) XXX_Unmarshal

func (m *SendMsgReq) XXX_Unmarshal(b []byte) error

type SendMsgResp

type SendMsgResp struct {
	IsLimit              bool     `protobuf:"varint,1,opt,name=isLimit,proto3" json:"islimit"`
	LimitMsg             string   `protobuf:"bytes,2,opt,name=limitMsg,proto3" json:"limitmsg"`
	Code                 int32    `protobuf:"varint,3,opt,name=code,proto3" json:"code"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*SendMsgResp) Descriptor

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

func (*SendMsgResp) GetCode

func (m *SendMsgResp) GetCode() int32

func (*SendMsgResp) GetIsLimit

func (m *SendMsgResp) GetIsLimit() bool

func (*SendMsgResp) GetLimitMsg

func (m *SendMsgResp) GetLimitMsg() string

func (*SendMsgResp) Marshal

func (m *SendMsgResp) Marshal() (dAtA []byte, err error)

func (*SendMsgResp) MarshalTo

func (m *SendMsgResp) MarshalTo(dAtA []byte) (int, error)

func (*SendMsgResp) ProtoMessage

func (*SendMsgResp) ProtoMessage()

func (*SendMsgResp) Reset

func (m *SendMsgResp) Reset()

func (*SendMsgResp) Size

func (m *SendMsgResp) Size() (n int)

func (*SendMsgResp) String

func (m *SendMsgResp) String() string

func (*SendMsgResp) Unmarshal

func (m *SendMsgResp) Unmarshal(dAtA []byte) error

func (*SendMsgResp) XXX_DiscardUnknown

func (m *SendMsgResp) XXX_DiscardUnknown()

func (*SendMsgResp) XXX_Marshal

func (m *SendMsgResp) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*SendMsgResp) XXX_Merge

func (dst *SendMsgResp) XXX_Merge(src proto.Message)

func (*SendMsgResp) XXX_Size

func (m *SendMsgResp) XXX_Size() int

func (*SendMsgResp) XXX_Unmarshal

func (m *SendMsgResp) XXX_Unmarshal(b []byte) error

Jump to

Keyboard shortcuts

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