id int32 0 167k | repo stringlengths 5 54 | path stringlengths 4 155 | func_name stringlengths 1 118 | original_string stringlengths 52 85.5k | language stringclasses 1
value | code stringlengths 52 85.5k | code_tokens list | docstring stringlengths 6 2.61k | docstring_tokens list | sha stringlengths 40 40 | url stringlengths 85 252 |
|---|---|---|---|---|---|---|---|---|---|---|---|
25,000 | envoyproxy/go-control-plane | envoy/config/filter/network/dubbo_proxy/v2alpha1/dubbo_proxy.pb.validate.go | Validate | func (m *DubboFilter) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return DubboFilterValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetConfig()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if e... | go | func (m *DubboFilter) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return DubboFilterValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetConfig()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if e... | [
"func",
"(",
"m",
"*",
"DubboFilter",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"DubboFilterValidationErr... | // Validate checks the field values on DubboFilter with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"DubboFilter",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/dubbo_proxy/v2alpha1/dubbo_proxy.pb.validate.go#L164-L192 |
25,001 | envoyproxy/go-control-plane | envoy/config/common/tap/v2alpha/common.pb.validate.go | Validate | func (m *CommonExtensionConfig) Validate() error {
if m == nil {
return nil
}
switch m.ConfigType.(type) {
case *CommonExtensionConfig_AdminConfig:
{
tmp := m.GetAdminConfig()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Commo... | go | func (m *CommonExtensionConfig) Validate() error {
if m == nil {
return nil
}
switch m.ConfigType.(type) {
case *CommonExtensionConfig_AdminConfig:
{
tmp := m.GetAdminConfig()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Commo... | [
"func",
"(",
"m",
"*",
"CommonExtensionConfig",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"ConfigType",
".",
"(",
"type",
")",
"{",
"case",
"*",
"CommonExtensionConfig_... | // Validate checks the field values on CommonExtensionConfig with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"CommonExtensionConfig",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/common/tap/v2alpha/common.pb.validate.go#L39-L89 |
25,002 | envoyproxy/go-control-plane | envoy/config/common/tap/v2alpha/common.pb.validate.go | Validate | func (m *AdminConfig) Validate() error {
if m == nil {
return nil
}
if len(m.GetConfigId()) < 1 {
return AdminConfigValidationError{
field: "ConfigId",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *AdminConfig) Validate() error {
if m == nil {
return nil
}
if len(m.GetConfigId()) < 1 {
return AdminConfigValidationError{
field: "ConfigId",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"AdminConfig",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetConfigId",
"(",
")",
")",
"<",
"1",
"{",
"return",
"AdminConfigValidatio... | // Validate checks the field values on AdminConfig with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"AdminConfig",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/common/tap/v2alpha/common.pb.validate.go#L150-L163 |
25,003 | envoyproxy/go-control-plane | envoy/config/filter/http/grpc_http1_reverse_bridge/v2alpha1/config.pb.validate.go | Validate | func (m *FilterConfig) Validate() error {
if m == nil {
return nil
}
if len(m.GetContentType()) < 1 {
return FilterConfigValidationError{
field: "ContentType",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for WithholdGrpcFrames
return nil
} | go | func (m *FilterConfig) Validate() error {
if m == nil {
return nil
}
if len(m.GetContentType()) < 1 {
return FilterConfigValidationError{
field: "ContentType",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for WithholdGrpcFrames
return nil
} | [
"func",
"(",
"m",
"*",
"FilterConfig",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetContentType",
"(",
")",
")",
"<",
"1",
"{",
"return",
"FilterConfigVali... | // Validate checks the field values on FilterConfig with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"FilterConfig",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/grpc_http1_reverse_bridge/v2alpha1/config.pb.validate.go#L39-L54 |
25,004 | envoyproxy/go-control-plane | envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go | Validate | func (m *ThriftProxy) Validate() error {
if m == nil {
return nil
}
if _, ok := TransportType_name[int32(m.GetTransport())]; !ok {
return ThriftProxyValidationError{
field: "Transport",
reason: "value must be one of the defined enum values",
}
}
if _, ok := ProtocolType_name[int32(m.GetProtocol())];... | go | func (m *ThriftProxy) Validate() error {
if m == nil {
return nil
}
if _, ok := TransportType_name[int32(m.GetTransport())]; !ok {
return ThriftProxyValidationError{
field: "Transport",
reason: "value must be one of the defined enum values",
}
}
if _, ok := ProtocolType_name[int32(m.GetProtocol())];... | [
"func",
"(",
"m",
"*",
"ThriftProxy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"_",
",",
"ok",
":=",
"TransportType_name",
"[",
"int32",
"(",
"m",
".",
"GetTransport",
"(",
")",... | // Validate checks the field values on ThriftProxy with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ThriftProxy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go#L39-L101 |
25,005 | envoyproxy/go-control-plane | envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go | Validate | func (m *ThriftFilter) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return ThriftFilterValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *ThriftFilter_Config:
{
tmp := m.GetConfig()
if v, ok :... | go | func (m *ThriftFilter) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return ThriftFilterValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *ThriftFilter_Config:
{
tmp := m.GetConfig()
if v, ok :... | [
"func",
"(",
"m",
"*",
"ThriftFilter",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"ThriftFilterValidationE... | // Validate checks the field values on ThriftFilter with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ThriftFilter",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go#L160-L211 |
25,006 | envoyproxy/go-control-plane | envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go | Validate | func (m *ThriftProtocolOptions) Validate() error {
if m == nil {
return nil
}
if _, ok := TransportType_name[int32(m.GetTransport())]; !ok {
return ThriftProtocolOptionsValidationError{
field: "Transport",
reason: "value must be one of the defined enum values",
}
}
if _, ok := ProtocolType_name[int3... | go | func (m *ThriftProtocolOptions) Validate() error {
if m == nil {
return nil
}
if _, ok := TransportType_name[int32(m.GetTransport())]; !ok {
return ThriftProtocolOptionsValidationError{
field: "Transport",
reason: "value must be one of the defined enum values",
}
}
if _, ok := ProtocolType_name[int3... | [
"func",
"(",
"m",
"*",
"ThriftProtocolOptions",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"_",
",",
"ok",
":=",
"TransportType_name",
"[",
"int32",
"(",
"m",
".",
"GetTransport",
"... | // Validate checks the field values on ThriftProtocolOptions with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ThriftProtocolOptions",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/thrift_proxy/v2alpha1/thrift_proxy.pb.validate.go#L270-L290 |
25,007 | envoyproxy/go-control-plane | envoy/service/accesslog/v2/als.pb.validate.go | Validate | func (m *StreamAccessLogsMessage) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetIdentifier()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return StreamAccessLogsMessageValidationError{
field: "Identifier",
reason: "em... | go | func (m *StreamAccessLogsMessage) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetIdentifier()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return StreamAccessLogsMessageValidationError{
field: "Identifier",
reason: "em... | [
"func",
"(",
"m",
"*",
"StreamAccessLogsMessage",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetIdentifier",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
... | // Validate checks the field values on StreamAccessLogsMessage with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"StreamAccessLogsMessage",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/accesslog/v2/als.pb.validate.go#L106-L171 |
25,008 | envoyproxy/go-control-plane | envoy/service/accesslog/v2/als.pb.validate.go | Validate | func (m *StreamAccessLogsMessage_Identifier) Validate() error {
if m == nil {
return nil
}
if m.GetNode() == nil {
return StreamAccessLogsMessage_IdentifierValidationError{
field: "Node",
reason: "value is required",
}
}
{
tmp := m.GetNode()
if v, ok := interface{}(tmp).(interface{ Validate() e... | go | func (m *StreamAccessLogsMessage_Identifier) Validate() error {
if m == nil {
return nil
}
if m.GetNode() == nil {
return StreamAccessLogsMessage_IdentifierValidationError{
field: "Node",
reason: "value is required",
}
}
{
tmp := m.GetNode()
if v, ok := interface{}(tmp).(interface{ Validate() e... | [
"func",
"(",
"m",
"*",
"StreamAccessLogsMessage_Identifier",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetNode",
"(",
")",
"==",
"nil",
"{",
"return",
"StreamAccessLogsMessa... | // Validate checks the field values on StreamAccessLogsMessage_Identifier with
// the rules defined in the proto definition for this message. If any rules
// are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"StreamAccessLogsMessage_Identifier",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"retur... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/accesslog/v2/als.pb.validate.go#L232-L267 |
25,009 | envoyproxy/go-control-plane | envoy/service/accesslog/v2/als.pb.validate.go | Validate | func (m *StreamAccessLogsMessage_TCPAccessLogEntries) Validate() error {
if m == nil {
return nil
}
if len(m.GetLogEntry()) < 1 {
return StreamAccessLogsMessage_TCPAccessLogEntriesValidationError{
field: "LogEntry",
reason: "value must contain at least 1 item(s)",
}
}
for idx, item := range m.GetLog... | go | func (m *StreamAccessLogsMessage_TCPAccessLogEntries) Validate() error {
if m == nil {
return nil
}
if len(m.GetLogEntry()) < 1 {
return StreamAccessLogsMessage_TCPAccessLogEntriesValidationError{
field: "LogEntry",
reason: "value must contain at least 1 item(s)",
}
}
for idx, item := range m.GetLog... | [
"func",
"(",
"m",
"*",
"StreamAccessLogsMessage_TCPAccessLogEntries",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetLogEntry",
"(",
")",
")",
"<",
"1",
"{",
"... | // Validate checks the field values on
// StreamAccessLogsMessage_TCPAccessLogEntries with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"StreamAccessLogsMessage_TCPAccessLogEntries",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/accesslog/v2/als.pb.validate.go#L425-L458 |
25,010 | envoyproxy/go-control-plane | envoy/config/filter/http/buffer/v2/buffer.pb.validate.go | Validate | func (m *Buffer) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetMaxRequestBytes(); wrapper != nil {
if wrapper.GetValue() <= 0 {
return BufferValidationError{
field: "MaxRequestBytes",
reason: "value must be greater than 0",
}
}
}
return nil
} | go | func (m *Buffer) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetMaxRequestBytes(); wrapper != nil {
if wrapper.GetValue() <= 0 {
return BufferValidationError{
field: "MaxRequestBytes",
reason: "value must be greater than 0",
}
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"Buffer",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"wrapper",
":=",
"m",
".",
"GetMaxRequestBytes",
"(",
")",
";",
"wrapper",
"!=",
"nil",
"{",
"if",
"w... | // Validate checks the field values on Buffer with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Buffer",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/buffer/v2/buffer.pb.validate.go#L38-L55 |
25,011 | envoyproxy/go-control-plane | envoy/config/filter/http/buffer/v2/buffer.pb.validate.go | Validate | func (m *BufferPerRoute) Validate() error {
if m == nil {
return nil
}
switch m.Override.(type) {
case *BufferPerRoute_Disabled:
if m.GetDisabled() != true {
return BufferPerRouteValidationError{
field: "Disabled",
reason: "value must equal true",
}
}
case *BufferPerRoute_Buffer:
if m.G... | go | func (m *BufferPerRoute) Validate() error {
if m == nil {
return nil
}
switch m.Override.(type) {
case *BufferPerRoute_Disabled:
if m.GetDisabled() != true {
return BufferPerRouteValidationError{
field: "Disabled",
reason: "value must equal true",
}
}
case *BufferPerRoute_Buffer:
if m.G... | [
"func",
"(",
"m",
"*",
"BufferPerRoute",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"Override",
".",
"(",
"type",
")",
"{",
"case",
"*",
"BufferPerRoute_Disabled",
":"... | // Validate checks the field values on BufferPerRoute with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"BufferPerRoute",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/buffer/v2/buffer.pb.validate.go#L114-L163 |
25,012 | envoyproxy/go-control-plane | envoy/config/accesslog/v2/file.pb.validate.go | Validate | func (m *FileAccessLog) Validate() error {
if m == nil {
return nil
}
if len(m.GetPath()) < 1 {
return FileAccessLogValidationError{
field: "Path",
reason: "value length must be at least 1 bytes",
}
}
switch m.AccessLogFormat.(type) {
case *FileAccessLog_Format:
// no validation rules for Format... | go | func (m *FileAccessLog) Validate() error {
if m == nil {
return nil
}
if len(m.GetPath()) < 1 {
return FileAccessLogValidationError{
field: "Path",
reason: "value length must be at least 1 bytes",
}
}
switch m.AccessLogFormat.(type) {
case *FileAccessLog_Format:
// no validation rules for Format... | [
"func",
"(",
"m",
"*",
"FileAccessLog",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetPath",
"(",
")",
")",
"<",
"1",
"{",
"return",
"FileAccessLogValidatio... | // Validate checks the field values on FileAccessLog with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"FileAccessLog",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/accesslog/v2/file.pb.validate.go#L39-L76 |
25,013 | envoyproxy/go-control-plane | envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go | Validate | func (m *BufferSettings) Validate() error {
if m == nil {
return nil
}
if m.GetMaxRequestBytes() <= 0 {
return BufferSettingsValidationError{
field: "MaxRequestBytes",
reason: "value must be greater than 0",
}
}
// no validation rules for AllowPartialMessage
return nil
} | go | func (m *BufferSettings) Validate() error {
if m == nil {
return nil
}
if m.GetMaxRequestBytes() <= 0 {
return BufferSettingsValidationError{
field: "MaxRequestBytes",
reason: "value must be greater than 0",
}
}
// no validation rules for AllowPartialMessage
return nil
} | [
"func",
"(",
"m",
"*",
"BufferSettings",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetMaxRequestBytes",
"(",
")",
"<=",
"0",
"{",
"return",
"BufferSettingsValidationError",
... | // Validate checks the field values on BufferSettings with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"BufferSettings",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go#L162-L177 |
25,014 | envoyproxy/go-control-plane | envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go | Validate | func (m *HttpService) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetServerUri()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpServiceValidationError{
field: "ServerUri",
reason: "embedded message failed vali... | go | func (m *HttpService) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetServerUri()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpServiceValidationError{
field: "ServerUri",
reason: "embedded message failed vali... | [
"func",
"(",
"m",
"*",
"HttpService",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetServerUri",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",... | // Validate checks the field values on HttpService with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpService",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go#L236-L289 |
25,015 | envoyproxy/go-control-plane | envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go | Validate | func (m *AuthorizationRequest) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowedHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return AuthorizationRequestValidationError{
field: "AllowedHeaders",
reason: "... | go | func (m *AuthorizationRequest) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowedHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return AuthorizationRequestValidationError{
field: "AllowedHeaders",
reason: "... | [
"func",
"(",
"m",
"*",
"AuthorizationRequest",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAllowedHeaders",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
... | // Validate checks the field values on AuthorizationRequest with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"AuthorizationRequest",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go#L348-L389 |
25,016 | envoyproxy/go-control-plane | envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go | Validate | func (m *AuthorizationResponse) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowedUpstreamHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return AuthorizationResponseValidationError{
field: "AllowedUpstreamHeader... | go | func (m *AuthorizationResponse) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowedUpstreamHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return AuthorizationResponseValidationError{
field: "AllowedUpstreamHeader... | [
"func",
"(",
"m",
"*",
"AuthorizationResponse",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAllowedUpstreamHeaders",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",... | // Validate checks the field values on AuthorizationResponse with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"AuthorizationResponse",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go#L450-L486 |
25,017 | envoyproxy/go-control-plane | envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go | Validate | func (m *ExtAuthzPerRoute) Validate() error {
if m == nil {
return nil
}
switch m.Override.(type) {
case *ExtAuthzPerRoute_Disabled:
if m.GetDisabled() != true {
return ExtAuthzPerRouteValidationError{
field: "Disabled",
reason: "value must equal true",
}
}
case *ExtAuthzPerRoute_CheckSett... | go | func (m *ExtAuthzPerRoute) Validate() error {
if m == nil {
return nil
}
switch m.Override.(type) {
case *ExtAuthzPerRoute_Disabled:
if m.GetDisabled() != true {
return ExtAuthzPerRouteValidationError{
field: "Disabled",
reason: "value must equal true",
}
}
case *ExtAuthzPerRoute_CheckSett... | [
"func",
"(",
"m",
"*",
"ExtAuthzPerRoute",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"Override",
".",
"(",
"type",
")",
"{",
"case",
"*",
"ExtAuthzPerRoute_Disabled",
... | // Validate checks the field values on ExtAuthzPerRoute with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ExtAuthzPerRoute",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/ext_authz/v2/ext_authz.pb.validate.go#L547-L596 |
25,018 | envoyproxy/go-control-plane | pkg/cache/status.go | newStatusInfo | func newStatusInfo(node *core.Node) *statusInfo {
out := statusInfo{
node: node,
watches: make(map[int64]ResponseWatch),
}
return &out
} | go | func newStatusInfo(node *core.Node) *statusInfo {
out := statusInfo{
node: node,
watches: make(map[int64]ResponseWatch),
}
return &out
} | [
"func",
"newStatusInfo",
"(",
"node",
"*",
"core",
".",
"Node",
")",
"*",
"statusInfo",
"{",
"out",
":=",
"statusInfo",
"{",
"node",
":",
"node",
",",
"watches",
":",
"make",
"(",
"map",
"[",
"int64",
"]",
"ResponseWatch",
")",
",",
"}",
"\n",
"retur... | // newStatusInfo initializes a status info data structure. | [
"newStatusInfo",
"initializes",
"a",
"status",
"info",
"data",
"structure",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/pkg/cache/status.go#L68-L74 |
25,019 | envoyproxy/go-control-plane | envoy/api/v2/cluster/circuit_breaker.pb.validate.go | Validate | func (m *CircuitBreakers) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetThresholds() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CircuitBreakersValidationError{
... | go | func (m *CircuitBreakers) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetThresholds() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CircuitBreakersValidationError{
... | [
"func",
"(",
"m",
"*",
"CircuitBreakers",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetThresholds",
"(",
")",
"{",
"_",
",",
"_",... | // Validate checks the field values on CircuitBreakers with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"CircuitBreakers",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/cluster/circuit_breaker.pb.validate.go#L43-L69 |
25,020 | envoyproxy/go-control-plane | envoy/api/v2/cluster/circuit_breaker.pb.validate.go | Validate | func (m *CircuitBreakers_Thresholds) Validate() error {
if m == nil {
return nil
}
// no validation rules for Priority
{
tmp := m.GetMaxConnections()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CircuitBreakers_ThresholdsValidationEr... | go | func (m *CircuitBreakers_Thresholds) Validate() error {
if m == nil {
return nil
}
// no validation rules for Priority
{
tmp := m.GetMaxConnections()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return CircuitBreakers_ThresholdsValidationEr... | [
"func",
"(",
"m",
"*",
"CircuitBreakers_Thresholds",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Priority",
"{",
"tmp",
":=",
"m",
".",
"GetMaxConnections",
"(",
")",
... | // Validate checks the field values on CircuitBreakers_Thresholds with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"CircuitBreakers_Thresholds",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/cluster/circuit_breaker.pb.validate.go#L128-L213 |
25,021 | envoyproxy/go-control-plane | envoy/data/tap/v2alpha/http.pb.validate.go | Validate | func (m *HttpBufferedTrace) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetRequest()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpBufferedTraceValidationError{
field: "Request",
reason: "embedded message fai... | go | func (m *HttpBufferedTrace) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetRequest()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpBufferedTraceValidationError{
field: "Request",
reason: "embedded message fai... | [
"func",
"(",
"m",
"*",
"HttpBufferedTrace",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetRequest",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interfa... | // Validate checks the field values on HttpBufferedTrace with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpBufferedTrace",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/data/tap/v2alpha/http.pb.validate.go#L39-L75 |
25,022 | envoyproxy/go-control-plane | envoy/data/tap/v2alpha/http.pb.validate.go | Validate | func (m *HttpStreamedTraceSegment) Validate() error {
if m == nil {
return nil
}
// no validation rules for TraceId
switch m.MessagePiece.(type) {
case *HttpStreamedTraceSegment_RequestHeaders:
{
tmp := m.GetRequestHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if ... | go | func (m *HttpStreamedTraceSegment) Validate() error {
if m == nil {
return nil
}
// no validation rules for TraceId
switch m.MessagePiece.(type) {
case *HttpStreamedTraceSegment_RequestHeaders:
{
tmp := m.GetRequestHeaders()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if ... | [
"func",
"(",
"m",
"*",
"HttpStreamedTraceSegment",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for TraceId",
"switch",
"m",
".",
"MessagePiece",
".",
"(",
"type",
")",
"{... | // Validate checks the field values on HttpStreamedTraceSegment with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpStreamedTraceSegment",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
".... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/data/tap/v2alpha/http.pb.validate.go#L136-L250 |
25,023 | envoyproxy/go-control-plane | envoy/data/tap/v2alpha/http.pb.validate.go | Validate | func (m *HttpBufferedTrace_Message) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetHeaders() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpBufferedTrace_MessageVal... | go | func (m *HttpBufferedTrace_Message) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetHeaders() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpBufferedTrace_MessageVal... | [
"func",
"(",
"m",
"*",
"HttpBufferedTrace_Message",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetHeaders",
"(",
")",
"{",
"_",
",",... | // Validate checks the field values on HttpBufferedTrace_Message with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpBufferedTrace_Message",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/data/tap/v2alpha/http.pb.validate.go#L311-L372 |
25,024 | envoyproxy/go-control-plane | envoy/config/transport_socket/alts/v2alpha/alts.pb.validate.go | Validate | func (m *Alts) Validate() error {
if m == nil {
return nil
}
if len(m.GetHandshakerService()) < 1 {
return AltsValidationError{
field: "HandshakerService",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *Alts) Validate() error {
if m == nil {
return nil
}
if len(m.GetHandshakerService()) < 1 {
return AltsValidationError{
field: "HandshakerService",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"Alts",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetHandshakerService",
"(",
")",
")",
"<",
"1",
"{",
"return",
"AltsValidationErro... | // Validate checks the field values on Alts with the rules defined in the proto
// definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Alts",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/transport_socket/alts/v2alpha/alts.pb.validate.go#L38-L51 |
25,025 | envoyproxy/go-control-plane | envoy/api/v2/core/health_check.pb.validate.go | Validate | func (m *HealthCheck_Payload) Validate() error {
if m == nil {
return nil
}
switch m.Payload.(type) {
case *HealthCheck_Payload_Text:
if len(m.GetText()) < 1 {
return HealthCheck_PayloadValidationError{
field: "Text",
reason: "value length must be at least 1 bytes",
}
}
case *HealthCheck_P... | go | func (m *HealthCheck_Payload) Validate() error {
if m == nil {
return nil
}
switch m.Payload.(type) {
case *HealthCheck_Payload_Text:
if len(m.GetText()) < 1 {
return HealthCheck_PayloadValidationError{
field: "Text",
reason: "value length must be at least 1 bytes",
}
}
case *HealthCheck_P... | [
"func",
"(",
"m",
"*",
"HealthCheck_Payload",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"Payload",
".",
"(",
"type",
")",
"{",
"case",
"*",
"HealthCheck_Payload_Text",
... | // Validate checks the field values on HealthCheck_Payload with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HealthCheck_Payload",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/health_check.pb.validate.go#L389-L417 |
25,026 | envoyproxy/go-control-plane | envoy/api/v2/core/health_check.pb.validate.go | Validate | func (m *HealthCheck_HttpHealthCheck) Validate() error {
if m == nil {
return nil
}
// no validation rules for Host
if len(m.GetPath()) < 1 {
return HealthCheck_HttpHealthCheckValidationError{
field: "Path",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetSend()
if v, ok :=... | go | func (m *HealthCheck_HttpHealthCheck) Validate() error {
if m == nil {
return nil
}
// no validation rules for Host
if len(m.GetPath()) < 1 {
return HealthCheck_HttpHealthCheckValidationError{
field: "Path",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetSend()
if v, ok :=... | [
"func",
"(",
"m",
"*",
"HealthCheck_HttpHealthCheck",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Host",
"if",
"len",
"(",
"m",
".",
"GetPath",
"(",
")",
")",
"<",
... | // Validate checks the field values on HealthCheck_HttpHealthCheck with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HealthCheck_HttpHealthCheck",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/health_check.pb.validate.go#L478-L574 |
25,027 | envoyproxy/go-control-plane | envoy/api/v2/core/health_check.pb.validate.go | Validate | func (m *HealthCheck_TcpHealthCheck) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetSend()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HealthCheck_TcpHealthCheckValidationError{
field: "Send",
reason: "embedded... | go | func (m *HealthCheck_TcpHealthCheck) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetSend()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HealthCheck_TcpHealthCheckValidationError{
field: "Send",
reason: "embedded... | [
"func",
"(",
"m",
"*",
"HealthCheck_TcpHealthCheck",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetSend",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"i... | // Validate checks the field values on HealthCheck_TcpHealthCheck with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HealthCheck_TcpHealthCheck",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/health_check.pb.validate.go#L636-L677 |
25,028 | envoyproxy/go-control-plane | envoy/api/v2/core/health_check.pb.validate.go | Validate | func (m *HealthCheck_CustomHealthCheck) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return HealthCheck_CustomHealthCheckValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *HealthCheck_CustomHealthCheck_... | go | func (m *HealthCheck_CustomHealthCheck) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return HealthCheck_CustomHealthCheckValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *HealthCheck_CustomHealthCheck_... | [
"func",
"(",
"m",
"*",
"HealthCheck_CustomHealthCheck",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"Health... | // Validate checks the field values on HealthCheck_CustomHealthCheck with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HealthCheck_CustomHealthCheck",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/health_check.pb.validate.go#L880-L931 |
25,029 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/load_report.pb.validate.go | Validate | func (m *UpstreamLocalityStats) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetLocality()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return UpstreamLocalityStatsValidationError{
field: "Locality",
reason: "embedded m... | go | func (m *UpstreamLocalityStats) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetLocality()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return UpstreamLocalityStatsValidationError{
field: "Locality",
reason: "embedded m... | [
"func",
"(",
"m",
"*",
"UpstreamLocalityStats",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetLocality",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"in... | // Validate checks the field values on UpstreamLocalityStats with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"UpstreamLocalityStats",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/load_report.pb.validate.go#L39-L108 |
25,030 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/load_report.pb.validate.go | Validate | func (m *UpstreamEndpointStats) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return UpstreamEndpointStatsValidationError{
field: "Address",
reason: "embedded mes... | go | func (m *UpstreamEndpointStats) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return UpstreamEndpointStatsValidationError{
field: "Address",
reason: "embedded mes... | [
"func",
"(",
"m",
"*",
"UpstreamEndpointStats",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAddress",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"int... | // Validate checks the field values on UpstreamEndpointStats with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"UpstreamEndpointStats",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/load_report.pb.validate.go#L169-L231 |
25,031 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/load_report.pb.validate.go | Validate | func (m *ClusterStats) Validate() error {
if m == nil {
return nil
}
if len(m.GetClusterName()) < 1 {
return ClusterStatsValidationError{
field: "ClusterName",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for ClusterServiceName
if len(m.GetUpstreamLocalityStats()) < ... | go | func (m *ClusterStats) Validate() error {
if m == nil {
return nil
}
if len(m.GetClusterName()) < 1 {
return ClusterStatsValidationError{
field: "ClusterName",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for ClusterServiceName
if len(m.GetUpstreamLocalityStats()) < ... | [
"func",
"(",
"m",
"*",
"ClusterStats",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetClusterName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"ClusterStatsVali... | // Validate checks the field values on ClusterStats with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ClusterStats",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/load_report.pb.validate.go#L365-L444 |
25,032 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/load_report.pb.validate.go | Validate | func (m *ClusterStats_DroppedRequests) Validate() error {
if m == nil {
return nil
}
if len(m.GetCategory()) < 1 {
return ClusterStats_DroppedRequestsValidationError{
field: "Category",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for DroppedCount
return nil
} | go | func (m *ClusterStats_DroppedRequests) Validate() error {
if m == nil {
return nil
}
if len(m.GetCategory()) < 1 {
return ClusterStats_DroppedRequestsValidationError{
field: "Category",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for DroppedCount
return nil
} | [
"func",
"(",
"m",
"*",
"ClusterStats_DroppedRequests",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetCategory",
"(",
")",
")",
"<",
"1",
"{",
"return",
"Clu... | // Validate checks the field values on ClusterStats_DroppedRequests with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ClusterStats_DroppedRequests",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/load_report.pb.validate.go#L503-L518 |
25,033 | envoyproxy/go-control-plane | envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go | Validate | func (m *Config) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetRequestRules() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ConfigValidationError{
field: fmt.S... | go | func (m *Config) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetRequestRules() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ConfigValidationError{
field: fmt.S... | [
"func",
"(",
"m",
"*",
"Config",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetRequestRules",
"(",
")",
"{",
"_",
",",
"_",
"=",... | // Validate checks the field values on Config with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Config",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go#L38-L84 |
25,034 | envoyproxy/go-control-plane | envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go | Validate | func (m *Config_KeyValuePair) Validate() error {
if m == nil {
return nil
}
// no validation rules for MetadataNamespace
if len(m.GetKey()) < 1 {
return Config_KeyValuePairValidationError{
field: "Key",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Value
// no v... | go | func (m *Config_KeyValuePair) Validate() error {
if m == nil {
return nil
}
// no validation rules for MetadataNamespace
if len(m.GetKey()) < 1 {
return Config_KeyValuePairValidationError{
field: "Key",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Value
// no v... | [
"func",
"(",
"m",
"*",
"Config_KeyValuePair",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for MetadataNamespace",
"if",
"len",
"(",
"m",
".",
"GetKey",
"(",
")",
")",
"... | // Validate checks the field values on Config_KeyValuePair with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Config_KeyValuePair",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go#L143-L162 |
25,035 | envoyproxy/go-control-plane | envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go | Validate | func (m *Config_Rule) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeader()) < 1 {
return Config_RuleValidationError{
field: "Header",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetOnHeaderPresent()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ... | go | func (m *Config_Rule) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeader()) < 1 {
return Config_RuleValidationError{
field: "Header",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetOnHeaderPresent()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ... | [
"func",
"(",
"m",
"*",
"Config_Rule",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetHeader",
"(",
")",
")",
"<",
"1",
"{",
"return",
"Config_RuleValidationE... | // Validate checks the field values on Config_Rule with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Config_Rule",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/header_to_metadata/v2/header_to_metadata.pb.validate.go#L223-L268 |
25,036 | envoyproxy/go-control-plane | pkg/util/struct.go | StructToMessage | func StructToMessage(pbst *types.Struct, out proto.Message) error {
if pbst == nil {
return errors.New("nil struct")
}
buf := &bytes.Buffer{}
if err := (&jsonpb.Marshaler{OrigName: true}).Marshal(buf, pbst); err != nil {
return err
}
return jsonpb.Unmarshal(buf, out)
} | go | func StructToMessage(pbst *types.Struct, out proto.Message) error {
if pbst == nil {
return errors.New("nil struct")
}
buf := &bytes.Buffer{}
if err := (&jsonpb.Marshaler{OrigName: true}).Marshal(buf, pbst); err != nil {
return err
}
return jsonpb.Unmarshal(buf, out)
} | [
"func",
"StructToMessage",
"(",
"pbst",
"*",
"types",
".",
"Struct",
",",
"out",
"proto",
".",
"Message",
")",
"error",
"{",
"if",
"pbst",
"==",
"nil",
"{",
"return",
"errors",
".",
"New",
"(",
"\"",
"\"",
")",
"\n",
"}",
"\n\n",
"buf",
":=",
"&",
... | // StructToMessage decodes a protobuf Message from a Struct. | [
"StructToMessage",
"decodes",
"a",
"protobuf",
"Message",
"from",
"a",
"Struct",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/pkg/util/struct.go#L49-L60 |
25,037 | envoyproxy/go-control-plane | envoy/api/v2/core/http_uri.pb.validate.go | Validate | func (m *HttpUri) Validate() error {
if m == nil {
return nil
}
if len(m.GetUri()) < 1 {
return HttpUriValidationError{
field: "Uri",
reason: "value length must be at least 1 bytes",
}
}
if m.GetTimeout() == nil {
return HttpUriValidationError{
field: "Timeout",
reason: "value is required",... | go | func (m *HttpUri) Validate() error {
if m == nil {
return nil
}
if len(m.GetUri()) < 1 {
return HttpUriValidationError{
field: "Uri",
reason: "value length must be at least 1 bytes",
}
}
if m.GetTimeout() == nil {
return HttpUriValidationError{
field: "Timeout",
reason: "value is required",... | [
"func",
"(",
"m",
"*",
"HttpUri",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetUri",
"(",
")",
")",
"<",
"1",
"{",
"return",
"HttpUriValidationError",
"{... | // Validate checks the field values on HttpUri with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpUri",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/http_uri.pb.validate.go#L38-L77 |
25,038 | envoyproxy/go-control-plane | envoy/config/filter/network/client_ssl_auth/v2/client_ssl_auth.pb.validate.go | Validate | func (m *ClientSSLAuth) Validate() error {
if m == nil {
return nil
}
if len(m.GetAuthApiCluster()) < 1 {
return ClientSSLAuthValidationError{
field: "AuthApiCluster",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetStatPrefix()) < 1 {
return ClientSSLAuthValidationError{
field... | go | func (m *ClientSSLAuth) Validate() error {
if m == nil {
return nil
}
if len(m.GetAuthApiCluster()) < 1 {
return ClientSSLAuthValidationError{
field: "AuthApiCluster",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetStatPrefix()) < 1 {
return ClientSSLAuthValidationError{
field... | [
"func",
"(",
"m",
"*",
"ClientSSLAuth",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetAuthApiCluster",
"(",
")",
")",
"<",
"1",
"{",
"return",
"ClientSSLAut... | // Validate checks the field values on ClientSSLAuth with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ClientSSLAuth",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/client_ssl_auth/v2/client_ssl_auth.pb.validate.go#L39-L94 |
25,039 | envoyproxy/go-control-plane | envoy/data/tap/v2alpha/common.pb.validate.go | Validate | func (m *Body) Validate() error {
if m == nil {
return nil
}
// no validation rules for Truncated
switch m.BodyType.(type) {
case *Body_AsBytes:
// no validation rules for AsBytes
case *Body_AsString:
// no validation rules for AsString
}
return nil
} | go | func (m *Body) Validate() error {
if m == nil {
return nil
}
// no validation rules for Truncated
switch m.BodyType.(type) {
case *Body_AsBytes:
// no validation rules for AsBytes
case *Body_AsString:
// no validation rules for AsString
}
return nil
} | [
"func",
"(",
"m",
"*",
"Body",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Truncated",
"switch",
"m",
".",
"BodyType",
".",
"(",
"type",
")",
"{",
"case",
"*",
... | // Validate checks the field values on Body with the rules defined in the proto
// definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Body",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/data/tap/v2alpha/common.pb.validate.go#L38-L56 |
25,040 | envoyproxy/go-control-plane | envoy/type/matcher/metadata.pb.validate.go | Validate | func (m *MetadataMatcher) Validate() error {
if m == nil {
return nil
}
if len(m.GetFilter()) < 1 {
return MetadataMatcherValidationError{
field: "Filter",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetPath()) < 1 {
return MetadataMatcherValidationError{
field: "Path",
re... | go | func (m *MetadataMatcher) Validate() error {
if m == nil {
return nil
}
if len(m.GetFilter()) < 1 {
return MetadataMatcherValidationError{
field: "Filter",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetPath()) < 1 {
return MetadataMatcherValidationError{
field: "Path",
re... | [
"func",
"(",
"m",
"*",
"MetadataMatcher",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetFilter",
"(",
")",
")",
"<",
"1",
"{",
"return",
"MetadataMatcherVal... | // Validate checks the field values on MetadataMatcher with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"MetadataMatcher",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/type/matcher/metadata.pb.validate.go#L39-L101 |
25,041 | envoyproxy/go-control-plane | envoy/type/matcher/metadata.pb.validate.go | Validate | func (m *MetadataMatcher_PathSegment) Validate() error {
if m == nil {
return nil
}
switch m.Segment.(type) {
case *MetadataMatcher_PathSegment_Key:
if len(m.GetKey()) < 1 {
return MetadataMatcher_PathSegmentValidationError{
field: "Key",
reason: "value length must be at least 1 bytes",
}
}
... | go | func (m *MetadataMatcher_PathSegment) Validate() error {
if m == nil {
return nil
}
switch m.Segment.(type) {
case *MetadataMatcher_PathSegment_Key:
if len(m.GetKey()) < 1 {
return MetadataMatcher_PathSegmentValidationError{
field: "Key",
reason: "value length must be at least 1 bytes",
}
}
... | [
"func",
"(",
"m",
"*",
"MetadataMatcher_PathSegment",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"Segment",
".",
"(",
"type",
")",
"{",
"case",
"*",
"MetadataMatcher_Pat... | // Validate checks the field values on MetadataMatcher_PathSegment with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"MetadataMatcher_PathSegment",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/type/matcher/metadata.pb.validate.go#L160-L185 |
25,042 | envoyproxy/go-control-plane | envoy/service/ratelimit/v2/rls.pb.validate.go | Validate | func (m *RateLimitRequest) Validate() error {
if m == nil {
return nil
}
// no validation rules for Domain
for idx, item := range m.GetDescriptors() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
retu... | go | func (m *RateLimitRequest) Validate() error {
if m == nil {
return nil
}
// no validation rules for Domain
for idx, item := range m.GetDescriptors() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
retu... | [
"func",
"(",
"m",
"*",
"RateLimitRequest",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Domain",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetDescriptors",
... | // Validate checks the field values on RateLimitRequest with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimitRequest",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/ratelimit/v2/rls.pb.validate.go#L39-L69 |
25,043 | envoyproxy/go-control-plane | envoy/service/ratelimit/v2/rls.pb.validate.go | Validate | func (m *RateLimitResponse) Validate() error {
if m == nil {
return nil
}
// no validation rules for OverallCode
for idx, item := range m.GetStatuses() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
r... | go | func (m *RateLimitResponse) Validate() error {
if m == nil {
return nil
}
// no validation rules for OverallCode
for idx, item := range m.GetStatuses() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
r... | [
"func",
"(",
"m",
"*",
"RateLimitResponse",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for OverallCode",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetStatuses... | // Validate checks the field values on RateLimitResponse with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimitResponse",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/ratelimit/v2/rls.pb.validate.go#L128-L176 |
25,044 | envoyproxy/go-control-plane | envoy/service/ratelimit/v2/rls.pb.validate.go | Validate | func (m *RateLimitResponse_DescriptorStatus) Validate() error {
if m == nil {
return nil
}
// no validation rules for Code
{
tmp := m.GetCurrentLimit()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RateLimitResponse_DescriptorStatusVa... | go | func (m *RateLimitResponse_DescriptorStatus) Validate() error {
if m == nil {
return nil
}
// no validation rules for Code
{
tmp := m.GetCurrentLimit()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RateLimitResponse_DescriptorStatusVa... | [
"func",
"(",
"m",
"*",
"RateLimitResponse_DescriptorStatus",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Code",
"{",
"tmp",
":=",
"m",
".",
"GetCurrentLimit",
"(",
")",... | // Validate checks the field values on RateLimitResponse_DescriptorStatus with
// the rules defined in the proto definition for this message. If any rules
// are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimitResponse_DescriptorStatus",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"retur... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/service/ratelimit/v2/rls.pb.validate.go#L309-L334 |
25,045 | envoyproxy/go-control-plane | envoy/config/filter/http/gzip/v2/gzip.pb.validate.go | Validate | func (m *Gzip) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetMemoryLevel(); wrapper != nil {
if val := wrapper.GetValue(); val < 1 || val > 9 {
return GzipValidationError{
field: "MemoryLevel",
reason: "value must be inside range [1, 9]",
}
}
}
if wrapper := m.GetContent... | go | func (m *Gzip) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetMemoryLevel(); wrapper != nil {
if val := wrapper.GetValue(); val < 1 || val > 9 {
return GzipValidationError{
field: "MemoryLevel",
reason: "value must be inside range [1, 9]",
}
}
}
if wrapper := m.GetContent... | [
"func",
"(",
"m",
"*",
"Gzip",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"wrapper",
":=",
"m",
".",
"GetMemoryLevel",
"(",
")",
";",
"wrapper",
"!=",
"nil",
"{",
"if",
"val",
... | // Validate checks the field values on Gzip with the rules defined in the proto
// definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Gzip",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/gzip/v2/gzip.pb.validate.go#L38-L102 |
25,046 | envoyproxy/go-control-plane | envoy/config/filter/http/fault/v2/fault.pb.validate.go | Validate | func (m *FaultAbort) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetPercentage()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return FaultAbortValidationError{
field: "Percentage",
reason: "embedded message failed vali... | go | func (m *FaultAbort) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetPercentage()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return FaultAbortValidationError{
field: "Percentage",
reason: "embedded message failed vali... | [
"func",
"(",
"m",
"*",
"FaultAbort",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetPercentage",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",... | // Validate checks the field values on FaultAbort with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"FaultAbort",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/fault/v2/fault.pb.validate.go#L38-L78 |
25,047 | envoyproxy/go-control-plane | envoy/config/filter/http/fault/v2/fault.pb.validate.go | Validate | func (m *HTTPFault) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetDelay()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HTTPFaultValidationError{
field: "Delay",
reason: "embedded message failed validation",
... | go | func (m *HTTPFault) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetDelay()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HTTPFaultValidationError{
field: "Delay",
reason: "embedded message failed validation",
... | [
"func",
"(",
"m",
"*",
"HTTPFault",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetDelay",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",
"{"... | // Validate checks the field values on HTTPFault with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HTTPFault",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/fault/v2/fault.pb.validate.go#L136-L224 |
25,048 | envoyproxy/go-control-plane | envoy/config/filter/network/mongo_proxy/v2/mongo_proxy.pb.validate.go | Validate | func (m *MongoProxy) Validate() error {
if m == nil {
return nil
}
if len(m.GetStatPrefix()) < 1 {
return MongoProxyValidationError{
field: "StatPrefix",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for AccessLog
{
tmp := m.GetDelay()
if v, ok := interface{}(tmp... | go | func (m *MongoProxy) Validate() error {
if m == nil {
return nil
}
if len(m.GetStatPrefix()) < 1 {
return MongoProxyValidationError{
field: "StatPrefix",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for AccessLog
{
tmp := m.GetDelay()
if v, ok := interface{}(tmp... | [
"func",
"(",
"m",
"*",
"MongoProxy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetStatPrefix",
"(",
")",
")",
"<",
"1",
"{",
"return",
"MongoProxyValidatio... | // Validate checks the field values on MongoProxy with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"MongoProxy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/network/mongo_proxy/v2/mongo_proxy.pb.validate.go#L38-L70 |
25,049 | envoyproxy/go-control-plane | envoy/admin/v2alpha/clusters.pb.validate.go | Validate | func (m *Clusters) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetClusterStatuses() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ClustersValidationError{
field:... | go | func (m *Clusters) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetClusterStatuses() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ClustersValidationError{
field:... | [
"func",
"(",
"m",
"*",
"Clusters",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetClusterStatuses",
"(",
")",
"{",
"_",
",",
"_",
... | // Validate checks the field values on Clusters with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Clusters",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/admin/v2alpha/clusters.pb.validate.go#L42-L68 |
25,050 | envoyproxy/go-control-plane | envoy/admin/v2alpha/clusters.pb.validate.go | Validate | func (m *ClusterStatus) Validate() error {
if m == nil {
return nil
}
// no validation rules for Name
// no validation rules for AddedViaApi
{
tmp := m.GetSuccessRateEjectionThreshold()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ... | go | func (m *ClusterStatus) Validate() error {
if m == nil {
return nil
}
// no validation rules for Name
// no validation rules for AddedViaApi
{
tmp := m.GetSuccessRateEjectionThreshold()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return ... | [
"func",
"(",
"m",
"*",
"ClusterStatus",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Name",
"// no validation rules for AddedViaApi",
"{",
"tmp",
":=",
"m",
".",
"GetSucce... | // Validate checks the field values on ClusterStatus with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"ClusterStatus",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/admin/v2alpha/clusters.pb.validate.go#L127-L172 |
25,051 | envoyproxy/go-control-plane | envoy/admin/v2alpha/clusters.pb.validate.go | Validate | func (m *HostStatus) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HostStatusValidationError{
field: "Address",
reason: "embedded message failed validation... | go | func (m *HostStatus) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HostStatusValidationError{
field: "Address",
reason: "embedded message failed validation... | [
"func",
"(",
"m",
"*",
"HostStatus",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAddress",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",
... | // Validate checks the field values on HostStatus with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HostStatus",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/admin/v2alpha/clusters.pb.validate.go#L230-L303 |
25,052 | envoyproxy/go-control-plane | envoy/type/percent.pb.validate.go | Validate | func (m *Percent) Validate() error {
if m == nil {
return nil
}
if val := m.GetValue(); val < 0 || val > 100 {
return PercentValidationError{
field: "Value",
reason: "value must be inside range [0, 100]",
}
}
return nil
} | go | func (m *Percent) Validate() error {
if m == nil {
return nil
}
if val := m.GetValue(); val < 0 || val > 100 {
return PercentValidationError{
field: "Value",
reason: "value must be inside range [0, 100]",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"Percent",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"val",
":=",
"m",
".",
"GetValue",
"(",
")",
";",
"val",
"<",
"0",
"||",
"val",
">",
"100",
"{",... | // Validate checks the field values on Percent with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Percent",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/type/percent.pb.validate.go#L38-L51 |
25,053 | envoyproxy/go-control-plane | envoy/type/percent.pb.validate.go | Validate | func (m *FractionalPercent) Validate() error {
if m == nil {
return nil
}
// no validation rules for Numerator
if _, ok := FractionalPercent_DenominatorType_name[int32(m.GetDenominator())]; !ok {
return FractionalPercentValidationError{
field: "Denominator",
reason: "value must be one of the defined en... | go | func (m *FractionalPercent) Validate() error {
if m == nil {
return nil
}
// no validation rules for Numerator
if _, ok := FractionalPercent_DenominatorType_name[int32(m.GetDenominator())]; !ok {
return FractionalPercentValidationError{
field: "Denominator",
reason: "value must be one of the defined en... | [
"func",
"(",
"m",
"*",
"FractionalPercent",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Numerator",
"if",
"_",
",",
"ok",
":=",
"FractionalPercent_DenominatorType_name",
... | // Validate checks the field values on FractionalPercent with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"FractionalPercent",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/type/percent.pb.validate.go#L110-L125 |
25,054 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *JwtProvider) Validate() error {
if m == nil {
return nil
}
if len(m.GetIssuer()) < 1 {
return JwtProviderValidationError{
field: "Issuer",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Forward
for idx, item := range m.GetFromHeaders() {
_, _ = idx, item... | go | func (m *JwtProvider) Validate() error {
if m == nil {
return nil
}
if len(m.GetIssuer()) < 1 {
return JwtProviderValidationError{
field: "Issuer",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Forward
for idx, item := range m.GetFromHeaders() {
_, _ = idx, item... | [
"func",
"(",
"m",
"*",
"JwtProvider",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetIssuer",
"(",
")",
")",
"<",
"1",
"{",
"return",
"JwtProviderValidationE... | // Validate checks the field values on JwtProvider with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"JwtProvider",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L39-L122 |
25,055 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *RemoteJwks) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHttpUri()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RemoteJwksValidationError{
field: "HttpUri",
reason: "embedded message failed validation... | go | func (m *RemoteJwks) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHttpUri()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RemoteJwksValidationError{
field: "HttpUri",
reason: "embedded message failed validation... | [
"func",
"(",
"m",
"*",
"RemoteJwks",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetHttpUri",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",
... | // Validate checks the field values on RemoteJwks with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RemoteJwks",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L180-L216 |
25,056 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *JwtHeader) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return JwtHeaderValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for ValuePrefix
return nil
} | go | func (m *JwtHeader) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return JwtHeaderValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for ValuePrefix
return nil
} | [
"func",
"(",
"m",
"*",
"JwtHeader",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"JwtHeaderValidationError",... | // Validate checks the field values on JwtHeader with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"JwtHeader",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L274-L289 |
25,057 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *JwtRequirement) Validate() error {
if m == nil {
return nil
}
switch m.RequiresType.(type) {
case *JwtRequirement_ProviderName:
// no validation rules for ProviderName
case *JwtRequirement_ProviderAndAudiences:
{
tmp := m.GetProviderAndAudiences()
if v, ok := interface{}(tmp).(interface{ ... | go | func (m *JwtRequirement) Validate() error {
if m == nil {
return nil
}
switch m.RequiresType.(type) {
case *JwtRequirement_ProviderName:
// no validation rules for ProviderName
case *JwtRequirement_ProviderAndAudiences:
{
tmp := m.GetProviderAndAudiences()
if v, ok := interface{}(tmp).(interface{ ... | [
"func",
"(",
"m",
"*",
"JwtRequirement",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"RequiresType",
".",
"(",
"type",
")",
"{",
"case",
"*",
"JwtRequirement_ProviderName... | // Validate checks the field values on JwtRequirement with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"JwtRequirement",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L417-L498 |
25,058 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *JwtRequirementAndList) Validate() error {
if m == nil {
return nil
}
if len(m.GetRequirements()) < 2 {
return JwtRequirementAndListValidationError{
field: "Requirements",
reason: "value must contain at least 2 item(s)",
}
}
for idx, item := range m.GetRequirements() {
_, _ = idx, item
... | go | func (m *JwtRequirementAndList) Validate() error {
if m == nil {
return nil
}
if len(m.GetRequirements()) < 2 {
return JwtRequirementAndListValidationError{
field: "Requirements",
reason: "value must contain at least 2 item(s)",
}
}
for idx, item := range m.GetRequirements() {
_, _ = idx, item
... | [
"func",
"(",
"m",
"*",
"JwtRequirementAndList",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetRequirements",
"(",
")",
")",
"<",
"2",
"{",
"return",
"JwtReq... | // Validate checks the field values on JwtRequirementAndList with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"JwtRequirementAndList",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L651-L684 |
25,059 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *RequirementRule) Validate() error {
if m == nil {
return nil
}
if m.GetMatch() == nil {
return RequirementRuleValidationError{
field: "Match",
reason: "value is required",
}
}
{
tmp := m.GetMatch()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Valid... | go | func (m *RequirementRule) Validate() error {
if m == nil {
return nil
}
if m.GetMatch() == nil {
return RequirementRuleValidationError{
field: "Match",
reason: "value is required",
}
}
{
tmp := m.GetMatch()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Valid... | [
"func",
"(",
"m",
"*",
"RequirementRule",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetMatch",
"(",
")",
"==",
"nil",
"{",
"return",
"RequirementRuleValidationError",
"{",... | // Validate checks the field values on RequirementRule with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RequirementRule",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L745-L788 |
25,060 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *FilterStateRule) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return FilterStateRuleValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Requires
return nil
} | go | func (m *FilterStateRule) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return FilterStateRuleValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for Requires
return nil
} | [
"func",
"(",
"m",
"*",
"FilterStateRule",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"FilterStateRuleValid... | // Validate checks the field values on FilterStateRule with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"FilterStateRule",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L847-L862 |
25,061 | envoyproxy/go-control-plane | envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go | Validate | func (m *JwtAuthentication) Validate() error {
if m == nil {
return nil
}
// no validation rules for Providers
for idx, item := range m.GetRules() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return... | go | func (m *JwtAuthentication) Validate() error {
if m == nil {
return nil
}
// no validation rules for Providers
for idx, item := range m.GetRules() {
_, _ = idx, item
{
tmp := item
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return... | [
"func",
"(",
"m",
"*",
"JwtAuthentication",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Providers",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetRules",
... | // Validate checks the field values on JwtAuthentication with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"JwtAuthentication",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/config/filter/http/jwt_authn/v2alpha/config.pb.validate.go#L921-L964 |
25,062 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *Node) Validate() error {
if m == nil {
return nil
}
// no validation rules for Id
// no validation rules for Cluster
{
tmp := m.GetMetadata()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return NodeValidationError{
field: "... | go | func (m *Node) Validate() error {
if m == nil {
return nil
}
// no validation rules for Id
// no validation rules for Cluster
{
tmp := m.GetMetadata()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return NodeValidationError{
field: "... | [
"func",
"(",
"m",
"*",
"Node",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Id",
"// no validation rules for Cluster",
"{",
"tmp",
":=",
"m",
".",
"GetMetadata",
"(",
... | // Validate checks the field values on Node with the rules defined in the proto
// definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Node",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L108-L150 |
25,063 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *RuntimeUInt32) Validate() error {
if m == nil {
return nil
}
// no validation rules for DefaultValue
if len(m.GetRuntimeKey()) < 1 {
return RuntimeUInt32ValidationError{
field: "RuntimeKey",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *RuntimeUInt32) Validate() error {
if m == nil {
return nil
}
// no validation rules for DefaultValue
if len(m.GetRuntimeKey()) < 1 {
return RuntimeUInt32ValidationError{
field: "RuntimeKey",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"RuntimeUInt32",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for DefaultValue",
"if",
"len",
"(",
"m",
".",
"GetRuntimeKey",
"(",
")",
")",
"<",
... | // Validate checks the field values on RuntimeUInt32 with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RuntimeUInt32",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L275-L290 |
25,064 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *HeaderValue) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetKey()); l < 1 || l > 16384 {
return HeaderValueValidationError{
field: "Key",
reason: "value length must be between 1 and 16384 bytes, inclusive",
}
}
if len(m.GetValue()) > 16384 {
return HeaderValueValidationErr... | go | func (m *HeaderValue) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetKey()); l < 1 || l > 16384 {
return HeaderValueValidationError{
field: "Key",
reason: "value length must be between 1 and 16384 bytes, inclusive",
}
}
if len(m.GetValue()) > 16384 {
return HeaderValueValidationErr... | [
"func",
"(",
"m",
"*",
"HeaderValue",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"l",
":=",
"len",
"(",
"m",
".",
"GetKey",
"(",
")",
")",
";",
"l",
"<",
"1",
"||",
"l",
"... | // Validate checks the field values on HeaderValue with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HeaderValue",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L349-L369 |
25,065 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *HeaderValueOption) Validate() error {
if m == nil {
return nil
}
if m.GetHeader() == nil {
return HeaderValueOptionValidationError{
field: "Header",
reason: "value is required",
}
}
{
tmp := m.GetHeader()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := ... | go | func (m *HeaderValueOption) Validate() error {
if m == nil {
return nil
}
if m.GetHeader() == nil {
return HeaderValueOptionValidationError{
field: "Header",
reason: "value is required",
}
}
{
tmp := m.GetHeader()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := ... | [
"func",
"(",
"m",
"*",
"HeaderValueOption",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetHeader",
"(",
")",
"==",
"nil",
"{",
"return",
"HeaderValueOptionValidationError",
... | // Validate checks the field values on HeaderValueOption with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HeaderValueOption",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L428-L471 |
25,066 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Error | func (e HeaderMapValidationError) 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 %sHeaderMap.%s: %s%s",
key,
e.field,
e.reason,
cause)
} | go | func (e HeaderMapValidationError) 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 %sHeaderMap.%s: %s%s",
key,
e.field,
e.reason,
cause)
} | [
"func",
"(",
"e",
"HeaderMapValidationError",
")",
"Error",
"(",
")",
"string",
"{",
"cause",
":=",
"\"",
"\"",
"\n",
"if",
"e",
".",
"cause",
"!=",
"nil",
"{",
"cause",
"=",
"fmt",
".",
"Sprintf",
"(",
"\"",
"\"",
",",
"e",
".",
"cause",
")",
"\... | // Error satisfies the builtin error interface | [
"Error",
"satisfies",
"the",
"builtin",
"error",
"interface"
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L584-L601 |
25,067 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *DataSource) Validate() error {
if m == nil {
return nil
}
switch m.Specifier.(type) {
case *DataSource_Filename:
if len(m.GetFilename()) < 1 {
return DataSourceValidationError{
field: "Filename",
reason: "value length must be at least 1 bytes",
}
}
case *DataSource_InlineBytes:
... | go | func (m *DataSource) Validate() error {
if m == nil {
return nil
}
switch m.Specifier.(type) {
case *DataSource_Filename:
if len(m.GetFilename()) < 1 {
return DataSourceValidationError{
field: "Filename",
reason: "value length must be at least 1 bytes",
}
}
case *DataSource_InlineBytes:
... | [
"func",
"(",
"m",
"*",
"DataSource",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"Specifier",
".",
"(",
"type",
")",
"{",
"case",
"*",
"DataSource_Filename",
":",
"if... | // Validate checks the field values on DataSource with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"DataSource",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L615-L658 |
25,068 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *TransportSocket) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return TransportSocketValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *TransportSocket_Config:
{
tmp := m.GetConfig()
i... | go | func (m *TransportSocket) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return TransportSocketValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *TransportSocket_Config:
{
tmp := m.GetConfig()
i... | [
"func",
"(",
"m",
"*",
"TransportSocket",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"TransportSocketValid... | // Validate checks the field values on TransportSocket with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"TransportSocket",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L717-L768 |
25,069 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *SocketOption) Validate() error {
if m == nil {
return nil
}
// no validation rules for Description
// no validation rules for Level
// no validation rules for Name
if _, ok := SocketOption_SocketState_name[int32(m.GetState())]; !ok {
return SocketOptionValidationError{
field: "State",
reas... | go | func (m *SocketOption) Validate() error {
if m == nil {
return nil
}
// no validation rules for Description
// no validation rules for Level
// no validation rules for Name
if _, ok := SocketOption_SocketState_name[int32(m.GetState())]; !ok {
return SocketOptionValidationError{
field: "State",
reas... | [
"func",
"(",
"m",
"*",
"SocketOption",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Description",
"// no validation rules for Level",
"// no validation rules for Name",
"if",
"_... | // Validate checks the field values on SocketOption with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"SocketOption",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L827-L862 |
25,070 | envoyproxy/go-control-plane | envoy/api/v2/core/base.pb.validate.go | Validate | func (m *RuntimeFractionalPercent) Validate() error {
if m == nil {
return nil
}
if m.GetDefaultValue() == nil {
return RuntimeFractionalPercentValidationError{
field: "DefaultValue",
reason: "value is required",
}
}
{
tmp := m.GetDefaultValue()
if v, ok := interface{}(tmp).(interface{ Validate... | go | func (m *RuntimeFractionalPercent) Validate() error {
if m == nil {
return nil
}
if m.GetDefaultValue() == nil {
return RuntimeFractionalPercentValidationError{
field: "DefaultValue",
reason: "value is required",
}
}
{
tmp := m.GetDefaultValue()
if v, ok := interface{}(tmp).(interface{ Validate... | [
"func",
"(",
"m",
"*",
"RuntimeFractionalPercent",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetDefaultValue",
"(",
")",
"==",
"nil",
"{",
"return",
"RuntimeFractionalPercen... | // Validate checks the field values on RuntimeFractionalPercent with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RuntimeFractionalPercent",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
".... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/base.pb.validate.go#L921-L951 |
25,071 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/endpoint.pb.validate.go | Validate | func (m *Endpoint) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return EndpointValidationError{
field: "Address",
reason: "embedded message failed validation",
... | go | func (m *Endpoint) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAddress()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return EndpointValidationError{
field: "Address",
reason: "embedded message failed validation",
... | [
"func",
"(",
"m",
"*",
"Endpoint",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAddress",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"interface",
"{... | // Validate checks the field values on Endpoint with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Endpoint",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/endpoint.pb.validate.go#L42-L78 |
25,072 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/endpoint.pb.validate.go | Validate | func (m *LbEndpoint) Validate() error {
if m == nil {
return nil
}
// no validation rules for HealthStatus
{
tmp := m.GetMetadata()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return LbEndpointValidationError{
field: "Metadata",
... | go | func (m *LbEndpoint) Validate() error {
if m == nil {
return nil
}
// no validation rules for HealthStatus
{
tmp := m.GetMetadata()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return LbEndpointValidationError{
field: "Metadata",
... | [
"func",
"(",
"m",
"*",
"LbEndpoint",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for HealthStatus",
"{",
"tmp",
":=",
"m",
".",
"GetMetadata",
"(",
")",
"\n\n",
"if",
... | // Validate checks the field values on LbEndpoint with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"LbEndpoint",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/endpoint.pb.validate.go#L136-L194 |
25,073 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/endpoint.pb.validate.go | Validate | func (m *LocalityLbEndpoints) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetLocality()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return LocalityLbEndpointsValidationError{
field: "Locality",
reason: "embedded messa... | go | func (m *LocalityLbEndpoints) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetLocality()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return LocalityLbEndpointsValidationError{
field: "Locality",
reason: "embedded messa... | [
"func",
"(",
"m",
"*",
"LocalityLbEndpoints",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetLocality",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"inte... | // Validate checks the field values on LocalityLbEndpoints with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"LocalityLbEndpoints",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/endpoint.pb.validate.go#L253-L312 |
25,074 | envoyproxy/go-control-plane | envoy/api/v2/endpoint/endpoint.pb.validate.go | Validate | func (m *Endpoint_HealthCheckConfig) Validate() error {
if m == nil {
return nil
}
if m.GetPortValue() > 65535 {
return Endpoint_HealthCheckConfigValidationError{
field: "PortValue",
reason: "value must be less than or equal to 65535",
}
}
return nil
} | go | func (m *Endpoint_HealthCheckConfig) Validate() error {
if m == nil {
return nil
}
if m.GetPortValue() > 65535 {
return Endpoint_HealthCheckConfigValidationError{
field: "PortValue",
reason: "value must be less than or equal to 65535",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"Endpoint_HealthCheckConfig",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetPortValue",
"(",
")",
">",
"65535",
"{",
"return",
"Endpoint_HealthCheckCon... | // Validate checks the field values on Endpoint_HealthCheckConfig with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Endpoint_HealthCheckConfig",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/endpoint/endpoint.pb.validate.go#L373-L386 |
25,075 | envoyproxy/go-control-plane | envoy/api/v2/core/protocol.pb.validate.go | Validate | func (m *HttpProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetIdleTimeout()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpProtocolOptionsValidationError{
field: "IdleTimeout",
reason: "embedded... | go | func (m *HttpProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetIdleTimeout()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return HttpProtocolOptionsValidationError{
field: "IdleTimeout",
reason: "embedded... | [
"func",
"(",
"m",
"*",
"HttpProtocolOptions",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetIdleTimeout",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
"i... | // Validate checks the field values on HttpProtocolOptions with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HttpProtocolOptions",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/protocol.pb.validate.go#L106-L127 |
25,076 | envoyproxy/go-control-plane | envoy/api/v2/core/protocol.pb.validate.go | Validate | func (m *Http1ProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowAbsoluteUrl()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Http1ProtocolOptionsValidationError{
field: "AllowAbsoluteUrl",
reaso... | go | func (m *Http1ProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetAllowAbsoluteUrl()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Http1ProtocolOptionsValidationError{
field: "AllowAbsoluteUrl",
reaso... | [
"func",
"(",
"m",
"*",
"Http1ProtocolOptions",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetAllowAbsoluteUrl",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":="... | // Validate checks the field values on Http1ProtocolOptions with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Http1ProtocolOptions",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/protocol.pb.validate.go#L188-L213 |
25,077 | envoyproxy/go-control-plane | envoy/api/v2/core/protocol.pb.validate.go | Validate | func (m *Http2ProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHpackTableSize()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Http2ProtocolOptionsValidationError{
field: "HpackTableSize",
reason: "... | go | func (m *Http2ProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHpackTableSize()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return Http2ProtocolOptionsValidationError{
field: "HpackTableSize",
reason: "... | [
"func",
"(",
"m",
"*",
"Http2ProtocolOptions",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetHpackTableSize",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
":=",
... | // Validate checks the field values on Http2ProtocolOptions with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Http2ProtocolOptions",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/protocol.pb.validate.go#L274-L332 |
25,078 | envoyproxy/go-control-plane | envoy/api/v2/core/protocol.pb.validate.go | Validate | func (m *GrpcProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHttp2ProtocolOptions()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return GrpcProtocolOptionsValidationError{
field: "Http2ProtocolOptions",
... | go | func (m *GrpcProtocolOptions) Validate() error {
if m == nil {
return nil
}
{
tmp := m.GetHttp2ProtocolOptions()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return GrpcProtocolOptionsValidationError{
field: "Http2ProtocolOptions",
... | [
"func",
"(",
"m",
"*",
"GrpcProtocolOptions",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"{",
"tmp",
":=",
"m",
".",
"GetHttp2ProtocolOptions",
"(",
")",
"\n\n",
"if",
"v",
",",
"ok",
"... | // Validate checks the field values on GrpcProtocolOptions with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"GrpcProtocolOptions",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/core/protocol.pb.validate.go#L393-L414 |
25,079 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *CorsPolicy) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetAllowOriginRegex() {
_, _ = idx, item
if len(item) > 1024 {
return CorsPolicyValidationError{
field: fmt.Sprintf("AllowOriginRegex[%v]", idx),
reason: "value length must be at most 1024 bytes",
}
}... | go | func (m *CorsPolicy) Validate() error {
if m == nil {
return nil
}
for idx, item := range m.GetAllowOriginRegex() {
_, _ = idx, item
if len(item) > 1024 {
return CorsPolicyValidationError{
field: fmt.Sprintf("AllowOriginRegex[%v]", idx),
reason: "value length must be at most 1024 bytes",
}
}... | [
"func",
"(",
"m",
"*",
"CorsPolicy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"for",
"idx",
",",
"item",
":=",
"range",
"m",
".",
"GetAllowOriginRegex",
"(",
")",
"{",
"_",
",",
"_"... | // Validate checks the field values on CorsPolicy with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"CorsPolicy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L797-L891 |
25,080 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RetryPolicy) Validate() error {
if m == nil {
return nil
}
// no validation rules for RetryOn
{
tmp := m.GetNumRetries()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RetryPolicyValidationError{
field: "NumRetries",
... | go | func (m *RetryPolicy) Validate() error {
if m == nil {
return nil
}
// no validation rules for RetryOn
{
tmp := m.GetNumRetries()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RetryPolicyValidationError{
field: "NumRetries",
... | [
"func",
"(",
"m",
"*",
"RetryPolicy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for RetryOn",
"{",
"tmp",
":=",
"m",
".",
"GetNumRetries",
"(",
")",
"\n\n",
"if",
"... | // Validate checks the field values on RetryPolicy with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RetryPolicy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1307-L1397 |
25,081 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *HedgePolicy) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetInitialRequests(); wrapper != nil {
if wrapper.GetValue() < 1 {
return HedgePolicyValidationError{
field: "InitialRequests",
reason: "value must be greater than or equal to 1",
}
}
}
{
tmp := m.GetAddi... | go | func (m *HedgePolicy) Validate() error {
if m == nil {
return nil
}
if wrapper := m.GetInitialRequests(); wrapper != nil {
if wrapper.GetValue() < 1 {
return HedgePolicyValidationError{
field: "InitialRequests",
reason: "value must be greater than or equal to 1",
}
}
}
{
tmp := m.GetAddi... | [
"func",
"(",
"m",
"*",
"HedgePolicy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"wrapper",
":=",
"m",
".",
"GetInitialRequests",
"(",
")",
";",
"wrapper",
"!=",
"nil",
"{",
"if",... | // Validate checks the field values on HedgePolicy with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HedgePolicy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1456-L1490 |
25,082 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RedirectAction) Validate() error {
if m == nil {
return nil
}
// no validation rules for HostRedirect
// no validation rules for PortRedirect
if _, ok := RedirectAction_RedirectResponseCode_name[int32(m.GetResponseCode())]; !ok {
return RedirectActionValidationError{
field: "ResponseCode",
r... | go | func (m *RedirectAction) Validate() error {
if m == nil {
return nil
}
// no validation rules for HostRedirect
// no validation rules for PortRedirect
if _, ok := RedirectAction_RedirectResponseCode_name[int32(m.GetResponseCode())]; !ok {
return RedirectActionValidationError{
field: "ResponseCode",
r... | [
"func",
"(",
"m",
"*",
"RedirectAction",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for HostRedirect",
"// no validation rules for PortRedirect",
"if",
"_",
",",
"ok",
":=",
... | // Validate checks the field values on RedirectAction with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RedirectAction",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1549-L1588 |
25,083 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *DirectResponseAction) Validate() error {
if m == nil {
return nil
}
if val := m.GetStatus(); val < 100 || val >= 600 {
return DirectResponseActionValidationError{
field: "Status",
reason: "value must be inside range [100, 600)",
}
}
{
tmp := m.GetBody()
if v, ok := interface{}(tmp).(in... | go | func (m *DirectResponseAction) Validate() error {
if m == nil {
return nil
}
if val := m.GetStatus(); val < 100 || val >= 600 {
return DirectResponseActionValidationError{
field: "Status",
reason: "value must be inside range [100, 600)",
}
}
{
tmp := m.GetBody()
if v, ok := interface{}(tmp).(in... | [
"func",
"(",
"m",
"*",
"DirectResponseAction",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"val",
":=",
"m",
".",
"GetStatus",
"(",
")",
";",
"val",
"<",
"100",
"||",
"val",
">="... | // Validate checks the field values on DirectResponseAction with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"DirectResponseAction",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1647-L1675 |
25,084 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *Decorator) Validate() error {
if m == nil {
return nil
}
if len(m.GetOperation()) < 1 {
return DecoratorValidationError{
field: "Operation",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *Decorator) Validate() error {
if m == nil {
return nil
}
if len(m.GetOperation()) < 1 {
return DecoratorValidationError{
field: "Operation",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"Decorator",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetOperation",
"(",
")",
")",
"<",
"1",
"{",
"return",
"DecoratorValidationEr... | // Validate checks the field values on Decorator with the rules defined in the
// proto definition for this message. If any rules are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"Decorator",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1735-L1748 |
25,085 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *VirtualCluster) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetPattern()); l < 1 || l > 1024 {
return VirtualClusterValidationError{
field: "Pattern",
reason: "value length must be between 1 and 1024 bytes, inclusive",
}
}
if len(m.GetName()) < 1 {
return VirtualClusterVal... | go | func (m *VirtualCluster) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetPattern()); l < 1 || l > 1024 {
return VirtualClusterValidationError{
field: "Pattern",
reason: "value length must be between 1 and 1024 bytes, inclusive",
}
}
if len(m.GetName()) < 1 {
return VirtualClusterVal... | [
"func",
"(",
"m",
"*",
"VirtualCluster",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"l",
":=",
"len",
"(",
"m",
".",
"GetPattern",
"(",
")",
")",
";",
"l",
"<",
"1",
"||",
"... | // Validate checks the field values on VirtualCluster with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"VirtualCluster",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1807-L1829 |
25,086 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *HeaderMatcher) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return HeaderMatcherValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for InvertMatch
switch m.HeaderMatchSpecifier.(type) {
case *HeaderMatch... | go | func (m *HeaderMatcher) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return HeaderMatcherValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for InvertMatch
switch m.HeaderMatchSpecifier.(type) {
case *HeaderMatch... | [
"func",
"(",
"m",
"*",
"HeaderMatcher",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"HeaderMatcherValidatio... | // Validate checks the field values on HeaderMatcher with the rules defined in
// the proto definition for this message. If any rules are violated, an error
// is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"HeaderMatcher",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L1992-L2061 |
25,087 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *QueryParameterMatcher) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetName()); l < 1 || l > 1024 {
return QueryParameterMatcherValidationError{
field: "Name",
reason: "value length must be between 1 and 1024 bytes, inclusive",
}
}
// no validation rules for Value
{
tmp :... | go | func (m *QueryParameterMatcher) Validate() error {
if m == nil {
return nil
}
if l := len(m.GetName()); l < 1 || l > 1024 {
return QueryParameterMatcherValidationError{
field: "Name",
reason: "value length must be between 1 and 1024 bytes, inclusive",
}
}
// no validation rules for Value
{
tmp :... | [
"func",
"(",
"m",
"*",
"QueryParameterMatcher",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"l",
":=",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
";",
"l",
"<",
"1",
"||",... | // Validate checks the field values on QueryParameterMatcher with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"QueryParameterMatcher",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2120-L2150 |
25,088 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RouteAction_RequestMirrorPolicy) Validate() error {
if m == nil {
return nil
}
if len(m.GetCluster()) < 1 {
return RouteAction_RequestMirrorPolicyValidationError{
field: "Cluster",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for RuntimeKey
{
tmp := m.GetR... | go | func (m *RouteAction_RequestMirrorPolicy) Validate() error {
if m == nil {
return nil
}
if len(m.GetCluster()) < 1 {
return RouteAction_RequestMirrorPolicyValidationError{
field: "Cluster",
reason: "value length must be at least 1 bytes",
}
}
// no validation rules for RuntimeKey
{
tmp := m.GetR... | [
"func",
"(",
"m",
"*",
"RouteAction_RequestMirrorPolicy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetCluster",
"(",
")",
")",
"<",
"1",
"{",
"return",
"R... | // Validate checks the field values on RouteAction_RequestMirrorPolicy with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RouteAction_RequestMirrorPolicy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2442-L2472 |
25,089 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RouteAction_HashPolicy) Validate() error {
if m == nil {
return nil
}
// no validation rules for Terminal
switch m.PolicySpecifier.(type) {
case *RouteAction_HashPolicy_Header_:
{
tmp := m.GetHeader()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Valida... | go | func (m *RouteAction_HashPolicy) Validate() error {
if m == nil {
return nil
}
// no validation rules for Terminal
switch m.PolicySpecifier.(type) {
case *RouteAction_HashPolicy_Header_:
{
tmp := m.GetHeader()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Valida... | [
"func",
"(",
"m",
"*",
"RouteAction_HashPolicy",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for Terminal",
"switch",
"m",
".",
"PolicySpecifier",
".",
"(",
"type",
")",
... | // Validate checks the field values on RouteAction_HashPolicy with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RouteAction_HashPolicy",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2534-L2603 |
25,090 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RouteAction_UpgradeConfig) Validate() error {
if m == nil {
return nil
}
// no validation rules for UpgradeType
{
tmp := m.GetEnabled()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RouteAction_UpgradeConfigValidationError{
... | go | func (m *RouteAction_UpgradeConfig) Validate() error {
if m == nil {
return nil
}
// no validation rules for UpgradeType
{
tmp := m.GetEnabled()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RouteAction_UpgradeConfigValidationError{
... | [
"func",
"(",
"m",
"*",
"RouteAction_UpgradeConfig",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"// no validation rules for UpgradeType",
"{",
"tmp",
":=",
"m",
".",
"GetEnabled",
"(",
")",
"\n\... | // Validate checks the field values on RouteAction_UpgradeConfig with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RouteAction_UpgradeConfig",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2664-L2687 |
25,091 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RouteAction_HashPolicy_Header) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeaderName()) < 1 {
return RouteAction_HashPolicy_HeaderValidationError{
field: "HeaderName",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *RouteAction_HashPolicy_Header) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeaderName()) < 1 {
return RouteAction_HashPolicy_HeaderValidationError{
field: "HeaderName",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"RouteAction_HashPolicy_Header",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetHeaderName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"... | // Validate checks the field values on RouteAction_HashPolicy_Header with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RouteAction_HashPolicy_Header",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2748-L2761 |
25,092 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RouteAction_HashPolicy_Cookie) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RouteAction_HashPolicy_CookieValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetTtl()
if v, ok := interface{}(tmp).(interface{ V... | go | func (m *RouteAction_HashPolicy_Cookie) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RouteAction_HashPolicy_CookieValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetTtl()
if v, ok := interface{}(tmp).(interface{ V... | [
"func",
"(",
"m",
"*",
"RouteAction_HashPolicy_Cookie",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"RouteA... | // Validate checks the field values on RouteAction_HashPolicy_Cookie with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RouteAction_HashPolicy_Cookie",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2823-L2853 |
25,093 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RetryPolicy_RetryPriority) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RetryPolicy_RetryPriorityValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *RetryPolicy_RetryPriority_Config:
{... | go | func (m *RetryPolicy_RetryPriority) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RetryPolicy_RetryPriorityValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *RetryPolicy_RetryPriority_Config:
{... | [
"func",
"(",
"m",
"*",
"RetryPolicy_RetryPriority",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"RetryPolic... | // Validate checks the field values on RetryPolicy_RetryPriority with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RetryPolicy_RetryPriority",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L2985-L3036 |
25,094 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RetryPolicy_RetryHostPredicate) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RetryPolicy_RetryHostPredicateValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *RetryPolicy_RetryHostPredica... | go | func (m *RetryPolicy_RetryHostPredicate) Validate() error {
if m == nil {
return nil
}
if len(m.GetName()) < 1 {
return RetryPolicy_RetryHostPredicateValidationError{
field: "Name",
reason: "value length must be at least 1 bytes",
}
}
switch m.ConfigType.(type) {
case *RetryPolicy_RetryHostPredica... | [
"func",
"(",
"m",
"*",
"RetryPolicy_RetryHostPredicate",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetName",
"(",
")",
")",
"<",
"1",
"{",
"return",
"Retry... | // Validate checks the field values on RetryPolicy_RetryHostPredicate with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RetryPolicy_RetryHostPredicate",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned"... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3097-L3148 |
25,095 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RetryPolicy_RetryBackOff) Validate() error {
if m == nil {
return nil
}
if m.GetBaseInterval() == nil {
return RetryPolicy_RetryBackOffValidationError{
field: "BaseInterval",
reason: "value is required",
}
}
if d := m.GetBaseInterval(); d != nil {
dur := *d
gt := time.Duration(0*time.S... | go | func (m *RetryPolicy_RetryBackOff) Validate() error {
if m == nil {
return nil
}
if m.GetBaseInterval() == nil {
return RetryPolicy_RetryBackOffValidationError{
field: "BaseInterval",
reason: "value is required",
}
}
if d := m.GetBaseInterval(); d != nil {
dur := *d
gt := time.Duration(0*time.S... | [
"func",
"(",
"m",
"*",
"RetryPolicy_RetryBackOff",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"m",
".",
"GetBaseInterval",
"(",
")",
"==",
"nil",
"{",
"return",
"RetryPolicy_RetryBackOf... | // Validate checks the field values on RetryPolicy_RetryBackOff with the rules
// defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RetryPolicy_RetryBackOff",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
".... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3210-L3251 |
25,096 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RateLimit_Action) Validate() error {
if m == nil {
return nil
}
switch m.ActionSpecifier.(type) {
case *RateLimit_Action_SourceCluster_:
{
tmp := m.GetSourceCluster()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RateL... | go | func (m *RateLimit_Action) Validate() error {
if m == nil {
return nil
}
switch m.ActionSpecifier.(type) {
case *RateLimit_Action_SourceCluster_:
{
tmp := m.GetSourceCluster()
if v, ok := interface{}(tmp).(interface{ Validate() error }); ok {
if err := v.Validate(); err != nil {
return RateL... | [
"func",
"(",
"m",
"*",
"RateLimit_Action",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"switch",
"m",
".",
"ActionSpecifier",
".",
"(",
"type",
")",
"{",
"case",
"*",
"RateLimit_Action_Sourc... | // Validate checks the field values on RateLimit_Action with the rules defined
// in the proto definition for this message. If any rules are violated, an
// error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimit_Action",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
"."
] | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3312-L3430 |
25,097 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RateLimit_Action_RequestHeaders) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeaderName()) < 1 {
return RateLimit_Action_RequestHeadersValidationError{
field: "HeaderName",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetDescriptorKey()) < 1 {
return RateLim... | go | func (m *RateLimit_Action_RequestHeaders) Validate() error {
if m == nil {
return nil
}
if len(m.GetHeaderName()) < 1 {
return RateLimit_Action_RequestHeadersValidationError{
field: "HeaderName",
reason: "value length must be at least 1 bytes",
}
}
if len(m.GetDescriptorKey()) < 1 {
return RateLim... | [
"func",
"(",
"m",
"*",
"RateLimit_Action_RequestHeaders",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetHeaderName",
"(",
")",
")",
"<",
"1",
"{",
"return",
... | // Validate checks the field values on RateLimit_Action_RequestHeaders with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimit_Action_RequestHeaders",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3625-L3645 |
25,098 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RateLimit_Action_GenericKey) Validate() error {
if m == nil {
return nil
}
if len(m.GetDescriptorValue()) < 1 {
return RateLimit_Action_GenericKeyValidationError{
field: "DescriptorValue",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | go | func (m *RateLimit_Action_GenericKey) Validate() error {
if m == nil {
return nil
}
if len(m.GetDescriptorValue()) < 1 {
return RateLimit_Action_GenericKeyValidationError{
field: "DescriptorValue",
reason: "value length must be at least 1 bytes",
}
}
return nil
} | [
"func",
"(",
"m",
"*",
"RateLimit_Action_GenericKey",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetDescriptorValue",
"(",
")",
")",
"<",
"1",
"{",
"return",
... | // Validate checks the field values on RateLimit_Action_GenericKey with the
// rules defined in the proto definition for this message. If any rules are
// violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimit_Action_GenericKey",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"returned",
... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3775-L3788 |
25,099 | envoyproxy/go-control-plane | envoy/api/v2/route/route.pb.validate.go | Validate | func (m *RateLimit_Action_HeaderValueMatch) Validate() error {
if m == nil {
return nil
}
if len(m.GetDescriptorValue()) < 1 {
return RateLimit_Action_HeaderValueMatchValidationError{
field: "DescriptorValue",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetExpectMatch()
if v... | go | func (m *RateLimit_Action_HeaderValueMatch) Validate() error {
if m == nil {
return nil
}
if len(m.GetDescriptorValue()) < 1 {
return RateLimit_Action_HeaderValueMatchValidationError{
field: "DescriptorValue",
reason: "value length must be at least 1 bytes",
}
}
{
tmp := m.GetExpectMatch()
if v... | [
"func",
"(",
"m",
"*",
"RateLimit_Action_HeaderValueMatch",
")",
"Validate",
"(",
")",
"error",
"{",
"if",
"m",
"==",
"nil",
"{",
"return",
"nil",
"\n",
"}",
"\n\n",
"if",
"len",
"(",
"m",
".",
"GetDescriptorValue",
"(",
")",
")",
"<",
"1",
"{",
"ret... | // Validate checks the field values on RateLimit_Action_HeaderValueMatch with
// the rules defined in the proto definition for this message. If any rules
// are violated, an error is returned. | [
"Validate",
"checks",
"the",
"field",
"values",
"on",
"RateLimit_Action_HeaderValueMatch",
"with",
"the",
"rules",
"defined",
"in",
"the",
"proto",
"definition",
"for",
"this",
"message",
".",
"If",
"any",
"rules",
"are",
"violated",
"an",
"error",
"is",
"return... | 9ffbaf293221f9fef735838632a9109d00aa2f4c | https://github.com/envoyproxy/go-control-plane/blob/9ffbaf293221f9fef735838632a9109d00aa2f4c/envoy/api/v2/route/route.pb.validate.go#L3850-L3905 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.