bob_example

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Jan 19, 2018 License: BSD-3-Clause Imports: 13 Imported by: 0

Documentation

Overview

Package bob_example is a generated protocol buffer package.

It is generated from these files:

tests/spanner/bob_example/bobs.proto

It has these top-level messages:

Bob
NumRows
Names
Empty

This file is generated by protoc-gen-persist Source File: tests/spanner/bob_example/bobs.proto DO NOT EDIT !

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BobToBobsPersistType

func BobToBobsPersistType(req *Bob) (*persist_lib.BobForBobs, error)

func EmptyToBobsPersistType

func EmptyToBobsPersistType(req *Empty) (*persist_lib.EmptyForBobs, error)

func IterBobsBobProto

func IterBobsBobProto(iter *spanner.RowIterator, next func(i *Bob) error) error

func IterBobsEmptyProto

func IterBobsEmptyProto(iter *spanner.RowIterator, next func(i *Empty) error) error

func IterBobsNumRowsProto

func IterBobsNumRowsProto(iter *spanner.RowIterator, next func(i *NumRows) error) error

func NamesToBobsPersistType

func NamesToBobsPersistType(req *Names) (*persist_lib.NamesForBobs, error)

func RegisterBobsServer

func RegisterBobsServer(s *grpc.Server, srv BobsServer)

Types

type Bob

type Bob struct {
	Id        int64                       `protobuf:"varint,1,opt,name=id" json:"id,omitempty"`
	StartTime *google_protobuf1.Timestamp `protobuf:"bytes,2,opt,name=start_time,json=startTime" json:"start_time,omitempty"`
	Name      string                      `protobuf:"bytes,3,opt,name=name" json:"name,omitempty"`
}

func BobFromBobsDatabaseRow

func BobFromBobsDatabaseRow(row *spanner.Row) (*Bob, error)

func (*Bob) Descriptor

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

func (*Bob) GetId

func (m *Bob) GetId() int64

func (*Bob) GetName

func (m *Bob) GetName() string

func (*Bob) GetStartTime

func (m *Bob) GetStartTime() *google_protobuf1.Timestamp

func (*Bob) ProtoMessage

func (*Bob) ProtoMessage()

func (*Bob) Reset

func (m *Bob) Reset()

func (*Bob) String

func (m *Bob) String() string

type BobsClient

type BobsClient interface {
	// Delete all bob events before the time in the end key
	DeleteBobs(ctx context.Context, in *Bob, opts ...grpc.CallOption) (*Empty, error)
	PutBobs(ctx context.Context, opts ...grpc.CallOption) (Bobs_PutBobsClient, error)
	GetBobs(ctx context.Context, in *Empty, opts ...grpc.CallOption) (Bobs_GetBobsClient, error)
	GetPeopleFromNames(ctx context.Context, in *Names, opts ...grpc.CallOption) (Bobs_GetPeopleFromNamesClient, error)
}

func NewBobsClient

func NewBobsClient(cc *grpc.ClientConn) BobsClient

type BobsImpl

type BobsImpl struct {
	PERSIST   *persist_lib.BobsMethodReceiver
	FORWARDED RestOfBobsHandlers
}

func (*BobsImpl) DeleteBobs

func (s *BobsImpl) DeleteBobs(ctx context.Context, req *Bob) (*Empty, error)

func (*BobsImpl) GetBobs

func (s *BobsImpl) GetBobs(req *Empty, stream Bobs_GetBobsServer) error

func (*BobsImpl) GetPeopleFromNames

func (s *BobsImpl) GetPeopleFromNames(req *Names, stream Bobs_GetPeopleFromNamesServer) error

func (*BobsImpl) PutBobs

func (s *BobsImpl) PutBobs(stream Bobs_PutBobsServer) error

type BobsImplBuilder

type BobsImplBuilder struct {
	// contains filtered or unexported fields
}

func NewBobsBuilder

func NewBobsBuilder() *BobsImplBuilder

func (*BobsImplBuilder) Build

func (b *BobsImplBuilder) Build() (*BobsImpl, error)

func (*BobsImplBuilder) MustBuild

func (b *BobsImplBuilder) MustBuild() *BobsImpl

func (*BobsImplBuilder) WithDefaultQueryHandlers

func (b *BobsImplBuilder) WithDefaultQueryHandlers() *BobsImplBuilder

func (*BobsImplBuilder) WithNilAsDefaultQueryHandlers

func (b *BobsImplBuilder) WithNilAsDefaultQueryHandlers(p *persist_lib.BobsQueryHandlers) *BobsImplBuilder

set the custom handlers you want to use in the handlers this method will make sure to use a default handler if the handler is nil.

func (*BobsImplBuilder) WithPersistQueryHandlers

func (b *BobsImplBuilder) WithPersistQueryHandlers(p *persist_lib.BobsQueryHandlers) *BobsImplBuilder

func (*BobsImplBuilder) WithRestOfGrpcHandlers

func (b *BobsImplBuilder) WithRestOfGrpcHandlers(r RestOfBobsHandlers) *BobsImplBuilder

func (*BobsImplBuilder) WithSpannerClient

func (b *BobsImplBuilder) WithSpannerClient(c *spanner.Client) *BobsImplBuilder

func (*BobsImplBuilder) WithSpannerURI

func (b *BobsImplBuilder) WithSpannerURI(ctx context.Context, uri string) *BobsImplBuilder

type BobsServer

type BobsServer interface {
	// Delete all bob events before the time in the end key
	DeleteBobs(context.Context, *Bob) (*Empty, error)
	PutBobs(Bobs_PutBobsServer) error
	GetBobs(*Empty, Bobs_GetBobsServer) error
	GetPeopleFromNames(*Names, Bobs_GetPeopleFromNamesServer) error
}

type Bobs_GetBobsClient

type Bobs_GetBobsClient interface {
	Recv() (*Bob, error)
	grpc.ClientStream
}

type Bobs_GetBobsServer

type Bobs_GetBobsServer interface {
	Send(*Bob) error
	grpc.ServerStream
}

type Bobs_GetPeopleFromNamesClient

type Bobs_GetPeopleFromNamesClient interface {
	Recv() (*Bob, error)
	grpc.ClientStream
}

type Bobs_GetPeopleFromNamesServer

type Bobs_GetPeopleFromNamesServer interface {
	Send(*Bob) error
	grpc.ServerStream
}

type Bobs_PutBobsClient

type Bobs_PutBobsClient interface {
	Send(*Bob) error
	CloseAndRecv() (*NumRows, error)
	grpc.ClientStream
}

type Bobs_PutBobsServer

type Bobs_PutBobsServer interface {
	SendAndClose(*NumRows) error
	Recv() (*Bob, error)
	grpc.ServerStream
}

type Empty

type Empty struct {
}

func EmptyFromBobsDatabaseRow

func EmptyFromBobsDatabaseRow(row *spanner.Row) (*Empty, error)

func (*Empty) Descriptor

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

func (*Empty) ProtoMessage

func (*Empty) ProtoMessage()

func (*Empty) Reset

func (m *Empty) Reset()

func (*Empty) String

func (m *Empty) String() string

type Names

type Names struct {
	Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
}

func (*Names) Descriptor

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

func (*Names) GetNames

func (m *Names) GetNames() []string

func (*Names) ProtoMessage

func (*Names) ProtoMessage()

func (*Names) Reset

func (m *Names) Reset()

func (*Names) String

func (m *Names) String() string

type NumRows

type NumRows struct {
	Count int64 `protobuf:"varint,1,opt,name=count" json:"count,omitempty"`
}

func NumRowsFromBobsDatabaseRow

func NumRowsFromBobsDatabaseRow(row *spanner.Row) (*NumRows, error)

func (*NumRows) Descriptor

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

func (*NumRows) GetCount

func (m *NumRows) GetCount() int64

func (*NumRows) ProtoMessage

func (*NumRows) ProtoMessage()

func (*NumRows) Reset

func (m *NumRows) Reset()

func (*NumRows) String

func (m *NumRows) String() string

type RestOfBobsHandlers

type RestOfBobsHandlers interface {
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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