didcomm

package
v0.1.6-0...-5c25bcb Latest Latest
Warning

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

Go to latest
Published: Feb 1, 2021 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockAuthCrypt

type MockAuthCrypt struct {
	EncryptValue func(payload, senderPubKey []byte, recipients [][]byte) ([]byte, error)
	DecryptValue func(envelope []byte) (*transport.Envelope, error)
	Type         string
}

MockAuthCrypt mock auth crypt.

func (*MockAuthCrypt) EncodingType

func (m *MockAuthCrypt) EncodingType() string

EncodingType mock encoding type.

func (*MockAuthCrypt) Pack

func (m *MockAuthCrypt) Pack(payload, senderPubKey []byte,
	recipients [][]byte) ([]byte, error)

Pack mock message packing.

func (*MockAuthCrypt) Unpack

func (m *MockAuthCrypt) Unpack(envelope []byte) (*transport.Envelope, error)

Unpack mock message unpacking.

type MockOutboundTransport

type MockOutboundTransport struct {
	ExpectedResponse string
	SendErr          error
	AcceptValue      bool
}

MockOutboundTransport mock outbound transport structure.

func NewMockOutboundTransport

func NewMockOutboundTransport(expectedResponse string) *MockOutboundTransport

NewMockOutboundTransport new MockOutboundTransport instance.

func (*MockOutboundTransport) Accept

func (o *MockOutboundTransport) Accept(url string) bool

Accept url.

func (*MockOutboundTransport) AcceptRecipient

func (o *MockOutboundTransport) AcceptRecipient([]string) bool

AcceptRecipient checks if there is a connection for the list of recipient keys.

func (*MockOutboundTransport) Send

func (o *MockOutboundTransport) Send(data []byte, destination *service.Destination) (string, error)

Send implementation of MockOutboundTransport.Send api.

func (*MockOutboundTransport) Start

Start starts the transport.

Jump to

Keyboard shortcuts

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