basic

package
v2.1.1+incompatible Latest Latest
Warning

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

Go to latest
Published: Nov 10, 2018 License: BSD-3-Clause Imports: 15 Imported by: 0

Documentation

Overview

Package basic is a generated protocol buffer package.

It is generated from these files:

tests/sql/basic/basic.proto

It has these top-level messages:

IntVal
BadReturn

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

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExampleTableFromAmazingDatabaseRow

func ExampleTableFromAmazingDatabaseRow(serv AmazingTypeMapping, row persist_lib.Scanable) (*test.ExampleTable, error)

func IdsFromAmazingDatabaseRow

func IdsFromAmazingDatabaseRow(serv AmazingTypeMapping, row persist_lib.Scanable) (*test.Ids, error)

func IterAmazingExampleTableProto

func IterAmazingExampleTableProto(ms AmazingTypeMapping, iter *persist_lib.Result, next func(i *test.ExampleTable) error) error

func IterAmazingIdsProto

func IterAmazingIdsProto(ms AmazingTypeMapping, iter *persist_lib.Result, next func(i *test.Ids) error) error

func IterAmazingNumRowsProto

func IterAmazingNumRowsProto(ms AmazingTypeMapping, iter *persist_lib.Result, next func(i *test.NumRows) error) error

func NameToAmazingPersistType

func NameToAmazingPersistType(serv AmazingTypeMapping, req *test.Name) (*persist_lib.Test_NameForAmazing, error)

func NumRowsFromAmazingDatabaseRow

func NumRowsFromAmazingDatabaseRow(serv AmazingTypeMapping, row persist_lib.Scanable) (*test.NumRows, error)

func RegisterAmazingServer

func RegisterAmazingServer(s *grpc.Server, srv AmazingServer)

Types

type AmazingClient

type AmazingClient interface {
	UniarySelect(ctx context.Context, in *tests_test.PartialTable, opts ...grpc.CallOption) (*tests_test.ExampleTable, error)
	UniarySelectWithHooks(ctx context.Context, in *tests_test.PartialTable, opts ...grpc.CallOption) (*tests_test.ExampleTable, error)
	ServerStream(ctx context.Context, in *tests_test.Name, opts ...grpc.CallOption) (Amazing_ServerStreamClient, error)
	ServerStreamWithHooks(ctx context.Context, in *tests_test.Name, opts ...grpc.CallOption) (Amazing_ServerStreamWithHooksClient, error)
	Bidirectional(ctx context.Context, opts ...grpc.CallOption) (Amazing_BidirectionalClient, error)
	// Test multi-line query
	BidirectionalWithHooks(ctx context.Context, opts ...grpc.CallOption) (Amazing_BidirectionalWithHooksClient, error)
	ClientStream(ctx context.Context, opts ...grpc.CallOption) (Amazing_ClientStreamClient, error)
	ClientStreamWithHook(ctx context.Context, opts ...grpc.CallOption) (Amazing_ClientStreamWithHookClient, error)
	UnImplementedPersistMethod(ctx context.Context, in *tests_test.ExampleTable, opts ...grpc.CallOption) (*tests_test.ExampleTable, error)
	NoGenerationForBadReturnTypes(ctx context.Context, in *tests_test.ExampleTable, opts ...grpc.CallOption) (*BadReturn, error)
}

func NewAmazingClient

func NewAmazingClient(cc *grpc.ClientConn) AmazingClient

type AmazingHooks

type AmazingHooks interface {
	UniarySelectWithHooksBeforeHook(*test.PartialTable) (*test.ExampleTable, error)
	UniarySelectWithHooksAfterHook(*test.PartialTable, *test.ExampleTable) error
	ServerStreamWithHooksBeforeHook(*test.Name) ([]*test.ExampleTable, error)
	ServerStreamWithHooksAfterHook(*test.Name, *test.ExampleTable) error
	BidirectionalWithHooksBeforeHook(*test.ExampleTable) (*test.ExampleTable, error)
	BidirectionalWithHooksAfterHook(*test.ExampleTable, *test.ExampleTable) error
	ClientStreamWithHookBeforeHook(*test.ExampleTable) (*test.Ids, error)
	ClientStreamWithHookAfterHook(*test.ExampleTable, *test.Ids) error
}

type AmazingImpl

type AmazingImpl struct {
	PERSIST   *persist_lib.AmazingMethodReceiver
	FORWARDED RestOfAmazingHandlers
	HOOKS     AmazingHooks
	MAPPINGS  AmazingTypeMapping
}

func (*AmazingImpl) Bidirectional

func (s *AmazingImpl) Bidirectional(stream Amazing_BidirectionalServer) error

func (*AmazingImpl) BidirectionalWithHooks

func (s *AmazingImpl) BidirectionalWithHooks(stream Amazing_BidirectionalWithHooksServer) error

func (*AmazingImpl) ClientStream

func (s *AmazingImpl) ClientStream(stream Amazing_ClientStreamServer) error

func (*AmazingImpl) ClientStreamWithHook

func (s *AmazingImpl) ClientStreamWithHook(stream Amazing_ClientStreamWithHookServer) error

func (*AmazingImpl) NoGenerationForBadReturnTypes

func (s *AmazingImpl) NoGenerationForBadReturnTypes(ctx context.Context, req *test.ExampleTable) (*BadReturn, error)

func (*AmazingImpl) ServerStream

func (s *AmazingImpl) ServerStream(req *test.Name, stream Amazing_ServerStreamServer) error

func (*AmazingImpl) ServerStreamWithHooks

func (s *AmazingImpl) ServerStreamWithHooks(req *test.Name, stream Amazing_ServerStreamWithHooksServer) error

func (*AmazingImpl) UnImplementedPersistMethod

func (s *AmazingImpl) UnImplementedPersistMethod(ctx context.Context, req *test.ExampleTable) (*test.ExampleTable, error)

func (*AmazingImpl) UniarySelect

func (s *AmazingImpl) UniarySelect(ctx context.Context, req *test.PartialTable) (*test.ExampleTable, error)

func (*AmazingImpl) UniarySelectWithHooks

func (s *AmazingImpl) UniarySelectWithHooks(ctx context.Context, req *test.PartialTable) (*test.ExampleTable, error)

type AmazingImplBuilder

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

func NewAmazingBuilder

func NewAmazingBuilder() *AmazingImplBuilder

func (*AmazingImplBuilder) Build

func (b *AmazingImplBuilder) Build() (*AmazingImpl, error)

func (*AmazingImplBuilder) MustBuild

func (b *AmazingImplBuilder) MustBuild() *AmazingImpl

func (*AmazingImplBuilder) WithDefaultQueryHandlers

func (b *AmazingImplBuilder) WithDefaultQueryHandlers() *AmazingImplBuilder

func (*AmazingImplBuilder) WithHooks

func (*AmazingImplBuilder) WithNewSqlDb

func (b *AmazingImplBuilder) WithNewSqlDb(driverName, dataSourceName string) *AmazingImplBuilder

func (*AmazingImplBuilder) WithNilAsDefaultQueryHandlers

func (b *AmazingImplBuilder) WithNilAsDefaultQueryHandlers(p *persist_lib.AmazingQueryHandlers) *AmazingImplBuilder

func (*AmazingImplBuilder) WithPersistQueryHandlers

func (b *AmazingImplBuilder) WithPersistQueryHandlers(p *persist_lib.AmazingQueryHandlers) *AmazingImplBuilder

func (*AmazingImplBuilder) WithRestOfGrpcHandlers

func (b *AmazingImplBuilder) WithRestOfGrpcHandlers(r RestOfAmazingHandlers) *AmazingImplBuilder

func (*AmazingImplBuilder) WithSqlClient

func (b *AmazingImplBuilder) WithSqlClient(c *sql.DB) *AmazingImplBuilder

func (*AmazingImplBuilder) WithTypeMapping

type AmazingServer

type AmazingServer interface {
	UniarySelect(context.Context, *tests_test.PartialTable) (*tests_test.ExampleTable, error)
	UniarySelectWithHooks(context.Context, *tests_test.PartialTable) (*tests_test.ExampleTable, error)
	ServerStream(*tests_test.Name, Amazing_ServerStreamServer) error
	ServerStreamWithHooks(*tests_test.Name, Amazing_ServerStreamWithHooksServer) error
	Bidirectional(Amazing_BidirectionalServer) error
	// Test multi-line query
	BidirectionalWithHooks(Amazing_BidirectionalWithHooksServer) error
	ClientStream(Amazing_ClientStreamServer) error
	ClientStreamWithHook(Amazing_ClientStreamWithHookServer) error
	UnImplementedPersistMethod(context.Context, *tests_test.ExampleTable) (*tests_test.ExampleTable, error)
	NoGenerationForBadReturnTypes(context.Context, *tests_test.ExampleTable) (*BadReturn, error)
}

type AmazingTimestampTimestampMappingImpl

type AmazingTimestampTimestampMappingImpl interface {
	ToProto(**timestamp.Timestamp) error
	ToSql(*timestamp.Timestamp) sql.Scanner
	Empty() AmazingTimestampTimestampMappingImpl
	sql.Scanner
	driver.Valuer
}

type AmazingTypeMapping

type AmazingTypeMapping interface {
	TimestampTimestamp() AmazingTimestampTimestampMappingImpl
}

type Amazing_BidirectionalClient

type Amazing_BidirectionalClient interface {
	Send(*tests_test.ExampleTable) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ClientStream
}

type Amazing_BidirectionalServer

type Amazing_BidirectionalServer interface {
	Send(*tests_test.ExampleTable) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ServerStream
}

type Amazing_BidirectionalWithHooksClient

type Amazing_BidirectionalWithHooksClient interface {
	Send(*tests_test.ExampleTable) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ClientStream
}

type Amazing_BidirectionalWithHooksServer

type Amazing_BidirectionalWithHooksServer interface {
	Send(*tests_test.ExampleTable) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ServerStream
}

type Amazing_ClientStreamClient

type Amazing_ClientStreamClient interface {
	Send(*tests_test.ExampleTable) error
	CloseAndRecv() (*tests_test.NumRows, error)
	grpc.ClientStream
}

type Amazing_ClientStreamServer

type Amazing_ClientStreamServer interface {
	SendAndClose(*tests_test.NumRows) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ServerStream
}

type Amazing_ClientStreamWithHookClient

type Amazing_ClientStreamWithHookClient interface {
	Send(*tests_test.ExampleTable) error
	CloseAndRecv() (*tests_test.Ids, error)
	grpc.ClientStream
}

type Amazing_ClientStreamWithHookServer

type Amazing_ClientStreamWithHookServer interface {
	SendAndClose(*tests_test.Ids) error
	Recv() (*tests_test.ExampleTable, error)
	grpc.ServerStream
}

type Amazing_ServerStreamClient

type Amazing_ServerStreamClient interface {
	Recv() (*tests_test.ExampleTable, error)
	grpc.ClientStream
}

type Amazing_ServerStreamServer

type Amazing_ServerStreamServer interface {
	Send(*tests_test.ExampleTable) error
	grpc.ServerStream
}

type Amazing_ServerStreamWithHooksClient

type Amazing_ServerStreamWithHooksClient interface {
	Recv() (*tests_test.ExampleTable, error)
	grpc.ClientStream
}

type Amazing_ServerStreamWithHooksServer

type Amazing_ServerStreamWithHooksServer interface {
	Send(*tests_test.ExampleTable) error
	grpc.ServerStream
}

type BadReturn

type BadReturn struct {
	No []*IntVal `protobuf:"bytes,1,rep,name=no" json:"no,omitempty"`
}

func (*BadReturn) Descriptor

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

func (*BadReturn) GetNo

func (m *BadReturn) GetNo() []*IntVal

func (*BadReturn) ProtoMessage

func (*BadReturn) ProtoMessage()

func (*BadReturn) Reset

func (m *BadReturn) Reset()

func (*BadReturn) String

func (m *BadReturn) String() string

type IntVal

type IntVal struct {
	Val int64 `protobuf:"varint,1,opt,name=val" json:"val,omitempty"`
}

func (*IntVal) Descriptor

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

func (*IntVal) GetVal

func (m *IntVal) GetVal() int64

func (*IntVal) ProtoMessage

func (*IntVal) ProtoMessage()

func (*IntVal) Reset

func (m *IntVal) Reset()

func (*IntVal) String

func (m *IntVal) String() string

type RestOfAmazingHandlers

type RestOfAmazingHandlers interface {
	UnImplementedPersistMethod(ctx context.Context, req *test.ExampleTable) (*test.ExampleTable, error)
	NoGenerationForBadReturnTypes(ctx context.Context, req *test.ExampleTable) (*BadReturn, error)
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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