// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// 	protoc-gen-go v1.36.11
// 	protoc        (unknown)
// source: silence.proto

package silencepb

import (
	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 specifies how the given name and pattern are matched
// against a label set.
type Matcher_Type int32

const (
	Matcher_EQUAL      Matcher_Type = 0
	Matcher_REGEXP     Matcher_Type = 1
	Matcher_NOT_EQUAL  Matcher_Type = 2
	Matcher_NOT_REGEXP Matcher_Type = 3
)

// Enum value maps for Matcher_Type.
var (
	Matcher_Type_name = map[int32]string{
		0: "EQUAL",
		1: "REGEXP",
		2: "NOT_EQUAL",
		3: "NOT_REGEXP",
	}
	Matcher_Type_value = map[string]int32{
		"EQUAL":      0,
		"REGEXP":     1,
		"NOT_EQUAL":  2,
		"NOT_REGEXP": 3,
	}
)

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

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

func (Matcher_Type) Descriptor() protoreflect.EnumDescriptor {
	return file_silence_proto_enumTypes[0].Descriptor()
}

func (Matcher_Type) Type() protoreflect.EnumType {
	return &file_silence_proto_enumTypes[0]
}

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

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

// Matcher specifies a rule, which can match or set of labels or not.
type Matcher struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	Type  Matcher_Type           `protobuf:"varint,1,opt,name=type,proto3,enum=silencepb.Matcher_Type" json:"type,omitempty"`
	// The label name in a label set to against which the matcher
	// checks the pattern.
	Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
	// The pattern being checked according to the matcher's type.
	Pattern       string `protobuf:"bytes,3,opt,name=pattern,proto3" json:"pattern,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*Matcher) ProtoMessage() {}

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

func (x *Matcher) GetType() Matcher_Type {
	if x != nil {
		return x.Type
	}
	return Matcher_EQUAL
}

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

func (x *Matcher) GetPattern() string {
	if x != nil {
		return x.Pattern
	}
	return ""
}

// DEPRECATED: A comment can be attached to a silence.
type Comment struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Author        string                 `protobuf:"bytes,1,opt,name=author,proto3" json:"author,omitempty"`
	Comment       string                 `protobuf:"bytes,2,opt,name=comment,proto3" json:"comment,omitempty"`
	Timestamp     *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*Comment) ProtoMessage() {}

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

func (x *Comment) GetAuthor() string {
	if x != nil {
		return x.Author
	}
	return ""
}

func (x *Comment) GetComment() string {
	if x != nil {
		return x.Comment
	}
	return ""
}

func (x *Comment) GetTimestamp() *timestamppb.Timestamp {
	if x != nil {
		return x.Timestamp
	}
	return nil
}

// MatcherSet is a set of matchers all of which have to be true
// for a silence to affect a given label set.
type MatcherSet struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Matchers      []*Matcher             `protobuf:"bytes,1,rep,name=matchers,proto3" json:"matchers,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

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

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

func (*MatcherSet) ProtoMessage() {}

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

func (x *MatcherSet) GetMatchers() []*Matcher {
	if x != nil {
		return x.Matchers
	}
	return nil
}

// Silence specifies an object that ignores alerts based
// on a set of matchers during a given time frame.
type Silence struct {
	state protoimpl.MessageState `protogen:"open.v1"`
	// A globally unique identifier.
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// A set of matchers all of which have to be true for a silence
	// to affect a given label set. For silences with matcher_sets,
	// this is expected to be equal to the first entry in matcher_sets
	Matchers []*Matcher `protobuf:"bytes,2,rep,name=matchers,proto3" json:"matchers,omitempty"`
	// The time range during which the silence is active.
	StartsAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=starts_at,json=startsAt,proto3" json:"starts_at,omitempty"`
	EndsAt   *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=ends_at,json=endsAt,proto3" json:"ends_at,omitempty"`
	// The last notification made to the silence.
	UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,5,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
	// DEPRECATED: A set of comments made on the silence.
	Comments []*Comment `protobuf:"bytes,7,rep,name=comments,proto3" json:"comments,omitempty"`
	// Comment for the silence.
	CreatedBy string `protobuf:"bytes,8,opt,name=created_by,json=createdBy,proto3" json:"created_by,omitempty"`
	Comment   string `protobuf:"bytes,9,opt,name=comment,proto3" json:"comment,omitempty"`
	// Additional structured information about the silence
	Annotations map[string]string `protobuf:"bytes,10,rep,name=annotations,proto3" json:"annotations,omitempty" protobuf_key:"bytes,1,opt,name=key" protobuf_val:"bytes,2,opt,name=value"`
	// Multiple matcher sets with OR logic between them.
	// At least one matcher set must match for the silence to apply.
	MatcherSets   []*MatcherSet `protobuf:"bytes,11,rep,name=matcher_sets,json=matcherSets,proto3" json:"matcher_sets,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *Silence) Reset() {
	*x = Silence{}
	mi := &file_silence_proto_msgTypes[3]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*Silence) ProtoMessage() {}

func (x *Silence) ProtoReflect() protoreflect.Message {
	mi := &file_silence_proto_msgTypes[3]
	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 Silence.ProtoReflect.Descriptor instead.
func (*Silence) Descriptor() ([]byte, []int) {
	return file_silence_proto_rawDescGZIP(), []int{3}
}

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

func (x *Silence) GetMatchers() []*Matcher {
	if x != nil {
		return x.Matchers
	}
	return nil
}

func (x *Silence) GetStartsAt() *timestamppb.Timestamp {
	if x != nil {
		return x.StartsAt
	}
	return nil
}

func (x *Silence) GetEndsAt() *timestamppb.Timestamp {
	if x != nil {
		return x.EndsAt
	}
	return nil
}

func (x *Silence) GetUpdatedAt() *timestamppb.Timestamp {
	if x != nil {
		return x.UpdatedAt
	}
	return nil
}

func (x *Silence) GetComments() []*Comment {
	if x != nil {
		return x.Comments
	}
	return nil
}

func (x *Silence) GetCreatedBy() string {
	if x != nil {
		return x.CreatedBy
	}
	return ""
}

func (x *Silence) GetComment() string {
	if x != nil {
		return x.Comment
	}
	return ""
}

func (x *Silence) GetAnnotations() map[string]string {
	if x != nil {
		return x.Annotations
	}
	return nil
}

func (x *Silence) GetMatcherSets() []*MatcherSet {
	if x != nil {
		return x.MatcherSets
	}
	return nil
}

// MeshSilence wraps a regular silence with an expiration timestamp
// after which the silence may be garbage collected.
type MeshSilence struct {
	state         protoimpl.MessageState `protogen:"open.v1"`
	Silence       *Silence               `protobuf:"bytes,1,opt,name=silence,proto3" json:"silence,omitempty"`
	ExpiresAt     *timestamppb.Timestamp `protobuf:"bytes,2,opt,name=expires_at,json=expiresAt,proto3" json:"expires_at,omitempty"`
	unknownFields protoimpl.UnknownFields
	sizeCache     protoimpl.SizeCache
}

func (x *MeshSilence) Reset() {
	*x = MeshSilence{}
	mi := &file_silence_proto_msgTypes[4]
	ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
	ms.StoreMessageInfo(mi)
}

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

func (*MeshSilence) ProtoMessage() {}

func (x *MeshSilence) ProtoReflect() protoreflect.Message {
	mi := &file_silence_proto_msgTypes[4]
	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 MeshSilence.ProtoReflect.Descriptor instead.
func (*MeshSilence) Descriptor() ([]byte, []int) {
	return file_silence_proto_rawDescGZIP(), []int{4}
}

func (x *MeshSilence) GetSilence() *Silence {
	if x != nil {
		return x.Silence
	}
	return nil
}

func (x *MeshSilence) GetExpiresAt() *timestamppb.Timestamp {
	if x != nil {
		return x.ExpiresAt
	}
	return nil
}

var File_silence_proto protoreflect.FileDescriptor

const file_silence_proto_rawDesc = "" +
	"\n" +
	"\rsilence.proto\x12\tsilencepb\x1a\x1fgoogle/protobuf/timestamp.proto\"\xa2\x01\n" +
	"\aMatcher\x12+\n" +
	"\x04type\x18\x01 \x01(\x0e2\x17.silencepb.Matcher.TypeR\x04type\x12\x12\n" +
	"\x04name\x18\x02 \x01(\tR\x04name\x12\x18\n" +
	"\apattern\x18\x03 \x01(\tR\apattern\"<\n" +
	"\x04Type\x12\t\n" +
	"\x05EQUAL\x10\x00\x12\n" +
	"\n" +
	"\x06REGEXP\x10\x01\x12\r\n" +
	"\tNOT_EQUAL\x10\x02\x12\x0e\n" +
	"\n" +
	"NOT_REGEXP\x10\x03\"u\n" +
	"\aComment\x12\x16\n" +
	"\x06author\x18\x01 \x01(\tR\x06author\x12\x18\n" +
	"\acomment\x18\x02 \x01(\tR\acomment\x128\n" +
	"\ttimestamp\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampR\ttimestamp\"<\n" +
	"\n" +
	"MatcherSet\x12.\n" +
	"\bmatchers\x18\x01 \x03(\v2\x12.silencepb.MatcherR\bmatchers\"\x9c\x04\n" +
	"\aSilence\x12\x0e\n" +
	"\x02id\x18\x01 \x01(\tR\x02id\x12.\n" +
	"\bmatchers\x18\x02 \x03(\v2\x12.silencepb.MatcherR\bmatchers\x127\n" +
	"\tstarts_at\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampR\bstartsAt\x123\n" +
	"\aends_at\x18\x04 \x01(\v2\x1a.google.protobuf.TimestampR\x06endsAt\x129\n" +
	"\n" +
	"updated_at\x18\x05 \x01(\v2\x1a.google.protobuf.TimestampR\tupdatedAt\x12.\n" +
	"\bcomments\x18\a \x03(\v2\x12.silencepb.CommentR\bcomments\x12\x1d\n" +
	"\n" +
	"created_by\x18\b \x01(\tR\tcreatedBy\x12\x18\n" +
	"\acomment\x18\t \x01(\tR\acomment\x12E\n" +
	"\vannotations\x18\n" +
	" \x03(\v2#.silencepb.Silence.AnnotationsEntryR\vannotations\x128\n" +
	"\fmatcher_sets\x18\v \x03(\v2\x15.silencepb.MatcherSetR\vmatcherSets\x1a>\n" +
	"\x10AnnotationsEntry\x12\x10\n" +
	"\x03key\x18\x01 \x01(\tR\x03key\x12\x14\n" +
	"\x05value\x18\x02 \x01(\tR\x05value:\x028\x01\"v\n" +
	"\vMeshSilence\x12,\n" +
	"\asilence\x18\x01 \x01(\v2\x12.silencepb.SilenceR\asilence\x129\n" +
	"\n" +
	"expires_at\x18\x02 \x01(\v2\x1a.google.protobuf.TimestampR\texpiresAtB6Z4github.com/prometheus/alertmanager/silence/silencepbb\x06proto3"

var (
	file_silence_proto_rawDescOnce sync.Once
	file_silence_proto_rawDescData []byte
)

func file_silence_proto_rawDescGZIP() []byte {
	file_silence_proto_rawDescOnce.Do(func() {
		file_silence_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_silence_proto_rawDesc), len(file_silence_proto_rawDesc)))
	})
	return file_silence_proto_rawDescData
}

var file_silence_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
var file_silence_proto_msgTypes = make([]protoimpl.MessageInfo, 6)
var file_silence_proto_goTypes = []any{
	(Matcher_Type)(0),             // 0: silencepb.Matcher.Type
	(*Matcher)(nil),               // 1: silencepb.Matcher
	(*Comment)(nil),               // 2: silencepb.Comment
	(*MatcherSet)(nil),            // 3: silencepb.MatcherSet
	(*Silence)(nil),               // 4: silencepb.Silence
	(*MeshSilence)(nil),           // 5: silencepb.MeshSilence
	nil,                           // 6: silencepb.Silence.AnnotationsEntry
	(*timestamppb.Timestamp)(nil), // 7: google.protobuf.Timestamp
}
var file_silence_proto_depIdxs = []int32{
	0,  // 0: silencepb.Matcher.type:type_name -> silencepb.Matcher.Type
	7,  // 1: silencepb.Comment.timestamp:type_name -> google.protobuf.Timestamp
	1,  // 2: silencepb.MatcherSet.matchers:type_name -> silencepb.Matcher
	1,  // 3: silencepb.Silence.matchers:type_name -> silencepb.Matcher
	7,  // 4: silencepb.Silence.starts_at:type_name -> google.protobuf.Timestamp
	7,  // 5: silencepb.Silence.ends_at:type_name -> google.protobuf.Timestamp
	7,  // 6: silencepb.Silence.updated_at:type_name -> google.protobuf.Timestamp
	2,  // 7: silencepb.Silence.comments:type_name -> silencepb.Comment
	6,  // 8: silencepb.Silence.annotations:type_name -> silencepb.Silence.AnnotationsEntry
	3,  // 9: silencepb.Silence.matcher_sets:type_name -> silencepb.MatcherSet
	4,  // 10: silencepb.MeshSilence.silence:type_name -> silencepb.Silence
	7,  // 11: silencepb.MeshSilence.expires_at:type_name -> google.protobuf.Timestamp
	12, // [12:12] is the sub-list for method output_type
	12, // [12:12] is the sub-list for method input_type
	12, // [12:12] is the sub-list for extension type_name
	12, // [12:12] is the sub-list for extension extendee
	0,  // [0:12] is the sub-list for field type_name
}

func init() { file_silence_proto_init() }
func file_silence_proto_init() {
	if File_silence_proto != nil {
		return
	}
	type x struct{}
	out := protoimpl.TypeBuilder{
		File: protoimpl.DescBuilder{
			GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
			RawDescriptor: unsafe.Slice(unsafe.StringData(file_silence_proto_rawDesc), len(file_silence_proto_rawDesc)),
			NumEnums:      1,
			NumMessages:   6,
			NumExtensions: 0,
			NumServices:   0,
		},
		GoTypes:           file_silence_proto_goTypes,
		DependencyIndexes: file_silence_proto_depIdxs,
		EnumInfos:         file_silence_proto_enumTypes,
		MessageInfos:      file_silence_proto_msgTypes,
	}.Build()
	File_silence_proto = out.File
	file_silence_proto_goTypes = nil
	file_silence_proto_depIdxs = nil
}
