bertychat

package
v2.63.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 28, 2020 License: Apache-2.0, MIT Imports: 16 Imported by: 0

Documentation

Overview

Package bertychat contains the top-level API that uses the Berty Protocol to implement the Berty Chat specific logic.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterChatServiceServer

func RegisterChatServiceServer(s *grpc.Server, srv ChatServiceServer)

Types

type ChatServiceClient

type ChatServiceClient interface {
	// InstanceShareableBertyID returns a Berty ID that can be shared as a string, QR code or deep link.
	InstanceShareableBertyID(ctx context.Context, in *InstanceShareableBertyID_Request, opts ...grpc.CallOption) (*InstanceShareableBertyID_Reply, error)
	// DevShareInstanceBertyID shares your Berty ID on a dev channel.
	// TODO: remove for public.
	DevShareInstanceBertyID(ctx context.Context, in *DevShareInstanceBertyID_Request, opts ...grpc.CallOption) (*DevShareInstanceBertyID_Reply, error)
}

ChatServiceClient is the client API for ChatService service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.

func NewChatServiceClient

func NewChatServiceClient(cc *grpc.ClientConn) ChatServiceClient

type ChatServiceServer

type ChatServiceServer interface {
	// InstanceShareableBertyID returns a Berty ID that can be shared as a string, QR code or deep link.
	InstanceShareableBertyID(context.Context, *InstanceShareableBertyID_Request) (*InstanceShareableBertyID_Reply, error)
	// DevShareInstanceBertyID shares your Berty ID on a dev channel.
	// TODO: remove for public.
	DevShareInstanceBertyID(context.Context, *DevShareInstanceBertyID_Request) (*DevShareInstanceBertyID_Reply, error)
}

ChatServiceServer is the server API for ChatService service.

func TestingService

func TestingService(ctx context.Context, t *testing.T, opts *TestingServiceOpts) (ChatServiceServer, func())

type DevShareInstanceBertyID

type DevShareInstanceBertyID struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*DevShareInstanceBertyID) Descriptor

func (*DevShareInstanceBertyID) Descriptor() ([]byte, []int)

func (*DevShareInstanceBertyID) ProtoMessage

func (*DevShareInstanceBertyID) ProtoMessage()

func (*DevShareInstanceBertyID) Reset

func (m *DevShareInstanceBertyID) Reset()

func (*DevShareInstanceBertyID) String

func (m *DevShareInstanceBertyID) String() string

func (*DevShareInstanceBertyID) XXX_DiscardUnknown

func (m *DevShareInstanceBertyID) XXX_DiscardUnknown()

func (*DevShareInstanceBertyID) XXX_Marshal

func (m *DevShareInstanceBertyID) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DevShareInstanceBertyID) XXX_Merge

func (m *DevShareInstanceBertyID) XXX_Merge(src proto.Message)

func (*DevShareInstanceBertyID) XXX_Size

func (m *DevShareInstanceBertyID) XXX_Size() int

func (*DevShareInstanceBertyID) XXX_Unmarshal

func (m *DevShareInstanceBertyID) XXX_Unmarshal(b []byte) error

type DevShareInstanceBertyID_Reply

type DevShareInstanceBertyID_Reply struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*DevShareInstanceBertyID_Reply) Descriptor

func (*DevShareInstanceBertyID_Reply) Descriptor() ([]byte, []int)

func (*DevShareInstanceBertyID_Reply) ProtoMessage

func (*DevShareInstanceBertyID_Reply) ProtoMessage()

func (*DevShareInstanceBertyID_Reply) Reset

func (m *DevShareInstanceBertyID_Reply) Reset()

func (*DevShareInstanceBertyID_Reply) String

func (*DevShareInstanceBertyID_Reply) XXX_DiscardUnknown

func (m *DevShareInstanceBertyID_Reply) XXX_DiscardUnknown()

func (*DevShareInstanceBertyID_Reply) XXX_Marshal

func (m *DevShareInstanceBertyID_Reply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DevShareInstanceBertyID_Reply) XXX_Merge

func (m *DevShareInstanceBertyID_Reply) XXX_Merge(src proto.Message)

func (*DevShareInstanceBertyID_Reply) XXX_Size

func (m *DevShareInstanceBertyID_Reply) XXX_Size() int

func (*DevShareInstanceBertyID_Reply) XXX_Unmarshal

func (m *DevShareInstanceBertyID_Reply) XXX_Unmarshal(b []byte) error

type DevShareInstanceBertyID_Request

type DevShareInstanceBertyID_Request struct {
	// reset will regenerate a new link
	Reset_               bool     `protobuf:"varint,1,opt,name=reset,proto3" json:"reset,omitempty"`
	DisplayName          string   `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*DevShareInstanceBertyID_Request) Descriptor

func (*DevShareInstanceBertyID_Request) Descriptor() ([]byte, []int)

func (*DevShareInstanceBertyID_Request) GetDisplayName

func (m *DevShareInstanceBertyID_Request) GetDisplayName() string

func (*DevShareInstanceBertyID_Request) GetReset_

func (m *DevShareInstanceBertyID_Request) GetReset_() bool

func (*DevShareInstanceBertyID_Request) ProtoMessage

func (*DevShareInstanceBertyID_Request) ProtoMessage()

func (*DevShareInstanceBertyID_Request) Reset

func (*DevShareInstanceBertyID_Request) String

func (*DevShareInstanceBertyID_Request) XXX_DiscardUnknown

func (m *DevShareInstanceBertyID_Request) XXX_DiscardUnknown()

func (*DevShareInstanceBertyID_Request) XXX_Marshal

func (m *DevShareInstanceBertyID_Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*DevShareInstanceBertyID_Request) XXX_Merge

func (m *DevShareInstanceBertyID_Request) XXX_Merge(src proto.Message)

func (*DevShareInstanceBertyID_Request) XXX_Size

func (m *DevShareInstanceBertyID_Request) XXX_Size() int

func (*DevShareInstanceBertyID_Request) XXX_Unmarshal

func (m *DevShareInstanceBertyID_Request) XXX_Unmarshal(b []byte) error

type InstanceShareableBertyID

type InstanceShareableBertyID struct {
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InstanceShareableBertyID) Descriptor

func (*InstanceShareableBertyID) Descriptor() ([]byte, []int)

func (*InstanceShareableBertyID) ProtoMessage

func (*InstanceShareableBertyID) ProtoMessage()

func (*InstanceShareableBertyID) Reset

func (m *InstanceShareableBertyID) Reset()

func (*InstanceShareableBertyID) String

func (m *InstanceShareableBertyID) String() string

func (*InstanceShareableBertyID) XXX_DiscardUnknown

func (m *InstanceShareableBertyID) XXX_DiscardUnknown()

func (*InstanceShareableBertyID) XXX_Marshal

func (m *InstanceShareableBertyID) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstanceShareableBertyID) XXX_Merge

func (m *InstanceShareableBertyID) XXX_Merge(src proto.Message)

func (*InstanceShareableBertyID) XXX_Size

func (m *InstanceShareableBertyID) XXX_Size() int

func (*InstanceShareableBertyID) XXX_Unmarshal

func (m *InstanceShareableBertyID) XXX_Unmarshal(b []byte) error

type InstanceShareableBertyID_Reply

type InstanceShareableBertyID_Reply struct {
	BertyID              string   `protobuf:"bytes,1,opt,name=berty_id,json=bertyId,proto3" json:"berty_id,omitempty"`
	DeepLink             string   `protobuf:"bytes,2,opt,name=deep_link,json=deepLink,proto3" json:"deep_link,omitempty"`
	HTMLURL              string   `protobuf:"bytes,3,opt,name=html_url,json=htmlUrl,proto3" json:"html_url,omitempty"`
	DisplayName          string   `protobuf:"bytes,4,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InstanceShareableBertyID_Reply) Descriptor

func (*InstanceShareableBertyID_Reply) Descriptor() ([]byte, []int)

func (*InstanceShareableBertyID_Reply) GetBertyID

func (m *InstanceShareableBertyID_Reply) GetBertyID() string
func (m *InstanceShareableBertyID_Reply) GetDeepLink() string

func (*InstanceShareableBertyID_Reply) GetDisplayName

func (m *InstanceShareableBertyID_Reply) GetDisplayName() string

func (*InstanceShareableBertyID_Reply) GetHTMLURL

func (m *InstanceShareableBertyID_Reply) GetHTMLURL() string

func (*InstanceShareableBertyID_Reply) ProtoMessage

func (*InstanceShareableBertyID_Reply) ProtoMessage()

func (*InstanceShareableBertyID_Reply) Reset

func (m *InstanceShareableBertyID_Reply) Reset()

func (*InstanceShareableBertyID_Reply) String

func (*InstanceShareableBertyID_Reply) XXX_DiscardUnknown

func (m *InstanceShareableBertyID_Reply) XXX_DiscardUnknown()

func (*InstanceShareableBertyID_Reply) XXX_Marshal

func (m *InstanceShareableBertyID_Reply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstanceShareableBertyID_Reply) XXX_Merge

func (m *InstanceShareableBertyID_Reply) XXX_Merge(src proto.Message)

func (*InstanceShareableBertyID_Reply) XXX_Size

func (m *InstanceShareableBertyID_Reply) XXX_Size() int

func (*InstanceShareableBertyID_Reply) XXX_Unmarshal

func (m *InstanceShareableBertyID_Reply) XXX_Unmarshal(b []byte) error

type InstanceShareableBertyID_Request

type InstanceShareableBertyID_Request struct {
	// reset will regenerate a new link
	Reset_               bool     `protobuf:"varint,1,opt,name=reset,proto3" json:"reset,omitempty"`
	DisplayName          string   `protobuf:"bytes,2,opt,name=display_name,json=displayName,proto3" json:"display_name,omitempty"`
	XXX_NoUnkeyedLiteral struct{} `json:"-"`
	XXX_unrecognized     []byte   `json:"-"`
	XXX_sizecache        int32    `json:"-"`
}

func (*InstanceShareableBertyID_Request) Descriptor

func (*InstanceShareableBertyID_Request) Descriptor() ([]byte, []int)

func (*InstanceShareableBertyID_Request) GetDisplayName

func (m *InstanceShareableBertyID_Request) GetDisplayName() string

func (*InstanceShareableBertyID_Request) GetReset_

func (m *InstanceShareableBertyID_Request) GetReset_() bool

func (*InstanceShareableBertyID_Request) ProtoMessage

func (*InstanceShareableBertyID_Request) ProtoMessage()

func (*InstanceShareableBertyID_Request) Reset

func (*InstanceShareableBertyID_Request) String

func (*InstanceShareableBertyID_Request) XXX_DiscardUnknown

func (m *InstanceShareableBertyID_Request) XXX_DiscardUnknown()

func (*InstanceShareableBertyID_Request) XXX_Marshal

func (m *InstanceShareableBertyID_Request) XXX_Marshal(b []byte, deterministic bool) ([]byte, error)

func (*InstanceShareableBertyID_Request) XXX_Merge

func (*InstanceShareableBertyID_Request) XXX_Size

func (m *InstanceShareableBertyID_Request) XXX_Size() int

func (*InstanceShareableBertyID_Request) XXX_Unmarshal

func (m *InstanceShareableBertyID_Request) XXX_Unmarshal(b []byte) error

type Opts

type Opts struct {
	Logger *zap.Logger
}

type TestingServiceOpts

type TestingServiceOpts struct {
	Logger *zap.Logger
	Client bertyprotocol.Client
}

type UnimplementedChatServiceServer

type UnimplementedChatServiceServer struct {
}

UnimplementedChatServiceServer can be embedded to have forward compatible implementations.

func (*UnimplementedChatServiceServer) DevShareInstanceBertyID

func (*UnimplementedChatServiceServer) InstanceShareableBertyID

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL