0.29.1原版
This commit is contained in:
@@ -0,0 +1,495 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.11
|
||||
// protoc (unknown)
|
||||
// source: store/attachment.proto
|
||||
|
||||
package store
|
||||
|
||||
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 AttachmentStorageType int32
|
||||
|
||||
const (
|
||||
AttachmentStorageType_ATTACHMENT_STORAGE_TYPE_UNSPECIFIED AttachmentStorageType = 0
|
||||
// Attachment is stored locally. AKA, local file system.
|
||||
AttachmentStorageType_LOCAL AttachmentStorageType = 1
|
||||
// Attachment is stored in S3.
|
||||
AttachmentStorageType_S3 AttachmentStorageType = 2
|
||||
// Attachment is stored in an external storage. The reference is a URL.
|
||||
AttachmentStorageType_EXTERNAL AttachmentStorageType = 3
|
||||
)
|
||||
|
||||
// Enum value maps for AttachmentStorageType.
|
||||
var (
|
||||
AttachmentStorageType_name = map[int32]string{
|
||||
0: "ATTACHMENT_STORAGE_TYPE_UNSPECIFIED",
|
||||
1: "LOCAL",
|
||||
2: "S3",
|
||||
3: "EXTERNAL",
|
||||
}
|
||||
AttachmentStorageType_value = map[string]int32{
|
||||
"ATTACHMENT_STORAGE_TYPE_UNSPECIFIED": 0,
|
||||
"LOCAL": 1,
|
||||
"S3": 2,
|
||||
"EXTERNAL": 3,
|
||||
}
|
||||
)
|
||||
|
||||
func (x AttachmentStorageType) Enum() *AttachmentStorageType {
|
||||
p := new(AttachmentStorageType)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x AttachmentStorageType) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (AttachmentStorageType) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_store_attachment_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (AttachmentStorageType) Type() protoreflect.EnumType {
|
||||
return &file_store_attachment_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x AttachmentStorageType) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use AttachmentStorageType.Descriptor instead.
|
||||
func (AttachmentStorageType) EnumDescriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
type MotionMediaFamily int32
|
||||
|
||||
const (
|
||||
MotionMediaFamily_MOTION_MEDIA_FAMILY_UNSPECIFIED MotionMediaFamily = 0
|
||||
MotionMediaFamily_APPLE_LIVE_PHOTO MotionMediaFamily = 1
|
||||
MotionMediaFamily_ANDROID_MOTION_PHOTO MotionMediaFamily = 2
|
||||
)
|
||||
|
||||
// Enum value maps for MotionMediaFamily.
|
||||
var (
|
||||
MotionMediaFamily_name = map[int32]string{
|
||||
0: "MOTION_MEDIA_FAMILY_UNSPECIFIED",
|
||||
1: "APPLE_LIVE_PHOTO",
|
||||
2: "ANDROID_MOTION_PHOTO",
|
||||
}
|
||||
MotionMediaFamily_value = map[string]int32{
|
||||
"MOTION_MEDIA_FAMILY_UNSPECIFIED": 0,
|
||||
"APPLE_LIVE_PHOTO": 1,
|
||||
"ANDROID_MOTION_PHOTO": 2,
|
||||
}
|
||||
)
|
||||
|
||||
func (x MotionMediaFamily) Enum() *MotionMediaFamily {
|
||||
p := new(MotionMediaFamily)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x MotionMediaFamily) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (MotionMediaFamily) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_store_attachment_proto_enumTypes[1].Descriptor()
|
||||
}
|
||||
|
||||
func (MotionMediaFamily) Type() protoreflect.EnumType {
|
||||
return &file_store_attachment_proto_enumTypes[1]
|
||||
}
|
||||
|
||||
func (x MotionMediaFamily) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use MotionMediaFamily.Descriptor instead.
|
||||
func (MotionMediaFamily) EnumDescriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
type MotionMediaRole int32
|
||||
|
||||
const (
|
||||
MotionMediaRole_MOTION_MEDIA_ROLE_UNSPECIFIED MotionMediaRole = 0
|
||||
MotionMediaRole_STILL MotionMediaRole = 1
|
||||
MotionMediaRole_VIDEO MotionMediaRole = 2
|
||||
MotionMediaRole_CONTAINER MotionMediaRole = 3
|
||||
)
|
||||
|
||||
// Enum value maps for MotionMediaRole.
|
||||
var (
|
||||
MotionMediaRole_name = map[int32]string{
|
||||
0: "MOTION_MEDIA_ROLE_UNSPECIFIED",
|
||||
1: "STILL",
|
||||
2: "VIDEO",
|
||||
3: "CONTAINER",
|
||||
}
|
||||
MotionMediaRole_value = map[string]int32{
|
||||
"MOTION_MEDIA_ROLE_UNSPECIFIED": 0,
|
||||
"STILL": 1,
|
||||
"VIDEO": 2,
|
||||
"CONTAINER": 3,
|
||||
}
|
||||
)
|
||||
|
||||
func (x MotionMediaRole) Enum() *MotionMediaRole {
|
||||
p := new(MotionMediaRole)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x MotionMediaRole) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (MotionMediaRole) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_store_attachment_proto_enumTypes[2].Descriptor()
|
||||
}
|
||||
|
||||
func (MotionMediaRole) Type() protoreflect.EnumType {
|
||||
return &file_store_attachment_proto_enumTypes[2]
|
||||
}
|
||||
|
||||
func (x MotionMediaRole) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use MotionMediaRole.Descriptor instead.
|
||||
func (MotionMediaRole) EnumDescriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
type MotionMedia struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Family MotionMediaFamily `protobuf:"varint,1,opt,name=family,proto3,enum=memos.store.MotionMediaFamily" json:"family,omitempty"`
|
||||
Role MotionMediaRole `protobuf:"varint,2,opt,name=role,proto3,enum=memos.store.MotionMediaRole" json:"role,omitempty"`
|
||||
GroupId string `protobuf:"bytes,3,opt,name=group_id,json=groupId,proto3" json:"group_id,omitempty"`
|
||||
PresentationTimestampUs int64 `protobuf:"varint,4,opt,name=presentation_timestamp_us,json=presentationTimestampUs,proto3" json:"presentation_timestamp_us,omitempty"`
|
||||
HasEmbeddedVideo bool `protobuf:"varint,5,opt,name=has_embedded_video,json=hasEmbeddedVideo,proto3" json:"has_embedded_video,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *MotionMedia) Reset() {
|
||||
*x = MotionMedia{}
|
||||
mi := &file_store_attachment_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *MotionMedia) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MotionMedia) ProtoMessage() {}
|
||||
|
||||
func (x *MotionMedia) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_attachment_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 MotionMedia.ProtoReflect.Descriptor instead.
|
||||
func (*MotionMedia) Descriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *MotionMedia) GetFamily() MotionMediaFamily {
|
||||
if x != nil {
|
||||
return x.Family
|
||||
}
|
||||
return MotionMediaFamily_MOTION_MEDIA_FAMILY_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *MotionMedia) GetRole() MotionMediaRole {
|
||||
if x != nil {
|
||||
return x.Role
|
||||
}
|
||||
return MotionMediaRole_MOTION_MEDIA_ROLE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *MotionMedia) GetGroupId() string {
|
||||
if x != nil {
|
||||
return x.GroupId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *MotionMedia) GetPresentationTimestampUs() int64 {
|
||||
if x != nil {
|
||||
return x.PresentationTimestampUs
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *MotionMedia) GetHasEmbeddedVideo() bool {
|
||||
if x != nil {
|
||||
return x.HasEmbeddedVideo
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
type AttachmentPayload struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
// Types that are valid to be assigned to Payload:
|
||||
//
|
||||
// *AttachmentPayload_S3Object_
|
||||
Payload isAttachmentPayload_Payload `protobuf_oneof:"payload"`
|
||||
MotionMedia *MotionMedia `protobuf:"bytes,10,opt,name=motion_media,json=motionMedia,proto3" json:"motion_media,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload) Reset() {
|
||||
*x = AttachmentPayload{}
|
||||
mi := &file_store_attachment_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*AttachmentPayload) ProtoMessage() {}
|
||||
|
||||
func (x *AttachmentPayload) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_attachment_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 AttachmentPayload.ProtoReflect.Descriptor instead.
|
||||
func (*AttachmentPayload) Descriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload) GetPayload() isAttachmentPayload_Payload {
|
||||
if x != nil {
|
||||
return x.Payload
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload) GetS3Object() *AttachmentPayload_S3Object {
|
||||
if x != nil {
|
||||
if x, ok := x.Payload.(*AttachmentPayload_S3Object_); ok {
|
||||
return x.S3Object
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload) GetMotionMedia() *MotionMedia {
|
||||
if x != nil {
|
||||
return x.MotionMedia
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type isAttachmentPayload_Payload interface {
|
||||
isAttachmentPayload_Payload()
|
||||
}
|
||||
|
||||
type AttachmentPayload_S3Object_ struct {
|
||||
S3Object *AttachmentPayload_S3Object `protobuf:"bytes,1,opt,name=s3_object,json=s3Object,proto3,oneof"`
|
||||
}
|
||||
|
||||
func (*AttachmentPayload_S3Object_) isAttachmentPayload_Payload() {}
|
||||
|
||||
type AttachmentPayload_S3Object struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
S3Config *StorageS3Config `protobuf:"bytes,1,opt,name=s3_config,json=s3Config,proto3" json:"s3_config,omitempty"`
|
||||
// key is the S3 object key.
|
||||
Key string `protobuf:"bytes,2,opt,name=key,proto3" json:"key,omitempty"`
|
||||
// last_presigned_time is the last time the object was presigned.
|
||||
// This is used to determine if the presigned URL is still valid.
|
||||
LastPresignedTime *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=last_presigned_time,json=lastPresignedTime,proto3" json:"last_presigned_time,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) Reset() {
|
||||
*x = AttachmentPayload_S3Object{}
|
||||
mi := &file_store_attachment_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*AttachmentPayload_S3Object) ProtoMessage() {}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_attachment_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 AttachmentPayload_S3Object.ProtoReflect.Descriptor instead.
|
||||
func (*AttachmentPayload_S3Object) Descriptor() ([]byte, []int) {
|
||||
return file_store_attachment_proto_rawDescGZIP(), []int{1, 0}
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) GetS3Config() *StorageS3Config {
|
||||
if x != nil {
|
||||
return x.S3Config
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) GetKey() string {
|
||||
if x != nil {
|
||||
return x.Key
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *AttachmentPayload_S3Object) GetLastPresignedTime() *timestamppb.Timestamp {
|
||||
if x != nil {
|
||||
return x.LastPresignedTime
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_store_attachment_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_store_attachment_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x16store/attachment.proto\x12\vmemos.store\x1a\x1fgoogle/protobuf/timestamp.proto\x1a\x1cstore/instance_setting.proto\"\xfc\x01\n" +
|
||||
"\vMotionMedia\x126\n" +
|
||||
"\x06family\x18\x01 \x01(\x0e2\x1e.memos.store.MotionMediaFamilyR\x06family\x120\n" +
|
||||
"\x04role\x18\x02 \x01(\x0e2\x1c.memos.store.MotionMediaRoleR\x04role\x12\x19\n" +
|
||||
"\bgroup_id\x18\x03 \x01(\tR\agroupId\x12:\n" +
|
||||
"\x19presentation_timestamp_us\x18\x04 \x01(\x03R\x17presentationTimestampUs\x12,\n" +
|
||||
"\x12has_embedded_video\x18\x05 \x01(\bR\x10hasEmbeddedVideo\"\xc9\x02\n" +
|
||||
"\x11AttachmentPayload\x12F\n" +
|
||||
"\ts3_object\x18\x01 \x01(\v2'.memos.store.AttachmentPayload.S3ObjectH\x00R\bs3Object\x12;\n" +
|
||||
"\fmotion_media\x18\n" +
|
||||
" \x01(\v2\x18.memos.store.MotionMediaR\vmotionMedia\x1a\xa3\x01\n" +
|
||||
"\bS3Object\x129\n" +
|
||||
"\ts3_config\x18\x01 \x01(\v2\x1c.memos.store.StorageS3ConfigR\bs3Config\x12\x10\n" +
|
||||
"\x03key\x18\x02 \x01(\tR\x03key\x12J\n" +
|
||||
"\x13last_presigned_time\x18\x03 \x01(\v2\x1a.google.protobuf.TimestampR\x11lastPresignedTimeB\t\n" +
|
||||
"\apayload*a\n" +
|
||||
"\x15AttachmentStorageType\x12'\n" +
|
||||
"#ATTACHMENT_STORAGE_TYPE_UNSPECIFIED\x10\x00\x12\t\n" +
|
||||
"\x05LOCAL\x10\x01\x12\x06\n" +
|
||||
"\x02S3\x10\x02\x12\f\n" +
|
||||
"\bEXTERNAL\x10\x03*h\n" +
|
||||
"\x11MotionMediaFamily\x12#\n" +
|
||||
"\x1fMOTION_MEDIA_FAMILY_UNSPECIFIED\x10\x00\x12\x14\n" +
|
||||
"\x10APPLE_LIVE_PHOTO\x10\x01\x12\x18\n" +
|
||||
"\x14ANDROID_MOTION_PHOTO\x10\x02*Y\n" +
|
||||
"\x0fMotionMediaRole\x12!\n" +
|
||||
"\x1dMOTION_MEDIA_ROLE_UNSPECIFIED\x10\x00\x12\t\n" +
|
||||
"\x05STILL\x10\x01\x12\t\n" +
|
||||
"\x05VIDEO\x10\x02\x12\r\n" +
|
||||
"\tCONTAINER\x10\x03B\x9a\x01\n" +
|
||||
"\x0fcom.memos.storeB\x0fAttachmentProtoP\x01Z)github.com/usememos/memos/proto/gen/store\xa2\x02\x03MSX\xaa\x02\vMemos.Store\xca\x02\vMemos\\Store\xe2\x02\x17Memos\\Store\\GPBMetadata\xea\x02\fMemos::Storeb\x06proto3"
|
||||
|
||||
var (
|
||||
file_store_attachment_proto_rawDescOnce sync.Once
|
||||
file_store_attachment_proto_rawDescData []byte
|
||||
)
|
||||
|
||||
func file_store_attachment_proto_rawDescGZIP() []byte {
|
||||
file_store_attachment_proto_rawDescOnce.Do(func() {
|
||||
file_store_attachment_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_store_attachment_proto_rawDesc), len(file_store_attachment_proto_rawDesc)))
|
||||
})
|
||||
return file_store_attachment_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_store_attachment_proto_enumTypes = make([]protoimpl.EnumInfo, 3)
|
||||
var file_store_attachment_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
|
||||
var file_store_attachment_proto_goTypes = []any{
|
||||
(AttachmentStorageType)(0), // 0: memos.store.AttachmentStorageType
|
||||
(MotionMediaFamily)(0), // 1: memos.store.MotionMediaFamily
|
||||
(MotionMediaRole)(0), // 2: memos.store.MotionMediaRole
|
||||
(*MotionMedia)(nil), // 3: memos.store.MotionMedia
|
||||
(*AttachmentPayload)(nil), // 4: memos.store.AttachmentPayload
|
||||
(*AttachmentPayload_S3Object)(nil), // 5: memos.store.AttachmentPayload.S3Object
|
||||
(*StorageS3Config)(nil), // 6: memos.store.StorageS3Config
|
||||
(*timestamppb.Timestamp)(nil), // 7: google.protobuf.Timestamp
|
||||
}
|
||||
var file_store_attachment_proto_depIdxs = []int32{
|
||||
1, // 0: memos.store.MotionMedia.family:type_name -> memos.store.MotionMediaFamily
|
||||
2, // 1: memos.store.MotionMedia.role:type_name -> memos.store.MotionMediaRole
|
||||
5, // 2: memos.store.AttachmentPayload.s3_object:type_name -> memos.store.AttachmentPayload.S3Object
|
||||
3, // 3: memos.store.AttachmentPayload.motion_media:type_name -> memos.store.MotionMedia
|
||||
6, // 4: memos.store.AttachmentPayload.S3Object.s3_config:type_name -> memos.store.StorageS3Config
|
||||
7, // 5: memos.store.AttachmentPayload.S3Object.last_presigned_time:type_name -> google.protobuf.Timestamp
|
||||
6, // [6:6] is the sub-list for method output_type
|
||||
6, // [6:6] is the sub-list for method input_type
|
||||
6, // [6:6] is the sub-list for extension type_name
|
||||
6, // [6:6] is the sub-list for extension extendee
|
||||
0, // [0:6] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_store_attachment_proto_init() }
|
||||
func file_store_attachment_proto_init() {
|
||||
if File_store_attachment_proto != nil {
|
||||
return
|
||||
}
|
||||
file_store_instance_setting_proto_init()
|
||||
file_store_attachment_proto_msgTypes[1].OneofWrappers = []any{
|
||||
(*AttachmentPayload_S3Object_)(nil),
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_store_attachment_proto_rawDesc), len(file_store_attachment_proto_rawDesc)),
|
||||
NumEnums: 3,
|
||||
NumMessages: 3,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_store_attachment_proto_goTypes,
|
||||
DependencyIndexes: file_store_attachment_proto_depIdxs,
|
||||
EnumInfos: file_store_attachment_proto_enumTypes,
|
||||
MessageInfos: file_store_attachment_proto_msgTypes,
|
||||
}.Build()
|
||||
File_store_attachment_proto = out.File
|
||||
file_store_attachment_proto_goTypes = nil
|
||||
file_store_attachment_proto_depIdxs = nil
|
||||
}
|
||||
@@ -0,0 +1,476 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.11
|
||||
// protoc (unknown)
|
||||
// source: store/idp.proto
|
||||
|
||||
package store
|
||||
|
||||
import (
|
||||
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 IdentityProvider_Type int32
|
||||
|
||||
const (
|
||||
IdentityProvider_TYPE_UNSPECIFIED IdentityProvider_Type = 0
|
||||
IdentityProvider_OAUTH2 IdentityProvider_Type = 1
|
||||
)
|
||||
|
||||
// Enum value maps for IdentityProvider_Type.
|
||||
var (
|
||||
IdentityProvider_Type_name = map[int32]string{
|
||||
0: "TYPE_UNSPECIFIED",
|
||||
1: "OAUTH2",
|
||||
}
|
||||
IdentityProvider_Type_value = map[string]int32{
|
||||
"TYPE_UNSPECIFIED": 0,
|
||||
"OAUTH2": 1,
|
||||
}
|
||||
)
|
||||
|
||||
func (x IdentityProvider_Type) Enum() *IdentityProvider_Type {
|
||||
p := new(IdentityProvider_Type)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x IdentityProvider_Type) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (IdentityProvider_Type) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_store_idp_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (IdentityProvider_Type) Type() protoreflect.EnumType {
|
||||
return &file_store_idp_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x IdentityProvider_Type) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use IdentityProvider_Type.Descriptor instead.
|
||||
func (IdentityProvider_Type) EnumDescriptor() ([]byte, []int) {
|
||||
return file_store_idp_proto_rawDescGZIP(), []int{0, 0}
|
||||
}
|
||||
|
||||
type IdentityProvider struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
|
||||
Name string `protobuf:"bytes,2,opt,name=name,proto3" json:"name,omitempty"`
|
||||
Type IdentityProvider_Type `protobuf:"varint,3,opt,name=type,proto3,enum=memos.store.IdentityProvider_Type" json:"type,omitempty"`
|
||||
IdentifierFilter string `protobuf:"bytes,4,opt,name=identifier_filter,json=identifierFilter,proto3" json:"identifier_filter,omitempty"`
|
||||
Config *IdentityProviderConfig `protobuf:"bytes,5,opt,name=config,proto3" json:"config,omitempty"`
|
||||
Uid string `protobuf:"bytes,6,opt,name=uid,proto3" json:"uid,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) Reset() {
|
||||
*x = IdentityProvider{}
|
||||
mi := &file_store_idp_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*IdentityProvider) ProtoMessage() {}
|
||||
|
||||
func (x *IdentityProvider) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_idp_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 IdentityProvider.ProtoReflect.Descriptor instead.
|
||||
func (*IdentityProvider) Descriptor() ([]byte, []int) {
|
||||
return file_store_idp_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetId() int32 {
|
||||
if x != nil {
|
||||
return x.Id
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetName() string {
|
||||
if x != nil {
|
||||
return x.Name
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetType() IdentityProvider_Type {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return IdentityProvider_TYPE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetIdentifierFilter() string {
|
||||
if x != nil {
|
||||
return x.IdentifierFilter
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetConfig() *IdentityProviderConfig {
|
||||
if x != nil {
|
||||
return x.Config
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *IdentityProvider) GetUid() string {
|
||||
if x != nil {
|
||||
return x.Uid
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type IdentityProviderConfig struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
// Types that are valid to be assigned to Config:
|
||||
//
|
||||
// *IdentityProviderConfig_Oauth2Config
|
||||
Config isIdentityProviderConfig_Config `protobuf_oneof:"config"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *IdentityProviderConfig) Reset() {
|
||||
*x = IdentityProviderConfig{}
|
||||
mi := &file_store_idp_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *IdentityProviderConfig) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*IdentityProviderConfig) ProtoMessage() {}
|
||||
|
||||
func (x *IdentityProviderConfig) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_idp_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 IdentityProviderConfig.ProtoReflect.Descriptor instead.
|
||||
func (*IdentityProviderConfig) Descriptor() ([]byte, []int) {
|
||||
return file_store_idp_proto_rawDescGZIP(), []int{1}
|
||||
}
|
||||
|
||||
func (x *IdentityProviderConfig) GetConfig() isIdentityProviderConfig_Config {
|
||||
if x != nil {
|
||||
return x.Config
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *IdentityProviderConfig) GetOauth2Config() *OAuth2Config {
|
||||
if x != nil {
|
||||
if x, ok := x.Config.(*IdentityProviderConfig_Oauth2Config); ok {
|
||||
return x.Oauth2Config
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type isIdentityProviderConfig_Config interface {
|
||||
isIdentityProviderConfig_Config()
|
||||
}
|
||||
|
||||
type IdentityProviderConfig_Oauth2Config struct {
|
||||
Oauth2Config *OAuth2Config `protobuf:"bytes,1,opt,name=oauth2_config,json=oauth2Config,proto3,oneof"`
|
||||
}
|
||||
|
||||
func (*IdentityProviderConfig_Oauth2Config) isIdentityProviderConfig_Config() {}
|
||||
|
||||
type FieldMapping struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Identifier string `protobuf:"bytes,1,opt,name=identifier,proto3" json:"identifier,omitempty"`
|
||||
DisplayName string `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
|
||||
Email string `protobuf:"bytes,3,opt,name=email,proto3" json:"email,omitempty"`
|
||||
AvatarUrl string `protobuf:"bytes,4,opt,name=avatar_url,json=avatarUrl,proto3" json:"avatar_url,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *FieldMapping) Reset() {
|
||||
*x = FieldMapping{}
|
||||
mi := &file_store_idp_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *FieldMapping) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*FieldMapping) ProtoMessage() {}
|
||||
|
||||
func (x *FieldMapping) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_idp_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 FieldMapping.ProtoReflect.Descriptor instead.
|
||||
func (*FieldMapping) Descriptor() ([]byte, []int) {
|
||||
return file_store_idp_proto_rawDescGZIP(), []int{2}
|
||||
}
|
||||
|
||||
func (x *FieldMapping) GetIdentifier() string {
|
||||
if x != nil {
|
||||
return x.Identifier
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *FieldMapping) GetDisplayName() string {
|
||||
if x != nil {
|
||||
return x.DisplayName
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *FieldMapping) GetEmail() string {
|
||||
if x != nil {
|
||||
return x.Email
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *FieldMapping) GetAvatarUrl() string {
|
||||
if x != nil {
|
||||
return x.AvatarUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type OAuth2Config struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
ClientId string `protobuf:"bytes,1,opt,name=client_id,json=clientId,proto3" json:"client_id,omitempty"`
|
||||
ClientSecret string `protobuf:"bytes,2,opt,name=client_secret,json=clientSecret,proto3" json:"client_secret,omitempty"`
|
||||
AuthUrl string `protobuf:"bytes,3,opt,name=auth_url,json=authUrl,proto3" json:"auth_url,omitempty"`
|
||||
TokenUrl string `protobuf:"bytes,4,opt,name=token_url,json=tokenUrl,proto3" json:"token_url,omitempty"`
|
||||
UserInfoUrl string `protobuf:"bytes,5,opt,name=user_info_url,json=userInfoUrl,proto3" json:"user_info_url,omitempty"`
|
||||
Scopes []string `protobuf:"bytes,6,rep,name=scopes,proto3" json:"scopes,omitempty"`
|
||||
FieldMapping *FieldMapping `protobuf:"bytes,7,opt,name=field_mapping,json=fieldMapping,proto3" json:"field_mapping,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) Reset() {
|
||||
*x = OAuth2Config{}
|
||||
mi := &file_store_idp_proto_msgTypes[3]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*OAuth2Config) ProtoMessage() {}
|
||||
|
||||
func (x *OAuth2Config) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_idp_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 OAuth2Config.ProtoReflect.Descriptor instead.
|
||||
func (*OAuth2Config) Descriptor() ([]byte, []int) {
|
||||
return file_store_idp_proto_rawDescGZIP(), []int{3}
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetClientId() string {
|
||||
if x != nil {
|
||||
return x.ClientId
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetClientSecret() string {
|
||||
if x != nil {
|
||||
return x.ClientSecret
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetAuthUrl() string {
|
||||
if x != nil {
|
||||
return x.AuthUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetTokenUrl() string {
|
||||
if x != nil {
|
||||
return x.TokenUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetUserInfoUrl() string {
|
||||
if x != nil {
|
||||
return x.UserInfoUrl
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetScopes() []string {
|
||||
if x != nil {
|
||||
return x.Scopes
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *OAuth2Config) GetFieldMapping() *FieldMapping {
|
||||
if x != nil {
|
||||
return x.FieldMapping
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
var File_store_idp_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_store_idp_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x0fstore/idp.proto\x12\vmemos.store\"\x94\x02\n" +
|
||||
"\x10IdentityProvider\x12\x0e\n" +
|
||||
"\x02id\x18\x01 \x01(\x05R\x02id\x12\x12\n" +
|
||||
"\x04name\x18\x02 \x01(\tR\x04name\x126\n" +
|
||||
"\x04type\x18\x03 \x01(\x0e2\".memos.store.IdentityProvider.TypeR\x04type\x12+\n" +
|
||||
"\x11identifier_filter\x18\x04 \x01(\tR\x10identifierFilter\x12;\n" +
|
||||
"\x06config\x18\x05 \x01(\v2#.memos.store.IdentityProviderConfigR\x06config\x12\x10\n" +
|
||||
"\x03uid\x18\x06 \x01(\tR\x03uid\"(\n" +
|
||||
"\x04Type\x12\x14\n" +
|
||||
"\x10TYPE_UNSPECIFIED\x10\x00\x12\n" +
|
||||
"\n" +
|
||||
"\x06OAUTH2\x10\x01\"d\n" +
|
||||
"\x16IdentityProviderConfig\x12@\n" +
|
||||
"\roauth2_config\x18\x01 \x01(\v2\x19.memos.store.OAuth2ConfigH\x00R\foauth2ConfigB\b\n" +
|
||||
"\x06config\"\x86\x01\n" +
|
||||
"\fFieldMapping\x12\x1e\n" +
|
||||
"\n" +
|
||||
"identifier\x18\x01 \x01(\tR\n" +
|
||||
"identifier\x12!\n" +
|
||||
"\fdisplay_name\x18\x02 \x01(\tR\vdisplayName\x12\x14\n" +
|
||||
"\x05email\x18\x03 \x01(\tR\x05email\x12\x1d\n" +
|
||||
"\n" +
|
||||
"avatar_url\x18\x04 \x01(\tR\tavatarUrl\"\x84\x02\n" +
|
||||
"\fOAuth2Config\x12\x1b\n" +
|
||||
"\tclient_id\x18\x01 \x01(\tR\bclientId\x12#\n" +
|
||||
"\rclient_secret\x18\x02 \x01(\tR\fclientSecret\x12\x19\n" +
|
||||
"\bauth_url\x18\x03 \x01(\tR\aauthUrl\x12\x1b\n" +
|
||||
"\ttoken_url\x18\x04 \x01(\tR\btokenUrl\x12\"\n" +
|
||||
"\ruser_info_url\x18\x05 \x01(\tR\vuserInfoUrl\x12\x16\n" +
|
||||
"\x06scopes\x18\x06 \x03(\tR\x06scopes\x12>\n" +
|
||||
"\rfield_mapping\x18\a \x01(\v2\x19.memos.store.FieldMappingR\ffieldMappingB\x93\x01\n" +
|
||||
"\x0fcom.memos.storeB\bIdpProtoP\x01Z)github.com/usememos/memos/proto/gen/store\xa2\x02\x03MSX\xaa\x02\vMemos.Store\xca\x02\vMemos\\Store\xe2\x02\x17Memos\\Store\\GPBMetadata\xea\x02\fMemos::Storeb\x06proto3"
|
||||
|
||||
var (
|
||||
file_store_idp_proto_rawDescOnce sync.Once
|
||||
file_store_idp_proto_rawDescData []byte
|
||||
)
|
||||
|
||||
func file_store_idp_proto_rawDescGZIP() []byte {
|
||||
file_store_idp_proto_rawDescOnce.Do(func() {
|
||||
file_store_idp_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_store_idp_proto_rawDesc), len(file_store_idp_proto_rawDesc)))
|
||||
})
|
||||
return file_store_idp_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_store_idp_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_store_idp_proto_msgTypes = make([]protoimpl.MessageInfo, 4)
|
||||
var file_store_idp_proto_goTypes = []any{
|
||||
(IdentityProvider_Type)(0), // 0: memos.store.IdentityProvider.Type
|
||||
(*IdentityProvider)(nil), // 1: memos.store.IdentityProvider
|
||||
(*IdentityProviderConfig)(nil), // 2: memos.store.IdentityProviderConfig
|
||||
(*FieldMapping)(nil), // 3: memos.store.FieldMapping
|
||||
(*OAuth2Config)(nil), // 4: memos.store.OAuth2Config
|
||||
}
|
||||
var file_store_idp_proto_depIdxs = []int32{
|
||||
0, // 0: memos.store.IdentityProvider.type:type_name -> memos.store.IdentityProvider.Type
|
||||
2, // 1: memos.store.IdentityProvider.config:type_name -> memos.store.IdentityProviderConfig
|
||||
4, // 2: memos.store.IdentityProviderConfig.oauth2_config:type_name -> memos.store.OAuth2Config
|
||||
3, // 3: memos.store.OAuth2Config.field_mapping:type_name -> memos.store.FieldMapping
|
||||
4, // [4:4] is the sub-list for method output_type
|
||||
4, // [4:4] is the sub-list for method input_type
|
||||
4, // [4:4] is the sub-list for extension type_name
|
||||
4, // [4:4] is the sub-list for extension extendee
|
||||
0, // [0:4] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_store_idp_proto_init() }
|
||||
func file_store_idp_proto_init() {
|
||||
if File_store_idp_proto != nil {
|
||||
return
|
||||
}
|
||||
file_store_idp_proto_msgTypes[1].OneofWrappers = []any{
|
||||
(*IdentityProviderConfig_Oauth2Config)(nil),
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_store_idp_proto_rawDesc), len(file_store_idp_proto_rawDesc)),
|
||||
NumEnums: 1,
|
||||
NumMessages: 4,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_store_idp_proto_goTypes,
|
||||
DependencyIndexes: file_store_idp_proto_depIdxs,
|
||||
EnumInfos: file_store_idp_proto_enumTypes,
|
||||
MessageInfos: file_store_idp_proto_msgTypes,
|
||||
}.Build()
|
||||
File_store_idp_proto = out.File
|
||||
file_store_idp_proto_goTypes = nil
|
||||
file_store_idp_proto_depIdxs = nil
|
||||
}
|
||||
@@ -0,0 +1,351 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.11
|
||||
// protoc (unknown)
|
||||
// source: store/inbox.proto
|
||||
|
||||
package store
|
||||
|
||||
import (
|
||||
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 InboxMessage_Type int32
|
||||
|
||||
const (
|
||||
InboxMessage_TYPE_UNSPECIFIED InboxMessage_Type = 0
|
||||
// Memo comment notification.
|
||||
InboxMessage_MEMO_COMMENT InboxMessage_Type = 1
|
||||
// Memo mention notification.
|
||||
InboxMessage_MEMO_MENTION InboxMessage_Type = 2
|
||||
)
|
||||
|
||||
// Enum value maps for InboxMessage_Type.
|
||||
var (
|
||||
InboxMessage_Type_name = map[int32]string{
|
||||
0: "TYPE_UNSPECIFIED",
|
||||
1: "MEMO_COMMENT",
|
||||
2: "MEMO_MENTION",
|
||||
}
|
||||
InboxMessage_Type_value = map[string]int32{
|
||||
"TYPE_UNSPECIFIED": 0,
|
||||
"MEMO_COMMENT": 1,
|
||||
"MEMO_MENTION": 2,
|
||||
}
|
||||
)
|
||||
|
||||
func (x InboxMessage_Type) Enum() *InboxMessage_Type {
|
||||
p := new(InboxMessage_Type)
|
||||
*p = x
|
||||
return p
|
||||
}
|
||||
|
||||
func (x InboxMessage_Type) String() string {
|
||||
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
|
||||
}
|
||||
|
||||
func (InboxMessage_Type) Descriptor() protoreflect.EnumDescriptor {
|
||||
return file_store_inbox_proto_enumTypes[0].Descriptor()
|
||||
}
|
||||
|
||||
func (InboxMessage_Type) Type() protoreflect.EnumType {
|
||||
return &file_store_inbox_proto_enumTypes[0]
|
||||
}
|
||||
|
||||
func (x InboxMessage_Type) Number() protoreflect.EnumNumber {
|
||||
return protoreflect.EnumNumber(x)
|
||||
}
|
||||
|
||||
// Deprecated: Use InboxMessage_Type.Descriptor instead.
|
||||
func (InboxMessage_Type) EnumDescriptor() ([]byte, []int) {
|
||||
return file_store_inbox_proto_rawDescGZIP(), []int{0, 0}
|
||||
}
|
||||
|
||||
type InboxMessage struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
// The type of the inbox message.
|
||||
Type InboxMessage_Type `protobuf:"varint,1,opt,name=type,proto3,enum=memos.store.InboxMessage_Type" json:"type,omitempty"`
|
||||
// Types that are valid to be assigned to Payload:
|
||||
//
|
||||
// *InboxMessage_MemoComment
|
||||
// *InboxMessage_MemoMention
|
||||
Payload isInboxMessage_Payload `protobuf_oneof:"payload"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *InboxMessage) Reset() {
|
||||
*x = InboxMessage{}
|
||||
mi := &file_store_inbox_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *InboxMessage) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*InboxMessage) ProtoMessage() {}
|
||||
|
||||
func (x *InboxMessage) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_inbox_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 InboxMessage.ProtoReflect.Descriptor instead.
|
||||
func (*InboxMessage) Descriptor() ([]byte, []int) {
|
||||
return file_store_inbox_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *InboxMessage) GetType() InboxMessage_Type {
|
||||
if x != nil {
|
||||
return x.Type
|
||||
}
|
||||
return InboxMessage_TYPE_UNSPECIFIED
|
||||
}
|
||||
|
||||
func (x *InboxMessage) GetPayload() isInboxMessage_Payload {
|
||||
if x != nil {
|
||||
return x.Payload
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *InboxMessage) GetMemoComment() *InboxMessage_MemoCommentPayload {
|
||||
if x != nil {
|
||||
if x, ok := x.Payload.(*InboxMessage_MemoComment); ok {
|
||||
return x.MemoComment
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *InboxMessage) GetMemoMention() *InboxMessage_MemoMentionPayload {
|
||||
if x != nil {
|
||||
if x, ok := x.Payload.(*InboxMessage_MemoMention); ok {
|
||||
return x.MemoMention
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
type isInboxMessage_Payload interface {
|
||||
isInboxMessage_Payload()
|
||||
}
|
||||
|
||||
type InboxMessage_MemoComment struct {
|
||||
MemoComment *InboxMessage_MemoCommentPayload `protobuf:"bytes,2,opt,name=memo_comment,json=memoComment,proto3,oneof"`
|
||||
}
|
||||
|
||||
type InboxMessage_MemoMention struct {
|
||||
MemoMention *InboxMessage_MemoMentionPayload `protobuf:"bytes,3,opt,name=memo_mention,json=memoMention,proto3,oneof"`
|
||||
}
|
||||
|
||||
func (*InboxMessage_MemoComment) isInboxMessage_Payload() {}
|
||||
|
||||
func (*InboxMessage_MemoMention) isInboxMessage_Payload() {}
|
||||
|
||||
type InboxMessage_MemoCommentPayload struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
MemoId int32 `protobuf:"varint,1,opt,name=memo_id,json=memoId,proto3" json:"memo_id,omitempty"`
|
||||
RelatedMemoId int32 `protobuf:"varint,2,opt,name=related_memo_id,json=relatedMemoId,proto3" json:"related_memo_id,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoCommentPayload) Reset() {
|
||||
*x = InboxMessage_MemoCommentPayload{}
|
||||
mi := &file_store_inbox_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoCommentPayload) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*InboxMessage_MemoCommentPayload) ProtoMessage() {}
|
||||
|
||||
func (x *InboxMessage_MemoCommentPayload) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_inbox_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 InboxMessage_MemoCommentPayload.ProtoReflect.Descriptor instead.
|
||||
func (*InboxMessage_MemoCommentPayload) Descriptor() ([]byte, []int) {
|
||||
return file_store_inbox_proto_rawDescGZIP(), []int{0, 0}
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoCommentPayload) GetMemoId() int32 {
|
||||
if x != nil {
|
||||
return x.MemoId
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoCommentPayload) GetRelatedMemoId() int32 {
|
||||
if x != nil {
|
||||
return x.RelatedMemoId
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
type InboxMessage_MemoMentionPayload struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
MemoId int32 `protobuf:"varint,1,opt,name=memo_id,json=memoId,proto3" json:"memo_id,omitempty"`
|
||||
RelatedMemoId int32 `protobuf:"varint,2,opt,name=related_memo_id,json=relatedMemoId,proto3" json:"related_memo_id,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoMentionPayload) Reset() {
|
||||
*x = InboxMessage_MemoMentionPayload{}
|
||||
mi := &file_store_inbox_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoMentionPayload) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*InboxMessage_MemoMentionPayload) ProtoMessage() {}
|
||||
|
||||
func (x *InboxMessage_MemoMentionPayload) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_inbox_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 InboxMessage_MemoMentionPayload.ProtoReflect.Descriptor instead.
|
||||
func (*InboxMessage_MemoMentionPayload) Descriptor() ([]byte, []int) {
|
||||
return file_store_inbox_proto_rawDescGZIP(), []int{0, 1}
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoMentionPayload) GetMemoId() int32 {
|
||||
if x != nil {
|
||||
return x.MemoId
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *InboxMessage_MemoMentionPayload) GetRelatedMemoId() int32 {
|
||||
if x != nil {
|
||||
return x.RelatedMemoId
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
var File_store_inbox_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_store_inbox_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x11store/inbox.proto\x12\vmemos.store\"\xe3\x03\n" +
|
||||
"\fInboxMessage\x122\n" +
|
||||
"\x04type\x18\x01 \x01(\x0e2\x1e.memos.store.InboxMessage.TypeR\x04type\x12Q\n" +
|
||||
"\fmemo_comment\x18\x02 \x01(\v2,.memos.store.InboxMessage.MemoCommentPayloadH\x00R\vmemoComment\x12Q\n" +
|
||||
"\fmemo_mention\x18\x03 \x01(\v2,.memos.store.InboxMessage.MemoMentionPayloadH\x00R\vmemoMention\x1aU\n" +
|
||||
"\x12MemoCommentPayload\x12\x17\n" +
|
||||
"\amemo_id\x18\x01 \x01(\x05R\x06memoId\x12&\n" +
|
||||
"\x0frelated_memo_id\x18\x02 \x01(\x05R\rrelatedMemoId\x1aU\n" +
|
||||
"\x12MemoMentionPayload\x12\x17\n" +
|
||||
"\amemo_id\x18\x01 \x01(\x05R\x06memoId\x12&\n" +
|
||||
"\x0frelated_memo_id\x18\x02 \x01(\x05R\rrelatedMemoId\"@\n" +
|
||||
"\x04Type\x12\x14\n" +
|
||||
"\x10TYPE_UNSPECIFIED\x10\x00\x12\x10\n" +
|
||||
"\fMEMO_COMMENT\x10\x01\x12\x10\n" +
|
||||
"\fMEMO_MENTION\x10\x02B\t\n" +
|
||||
"\apayloadB\x95\x01\n" +
|
||||
"\x0fcom.memos.storeB\n" +
|
||||
"InboxProtoP\x01Z)github.com/usememos/memos/proto/gen/store\xa2\x02\x03MSX\xaa\x02\vMemos.Store\xca\x02\vMemos\\Store\xe2\x02\x17Memos\\Store\\GPBMetadata\xea\x02\fMemos::Storeb\x06proto3"
|
||||
|
||||
var (
|
||||
file_store_inbox_proto_rawDescOnce sync.Once
|
||||
file_store_inbox_proto_rawDescData []byte
|
||||
)
|
||||
|
||||
func file_store_inbox_proto_rawDescGZIP() []byte {
|
||||
file_store_inbox_proto_rawDescOnce.Do(func() {
|
||||
file_store_inbox_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_store_inbox_proto_rawDesc), len(file_store_inbox_proto_rawDesc)))
|
||||
})
|
||||
return file_store_inbox_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_store_inbox_proto_enumTypes = make([]protoimpl.EnumInfo, 1)
|
||||
var file_store_inbox_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
|
||||
var file_store_inbox_proto_goTypes = []any{
|
||||
(InboxMessage_Type)(0), // 0: memos.store.InboxMessage.Type
|
||||
(*InboxMessage)(nil), // 1: memos.store.InboxMessage
|
||||
(*InboxMessage_MemoCommentPayload)(nil), // 2: memos.store.InboxMessage.MemoCommentPayload
|
||||
(*InboxMessage_MemoMentionPayload)(nil), // 3: memos.store.InboxMessage.MemoMentionPayload
|
||||
}
|
||||
var file_store_inbox_proto_depIdxs = []int32{
|
||||
0, // 0: memos.store.InboxMessage.type:type_name -> memos.store.InboxMessage.Type
|
||||
2, // 1: memos.store.InboxMessage.memo_comment:type_name -> memos.store.InboxMessage.MemoCommentPayload
|
||||
3, // 2: memos.store.InboxMessage.memo_mention:type_name -> memos.store.InboxMessage.MemoMentionPayload
|
||||
3, // [3:3] is the sub-list for method output_type
|
||||
3, // [3:3] is the sub-list for method input_type
|
||||
3, // [3:3] is the sub-list for extension type_name
|
||||
3, // [3:3] is the sub-list for extension extendee
|
||||
0, // [0:3] is the sub-list for field type_name
|
||||
}
|
||||
|
||||
func init() { file_store_inbox_proto_init() }
|
||||
func file_store_inbox_proto_init() {
|
||||
if File_store_inbox_proto != nil {
|
||||
return
|
||||
}
|
||||
file_store_inbox_proto_msgTypes[0].OneofWrappers = []any{
|
||||
(*InboxMessage_MemoComment)(nil),
|
||||
(*InboxMessage_MemoMention)(nil),
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_store_inbox_proto_rawDesc), len(file_store_inbox_proto_rawDesc)),
|
||||
NumEnums: 1,
|
||||
NumMessages: 3,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_store_inbox_proto_goTypes,
|
||||
DependencyIndexes: file_store_inbox_proto_depIdxs,
|
||||
EnumInfos: file_store_inbox_proto_enumTypes,
|
||||
MessageInfos: file_store_inbox_proto_msgTypes,
|
||||
}.Build()
|
||||
File_store_inbox_proto = out.File
|
||||
file_store_inbox_proto_goTypes = nil
|
||||
file_store_inbox_proto_depIdxs = nil
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
@@ -0,0 +1,293 @@
|
||||
// Code generated by protoc-gen-go. DO NOT EDIT.
|
||||
// versions:
|
||||
// protoc-gen-go v1.36.11
|
||||
// protoc (unknown)
|
||||
// source: store/memo.proto
|
||||
|
||||
package store
|
||||
|
||||
import (
|
||||
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 MemoPayload struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Property *MemoPayload_Property `protobuf:"bytes,1,opt,name=property,proto3" json:"property,omitempty"`
|
||||
Location *MemoPayload_Location `protobuf:"bytes,2,opt,name=location,proto3" json:"location,omitempty"`
|
||||
Tags []string `protobuf:"bytes,3,rep,name=tags,proto3" json:"tags,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *MemoPayload) Reset() {
|
||||
*x = MemoPayload{}
|
||||
mi := &file_store_memo_proto_msgTypes[0]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *MemoPayload) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MemoPayload) ProtoMessage() {}
|
||||
|
||||
func (x *MemoPayload) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_memo_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 MemoPayload.ProtoReflect.Descriptor instead.
|
||||
func (*MemoPayload) Descriptor() ([]byte, []int) {
|
||||
return file_store_memo_proto_rawDescGZIP(), []int{0}
|
||||
}
|
||||
|
||||
func (x *MemoPayload) GetProperty() *MemoPayload_Property {
|
||||
if x != nil {
|
||||
return x.Property
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *MemoPayload) GetLocation() *MemoPayload_Location {
|
||||
if x != nil {
|
||||
return x.Location
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func (x *MemoPayload) GetTags() []string {
|
||||
if x != nil {
|
||||
return x.Tags
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// The calculated properties from the memo content.
|
||||
type MemoPayload_Property struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
HasLink bool `protobuf:"varint,1,opt,name=has_link,json=hasLink,proto3" json:"has_link,omitempty"`
|
||||
HasTaskList bool `protobuf:"varint,2,opt,name=has_task_list,json=hasTaskList,proto3" json:"has_task_list,omitempty"`
|
||||
HasCode bool `protobuf:"varint,3,opt,name=has_code,json=hasCode,proto3" json:"has_code,omitempty"`
|
||||
HasIncompleteTasks bool `protobuf:"varint,4,opt,name=has_incomplete_tasks,json=hasIncompleteTasks,proto3" json:"has_incomplete_tasks,omitempty"`
|
||||
// The title extracted from the first H1 heading, if present.
|
||||
Title string `protobuf:"bytes,5,opt,name=title,proto3" json:"title,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) Reset() {
|
||||
*x = MemoPayload_Property{}
|
||||
mi := &file_store_memo_proto_msgTypes[1]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MemoPayload_Property) ProtoMessage() {}
|
||||
|
||||
func (x *MemoPayload_Property) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_memo_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 MemoPayload_Property.ProtoReflect.Descriptor instead.
|
||||
func (*MemoPayload_Property) Descriptor() ([]byte, []int) {
|
||||
return file_store_memo_proto_rawDescGZIP(), []int{0, 0}
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) GetHasLink() bool {
|
||||
if x != nil {
|
||||
return x.HasLink
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) GetHasTaskList() bool {
|
||||
if x != nil {
|
||||
return x.HasTaskList
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) GetHasCode() bool {
|
||||
if x != nil {
|
||||
return x.HasCode
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) GetHasIncompleteTasks() bool {
|
||||
if x != nil {
|
||||
return x.HasIncompleteTasks
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Property) GetTitle() string {
|
||||
if x != nil {
|
||||
return x.Title
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
type MemoPayload_Location struct {
|
||||
state protoimpl.MessageState `protogen:"open.v1"`
|
||||
Placeholder string `protobuf:"bytes,1,opt,name=placeholder,proto3" json:"placeholder,omitempty"`
|
||||
Latitude float64 `protobuf:"fixed64,2,opt,name=latitude,proto3" json:"latitude,omitempty"`
|
||||
Longitude float64 `protobuf:"fixed64,3,opt,name=longitude,proto3" json:"longitude,omitempty"`
|
||||
unknownFields protoimpl.UnknownFields
|
||||
sizeCache protoimpl.SizeCache
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Location) Reset() {
|
||||
*x = MemoPayload_Location{}
|
||||
mi := &file_store_memo_proto_msgTypes[2]
|
||||
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
|
||||
ms.StoreMessageInfo(mi)
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Location) String() string {
|
||||
return protoimpl.X.MessageStringOf(x)
|
||||
}
|
||||
|
||||
func (*MemoPayload_Location) ProtoMessage() {}
|
||||
|
||||
func (x *MemoPayload_Location) ProtoReflect() protoreflect.Message {
|
||||
mi := &file_store_memo_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 MemoPayload_Location.ProtoReflect.Descriptor instead.
|
||||
func (*MemoPayload_Location) Descriptor() ([]byte, []int) {
|
||||
return file_store_memo_proto_rawDescGZIP(), []int{0, 1}
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Location) GetPlaceholder() string {
|
||||
if x != nil {
|
||||
return x.Placeholder
|
||||
}
|
||||
return ""
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Location) GetLatitude() float64 {
|
||||
if x != nil {
|
||||
return x.Latitude
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
func (x *MemoPayload_Location) GetLongitude() float64 {
|
||||
if x != nil {
|
||||
return x.Longitude
|
||||
}
|
||||
return 0
|
||||
}
|
||||
|
||||
var File_store_memo_proto protoreflect.FileDescriptor
|
||||
|
||||
const file_store_memo_proto_rawDesc = "" +
|
||||
"\n" +
|
||||
"\x10store/memo.proto\x12\vmemos.store\"\xb6\x03\n" +
|
||||
"\vMemoPayload\x12=\n" +
|
||||
"\bproperty\x18\x01 \x01(\v2!.memos.store.MemoPayload.PropertyR\bproperty\x12=\n" +
|
||||
"\blocation\x18\x02 \x01(\v2!.memos.store.MemoPayload.LocationR\blocation\x12\x12\n" +
|
||||
"\x04tags\x18\x03 \x03(\tR\x04tags\x1a\xac\x01\n" +
|
||||
"\bProperty\x12\x19\n" +
|
||||
"\bhas_link\x18\x01 \x01(\bR\ahasLink\x12\"\n" +
|
||||
"\rhas_task_list\x18\x02 \x01(\bR\vhasTaskList\x12\x19\n" +
|
||||
"\bhas_code\x18\x03 \x01(\bR\ahasCode\x120\n" +
|
||||
"\x14has_incomplete_tasks\x18\x04 \x01(\bR\x12hasIncompleteTasks\x12\x14\n" +
|
||||
"\x05title\x18\x05 \x01(\tR\x05title\x1af\n" +
|
||||
"\bLocation\x12 \n" +
|
||||
"\vplaceholder\x18\x01 \x01(\tR\vplaceholder\x12\x1a\n" +
|
||||
"\blatitude\x18\x02 \x01(\x01R\blatitude\x12\x1c\n" +
|
||||
"\tlongitude\x18\x03 \x01(\x01R\tlongitudeB\x94\x01\n" +
|
||||
"\x0fcom.memos.storeB\tMemoProtoP\x01Z)github.com/usememos/memos/proto/gen/store\xa2\x02\x03MSX\xaa\x02\vMemos.Store\xca\x02\vMemos\\Store\xe2\x02\x17Memos\\Store\\GPBMetadata\xea\x02\fMemos::Storeb\x06proto3"
|
||||
|
||||
var (
|
||||
file_store_memo_proto_rawDescOnce sync.Once
|
||||
file_store_memo_proto_rawDescData []byte
|
||||
)
|
||||
|
||||
func file_store_memo_proto_rawDescGZIP() []byte {
|
||||
file_store_memo_proto_rawDescOnce.Do(func() {
|
||||
file_store_memo_proto_rawDescData = protoimpl.X.CompressGZIP(unsafe.Slice(unsafe.StringData(file_store_memo_proto_rawDesc), len(file_store_memo_proto_rawDesc)))
|
||||
})
|
||||
return file_store_memo_proto_rawDescData
|
||||
}
|
||||
|
||||
var file_store_memo_proto_msgTypes = make([]protoimpl.MessageInfo, 3)
|
||||
var file_store_memo_proto_goTypes = []any{
|
||||
(*MemoPayload)(nil), // 0: memos.store.MemoPayload
|
||||
(*MemoPayload_Property)(nil), // 1: memos.store.MemoPayload.Property
|
||||
(*MemoPayload_Location)(nil), // 2: memos.store.MemoPayload.Location
|
||||
}
|
||||
var file_store_memo_proto_depIdxs = []int32{
|
||||
1, // 0: memos.store.MemoPayload.property:type_name -> memos.store.MemoPayload.Property
|
||||
2, // 1: memos.store.MemoPayload.location:type_name -> memos.store.MemoPayload.Location
|
||||
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_store_memo_proto_init() }
|
||||
func file_store_memo_proto_init() {
|
||||
if File_store_memo_proto != nil {
|
||||
return
|
||||
}
|
||||
type x struct{}
|
||||
out := protoimpl.TypeBuilder{
|
||||
File: protoimpl.DescBuilder{
|
||||
GoPackagePath: reflect.TypeOf(x{}).PkgPath(),
|
||||
RawDescriptor: unsafe.Slice(unsafe.StringData(file_store_memo_proto_rawDesc), len(file_store_memo_proto_rawDesc)),
|
||||
NumEnums: 0,
|
||||
NumMessages: 3,
|
||||
NumExtensions: 0,
|
||||
NumServices: 0,
|
||||
},
|
||||
GoTypes: file_store_memo_proto_goTypes,
|
||||
DependencyIndexes: file_store_memo_proto_depIdxs,
|
||||
MessageInfos: file_store_memo_proto_msgTypes,
|
||||
}.Build()
|
||||
File_store_memo_proto = out.File
|
||||
file_store_memo_proto_goTypes = nil
|
||||
file_store_memo_proto_depIdxs = nil
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user