simple_interface

package
v1.0.3 Latest Latest
Warning

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

Go to latest
Published: Sep 26, 2022 License: GPL-3.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Type_name = map[int32]string{
		0: "String",
		1: "Number",
		2: "Bool",
		3: "StringArray",
	}
	Type_value = map[string]int32{
		"String":      0,
		"Number":      1,
		"Bool":        2,
		"StringArray": 3,
	}
)

Enum value maps for Type.

View Source
var (
	ConfigType_name = map[int32]string{
		0: "JSON",
		1: "YAML",
		2: "URL",
		3: "TEXT",
	}
	ConfigType_value = map[string]int32{
		"JSON": 0,
		"YAML": 1,
		"URL":  2,
		"TEXT": 3,
	}
)

Enum value maps for ConfigType.

View Source
var (
	Code_name = map[int32]string{
		0:     "OK",
		10404: "NotFound",
		10500: "Fail",
	}
	Code_value = map[string]int32{
		"OK":       0,
		"NotFound": 10404,
		"Fail":     10500,
	}
)

Enum value maps for Code.

View Source
var File_proto_simple_interface_interface_proto protoreflect.FileDescriptor
View Source
var Interface_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "interface.Interface",
	HandlerType: (*InterfaceServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Name",
			Handler:    _Interface_Name_Handler,
		},
		{
			MethodName: "IsSupportPersistence",
			Handler:    _Interface_IsSupportPersistence_Handler,
		},
		{
			MethodName: "CustomOptionSchema",
			Handler:    _Interface_CustomOptionSchema_Handler,
		},
		{
			MethodName: "SetMetadata",
			Handler:    _Interface_SetMetadata_Handler,
		},
		{
			MethodName: "Create",
			Handler:    _Interface_Create_Handler,
		},
		{
			MethodName: "CreateByConfig",
			Handler:    _Interface_CreateByConfig_Handler,
		},
		{
			MethodName: "Get",
			Handler:    _Interface_Get_Handler,
		},
		{
			MethodName: "Delete",
			Handler:    _Interface_Delete_Handler,
		},
		{
			MethodName: "GetAll",
			Handler:    _Interface_GetAll_Handler,
		},
		{
			MethodName: "UpdateOption",
			Handler:    _Interface_UpdateOption_Handler,
		},
		{
			MethodName: "GetStat",
			Handler:    _Interface_GetStat_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/simple-interface/interface.proto",
}

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

Functions

func RegisterInterfaceServer

func RegisterInterfaceServer(s grpc.ServiceRegistrar, srv InterfaceServer)

Types

type Code

type Code int32
const (
	Code_OK       Code = 0 // 请求成功
	Code_NotFound Code = 10404
	Code_Fail     Code = 10500
)

func (Code) Descriptor

func (Code) Descriptor() protoreflect.EnumDescriptor

func (Code) Enum

func (x Code) Enum() *Code

func (Code) EnumDescriptor deprecated

func (Code) EnumDescriptor() ([]byte, []int)

Deprecated: Use Code.Descriptor instead.

func (Code) Number

func (x Code) Number() protoreflect.EnumNumber

func (Code) String

func (x Code) String() string

func (Code) Type

func (Code) Type() protoreflect.EnumType

type Config

type Config struct {
	Name       string     `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"`
	ConfigType ConfigType `protobuf:"varint,2,opt,name=ConfigType,proto3,enum=interface.ConfigType" json:"ConfigType,omitempty"`
	Config     []byte     `protobuf:"bytes,3,opt,name=Config,proto3" json:"Config,omitempty"`
	// contains filtered or unexported fields
}

func (*Config) Descriptor deprecated

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

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (*Config) GetConfig

func (x *Config) GetConfig() []byte

func (*Config) GetConfigType

func (x *Config) GetConfigType() ConfigType

func (*Config) GetName

func (x *Config) GetName() string

func (*Config) ProtoMessage

func (*Config) ProtoMessage()

func (*Config) ProtoReflect

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

func (*Config) Reset

func (x *Config) Reset()

func (*Config) String

func (x *Config) String() string

type ConfigType

type ConfigType int32
const (
	ConfigType_JSON ConfigType = 0
	ConfigType_YAML ConfigType = 1
	ConfigType_URL  ConfigType = 2
	ConfigType_TEXT ConfigType = 3
)

func (ConfigType) Descriptor

func (ConfigType) Descriptor() protoreflect.EnumDescriptor

func (ConfigType) Enum

func (x ConfigType) Enum() *ConfigType

func (ConfigType) EnumDescriptor deprecated

func (ConfigType) EnumDescriptor() ([]byte, []int)

Deprecated: Use ConfigType.Descriptor instead.

func (ConfigType) Number

func (x ConfigType) Number() protoreflect.EnumNumber

func (ConfigType) String

func (x ConfigType) String() string

func (ConfigType) Type

type CreateByConfigReq

type CreateByConfigReq struct {
	Index        string  `protobuf:"bytes,1,opt,name=Index,proto3" json:"Index,omitempty"`
	Config       *Config `protobuf:"bytes,2,opt,name=Config,proto3" json:"Config,omitempty"`
	Opt          *Option `protobuf:"bytes,3,opt,name=Opt,proto3" json:"Opt,omitempty"`
	CustomOption string  `protobuf:"bytes,4,opt,name=CustomOption,proto3" json:"CustomOption,omitempty"` // in json
	// contains filtered or unexported fields
}

func (*CreateByConfigReq) Descriptor deprecated

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

Deprecated: Use CreateByConfigReq.ProtoReflect.Descriptor instead.

func (*CreateByConfigReq) GetConfig

func (x *CreateByConfigReq) GetConfig() *Config

func (*CreateByConfigReq) GetCustomOption

func (x *CreateByConfigReq) GetCustomOption() string

func (*CreateByConfigReq) GetIndex

func (x *CreateByConfigReq) GetIndex() string

func (*CreateByConfigReq) GetOpt

func (x *CreateByConfigReq) GetOpt() *Option

func (*CreateByConfigReq) ProtoMessage

func (*CreateByConfigReq) ProtoMessage()

func (*CreateByConfigReq) ProtoReflect

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

func (*CreateByConfigReq) Reset

func (x *CreateByConfigReq) Reset()

func (*CreateByConfigReq) String

func (x *CreateByConfigReq) String() string

type CreateByConfigRsp

type CreateByConfigRsp struct {
	Code Code   `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateByConfigRsp) Descriptor deprecated

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

Deprecated: Use CreateByConfigRsp.ProtoReflect.Descriptor instead.

func (*CreateByConfigRsp) GetCode

func (x *CreateByConfigRsp) GetCode() Code

func (*CreateByConfigRsp) GetMsg

func (x *CreateByConfigRsp) GetMsg() string

func (*CreateByConfigRsp) ProtoMessage

func (*CreateByConfigRsp) ProtoMessage()

func (*CreateByConfigRsp) ProtoReflect

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

func (*CreateByConfigRsp) Reset

func (x *CreateByConfigRsp) Reset()

func (*CreateByConfigRsp) String

func (x *CreateByConfigRsp) String() string

type CreateReq

type CreateReq struct {
	Opt          *Option    `protobuf:"bytes,1,opt,name=Opt,proto3" json:"Opt,omitempty"`
	ConfigType   ConfigType `protobuf:"varint,2,opt,name=ConfigType,proto3,enum=interface.ConfigType" json:"ConfigType,omitempty"`
	CustomOption string     `protobuf:"bytes,3,opt,name=CustomOption,proto3" json:"CustomOption,omitempty"` // in json
	// contains filtered or unexported fields
}

func (*CreateReq) Descriptor deprecated

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

Deprecated: Use CreateReq.ProtoReflect.Descriptor instead.

func (*CreateReq) GetConfigType

func (x *CreateReq) GetConfigType() ConfigType

func (*CreateReq) GetCustomOption

func (x *CreateReq) GetCustomOption() string

func (*CreateReq) GetOpt

func (x *CreateReq) GetOpt() *Option

func (*CreateReq) ProtoMessage

func (*CreateReq) ProtoMessage()

func (*CreateReq) ProtoReflect

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

func (*CreateReq) Reset

func (x *CreateReq) Reset()

func (*CreateReq) String

func (x *CreateReq) String() string

type CreateRsp

type CreateRsp struct {
	Code   Code    `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg    string  `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	Index  string  `protobuf:"bytes,3,opt,name=Index,proto3" json:"Index,omitempty"`
	Config *Config `protobuf:"bytes,4,opt,name=Config,proto3" json:"Config,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateRsp) Descriptor deprecated

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

Deprecated: Use CreateRsp.ProtoReflect.Descriptor instead.

func (*CreateRsp) GetCode

func (x *CreateRsp) GetCode() Code

func (*CreateRsp) GetConfig

func (x *CreateRsp) GetConfig() *Config

func (*CreateRsp) GetIndex

func (x *CreateRsp) GetIndex() string

func (*CreateRsp) GetMsg

func (x *CreateRsp) GetMsg() string

func (*CreateRsp) ProtoMessage

func (*CreateRsp) ProtoMessage()

func (*CreateRsp) ProtoReflect

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

func (*CreateRsp) Reset

func (x *CreateRsp) Reset()

func (*CreateRsp) String

func (x *CreateRsp) String() string

type CustomOptionSchemaReq

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

func (*CustomOptionSchemaReq) Descriptor deprecated

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

Deprecated: Use CustomOptionSchemaReq.ProtoReflect.Descriptor instead.

func (*CustomOptionSchemaReq) ProtoMessage

func (*CustomOptionSchemaReq) ProtoMessage()

func (*CustomOptionSchemaReq) ProtoReflect

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

func (*CustomOptionSchemaReq) Reset

func (x *CustomOptionSchemaReq) Reset()

func (*CustomOptionSchemaReq) String

func (x *CustomOptionSchemaReq) String() string

type CustomOptionSchemaRsp

type CustomOptionSchemaRsp struct {
	Fields []*Field `protobuf:"bytes,1,rep,name=Fields,proto3" json:"Fields,omitempty"`
	// contains filtered or unexported fields
}

func (*CustomOptionSchemaRsp) Descriptor deprecated

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

Deprecated: Use CustomOptionSchemaRsp.ProtoReflect.Descriptor instead.

func (*CustomOptionSchemaRsp) GetFields

func (x *CustomOptionSchemaRsp) GetFields() []*Field

func (*CustomOptionSchemaRsp) ProtoMessage

func (*CustomOptionSchemaRsp) ProtoMessage()

func (*CustomOptionSchemaRsp) ProtoReflect

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

func (*CustomOptionSchemaRsp) Reset

func (x *CustomOptionSchemaRsp) Reset()

func (*CustomOptionSchemaRsp) String

func (x *CustomOptionSchemaRsp) String() string

type DeleteReq

type DeleteReq struct {
	Index string `protobuf:"bytes,1,opt,name=Index,proto3" json:"Index,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteReq) Descriptor deprecated

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

Deprecated: Use DeleteReq.ProtoReflect.Descriptor instead.

func (*DeleteReq) GetIndex

func (x *DeleteReq) GetIndex() string

func (*DeleteReq) ProtoMessage

func (*DeleteReq) ProtoMessage()

func (*DeleteReq) ProtoReflect

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

func (*DeleteReq) Reset

func (x *DeleteReq) Reset()

func (*DeleteReq) String

func (x *DeleteReq) String() string

type DeleteRsp

type DeleteRsp struct {
	Code Code   `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	// contains filtered or unexported fields
}

func (*DeleteRsp) Descriptor deprecated

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

Deprecated: Use DeleteRsp.ProtoReflect.Descriptor instead.

func (*DeleteRsp) GetCode

func (x *DeleteRsp) GetCode() Code

func (*DeleteRsp) GetMsg

func (x *DeleteRsp) GetMsg() string

func (*DeleteRsp) ProtoMessage

func (*DeleteRsp) ProtoMessage()

func (*DeleteRsp) ProtoReflect

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

func (*DeleteRsp) Reset

func (x *DeleteRsp) Reset()

func (*DeleteRsp) String

func (x *DeleteRsp) String() string

type Field

type Field struct {
	Name     string   `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"`
	Type     Type     `protobuf:"varint,2,opt,name=Type,proto3,enum=interface.Type" json:"Type,omitempty"`
	Optional []string `protobuf:"bytes,3,rep,name=optional,proto3" json:"optional,omitempty"`
	// contains filtered or unexported fields
}

func (*Field) Descriptor deprecated

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

Deprecated: Use Field.ProtoReflect.Descriptor instead.

func (*Field) GetName

func (x *Field) GetName() string

func (*Field) GetOptional

func (x *Field) GetOptional() []string

func (*Field) GetType

func (x *Field) GetType() Type

func (*Field) ProtoMessage

func (*Field) ProtoMessage()

func (*Field) ProtoReflect

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

func (*Field) Reset

func (x *Field) Reset()

func (*Field) String

func (x *Field) String() string

type GetAllReq

type GetAllReq struct {
	ConfigType ConfigType `protobuf:"varint,1,opt,name=ConfigType,proto3,enum=interface.ConfigType" json:"ConfigType,omitempty"`
	// contains filtered or unexported fields
}

func (*GetAllReq) Descriptor deprecated

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

Deprecated: Use GetAllReq.ProtoReflect.Descriptor instead.

func (*GetAllReq) GetConfigType

func (x *GetAllReq) GetConfigType() ConfigType

func (*GetAllReq) ProtoMessage

func (*GetAllReq) ProtoMessage()

func (*GetAllReq) ProtoReflect

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

func (*GetAllReq) Reset

func (x *GetAllReq) Reset()

func (*GetAllReq) String

func (x *GetAllReq) String() string

type GetAllRsp

type GetAllRsp struct {
	Code Code               `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg  string             `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	All  map[string]*Config `` // Index, Config
	/* 147-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*GetAllRsp) Descriptor deprecated

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

Deprecated: Use GetAllRsp.ProtoReflect.Descriptor instead.

func (*GetAllRsp) GetAll

func (x *GetAllRsp) GetAll() map[string]*Config

func (*GetAllRsp) GetCode

func (x *GetAllRsp) GetCode() Code

func (*GetAllRsp) GetMsg

func (x *GetAllRsp) GetMsg() string

func (*GetAllRsp) ProtoMessage

func (*GetAllRsp) ProtoMessage()

func (*GetAllRsp) ProtoReflect

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

func (*GetAllRsp) Reset

func (x *GetAllRsp) Reset()

func (*GetAllRsp) String

func (x *GetAllRsp) String() string

type GetReq

type GetReq struct {
	Index      string     `protobuf:"bytes,1,opt,name=Index,proto3" json:"Index,omitempty"`
	ConfigType ConfigType `protobuf:"varint,2,opt,name=ConfigType,proto3,enum=interface.ConfigType" json:"ConfigType,omitempty"`
	// contains filtered or unexported fields
}

func (*GetReq) Descriptor deprecated

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

Deprecated: Use GetReq.ProtoReflect.Descriptor instead.

func (*GetReq) GetConfigType

func (x *GetReq) GetConfigType() ConfigType

func (*GetReq) GetIndex

func (x *GetReq) GetIndex() string

func (*GetReq) ProtoMessage

func (*GetReq) ProtoMessage()

func (*GetReq) ProtoReflect

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

func (*GetReq) Reset

func (x *GetReq) Reset()

func (*GetReq) String

func (x *GetReq) String() string

type GetRsp

type GetRsp struct {
	Code   Code    `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg    string  `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	Index  string  `protobuf:"bytes,3,opt,name=Index,proto3" json:"Index,omitempty"`
	Config *Config `protobuf:"bytes,4,opt,name=Config,proto3" json:"Config,omitempty"`
	// contains filtered or unexported fields
}

func (*GetRsp) Descriptor deprecated

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

Deprecated: Use GetRsp.ProtoReflect.Descriptor instead.

func (*GetRsp) GetCode

func (x *GetRsp) GetCode() Code

func (*GetRsp) GetConfig

func (x *GetRsp) GetConfig() *Config

func (*GetRsp) GetIndex

func (x *GetRsp) GetIndex() string

func (*GetRsp) GetMsg

func (x *GetRsp) GetMsg() string

func (*GetRsp) ProtoMessage

func (*GetRsp) ProtoMessage()

func (*GetRsp) ProtoReflect

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

func (*GetRsp) Reset

func (x *GetRsp) Reset()

func (*GetRsp) String

func (x *GetRsp) String() string

type GetStatReq

type GetStatReq struct {
	Index string `protobuf:"bytes,1,opt,name=Index,proto3" json:"Index,omitempty"`
	// contains filtered or unexported fields
}

func (*GetStatReq) Descriptor deprecated

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

Deprecated: Use GetStatReq.ProtoReflect.Descriptor instead.

func (*GetStatReq) GetIndex

func (x *GetStatReq) GetIndex() string

func (*GetStatReq) ProtoMessage

func (*GetStatReq) ProtoMessage()

func (*GetStatReq) ProtoReflect

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

func (*GetStatReq) Reset

func (x *GetStatReq) Reset()

func (*GetStatReq) String

func (x *GetStatReq) String() string

type GetStatRsp

type GetStatRsp struct {
	Code Code   `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	Stat *Stat  `protobuf:"bytes,3,opt,name=Stat,proto3" json:"Stat,omitempty"`
	// contains filtered or unexported fields
}

func (*GetStatRsp) Descriptor deprecated

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

Deprecated: Use GetStatRsp.ProtoReflect.Descriptor instead.

func (*GetStatRsp) GetCode

func (x *GetStatRsp) GetCode() Code

func (*GetStatRsp) GetMsg

func (x *GetStatRsp) GetMsg() string

func (*GetStatRsp) GetStat

func (x *GetStatRsp) GetStat() *Stat

func (*GetStatRsp) ProtoMessage

func (*GetStatRsp) ProtoMessage()

func (*GetStatRsp) ProtoReflect

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

func (*GetStatRsp) Reset

func (x *GetStatRsp) Reset()

func (*GetStatRsp) String

func (x *GetStatRsp) String() string

type InterfaceClient

type InterfaceClient interface {
	Name(ctx context.Context, in *NameReq, opts ...grpc.CallOption) (*NameRsp, error)
	IsSupportPersistence(ctx context.Context, in *IsSupportPersistenceReq, opts ...grpc.CallOption) (*IsSupportPersistenceRsp, error)
	CustomOptionSchema(ctx context.Context, in *CustomOptionSchemaReq, opts ...grpc.CallOption) (*CustomOptionSchemaRsp, error)
	SetMetadata(ctx context.Context, in *SetMetadataReq, opts ...grpc.CallOption) (*SetMetadataRsp, error)
	Create(ctx context.Context, in *CreateReq, opts ...grpc.CallOption) (*CreateRsp, error)
	CreateByConfig(ctx context.Context, in *CreateByConfigReq, opts ...grpc.CallOption) (*CreateByConfigRsp, error)
	Get(ctx context.Context, in *GetReq, opts ...grpc.CallOption) (*GetRsp, error)
	Delete(ctx context.Context, in *DeleteReq, opts ...grpc.CallOption) (*DeleteRsp, error)
	GetAll(ctx context.Context, in *GetAllReq, opts ...grpc.CallOption) (*GetAllRsp, error)
	UpdateOption(ctx context.Context, in *UpdateOptionReq, opts ...grpc.CallOption) (*UpdateOptionRsp, error)
	GetStat(ctx context.Context, in *GetStatReq, opts ...grpc.CallOption) (*GetStatRsp, error)
}

InterfaceClient is the client API for Interface 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.

func NewInterfaceClient

func NewInterfaceClient(cc grpc.ClientConnInterface) InterfaceClient

type InterfaceServer

type InterfaceServer interface {
	Name(context.Context, *NameReq) (*NameRsp, error)
	IsSupportPersistence(context.Context, *IsSupportPersistenceReq) (*IsSupportPersistenceRsp, error)
	CustomOptionSchema(context.Context, *CustomOptionSchemaReq) (*CustomOptionSchemaRsp, error)
	SetMetadata(context.Context, *SetMetadataReq) (*SetMetadataRsp, error)
	Create(context.Context, *CreateReq) (*CreateRsp, error)
	CreateByConfig(context.Context, *CreateByConfigReq) (*CreateByConfigRsp, error)
	Get(context.Context, *GetReq) (*GetRsp, error)
	Delete(context.Context, *DeleteReq) (*DeleteRsp, error)
	GetAll(context.Context, *GetAllReq) (*GetAllRsp, error)
	UpdateOption(context.Context, *UpdateOptionReq) (*UpdateOptionRsp, error)
	GetStat(context.Context, *GetStatReq) (*GetStatRsp, error)
	// contains filtered or unexported methods
}

InterfaceServer is the server API for Interface service. All implementations must embed UnimplementedInterfaceServer for forward compatibility

type IsSupportPersistenceReq

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

func (*IsSupportPersistenceReq) Descriptor deprecated

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

Deprecated: Use IsSupportPersistenceReq.ProtoReflect.Descriptor instead.

func (*IsSupportPersistenceReq) ProtoMessage

func (*IsSupportPersistenceReq) ProtoMessage()

func (*IsSupportPersistenceReq) ProtoReflect

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

func (*IsSupportPersistenceReq) Reset

func (x *IsSupportPersistenceReq) Reset()

func (*IsSupportPersistenceReq) String

func (x *IsSupportPersistenceReq) String() string

type IsSupportPersistenceRsp

type IsSupportPersistenceRsp struct {
	IsSupport bool `protobuf:"varint,1,opt,name=IsSupport,proto3" json:"IsSupport,omitempty"`
	// contains filtered or unexported fields
}

func (*IsSupportPersistenceRsp) Descriptor deprecated

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

Deprecated: Use IsSupportPersistenceRsp.ProtoReflect.Descriptor instead.

func (*IsSupportPersistenceRsp) GetIsSupport

func (x *IsSupportPersistenceRsp) GetIsSupport() bool

func (*IsSupportPersistenceRsp) ProtoMessage

func (*IsSupportPersistenceRsp) ProtoMessage()

func (*IsSupportPersistenceRsp) ProtoReflect

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

func (*IsSupportPersistenceRsp) Reset

func (x *IsSupportPersistenceRsp) Reset()

func (*IsSupportPersistenceRsp) String

func (x *IsSupportPersistenceRsp) String() string

type NameReq

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

func (*NameReq) Descriptor deprecated

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

Deprecated: Use NameReq.ProtoReflect.Descriptor instead.

func (*NameReq) ProtoMessage

func (*NameReq) ProtoMessage()

func (*NameReq) ProtoReflect

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

func (*NameReq) Reset

func (x *NameReq) Reset()

func (*NameReq) String

func (x *NameReq) String() string

type NameRsp

type NameRsp struct {
	Name string `protobuf:"bytes,1,opt,name=Name,proto3" json:"Name,omitempty"`
	// contains filtered or unexported fields
}

func (*NameRsp) Descriptor deprecated

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

Deprecated: Use NameRsp.ProtoReflect.Descriptor instead.

func (*NameRsp) GetName

func (x *NameRsp) GetName() string

func (*NameRsp) ProtoMessage

func (*NameRsp) ProtoMessage()

func (*NameRsp) ProtoReflect

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

func (*NameRsp) Reset

func (x *NameRsp) Reset()

func (*NameRsp) String

func (x *NameRsp) String() string

type Option

type Option struct {
	SendRateLimit uint64 `protobuf:"varint,1,opt,name=SendRateLimit,proto3" json:"SendRateLimit,omitempty"`
	RecvRateLimit uint64 `protobuf:"varint,2,opt,name=RecvRateLimit,proto3" json:"RecvRateLimit,omitempty"`
	// contains filtered or unexported fields
}

func (*Option) Descriptor deprecated

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

Deprecated: Use Option.ProtoReflect.Descriptor instead.

func (*Option) GetRecvRateLimit

func (x *Option) GetRecvRateLimit() uint64

func (*Option) GetSendRateLimit

func (x *Option) GetSendRateLimit() uint64

func (*Option) ProtoMessage

func (*Option) ProtoMessage()

func (*Option) ProtoReflect

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

func (*Option) Reset

func (x *Option) Reset()

func (*Option) String

func (x *Option) String() string

type SetMetadataReq

type SetMetadataReq struct {
	IP     string `protobuf:"bytes,1,opt,name=IP,proto3" json:"IP,omitempty"`
	Domain string `protobuf:"bytes,2,opt,name=Domain,proto3" json:"Domain,omitempty"`
	// contains filtered or unexported fields
}

func (*SetMetadataReq) Descriptor deprecated

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

Deprecated: Use SetMetadataReq.ProtoReflect.Descriptor instead.

func (*SetMetadataReq) GetDomain

func (x *SetMetadataReq) GetDomain() string

func (*SetMetadataReq) GetIP

func (x *SetMetadataReq) GetIP() string

func (*SetMetadataReq) ProtoMessage

func (*SetMetadataReq) ProtoMessage()

func (*SetMetadataReq) ProtoReflect

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

func (*SetMetadataReq) Reset

func (x *SetMetadataReq) Reset()

func (*SetMetadataReq) String

func (x *SetMetadataReq) String() string

type SetMetadataRsp

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

func (*SetMetadataRsp) Descriptor deprecated

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

Deprecated: Use SetMetadataRsp.ProtoReflect.Descriptor instead.

func (*SetMetadataRsp) ProtoMessage

func (*SetMetadataRsp) ProtoMessage()

func (*SetMetadataRsp) ProtoReflect

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

func (*SetMetadataRsp) Reset

func (x *SetMetadataRsp) Reset()

func (*SetMetadataRsp) String

func (x *SetMetadataRsp) String() string

type Stat

type Stat struct {
	SendTraffic uint64 `protobuf:"varint,1,opt,name=SendTraffic,proto3" json:"SendTraffic,omitempty"`
	RecvTraffic uint64 `protobuf:"varint,2,opt,name=RecvTraffic,proto3" json:"RecvTraffic,omitempty"`
	// contains filtered or unexported fields
}

func (*Stat) Descriptor deprecated

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

Deprecated: Use Stat.ProtoReflect.Descriptor instead.

func (*Stat) GetRecvTraffic

func (x *Stat) GetRecvTraffic() uint64

func (*Stat) GetSendTraffic

func (x *Stat) GetSendTraffic() uint64

func (*Stat) ProtoMessage

func (*Stat) ProtoMessage()

func (*Stat) ProtoReflect

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

func (*Stat) Reset

func (x *Stat) Reset()

func (*Stat) String

func (x *Stat) String() string

type Type

type Type int32
const (
	Type_String      Type = 0
	Type_Number      Type = 1
	Type_Bool        Type = 2
	Type_StringArray Type = 3
)

func (Type) Descriptor

func (Type) Descriptor() protoreflect.EnumDescriptor

func (Type) Enum

func (x Type) Enum() *Type

func (Type) EnumDescriptor deprecated

func (Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use Type.Descriptor instead.

func (Type) Number

func (x Type) Number() protoreflect.EnumNumber

func (Type) String

func (x Type) String() string

func (Type) Type

func (Type) Type() protoreflect.EnumType

type UnimplementedInterfaceServer

type UnimplementedInterfaceServer struct {
}

UnimplementedInterfaceServer must be embedded to have forward compatible implementations.

func (UnimplementedInterfaceServer) Create

func (UnimplementedInterfaceServer) CreateByConfig

func (UnimplementedInterfaceServer) CustomOptionSchema

func (UnimplementedInterfaceServer) Delete

func (UnimplementedInterfaceServer) Get

func (UnimplementedInterfaceServer) GetAll

func (UnimplementedInterfaceServer) GetStat

func (UnimplementedInterfaceServer) IsSupportPersistence

func (UnimplementedInterfaceServer) Name

func (UnimplementedInterfaceServer) SetMetadata

func (UnimplementedInterfaceServer) UpdateOption

type UnsafeInterfaceServer

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

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

type UpdateOptionReq

type UpdateOptionReq struct {
	Index string  `protobuf:"bytes,1,opt,name=Index,proto3" json:"Index,omitempty"`
	Opt   *Option `protobuf:"bytes,2,opt,name=Opt,proto3" json:"Opt,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateOptionReq) Descriptor deprecated

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

Deprecated: Use UpdateOptionReq.ProtoReflect.Descriptor instead.

func (*UpdateOptionReq) GetIndex

func (x *UpdateOptionReq) GetIndex() string

func (*UpdateOptionReq) GetOpt

func (x *UpdateOptionReq) GetOpt() *Option

func (*UpdateOptionReq) ProtoMessage

func (*UpdateOptionReq) ProtoMessage()

func (*UpdateOptionReq) ProtoReflect

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

func (*UpdateOptionReq) Reset

func (x *UpdateOptionReq) Reset()

func (*UpdateOptionReq) String

func (x *UpdateOptionReq) String() string

type UpdateOptionRsp

type UpdateOptionRsp struct {
	Code Code   `protobuf:"varint,1,opt,name=Code,proto3,enum=interface.Code" json:"Code,omitempty"`
	Msg  string `protobuf:"bytes,2,opt,name=Msg,proto3" json:"Msg,omitempty"`
	// contains filtered or unexported fields
}

func (*UpdateOptionRsp) Descriptor deprecated

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

Deprecated: Use UpdateOptionRsp.ProtoReflect.Descriptor instead.

func (*UpdateOptionRsp) GetCode

func (x *UpdateOptionRsp) GetCode() Code

func (*UpdateOptionRsp) GetMsg

func (x *UpdateOptionRsp) GetMsg() string

func (*UpdateOptionRsp) ProtoMessage

func (*UpdateOptionRsp) ProtoMessage()

func (*UpdateOptionRsp) ProtoReflect

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

func (*UpdateOptionRsp) Reset

func (x *UpdateOptionRsp) Reset()

func (*UpdateOptionRsp) String

func (x *UpdateOptionRsp) String() string

Jump to

Keyboard shortcuts

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