control

package
v0.0.3 Latest Latest
Warning

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

Go to latest
Published: Jan 20, 2020 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package control is a generated protocol buffer package.

It is generated from these files:

control.proto

It has these top-level messages:

Item
Chunk
Update
Response
Empty

Index

Constants

This section is empty.

Variables

View Source
var Item_DataType_name = map[int32]string{
	0: "POLICIES",
	1: "CONTENT",
}
View Source
var Item_DataType_value = map[string]int32{
	"POLICIES": 0,
	"CONTENT":  1,
}
View Source
var Response_Status_name = map[int32]string{
	0: "ACK",
	1: "ERROR",
	2: "TAG_ERROR",
}
View Source
var Response_Status_value = map[string]int32{
	"ACK":       0,
	"ERROR":     1,
	"TAG_ERROR": 2,
}

Functions

func RegisterPDPControlServer

func RegisterPDPControlServer(s *grpc.Server, srv PDPControlServer)

Types

type Chunk

type Chunk struct {
	Id   int32  `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	Data string `protobuf:"bytes,2,opt,name=data" json:"data,omitempty"`
}

func (*Chunk) Descriptor

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

func (*Chunk) GetData

func (m *Chunk) GetData() string

func (*Chunk) GetId

func (m *Chunk) GetId() int32

func (*Chunk) ProtoMessage

func (*Chunk) ProtoMessage()

func (*Chunk) Reset

func (m *Chunk) Reset()

func (*Chunk) String

func (m *Chunk) String() string

type Empty

type Empty struct {
}

func (*Empty) Descriptor

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

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) Reset

func (m *Empty) Reset()

func (*Empty) String

func (m *Empty) String() string

type Item

type Item struct {
	Type    Item_DataType `protobuf:"varint,1,opt,name=type,enum=control.Item_DataType" json:"type,omitempty"`
	FromTag string        `protobuf:"bytes,2,opt,name=fromTag" json:"fromTag,omitempty"`
	ToTag   string        `protobuf:"bytes,3,opt,name=toTag" json:"toTag,omitempty"`
	Id      string        `protobuf:"bytes,4,opt,name=id" json:"id,omitempty"`
}

func (*Item) Descriptor

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

func (*Item) GetFromTag

func (m *Item) GetFromTag() string

func (*Item) GetId

func (m *Item) GetId() string

func (*Item) GetToTag

func (m *Item) GetToTag() string

func (*Item) GetType

func (m *Item) GetType() Item_DataType

func (*Item) ProtoMessage

func (*Item) ProtoMessage()

func (*Item) Reset

func (m *Item) Reset()

func (*Item) String

func (m *Item) String() string

type Item_DataType

type Item_DataType int32
const (
	Item_POLICIES Item_DataType = 0
	Item_CONTENT  Item_DataType = 1
)

func (Item_DataType) EnumDescriptor

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

func (Item_DataType) String

func (x Item_DataType) String() string

type PDPControlClient

type PDPControlClient interface {
	Request(ctx context.Context, in *Item, opts ...grpc.CallOption) (*Response, error)
	Upload(ctx context.Context, opts ...grpc.CallOption) (PDPControl_UploadClient, error)
	Apply(ctx context.Context, in *Update, opts ...grpc.CallOption) (*Response, error)
	NotifyReady(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Response, error)
}

func NewPDPControlClient

func NewPDPControlClient(cc *grpc.ClientConn) PDPControlClient

type PDPControlServer

type PDPControlServer interface {
	Request(context.Context, *Item) (*Response, error)
	Upload(PDPControl_UploadServer) error
	Apply(context.Context, *Update) (*Response, error)
	NotifyReady(context.Context, *Empty) (*Response, error)
}

type PDPControl_UploadClient

type PDPControl_UploadClient interface {
	Send(*Chunk) error
	CloseAndRecv() (*Response, error)
	grpc.ClientStream
}

type PDPControl_UploadServer

type PDPControl_UploadServer interface {
	SendAndClose(*Response) error
	Recv() (*Chunk, error)
	grpc.ServerStream
}

type Response

type Response struct {
	Status  Response_Status `protobuf:"varint,1,opt,name=status,enum=control.Response_Status" json:"status,omitempty"`
	Id      int32           `protobuf:"varint,2,opt,name=id" json:"id,omitempty"`
	Details string          `protobuf:"bytes,3,opt,name=details" json:"details,omitempty"`
}

func (*Response) Descriptor

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

func (*Response) GetDetails

func (m *Response) GetDetails() string

func (*Response) GetId

func (m *Response) GetId() int32

func (*Response) GetStatus

func (m *Response) GetStatus() Response_Status

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) Reset

func (m *Response) Reset()

func (*Response) String

func (m *Response) String() string

type Response_Status

type Response_Status int32
const (
	Response_ACK       Response_Status = 0
	Response_ERROR     Response_Status = 1
	Response_TAG_ERROR Response_Status = 2
)

func (Response_Status) EnumDescriptor

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

func (Response_Status) String

func (x Response_Status) String() string

type Update

type Update struct {
	Id int32 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
}

func (*Update) Descriptor

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

func (*Update) GetId

func (m *Update) GetId() int32

func (*Update) ProtoMessage

func (*Update) ProtoMessage()

func (*Update) Reset

func (m *Update) Reset()

func (*Update) String

func (m *Update) String() string

Jump to

Keyboard shortcuts

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