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

package logging

import (
	_ "github.com/yandex-cloud/go-genproto/yandex/cloud"
	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 ReadRequest struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Read selector.
	//
	// Types that are valid to be assigned to Selector:
	//
	//	*ReadRequest_PageToken
	//	*ReadRequest_Criteria
	Selector      isReadRequest_Selector `protobuf_oneof:"selector"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*ReadRequest) ProtoMessage() {}

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

func (x *ReadRequest) GetSelector() isReadRequest_Selector {
	if x != nil {
		return x.Selector
	}
	return nil
}

func (x *ReadRequest) GetPageToken() string {
	if x != nil {
		if x, ok := x.Selector.(*ReadRequest_PageToken); ok {
			return x.PageToken
		}
	}
	return ""
}

func (x *ReadRequest) GetCriteria() *Criteria {
	if x != nil {
		if x, ok := x.Selector.(*ReadRequest_Criteria); ok {
			return x.Criteria
		}
	}
	return nil
}

type isReadRequest_Selector interface {
	isReadRequest_Selector()
}

type ReadRequest_PageToken struct {
	// Page token. To get the next page of results, set `page_token` to the
	// [ReadResponse.next_page_token] or [ReadResponse.previous_page_token] returned by a previous read request.
	PageToken string `protobuf:"bytes,1,opt,name=page_token,json=pageToken,proto3,oneof"`
}

type ReadRequest_Criteria struct {
	// Read criteria.
	//
	// See [Criteria] for details.
	Criteria *Criteria `protobuf:"bytes,2,opt,name=criteria,proto3,oneof"`
}

func (*ReadRequest_PageToken) isReadRequest_Selector() {}

func (*ReadRequest_Criteria) isReadRequest_Selector() {}

type ReadResponse struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// Log group ID the read was performed from.
	LogGroupId string `protobuf:"bytes,1,opt,name=log_group_id,json=logGroupId,proto3" json:"log_group_id,omitempty"`
	// List of matching log entries.
	Entries []*LogEntry `protobuf:"bytes,2,rep,name=entries,proto3" json:"entries,omitempty"`
	// Token for getting the next page of the log entries.
	//
	// After getting log entries initially with [Criteria], you can use `next_page_token` as the value
	// for the [ReadRequest.page_token] parameter in the next read request.
	//
	// Each subsequent page will have its own `next_page_token` to continue paging through the results.
	NextPageToken string `protobuf:"bytes,3,opt,name=next_page_token,json=nextPageToken,proto3" json:"next_page_token,omitempty"`
	// Token for getting the previous page of the log entries.
	//
	// After getting log entries initially with [Criteria], you can use `previous_page_token` as the value
	// for the [ReadRequest.page_token] parameter in the next read request.
	//
	// Each subsequent page will have its own `next_page_token` to continue paging through the results.
	PreviousPageToken string `protobuf:"bytes,4,opt,name=previous_page_token,json=previousPageToken,proto3" json:"previous_page_token,omitempty"`
	unknownFields     protoimpl.UnknownFields
	sizeCache         protoimpl.SizeCache
}

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

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

func (*ReadResponse) ProtoMessage() {}

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

func (x *ReadResponse) GetLogGroupId() string {
	if x != nil {
		return x.LogGroupId
	}
	return ""
}

func (x *ReadResponse) GetEntries() []*LogEntry {
	if x != nil {
		return x.Entries
	}
	return nil
}

func (x *ReadResponse) GetNextPageToken() string {
	if x != nil {
		return x.NextPageToken
	}
	return ""
}

func (x *ReadResponse) GetPreviousPageToken() string {
	if x != nil {
		return x.PreviousPageToken
	}
	return ""
}

// Read criteria. Should be used in initial [ReadRequest].
type Criteria struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// ID of the log group to return.
	//
	// To get a log group ID make a [LogGroupService.List] request.
	LogGroupId string `protobuf:"bytes,1,opt,name=log_group_id,json=logGroupId,proto3" json:"log_group_id,omitempty"`
	// List of resource types to limit log entries to.
	//
	// Empty list disables filter.
	ResourceTypes []string `protobuf:"bytes,2,rep,name=resource_types,json=resourceTypes,proto3" json:"resource_types,omitempty"`
	// List of resource IDs to limit log entries to.
	//
	// Empty list disables filter.
	ResourceIds []string `protobuf:"bytes,3,rep,name=resource_ids,json=resourceIds,proto3" json:"resource_ids,omitempty"`
	// Lower bound of log entries timestamps.
	Since *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=since,proto3" json:"since,omitempty"`
	// Upper bound of log entries timestamps.
	Until *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=until,proto3" json:"until,omitempty"`
	// List of log levels to limit log entries to.
	//
	// Empty list disables filter.
	Levels []LogLevel_Level `protobuf:"varint,6,rep,packed,name=levels,proto3,enum=yandex.cloud.logging.v1.LogLevel_Level" json:"levels,omitempty"`
	// Filter expression. For details about filtering, see [documentation](/docs/logging/concepts/filter).
	Filter string `protobuf:"bytes,7,opt,name=filter,proto3" json:"filter,omitempty"`
	// List of stream names to limit log entries to.
	//
	// Empty list disables filter.
	StreamNames []string `protobuf:"bytes,10,rep,name=stream_names,json=streamNames,proto3" json:"stream_names,omitempty"`
	// The maximum number of results per page to return.
	PageSize int64 `protobuf:"varint,8,opt,name=page_size,json=pageSize,proto3" json:"page_size,omitempty"`
	// Limits response to maximum size in bytes. Prevents gRPC resource exhaustion.
	//
	// Default value for max response size is 3.5 MiB
	MaxResponseSize int64 `protobuf:"varint,9,opt,name=max_response_size,json=maxResponseSize,proto3" json:"max_response_size,omitempty"`
	unknownFields   protoimpl.UnknownFields
	sizeCache       protoimpl.SizeCache
}

func (x *Criteria) Reset() {
	*x = Criteria{}
	mi := &file_yandex_cloud_logging_v1_log_reading_service_proto_msgTypes[2]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*Criteria) ProtoMessage() {}

func (x *Criteria) ProtoReflect() protoreflect.Message {
	mi := &file_yandex_cloud_logging_v1_log_reading_service_proto_msgTypes[2]
	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 Criteria.ProtoReflect.Descriptor instead.
func (*Criteria) Descriptor() ([]byte, []int) {
	return file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescGZIP(), []int{2}
}

func (x *Criteria) GetLogGroupId() string {
	if x != nil {
		return x.LogGroupId
	}
	return ""
}

func (x *Criteria) GetResourceTypes() []string {
	if x != nil {
		return x.ResourceTypes
	}
	return nil
}

func (x *Criteria) GetResourceIds() []string {
	if x != nil {
		return x.ResourceIds
	}
	return nil
}

func (x *Criteria) GetSince() *timestamppb.Timestamp {
	if x != nil {
		return x.Since
	}
	return nil
}

func (x *Criteria) GetUntil() *timestamppb.Timestamp {
	if x != nil {
		return x.Until
	}
	return nil
}

func (x *Criteria) GetLevels() []LogLevel_Level {
	if x != nil {
		return x.Levels
	}
	return nil
}

func (x *Criteria) GetFilter() string {
	if x != nil {
		return x.Filter
	}
	return ""
}

func (x *Criteria) GetStreamNames() []string {
	if x != nil {
		return x.StreamNames
	}
	return nil
}

func (x *Criteria) GetPageSize() int64 {
	if x != nil {
		return x.PageSize
	}
	return 0
}

func (x *Criteria) GetMaxResponseSize() int64 {
	if x != nil {
		return x.MaxResponseSize
	}
	return 0
}

var File_yandex_cloud_logging_v1_log_reading_service_proto protoreflect.FileDescriptor

const file_yandex_cloud_logging_v1_log_reading_service_proto_rawDesc = "" +
	"\n" +
	"1yandex/cloud/logging/v1/log_reading_service.proto\x12\x17yandex.cloud.logging.v1\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1dyandex/cloud/validation.proto\x1a'yandex/cloud/logging/v1/log_entry.proto\"{\n" +
	"\vReadRequest\x12\x1f\n" +
	"\n" +
	"page_token\x18\x01 \x01(\tH\x00R\tpageToken\x12?\n" +
	"\bcriteria\x18\x02 \x01(\v2!.yandex.cloud.logging.v1.CriteriaH\x00R\bcriteriaB\n" +
	"\n" +
	"\bselector\"\xc5\x01\n" +
	"\fReadResponse\x12 \n" +
	"\flog_group_id\x18\x01 \x01(\tR\n" +
	"logGroupId\x12;\n" +
	"\aentries\x18\x02 \x03(\v2!.yandex.cloud.logging.v1.LogEntryR\aentries\x12&\n" +
	"\x0fnext_page_token\x18\x03 \x01(\tR\rnextPageToken\x12.\n" +
	"\x13previous_page_token\x18\x04 \x01(\tR\x11previousPageToken\"\x98\x04\n" +
	"\bCriteria\x12.\n" +
	"\flog_group_id\x18\x01 \x01(\tB\f\xe8\xc71\x01\x8a\xc81\x04<=64R\n" +
	"logGroupId\x128\n" +
	"\x0eresource_types\x18\x02 \x03(\tB\x11\x82\xc81\x05<=100\x8a\xc81\x04<=63R\rresourceTypes\x124\n" +
	"\fresource_ids\x18\x03 \x03(\tB\x11\x82\xc81\x05<=100\x8a\xc81\x04<=63R\vresourceIds\x120\n" +
	"\x05since\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\x05since\x120\n" +
	"\x05until\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\x05until\x12I\n" +
	"\x06levels\x18\x06 \x03(\x0e2'.yandex.cloud.logging.v1.LogLevel.LevelB\b\x82\xc81\x04<=10R\x06levels\x12\"\n" +
	"\x06filter\x18\a \x01(\tB\n" +
	"\x8a\xc81\x06<=1000R\x06filter\x124\n" +
	"\fstream_names\x18\n" +
	" \x03(\tB\x11\x82\xc81\x05<=100\x8a\xc81\x04<=63R\vstreamNames\x12'\n" +
	"\tpage_size\x18\b \x01(\x03B\n" +
	"\xfa\xc71\x060-1000R\bpageSize\x12:\n" +
	"\x11max_response_size\x18\t \x01(\x03B\x0e\xfa\xc71\n" +
	"0-10485760R\x0fmaxResponseSize2h\n" +
	"\x11LogReadingService\x12S\n" +
	"\x04Read\x12$.yandex.cloud.logging.v1.ReadRequest\x1a%.yandex.cloud.logging.v1.ReadResponseBb\n" +
	"\x1byandex.cloud.api.logging.v1ZCgithub.com/yandex-cloud/go-genproto/yandex/cloud/logging/v1;loggingb\x06proto3"

var (
	file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescOnce sync.Once
	file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescData []byte
)

func file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescGZIP() []byte {
	file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescOnce.Do(func() {
		file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_yandex_cloud_logging_v1_log_reading_service_proto_rawDesc), len(file_yandex_cloud_logging_v1_log_reading_service_proto_rawDesc)))
	})
	return file_yandex_cloud_logging_v1_log_reading_service_proto_rawDescData
}

var file_yandex_cloud_logging_v1_log_reading_service_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
var file_yandex_cloud_logging_v1_log_reading_service_proto_goTypes = []any{
	(*ReadRequest)(nil),           // 0: yandex.cloud.logging.v1.ReadRequest
	(*ReadResponse)(nil),          // 1: yandex.cloud.logging.v1.ReadResponse
	(*Criteria)(nil),              // 2: yandex.cloud.logging.v1.Criteria
	(*LogEntry)(nil),              // 3: yandex.cloud.logging.v1.LogEntry
	(*timestamppb.Timestamp)(nil), // 4: google.protobuf.Timestamp
	(LogLevel_Level)(0),           // 5: yandex.cloud.logging.v1.LogLevel.Level
}
var file_yandex_cloud_logging_v1_log_reading_service_proto_depIdxs = []int32{
	2, // 0: yandex.cloud.logging.v1.ReadRequest.criteria:type_name -> yandex.cloud.logging.v1.Criteria
	3, // 1: yandex.cloud.logging.v1.ReadResponse.entries:type_name -> yandex.cloud.logging.v1.LogEntry
	4, // 2: yandex.cloud.logging.v1.Criteria.since:type_name -> google.protobuf.Timestamp
	4, // 3: yandex.cloud.logging.v1.Criteria.until:type_name -> google.protobuf.Timestamp
	5, // 4: yandex.cloud.logging.v1.Criteria.levels:type_name -> yandex.cloud.logging.v1.LogLevel.Level
	0, // 5: yandex.cloud.logging.v1.LogReadingService.Read:input_type -> yandex.cloud.logging.v1.ReadRequest
	1, // 6: yandex.cloud.logging.v1.LogReadingService.Read:output_type -> yandex.cloud.logging.v1.ReadResponse
	6, // [6:7] is the sub-list for method output_type
	5, // [5:6] 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_logging_v1_log_reading_service_proto_init() }
func file_yandex_cloud_logging_v1_log_reading_service_proto_init() {
	if File_yandex_cloud_logging_v1_log_reading_service_proto != nil {
		return
	}
	file_yandex_cloud_logging_v1_log_entry_proto_init()
	file_yandex_cloud_logging_v1_log_reading_service_proto_msgTypes[0].OneofWrappers = []any{
		(*ReadRequest_PageToken)(nil),
		(*ReadRequest_Criteria)(nil),
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_yandex_cloud_logging_v1_log_reading_service_proto_rawDesc), len(file_yandex_cloud_logging_v1_log_reading_service_proto_rawDesc)),
			NumEnums:      0,
			NumMessages:   3,
			NumExtensions: 0,
			NumServices:   1,
		},
		GoTypes:           file_yandex_cloud_logging_v1_log_reading_service_proto_goTypes,
		DependencyIndexes: file_yandex_cloud_logging_v1_log_reading_service_proto_depIdxs,
		MessageInfos:      file_yandex_cloud_logging_v1_log_reading_service_proto_msgTypes,
	}.Build()
	File_yandex_cloud_logging_v1_log_reading_service_proto = out.File
	file_yandex_cloud_logging_v1_log_reading_service_proto_goTypes = nil
	file_yandex_cloud_logging_v1_log_reading_service_proto_depIdxs = nil
}
