l1s_pb

package
v0.0.0-...-bdfb71f Latest Latest
Warning

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

Go to latest
Published: Jul 30, 2024 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	Config_Operation_Enum_name = map[int32]string{
		0: "unspecified",
		1: "CREATE",
		2: "DELETE",
	}
	Config_Operation_Enum_value = map[string]int32{
		"unspecified": 0,
		"CREATE":      1,
		"DELETE":      2,
	}
)

Enum value maps for Config_Operation_Enum.

View Source
var (
	Link_Mode_Enum_name = map[int32]string{
		0: "unspecified",
		1: "unidirectional",
		2: "bidirectional",
	}
	Link_Mode_Enum_value = map[string]int32{
		"unspecified":    0,
		"unidirectional": 1,
		"bidirectional":  2,
	}
)

Enum value maps for Link_Mode_Enum.

View Source
var (
	Error_Kind_Enum_name = map[int32]string{
		0: "unspecified",
		1: "validation",
		2: "internal",
	}
	Error_Kind_Enum_value = map[string]int32{
		"unspecified": 0,
		"validation":  1,
		"internal":    2,
	}
)

Enum value maps for Error_Kind_Enum.

View Source
var File_l1s_pb_proto protoreflect.FileDescriptor
View Source
var Openapi_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "l1s_pb.Openapi",
	HandlerType: (*OpenapiServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "SetConfig",
			Handler:    _Openapi_SetConfig_Handler,
		},
		{
			MethodName: "GetVersion",
			Handler:    _Openapi_GetVersion_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "l1s_pb.proto",
}

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

Functions

func RegisterOpenapiServer

func RegisterOpenapiServer(s grpc.ServiceRegistrar, srv OpenapiServer)

Types

type Config

type Config struct {

	// Connection between ports within a switch.
	Links []*Link `protobuf:"bytes,1,rep,name=links,proto3" json:"links,omitempty"`
	// Operation to Create or Delete Links
	// default = Operation.Enum.create
	Operation *Config_Operation_Enum `protobuf:"varint,2,opt,name=operation,proto3,enum=l1s_pb.Config_Operation_Enum,oneof" json:"operation,omitempty"`
	// contains filtered or unexported fields
}

A container for L1S configuration.

func (*Config) Descriptor deprecated

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

Deprecated: Use Config.ProtoReflect.Descriptor instead.

func (x *Config) GetLinks() []*Link

func (*Config) GetOperation

func (x *Config) GetOperation() Config_Operation_Enum

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 Config_Operation

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

func (*Config_Operation) Descriptor deprecated

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

Deprecated: Use Config_Operation.ProtoReflect.Descriptor instead.

func (*Config_Operation) ProtoMessage

func (*Config_Operation) ProtoMessage()

func (*Config_Operation) ProtoReflect

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

func (*Config_Operation) Reset

func (x *Config_Operation) Reset()

func (*Config_Operation) String

func (x *Config_Operation) String() string

type Config_Operation_Enum

type Config_Operation_Enum int32
const (
	Config_Operation_unspecified Config_Operation_Enum = 0
	Config_Operation_CREATE      Config_Operation_Enum = 1
	Config_Operation_DELETE      Config_Operation_Enum = 2
)

func (Config_Operation_Enum) Descriptor

func (Config_Operation_Enum) Enum

func (Config_Operation_Enum) EnumDescriptor deprecated

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

Deprecated: Use Config_Operation_Enum.Descriptor instead.

func (Config_Operation_Enum) Number

func (Config_Operation_Enum) String

func (x Config_Operation_Enum) String() string

func (Config_Operation_Enum) Type

type Error

type Error struct {

	// Numeric status code based on the underlying transport being used.
	// The API server MUST set this code explicitly based on following references:
	// - HTTP 4xx errors: https://datatracker.ietf.org/doc/html/rfc9110#section-15.5
	// - HTTP 5xx errors: https://datatracker.ietf.org/doc/html/rfc9110#section-15.6
	// - gRPC errors: https://grpc.github.io/grpc/core/md_doc_statuscodes.html
	// required = true
	Code *int32 `protobuf:"varint,1,opt,name=code,proto3,oneof" json:"code,omitempty"`
	// Classification of error originating from within API server that may not be mapped
	// to the value in `code`.
	// Absence of this field may indicate that the error did not originate from within API
	// server.
	Kind *Error_Kind_Enum `protobuf:"varint,2,opt,name=kind,proto3,enum=l1s_pb.Error_Kind_Enum,oneof" json:"kind,omitempty"`
	// List of error messages generated while executing the request.
	Errors []string `protobuf:"bytes,3,rep,name=errors,proto3" json:"errors,omitempty"`
	// contains filtered or unexported fields
}

Error response generated while serving API request.

func (*Error) Descriptor deprecated

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

Deprecated: Use Error.ProtoReflect.Descriptor instead.

func (*Error) GetCode

func (x *Error) GetCode() int32

func (*Error) GetErrors

func (x *Error) GetErrors() []string

func (*Error) GetKind

func (x *Error) GetKind() Error_Kind_Enum

func (*Error) ProtoMessage

func (*Error) ProtoMessage()

func (*Error) ProtoReflect

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

func (*Error) Reset

func (x *Error) Reset()

func (*Error) String

func (x *Error) String() string

type Error_Kind

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

func (*Error_Kind) Descriptor deprecated

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

Deprecated: Use Error_Kind.ProtoReflect.Descriptor instead.

func (*Error_Kind) ProtoMessage

func (*Error_Kind) ProtoMessage()

func (*Error_Kind) ProtoReflect

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

func (*Error_Kind) Reset

func (x *Error_Kind) Reset()

func (*Error_Kind) String

func (x *Error_Kind) String() string

type Error_Kind_Enum

type Error_Kind_Enum int32
const (
	Error_Kind_unspecified Error_Kind_Enum = 0
	Error_Kind_validation  Error_Kind_Enum = 1
	Error_Kind_internal    Error_Kind_Enum = 2
)

func (Error_Kind_Enum) Descriptor

func (Error_Kind_Enum) Enum

func (x Error_Kind_Enum) Enum() *Error_Kind_Enum

func (Error_Kind_Enum) EnumDescriptor deprecated

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

Deprecated: Use Error_Kind_Enum.Descriptor instead.

func (Error_Kind_Enum) Number

func (Error_Kind_Enum) String

func (x Error_Kind_Enum) String() string

func (Error_Kind_Enum) Type

type Failure

type Failure struct {
	Error *Error `protobuf:"bytes,1,opt,name=error,proto3" json:"error,omitempty"`
	// contains filtered or unexported fields
}

The request did not succeed and server has responded with error details.

func (*Failure) Descriptor deprecated

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

Deprecated: Use Failure.ProtoReflect.Descriptor instead.

func (*Failure) GetError

func (x *Failure) GetError() *Error

func (*Failure) ProtoMessage

func (*Failure) ProtoMessage()

func (*Failure) ProtoReflect

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

func (*Failure) Reset

func (x *Failure) Reset()

func (*Failure) String

func (x *Failure) String() string

type GetVersionResponse

type GetVersionResponse struct {
	Version *Version `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
	// contains filtered or unexported fields
}

func (*GetVersionResponse) Descriptor deprecated

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

Deprecated: Use GetVersionResponse.ProtoReflect.Descriptor instead.

func (*GetVersionResponse) GetVersion

func (x *GetVersionResponse) GetVersion() *Version

func (*GetVersionResponse) ProtoMessage

func (*GetVersionResponse) ProtoMessage()

func (*GetVersionResponse) ProtoReflect

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

func (*GetVersionResponse) Reset

func (x *GetVersionResponse) Reset()

func (*GetVersionResponse) String

func (x *GetVersionResponse) String() string
type Link struct {

	// Src for the link.
	// required = true
	Src *string `protobuf:"bytes,1,opt,name=src,proto3,oneof" json:"src,omitempty"`
	// Dst of the link.
	// required = true
	Dst *string `protobuf:"bytes,2,opt,name=dst,proto3,oneof" json:"dst,omitempty"`
	// Description missing in models
	// default = Mode.Enum.bidirectional
	Mode *Link_Mode_Enum `protobuf:"varint,3,opt,name=mode,proto3,enum=l1s_pb.Link_Mode_Enum,oneof" json:"mode,omitempty"`
	// contains filtered or unexported fields
}

Link between the Ports.

func (*Link) Descriptor deprecated

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

Deprecated: Use Link.ProtoReflect.Descriptor instead.

func (*Link) GetDst

func (x *Link) GetDst() string

func (*Link) GetMode

func (x *Link) GetMode() Link_Mode_Enum

func (*Link) GetSrc

func (x *Link) GetSrc() string

func (*Link) ProtoMessage

func (*Link) ProtoMessage()

func (*Link) ProtoReflect

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

func (*Link) Reset

func (x *Link) Reset()

func (*Link) String

func (x *Link) String() string
type Link_Mode struct {
	// contains filtered or unexported fields
}
func (*Link_Mode) Descriptor() ([]byte, []int)

Deprecated: Use Link_Mode.ProtoReflect.Descriptor instead.

func (*Link_Mode) ProtoMessage()
func (x *Link_Mode) ProtoReflect() protoreflect.Message
func (x *Link_Mode) Reset()
func (x *Link_Mode) String() string
type Link_Mode_Enum int32
const (
	Link_Mode_unspecified    Link_Mode_Enum = 0
	Link_Mode_unidirectional Link_Mode_Enum = 1
	Link_Mode_bidirectional  Link_Mode_Enum = 2
)
func (x Link_Mode_Enum) Enum() *Link_Mode_Enum
func (Link_Mode_Enum) EnumDescriptor() ([]byte, []int)

Deprecated: Use Link_Mode_Enum.Descriptor instead.

func (x Link_Mode_Enum) String() string

type OpenapiClient

type OpenapiClient interface {
	// Create configuration for L1S
	SetConfig(ctx context.Context, in *SetConfigRequest, opts ...grpc.CallOption) (*SetConfigResponse, error)
	// Description missing in models
	GetVersion(ctx context.Context, in *emptypb.Empty, opts ...grpc.CallOption) (*GetVersionResponse, error)
}

OpenapiClient is the client API for Openapi 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 NewOpenapiClient

func NewOpenapiClient(cc grpc.ClientConnInterface) OpenapiClient

type OpenapiServer

type OpenapiServer interface {
	// Create configuration for L1S
	SetConfig(context.Context, *SetConfigRequest) (*SetConfigResponse, error)
	// Description missing in models
	GetVersion(context.Context, *emptypb.Empty) (*GetVersionResponse, error)
	// contains filtered or unexported methods
}

OpenapiServer is the server API for Openapi service. All implementations must embed UnimplementedOpenapiServer for forward compatibility

type SetConfigRequest

type SetConfigRequest struct {
	Config *Config `protobuf:"bytes,1,opt,name=config,proto3" json:"config,omitempty"`
	// contains filtered or unexported fields
}

func (*SetConfigRequest) Descriptor deprecated

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

Deprecated: Use SetConfigRequest.ProtoReflect.Descriptor instead.

func (*SetConfigRequest) GetConfig

func (x *SetConfigRequest) GetConfig() *Config

func (*SetConfigRequest) ProtoMessage

func (*SetConfigRequest) ProtoMessage()

func (*SetConfigRequest) ProtoReflect

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

func (*SetConfigRequest) Reset

func (x *SetConfigRequest) Reset()

func (*SetConfigRequest) String

func (x *SetConfigRequest) String() string

type SetConfigResponse

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

func (*SetConfigResponse) Descriptor deprecated

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

Deprecated: Use SetConfigResponse.ProtoReflect.Descriptor instead.

func (*SetConfigResponse) GetString_

func (x *SetConfigResponse) GetString_() string

func (*SetConfigResponse) ProtoMessage

func (*SetConfigResponse) ProtoMessage()

func (*SetConfigResponse) ProtoReflect

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

func (*SetConfigResponse) Reset

func (x *SetConfigResponse) Reset()

func (*SetConfigResponse) String

func (x *SetConfigResponse) String() string

type Success

type Success struct {
	Warning *Warning `protobuf:"bytes,1,opt,name=warning,proto3" json:"warning,omitempty"`
	// contains filtered or unexported fields
}

The request has succeeded with no application content but the server may return a list of detailed warnings.

func (*Success) Descriptor deprecated

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

Deprecated: Use Success.ProtoReflect.Descriptor instead.

func (*Success) GetWarning

func (x *Success) GetWarning() *Warning

func (*Success) ProtoMessage

func (*Success) ProtoMessage()

func (*Success) ProtoReflect

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

func (*Success) Reset

func (x *Success) Reset()

func (*Success) String

func (x *Success) String() string

type UnimplementedOpenapiServer

type UnimplementedOpenapiServer struct {
}

UnimplementedOpenapiServer must be embedded to have forward compatible implementations.

func (UnimplementedOpenapiServer) GetVersion

func (UnimplementedOpenapiServer) SetConfig

type UnsafeOpenapiServer

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

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

type Version

type Version struct {

	// Version of API specification
	// default =
	ApiSpecVersion *string `protobuf:"bytes,1,opt,name=api_spec_version,json=apiSpecVersion,proto3,oneof" json:"api_spec_version,omitempty"`
	// Version of SDK generated from API specification
	// default =
	SdkVersion *string `protobuf:"bytes,2,opt,name=sdk_version,json=sdkVersion,proto3,oneof" json:"sdk_version,omitempty"`
	// Version of application consuming or serving the API
	// default =
	AppVersion *string `protobuf:"bytes,3,opt,name=app_version,json=appVersion,proto3,oneof" json:"app_version,omitempty"`
	// contains filtered or unexported fields
}

Version details

func (*Version) Descriptor deprecated

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

Deprecated: Use Version.ProtoReflect.Descriptor instead.

func (*Version) GetApiSpecVersion

func (x *Version) GetApiSpecVersion() string

func (*Version) GetAppVersion

func (x *Version) GetAppVersion() string

func (*Version) GetSdkVersion

func (x *Version) GetSdkVersion() string

func (*Version) ProtoMessage

func (*Version) ProtoMessage()

func (*Version) ProtoReflect

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

func (*Version) Reset

func (x *Version) Reset()

func (*Version) String

func (x *Version) String() string

type Warning

type Warning struct {

	// A list of any system specific warnings that have occurred while
	// executing the request.
	Warnings []string `protobuf:"bytes,1,rep,name=warnings,proto3" json:"warnings,omitempty"`
	// contains filtered or unexported fields
}

A list of warnings that have occurred while executing the request.

func (*Warning) Descriptor deprecated

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

Deprecated: Use Warning.ProtoReflect.Descriptor instead.

func (*Warning) GetWarnings

func (x *Warning) GetWarnings() []string

func (*Warning) ProtoMessage

func (*Warning) ProtoMessage()

func (*Warning) ProtoReflect

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

func (*Warning) Reset

func (x *Warning) Reset()

func (*Warning) String

func (x *Warning) String() string

Jump to

Keyboard shortcuts

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