representation

package
v0.11.2-rc2 Latest Latest
Warning

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

Go to latest
Published: Sep 13, 2023 License: Apache-2.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TopologyRepresentation_GetGraph_FullMethodName    = "/representation.TopologyRepresentation/GetGraph"
	TopologyRepresentation_RenderGraph_FullMethodName = "/representation.TopologyRepresentation/RenderGraph"
)

Variables

View Source
var (
	GraphRepr_name = map[int32]string{
		0: "None",
		1: "KubectlGraph",
	}
	GraphRepr_value = map[string]int32{
		"None":         0,
		"KubectlGraph": 1,
	}
)

Enum value maps for GraphRepr.

View Source
var File_github_com_rancher_opni_plugins_topology_apis_representation_representation_proto protoreflect.FileDescriptor
View Source
var TopologyRepresentation_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "representation.TopologyRepresentation",
	HandlerType: (*TopologyRepresentationServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetGraph",
			Handler:    _TopologyRepresentation_GetGraph_Handler,
		},
		{
			MethodName: "RenderGraph",
			Handler:    _TopologyRepresentation_RenderGraph_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "github.com/rancher/opni/plugins/topology/apis/representation/representation.proto",
}

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

Functions

func RegisterTopologyRepresentationServer

func RegisterTopologyRepresentationServer(s grpc.ServiceRegistrar, srv TopologyRepresentationServer)

Types

type DOTRepresentation

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

func (*DOTRepresentation) Descriptor deprecated

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

Deprecated: Use DOTRepresentation.ProtoReflect.Descriptor instead.

func (*DOTRepresentation) GetRawDotFormat

func (x *DOTRepresentation) GetRawDotFormat() string

func (*DOTRepresentation) ProtoMessage

func (*DOTRepresentation) ProtoMessage()

func (*DOTRepresentation) ProtoReflect

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

func (*DOTRepresentation) Reset

func (x *DOTRepresentation) Reset()

func (*DOTRepresentation) String

func (x *DOTRepresentation) String() string

type GraphRepr

type GraphRepr int32
const (
	GraphRepr_None         GraphRepr = 0
	GraphRepr_KubectlGraph GraphRepr = 1
)

func (GraphRepr) Descriptor

func (GraphRepr) Descriptor() protoreflect.EnumDescriptor

func (GraphRepr) Enum

func (x GraphRepr) Enum() *GraphRepr

func (GraphRepr) EnumDescriptor deprecated

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

Deprecated: Use GraphRepr.Descriptor instead.

func (GraphRepr) Number

func (x GraphRepr) Number() protoreflect.EnumNumber

func (GraphRepr) String

func (x GraphRepr) String() string

func (GraphRepr) Type

type TopologyGraph

type TopologyGraph struct {
	Id   *v1.Reference `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	Data []byte        `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
	Repr GraphRepr     `protobuf:"varint,3,opt,name=repr,proto3,enum=representation.GraphRepr" json:"repr,omitempty"`
	// contains filtered or unexported fields
}

func (*TopologyGraph) Descriptor deprecated

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

Deprecated: Use TopologyGraph.ProtoReflect.Descriptor instead.

func (*TopologyGraph) GetData

func (x *TopologyGraph) GetData() []byte

func (*TopologyGraph) GetId

func (x *TopologyGraph) GetId() *v1.Reference

func (*TopologyGraph) GetRepr

func (x *TopologyGraph) GetRepr() GraphRepr

func (*TopologyGraph) ProtoMessage

func (*TopologyGraph) ProtoMessage()

func (*TopologyGraph) ProtoReflect

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

func (*TopologyGraph) Reset

func (x *TopologyGraph) Reset()

func (*TopologyGraph) String

func (x *TopologyGraph) String() string

type TopologyRepresentationClient

type TopologyRepresentationClient interface {
	// opni internal use
	GetGraph(ctx context.Context, in *v1.Reference, opts ...grpc.CallOption) (*TopologyGraph, error)
	// cluster id  --> kubernetes graph SVG
	RenderGraph(ctx context.Context, in *v1.Reference, opts ...grpc.CallOption) (*DOTRepresentation, error)
}

TopologyRepresentationClient is the client API for TopologyRepresentation 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.

type TopologyRepresentationServer

type TopologyRepresentationServer interface {
	// opni internal use
	GetGraph(context.Context, *v1.Reference) (*TopologyGraph, error)
	// cluster id  --> kubernetes graph SVG
	RenderGraph(context.Context, *v1.Reference) (*DOTRepresentation, error)
	// contains filtered or unexported methods
}

TopologyRepresentationServer is the server API for TopologyRepresentation service. All implementations must embed UnimplementedTopologyRepresentationServer for forward compatibility

type UnimplementedTopologyRepresentationServer

type UnimplementedTopologyRepresentationServer struct {
}

UnimplementedTopologyRepresentationServer must be embedded to have forward compatible implementations.

func (UnimplementedTopologyRepresentationServer) GetGraph

func (UnimplementedTopologyRepresentationServer) RenderGraph

type UnsafeTopologyRepresentationServer

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

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

Jump to

Keyboard shortcuts

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