345 lines
11 KiB
Go
345 lines
11 KiB
Go
|
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||
|
// versions:
|
||
|
// protoc-gen-go v1.30.0
|
||
|
// protoc v3.12.4
|
||
|
// source: message.proto
|
||
|
|
||
|
package pb
|
||
|
|
||
|
import (
|
||
|
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
|
||
|
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
|
||
|
reflect "reflect"
|
||
|
sync "sync"
|
||
|
)
|
||
|
|
||
|
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 AlertType int32
|
||
|
|
||
|
const (
|
||
|
AlertType_AlertTypeInvalid AlertType = 0
|
||
|
AlertType_AlertTypeMessage AlertType = 1
|
||
|
AlertType_AlertTypeMessageWithTitle AlertType = 2
|
||
|
AlertType_AlertTypeMessageWithAttachment AlertType = 3
|
||
|
)
|
||
|
|
||
|
// Enum value maps for AlertType.
|
||
|
var (
|
||
|
AlertType_name = map[int32]string{
|
||
|
0: "AlertTypeInvalid",
|
||
|
1: "AlertTypeMessage",
|
||
|
2: "AlertTypeMessageWithTitle",
|
||
|
3: "AlertTypeMessageWithAttachment",
|
||
|
}
|
||
|
AlertType_value = map[string]int32{
|
||
|
"AlertTypeInvalid": 0,
|
||
|
"AlertTypeMessage": 1,
|
||
|
"AlertTypeMessageWithTitle": 2,
|
||
|
"AlertTypeMessageWithAttachment": 3,
|
||
|
}
|
||
|
)
|
||
|
|
||
|
func (x AlertType) Enum() *AlertType {
|
||
|
p := new(AlertType)
|
||
|
*p = x
|
||
|
return p
|
||
|
}
|
||
|
|
||
|
func (x AlertType) String() string {
|
||
|
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||
|
}
|
||
|
|
||
|
func (AlertType) Descriptor() protoreflect.EnumDescriptor {
|
||
|
return file_message_proto_enumTypes[0].Descriptor()
|
||
|
}
|
||
|
|
||
|
func (AlertType) Type() protoreflect.EnumType {
|
||
|
return &file_message_proto_enumTypes[0]
|
||
|
}
|
||
|
|
||
|
func (x AlertType) Number() protoreflect.EnumNumber {
|
||
|
return protoreflect.EnumNumber(x)
|
||
|
}
|
||
|
|
||
|
// Deprecated: Use AlertType.Descriptor instead.
|
||
|
func (AlertType) EnumDescriptor() ([]byte, []int) {
|
||
|
return file_message_proto_rawDescGZIP(), []int{0}
|
||
|
}
|
||
|
|
||
|
type Priority int32
|
||
|
|
||
|
const (
|
||
|
Priority_PriorityInvalid Priority = 0
|
||
|
Priority_PriorityLowest Priority = 1
|
||
|
Priority_PriorityLow Priority = 2
|
||
|
Priority_PriorityNormal Priority = 3
|
||
|
Priority_PriorityHigh Priority = 4
|
||
|
Priority_PriorityEmergency Priority = 5
|
||
|
)
|
||
|
|
||
|
// Enum value maps for Priority.
|
||
|
var (
|
||
|
Priority_name = map[int32]string{
|
||
|
0: "PriorityInvalid",
|
||
|
1: "PriorityLowest",
|
||
|
2: "PriorityLow",
|
||
|
3: "PriorityNormal",
|
||
|
4: "PriorityHigh",
|
||
|
5: "PriorityEmergency",
|
||
|
}
|
||
|
Priority_value = map[string]int32{
|
||
|
"PriorityInvalid": 0,
|
||
|
"PriorityLowest": 1,
|
||
|
"PriorityLow": 2,
|
||
|
"PriorityNormal": 3,
|
||
|
"PriorityHigh": 4,
|
||
|
"PriorityEmergency": 5,
|
||
|
}
|
||
|
)
|
||
|
|
||
|
func (x Priority) Enum() *Priority {
|
||
|
p := new(Priority)
|
||
|
*p = x
|
||
|
return p
|
||
|
}
|
||
|
|
||
|
func (x Priority) String() string {
|
||
|
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||
|
}
|
||
|
|
||
|
func (Priority) Descriptor() protoreflect.EnumDescriptor {
|
||
|
return file_message_proto_enumTypes[1].Descriptor()
|
||
|
}
|
||
|
|
||
|
func (Priority) Type() protoreflect.EnumType {
|
||
|
return &file_message_proto_enumTypes[1]
|
||
|
}
|
||
|
|
||
|
func (x Priority) Number() protoreflect.EnumNumber {
|
||
|
return protoreflect.EnumNumber(x)
|
||
|
}
|
||
|
|
||
|
// Deprecated: Use Priority.Descriptor instead.
|
||
|
func (Priority) EnumDescriptor() ([]byte, []int) {
|
||
|
return file_message_proto_rawDescGZIP(), []int{1}
|
||
|
}
|
||
|
|
||
|
type Message struct {
|
||
|
state protoimpl.MessageState
|
||
|
sizeCache protoimpl.SizeCache
|
||
|
unknownFields protoimpl.UnknownFields
|
||
|
|
||
|
Timestamp uint64 `protobuf:"varint,1,opt,name=timestamp,proto3" json:"timestamp,omitempty"`
|
||
|
Type AlertType `protobuf:"varint,2,opt,name=type,proto3,enum=overpush.AlertType" json:"type,omitempty"`
|
||
|
Priority Priority `protobuf:"varint,3,opt,name=priority,proto3,enum=overpush.Priority" json:"priority,omitempty"`
|
||
|
Recipients []string `protobuf:"bytes,4,rep,name=recipients,proto3" json:"recipients,omitempty"`
|
||
|
StreamName string `protobuf:"bytes,5,opt,name=stream_name,json=streamName,proto3" json:"stream_name,omitempty"` // string transmitter = 6;
|
||
|
Title string `protobuf:"bytes,8,opt,name=title,proto3" json:"title,omitempty"`
|
||
|
Text string `protobuf:"bytes,9,opt,name=text,proto3" json:"text,omitempty"`
|
||
|
Attachment []byte `protobuf:"bytes,10,opt,name=attachment,proto3" json:"attachment,omitempty"`
|
||
|
}
|
||
|
|
||
|
func (x *Message) Reset() {
|
||
|
*x = Message{}
|
||
|
if protoimpl.UnsafeEnabled {
|
||
|
mi := &file_message_proto_msgTypes[0]
|
||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||
|
ms.StoreMessageInfo(mi)
|
||
|
}
|
||
|
}
|
||
|
|
||
|
func (x *Message) String() string {
|
||
|
return protoimpl.X.MessageStringOf(x)
|
||
|
}
|
||
|
|
||
|
func (*Message) ProtoMessage() {}
|
||
|
|
||
|
func (x *Message) ProtoReflect() protoreflect.Message {
|
||
|
mi := &file_message_proto_msgTypes[0]
|
||
|
if protoimpl.UnsafeEnabled && x != nil {
|
||
|
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||
|
if ms.LoadMessageInfo() == nil {
|
||
|
ms.StoreMessageInfo(mi)
|
||
|
}
|
||
|
return ms
|
||
|
}
|
||
|
return mi.MessageOf(x)
|
||
|
}
|
||
|
|
||
|
// Deprecated: Use Message.ProtoReflect.Descriptor instead.
|
||
|
func (*Message) Descriptor() ([]byte, []int) {
|
||
|
return file_message_proto_rawDescGZIP(), []int{0}
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetTimestamp() uint64 {
|
||
|
if x != nil {
|
||
|
return x.Timestamp
|
||
|
}
|
||
|
return 0
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetType() AlertType {
|
||
|
if x != nil {
|
||
|
return x.Type
|
||
|
}
|
||
|
return AlertType_AlertTypeInvalid
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetPriority() Priority {
|
||
|
if x != nil {
|
||
|
return x.Priority
|
||
|
}
|
||
|
return Priority_PriorityInvalid
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetRecipients() []string {
|
||
|
if x != nil {
|
||
|
return x.Recipients
|
||
|
}
|
||
|
return nil
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetStreamName() string {
|
||
|
if x != nil {
|
||
|
return x.StreamName
|
||
|
}
|
||
|
return ""
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetTitle() string {
|
||
|
if x != nil {
|
||
|
return x.Title
|
||
|
}
|
||
|
return ""
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetText() string {
|
||
|
if x != nil {
|
||
|
return x.Text
|
||
|
}
|
||
|
return ""
|
||
|
}
|
||
|
|
||
|
func (x *Message) GetAttachment() []byte {
|
||
|
if x != nil {
|
||
|
return x.Attachment
|
||
|
}
|
||
|
return nil
|
||
|
}
|
||
|
|
||
|
var File_message_proto protoreflect.FileDescriptor
|
||
|
|
||
|
var file_message_proto_rawDesc = []byte{
|
||
|
0x0a, 0x0d, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12,
|
||
|
0x08, 0x6f, 0x76, 0x65, 0x72, 0x70, 0x75, 0x73, 0x68, 0x22, 0x8b, 0x02, 0x0a, 0x07, 0x4d, 0x65,
|
||
|
0x73, 0x73, 0x61, 0x67, 0x65, 0x12, 0x1c, 0x0a, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74, 0x61,
|
||
|
0x6d, 0x70, 0x18, 0x01, 0x20, 0x01, 0x28, 0x04, 0x52, 0x09, 0x74, 0x69, 0x6d, 0x65, 0x73, 0x74,
|
||
|
0x61, 0x6d, 0x70, 0x12, 0x27, 0x0a, 0x04, 0x74, 0x79, 0x70, 0x65, 0x18, 0x02, 0x20, 0x01, 0x28,
|
||
|
0x0e, 0x32, 0x13, 0x2e, 0x6f, 0x76, 0x65, 0x72, 0x70, 0x75, 0x73, 0x68, 0x2e, 0x41, 0x6c, 0x65,
|
||
|
0x72, 0x74, 0x54, 0x79, 0x70, 0x65, 0x52, 0x04, 0x74, 0x79, 0x70, 0x65, 0x12, 0x2e, 0x0a, 0x08,
|
||
|
0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x18, 0x03, 0x20, 0x01, 0x28, 0x0e, 0x32, 0x12,
|
||
|
0x2e, 0x6f, 0x76, 0x65, 0x72, 0x70, 0x75, 0x73, 0x68, 0x2e, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69,
|
||
|
0x74, 0x79, 0x52, 0x08, 0x70, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x12, 0x1e, 0x0a, 0x0a,
|
||
|
0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x73, 0x18, 0x04, 0x20, 0x03, 0x28, 0x09,
|
||
|
0x52, 0x0a, 0x72, 0x65, 0x63, 0x69, 0x70, 0x69, 0x65, 0x6e, 0x74, 0x73, 0x12, 0x1f, 0x0a, 0x0b,
|
||
|
0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x5f, 0x6e, 0x61, 0x6d, 0x65, 0x18, 0x05, 0x20, 0x01, 0x28,
|
||
|
0x09, 0x52, 0x0a, 0x73, 0x74, 0x72, 0x65, 0x61, 0x6d, 0x4e, 0x61, 0x6d, 0x65, 0x12, 0x14, 0x0a,
|
||
|
0x05, 0x74, 0x69, 0x74, 0x6c, 0x65, 0x18, 0x08, 0x20, 0x01, 0x28, 0x09, 0x52, 0x05, 0x74, 0x69,
|
||
|
0x74, 0x6c, 0x65, 0x12, 0x12, 0x0a, 0x04, 0x74, 0x65, 0x78, 0x74, 0x18, 0x09, 0x20, 0x01, 0x28,
|
||
|
0x09, 0x52, 0x04, 0x74, 0x65, 0x78, 0x74, 0x12, 0x1e, 0x0a, 0x0a, 0x61, 0x74, 0x74, 0x61, 0x63,
|
||
|
0x68, 0x6d, 0x65, 0x6e, 0x74, 0x18, 0x0a, 0x20, 0x01, 0x28, 0x0c, 0x52, 0x0a, 0x61, 0x74, 0x74,
|
||
|
0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e, 0x74, 0x2a, 0x7a, 0x0a, 0x09, 0x41, 0x6c, 0x65, 0x72, 0x74,
|
||
|
0x54, 0x79, 0x70, 0x65, 0x12, 0x14, 0x0a, 0x10, 0x41, 0x6c, 0x65, 0x72, 0x74, 0x54, 0x79, 0x70,
|
||
|
0x65, 0x49, 0x6e, 0x76, 0x61, 0x6c, 0x69, 0x64, 0x10, 0x00, 0x12, 0x14, 0x0a, 0x10, 0x41, 0x6c,
|
||
|
0x65, 0x72, 0x74, 0x54, 0x79, 0x70, 0x65, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x10, 0x01,
|
||
|
0x12, 0x1d, 0x0a, 0x19, 0x41, 0x6c, 0x65, 0x72, 0x74, 0x54, 0x79, 0x70, 0x65, 0x4d, 0x65, 0x73,
|
||
|
0x73, 0x61, 0x67, 0x65, 0x57, 0x69, 0x74, 0x68, 0x54, 0x69, 0x74, 0x6c, 0x65, 0x10, 0x02, 0x12,
|
||
|
0x22, 0x0a, 0x1e, 0x41, 0x6c, 0x65, 0x72, 0x74, 0x54, 0x79, 0x70, 0x65, 0x4d, 0x65, 0x73, 0x73,
|
||
|
0x61, 0x67, 0x65, 0x57, 0x69, 0x74, 0x68, 0x41, 0x74, 0x74, 0x61, 0x63, 0x68, 0x6d, 0x65, 0x6e,
|
||
|
0x74, 0x10, 0x03, 0x2a, 0x81, 0x01, 0x0a, 0x08, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79,
|
||
|
0x12, 0x13, 0x0a, 0x0f, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x49, 0x6e, 0x76, 0x61,
|
||
|
0x6c, 0x69, 0x64, 0x10, 0x00, 0x12, 0x12, 0x0a, 0x0e, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74,
|
||
|
0x79, 0x4c, 0x6f, 0x77, 0x65, 0x73, 0x74, 0x10, 0x01, 0x12, 0x0f, 0x0a, 0x0b, 0x50, 0x72, 0x69,
|
||
|
0x6f, 0x72, 0x69, 0x74, 0x79, 0x4c, 0x6f, 0x77, 0x10, 0x02, 0x12, 0x12, 0x0a, 0x0e, 0x50, 0x72,
|
||
|
0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x4e, 0x6f, 0x72, 0x6d, 0x61, 0x6c, 0x10, 0x03, 0x12, 0x10,
|
||
|
0x0a, 0x0c, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x48, 0x69, 0x67, 0x68, 0x10, 0x04,
|
||
|
0x12, 0x15, 0x0a, 0x11, 0x50, 0x72, 0x69, 0x6f, 0x72, 0x69, 0x74, 0x79, 0x45, 0x6d, 0x65, 0x72,
|
||
|
0x67, 0x65, 0x6e, 0x63, 0x79, 0x10, 0x05, 0x42, 0x06, 0x5a, 0x04, 0x2e, 0x3b, 0x70, 0x62, 0x62,
|
||
|
0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33,
|
||
|
}
|
||
|
|
||
|
var (
|
||
|
file_message_proto_rawDescOnce sync.Once
|
||
|
file_message_proto_rawDescData = file_message_proto_rawDesc
|
||
|
)
|
||
|
|
||
|
func file_message_proto_rawDescGZIP() []byte {
|
||
|
file_message_proto_rawDescOnce.Do(func() {
|
||
|
file_message_proto_rawDescData = protoimpl.X.CompressGZIP(file_message_proto_rawDescData)
|
||
|
})
|
||
|
return file_message_proto_rawDescData
|
||
|
}
|
||
|
|
||
|
var file_message_proto_enumTypes = make([]protoimpl.EnumInfo, 2)
|
||
|
var file_message_proto_msgTypes = make([]protoimpl.MessageInfo, 1)
|
||
|
var file_message_proto_goTypes = []interface{}{
|
||
|
(AlertType)(0), // 0: overpush.AlertType
|
||
|
(Priority)(0), // 1: overpush.Priority
|
||
|
(*Message)(nil), // 2: overpush.Message
|
||
|
}
|
||
|
var file_message_proto_depIdxs = []int32{
|
||
|
0, // 0: overpush.Message.type:type_name -> overpush.AlertType
|
||
|
1, // 1: overpush.Message.priority:type_name -> overpush.Priority
|
||
|
2, // [2:2] is the sub-list for method output_type
|
||
|
2, // [2:2] is the sub-list for method input_type
|
||
|
2, // [2:2] is the sub-list for extension type_name
|
||
|
2, // [2:2] is the sub-list for extension extendee
|
||
|
0, // [0:2] is the sub-list for field type_name
|
||
|
}
|
||
|
|
||
|
func init() { file_message_proto_init() }
|
||
|
func file_message_proto_init() {
|
||
|
if File_message_proto != nil {
|
||
|
return
|
||
|
}
|
||
|
if !protoimpl.UnsafeEnabled {
|
||
|
file_message_proto_msgTypes[0].Exporter = func(v interface{}, i int) interface{} {
|
||
|
switch v := v.(*Message); i {
|
||
|
case 0:
|
||
|
return &v.state
|
||
|
case 1:
|
||
|
return &v.sizeCache
|
||
|
case 2:
|
||
|
return &v.unknownFields
|
||
|
default:
|
||
|
return nil
|
||
|
}
|
||
|
}
|
||
|
}
|
||
|
type x struct{}
|
||
|
out := protoimpl.TypeBuilder{
|
||
|
File: protoimpl.DescBuilder{
|
||
|
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||
|
RawDescriptor: file_message_proto_rawDesc,
|
||
|
NumEnums: 2,
|
||
|
NumMessages: 1,
|
||
|
NumExtensions: 0,
|
||
|
NumServices: 0,
|
||
|
},
|
||
|
GoTypes: file_message_proto_goTypes,
|
||
|
DependencyIndexes: file_message_proto_depIdxs,
|
||
|
EnumInfos: file_message_proto_enumTypes,
|
||
|
MessageInfos: file_message_proto_msgTypes,
|
||
|
}.Build()
|
||
|
File_message_proto = out.File
|
||
|
file_message_proto_rawDesc = nil
|
||
|
file_message_proto_goTypes = nil
|
||
|
file_message_proto_depIdxs = nil
|
||
|
}
|