diff --git a/rpc/contact.pb.go b/rpc/contact.pb.go index 763ec43..aa51a84 100644 --- a/rpc/contact.pb.go +++ b/rpc/contact.pb.go @@ -152,6 +152,41 @@ func (m *Contact) String() string { return proto.CompactTextString(m) func (*Contact) ProtoMessage() {} func (*Contact) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} } +func (m *Contact) GetId() int32 { + if m != nil { + return m.Id + } + return 0 +} + +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 "" +} + func (m *Contact) GetRequest() *ContactRequest { if m != nil { return m.Request @@ -159,6 +194,13 @@ func (m *Contact) GetRequest() *ContactRequest { return nil } +func (m *Contact) GetStatus() Contact_Status { + if m != nil { + return m.Status + } + return Contact_UNKNOWN +} + 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"` @@ -172,6 +214,41 @@ func (m *ContactRequest) String() string { return proto.CompactTextSt func (*ContactRequest) ProtoMessage() {} func (*ContactRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} } +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 "" +} + type MonitorContactsRequest struct { } @@ -214,6 +291,13 @@ func (m *ContactEvent) GetSubject() isContactEvent_Subject { return nil } +func (m *ContactEvent) GetType() ContactEvent_Type { + if m != nil { + return m.Type + } + return ContactEvent_NULL +} + func (m *ContactEvent) GetContact() *Contact { if x, ok := m.GetSubject().(*ContactEvent_Contact); ok { return x.Contact @@ -320,6 +404,20 @@ func (m *DeleteContactRequest) String() string { return proto.Compact func (*DeleteContactRequest) ProtoMessage() {} func (*DeleteContactRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{5} } +func (m *DeleteContactRequest) GetId() int32 { + if m != nil { + return m.Id + } + return 0 +} + +func (m *DeleteContactRequest) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + type DeleteContactReply struct { } diff --git a/rpc/conversation.pb.go b/rpc/conversation.pb.go index 7a7b8aa..8dfa931 100644 --- a/rpc/conversation.pb.go +++ b/rpc/conversation.pb.go @@ -91,6 +91,13 @@ func (m *ConversationEvent) String() string { return proto.CompactTex func (*ConversationEvent) ProtoMessage() {} func (*ConversationEvent) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{0} } +func (m *ConversationEvent) GetType() ConversationEvent_Type { + if m != nil { + return m.Type + } + return ConversationEvent_NULL +} + func (m *ConversationEvent) GetMsg() *Message { if m != nil { return m.Msg @@ -118,6 +125,27 @@ func (m *Entity) String() string { return proto.CompactTextString(m) func (*Entity) ProtoMessage() {} func (*Entity) Descriptor() ([]byte, []int) { return fileDescriptor1, []int{2} } +func (m *Entity) GetContactId() int32 { + if m != nil { + return m.ContactId + } + return 0 +} + +func (m *Entity) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + +func (m *Entity) GetIsSelf() bool { + if m != nil { + return m.IsSelf + } + return false +} + type Message struct { Sender *Entity `protobuf:"bytes,1,opt,name=sender" json:"sender,omitempty"` Recipient *Entity `protobuf:"bytes,2,opt,name=recipient" json:"recipient,omitempty"` @@ -149,6 +177,34 @@ func (m *Message) GetRecipient() *Entity { return nil } +func (m *Message) GetTimestamp() int64 { + if m != nil { + return m.Timestamp + } + return 0 +} + +func (m *Message) GetIdentifier() uint64 { + if m != nil { + return m.Identifier + } + return 0 +} + +func (m *Message) GetStatus() Message_Status { + if m != nil { + return m.Status + } + return Message_NULL +} + +func (m *Message) GetText() string { + if m != nil { + return m.Text + } + return "" +} + type MarkConversationReadRequest struct { Entity *Entity `protobuf:"bytes,1,opt,name=entity" json:"entity,omitempty"` LastRecvIdentifier uint64 `protobuf:"varint,2,opt,name=lastRecvIdentifier" json:"lastRecvIdentifier,omitempty"` @@ -166,6 +222,13 @@ func (m *MarkConversationReadRequest) GetEntity() *Entity { return nil } +func (m *MarkConversationReadRequest) GetLastRecvIdentifier() uint64 { + if m != nil { + return m.LastRecvIdentifier + } + return 0 +} + func init() { proto.RegisterType((*ConversationEvent)(nil), "ricochet.ConversationEvent") proto.RegisterType((*MonitorConversationsRequest)(nil), "ricochet.MonitorConversationsRequest") diff --git a/rpc/core.pb.go b/rpc/core.pb.go index 30b6b7b..f4eb18a 100644 --- a/rpc/core.pb.go +++ b/rpc/core.pb.go @@ -35,6 +35,13 @@ func (m *ServerStatusRequest) String() string { return proto.CompactT func (*ServerStatusRequest) ProtoMessage() {} func (*ServerStatusRequest) Descriptor() ([]byte, []int) { return fileDescriptor2, []int{1} } +func (m *ServerStatusRequest) GetRpcVersion() int32 { + if m != nil { + return m.RpcVersion + } + return 0 +} + type ServerStatusReply struct { RpcVersion int32 `protobuf:"varint,1,opt,name=rpcVersion" json:"rpcVersion,omitempty"` ServerVersion string `protobuf:"bytes,2,opt,name=serverVersion" json:"serverVersion,omitempty"` @@ -45,6 +52,20 @@ func (m *ServerStatusReply) String() string { return proto.CompactTex func (*ServerStatusReply) ProtoMessage() {} func (*ServerStatusReply) Descriptor() ([]byte, []int) { return fileDescriptor2, []int{2} } +func (m *ServerStatusReply) GetRpcVersion() int32 { + if m != nil { + return m.RpcVersion + } + return 0 +} + +func (m *ServerStatusReply) GetServerVersion() string { + if m != nil { + return m.ServerVersion + } + return "" +} + func init() { proto.RegisterType((*Reply)(nil), "ricochet.Reply") proto.RegisterType((*ServerStatusRequest)(nil), "ricochet.ServerStatusRequest") @@ -57,7 +78,7 @@ var _ grpc.ClientConn // This is a compile-time assertion to ensure that this generated file // is compatible with the grpc package it is being compiled against. -const _ = grpc.SupportPackageIsVersion3 +const _ = grpc.SupportPackageIsVersion4 // Client API for RicochetCore service @@ -78,7 +99,6 @@ type RicochetCoreClient interface { // Stop all network connections and go offline. Blocks until the network // has been taken offline, and returns the new network status. StopNetwork(ctx context.Context, in *StopNetworkRequest, opts ...grpc.CallOption) (*NetworkStatus, error) - // XXX Service status GetIdentity(ctx context.Context, in *IdentityRequest, opts ...grpc.CallOption) (*Identity, error) // Query contacts and monitor for contact changes. The full contact list // is sent in POPULATE events, terminated by a POPULATE event with no @@ -319,7 +339,6 @@ type RicochetCoreServer interface { // Stop all network connections and go offline. Blocks until the network // has been taken offline, and returns the new network status. StopNetwork(context.Context, *StopNetworkRequest) (*NetworkStatus, error) - // XXX Service status GetIdentity(context.Context, *IdentityRequest) (*Identity, error) // Query contacts and monitor for contact changes. The full contact list // is sent in POPULATE events, terminated by a POPULATE event with no @@ -669,7 +688,7 @@ var _RicochetCore_serviceDesc = grpc.ServiceDesc{ ServerStreams: true, }, }, - Metadata: fileDescriptor2, + Metadata: "core.proto", } func init() { proto.RegisterFile("core.proto", fileDescriptor2) } diff --git a/rpc/identity.pb.go b/rpc/identity.pb.go index 6a99cd5..b0c0778 100644 --- a/rpc/identity.pb.go +++ b/rpc/identity.pb.go @@ -22,6 +22,13 @@ func (m *Identity) String() string { return proto.CompactTextString(m func (*Identity) ProtoMessage() {} func (*Identity) Descriptor() ([]byte, []int) { return fileDescriptor3, []int{0} } +func (m *Identity) GetAddress() string { + if m != nil { + return m.Address + } + return "" +} + type IdentityRequest struct { } diff --git a/rpc/network.pb.go b/rpc/network.pb.go index 07c1e63..464c3fc 100644 --- a/rpc/network.pb.go +++ b/rpc/network.pb.go @@ -114,6 +114,20 @@ func (m *TorProcessStatus) String() string { return proto.CompactText func (*TorProcessStatus) ProtoMessage() {} func (*TorProcessStatus) Descriptor() ([]byte, []int) { return fileDescriptor4, []int{1} } +func (m *TorProcessStatus) GetStatus() TorProcessStatus_Status { + if m != nil { + return m.Status + } + return TorProcessStatus_DISABLED +} + +func (m *TorProcessStatus) GetErrorMessage() string { + if m != nil { + return m.ErrorMessage + } + return "" +} + type TorControlStatus struct { Status TorControlStatus_Status `protobuf:"varint,1,opt,name=status,enum=ricochet.TorControlStatus_Status" json:"status,omitempty"` ErrorMessage string `protobuf:"bytes,2,opt,name=errorMessage" json:"errorMessage,omitempty"` @@ -125,6 +139,27 @@ func (m *TorControlStatus) String() string { return proto.CompactText func (*TorControlStatus) ProtoMessage() {} func (*TorControlStatus) Descriptor() ([]byte, []int) { return fileDescriptor4, []int{2} } +func (m *TorControlStatus) GetStatus() TorControlStatus_Status { + if m != nil { + return m.Status + } + return TorControlStatus_STOPPED +} + +func (m *TorControlStatus) GetErrorMessage() string { + if m != nil { + return m.ErrorMessage + } + return "" +} + +func (m *TorControlStatus) GetTorVersion() string { + if m != nil { + return m.TorVersion + } + return "" +} + type TorConnectionStatus struct { Status TorConnectionStatus_Status `protobuf:"varint,1,opt,name=status,enum=ricochet.TorConnectionStatus_Status" json:"status,omitempty"` BootstrapProgress string `protobuf:"bytes,10,opt,name=bootstrapProgress" json:"bootstrapProgress,omitempty"` @@ -136,6 +171,27 @@ func (m *TorConnectionStatus) String() string { return proto.CompactT func (*TorConnectionStatus) ProtoMessage() {} func (*TorConnectionStatus) Descriptor() ([]byte, []int) { return fileDescriptor4, []int{3} } +func (m *TorConnectionStatus) GetStatus() TorConnectionStatus_Status { + if m != nil { + return m.Status + } + return TorConnectionStatus_UNKNOWN +} + +func (m *TorConnectionStatus) GetBootstrapProgress() string { + if m != nil { + return m.BootstrapProgress + } + return "" +} + +func (m *TorConnectionStatus) GetSocksAddress() []string { + if m != nil { + return m.SocksAddress + } + return nil +} + type NetworkStatus struct { Process *TorProcessStatus `protobuf:"bytes,1,opt,name=process" json:"process,omitempty"` Control *TorControlStatus `protobuf:"bytes,2,opt,name=control" json:"control,omitempty"`