// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.6
// 	protoc        v3.21.12
// source: yandex/cloud/serverless/eventrouter/v1/bus.proto

package eventrouter

import (
	_ "github.com/yandex-cloud/go-genproto/yandex/cloud"
	v1 "github.com/yandex-cloud/go-genproto/yandex/cloud/logging/v1"
	protoreflect "google.golang.org/protobuf/reflect/protoreflect"
	protoimpl "google.golang.org/protobuf/runtime/protoimpl"
	timestamppb "google.golang.org/protobuf/types/known/timestamppb"
	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 Bus_Status int32

const (
	Bus_STATUS_UNSPECIFIED Bus_Status = 0
	Bus_CREATING           Bus_Status = 1
	Bus_ACTIVE             Bus_Status = 2
	Bus_DELETING           Bus_Status = 3
)

// Enum value maps for Bus_Status.
var (
	Bus_Status_name = map[int32]string{
		0: "STATUS_UNSPECIFIED",
		1: "CREATING",
		2: "ACTIVE",
		3: "DELETING",
	}
	Bus_Status_value = map[string]int32{
		"STATUS_UNSPECIFIED": 0,
		"CREATING":           1,
		"ACTIVE":             2,
		"DELETING":           3,
	}
)

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

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

func (Bus_Status) Descriptor() protoreflect.EnumDescriptor {
	return file_yandex_cloud_serverless_eventrouter_v1_bus_proto_enumTypes[0].Descriptor()
}

func (Bus_Status) Type() protoreflect.EnumType {
	return &file_yandex_cloud_serverless_eventrouter_v1_bus_proto_enumTypes[0]
}

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

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

type LogOptions struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Log entries destination.
	//
	// Types that are valid to be assigned to Destination:
	//
	//	*LogOptions_LogGroupId
	//	*LogOptions_FolderId
	Destination isLogOptions_Destination `protobuf_oneof:"destination"`
	// Minimum log entry level.
	//
	// See [LogLevel.Level] for details.
	MinLevel      v1.LogLevel_Level `protobuf:"varint,3,opt,name=min_level,json=minLevel,proto3,enum=yandex.cloud.logging.v1.LogLevel_Level" json:"min_level,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*LogOptions) ProtoMessage() {}

func (x *LogOptions) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_serverless_eventrouter_v1_bus_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 LogOptions.ProtoReflect.Descriptor instead.
func (*LogOptions) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescGZIP(), []int{0}
}

func (x *LogOptions) GetDestination() isLogOptions_Destination {
	if x != nil {
		return x.Destination
	}
	return nil
}

func (x *LogOptions) GetLogGroupId() string {
	if x != nil {
		if x, ok := x.Destination.(*LogOptions_LogGroupId); ok {
			return x.LogGroupId
		}
	}
	return ""
}

func (x *LogOptions) GetFolderId() string {
	if x != nil {
		if x, ok := x.Destination.(*LogOptions_FolderId); ok {
			return x.FolderId
		}
	}
	return ""
}

func (x *LogOptions) GetMinLevel() v1.LogLevel_Level {
	if x != nil {
		return x.MinLevel
	}
	return v1.LogLevel_Level(0)
}

type isLogOptions_Destination interface {
	isLogOptions_Destination()
}

type LogOptions_LogGroupId struct {
	// Entry will be written to log group resolved by ID.
	LogGroupId string `protobuf:"bytes,1,opt,name=log_group_id,json=logGroupId,proto3,oneof"`
}

type LogOptions_FolderId struct {
	// Entry will be written to default log group for specified folder.
	FolderId string `protobuf:"bytes,2,opt,name=folder_id,json=folderId,proto3,oneof"`
}

func (*LogOptions_LogGroupId) isLogOptions_Destination() {}

func (*LogOptions_FolderId) isLogOptions_Destination() {}

type Bus struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// ID of the bus.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// ID of the folder that the bus belongs to.
	FolderId string `protobuf:"bytes,2,opt,name=folder_id,json=folderId,proto3" json:"folder_id,omitempty"`
	// ID of the cloud that the bus resides in.
	CloudId string `protobuf:"bytes,3,opt,name=cloud_id,json=cloudId,proto3" json:"cloud_id,omitempty"`
	// Creation timestamp.
	CreatedAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
	// Name of the bus.
	Name string `protobuf:"bytes,5,opt,name=name,proto3" json:"name,omitempty"`
	// Description of the bus.
	Description string `protobuf:"bytes,6,opt,name=description,proto3" json:"description,omitempty"`
	// Resource labels as `key:value` pairs.
	Labels map[string]string `protobuf:"bytes,7,rep,name=labels,proto3" json:"labels,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
	// Deletion protection.
	DeletionProtection bool `protobuf:"varint,8,opt,name=deletion_protection,json=deletionProtection,proto3" json:"deletion_protection,omitempty"`
	// Status of the bus.
	Status Bus_Status `protobuf:"varint,9,opt,name=status,proto3,enum=yandex.cloud.serverless.eventrouter.v1.Bus_Status" json:"status,omitempty"`
	// Is logging from the bus enabled.
	LoggingEnabled bool `protobuf:"varint,10,opt,name=logging_enabled,json=loggingEnabled,proto3" json:"logging_enabled,omitempty"`
	// Options for logging from the bus.
	LogOptions    *LogOptions `protobuf:"bytes,11,opt,name=log_options,json=logOptions,proto3" json:"log_options,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*Bus) ProtoMessage() {}

func (x *Bus) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_serverless_eventrouter_v1_bus_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 Bus.ProtoReflect.Descriptor instead.
func (*Bus) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescGZIP(), []int{1}
}

func (x *Bus) GetId() string {
	if x != nil {
		return x.Id
	}
	return ""
}

func (x *Bus) GetFolderId() string {
	if x != nil {
		return x.FolderId
	}
	return ""
}

func (x *Bus) GetCloudId() string {
	if x != nil {
		return x.CloudId
	}
	return ""
}

func (x *Bus) GetCreatedAt() *timestamppb.Timestamp {
	if x != nil {
		return x.CreatedAt
	}
	return nil
}

func (x *Bus) GetName() string {
	if x != nil {
		return x.Name
	}
	return ""
}

func (x *Bus) GetDescription() string {
	if x != nil {
		return x.Description
	}
	return ""
}

func (x *Bus) GetLabels() map[string]string {
	if x != nil {
		return x.Labels
	}
	return nil
}

func (x *Bus) GetDeletionProtection() bool {
	if x != nil {
		return x.DeletionProtection
	}
	return false
}

func (x *Bus) GetStatus() Bus_Status {
	if x != nil {
		return x.Status
	}
	return Bus_STATUS_UNSPECIFIED
}

func (x *Bus) GetLoggingEnabled() bool {
	if x != nil {
		return x.LoggingEnabled
	}
	return false
}

func (x *Bus) GetLogOptions() *LogOptions {
	if x != nil {
		return x.LogOptions
	}
	return nil
}

var File_yandex_cloud_serverless_eventrouter_v1_bus_proto protoreflect.FileDescriptor

const file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDesc = "" +
	"\n" +
	"0yandex/cloud/serverless/eventrouter/v1/bus.proto\x12&yandex.cloud.serverless.eventrouter.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a'yandex/cloud/logging/v1/log_entry.proto\x1a\x1dyandex/cloud/validation.proto\"\xbe\x01\n" +
	"\n" +
	"LogOptions\x12,\n" +
	"\flog_group_id\x18\x01 \x01(\tB\b\x8a\xc81\x04<=50H\x00R\n" +
	"logGroupId\x12'\n" +
	"\tfolder_id\x18\x02 \x01(\tB\b\x8a\xc81\x04<=50H\x00R\bfolderId\x12D\n" +
	"\tmin_level\x18\x03 \x01(\x0e2'.yandex.cloud.logging.v1.LogLevel.LevelR\bminLevelB\r\n" +
	"\vdestinationJ\x04\b\x04\x10\x05\"\x8f\x05\n" +
	"\x03Bus\x12\x0e\n" +
	"\x02id\x18\x01 \x01(\tR\x02id\x12\x1b\n" +
	"\tfolder_id\x18\x02 \x01(\tR\bfolderId\x12\x19\n" +
	"\bcloud_id\x18\x03 \x01(\tR\acloudId\x129\n" +
	"\n" +
	"created_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\tcreatedAt\x12\x12\n" +
	"\x04name\x18\x05 \x01(\tR\x04name\x12 \n" +
	"\vdescription\x18\x06 \x01(\tR\vdescription\x12O\n" +
	"\x06labels\x18\a \x03(\v27.yandex.cloud.serverless.eventrouter.v1.Bus.LabelsEntryR\x06labels\x12/\n" +
	"\x13deletion_protection\x18\b \x01(\bR\x12deletionProtection\x12J\n" +
	"\x06status\x18\t \x01(\x0e22.yandex.cloud.serverless.eventrouter.v1.Bus.StatusR\x06status\x12'\n" +
	"\x0flogging_enabled\x18\n" +
	" \x01(\bR\x0eloggingEnabled\x12S\n" +
	"\vlog_options\x18\v \x01(\v22.yandex.cloud.serverless.eventrouter.v1.LogOptionsR\n" +
	"logOptions\x1a9\n" +
	"\vLabelsEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" +
	"\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"H\n" +
	"\x06Status\x12\x16\n" +
	"\x12STATUS_UNSPECIFIED\x10\x00\x12\f\n" +
	"\bCREATING\x10\x01\x12\n" +
	"\n" +
	"\x06ACTIVE\x10\x02\x12\f\n" +
	"\bDELETING\x10\x03B\x8a\x01\n" +
	"*yandex.cloud.api.serverless.eventrouter.v1B\x04PERBZVgithub.com/yandex-cloud/go-genproto/yandex/cloud/serverless/eventrouter/v1;eventrouterb\x06proto3"

var (
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescOnce sync.Once
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescData []byte
)

func file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescGZIP() []byte {
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescOnce.Do(func() {
		file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDesc), len(file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDesc)))
	})
	return file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDescData
}

var file_yandex_cloud_serverless_eventrouter_v1_bus_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_yandex_cloud_serverless_eventrouter_v1_bus_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_yandex_cloud_serverless_eventrouter_v1_bus_proto_goTypes = []any{
	(Bus_Status)(0),               // 0: yandex.cloud.serverless.eventrouter.v1.Bus.Status
	(*LogOptions)(nil),            // 1: yandex.cloud.serverless.eventrouter.v1.LogOptions
	(*Bus)(nil),                   // 2: yandex.cloud.serverless.eventrouter.v1.Bus
	nil,                           // 3: yandex.cloud.serverless.eventrouter.v1.Bus.LabelsEntry
	(v1.LogLevel_Level)(0),        // 4: yandex.cloud.logging.v1.LogLevel.Level
	(*timestamppb.Timestamp)(nil), // 5: google.protobuf.Timestamp
}
var file_yandex_cloud_serverless_eventrouter_v1_bus_proto_depIdxs = []int32{
	4, // 0: yandex.cloud.serverless.eventrouter.v1.LogOptions.min_level:type_name -> yandex.cloud.logging.v1.LogLevel.Level
	5, // 1: yandex.cloud.serverless.eventrouter.v1.Bus.created_at:type_name -> google.protobuf.Timestamp
	3, // 2: yandex.cloud.serverless.eventrouter.v1.Bus.labels:type_name -> yandex.cloud.serverless.eventrouter.v1.Bus.LabelsEntry
	0, // 3: yandex.cloud.serverless.eventrouter.v1.Bus.status:type_name -> yandex.cloud.serverless.eventrouter.v1.Bus.Status
	1, // 4: yandex.cloud.serverless.eventrouter.v1.Bus.log_options:type_name -> yandex.cloud.serverless.eventrouter.v1.LogOptions
	5, // [5:5] is the sub-list for method output_type
	5, // [5:5] is the sub-list for method input_type
	5, // [5:5] is the sub-list for extension type_name
	5, // [5:5] is the sub-list for extension extendee
	0, // [0:5] is the sub-list for field type_name
}

func init() { file_yandex_cloud_serverless_eventrouter_v1_bus_proto_init() }
func file_yandex_cloud_serverless_eventrouter_v1_bus_proto_init() {
	if File_yandex_cloud_serverless_eventrouter_v1_bus_proto != nil {
		return
	}
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_msgTypes[0].OneofWrappers = []any{
		(*LogOptions_LogGroupId)(nil),
		(*LogOptions_FolderId)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDesc), len(file_yandex_cloud_serverless_eventrouter_v1_bus_proto_rawDesc)),
			NumEnums:      1,
			NumMessages:   3,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_yandex_cloud_serverless_eventrouter_v1_bus_proto_goTypes,
		DependencyIndexes: file_yandex_cloud_serverless_eventrouter_v1_bus_proto_depIdxs,
		EnumInfos:         file_yandex_cloud_serverless_eventrouter_v1_bus_proto_enumTypes,
		MessageInfos:      file_yandex_cloud_serverless_eventrouter_v1_bus_proto_msgTypes,
	}.Build()
	File_yandex_cloud_serverless_eventrouter_v1_bus_proto = out.File
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_goTypes = nil
	file_yandex_cloud_serverless_eventrouter_v1_bus_proto_depIdxs = nil
}
