Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found
Select Git revision
  • integration-test
  • master
  • memguard
  • pass-state
  • renovate/git.autistici.org-ai3-go-common-digest
  • renovate/git.autistici.org-id-go-sso-digest
  • renovate/github.com-go-ldap-ldap-v3-3.x
  • renovate/github.com-go-sql-driver-mysql-1.x
  • renovate/github.com-lib-pq-1.x
  • renovate/github.com-mattn-go-sqlite3-1.x
  • renovate/github.com-prometheus-client_golang-1.x
  • renovate/golang.org-x-crypto-0.x
  • renovate/golang.org-x-sync-0.x
13 results

Target

Select target project
  • id/keystore
1 result
Select Git revision
  • integration-test
  • master
  • memguard
  • pass-state
  • renovate/git.autistici.org-ai3-go-common-digest
  • renovate/git.autistici.org-id-go-sso-digest
  • renovate/github.com-go-ldap-ldap-v3-3.x
  • renovate/github.com-go-sql-driver-mysql-1.x
  • renovate/github.com-lib-pq-1.x
  • renovate/github.com-mattn-go-sqlite3-1.x
  • renovate/github.com-prometheus-client_golang-1.x
  • renovate/golang.org-x-crypto-0.x
  • renovate/golang.org-x-sync-0.x
13 results
Show changes
Showing
with 2549 additions and 0 deletions
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: udpa/annotations/sensitive.proto
package udpa_annotations
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
descriptor "github.com/golang/protobuf/protoc-gen-go/descriptor"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
var E_Sensitive = &proto.ExtensionDesc{
ExtendedType: (*descriptor.FieldOptions)(nil),
ExtensionType: (*bool)(nil),
Field: 76569463,
Name: "udpa.annotations.sensitive",
Tag: "varint,76569463,opt,name=sensitive",
Filename: "udpa/annotations/sensitive.proto",
}
func init() {
proto.RegisterExtension(E_Sensitive)
}
func init() { proto.RegisterFile("udpa/annotations/sensitive.proto", fileDescriptor_abbd0dde0408189d) }
var fileDescriptor_abbd0dde0408189d = []byte{
// 134 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x28, 0x4d, 0x29, 0x48,
0xd4, 0x4f, 0xcc, 0xcb, 0xcb, 0x2f, 0x49, 0x2c, 0xc9, 0xcc, 0xcf, 0x2b, 0xd6, 0x2f, 0x4e, 0xcd,
0x2b, 0xce, 0x2c, 0xc9, 0x2c, 0x4b, 0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x00, 0xa9,
0xd0, 0x43, 0x52, 0x21, 0xa5, 0x90, 0x9e, 0x9f, 0x9f, 0x9e, 0x93, 0xaa, 0x0f, 0x96, 0x4f, 0x2a,
0x4d, 0xd3, 0x4f, 0x49, 0x2d, 0x4e, 0x2e, 0xca, 0x2c, 0x28, 0xc9, 0x2f, 0x82, 0xe8, 0xb1, 0xb2,
0xe3, 0xe2, 0x84, 0x1b, 0x23, 0x24, 0xab, 0x07, 0x51, 0xaf, 0x07, 0x53, 0xaf, 0xe7, 0x96, 0x99,
0x9a, 0x93, 0xe2, 0x5f, 0x00, 0x36, 0x4d, 0xe2, 0xfb, 0xb6, 0x83, 0x2a, 0x0a, 0x8c, 0x1a, 0x1c,
0x41, 0x08, 0x2d, 0x49, 0x6c, 0x60, 0xa5, 0xc6, 0x80, 0x00, 0x00, 0x00, 0xff, 0xff, 0x5f, 0xba,
0xeb, 0x73, 0x9e, 0x00, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: udpa/annotations/sensitive.proto
package udpa_annotations
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _sensitive_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: udpa/annotations/status.proto
package udpa_annotations
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
descriptor "github.com/golang/protobuf/protoc-gen-go/descriptor"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type PackageVersionStatus int32
const (
PackageVersionStatus_UNKNOWN PackageVersionStatus = 0
PackageVersionStatus_FROZEN PackageVersionStatus = 1
PackageVersionStatus_ACTIVE PackageVersionStatus = 2
PackageVersionStatus_NEXT_MAJOR_VERSION_CANDIDATE PackageVersionStatus = 3
)
var PackageVersionStatus_name = map[int32]string{
0: "UNKNOWN",
1: "FROZEN",
2: "ACTIVE",
3: "NEXT_MAJOR_VERSION_CANDIDATE",
}
var PackageVersionStatus_value = map[string]int32{
"UNKNOWN": 0,
"FROZEN": 1,
"ACTIVE": 2,
"NEXT_MAJOR_VERSION_CANDIDATE": 3,
}
func (x PackageVersionStatus) String() string {
return proto.EnumName(PackageVersionStatus_name, int32(x))
}
func (PackageVersionStatus) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_011cc2e7e491b0ff, []int{0}
}
type StatusAnnotation struct {
WorkInProgress bool `protobuf:"varint,1,opt,name=work_in_progress,json=workInProgress,proto3" json:"work_in_progress,omitempty"`
PackageVersionStatus PackageVersionStatus `protobuf:"varint,2,opt,name=package_version_status,json=packageVersionStatus,proto3,enum=udpa.annotations.PackageVersionStatus" json:"package_version_status,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *StatusAnnotation) Reset() { *m = StatusAnnotation{} }
func (m *StatusAnnotation) String() string { return proto.CompactTextString(m) }
func (*StatusAnnotation) ProtoMessage() {}
func (*StatusAnnotation) Descriptor() ([]byte, []int) {
return fileDescriptor_011cc2e7e491b0ff, []int{0}
}
func (m *StatusAnnotation) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_StatusAnnotation.Unmarshal(m, b)
}
func (m *StatusAnnotation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_StatusAnnotation.Marshal(b, m, deterministic)
}
func (m *StatusAnnotation) XXX_Merge(src proto.Message) {
xxx_messageInfo_StatusAnnotation.Merge(m, src)
}
func (m *StatusAnnotation) XXX_Size() int {
return xxx_messageInfo_StatusAnnotation.Size(m)
}
func (m *StatusAnnotation) XXX_DiscardUnknown() {
xxx_messageInfo_StatusAnnotation.DiscardUnknown(m)
}
var xxx_messageInfo_StatusAnnotation proto.InternalMessageInfo
func (m *StatusAnnotation) GetWorkInProgress() bool {
if m != nil {
return m.WorkInProgress
}
return false
}
func (m *StatusAnnotation) GetPackageVersionStatus() PackageVersionStatus {
if m != nil {
return m.PackageVersionStatus
}
return PackageVersionStatus_UNKNOWN
}
var E_FileStatus = &proto.ExtensionDesc{
ExtendedType: (*descriptor.FileOptions)(nil),
ExtensionType: (*StatusAnnotation)(nil),
Field: 222707719,
Name: "udpa.annotations.file_status",
Tag: "bytes,222707719,opt,name=file_status",
Filename: "udpa/annotations/status.proto",
}
func init() {
proto.RegisterEnum("udpa.annotations.PackageVersionStatus", PackageVersionStatus_name, PackageVersionStatus_value)
proto.RegisterType((*StatusAnnotation)(nil), "udpa.annotations.StatusAnnotation")
proto.RegisterExtension(E_FileStatus)
}
func init() { proto.RegisterFile("udpa/annotations/status.proto", fileDescriptor_011cc2e7e491b0ff) }
var fileDescriptor_011cc2e7e491b0ff = []byte{
// 305 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x6c, 0x50, 0x4f, 0x4b, 0xc3, 0x30,
0x1c, 0xb5, 0x13, 0xa6, 0x64, 0x30, 0x42, 0x18, 0x32, 0x64, 0x42, 0xd9, 0x41, 0x8a, 0x87, 0x14,
0xe6, 0xcd, 0x5b, 0xd9, 0x3a, 0xa8, 0x62, 0x3a, 0xba, 0x39, 0x45, 0x94, 0xd0, 0x6d, 0x59, 0x89,
0x1b, 0x49, 0x48, 0x32, 0xbd, 0x7a, 0xf3, 0x33, 0xe8, 0xa7, 0x95, 0x36, 0x53, 0x64, 0xee, 0x16,
0xde, 0xbf, 0xbc, 0xdf, 0x03, 0x67, 0x9b, 0x85, 0xca, 0xc3, 0x5c, 0x08, 0x69, 0x73, 0xcb, 0xa5,
0x30, 0xa1, 0xb1, 0xb9, 0xdd, 0x18, 0xac, 0xb4, 0xb4, 0x12, 0xc1, 0x92, 0xc6, 0x7f, 0xe8, 0x53,
0xbf, 0x90, 0xb2, 0x58, 0xb3, 0xb0, 0xe2, 0x67, 0x9b, 0x65, 0xb8, 0x60, 0x66, 0xae, 0xb9, 0xb2,
0x52, 0x3b, 0x4f, 0xf7, 0xcb, 0x03, 0x70, 0x5c, 0x85, 0x44, 0xbf, 0x3e, 0x14, 0x00, 0xf8, 0x26,
0xf5, 0x8a, 0x72, 0x41, 0x95, 0x96, 0x85, 0x66, 0xc6, 0xb4, 0x3d, 0xdf, 0x0b, 0x8e, 0xb3, 0x66,
0x89, 0x27, 0x62, 0xb4, 0x45, 0xd1, 0x13, 0x38, 0x51, 0xf9, 0x7c, 0x95, 0x17, 0x8c, 0xbe, 0x32,
0x6d, 0xb8, 0x14, 0xd4, 0x55, 0x6a, 0xd7, 0x7c, 0x2f, 0x68, 0xf6, 0xce, 0xf1, 0x6e, 0x27, 0x3c,
0x72, 0xfa, 0xa9, 0x93, 0xbb, 0xbf, 0xb3, 0x96, 0xda, 0x83, 0x5e, 0x3c, 0x83, 0xd6, 0x3e, 0x35,
0x6a, 0x80, 0xa3, 0x3b, 0x72, 0x43, 0xd2, 0x7b, 0x02, 0x0f, 0x10, 0x00, 0xf5, 0x61, 0x96, 0x3e,
0xc6, 0x04, 0x7a, 0xe5, 0x3b, 0xea, 0x4f, 0x92, 0x69, 0x0c, 0x6b, 0xc8, 0x07, 0x1d, 0x12, 0x3f,
0x4c, 0xe8, 0x6d, 0x74, 0x9d, 0x66, 0x74, 0x1a, 0x67, 0xe3, 0x24, 0x25, 0xb4, 0x1f, 0x91, 0x41,
0x32, 0x88, 0x26, 0x31, 0x3c, 0xbc, 0x5a, 0x80, 0xc6, 0x92, 0xaf, 0xd9, 0xb6, 0x31, 0xea, 0x60,
0xb7, 0x16, 0xfe, 0x59, 0x0b, 0x0f, 0xf9, 0x9a, 0xa5, 0xaa, 0xaa, 0xdd, 0xfe, 0x78, 0xff, 0x7c,
0xf1, 0xbd, 0xa0, 0xd1, 0xeb, 0xfe, 0x3f, 0x69, 0x77, 0xc0, 0x0c, 0x94, 0xb9, 0x0e, 0x9d, 0xd5,
0xab, 0xb8, 0xcb, 0xef, 0x00, 0x00, 0x00, 0xff, 0xff, 0x58, 0x12, 0xee, 0xf3, 0xbd, 0x01, 0x00,
0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: udpa/annotations/status.proto
package udpa_annotations
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _status_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on StatusAnnotation with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned.
func (m *StatusAnnotation) Validate() error {
if m == nil {
return nil
}
// no validation rules for WorkInProgress
// no validation rules for PackageVersionStatus
return nil
}
// StatusAnnotationValidationError is the validation error returned by
// StatusAnnotation.Validate if the designated constraints aren't met.
type StatusAnnotationValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e StatusAnnotationValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e StatusAnnotationValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e StatusAnnotationValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e StatusAnnotationValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e StatusAnnotationValidationError) ErrorName() string { return "StatusAnnotationValidationError" }
// Error satisfies the builtin error interface
func (e StatusAnnotationValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sStatusAnnotation.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = StatusAnnotationValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = StatusAnnotationValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: udpa/annotations/versioning.proto
package udpa_annotations
import (
fmt "fmt"
proto "github.com/golang/protobuf/proto"
descriptor "github.com/golang/protobuf/protoc-gen-go/descriptor"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type VersioningAnnotation struct {
PreviousMessageType string `protobuf:"bytes,1,opt,name=previous_message_type,json=previousMessageType,proto3" json:"previous_message_type,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *VersioningAnnotation) Reset() { *m = VersioningAnnotation{} }
func (m *VersioningAnnotation) String() string { return proto.CompactTextString(m) }
func (*VersioningAnnotation) ProtoMessage() {}
func (*VersioningAnnotation) Descriptor() ([]byte, []int) {
return fileDescriptor_5bc0544382e16cfc, []int{0}
}
func (m *VersioningAnnotation) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_VersioningAnnotation.Unmarshal(m, b)
}
func (m *VersioningAnnotation) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_VersioningAnnotation.Marshal(b, m, deterministic)
}
func (m *VersioningAnnotation) XXX_Merge(src proto.Message) {
xxx_messageInfo_VersioningAnnotation.Merge(m, src)
}
func (m *VersioningAnnotation) XXX_Size() int {
return xxx_messageInfo_VersioningAnnotation.Size(m)
}
func (m *VersioningAnnotation) XXX_DiscardUnknown() {
xxx_messageInfo_VersioningAnnotation.DiscardUnknown(m)
}
var xxx_messageInfo_VersioningAnnotation proto.InternalMessageInfo
func (m *VersioningAnnotation) GetPreviousMessageType() string {
if m != nil {
return m.PreviousMessageType
}
return ""
}
var E_Versioning = &proto.ExtensionDesc{
ExtendedType: (*descriptor.MessageOptions)(nil),
ExtensionType: (*VersioningAnnotation)(nil),
Field: 7881811,
Name: "udpa.annotations.versioning",
Tag: "bytes,7881811,opt,name=versioning",
Filename: "udpa/annotations/versioning.proto",
}
func init() {
proto.RegisterType((*VersioningAnnotation)(nil), "udpa.annotations.VersioningAnnotation")
proto.RegisterExtension(E_Versioning)
}
func init() { proto.RegisterFile("udpa/annotations/versioning.proto", fileDescriptor_5bc0544382e16cfc) }
var fileDescriptor_5bc0544382e16cfc = []byte{
// 193 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0x2c, 0x4d, 0x29, 0x48,
0xd4, 0x4f, 0xcc, 0xcb, 0xcb, 0x2f, 0x49, 0x2c, 0xc9, 0xcc, 0xcf, 0x2b, 0xd6, 0x2f, 0x4b, 0x2d,
0x2a, 0xce, 0xcc, 0xcf, 0xcb, 0xcc, 0x4b, 0xd7, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x12, 0x00,
0x29, 0xd1, 0x43, 0x52, 0x22, 0xa5, 0x90, 0x9e, 0x9f, 0x9f, 0x9e, 0x93, 0xaa, 0x0f, 0x96, 0x4f,
0x2a, 0x4d, 0xd3, 0x4f, 0x49, 0x2d, 0x4e, 0x2e, 0xca, 0x2c, 0x28, 0xc9, 0x2f, 0x82, 0xe8, 0x51,
0xf2, 0xe2, 0x12, 0x09, 0x83, 0x9b, 0xe3, 0x08, 0xd7, 0x2a, 0x64, 0xc4, 0x25, 0x5a, 0x50, 0x94,
0x5a, 0x96, 0x99, 0x5f, 0x5a, 0x1c, 0x9f, 0x9b, 0x5a, 0x5c, 0x9c, 0x98, 0x9e, 0x1a, 0x5f, 0x52,
0x59, 0x90, 0x2a, 0xc1, 0xa8, 0xc0, 0xa8, 0xc1, 0x19, 0x24, 0x0c, 0x93, 0xf4, 0x85, 0xc8, 0x85,
0x54, 0x16, 0xa4, 0x5a, 0x65, 0x71, 0x71, 0x21, 0xdc, 0x24, 0x24, 0xaf, 0x07, 0xb1, 0x5c, 0x0f,
0x66, 0xb9, 0x1e, 0x54, 0xad, 0x7f, 0x01, 0xd8, 0x71, 0x12, 0x97, 0x3b, 0x1e, 0x32, 0x2b, 0x30,
0x6a, 0x70, 0x1b, 0xa9, 0xe9, 0xa1, 0x3b, 0x5c, 0x0f, 0x9b, 0x9b, 0x82, 0x90, 0x4c, 0x4f, 0x62,
0x03, 0x9b, 0x6a, 0x0c, 0x08, 0x00, 0x00, 0xff, 0xff, 0xc1, 0x9c, 0xb8, 0x85, 0x17, 0x01, 0x00,
0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: udpa/annotations/versioning.proto
package udpa_annotations
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _versioning_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on VersioningAnnotation with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned.
func (m *VersioningAnnotation) Validate() error {
if m == nil {
return nil
}
// no validation rules for PreviousMessageType
return nil
}
// VersioningAnnotationValidationError is the validation error returned by
// VersioningAnnotation.Validate if the designated constraints aren't met.
type VersioningAnnotationValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e VersioningAnnotationValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e VersioningAnnotationValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e VersioningAnnotationValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e VersioningAnnotationValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e VersioningAnnotationValidationError) ErrorName() string {
return "VersioningAnnotationValidationError"
}
// Error satisfies the builtin error interface
func (e VersioningAnnotationValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sVersioningAnnotation.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = VersioningAnnotationValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = VersioningAnnotationValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/authority.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type Authority struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Authority) Reset() { *m = Authority{} }
func (m *Authority) String() string { return proto.CompactTextString(m) }
func (*Authority) ProtoMessage() {}
func (*Authority) Descriptor() ([]byte, []int) {
return fileDescriptor_74635363e1fbb077, []int{0}
}
func (m *Authority) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Authority.Unmarshal(m, b)
}
func (m *Authority) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Authority.Marshal(b, m, deterministic)
}
func (m *Authority) XXX_Merge(src proto.Message) {
xxx_messageInfo_Authority.Merge(m, src)
}
func (m *Authority) XXX_Size() int {
return xxx_messageInfo_Authority.Size(m)
}
func (m *Authority) XXX_DiscardUnknown() {
xxx_messageInfo_Authority.DiscardUnknown(m)
}
var xxx_messageInfo_Authority proto.InternalMessageInfo
func (m *Authority) GetName() string {
if m != nil {
return m.Name
}
return ""
}
func init() {
proto.RegisterType((*Authority)(nil), "xds.core.v3.Authority")
}
func init() { proto.RegisterFile("xds/core/v3/authority.proto", fileDescriptor_74635363e1fbb077) }
var fileDescriptor_74635363e1fbb077 = []byte{
// 179 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xae, 0x48, 0x29, 0xd6,
0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x33, 0xd6, 0x4f, 0x2c, 0x2d, 0xc9, 0xc8, 0x2f, 0xca, 0x2c,
0xa9, 0xd4, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xae, 0x48, 0x29, 0xd6, 0x03, 0x49, 0xea,
0x95, 0x19, 0x4b, 0xc9, 0x96, 0xa6, 0x14, 0x24, 0xea, 0x27, 0xe6, 0xe5, 0xe5, 0x97, 0x24, 0x96,
0x64, 0xe6, 0xe7, 0x15, 0xeb, 0x17, 0x97, 0x24, 0x96, 0x94, 0x16, 0x43, 0xd4, 0x4a, 0x89, 0x97,
0x25, 0xe6, 0x64, 0xa6, 0x24, 0x96, 0xa4, 0xea, 0xc3, 0x18, 0x10, 0x09, 0x25, 0x0d, 0x2e, 0x4e,
0x47, 0x98, 0xb9, 0x42, 0xd2, 0x5c, 0x2c, 0x79, 0x89, 0xb9, 0xa9, 0x12, 0x8c, 0x0a, 0x8c, 0x1a,
0x9c, 0x4e, 0xec, 0xbf, 0x9c, 0x58, 0x8a, 0x98, 0x04, 0x18, 0x83, 0xc0, 0x82, 0x4e, 0x46, 0xbb,
0x1a, 0x4e, 0x5c, 0x64, 0x63, 0xe2, 0x60, 0xe4, 0x12, 0x4b, 0xce, 0xcf, 0xd5, 0x4b, 0xcf, 0x2c,
0xc9, 0x28, 0x4d, 0xd2, 0x43, 0x72, 0x83, 0x13, 0x1f, 0xdc, 0xa4, 0x00, 0x90, 0xd9, 0x01, 0x8c,
0x49, 0x6c, 0x60, 0x4b, 0x8c, 0x01, 0x01, 0x00, 0x00, 0xff, 0xff, 0xdb, 0x3c, 0x00, 0xc0, 0xc8,
0x00, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/authority.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _authority_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on Authority with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned.
func (m *Authority) Validate() error {
if m == nil {
return nil
}
if utf8.RuneCountInString(m.GetName()) < 1 {
return AuthorityValidationError{
field: "Name",
reason: "value length must be at least 1 runes",
}
}
return nil
}
// AuthorityValidationError is the validation error returned by
// Authority.Validate if the designated constraints aren't met.
type AuthorityValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e AuthorityValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e AuthorityValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e AuthorityValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e AuthorityValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e AuthorityValidationError) ErrorName() string { return "AuthorityValidationError" }
// Error satisfies the builtin error interface
func (e AuthorityValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sAuthority.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = AuthorityValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = AuthorityValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/collection_entry.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
any "github.com/golang/protobuf/ptypes/any"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type CollectionEntry struct {
// Types that are valid to be assigned to ResourceSpecifier:
// *CollectionEntry_Locator
// *CollectionEntry_InlineEntry_
ResourceSpecifier isCollectionEntry_ResourceSpecifier `protobuf_oneof:"resource_specifier"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CollectionEntry) Reset() { *m = CollectionEntry{} }
func (m *CollectionEntry) String() string { return proto.CompactTextString(m) }
func (*CollectionEntry) ProtoMessage() {}
func (*CollectionEntry) Descriptor() ([]byte, []int) {
return fileDescriptor_5b15c821e5994c90, []int{0}
}
func (m *CollectionEntry) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CollectionEntry.Unmarshal(m, b)
}
func (m *CollectionEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CollectionEntry.Marshal(b, m, deterministic)
}
func (m *CollectionEntry) XXX_Merge(src proto.Message) {
xxx_messageInfo_CollectionEntry.Merge(m, src)
}
func (m *CollectionEntry) XXX_Size() int {
return xxx_messageInfo_CollectionEntry.Size(m)
}
func (m *CollectionEntry) XXX_DiscardUnknown() {
xxx_messageInfo_CollectionEntry.DiscardUnknown(m)
}
var xxx_messageInfo_CollectionEntry proto.InternalMessageInfo
type isCollectionEntry_ResourceSpecifier interface {
isCollectionEntry_ResourceSpecifier()
}
type CollectionEntry_Locator struct {
Locator *ResourceLocator `protobuf:"bytes,1,opt,name=locator,proto3,oneof"`
}
type CollectionEntry_InlineEntry_ struct {
InlineEntry *CollectionEntry_InlineEntry `protobuf:"bytes,2,opt,name=inline_entry,json=inlineEntry,proto3,oneof"`
}
func (*CollectionEntry_Locator) isCollectionEntry_ResourceSpecifier() {}
func (*CollectionEntry_InlineEntry_) isCollectionEntry_ResourceSpecifier() {}
func (m *CollectionEntry) GetResourceSpecifier() isCollectionEntry_ResourceSpecifier {
if m != nil {
return m.ResourceSpecifier
}
return nil
}
func (m *CollectionEntry) GetLocator() *ResourceLocator {
if x, ok := m.GetResourceSpecifier().(*CollectionEntry_Locator); ok {
return x.Locator
}
return nil
}
func (m *CollectionEntry) GetInlineEntry() *CollectionEntry_InlineEntry {
if x, ok := m.GetResourceSpecifier().(*CollectionEntry_InlineEntry_); ok {
return x.InlineEntry
}
return nil
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*CollectionEntry) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*CollectionEntry_Locator)(nil),
(*CollectionEntry_InlineEntry_)(nil),
}
}
type CollectionEntry_InlineEntry struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
Resource *any.Any `protobuf:"bytes,3,opt,name=resource,proto3" json:"resource,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CollectionEntry_InlineEntry) Reset() { *m = CollectionEntry_InlineEntry{} }
func (m *CollectionEntry_InlineEntry) String() string { return proto.CompactTextString(m) }
func (*CollectionEntry_InlineEntry) ProtoMessage() {}
func (*CollectionEntry_InlineEntry) Descriptor() ([]byte, []int) {
return fileDescriptor_5b15c821e5994c90, []int{0, 0}
}
func (m *CollectionEntry_InlineEntry) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CollectionEntry_InlineEntry.Unmarshal(m, b)
}
func (m *CollectionEntry_InlineEntry) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CollectionEntry_InlineEntry.Marshal(b, m, deterministic)
}
func (m *CollectionEntry_InlineEntry) XXX_Merge(src proto.Message) {
xxx_messageInfo_CollectionEntry_InlineEntry.Merge(m, src)
}
func (m *CollectionEntry_InlineEntry) XXX_Size() int {
return xxx_messageInfo_CollectionEntry_InlineEntry.Size(m)
}
func (m *CollectionEntry_InlineEntry) XXX_DiscardUnknown() {
xxx_messageInfo_CollectionEntry_InlineEntry.DiscardUnknown(m)
}
var xxx_messageInfo_CollectionEntry_InlineEntry proto.InternalMessageInfo
func (m *CollectionEntry_InlineEntry) GetName() string {
if m != nil {
return m.Name
}
return ""
}
func (m *CollectionEntry_InlineEntry) GetVersion() string {
if m != nil {
return m.Version
}
return ""
}
func (m *CollectionEntry_InlineEntry) GetResource() *any.Any {
if m != nil {
return m.Resource
}
return nil
}
func init() {
proto.RegisterType((*CollectionEntry)(nil), "xds.core.v3.CollectionEntry")
proto.RegisterType((*CollectionEntry_InlineEntry)(nil), "xds.core.v3.CollectionEntry.InlineEntry")
}
func init() { proto.RegisterFile("xds/core/v3/collection_entry.proto", fileDescriptor_5b15c821e5994c90) }
var fileDescriptor_5b15c821e5994c90 = []byte{
// 371 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x5c, 0x91, 0xcf, 0x8b, 0x1a, 0x31,
0x1c, 0xc5, 0x1d, 0x2d, 0xfe, 0xc8, 0x14, 0x0a, 0xc1, 0xd6, 0x51, 0x2c, 0x14, 0xe9, 0x41, 0x28,
0x93, 0x88, 0x5e, 0x6c, 0x6f, 0x4e, 0x29, 0x58, 0x68, 0x41, 0xe6, 0xd8, 0xba, 0x2b, 0x71, 0x26,
0xba, 0x81, 0x31, 0x91, 0x24, 0x33, 0xe8, 0x1e, 0x96, 0xbd, 0xef, 0x7f, 0xb4, 0xd7, 0xbd, 0xec,
0x75, 0xff, 0x9b, 0x65, 0x4f, 0xcb, 0x64, 0x66, 0x5c, 0xf5, 0x96, 0xf0, 0x3e, 0x2f, 0xef, 0x7d,
0xf3, 0x05, 0xbd, 0x5d, 0xa8, 0x70, 0x20, 0x24, 0xc5, 0xc9, 0x08, 0x07, 0x22, 0x8a, 0x68, 0xa0,
0x99, 0xe0, 0x0b, 0xca, 0xb5, 0xdc, 0xa3, 0xad, 0x14, 0x5a, 0x40, 0x7b, 0x17, 0x2a, 0x94, 0x32,
0x28, 0x19, 0x75, 0xda, 0x6b, 0x21, 0xd6, 0x11, 0xc5, 0x46, 0x5a, 0xc6, 0x2b, 0x4c, 0x78, 0xce,
0x75, 0x3e, 0xc7, 0xe1, 0x96, 0x60, 0xc2, 0xb9, 0xd0, 0x24, 0x7d, 0x44, 0x61, 0xa5, 0x89, 0x8e,
0x55, 0x2e, 0x9f, 0x44, 0x49, 0xaa, 0x44, 0x2c, 0x03, 0xba, 0x88, 0x44, 0x40, 0xb4, 0x90, 0x39,
0xd3, 0x4a, 0x48, 0xc4, 0x42, 0xa2, 0x29, 0x2e, 0x0e, 0x99, 0xd0, 0x7b, 0x28, 0x83, 0x0f, 0x3f,
0x0f, 0xf5, 0x7e, 0xa5, 0xed, 0xe0, 0x18, 0xd4, 0x72, 0xb7, 0x63, 0x7d, 0xb1, 0xfa, 0xf6, 0xb0,
0x8b, 0x8e, 0x9a, 0x22, 0x3f, 0x8f, 0xf8, 0x93, 0x31, 0xd3, 0x92, 0x5f, 0xe0, 0xf0, 0x2f, 0x78,
0xcf, 0x78, 0xc4, 0x38, 0xcd, 0xe6, 0x74, 0xca, 0xc6, 0xde, 0x3f, 0xb1, 0x9f, 0xa5, 0xa1, 0xdf,
0xc6, 0x60, 0xce, 0xd3, 0x92, 0x6f, 0xb3, 0xb7, 0x6b, 0xe7, 0xce, 0x02, 0xf6, 0x91, 0x0c, 0x07,
0xe0, 0x1d, 0x27, 0x1b, 0x6a, 0x5a, 0x35, 0xbc, 0xee, 0x8b, 0xd7, 0x96, 0xad, 0xe1, 0xc7, 0xcb,
0xff, 0x03, 0xf7, 0x3b, 0x71, 0xaf, 0x27, 0xee, 0xbf, 0xc5, 0xdc, 0x9d, 0xa3, 0x9b, 0x1f, 0x17,
0xdf, 0xbe, 0xfa, 0x86, 0x84, 0x0e, 0xa8, 0x25, 0x54, 0x2a, 0x26, 0xb8, 0xe9, 0xd2, 0xf0, 0x8b,
0x2b, 0x1c, 0x80, 0x7a, 0xf1, 0x57, 0x4e, 0xc5, 0xd4, 0x6c, 0xa2, 0x6c, 0x05, 0xa8, 0x58, 0x01,
0x9a, 0xf0, 0xbd, 0x7f, 0xa0, 0xbc, 0x36, 0x80, 0x87, 0xdf, 0x55, 0x5b, 0x1a, 0xb0, 0x15, 0xa3,
0x12, 0x56, 0x9e, 0x3d, 0xcb, 0x1b, 0xdf, 0xdf, 0x3e, 0x3e, 0x55, 0xcb, 0x75, 0x0b, 0x7c, 0x0a,
0xc4, 0x06, 0xad, 0x99, 0xbe, 0x8a, 0x97, 0xc7, 0x53, 0x7b, 0xcd, 0xb3, 0xb1, 0x67, 0x69, 0xc6,
0xcc, 0x5a, 0x56, 0x4d, 0xd8, 0xe8, 0x35, 0x00, 0x00, 0xff, 0xff, 0x9f, 0x8b, 0xe3, 0xba, 0x30,
0x02, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/collection_entry.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _collection_entry_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on CollectionEntry with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned.
func (m *CollectionEntry) Validate() error {
if m == nil {
return nil
}
switch m.ResourceSpecifier.(type) {
case *CollectionEntry_Locator:
if v, ok := interface{}(m.GetLocator()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CollectionEntryValidationError{
field: "Locator",
reason: "embedded message failed validation",
cause: err,
}
}
}
case *CollectionEntry_InlineEntry_:
if v, ok := interface{}(m.GetInlineEntry()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CollectionEntryValidationError{
field: "InlineEntry",
reason: "embedded message failed validation",
cause: err,
}
}
}
default:
return CollectionEntryValidationError{
field: "ResourceSpecifier",
reason: "value is required",
}
}
return nil
}
// CollectionEntryValidationError is the validation error returned by
// CollectionEntry.Validate if the designated constraints aren't met.
type CollectionEntryValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e CollectionEntryValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e CollectionEntryValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e CollectionEntryValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e CollectionEntryValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e CollectionEntryValidationError) ErrorName() string { return "CollectionEntryValidationError" }
// Error satisfies the builtin error interface
func (e CollectionEntryValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sCollectionEntry.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = CollectionEntryValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = CollectionEntryValidationError{}
// Validate checks the field values on CollectionEntry_InlineEntry with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned.
func (m *CollectionEntry_InlineEntry) Validate() error {
if m == nil {
return nil
}
if !_CollectionEntry_InlineEntry_Name_Pattern.MatchString(m.GetName()) {
return CollectionEntry_InlineEntryValidationError{
field: "Name",
reason: "value does not match regex pattern \"^[0-9a-zA-Z_\\\\-\\\\.~:]+$\"",
}
}
// no validation rules for Version
if v, ok := interface{}(m.GetResource()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CollectionEntry_InlineEntryValidationError{
field: "Resource",
reason: "embedded message failed validation",
cause: err,
}
}
}
return nil
}
// CollectionEntry_InlineEntryValidationError is the validation error returned
// by CollectionEntry_InlineEntry.Validate if the designated constraints
// aren't met.
type CollectionEntry_InlineEntryValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e CollectionEntry_InlineEntryValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e CollectionEntry_InlineEntryValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e CollectionEntry_InlineEntryValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e CollectionEntry_InlineEntryValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e CollectionEntry_InlineEntryValidationError) ErrorName() string {
return "CollectionEntry_InlineEntryValidationError"
}
// Error satisfies the builtin error interface
func (e CollectionEntry_InlineEntryValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sCollectionEntry_InlineEntry.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = CollectionEntry_InlineEntryValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = CollectionEntry_InlineEntryValidationError{}
var _CollectionEntry_InlineEntry_Name_Pattern = regexp.MustCompile("^[0-9a-zA-Z_\\-\\.~:]+$")
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/context_params.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type ContextParams struct {
Params map[string]string `protobuf:"bytes,1,rep,name=params,proto3" json:"params,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ContextParams) Reset() { *m = ContextParams{} }
func (m *ContextParams) String() string { return proto.CompactTextString(m) }
func (*ContextParams) ProtoMessage() {}
func (*ContextParams) Descriptor() ([]byte, []int) {
return fileDescriptor_a77d5b5f2f15aa7c, []int{0}
}
func (m *ContextParams) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ContextParams.Unmarshal(m, b)
}
func (m *ContextParams) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ContextParams.Marshal(b, m, deterministic)
}
func (m *ContextParams) XXX_Merge(src proto.Message) {
xxx_messageInfo_ContextParams.Merge(m, src)
}
func (m *ContextParams) XXX_Size() int {
return xxx_messageInfo_ContextParams.Size(m)
}
func (m *ContextParams) XXX_DiscardUnknown() {
xxx_messageInfo_ContextParams.DiscardUnknown(m)
}
var xxx_messageInfo_ContextParams proto.InternalMessageInfo
func (m *ContextParams) GetParams() map[string]string {
if m != nil {
return m.Params
}
return nil
}
func init() {
proto.RegisterType((*ContextParams)(nil), "xds.core.v3.ContextParams")
proto.RegisterMapType((map[string]string)(nil), "xds.core.v3.ContextParams.ParamsEntry")
}
func init() { proto.RegisterFile("xds/core/v3/context_params.proto", fileDescriptor_a77d5b5f2f15aa7c) }
var fileDescriptor_a77d5b5f2f15aa7c = []byte{
// 217 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x52, 0xa8, 0x48, 0x29, 0xd6,
0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x33, 0xd6, 0x4f, 0xce, 0xcf, 0x2b, 0x49, 0xad, 0x28, 0x89,
0x2f, 0x48, 0x2c, 0x4a, 0xcc, 0x2d, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xae, 0x48,
0x29, 0xd6, 0x03, 0xa9, 0xd0, 0x2b, 0x33, 0x96, 0x92, 0x2d, 0x4d, 0x29, 0x48, 0xd4, 0x4f, 0xcc,
0xcb, 0xcb, 0x2f, 0x49, 0x2c, 0xc9, 0xcc, 0xcf, 0x2b, 0xd6, 0x2f, 0x2e, 0x49, 0x2c, 0x29, 0x85,
0xaa, 0x55, 0xea, 0x62, 0xe4, 0xe2, 0x75, 0x86, 0x18, 0x12, 0x00, 0x36, 0x43, 0xc8, 0x8e, 0x8b,
0x0d, 0x62, 0x9a, 0x04, 0xa3, 0x02, 0xb3, 0x06, 0xb7, 0x91, 0x9a, 0x1e, 0x92, 0x71, 0x7a, 0x28,
0x6a, 0xf5, 0x20, 0x94, 0x6b, 0x5e, 0x49, 0x51, 0x65, 0x10, 0x54, 0x97, 0x94, 0x25, 0x17, 0x37,
0x92, 0xb0, 0x90, 0x00, 0x17, 0x73, 0x76, 0x6a, 0xa5, 0x04, 0xa3, 0x02, 0xa3, 0x06, 0x67, 0x10,
0x88, 0x29, 0x24, 0xc2, 0xc5, 0x5a, 0x96, 0x98, 0x53, 0x9a, 0x2a, 0xc1, 0x04, 0x16, 0x83, 0x70,
0xac, 0x98, 0x2c, 0x18, 0x9d, 0xcc, 0x76, 0x35, 0x9c, 0xb8, 0xc8, 0xc6, 0xc4, 0xc1, 0xc8, 0x25,
0x96, 0x9c, 0x9f, 0xab, 0x97, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0x84, 0x6c, 0xbd, 0x93, 0x10, 0x8a,
0xfd, 0x01, 0x20, 0x2f, 0x04, 0x30, 0x26, 0xb1, 0x81, 0xfd, 0x62, 0x0c, 0x08, 0x00, 0x00, 0xff,
0xff, 0x74, 0x21, 0xd7, 0x1b, 0x1b, 0x01, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/context_params.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _context_params_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on ContextParams with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned.
func (m *ContextParams) Validate() error {
if m == nil {
return nil
}
// no validation rules for Params
return nil
}
// ContextParamsValidationError is the validation error returned by
// ContextParams.Validate if the designated constraints aren't met.
type ContextParamsValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e ContextParamsValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e ContextParamsValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e ContextParamsValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e ContextParamsValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e ContextParamsValidationError) ErrorName() string { return "ContextParamsValidationError" }
// Error satisfies the builtin error interface
func (e ContextParamsValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sContextParams.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = ContextParamsValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = ContextParamsValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/extension.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
any "github.com/golang/protobuf/ptypes/any"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type TypedExtensionConfig struct {
Name string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
TypedConfig *any.Any `protobuf:"bytes,2,opt,name=typed_config,json=typedConfig,proto3" json:"typed_config,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *TypedExtensionConfig) Reset() { *m = TypedExtensionConfig{} }
func (m *TypedExtensionConfig) String() string { return proto.CompactTextString(m) }
func (*TypedExtensionConfig) ProtoMessage() {}
func (*TypedExtensionConfig) Descriptor() ([]byte, []int) {
return fileDescriptor_ce7d8620783f5d54, []int{0}
}
func (m *TypedExtensionConfig) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_TypedExtensionConfig.Unmarshal(m, b)
}
func (m *TypedExtensionConfig) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_TypedExtensionConfig.Marshal(b, m, deterministic)
}
func (m *TypedExtensionConfig) XXX_Merge(src proto.Message) {
xxx_messageInfo_TypedExtensionConfig.Merge(m, src)
}
func (m *TypedExtensionConfig) XXX_Size() int {
return xxx_messageInfo_TypedExtensionConfig.Size(m)
}
func (m *TypedExtensionConfig) XXX_DiscardUnknown() {
xxx_messageInfo_TypedExtensionConfig.DiscardUnknown(m)
}
var xxx_messageInfo_TypedExtensionConfig proto.InternalMessageInfo
func (m *TypedExtensionConfig) GetName() string {
if m != nil {
return m.Name
}
return ""
}
func (m *TypedExtensionConfig) GetTypedConfig() *any.Any {
if m != nil {
return m.TypedConfig
}
return nil
}
func init() {
proto.RegisterType((*TypedExtensionConfig)(nil), "xds.core.v3.TypedExtensionConfig")
}
func init() { proto.RegisterFile("xds/core/v3/extension.proto", fileDescriptor_ce7d8620783f5d54) }
var fileDescriptor_ce7d8620783f5d54 = []byte{
// 220 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xae, 0x48, 0x29, 0xd6,
0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x33, 0xd6, 0x4f, 0xad, 0x28, 0x49, 0xcd, 0x2b, 0xce, 0xcc,
0xcf, 0xd3, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xae, 0x48, 0x29, 0xd6, 0x03, 0x49, 0xea,
0x95, 0x19, 0x4b, 0x89, 0x97, 0x25, 0xe6, 0x64, 0xa6, 0x24, 0x96, 0xa4, 0xea, 0xc3, 0x18, 0x10,
0x55, 0x52, 0x92, 0xe9, 0xf9, 0xf9, 0xe9, 0x39, 0xa9, 0xfa, 0x60, 0x5e, 0x52, 0x69, 0x9a, 0x7e,
0x62, 0x5e, 0x25, 0x44, 0x4a, 0xa9, 0x8c, 0x4b, 0x24, 0xa4, 0xb2, 0x20, 0x35, 0xc5, 0x15, 0x66,
0xb0, 0x73, 0x7e, 0x5e, 0x5a, 0x66, 0xba, 0x90, 0x34, 0x17, 0x4b, 0x5e, 0x62, 0x6e, 0xaa, 0x04,
0xa3, 0x02, 0xa3, 0x06, 0xa7, 0x13, 0xfb, 0x2f, 0x27, 0x96, 0x22, 0x26, 0x01, 0xc6, 0x20, 0xb0,
0xa0, 0x90, 0x23, 0x17, 0x4f, 0x09, 0x48, 0x53, 0x7c, 0x32, 0x58, 0xb1, 0x04, 0x93, 0x02, 0xa3,
0x06, 0xb7, 0x91, 0x88, 0x1e, 0xc4, 0x1a, 0x3d, 0x98, 0x35, 0x7a, 0x8e, 0x79, 0x95, 0x4e, 0x1c,
0xbf, 0x9c, 0x58, 0x17, 0x31, 0x32, 0x71, 0x30, 0x06, 0x71, 0x83, 0xf5, 0x40, 0xcc, 0x77, 0xd2,
0xe2, 0x12, 0x4b, 0xce, 0xcf, 0xd5, 0x4b, 0xcf, 0x2c, 0xc9, 0x28, 0x4d, 0xd2, 0x43, 0xf2, 0x85,
0x13, 0x1f, 0xdc, 0x29, 0x01, 0x20, 0x73, 0x02, 0x18, 0x93, 0xd8, 0xc0, 0x06, 0x1a, 0x03, 0x02,
0x00, 0x00, 0xff, 0xff, 0x34, 0x00, 0xe3, 0x99, 0x0a, 0x01, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/extension.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _extension_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on TypedExtensionConfig with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned.
func (m *TypedExtensionConfig) Validate() error {
if m == nil {
return nil
}
if utf8.RuneCountInString(m.GetName()) < 1 {
return TypedExtensionConfigValidationError{
field: "Name",
reason: "value length must be at least 1 runes",
}
}
if m.GetTypedConfig() == nil {
return TypedExtensionConfigValidationError{
field: "TypedConfig",
reason: "value is required",
}
}
if a := m.GetTypedConfig(); a != nil {
}
return nil
}
// TypedExtensionConfigValidationError is the validation error returned by
// TypedExtensionConfig.Validate if the designated constraints aren't met.
type TypedExtensionConfigValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e TypedExtensionConfigValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e TypedExtensionConfigValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e TypedExtensionConfigValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e TypedExtensionConfigValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e TypedExtensionConfigValidationError) ErrorName() string {
return "TypedExtensionConfigValidationError"
}
// Error satisfies the builtin error interface
func (e TypedExtensionConfigValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sTypedExtensionConfig.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = TypedExtensionConfigValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = TypedExtensionConfigValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/resource.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
proto "github.com/golang/protobuf/proto"
any "github.com/golang/protobuf/ptypes/any"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type Resource struct {
Name *ResourceName `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
Version string `protobuf:"bytes,2,opt,name=version,proto3" json:"version,omitempty"`
Resource *any.Any `protobuf:"bytes,3,opt,name=resource,proto3" json:"resource,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Resource) Reset() { *m = Resource{} }
func (m *Resource) String() string { return proto.CompactTextString(m) }
func (*Resource) ProtoMessage() {}
func (*Resource) Descriptor() ([]byte, []int) {
return fileDescriptor_acbac04701714df2, []int{0}
}
func (m *Resource) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Resource.Unmarshal(m, b)
}
func (m *Resource) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Resource.Marshal(b, m, deterministic)
}
func (m *Resource) XXX_Merge(src proto.Message) {
xxx_messageInfo_Resource.Merge(m, src)
}
func (m *Resource) XXX_Size() int {
return xxx_messageInfo_Resource.Size(m)
}
func (m *Resource) XXX_DiscardUnknown() {
xxx_messageInfo_Resource.DiscardUnknown(m)
}
var xxx_messageInfo_Resource proto.InternalMessageInfo
func (m *Resource) GetName() *ResourceName {
if m != nil {
return m.Name
}
return nil
}
func (m *Resource) GetVersion() string {
if m != nil {
return m.Version
}
return ""
}
func (m *Resource) GetResource() *any.Any {
if m != nil {
return m.Resource
}
return nil
}
func init() {
proto.RegisterType((*Resource)(nil), "xds.core.v3.Resource")
}
func init() { proto.RegisterFile("xds/core/v3/resource.proto", fileDescriptor_acbac04701714df2) }
var fileDescriptor_acbac04701714df2 = []byte{
// 238 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0x92, 0xaa, 0x48, 0x29, 0xd6,
0x4f, 0xce, 0x2f, 0x4a, 0xd5, 0x2f, 0x33, 0xd6, 0x2f, 0x4a, 0x2d, 0xce, 0x2f, 0x2d, 0x4a, 0x4e,
0xd5, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0xe2, 0xae, 0x48, 0x29, 0xd6, 0x03, 0xc9, 0xe9, 0x95,
0x19, 0x4b, 0x49, 0xa6, 0xe7, 0xe7, 0xa7, 0xe7, 0xa4, 0xea, 0x83, 0xa5, 0x92, 0x4a, 0xd3, 0xf4,
0x13, 0xf3, 0x2a, 0x21, 0xea, 0xa4, 0x64, 0x4b, 0x53, 0x0a, 0x12, 0xf5, 0x13, 0xf3, 0xf2, 0xf2,
0x4b, 0x12, 0x4b, 0x32, 0xf3, 0xf3, 0x8a, 0xf5, 0x8b, 0x4b, 0x12, 0x4b, 0x4a, 0x8b, 0xa1, 0xd2,
0xf2, 0xd8, 0xac, 0x88, 0xcf, 0x4b, 0xcc, 0x85, 0xda, 0xa3, 0xd4, 0xca, 0xc8, 0xc5, 0x11, 0x04,
0x15, 0x17, 0xd2, 0xe5, 0x62, 0x01, 0x49, 0x49, 0x30, 0x2a, 0x30, 0x6a, 0x70, 0x1b, 0x49, 0xea,
0x21, 0xb9, 0x41, 0x0f, 0xa6, 0xc8, 0x2f, 0x31, 0x37, 0x35, 0x08, 0xac, 0x4c, 0x48, 0x82, 0x8b,
0xbd, 0x2c, 0xb5, 0xa8, 0x38, 0x33, 0x3f, 0x4f, 0x82, 0x49, 0x81, 0x51, 0x83, 0x33, 0x08, 0xc6,
0x15, 0x32, 0xe0, 0xe2, 0x80, 0x59, 0x26, 0xc1, 0x0c, 0x36, 0x4c, 0x44, 0x0f, 0xe2, 0x07, 0x3d,
0x98, 0x1f, 0xf4, 0x1c, 0xf3, 0x2a, 0x83, 0xe0, 0xaa, 0x9c, 0x0c, 0x77, 0x35, 0x9c, 0xb8, 0xc8,
0xc6, 0xc4, 0xc1, 0xc8, 0x25, 0x96, 0x9c, 0x9f, 0xab, 0x97, 0x9e, 0x59, 0x92, 0x51, 0x9a, 0x84,
0xec, 0x00, 0x27, 0x5e, 0x98, 0x0b, 0x02, 0x40, 0x26, 0x04, 0x30, 0x26, 0xb1, 0x81, 0x8d, 0x32,
0x06, 0x04, 0x00, 0x00, 0xff, 0xff, 0x30, 0x49, 0x08, 0xff, 0x47, 0x01, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/resource.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _resource_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on Resource with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned.
func (m *Resource) Validate() error {
if m == nil {
return nil
}
if v, ok := interface{}(m.GetName()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceValidationError{
field: "Name",
reason: "embedded message failed validation",
cause: err,
}
}
}
// no validation rules for Version
if v, ok := interface{}(m.GetResource()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceValidationError{
field: "Resource",
reason: "embedded message failed validation",
cause: err,
}
}
}
return nil
}
// ResourceValidationError is the validation error returned by
// Resource.Validate if the designated constraints aren't met.
type ResourceValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e ResourceValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e ResourceValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e ResourceValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e ResourceValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e ResourceValidationError) ErrorName() string { return "ResourceValidationError" }
// Error satisfies the builtin error interface
func (e ResourceValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sResource.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = ResourceValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = ResourceValidationError{}
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/resource_locator.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type ResourceLocator_Scheme int32
const (
ResourceLocator_XDSTP ResourceLocator_Scheme = 0
ResourceLocator_HTTP ResourceLocator_Scheme = 1
ResourceLocator_FILE ResourceLocator_Scheme = 2
)
var ResourceLocator_Scheme_name = map[int32]string{
0: "XDSTP",
1: "HTTP",
2: "FILE",
}
var ResourceLocator_Scheme_value = map[string]int32{
"XDSTP": 0,
"HTTP": 1,
"FILE": 2,
}
func (x ResourceLocator_Scheme) String() string {
return proto.EnumName(ResourceLocator_Scheme_name, int32(x))
}
func (ResourceLocator_Scheme) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_eb09b3779eaf3665, []int{0, 0}
}
type ResourceLocator struct {
Scheme ResourceLocator_Scheme `protobuf:"varint,1,opt,name=scheme,proto3,enum=xds.core.v3.ResourceLocator_Scheme" json:"scheme,omitempty"`
Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"`
Authority string `protobuf:"bytes,3,opt,name=authority,proto3" json:"authority,omitempty"`
ResourceType string `protobuf:"bytes,4,opt,name=resource_type,json=resourceType,proto3" json:"resource_type,omitempty"`
// Types that are valid to be assigned to ContextParamSpecifier:
// *ResourceLocator_ExactContext
ContextParamSpecifier isResourceLocator_ContextParamSpecifier `protobuf_oneof:"context_param_specifier"`
Directives []*ResourceLocator_Directive `protobuf:"bytes,6,rep,name=directives,proto3" json:"directives,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceLocator) Reset() { *m = ResourceLocator{} }
func (m *ResourceLocator) String() string { return proto.CompactTextString(m) }
func (*ResourceLocator) ProtoMessage() {}
func (*ResourceLocator) Descriptor() ([]byte, []int) {
return fileDescriptor_eb09b3779eaf3665, []int{0}
}
func (m *ResourceLocator) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceLocator.Unmarshal(m, b)
}
func (m *ResourceLocator) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceLocator.Marshal(b, m, deterministic)
}
func (m *ResourceLocator) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceLocator.Merge(m, src)
}
func (m *ResourceLocator) XXX_Size() int {
return xxx_messageInfo_ResourceLocator.Size(m)
}
func (m *ResourceLocator) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceLocator.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceLocator proto.InternalMessageInfo
func (m *ResourceLocator) GetScheme() ResourceLocator_Scheme {
if m != nil {
return m.Scheme
}
return ResourceLocator_XDSTP
}
func (m *ResourceLocator) GetId() string {
if m != nil {
return m.Id
}
return ""
}
func (m *ResourceLocator) GetAuthority() string {
if m != nil {
return m.Authority
}
return ""
}
func (m *ResourceLocator) GetResourceType() string {
if m != nil {
return m.ResourceType
}
return ""
}
type isResourceLocator_ContextParamSpecifier interface {
isResourceLocator_ContextParamSpecifier()
}
type ResourceLocator_ExactContext struct {
ExactContext *ContextParams `protobuf:"bytes,5,opt,name=exact_context,json=exactContext,proto3,oneof"`
}
func (*ResourceLocator_ExactContext) isResourceLocator_ContextParamSpecifier() {}
func (m *ResourceLocator) GetContextParamSpecifier() isResourceLocator_ContextParamSpecifier {
if m != nil {
return m.ContextParamSpecifier
}
return nil
}
func (m *ResourceLocator) GetExactContext() *ContextParams {
if x, ok := m.GetContextParamSpecifier().(*ResourceLocator_ExactContext); ok {
return x.ExactContext
}
return nil
}
func (m *ResourceLocator) GetDirectives() []*ResourceLocator_Directive {
if m != nil {
return m.Directives
}
return nil
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*ResourceLocator) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*ResourceLocator_ExactContext)(nil),
}
}
type ResourceLocator_Directive struct {
// Types that are valid to be assigned to Directive:
// *ResourceLocator_Directive_Alt
// *ResourceLocator_Directive_Entry
Directive isResourceLocator_Directive_Directive `protobuf_oneof:"directive"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceLocator_Directive) Reset() { *m = ResourceLocator_Directive{} }
func (m *ResourceLocator_Directive) String() string { return proto.CompactTextString(m) }
func (*ResourceLocator_Directive) ProtoMessage() {}
func (*ResourceLocator_Directive) Descriptor() ([]byte, []int) {
return fileDescriptor_eb09b3779eaf3665, []int{0, 0}
}
func (m *ResourceLocator_Directive) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceLocator_Directive.Unmarshal(m, b)
}
func (m *ResourceLocator_Directive) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceLocator_Directive.Marshal(b, m, deterministic)
}
func (m *ResourceLocator_Directive) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceLocator_Directive.Merge(m, src)
}
func (m *ResourceLocator_Directive) XXX_Size() int {
return xxx_messageInfo_ResourceLocator_Directive.Size(m)
}
func (m *ResourceLocator_Directive) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceLocator_Directive.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceLocator_Directive proto.InternalMessageInfo
type isResourceLocator_Directive_Directive interface {
isResourceLocator_Directive_Directive()
}
type ResourceLocator_Directive_Alt struct {
Alt *ResourceLocator `protobuf:"bytes,1,opt,name=alt,proto3,oneof"`
}
type ResourceLocator_Directive_Entry struct {
Entry string `protobuf:"bytes,2,opt,name=entry,proto3,oneof"`
}
func (*ResourceLocator_Directive_Alt) isResourceLocator_Directive_Directive() {}
func (*ResourceLocator_Directive_Entry) isResourceLocator_Directive_Directive() {}
func (m *ResourceLocator_Directive) GetDirective() isResourceLocator_Directive_Directive {
if m != nil {
return m.Directive
}
return nil
}
func (m *ResourceLocator_Directive) GetAlt() *ResourceLocator {
if x, ok := m.GetDirective().(*ResourceLocator_Directive_Alt); ok {
return x.Alt
}
return nil
}
func (m *ResourceLocator_Directive) GetEntry() string {
if x, ok := m.GetDirective().(*ResourceLocator_Directive_Entry); ok {
return x.Entry
}
return ""
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*ResourceLocator_Directive) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*ResourceLocator_Directive_Alt)(nil),
(*ResourceLocator_Directive_Entry)(nil),
}
}
func init() {
proto.RegisterEnum("xds.core.v3.ResourceLocator_Scheme", ResourceLocator_Scheme_name, ResourceLocator_Scheme_value)
proto.RegisterType((*ResourceLocator)(nil), "xds.core.v3.ResourceLocator")
proto.RegisterType((*ResourceLocator_Directive)(nil), "xds.core.v3.ResourceLocator.Directive")
}
func init() { proto.RegisterFile("xds/core/v3/resource_locator.proto", fileDescriptor_eb09b3779eaf3665) }
var fileDescriptor_eb09b3779eaf3665 = []byte{
// 477 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x7c, 0x92, 0x4f, 0x6f, 0xd3, 0x30,
0x18, 0xc6, 0xeb, 0xb4, 0x0d, 0x8d, 0xbb, 0x8d, 0xc8, 0x42, 0x5b, 0x88, 0x8a, 0x88, 0x0a, 0x82,
0x4a, 0xd0, 0x64, 0x4a, 0x0f, 0xfc, 0xb9, 0xcd, 0x6c, 0x53, 0x91, 0x76, 0x88, 0xb2, 0x1e, 0x10,
0x0c, 0x22, 0x2f, 0x31, 0xd4, 0x52, 0x1b, 0x47, 0xb6, 0x53, 0xb5, 0x1c, 0x10, 0xe2, 0xc4, 0x89,
0x0f, 0xc4, 0x27, 0xe0, 0xca, 0xb7, 0x41, 0x3d, 0xa1, 0x24, 0x6d, 0xd7, 0xed, 0xb0, 0x9b, 0xf5,
0xbe, 0xbf, 0xf7, 0xd5, 0xf3, 0x3c, 0x7e, 0x61, 0x77, 0x9e, 0x48, 0x2f, 0xe6, 0x82, 0x7a, 0xb3,
0x81, 0x27, 0xa8, 0xe4, 0xb9, 0x88, 0x69, 0x34, 0xe1, 0x31, 0x51, 0x5c, 0xb8, 0x99, 0xe0, 0x8a,
0xa3, 0xf6, 0x3c, 0x91, 0x6e, 0xc1, 0xb8, 0xb3, 0x81, 0xfd, 0x20, 0x4f, 0x32, 0xe2, 0x91, 0x34,
0xe5, 0x8a, 0x28, 0xc6, 0x53, 0xe9, 0x49, 0x45, 0x54, 0x2e, 0x2b, 0xd6, 0x76, 0xb6, 0xf7, 0xc5,
0x3c, 0x55, 0x74, 0xae, 0xa2, 0x8c, 0x08, 0x32, 0x5d, 0x13, 0x07, 0x33, 0x32, 0x61, 0x09, 0x51,
0xd4, 0x5b, 0x3f, 0xaa, 0x46, 0xf7, 0x57, 0x03, 0xde, 0x0d, 0x57, 0x0a, 0xce, 0x2a, 0x01, 0xe8,
0x04, 0xea, 0x32, 0x1e, 0xd3, 0x29, 0xb5, 0x80, 0x03, 0x7a, 0x7b, 0xfe, 0x23, 0x77, 0x4b, 0x8b,
0x7b, 0x83, 0x76, 0xcf, 0x4b, 0x14, 0xb7, 0x96, 0xb8, 0xf9, 0x03, 0x68, 0x26, 0x08, 0x57, 0xc3,
0x68, 0x0f, 0x6a, 0x2c, 0xb1, 0x34, 0x07, 0xf4, 0x8c, 0x50, 0x63, 0x09, 0xea, 0x40, 0x83, 0xe4,
0x6a, 0xcc, 0x05, 0x53, 0x0b, 0xab, 0x5e, 0x96, 0xaf, 0x0a, 0xe8, 0x39, 0xdc, 0xdd, 0x24, 0xa1,
0x16, 0x19, 0xb5, 0x1a, 0x05, 0x81, 0xef, 0x2c, 0x71, 0x43, 0x14, 0x5b, 0x77, 0xd6, 0xdd, 0xd1,
0x22, 0xa3, 0xe8, 0x08, 0xee, 0xd2, 0x39, 0x89, 0x55, 0xb4, 0x72, 0x6b, 0x35, 0x1d, 0xd0, 0x6b,
0xfb, 0xf6, 0x35, 0xa5, 0x6f, 0xaa, 0x5e, 0x50, 0x06, 0x31, 0xac, 0x85, 0x3b, 0xe5, 0xc8, 0xaa,
0x8a, 0x4e, 0x21, 0x4c, 0x98, 0xa0, 0xb1, 0x62, 0x33, 0x2a, 0x2d, 0xdd, 0xa9, 0xf7, 0xda, 0xfe,
0x93, 0x5b, 0x9d, 0x1e, 0xaf, 0xf1, 0x70, 0x6b, 0xd2, 0xfe, 0x09, 0xa0, 0xb1, 0xe9, 0xa0, 0x43,
0x58, 0x27, 0x13, 0x55, 0x06, 0xd7, 0xf6, 0x3b, 0xb7, 0xad, 0x1b, 0xd6, 0xc2, 0x02, 0x45, 0x2f,
0x60, 0x93, 0xa6, 0x4a, 0x2c, 0xaa, 0xa4, 0xf0, 0xc3, 0x25, 0xee, 0x08, 0xdb, 0x04, 0xfe, 0xfe,
0xa7, 0x0f, 0x87, 0xfd, 0x57, 0xa4, 0xff, 0xf5, 0xa8, 0xff, 0x3e, 0xba, 0xe8, 0x5f, 0xb8, 0xde,
0xb7, 0xd7, 0x1f, 0x9f, 0x3d, 0x1e, 0xd6, 0xc2, 0x8a, 0xc7, 0x26, 0x34, 0x36, 0x32, 0x50, 0xfd,
0x1f, 0x06, 0xdd, 0xa7, 0x50, 0xaf, 0x7e, 0x03, 0x19, 0xb0, 0xf9, 0xee, 0xf8, 0x7c, 0x14, 0x98,
0x35, 0xd4, 0x82, 0x8d, 0xe1, 0x68, 0x14, 0x98, 0xa0, 0x78, 0x9d, 0xbe, 0x3d, 0x3b, 0x31, 0x35,
0x7c, 0x1f, 0x1e, 0x5c, 0x3b, 0x93, 0x48, 0x66, 0x34, 0x66, 0x9f, 0x19, 0x15, 0xf8, 0xe5, 0xef,
0xef, 0x7f, 0xfe, 0xea, 0x5a, 0x0b, 0xc0, 0xfd, 0x98, 0x4f, 0xdd, 0x2f, 0x4c, 0x8d, 0xf3, 0xcb,
0x6d, 0x1f, 0xf8, 0xde, 0x0d, 0x23, 0x41, 0x71, 0x48, 0x01, 0xb8, 0xd4, 0xcb, 0x8b, 0x1a, 0xfc,
0x0f, 0x00, 0x00, 0xff, 0xff, 0xb6, 0xed, 0xc3, 0xb8, 0xde, 0x02, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/resource_locator.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _resource_locator_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on ResourceLocator with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned.
func (m *ResourceLocator) Validate() error {
if m == nil {
return nil
}
if _, ok := ResourceLocator_Scheme_name[int32(m.GetScheme())]; !ok {
return ResourceLocatorValidationError{
field: "Scheme",
reason: "value must be one of the defined enum values",
}
}
// no validation rules for Id
// no validation rules for Authority
if utf8.RuneCountInString(m.GetResourceType()) < 1 {
return ResourceLocatorValidationError{
field: "ResourceType",
reason: "value length must be at least 1 runes",
}
}
for idx, item := range m.GetDirectives() {
_, _ = idx, item
if v, ok := interface{}(item).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceLocatorValidationError{
field: fmt.Sprintf("Directives[%v]", idx),
reason: "embedded message failed validation",
cause: err,
}
}
}
}
switch m.ContextParamSpecifier.(type) {
case *ResourceLocator_ExactContext:
if v, ok := interface{}(m.GetExactContext()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceLocatorValidationError{
field: "ExactContext",
reason: "embedded message failed validation",
cause: err,
}
}
}
}
return nil
}
// ResourceLocatorValidationError is the validation error returned by
// ResourceLocator.Validate if the designated constraints aren't met.
type ResourceLocatorValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e ResourceLocatorValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e ResourceLocatorValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e ResourceLocatorValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e ResourceLocatorValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e ResourceLocatorValidationError) ErrorName() string { return "ResourceLocatorValidationError" }
// Error satisfies the builtin error interface
func (e ResourceLocatorValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sResourceLocator.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = ResourceLocatorValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = ResourceLocatorValidationError{}
// Validate checks the field values on ResourceLocator_Directive with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned.
func (m *ResourceLocator_Directive) Validate() error {
if m == nil {
return nil
}
switch m.Directive.(type) {
case *ResourceLocator_Directive_Alt:
if v, ok := interface{}(m.GetAlt()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceLocator_DirectiveValidationError{
field: "Alt",
reason: "embedded message failed validation",
cause: err,
}
}
}
case *ResourceLocator_Directive_Entry:
if utf8.RuneCountInString(m.GetEntry()) < 1 {
return ResourceLocator_DirectiveValidationError{
field: "Entry",
reason: "value length must be at least 1 runes",
}
}
if !_ResourceLocator_Directive_Entry_Pattern.MatchString(m.GetEntry()) {
return ResourceLocator_DirectiveValidationError{
field: "Entry",
reason: "value does not match regex pattern \"^[0-9a-zA-Z_\\\\-\\\\./~:]+$\"",
}
}
default:
return ResourceLocator_DirectiveValidationError{
field: "Directive",
reason: "value is required",
}
}
return nil
}
// ResourceLocator_DirectiveValidationError is the validation error returned by
// ResourceLocator_Directive.Validate if the designated constraints aren't met.
type ResourceLocator_DirectiveValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e ResourceLocator_DirectiveValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e ResourceLocator_DirectiveValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e ResourceLocator_DirectiveValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e ResourceLocator_DirectiveValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e ResourceLocator_DirectiveValidationError) ErrorName() string {
return "ResourceLocator_DirectiveValidationError"
}
// Error satisfies the builtin error interface
func (e ResourceLocator_DirectiveValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sResourceLocator_Directive.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = ResourceLocator_DirectiveValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = ResourceLocator_DirectiveValidationError{}
var _ResourceLocator_Directive_Entry_Pattern = regexp.MustCompile("^[0-9a-zA-Z_\\-\\./~:]+$")
// Code generated by protoc-gen-go. DO NOT EDIT.
// source: xds/core/v3/resource_name.proto
package xds_core_v3
import (
fmt "fmt"
_ "github.com/cncf/xds/go/udpa/annotations"
_ "github.com/envoyproxy/protoc-gen-validate/validate"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
type ResourceName struct {
Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
Authority string `protobuf:"bytes,2,opt,name=authority,proto3" json:"authority,omitempty"`
ResourceType string `protobuf:"bytes,3,opt,name=resource_type,json=resourceType,proto3" json:"resource_type,omitempty"`
Context *ContextParams `protobuf:"bytes,4,opt,name=context,proto3" json:"context,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceName) Reset() { *m = ResourceName{} }
func (m *ResourceName) String() string { return proto.CompactTextString(m) }
func (*ResourceName) ProtoMessage() {}
func (*ResourceName) Descriptor() ([]byte, []int) {
return fileDescriptor_142e5d243416c11e, []int{0}
}
func (m *ResourceName) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceName.Unmarshal(m, b)
}
func (m *ResourceName) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceName.Marshal(b, m, deterministic)
}
func (m *ResourceName) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceName.Merge(m, src)
}
func (m *ResourceName) XXX_Size() int {
return xxx_messageInfo_ResourceName.Size(m)
}
func (m *ResourceName) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceName.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceName proto.InternalMessageInfo
func (m *ResourceName) GetId() string {
if m != nil {
return m.Id
}
return ""
}
func (m *ResourceName) GetAuthority() string {
if m != nil {
return m.Authority
}
return ""
}
func (m *ResourceName) GetResourceType() string {
if m != nil {
return m.ResourceType
}
return ""
}
func (m *ResourceName) GetContext() *ContextParams {
if m != nil {
return m.Context
}
return nil
}
func init() {
proto.RegisterType((*ResourceName)(nil), "xds.core.v3.ResourceName")
}
func init() { proto.RegisterFile("xds/core/v3/resource_name.proto", fileDescriptor_142e5d243416c11e) }
var fileDescriptor_142e5d243416c11e = []byte{
// 268 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0x4c, 0x8f, 0x41, 0x4e, 0x84, 0x30,
0x18, 0x85, 0x53, 0x9c, 0xcc, 0x38, 0x9d, 0xd1, 0x28, 0x0b, 0x25, 0x44, 0x23, 0x71, 0x35, 0x0b,
0xd3, 0x26, 0xa2, 0x17, 0xc0, 0xbd, 0x21, 0xc4, 0xfd, 0xe4, 0x1f, 0xda, 0x38, 0x4d, 0x84, 0x92,
0xf6, 0x2f, 0x81, 0x9d, 0x47, 0xf1, 0x1c, 0x9e, 0xc0, 0xad, 0xd7, 0x71, 0x65, 0x80, 0x41, 0xd9,
0x35, 0xef, 0x7d, 0x6d, 0xdf, 0x47, 0x6f, 0x1a, 0x61, 0x79, 0xae, 0x8d, 0xe4, 0x75, 0xcc, 0x8d,
0xb4, 0xda, 0x99, 0x5c, 0x6e, 0x4b, 0x28, 0x24, 0xab, 0x8c, 0x46, 0xed, 0xaf, 0x1a, 0x61, 0x59,
0x07, 0xb0, 0x3a, 0x0e, 0xaf, 0x9d, 0xa8, 0x80, 0x43, 0x59, 0x6a, 0x04, 0x54, 0xba, 0xb4, 0xdc,
0x22, 0xa0, 0xb3, 0x03, 0x1b, 0x46, 0xd3, 0xc7, 0x72, 0x5d, 0xa2, 0x6c, 0x70, 0x5b, 0x81, 0x81,
0x62, 0x24, 0x2e, 0x6b, 0x78, 0x53, 0x02, 0x50, 0xf2, 0xf1, 0x30, 0x14, 0xb7, 0x1f, 0x84, 0xae,
0xb3, 0xc3, 0xf7, 0xcf, 0x50, 0x48, 0xff, 0x94, 0x7a, 0x4a, 0x04, 0x24, 0x22, 0x9b, 0x65, 0xe6,
0x29, 0xe1, 0x5f, 0xd1, 0x25, 0x38, 0xdc, 0x6b, 0xa3, 0xb0, 0x0d, 0xbc, 0x3e, 0xfe, 0x0f, 0xfc,
0x3b, 0x7a, 0xf2, 0x37, 0x1e, 0xdb, 0x4a, 0x06, 0x47, 0x1d, 0x91, 0x2c, 0x7e, 0x92, 0x99, 0xf1,
0xce, 0x48, 0xb6, 0x1e, 0xdb, 0x97, 0xb6, 0x92, 0xfe, 0x03, 0x5d, 0x1c, 0xd6, 0x05, 0xb3, 0x88,
0x6c, 0x56, 0xf7, 0x21, 0x9b, 0x58, 0xb2, 0xa7, 0xa1, 0x4b, 0xfb, 0xe1, 0xd9, 0x88, 0x26, 0x8f,
0x9f, 0xef, 0x5f, 0xdf, 0x73, 0xef, 0x98, 0xd0, 0x8b, 0x5c, 0x17, 0xec, 0x55, 0xe1, 0xde, 0xed,
0xa6, 0x17, 0x93, 0xf3, 0xa9, 0x41, 0xda, 0x79, 0xa5, 0x64, 0x37, 0xef, 0x05, 0xe3, 0xdf, 0x00,
0x00, 0x00, 0xff, 0xff, 0x04, 0xbe, 0x3b, 0x1b, 0x6a, 0x01, 0x00, 0x00,
}
// Code generated by protoc-gen-validate. DO NOT EDIT.
// source: xds/core/v3/resource_name.proto
package xds_core_v3
import (
"bytes"
"errors"
"fmt"
"net"
"net/mail"
"net/url"
"regexp"
"strings"
"time"
"unicode/utf8"
"github.com/golang/protobuf/ptypes"
)
// ensure the imports are used
var (
_ = bytes.MinRead
_ = errors.New("")
_ = fmt.Print
_ = utf8.UTFMax
_ = (*regexp.Regexp)(nil)
_ = (*strings.Reader)(nil)
_ = net.IPv4len
_ = time.Duration(0)
_ = (*url.URL)(nil)
_ = (*mail.Address)(nil)
_ = ptypes.DynamicAny{}
)
// define the regex for a UUID once up-front
var _resource_name_uuidPattern = regexp.MustCompile("^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$")
// Validate checks the field values on ResourceName with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned.
func (m *ResourceName) Validate() error {
if m == nil {
return nil
}
// no validation rules for Id
// no validation rules for Authority
if utf8.RuneCountInString(m.GetResourceType()) < 1 {
return ResourceNameValidationError{
field: "ResourceType",
reason: "value length must be at least 1 runes",
}
}
if v, ok := interface{}(m.GetContext()).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ResourceNameValidationError{
field: "Context",
reason: "embedded message failed validation",
cause: err,
}
}
}
return nil
}
// ResourceNameValidationError is the validation error returned by
// ResourceName.Validate if the designated constraints aren't met.
type ResourceNameValidationError struct {
field string
reason string
cause error
key bool
}
// Field function returns field value.
func (e ResourceNameValidationError) Field() string { return e.field }
// Reason function returns reason value.
func (e ResourceNameValidationError) Reason() string { return e.reason }
// Cause function returns cause value.
func (e ResourceNameValidationError) Cause() error { return e.cause }
// Key function returns key value.
func (e ResourceNameValidationError) Key() bool { return e.key }
// ErrorName returns error name.
func (e ResourceNameValidationError) ErrorName() string { return "ResourceNameValidationError" }
// Error satisfies the builtin error interface
func (e ResourceNameValidationError) Error() string {
cause := ""
if e.cause != nil {
cause = fmt.Sprintf(" | caused by: %v", e.cause)
}
key := ""
if e.key {
key = "key for "
}
return fmt.Sprintf(
"invalid %sResourceName.%s: %s%s",
key,
e.field,
e.reason,
cause)
}
var _ error = ResourceNameValidationError{}
var _ interface {
Field() string
Reason() string
Key() bool
Cause() error
ErrorName() string
} = ResourceNameValidationError{}