api

package
Version: v0.0.0-...-46b6d0d Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2020 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Overview

Package api is a generated blademaster stub package. This code was generated with kratos/tool/protobuf/protoc-gen-bm v0.1.

package 命名使用 {appid}.{version} 的方式, version 形如 v1, v2 ..

It is generated from these files:

api.proto

Index

Constants

View Source
const AppID = "TODO: ADD APP ID"

AppID .

Variables

View Source
var (
	ErrInvalidLengthApi        = fmt.Errorf("proto: negative length found during unmarshaling")
	ErrIntOverflowApi          = fmt.Errorf("proto: integer overflow")
	ErrUnexpectedEndOfGroupApi = fmt.Errorf("proto: unexpected end of group")
)
View Source
var PathDemoPing = "/demo.service.v1.Demo/Ping"
View Source
var PathDemoSayHello = "/demo.service.v1.Demo/SayHello"
View Source
var PathDemoSayHelloURL = "/kratos-demo/say_hello"

Functions

func RegisterDemoBMServer

func RegisterDemoBMServer(e *bm.Engine, server DemoBMServer)

RegisterDemoBMServer Register the blademaster route

func RegisterDemoServer

func RegisterDemoServer(s *grpc.Server, srv DemoServer)

Types

type DemoBMServer

type DemoBMServer interface {
	Ping(ctx context.Context, req *google_protobuf1.Empty) (resp *google_protobuf1.Empty, err error)

	SayHello(ctx context.Context, req *HelloReq) (resp *google_protobuf1.Empty, err error)

	SayHelloURL(ctx context.Context, req *HelloReq) (resp *HelloResp, err error)
}

DemoBMServer is the server API for Demo service.

var DemoSvc DemoBMServer

type DemoClient

type DemoClient interface {
	Ping(ctx context.Context, in *empty.Empty, opts ...grpc.CallOption) (*empty.Empty, error)
	SayHello(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*empty.Empty, error)
	SayHelloURL(ctx context.Context, in *HelloReq, opts ...grpc.CallOption) (*HelloResp, error)
}

DemoClient is the client API for Demo 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) (DemoClient, error)

NewClient new grpc client

func NewDemoClient

func NewDemoClient(cc *grpc.ClientConn) DemoClient

type DemoServer

type DemoServer interface {
	Ping(context.Context, *empty.Empty) (*empty.Empty, error)
	SayHello(context.Context, *HelloReq) (*empty.Empty, error)
	SayHelloURL(context.Context, *HelloReq) (*HelloResp, error)
}

DemoServer is the server API for Demo service.

type HelloReq

type HelloReq struct {
	Name                 string   `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty" form:"name" validate:"required"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HelloReq) Descriptor

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

func (*HelloReq) Marshal

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

func (*HelloReq) MarshalTo

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

func (*HelloReq) MarshalToSizedBuffer

func (m *HelloReq) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HelloReq) ProtoMessage

func (*HelloReq) ProtoMessage()

func (*HelloReq) Reset

func (m *HelloReq) Reset()

func (*HelloReq) Size

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

func (*HelloReq) String

func (m *HelloReq) String() string

func (*HelloReq) Unmarshal

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

func (*HelloReq) XXX_DiscardUnknown

func (m *HelloReq) XXX_DiscardUnknown()

func (*HelloReq) XXX_Marshal

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

func (*HelloReq) XXX_Merge

func (m *HelloReq) XXX_Merge(src proto.Message)

func (*HelloReq) XXX_Size

func (m *HelloReq) XXX_Size() int

func (*HelloReq) XXX_Unmarshal

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

type HelloResp

type HelloResp struct {
	Content              string   `protobuf:"bytes,1,opt,name=Content,proto3" json:"content"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*HelloResp) Descriptor

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

func (*HelloResp) Marshal

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

func (*HelloResp) MarshalTo

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

func (*HelloResp) MarshalToSizedBuffer

func (m *HelloResp) MarshalToSizedBuffer(dAtA []byte) (int, error)

func (*HelloResp) ProtoMessage

func (*HelloResp) ProtoMessage()

func (*HelloResp) Reset

func (m *HelloResp) Reset()

func (*HelloResp) Size

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

func (*HelloResp) String

func (m *HelloResp) String() string

func (*HelloResp) Unmarshal

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

func (*HelloResp) XXX_DiscardUnknown

func (m *HelloResp) XXX_DiscardUnknown()

func (*HelloResp) XXX_Marshal

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

func (*HelloResp) XXX_Merge

func (m *HelloResp) XXX_Merge(src proto.Message)

func (*HelloResp) XXX_Size

func (m *HelloResp) XXX_Size() int

func (*HelloResp) XXX_Unmarshal

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

type UnimplementedDemoServer

type UnimplementedDemoServer struct {
}

UnimplementedDemoServer can be embedded to have forward compatible implementations.

func (*UnimplementedDemoServer) Ping

func (*UnimplementedDemoServer) SayHello

func (*UnimplementedDemoServer) SayHello(ctx context.Context, req *HelloReq) (*empty.Empty, error)

func (*UnimplementedDemoServer) SayHelloURL

func (*UnimplementedDemoServer) SayHelloURL(ctx context.Context, req *HelloReq) (*HelloResp, error)

Jump to

Keyboard shortcuts

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