examplepb

package
v0.0.0-...-8cd8f4d Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package examplepb serves as an example protobuf library which is structured similarly to how other protobuf libraries in this repo are structured, with the addition of a generated .lua file output.

Index

Constants

This section is empty.

Variables

View Source
var (
	VALUE_name = map[int32]string{
		0: "ZERO",
		1: "ONE",
		2: "TWO",
	}
	VALUE_value = map[string]int32{
		"ZERO": 0,
		"ONE":  1,
		"TWO":  2,
	}
)

Enum value maps for VALUE.

View Source
var File_go_chromium_org_luci_common_proto_msgpackpb_luagen_examplepb_msg_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type TestMessage

type TestMessage struct {
	Boolval        bool                    `protobuf:"varint,2,opt,name=boolval,proto3" json:"boolval,omitempty"`
	Intval         int64                   `protobuf:"varint,3,opt,name=intval,proto3" json:"intval,omitempty"`
	Uintval        uint64                  `protobuf:"varint,4,opt,name=uintval,proto3" json:"uintval,omitempty"`
	ShortIntval    int32                   `protobuf:"varint,5,opt,name=short_intval,json=shortIntval,proto3" json:"short_intval,omitempty"`
	ShortUintval   uint32                  `protobuf:"varint,6,opt,name=short_uintval,json=shortUintval,proto3" json:"short_uintval,omitempty"`
	Strval         string                  `protobuf:"bytes,7,opt,name=strval,proto3" json:"strval,omitempty"`
	Floatval       float64                 `protobuf:"fixed64,8,opt,name=floatval,proto3" json:"floatval,omitempty"`
	ShortFloatval  float32                 `protobuf:"fixed32,9,opt,name=short_floatval,json=shortFloatval,proto3" json:"short_floatval,omitempty"`
	Value          VALUE                   `` /* 137-byte string literal not displayed */
	Mapfield       map[string]*TestMessage `` /* 158-byte string literal not displayed */
	Duration       *durationpb.Duration    `protobuf:"bytes,12,opt,name=duration,proto3" json:"duration,omitempty"`
	Strings        []string                `protobuf:"bytes,13,rep,name=strings,proto3" json:"strings,omitempty"`
	SingleRecurse  *TestMessage            `protobuf:"bytes,14,opt,name=single_recurse,json=singleRecurse,proto3" json:"single_recurse,omitempty"`
	MultiRecursion []*TestMessage          `protobuf:"bytes,15,rep,name=multi_recursion,json=multiRecursion,proto3" json:"multi_recursion,omitempty"`
	// contains filtered or unexported fields
}

func (*TestMessage) Descriptor deprecated

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

Deprecated: Use TestMessage.ProtoReflect.Descriptor instead.

func (*TestMessage) GetBoolval

func (x *TestMessage) GetBoolval() bool

func (*TestMessage) GetDuration

func (x *TestMessage) GetDuration() *durationpb.Duration

func (*TestMessage) GetFloatval

func (x *TestMessage) GetFloatval() float64

func (*TestMessage) GetIntval

func (x *TestMessage) GetIntval() int64

func (*TestMessage) GetMapfield

func (x *TestMessage) GetMapfield() map[string]*TestMessage

func (*TestMessage) GetMultiRecursion

func (x *TestMessage) GetMultiRecursion() []*TestMessage

func (*TestMessage) GetShortFloatval

func (x *TestMessage) GetShortFloatval() float32

func (*TestMessage) GetShortIntval

func (x *TestMessage) GetShortIntval() int32

func (*TestMessage) GetShortUintval

func (x *TestMessage) GetShortUintval() uint32

func (*TestMessage) GetSingleRecurse

func (x *TestMessage) GetSingleRecurse() *TestMessage

func (*TestMessage) GetStrings

func (x *TestMessage) GetStrings() []string

func (*TestMessage) GetStrval

func (x *TestMessage) GetStrval() string

func (*TestMessage) GetUintval

func (x *TestMessage) GetUintval() uint64

func (*TestMessage) GetValue

func (x *TestMessage) GetValue() VALUE

func (*TestMessage) ProtoMessage

func (*TestMessage) ProtoMessage()

func (*TestMessage) ProtoReflect

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

func (*TestMessage) Reset

func (x *TestMessage) Reset()

func (*TestMessage) String

func (x *TestMessage) String() string

type VALUE

type VALUE int32
const (
	VALUE_ZERO VALUE = 0
	VALUE_ONE  VALUE = 1
	VALUE_TWO  VALUE = 2
)

func (VALUE) Descriptor

func (VALUE) Descriptor() protoreflect.EnumDescriptor

func (VALUE) Enum

func (x VALUE) Enum() *VALUE

func (VALUE) EnumDescriptor deprecated

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

Deprecated: Use VALUE.Descriptor instead.

func (VALUE) Number

func (x VALUE) Number() protoreflect.EnumNumber

func (VALUE) String

func (x VALUE) String() string

func (VALUE) Type

func (VALUE) Type() protoreflect.EnumType

Jump to

Keyboard shortcuts

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