api

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2016 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package api is a generated protocol buffer package.

It is generated from these files:

dfss/dfssc/api/client.proto

It has these top-level messages:

Context
Promise
Signature
Hello

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func RegisterClientServer

func RegisterClientServer(s *grpc.Server, srv ClientServer)

Types

type ClientClient

type ClientClient interface {
	TreatPromise(ctx context.Context, in *Promise, opts ...grpc.CallOption) (*api1.ErrorCode, error)
	TreatSignature(ctx context.Context, in *Signature, opts ...grpc.CallOption) (*api1.ErrorCode, error)
	Discover(ctx context.Context, in *Hello, opts ...grpc.CallOption) (*Hello, error)
}

func NewClientClient

func NewClientClient(cc *grpc.ClientConn) ClientClient

type ClientServer

type ClientServer interface {
	TreatPromise(context.Context, *Promise) (*api1.ErrorCode, error)
	TreatSignature(context.Context, *Signature) (*api1.ErrorCode, error)
	Discover(context.Context, *Hello) (*Hello, error)
}

type Context

type Context struct {
	RecipientKeyHash     []byte   `protobuf:"bytes,1,opt,name=recipientKeyHash,proto3" json:"recipientKeyHash,omitempty"`
	SenderKeyHash        []byte   `protobuf:"bytes,2,opt,name=senderKeyHash,proto3" json:"senderKeyHash,omitempty"`
	Sequence             []uint32 `protobuf:"varint,3,rep,name=sequence" json:"sequence,omitempty"`
	Signers              [][]byte `protobuf:"bytes,4,rep,name=signers,proto3" json:"signers,omitempty"`
	ContractDocumentHash []byte   `protobuf:"bytes,5,opt,name=contractDocumentHash,proto3" json:"contractDocumentHash,omitempty"`
	SignatureUUID        string   `protobuf:"bytes,6,opt,name=signatureUUID" json:"signatureUUID,omitempty"`
	SignedHash           []byte   `protobuf:"bytes,7,opt,name=signedHash,proto3" json:"signedHash,omitempty"`
}

func (*Context) Descriptor

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

func (*Context) ProtoMessage

func (*Context) ProtoMessage()

func (*Context) Reset

func (m *Context) Reset()

func (*Context) String

func (m *Context) String() string

type Hello

type Hello struct {
	Version string `protobuf:"bytes,1,opt,name=version" json:"version,omitempty"`
}

Hello message is used when discovering peers. It contains the current version of the software.

func (*Hello) Descriptor

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

func (*Hello) ProtoMessage

func (*Hello) ProtoMessage()

func (*Hello) Reset

func (m *Hello) Reset()

func (*Hello) String

func (m *Hello) String() string

type Promise

type Promise struct {
	Context *Context `protobuf:"bytes,1,opt,name=context" json:"context,omitempty"`
	Index   uint32   `protobuf:"varint,2,opt,name=index" json:"index,omitempty"`
	Payload []byte   `protobuf:"bytes,3,opt,name=payload,proto3" json:"payload,omitempty"`
}

Promise message contains all the required information to verify the identity of the sender and receiver, and the actual promise

func (*Promise) Descriptor

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

func (*Promise) GetContext

func (m *Promise) GetContext() *Context

func (*Promise) ProtoMessage

func (*Promise) ProtoMessage()

func (*Promise) Reset

func (m *Promise) Reset()

func (*Promise) String

func (m *Promise) String() string

type Signature

type Signature struct {
	Context *Context `protobuf:"bytes,1,opt,name=context" json:"context,omitempty"`
	Payload []byte   `protobuf:"bytes,2,opt,name=payload,proto3" json:"payload,omitempty"`
}

Signature message contains all the required information to verify the identity of the sender and receiver, and the actual signature

func (*Signature) Descriptor

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

func (*Signature) GetContext

func (m *Signature) GetContext() *Context

func (*Signature) ProtoMessage

func (*Signature) ProtoMessage()

func (*Signature) Reset

func (m *Signature) Reset()

func (*Signature) String

func (m *Signature) String() string

Jump to

Keyboard shortcuts

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