// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.10
// 	protoc        v7.35.1
// source: envoy/extensions/filters/http/proto_message_extraction/v3/config.proto

package proto_message_extractionv3

import (
	_ "github.com/cncf/xds/go/udpa/annotations"
	_ "github.com/cncf/xds/go/xds/annotations/v3"
	v3 "github.com/envoyproxy/go-control-plane/envoy/config/core/v3"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	reflect "reflect"
	sync "sync"
	unsafe "unsafe"
)

const (
	// Verify that this generated code is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
	// Verify that runtime/protoimpl is sufficiently up-to-date.
	_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)

type ProtoMessageExtractionConfig_ExtractMode int32

const (
	ProtoMessageExtractionConfig_ExtractMode_UNSPECIFIED ProtoMessageExtractionConfig_ExtractMode = 0
	// The filter will extract the first and the last message for
	// for streaming cases, containing
	// client-side streaming, server-side streaming or bi-directional streaming.
	ProtoMessageExtractionConfig_FIRST_AND_LAST ProtoMessageExtractionConfig_ExtractMode = 1
)

// Enum value maps for ProtoMessageExtractionConfig_ExtractMode.
var (
	ProtoMessageExtractionConfig_ExtractMode_name = map[int32]string{
		0: "ExtractMode_UNSPECIFIED",
		1: "FIRST_AND_LAST",
	}
	ProtoMessageExtractionConfig_ExtractMode_value = map[string]int32{
		"ExtractMode_UNSPECIFIED": 0,
		"FIRST_AND_LAST":          1,
	}
)

func (x ProtoMessageExtractionConfig_ExtractMode) Enum() *ProtoMessageExtractionConfig_ExtractMode {
	p := new(ProtoMessageExtractionConfig_ExtractMode)
	*p = x
	return p
}

func (x ProtoMessageExtractionConfig_ExtractMode) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (ProtoMessageExtractionConfig_ExtractMode) Descriptor() protoreflect.EnumDescriptor {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes[0].Descriptor()
}

func (ProtoMessageExtractionConfig_ExtractMode) Type() protoreflect.EnumType {
	return &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes[0]
}

func (x ProtoMessageExtractionConfig_ExtractMode) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use ProtoMessageExtractionConfig_ExtractMode.Descriptor instead.
func (ProtoMessageExtractionConfig_ExtractMode) EnumDescriptor() ([]byte, []int) {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescGZIP(), []int{0, 0}
}

type MethodExtraction_ExtractDirective int32

const (
	MethodExtraction_ExtractDirective_UNSPECIFIED MethodExtraction_ExtractDirective = 0
	// The value of this field will be extracted.
	MethodExtraction_EXTRACT MethodExtraction_ExtractDirective = 1
	// It should be only annotated on Message type fields so if the field isn't
	// empty, an empty Struct will be extracted.
	MethodExtraction_EXTRACT_REDACT MethodExtraction_ExtractDirective = 2
	// Extract a repeated top-level field and record its number of entries in
	// the extraction result. Can be applied to at most one field in the
	// response, and cannot be applied to any fields in the request.
	MethodExtraction_EXTRACT_REPEATED_CARDINALITY MethodExtraction_ExtractDirective = 3
)

// Enum value maps for MethodExtraction_ExtractDirective.
var (
	MethodExtraction_ExtractDirective_name = map[int32]string{
		0: "ExtractDirective_UNSPECIFIED",
		1: "EXTRACT",
		2: "EXTRACT_REDACT",
		3: "EXTRACT_REPEATED_CARDINALITY",
	}
	MethodExtraction_ExtractDirective_value = map[string]int32{
		"ExtractDirective_UNSPECIFIED": 0,
		"EXTRACT":                      1,
		"EXTRACT_REDACT":               2,
		"EXTRACT_REPEATED_CARDINALITY": 3,
	}
)

func (x MethodExtraction_ExtractDirective) Enum() *MethodExtraction_ExtractDirective {
	p := new(MethodExtraction_ExtractDirective)
	*p = x
	return p
}

func (x MethodExtraction_ExtractDirective) String() string {
	return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}

func (MethodExtraction_ExtractDirective) Descriptor() protoreflect.EnumDescriptor {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes[1].Descriptor()
}

func (MethodExtraction_ExtractDirective) Type() protoreflect.EnumType {
	return &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes[1]
}

func (x MethodExtraction_ExtractDirective) Number() protoreflect.EnumNumber {
	return protoreflect.EnumNumber(x)
}

// Deprecated: Use MethodExtraction_ExtractDirective.Descriptor instead.
func (MethodExtraction_ExtractDirective) EnumDescriptor() ([]byte, []int) {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescGZIP(), []int{1, 0}
}

type ProtoMessageExtractionConfig struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The proto descriptor set binary for the gRPC services.
	//
	// Types that are valid to be assigned to DescriptorSet:
	//
	//	*ProtoMessageExtractionConfig_DataSource
	//	*ProtoMessageExtractionConfig_ProtoDescriptorTypedMetadata
	DescriptorSet isProtoMessageExtractionConfig_DescriptorSet `protobuf_oneof:"descriptor_set"`
	Mode          ProtoMessageExtractionConfig_ExtractMode     `protobuf:"varint,3,opt,name=mode,proto3,enum=envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig_ExtractMode" json:"mode,omitempty"`
	// Specify the message extraction info.
	// The key is the fully qualified gRPC method name.
	// “${package}.${Service}.${Method}“, like
	// “endpoints.examples.bookstore.BookStore.GetShelf“
	//
	// The value is the message extraction information for individual gRPC
	// methods.
	ExtractionByMethod map[string]*MethodExtraction `protobuf:"bytes,4,rep,name=extraction_by_method,json=extractionByMethod,proto3" json:"extraction_by_method,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
	unknownFields      protoimpl.UnknownFields
	sizeCache          protoimpl.SizeCache
}

func (x *ProtoMessageExtractionConfig) Reset() {
	*x = ProtoMessageExtractionConfig{}
	mi := &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes[0]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *ProtoMessageExtractionConfig) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*ProtoMessageExtractionConfig) ProtoMessage() {}

func (x *ProtoMessageExtractionConfig) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes[0]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use ProtoMessageExtractionConfig.ProtoReflect.Descriptor instead.
func (*ProtoMessageExtractionConfig) Descriptor() ([]byte, []int) {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescGZIP(), []int{0}
}

func (x *ProtoMessageExtractionConfig) GetDescriptorSet() isProtoMessageExtractionConfig_DescriptorSet {
	if x != nil {
		return x.DescriptorSet
	}
	return nil
}

func (x *ProtoMessageExtractionConfig) GetDataSource() *v3.DataSource {
	if x != nil {
		if x, ok := x.DescriptorSet.(*ProtoMessageExtractionConfig_DataSource); ok {
			return x.DataSource
		}
	}
	return nil
}

func (x *ProtoMessageExtractionConfig) GetProtoDescriptorTypedMetadata() string {
	if x != nil {
		if x, ok := x.DescriptorSet.(*ProtoMessageExtractionConfig_ProtoDescriptorTypedMetadata); ok {
			return x.ProtoDescriptorTypedMetadata
		}
	}
	return ""
}

func (x *ProtoMessageExtractionConfig) GetMode() ProtoMessageExtractionConfig_ExtractMode {
	if x != nil {
		return x.Mode
	}
	return ProtoMessageExtractionConfig_ExtractMode_UNSPECIFIED
}

func (x *ProtoMessageExtractionConfig) GetExtractionByMethod() map[string]*MethodExtraction {
	if x != nil {
		return x.ExtractionByMethod
	}
	return nil
}

type isProtoMessageExtractionConfig_DescriptorSet interface {
	isProtoMessageExtractionConfig_DescriptorSet()
}

type ProtoMessageExtractionConfig_DataSource struct {
	// It could be passed by a local file through “Datasource.filename“ or
	// embedded in the “Datasource.inline_bytes“.
	DataSource *v3.DataSource `protobuf:"bytes,1,opt,name=data_source,json=dataSource,proto3,oneof"`
}

type ProtoMessageExtractionConfig_ProtoDescriptorTypedMetadata struct {
	// Unimplemented, the key of proto descriptor TypedMetadata.
	// Among filters depending on the proto descriptor, we can have a
	// TypedMetadata for proto descriptors, so that these filters can share one
	// copy of proto descriptor in memory.
	ProtoDescriptorTypedMetadata string `protobuf:"bytes,2,opt,name=proto_descriptor_typed_metadata,json=protoDescriptorTypedMetadata,proto3,oneof"`
}

func (*ProtoMessageExtractionConfig_DataSource) isProtoMessageExtractionConfig_DescriptorSet() {}

func (*ProtoMessageExtractionConfig_ProtoDescriptorTypedMetadata) isProtoMessageExtractionConfig_DescriptorSet() {
}

// This message can be used to support per route config approach later even
// though the Istio doesn't support that so far.
type MethodExtraction struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// The mapping of field path to its ExtractDirective for request messages
	RequestExtractionByField map[string]MethodExtraction_ExtractDirective `protobuf:"bytes,2,rep,name=request_extraction_by_field,json=requestExtractionByField,proto3" json:"request_extraction_by_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"varint,2,opt,name=value,enum=envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction_ExtractDirective"`
	// The mapping of field path to its ExtractDirective for response messages
	ResponseExtractionByField map[string]MethodExtraction_ExtractDirective `protobuf:"bytes,3,rep,name=response_extraction_by_field,json=responseExtractionByField,proto3" json:"response_extraction_by_field,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"varint,2,opt,name=value,enum=envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction_ExtractDirective"`
	unknownFields             protoimpl.UnknownFields
	sizeCache                 protoimpl.SizeCache
}

func (x *MethodExtraction) Reset() {
	*x = MethodExtraction{}
	mi := &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes[1]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

func (x *MethodExtraction) String() string {
	return protoimpl.X.MessageStringOf(x)
}

func (*MethodExtraction) ProtoMessage() {}

func (x *MethodExtraction) ProtoReflect() protoreflect.Message {
	mi := &file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes[1]
	if x != nil {
		ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
		if ms.LoadMessageInfo() == nil {
			ms.StoreMessageInfo(mi)
		}
		return ms
	}
	return mi.MessageOf(x)
}

// Deprecated: Use MethodExtraction.ProtoReflect.Descriptor instead.
func (*MethodExtraction) Descriptor() ([]byte, []int) {
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescGZIP(), []int{1}
}

func (x *MethodExtraction) GetRequestExtractionByField() map[string]MethodExtraction_ExtractDirective {
	if x != nil {
		return x.RequestExtractionByField
	}
	return nil
}

func (x *MethodExtraction) GetResponseExtractionByField() map[string]MethodExtraction_ExtractDirective {
	if x != nil {
		return x.ResponseExtractionByField
	}
	return nil
}

var File_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto protoreflect.FileDescriptor

const file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDesc = "" +
	"\n" +
	"Fenvoy/extensions/filters/http/proto_message_extraction/v3/config.proto\x129envoy.extensions.filters.http.proto_message_extraction.v3\x1a\x1fenvoy/config/core/v3/base.proto\x1a\x1fxds/annotations/v3/status.proto\x1a\x1dudpa/annotations/status.proto\"\xb0\x05\n" +
	"\x1cProtoMessageExtractionConfig\x12C\n" +
	"\vdata_source\x18\x01 \x01(\v2 .envoy.config.core.v3.DataSourceH\x00R\n" +
	"dataSource\x12G\n" +
	"\x1fproto_descriptor_typed_metadata\x18\x02 \x01(\tH\x00R\x1cprotoDescriptorTypedMetadata\x12w\n" +
	"\x04mode\x18\x03 \x01(\x0e2c.envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractModeR\x04mode\x12\xa1\x01\n" +
	"\x14extraction_by_method\x18\x04 \x03(\v2o.envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractionByMethodEntryR\x12extractionByMethod\x1a\x92\x01\n" +
	"\x17ExtractionByMethodEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12a\n" +
	"\x05value\x18\x02 \x01(\v2K.envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtractionR\x05value:\x028\x01\">\n" +
	"\vExtractMode\x12\x1b\n" +
	"\x17ExtractMode_UNSPECIFIED\x10\x00\x12\x12\n" +
	"\x0eFIRST_AND_LAST\x10\x01B\x10\n" +
	"\x0edescriptor_set\"\xbd\x06\n" +
	"\x10MethodExtraction\x12\xa8\x01\n" +
	"\x1brequest_extraction_by_field\x18\x02 \x03(\v2i.envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.RequestExtractionByFieldEntryR\x18requestExtractionByField\x12\xab\x01\n" +
	"\x1cresponse_extraction_by_field\x18\x03 \x03(\v2j.envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ResponseExtractionByFieldEntryR\x19responseExtractionByField\x1a\xa9\x01\n" +
	"\x1dRequestExtractionByFieldEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12r\n" +
	"\x05value\x18\x02 \x01(\x0e2\\.envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ExtractDirectiveR\x05value:\x028\x01\x1a\xaa\x01\n" +
	"\x1eResponseExtractionByFieldEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12r\n" +
	"\x05value\x18\x02 \x01(\x0e2\\.envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ExtractDirectiveR\x05value:\x028\x01\"w\n" +
	"\x10ExtractDirective\x12 \n" +
	"\x1cExtractDirective_UNSPECIFIED\x10\x00\x12\v\n" +
	"\aEXTRACT\x10\x01\x12\x12\n" +
	"\x0eEXTRACT_REDACT\x10\x02\x12 \n" +
	"\x1cEXTRACT_REPEATED_CARDINALITY\x10\x03B\xe5\x01\xba\x80\xc8\xd1\x06\x02\x10\x02\xd2Ƥ\xe1\x06\x02\b\x01\n" +
	"Gio.envoyproxy.envoy.extensions.filters.http.proto_message_extraction.v3B\vConfigProtoP\x01Z{github.com/envoyproxy/go-control-plane/envoy/extensions/filters/http/proto_message_extraction/v3;proto_message_extractionv3b\x06proto3"

var (
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescOnce sync.Once
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescData []byte
)

func file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescGZIP() []byte {
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescOnce.Do(func() {
		file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDesc), len(file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDesc)))
	})
	return file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDescData
}

var file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
var file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes = make([]protoimpl.MessageInfo, 5)
var file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_goTypes = []any{
	(ProtoMessageExtractionConfig_ExtractMode)(0), // 0: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractMode
	(MethodExtraction_ExtractDirective)(0),        // 1: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ExtractDirective
	(*ProtoMessageExtractionConfig)(nil),          // 2: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig
	(*MethodExtraction)(nil),                      // 3: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction
	nil,                                           // 4: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractionByMethodEntry
	nil,                                           // 5: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.RequestExtractionByFieldEntry
	nil,                                           // 6: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ResponseExtractionByFieldEntry
	(*v3.DataSource)(nil),                         // 7: envoy.config.core.v3.DataSource
}
var file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_depIdxs = []int32{
	7, // 0: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.data_source:type_name -> envoy.config.core.v3.DataSource
	0, // 1: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.mode:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractMode
	4, // 2: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.extraction_by_method:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractionByMethodEntry
	5, // 3: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.request_extraction_by_field:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.RequestExtractionByFieldEntry
	6, // 4: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.response_extraction_by_field:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ResponseExtractionByFieldEntry
	3, // 5: envoy.extensions.filters.http.proto_message_extraction.v3.ProtoMessageExtractionConfig.ExtractionByMethodEntry.value:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction
	1, // 6: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.RequestExtractionByFieldEntry.value:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ExtractDirective
	1, // 7: envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ResponseExtractionByFieldEntry.value:type_name -> envoy.extensions.filters.http.proto_message_extraction.v3.MethodExtraction.ExtractDirective
	8, // [8:8] is the sub-list for method output_type
	8, // [8:8] is the sub-list for method input_type
	8, // [8:8] is the sub-list for extension type_name
	8, // [8:8] is the sub-list for extension extendee
	0, // [0:8] is the sub-list for field type_name
}

func init() { file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_init() }
func file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_init() {
	if File_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto != nil {
		return
	}
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes[0].OneofWrappers = []any{
		(*ProtoMessageExtractionConfig_DataSource)(nil),
		(*ProtoMessageExtractionConfig_ProtoDescriptorTypedMetadata)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDesc), len(file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_rawDesc)),
			NumEnums:      2,
			NumMessages:   5,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_goTypes,
		DependencyIndexes: file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_depIdxs,
		EnumInfos:         file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_enumTypes,
		MessageInfos:      file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_msgTypes,
	}.Build()
	File_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto = out.File
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_goTypes = nil
	file_envoy_extensions_filters_http_proto_message_extraction_v3_config_proto_depIdxs = nil
}
