Documentation ¶
Index ¶
- Variables
- func RegisterCoreServer(s *grpc.Server, srv CoreServer)
- type CoreClient
- type CoreServer
- type GetRequest
- func (*GetRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetRequest) GetAll() bool
- func (x *GetRequest) GetPid() []string
- func (x *GetRequest) GetTimestamp() int64
- func (*GetRequest) ProtoMessage()
- func (x *GetRequest) ProtoReflect() protoreflect.Message
- func (x *GetRequest) Reset()
- func (x *GetRequest) String() string
- type GetResponse
- func (*GetResponse) Descriptor() ([]byte, []int)deprecated
- func (x *GetResponse) GetPnd() []*pnd.PrincipalNetworkDomain
- func (x *GetResponse) GetTimestamp() int64
- func (*GetResponse) ProtoMessage()
- func (x *GetResponse) ProtoReflect() protoreflect.Message
- func (x *GetResponse) Reset()
- func (x *GetResponse) String() string
- type SetPnd
- func (*SetPnd) Descriptor() ([]byte, []int)deprecated
- func (x *SetPnd) GetDescription() string
- func (x *SetPnd) GetName() string
- func (x *SetPnd) GetSbi() string
- func (*SetPnd) ProtoMessage()
- func (x *SetPnd) ProtoReflect() protoreflect.Message
- func (x *SetPnd) Reset()
- func (x *SetPnd) String() string
- type SetRequest
- type SetResponse
- func (*SetResponse) Descriptor() ([]byte, []int)deprecated
- func (x *SetResponse) GetStatus() SetResponseStatus
- func (x *SetResponse) GetTimestamp() int64
- func (*SetResponse) ProtoMessage()
- func (x *SetResponse) ProtoReflect() protoreflect.Message
- func (x *SetResponse) Reset()
- func (x *SetResponse) String() string
- type SetResponseStatus
- func (SetResponseStatus) Descriptor() protoreflect.EnumDescriptor
- func (x SetResponseStatus) Enum() *SetResponseStatus
- func (SetResponseStatus) EnumDescriptor() ([]byte, []int)deprecated
- func (x SetResponseStatus) Number() protoreflect.EnumNumber
- func (x SetResponseStatus) String() string
- func (SetResponseStatus) Type() protoreflect.EnumType
- type UnimplementedCoreServer
Constants ¶
This section is empty.
Variables ¶
var ( SetResponseStatus_name = map[int32]string{ 0: "OK", 1: "ERROR", } SetResponseStatus_value = map[string]int32{ "OK": 0, "ERROR": 1, } )
Enum value maps for SetResponseStatus.
var File_gosdn_core_core_proto protoreflect.FileDescriptor
Functions ¶
func RegisterCoreServer ¶
func RegisterCoreServer(s *grpc.Server, srv CoreServer)
Types ¶
type CoreClient ¶
type CoreClient interface { Get(ctx context.Context, in *GetRequest, opts ...grpc.CallOption) (*GetResponse, error) Set(ctx context.Context, in *SetRequest, opts ...grpc.CallOption) (*SetResponse, error) }
CoreClient is the client API for Core 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 NewCoreClient ¶
func NewCoreClient(cc grpc.ClientConnInterface) CoreClient
type CoreServer ¶
type CoreServer interface { Get(context.Context, *GetRequest) (*GetResponse, error) Set(context.Context, *SetRequest) (*SetResponse, error) // contains filtered or unexported methods }
CoreServer is the server API for Core service. All implementations must embed UnimplementedCoreServer for forward compatibility
type GetRequest ¶
type GetRequest struct { Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. All bool `protobuf:"varint,2,opt,name=all,proto3" json:"all,omitempty"` Pid []string `protobuf:"bytes,3,rep,name=pid,proto3" json:"pid,omitempty"` // contains filtered or unexported fields }
func (*GetRequest) Descriptor
deprecated
func (*GetRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetRequest.ProtoReflect.Descriptor instead.
func (*GetRequest) GetAll ¶
func (x *GetRequest) GetAll() bool
func (*GetRequest) GetPid ¶
func (x *GetRequest) GetPid() []string
func (*GetRequest) GetTimestamp ¶
func (x *GetRequest) GetTimestamp() int64
func (*GetRequest) ProtoMessage ¶
func (*GetRequest) ProtoMessage()
func (*GetRequest) ProtoReflect ¶
func (x *GetRequest) ProtoReflect() protoreflect.Message
func (*GetRequest) Reset ¶
func (x *GetRequest) Reset()
func (*GetRequest) String ¶
func (x *GetRequest) String() string
type GetResponse ¶
type GetResponse struct { Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. Pnd []*pnd.PrincipalNetworkDomain `protobuf:"bytes,2,rep,name=pnd,proto3" json:"pnd,omitempty"` // contains filtered or unexported fields }
func (*GetResponse) Descriptor
deprecated
func (*GetResponse) Descriptor() ([]byte, []int)
Deprecated: Use GetResponse.ProtoReflect.Descriptor instead.
func (*GetResponse) GetPnd ¶
func (x *GetResponse) GetPnd() []*pnd.PrincipalNetworkDomain
func (*GetResponse) GetTimestamp ¶
func (x *GetResponse) GetTimestamp() int64
func (*GetResponse) ProtoMessage ¶
func (*GetResponse) ProtoMessage()
func (*GetResponse) ProtoReflect ¶
func (x *GetResponse) ProtoReflect() protoreflect.Message
func (*GetResponse) Reset ¶
func (x *GetResponse) Reset()
func (*GetResponse) String ¶
func (x *GetResponse) String() string
type SetPnd ¶
type SetPnd struct { Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"` Description string `protobuf:"bytes,2,opt,name=description,proto3" json:"description,omitempty"` Sbi string `protobuf:"bytes,3,opt,name=sbi,proto3" json:"sbi,omitempty"` // contains filtered or unexported fields }
func (*SetPnd) Descriptor
deprecated
func (*SetPnd) GetDescription ¶
func (*SetPnd) ProtoMessage ¶
func (*SetPnd) ProtoMessage()
func (*SetPnd) ProtoReflect ¶
func (x *SetPnd) ProtoReflect() protoreflect.Message
type SetRequest ¶
type SetRequest struct { Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. Pnd []*SetPnd `protobuf:"bytes,2,rep,name=pnd,proto3" json:"pnd,omitempty"` // contains filtered or unexported fields }
func (*SetRequest) Descriptor
deprecated
func (*SetRequest) Descriptor() ([]byte, []int)
Deprecated: Use SetRequest.ProtoReflect.Descriptor instead.
func (*SetRequest) GetPnd ¶
func (x *SetRequest) GetPnd() []*SetPnd
func (*SetRequest) GetTimestamp ¶
func (x *SetRequest) GetTimestamp() int64
func (*SetRequest) ProtoMessage ¶
func (*SetRequest) ProtoMessage()
func (*SetRequest) ProtoReflect ¶
func (x *SetRequest) ProtoReflect() protoreflect.Message
func (*SetRequest) Reset ¶
func (x *SetRequest) Reset()
func (*SetRequest) String ¶
func (x *SetRequest) String() string
type SetResponse ¶
type SetResponse struct { Timestamp int64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp in nanoseconds since Epoch. Status SetResponseStatus `protobuf:"varint,2,opt,name=Status,proto3,enum=gosdn.core.SetResponseStatus" json:"Status,omitempty"` // contains filtered or unexported fields }
func (*SetResponse) Descriptor
deprecated
func (*SetResponse) Descriptor() ([]byte, []int)
Deprecated: Use SetResponse.ProtoReflect.Descriptor instead.
func (*SetResponse) GetStatus ¶
func (x *SetResponse) GetStatus() SetResponseStatus
func (*SetResponse) GetTimestamp ¶
func (x *SetResponse) GetTimestamp() int64
func (*SetResponse) ProtoMessage ¶
func (*SetResponse) ProtoMessage()
func (*SetResponse) ProtoReflect ¶
func (x *SetResponse) ProtoReflect() protoreflect.Message
func (*SetResponse) Reset ¶
func (x *SetResponse) Reset()
func (*SetResponse) String ¶
func (x *SetResponse) String() string
type SetResponseStatus ¶
type SetResponseStatus int32
const ( SetResponse_OK SetResponseStatus = 0 SetResponse_ERROR SetResponseStatus = 1 )
func (SetResponseStatus) Descriptor ¶
func (SetResponseStatus) Descriptor() protoreflect.EnumDescriptor
func (SetResponseStatus) Enum ¶
func (x SetResponseStatus) Enum() *SetResponseStatus
func (SetResponseStatus) EnumDescriptor
deprecated
func (SetResponseStatus) EnumDescriptor() ([]byte, []int)
Deprecated: Use SetResponseStatus.Descriptor instead.
func (SetResponseStatus) Number ¶
func (x SetResponseStatus) Number() protoreflect.EnumNumber
func (SetResponseStatus) String ¶
func (x SetResponseStatus) String() string
func (SetResponseStatus) Type ¶
func (SetResponseStatus) Type() protoreflect.EnumType
type UnimplementedCoreServer ¶
type UnimplementedCoreServer struct { }
UnimplementedCoreServer must be embedded to have forward compatible implementations.
func (*UnimplementedCoreServer) Get ¶
func (*UnimplementedCoreServer) Get(context.Context, *GetRequest) (*GetResponse, error)
func (*UnimplementedCoreServer) Set ¶
func (*UnimplementedCoreServer) Set(context.Context, *SetRequest) (*SetResponse, error)