Documentation ¶
Overview ¶
Package pb is a generated protocol buffer package.
It is generated from these files:
pb/user.proto
It has these top-level messages:
User Friends SliceStringParam FriendsReq Empty
This file is generated by protoc-gen-persist Source File: pb/user.proto DO NOT EDIT !
Index ¶
- func EmptyToUServPersistType(req *Empty) (*persist_lib.EmptyForUServ, error)
- func FriendsReqToUServPersistType(req *FriendsReq) (*persist_lib.FriendsReqForUServ, error)
- func IterUServEmptyProto(iter *persist_lib.Result, next func(i *Empty) error) error
- func IterUServUserProto(iter *persist_lib.Result, next func(i *User) error) error
- func RegisterUServServer(s *grpc.Server, srv UServServer)
- func UserToUServPersistType(req *User) (*persist_lib.UserForUServ, error)
- type Empty
- type Friends
- type FriendsReq
- type RestOfUServHandlers
- type SliceStringConverter
- type SliceStringParam
- type TimeString
- type UServClient
- type UServHooks
- type UServImpl
- func (s *UServImpl) CreateTable(ctx context.Context, req *Empty) (*Empty, error)
- func (s *UServImpl) DropTable(ctx context.Context, req *Empty) (*Empty, error)
- func (s *UServImpl) GetAllUsers(req *Empty, stream UServ_GetAllUsersServer) error
- func (s *UServImpl) GetFriends(req *FriendsReq, stream UServ_GetFriendsServer) error
- func (s *UServImpl) InsertUsers(stream UServ_InsertUsersServer) error
- func (s *UServImpl) SelectUserById(ctx context.Context, req *User) (*User, error)
- func (s *UServImpl) UpdateAllNames(req *Empty, stream UServ_UpdateAllNamesServer) error
- func (s *UServImpl) UpdateNameToFoo(ctx context.Context, req *User) (*Empty, error)
- func (s *UServImpl) UpdateUserNames(stream UServ_UpdateUserNamesServer) error
- type UServImplBuilder
- func (b *UServImplBuilder) Build() (*UServImpl, error)
- func (b *UServImplBuilder) MustBuild() *UServImpl
- func (b *UServImplBuilder) WithDefaultQueryHandlers() *UServImplBuilder
- func (b *UServImplBuilder) WithHooks(hs UServHooks) *UServImplBuilder
- func (b *UServImplBuilder) WithNewSqlDb(driverName, dataSourceName string) *UServImplBuilder
- func (b *UServImplBuilder) WithNilAsDefaultQueryHandlers(p *persist_lib.UServQueryHandlers) *UServImplBuilder
- func (b *UServImplBuilder) WithPersistQueryHandlers(p *persist_lib.UServQueryHandlers) *UServImplBuilder
- func (b *UServImplBuilder) WithRestOfGrpcHandlers(r RestOfUServHandlers) *UServImplBuilder
- func (b *UServImplBuilder) WithSqlClient(c *sql.DB) *UServImplBuilder
- type UServServer
- type UServ_GetAllUsersClient
- type UServ_GetAllUsersServer
- type UServ_GetFriendsClient
- type UServ_GetFriendsServer
- type UServ_InsertUsersClient
- type UServ_InsertUsersServer
- type UServ_UpdateAllNamesClient
- type UServ_UpdateAllNamesServer
- type UServ_UpdateUserNamesClient
- type UServ_UpdateUserNamesServer
- type User
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EmptyToUServPersistType ¶
func EmptyToUServPersistType(req *Empty) (*persist_lib.EmptyForUServ, error)
func FriendsReqToUServPersistType ¶
func FriendsReqToUServPersistType(req *FriendsReq) (*persist_lib.FriendsReqForUServ, error)
func IterUServEmptyProto ¶
func IterUServEmptyProto(iter *persist_lib.Result, next func(i *Empty) error) error
func IterUServUserProto ¶
func IterUServUserProto(iter *persist_lib.Result, next func(i *User) error) error
func RegisterUServServer ¶
func RegisterUServServer(s *grpc.Server, srv UServServer)
func UserToUServPersistType ¶
func UserToUServPersistType(req *User) (*persist_lib.UserForUServ, error)
Types ¶
type Empty ¶
type Empty struct { }
func EmptyFromUServDatabaseRow ¶
func EmptyFromUServDatabaseRow(row persist_lib.Scanable) (*Empty, error)
func (*Empty) Descriptor ¶
func (*Empty) ProtoMessage ¶
func (*Empty) ProtoMessage()
type Friends ¶
type Friends struct {
Names []string `protobuf:"bytes,1,rep,name=names" json:"names,omitempty"`
}
func (*Friends) Descriptor ¶
func (*Friends) ProtoMessage ¶
func (*Friends) ProtoMessage()
type FriendsReq ¶
type FriendsReq struct {
Names *SliceStringParam `protobuf:"bytes,2,opt,name=names" json:"names,omitempty"`
}
func (*FriendsReq) Descriptor ¶
func (*FriendsReq) Descriptor() ([]byte, []int)
func (*FriendsReq) GetNames ¶
func (m *FriendsReq) GetNames() *SliceStringParam
func (*FriendsReq) ProtoMessage ¶
func (*FriendsReq) ProtoMessage()
func (*FriendsReq) Reset ¶
func (m *FriendsReq) Reset()
func (*FriendsReq) String ¶
func (m *FriendsReq) String() string
type RestOfUServHandlers ¶
type RestOfUServHandlers interface {
UpdateAllNames(req *Empty, stream UServ_UpdateAllNamesServer) error
}
type SliceStringConverter ¶
type SliceStringConverter struct {
// contains filtered or unexported fields
}
func (*SliceStringConverter) Scan ¶
func (s *SliceStringConverter) Scan(src interface{}) error
func (SliceStringConverter) ToProto ¶
func (s SliceStringConverter) ToProto() *SliceStringParam
func (SliceStringConverter) ToSql ¶
func (s SliceStringConverter) ToSql(v *SliceStringParam) *SliceStringConverter
type SliceStringParam ¶
type SliceStringParam struct {
Slice []string `protobuf:"bytes,1,rep,name=slice" json:"slice,omitempty"`
}
func (*SliceStringParam) Descriptor ¶
func (*SliceStringParam) Descriptor() ([]byte, []int)
func (*SliceStringParam) GetSlice ¶
func (m *SliceStringParam) GetSlice() []string
func (*SliceStringParam) ProtoMessage ¶
func (*SliceStringParam) ProtoMessage()
func (*SliceStringParam) Reset ¶
func (m *SliceStringParam) Reset()
func (*SliceStringParam) String ¶
func (m *SliceStringParam) String() string
type TimeString ¶
type TimeString struct {
// contains filtered or unexported fields
}
func (*TimeString) Scan ¶
func (t *TimeString) Scan(src interface{}) error
func (TimeString) ToProto ¶
func (ts TimeString) ToProto() *timestamp.Timestamp
func (TimeString) ToSql ¶
func (ts TimeString) ToSql(t *timestamp.Timestamp) *TimeString
type UServClient ¶
type UServClient interface { CreateTable(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) InsertUsers(ctx context.Context, opts ...grpc.CallOption) (UServ_InsertUsersClient, error) GetAllUsers(ctx context.Context, in *Empty, opts ...grpc.CallOption) (UServ_GetAllUsersClient, error) SelectUserById(ctx context.Context, in *User, opts ...grpc.CallOption) (*User, error) UpdateUserNames(ctx context.Context, opts ...grpc.CallOption) (UServ_UpdateUserNamesClient, error) UpdateNameToFoo(ctx context.Context, in *User, opts ...grpc.CallOption) (*Empty, error) UpdateAllNames(ctx context.Context, in *Empty, opts ...grpc.CallOption) (UServ_UpdateAllNamesClient, error) GetFriends(ctx context.Context, in *FriendsReq, opts ...grpc.CallOption) (UServ_GetFriendsClient, error) DropTable(ctx context.Context, in *Empty, opts ...grpc.CallOption) (*Empty, error) }
func NewUServClient ¶
func NewUServClient(cc *grpc.ClientConn) UServClient
type UServHooks ¶
type UServImpl ¶
type UServImpl struct { PERSIST *persist_lib.UServMethodReceiver FORWARDED RestOfUServHandlers HOOKS UServHooks }
func (*UServImpl) CreateTable ¶
func (*UServImpl) GetAllUsers ¶
func (s *UServImpl) GetAllUsers(req *Empty, stream UServ_GetAllUsersServer) error
func (*UServImpl) GetFriends ¶
func (s *UServImpl) GetFriends(req *FriendsReq, stream UServ_GetFriendsServer) error
func (*UServImpl) InsertUsers ¶
func (s *UServImpl) InsertUsers(stream UServ_InsertUsersServer) error
func (*UServImpl) SelectUserById ¶
func (*UServImpl) UpdateAllNames ¶
func (s *UServImpl) UpdateAllNames(req *Empty, stream UServ_UpdateAllNamesServer) error
func (*UServImpl) UpdateNameToFoo ¶
func (*UServImpl) UpdateUserNames ¶
func (s *UServImpl) UpdateUserNames(stream UServ_UpdateUserNamesServer) error
type UServImplBuilder ¶
type UServImplBuilder struct {
// contains filtered or unexported fields
}
func NewUServBuilder ¶
func NewUServBuilder() *UServImplBuilder
func (*UServImplBuilder) Build ¶
func (b *UServImplBuilder) Build() (*UServImpl, error)
func (*UServImplBuilder) MustBuild ¶
func (b *UServImplBuilder) MustBuild() *UServImpl
func (*UServImplBuilder) WithDefaultQueryHandlers ¶
func (b *UServImplBuilder) WithDefaultQueryHandlers() *UServImplBuilder
func (*UServImplBuilder) WithHooks ¶
func (b *UServImplBuilder) WithHooks(hs UServHooks) *UServImplBuilder
func (*UServImplBuilder) WithNewSqlDb ¶
func (b *UServImplBuilder) WithNewSqlDb(driverName, dataSourceName string) *UServImplBuilder
func (*UServImplBuilder) WithNilAsDefaultQueryHandlers ¶
func (b *UServImplBuilder) WithNilAsDefaultQueryHandlers(p *persist_lib.UServQueryHandlers) *UServImplBuilder
func (*UServImplBuilder) WithPersistQueryHandlers ¶
func (b *UServImplBuilder) WithPersistQueryHandlers(p *persist_lib.UServQueryHandlers) *UServImplBuilder
func (*UServImplBuilder) WithRestOfGrpcHandlers ¶
func (b *UServImplBuilder) WithRestOfGrpcHandlers(r RestOfUServHandlers) *UServImplBuilder
func (*UServImplBuilder) WithSqlClient ¶
func (b *UServImplBuilder) WithSqlClient(c *sql.DB) *UServImplBuilder
type UServServer ¶
type UServServer interface { CreateTable(context.Context, *Empty) (*Empty, error) InsertUsers(UServ_InsertUsersServer) error GetAllUsers(*Empty, UServ_GetAllUsersServer) error SelectUserById(context.Context, *User) (*User, error) UpdateUserNames(UServ_UpdateUserNamesServer) error UpdateNameToFoo(context.Context, *User) (*Empty, error) UpdateAllNames(*Empty, UServ_UpdateAllNamesServer) error GetFriends(*FriendsReq, UServ_GetFriendsServer) error DropTable(context.Context, *Empty) (*Empty, error) }
type UServ_GetAllUsersClient ¶
type UServ_GetAllUsersClient interface { Recv() (*User, error) grpc.ClientStream }
type UServ_GetAllUsersServer ¶
type UServ_GetAllUsersServer interface { Send(*User) error grpc.ServerStream }
type UServ_GetFriendsClient ¶
type UServ_GetFriendsClient interface { Recv() (*User, error) grpc.ClientStream }
type UServ_GetFriendsServer ¶
type UServ_GetFriendsServer interface { Send(*User) error grpc.ServerStream }
type UServ_InsertUsersClient ¶
type UServ_InsertUsersServer ¶
type UServ_UpdateAllNamesClient ¶
type UServ_UpdateAllNamesClient interface { Recv() (*User, error) grpc.ClientStream }
type UServ_UpdateAllNamesServer ¶
type UServ_UpdateAllNamesServer interface { Send(*User) error grpc.ServerStream }
type User ¶
type User struct { Id int64 `protobuf:"varint,1,opt,name=id" json:"id,omitempty"` Name string `protobuf:"bytes,2,opt,name=name" json:"name,omitempty"` Friends *Friends `protobuf:"bytes,3,opt,name=friends" json:"friends,omitempty"` CreatedOn *google_protobuf1.Timestamp `protobuf:"bytes,4,opt,name=created_on,json=createdOn" json:"created_on,omitempty"` }
func UserFromUServDatabaseRow ¶
func UserFromUServDatabaseRow(row persist_lib.Scanable) (*User, error)
func (*User) Descriptor ¶
func (*User) GetCreatedOn ¶
func (m *User) GetCreatedOn() *google_protobuf1.Timestamp
func (*User) GetFriends ¶
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
Click to show internal directories.
Click to hide internal directories.