ricochet-go/rpc/contact.pb.go

519 lines
17 KiB
Go
Raw Normal View History

2016-08-17 00:43:39 +00:00
// Code generated by protoc-gen-go.
// source: contact.proto
// DO NOT EDIT!
/*
Package ricochet is a generated protocol buffer package.
It is generated from these files:
contact.proto
conversation.proto
core.proto
identity.proto
network.proto
config.proto
It has these top-level messages:
Contact
ContactRequest
MonitorContactsRequest
ContactEvent
AddContactReply
DeleteContactRequest
DeleteContactReply
RejectInboundRequestReply
ConversationEvent
MonitorConversationsRequest
Entity
Message
MarkConversationReadRequest
Reply
ServerStatusRequest
ServerStatusReply
Identity
IdentityRequest
MonitorNetworkRequest
TorProcessStatus
TorControlStatus
TorConnectionStatus
NetworkStatus
StartNetworkRequest
StopNetworkRequest
Config
Secrets
*/
2016-08-17 00:43:39 +00:00
package ricochet
import proto "github.com/golang/protobuf/proto"
import fmt "fmt"
import math "math"
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
2016-08-17 00:43:39 +00:00
type Contact_Status int32
const (
Contact_UNKNOWN Contact_Status = 0
Contact_OFFLINE Contact_Status = 1
Contact_ONLINE Contact_Status = 2
Contact_REQUEST Contact_Status = 3
Contact_REJECTED Contact_Status = 4
2016-08-17 00:43:39 +00:00
)
var Contact_Status_name = map[int32]string{
0: "UNKNOWN",
1: "OFFLINE",
2: "ONLINE",
3: "REQUEST",
4: "REJECTED",
2016-08-17 00:43:39 +00:00
}
var Contact_Status_value = map[string]int32{
"UNKNOWN": 0,
"OFFLINE": 1,
"ONLINE": 2,
"REQUEST": 3,
"REJECTED": 4,
2016-08-17 00:43:39 +00:00
}
func (x Contact_Status) String() string {
return proto.EnumName(Contact_Status_name, int32(x))
}
func (Contact_Status) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
2016-08-17 00:43:39 +00:00
type ContactRequest_Direction int32
const (
ContactRequest_INBOUND ContactRequest_Direction = 0
ContactRequest_OUTBOUND ContactRequest_Direction = 1
)
var ContactRequest_Direction_name = map[int32]string{
0: "INBOUND",
1: "OUTBOUND",
}
var ContactRequest_Direction_value = map[string]int32{
"INBOUND": 0,
"OUTBOUND": 1,
}
func (x ContactRequest_Direction) String() string {
return proto.EnumName(ContactRequest_Direction_name, int32(x))
}
func (ContactRequest_Direction) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{1, 0} }
2016-08-17 00:43:39 +00:00
type ContactEvent_Type int32
const (
ContactEvent_NULL ContactEvent_Type = 0
ContactEvent_POPULATE ContactEvent_Type = 1
ContactEvent_ADD ContactEvent_Type = 2
ContactEvent_UPDATE ContactEvent_Type = 3
ContactEvent_DELETE ContactEvent_Type = 4
)
var ContactEvent_Type_name = map[int32]string{
0: "NULL",
1: "POPULATE",
2: "ADD",
3: "UPDATE",
4: "DELETE",
}
var ContactEvent_Type_value = map[string]int32{
"NULL": 0,
"POPULATE": 1,
"ADD": 2,
"UPDATE": 3,
"DELETE": 4,
}
func (x ContactEvent_Type) String() string {
return proto.EnumName(ContactEvent_Type_name, int32(x))
}
func (ContactEvent_Type) EnumDescriptor() ([]byte, []int) { return fileDescriptor0, []int{3, 0} }
2016-08-17 00:43:39 +00:00
type Contact struct {
Address string `protobuf:"bytes,2,opt,name=address" json:"address,omitempty"`
Nickname string `protobuf:"bytes,3,opt,name=nickname" json:"nickname,omitempty"`
WhenCreated string `protobuf:"bytes,4,opt,name=whenCreated" json:"whenCreated,omitempty"`
LastConnected string `protobuf:"bytes,5,opt,name=lastConnected" json:"lastConnected,omitempty"`
Request *ContactRequest `protobuf:"bytes,6,opt,name=request" json:"request,omitempty"`
Status Contact_Status `protobuf:"varint,10,opt,name=status,enum=ricochet.Contact_Status" json:"status,omitempty"`
}
func (m *Contact) Reset() { *m = Contact{} }
func (m *Contact) String() string { return proto.CompactTextString(m) }
func (*Contact) ProtoMessage() {}
func (*Contact) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
2016-08-17 00:43:39 +00:00
2016-12-01 03:37:46 +00:00
func (m *Contact) GetAddress() string {
if m != nil {
return m.Address
}
return ""
}
func (m *Contact) GetNickname() string {
if m != nil {
return m.Nickname
}
return ""
}
func (m *Contact) GetWhenCreated() string {
if m != nil {
return m.WhenCreated
}
return ""
}
func (m *Contact) GetLastConnected() string {
if m != nil {
return m.LastConnected
}
return ""
}
2016-08-17 00:43:39 +00:00
func (m *Contact) GetRequest() *ContactRequest {
if m != nil {
return m.Request
}
return nil
}
2016-12-01 03:37:46 +00:00
func (m *Contact) GetStatus() Contact_Status {
if m != nil {
return m.Status
}
return Contact_UNKNOWN
}
2016-08-17 00:43:39 +00:00
type ContactRequest struct {
Direction ContactRequest_Direction `protobuf:"varint,1,opt,name=direction,enum=ricochet.ContactRequest_Direction" json:"direction,omitempty"`
Address string `protobuf:"bytes,2,opt,name=address" json:"address,omitempty"`
Nickname string `protobuf:"bytes,3,opt,name=nickname" json:"nickname,omitempty"`
Text string `protobuf:"bytes,4,opt,name=text" json:"text,omitempty"`
FromNickname string `protobuf:"bytes,5,opt,name=fromNickname" json:"fromNickname,omitempty"`
WhenCreated string `protobuf:"bytes,6,opt,name=whenCreated" json:"whenCreated,omitempty"`
Rejected bool `protobuf:"varint,7,opt,name=rejected" json:"rejected,omitempty"`
WhenDelivered string `protobuf:"bytes,8,opt,name=whenDelivered" json:"whenDelivered,omitempty"`
WhenRejected string `protobuf:"bytes,9,opt,name=whenRejected" json:"whenRejected,omitempty"`
RemoteError string `protobuf:"bytes,10,opt,name=remoteError" json:"remoteError,omitempty"`
2016-08-17 00:43:39 +00:00
}
func (m *ContactRequest) Reset() { *m = ContactRequest{} }
func (m *ContactRequest) String() string { return proto.CompactTextString(m) }
func (*ContactRequest) ProtoMessage() {}
func (*ContactRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
2016-08-17 00:43:39 +00:00
2016-12-01 03:37:46 +00:00
func (m *ContactRequest) GetDirection() ContactRequest_Direction {
if m != nil {
return m.Direction
}
return ContactRequest_INBOUND
}
func (m *ContactRequest) GetAddress() string {
if m != nil {
return m.Address
}
return ""
}
func (m *ContactRequest) GetNickname() string {
if m != nil {
return m.Nickname
}
return ""
}
func (m *ContactRequest) GetText() string {
if m != nil {
return m.Text
}
return ""
}
func (m *ContactRequest) GetFromNickname() string {
if m != nil {
return m.FromNickname
}
return ""
}
func (m *ContactRequest) GetWhenCreated() string {
if m != nil {
return m.WhenCreated
}
return ""
}
func (m *ContactRequest) GetRejected() bool {
if m != nil {
return m.Rejected
}
return false
}
func (m *ContactRequest) GetWhenDelivered() string {
if m != nil {
return m.WhenDelivered
}
return ""
}
func (m *ContactRequest) GetWhenRejected() string {
if m != nil {
return m.WhenRejected
}
return ""
}
func (m *ContactRequest) GetRemoteError() string {
if m != nil {
return m.RemoteError
}
return ""
}
2016-08-17 00:43:39 +00:00
type MonitorContactsRequest struct {
}
func (m *MonitorContactsRequest) Reset() { *m = MonitorContactsRequest{} }
func (m *MonitorContactsRequest) String() string { return proto.CompactTextString(m) }
func (*MonitorContactsRequest) ProtoMessage() {}
func (*MonitorContactsRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
2016-08-17 00:43:39 +00:00
type ContactEvent struct {
Type ContactEvent_Type `protobuf:"varint,1,opt,name=type,enum=ricochet.ContactEvent_Type" json:"type,omitempty"`
// Types that are valid to be assigned to Subject:
// *ContactEvent_Contact
// *ContactEvent_Request
Subject isContactEvent_Subject `protobuf_oneof:"subject"`
}
func (m *ContactEvent) Reset() { *m = ContactEvent{} }
func (m *ContactEvent) String() string { return proto.CompactTextString(m) }
func (*ContactEvent) ProtoMessage() {}
func (*ContactEvent) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
2016-08-17 00:43:39 +00:00
type isContactEvent_Subject interface {
isContactEvent_Subject()
}
type ContactEvent_Contact struct {
Contact *Contact `protobuf:"bytes,2,opt,name=contact,oneof"`
}
type ContactEvent_Request struct {
Request *ContactRequest `protobuf:"bytes,3,opt,name=request,oneof"`
}
func (*ContactEvent_Contact) isContactEvent_Subject() {}
func (*ContactEvent_Request) isContactEvent_Subject() {}
func (m *ContactEvent) GetSubject() isContactEvent_Subject {
if m != nil {
return m.Subject
}
return nil
}
2016-12-01 03:37:46 +00:00
func (m *ContactEvent) GetType() ContactEvent_Type {
if m != nil {
return m.Type
}
return ContactEvent_NULL
}
2016-08-17 00:43:39 +00:00
func (m *ContactEvent) GetContact() *Contact {
if x, ok := m.GetSubject().(*ContactEvent_Contact); ok {
return x.Contact
}
return nil
}
func (m *ContactEvent) GetRequest() *ContactRequest {
if x, ok := m.GetSubject().(*ContactEvent_Request); ok {
return x.Request
}
return nil
}
// XXX_OneofFuncs is for the internal use of the proto package.
func (*ContactEvent) XXX_OneofFuncs() (func(msg proto.Message, b *proto.Buffer) error, func(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error), func(msg proto.Message) (n int), []interface{}) {
return _ContactEvent_OneofMarshaler, _ContactEvent_OneofUnmarshaler, _ContactEvent_OneofSizer, []interface{}{
(*ContactEvent_Contact)(nil),
(*ContactEvent_Request)(nil),
}
}
func _ContactEvent_OneofMarshaler(msg proto.Message, b *proto.Buffer) error {
m := msg.(*ContactEvent)
// subject
switch x := m.Subject.(type) {
case *ContactEvent_Contact:
b.EncodeVarint(2<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Contact); err != nil {
return err
}
case *ContactEvent_Request:
b.EncodeVarint(3<<3 | proto.WireBytes)
if err := b.EncodeMessage(x.Request); err != nil {
return err
}
case nil:
default:
return fmt.Errorf("ContactEvent.Subject has unexpected type %T", x)
}
return nil
}
func _ContactEvent_OneofUnmarshaler(msg proto.Message, tag, wire int, b *proto.Buffer) (bool, error) {
m := msg.(*ContactEvent)
switch tag {
case 2: // subject.contact
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(Contact)
err := b.DecodeMessage(msg)
m.Subject = &ContactEvent_Contact{msg}
return true, err
case 3: // subject.request
if wire != proto.WireBytes {
return true, proto.ErrInternalBadWireType
}
msg := new(ContactRequest)
err := b.DecodeMessage(msg)
m.Subject = &ContactEvent_Request{msg}
return true, err
default:
return false, nil
}
}
func _ContactEvent_OneofSizer(msg proto.Message) (n int) {
m := msg.(*ContactEvent)
// subject
switch x := m.Subject.(type) {
case *ContactEvent_Contact:
s := proto.Size(x.Contact)
n += proto.SizeVarint(2<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case *ContactEvent_Request:
s := proto.Size(x.Request)
n += proto.SizeVarint(3<<3 | proto.WireBytes)
n += proto.SizeVarint(uint64(s))
n += s
case nil:
default:
panic(fmt.Sprintf("proto: unexpected type %T in oneof", x))
}
return n
}
type AddContactReply struct {
}
func (m *AddContactReply) Reset() { *m = AddContactReply{} }
func (m *AddContactReply) String() string { return proto.CompactTextString(m) }
func (*AddContactReply) ProtoMessage() {}
func (*AddContactReply) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{4} }
2016-08-17 00:43:39 +00:00
type DeleteContactRequest struct {
Address string `protobuf:"bytes,1,opt,name=address" json:"address,omitempty"`
2016-08-17 00:43:39 +00:00
}
func (m *DeleteContactRequest) Reset() { *m = DeleteContactRequest{} }
func (m *DeleteContactRequest) String() string { return proto.CompactTextString(m) }
func (*DeleteContactRequest) ProtoMessage() {}
func (*DeleteContactRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} }
2016-08-17 00:43:39 +00:00
2016-12-01 03:37:46 +00:00
func (m *DeleteContactRequest) GetAddress() string {
if m != nil {
return m.Address
}
return ""
}
2016-08-17 00:43:39 +00:00
type DeleteContactReply struct {
}
func (m *DeleteContactReply) Reset() { *m = DeleteContactReply{} }
func (m *DeleteContactReply) String() string { return proto.CompactTextString(m) }
func (*DeleteContactReply) ProtoMessage() {}
func (*DeleteContactReply) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{6} }
2016-08-17 00:43:39 +00:00
type RejectInboundRequestReply struct {
}
func (m *RejectInboundRequestReply) Reset() { *m = RejectInboundRequestReply{} }
func (m *RejectInboundRequestReply) String() string { return proto.CompactTextString(m) }
func (*RejectInboundRequestReply) ProtoMessage() {}
func (*RejectInboundRequestReply) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{7} }
2016-08-17 00:43:39 +00:00
func init() {
proto.RegisterType((*Contact)(nil), "ricochet.Contact")
proto.RegisterType((*ContactRequest)(nil), "ricochet.ContactRequest")
proto.RegisterType((*MonitorContactsRequest)(nil), "ricochet.MonitorContactsRequest")
proto.RegisterType((*ContactEvent)(nil), "ricochet.ContactEvent")
proto.RegisterType((*AddContactReply)(nil), "ricochet.AddContactReply")
proto.RegisterType((*DeleteContactRequest)(nil), "ricochet.DeleteContactRequest")
proto.RegisterType((*DeleteContactReply)(nil), "ricochet.DeleteContactReply")
proto.RegisterType((*RejectInboundRequestReply)(nil), "ricochet.RejectInboundRequestReply")
proto.RegisterEnum("ricochet.Contact_Status", Contact_Status_name, Contact_Status_value)
proto.RegisterEnum("ricochet.ContactRequest_Direction", ContactRequest_Direction_name, ContactRequest_Direction_value)
proto.RegisterEnum("ricochet.ContactEvent_Type", ContactEvent_Type_name, ContactEvent_Type_value)
}
func init() { proto.RegisterFile("contact.proto", fileDescriptor0) }
2016-08-17 00:43:39 +00:00
var fileDescriptor0 = []byte{
// 569 bytes of a gzipped FileDescriptorProto
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x09, 0x6e, 0x88, 0x02, 0xff, 0x9c, 0x54, 0x5d, 0x73, 0x93, 0x40,
0x14, 0x2d, 0x01, 0xf9, 0xb8, 0x69, 0x2b, 0xdd, 0xe9, 0x38, 0xd8, 0xbe, 0x64, 0x76, 0x1c, 0x27,
0x2f, 0x62, 0xa7, 0xfa, 0xae, 0x6d, 0xa0, 0x63, 0x34, 0x42, 0xdd, 0xc2, 0xf8, 0x4c, 0x61, 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