Documentation ¶
Index ¶
- Constants
- Variables
- func RegisterPostgresServer(s grpc.ServiceRegistrar, srv PostgresServer)
- type CreateParams
- func (*CreateParams) Descriptor() ([]byte, []int)deprecated
- func (x *CreateParams) GetRecord() *anypb.Any
- func (x *CreateParams) GetTable() string
- func (*CreateParams) ProtoMessage()
- func (x *CreateParams) ProtoReflect() protoreflect.Message
- func (x *CreateParams) Reset()
- func (x *CreateParams) String() string
- type DeleteResponse
- type ExecParams
- type ExecResponse
- type FilterParams
- func (*FilterParams) Descriptor() ([]byte, []int)deprecated
- func (x *FilterParams) GetFilter() *anypb.Any
- func (x *FilterParams) GetTable() string
- func (*FilterParams) ProtoMessage()
- func (x *FilterParams) ProtoReflect() protoreflect.Message
- func (x *FilterParams) Reset()
- func (x *FilterParams) String() string
- type IdParams
- type PostgresClient
- type PostgresServer
- type QueryParams
- func (*QueryParams) Descriptor() ([]byte, []int)deprecated
- func (x *QueryParams) GetArgs() []*anypb.Any
- func (x *QueryParams) GetQuery() string
- func (*QueryParams) ProtoMessage()
- func (x *QueryParams) ProtoReflect() protoreflect.Message
- func (x *QueryParams) Reset()
- func (x *QueryParams) String() string
- type QueryResponse
- type RecordResponse
- type RecordsResponse
- type UnimplementedPostgresServer
- func (UnimplementedPostgresServer) Create(context.Context, *CreateParams) (*RecordResponse, error)
- func (UnimplementedPostgresServer) Delete(context.Context, *IdParams) (*DeleteResponse, error)
- func (UnimplementedPostgresServer) Exec(context.Context, *ExecParams) (*ExecResponse, error)
- func (UnimplementedPostgresServer) Find(context.Context, *FilterParams) (*RecordsResponse, error)
- func (UnimplementedPostgresServer) Get(context.Context, *FilterParams) (*RecordResponse, error)
- func (UnimplementedPostgresServer) GetById(context.Context, *IdParams) (*RecordResponse, error)
- func (UnimplementedPostgresServer) Query(context.Context, *QueryParams) (*QueryResponse, error)
- func (UnimplementedPostgresServer) Update(context.Context, *UpdateParams) (*RecordResponse, error)
- type UnsafePostgresServer
- type UpdateParams
- func (*UpdateParams) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateParams) GetId() string
- func (x *UpdateParams) GetRecord() *anypb.Any
- func (x *UpdateParams) GetTable() string
- func (*UpdateParams) ProtoMessage()
- func (x *UpdateParams) ProtoReflect() protoreflect.Message
- func (x *UpdateParams) Reset()
- func (x *UpdateParams) String() string
Constants ¶
const ( Postgres_GetById_FullMethodName = "/database.Postgres/getById" Postgres_Get_FullMethodName = "/database.Postgres/get" Postgres_Find_FullMethodName = "/database.Postgres/find" Postgres_Create_FullMethodName = "/database.Postgres/create" Postgres_Update_FullMethodName = "/database.Postgres/update" Postgres_Delete_FullMethodName = "/database.Postgres/delete" Postgres_Query_FullMethodName = "/database.Postgres/query" Postgres_Exec_FullMethodName = "/database.Postgres/exec" )
Variables ¶
var File_proto_database_postgres_proto protoreflect.FileDescriptor
var Postgres_ServiceDesc = grpc.ServiceDesc{ ServiceName: "database.Postgres", HandlerType: (*PostgresServer)(nil), Methods: []grpc.MethodDesc{ { MethodName: "getById", Handler: _Postgres_GetById_Handler, }, { MethodName: "get", Handler: _Postgres_Get_Handler, }, { MethodName: "find", Handler: _Postgres_Find_Handler, }, { MethodName: "create", Handler: _Postgres_Create_Handler, }, { MethodName: "update", Handler: _Postgres_Update_Handler, }, { MethodName: "delete", Handler: _Postgres_Delete_Handler, }, { MethodName: "query", Handler: _Postgres_Query_Handler, }, { MethodName: "exec", Handler: _Postgres_Exec_Handler, }, }, Streams: []grpc.StreamDesc{}, Metadata: "proto/database/postgres.proto", }
Postgres_ServiceDesc is the grpc.ServiceDesc for Postgres service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)
Functions ¶
func RegisterPostgresServer ¶
func RegisterPostgresServer(s grpc.ServiceRegistrar, srv PostgresServer)
Types ¶
type CreateParams ¶
type CreateParams struct { Table string `protobuf:"bytes,1,opt,name=table,proto3" json:"table,omitempty"` Record *anypb.Any `protobuf:"bytes,2,opt,name=record,proto3" json:"record,omitempty"` // contains filtered or unexported fields }
func (*CreateParams) Descriptor
deprecated
func (*CreateParams) Descriptor() ([]byte, []int)
Deprecated: Use CreateParams.ProtoReflect.Descriptor instead.
func (*CreateParams) GetRecord ¶
func (x *CreateParams) GetRecord() *anypb.Any
func (*CreateParams) GetTable ¶
func (x *CreateParams) GetTable() string
func (*CreateParams) ProtoMessage ¶
func (*CreateParams) ProtoMessage()
func (*CreateParams) ProtoReflect ¶
func (x *CreateParams) ProtoReflect() protoreflect.Message
func (*CreateParams) Reset ¶
func (x *CreateParams) Reset()
func (*CreateParams) String ¶
func (x *CreateParams) String() string
type DeleteResponse ¶
type DeleteResponse struct {
// contains filtered or unexported fields
}
func (*DeleteResponse) Descriptor
deprecated
func (*DeleteResponse) Descriptor() ([]byte, []int)
Deprecated: Use DeleteResponse.ProtoReflect.Descriptor instead.
func (*DeleteResponse) ProtoMessage ¶
func (*DeleteResponse) ProtoMessage()
func (*DeleteResponse) ProtoReflect ¶
func (x *DeleteResponse) ProtoReflect() protoreflect.Message
func (*DeleteResponse) Reset ¶
func (x *DeleteResponse) Reset()
func (*DeleteResponse) String ¶
func (x *DeleteResponse) String() string
type ExecParams ¶
type ExecParams struct { Query string `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` Args []*anypb.Any `protobuf:"bytes,2,rep,name=args,proto3" json:"args,omitempty"` // contains filtered or unexported fields }
func (*ExecParams) Descriptor
deprecated
func (*ExecParams) Descriptor() ([]byte, []int)
Deprecated: Use ExecParams.ProtoReflect.Descriptor instead.
func (*ExecParams) GetArgs ¶
func (x *ExecParams) GetArgs() []*anypb.Any
func (*ExecParams) GetQuery ¶
func (x *ExecParams) GetQuery() string
func (*ExecParams) ProtoMessage ¶
func (*ExecParams) ProtoMessage()
func (*ExecParams) ProtoReflect ¶
func (x *ExecParams) ProtoReflect() protoreflect.Message
func (*ExecParams) Reset ¶
func (x *ExecParams) Reset()
func (*ExecParams) String ¶
func (x *ExecParams) String() string
type ExecResponse ¶
type ExecResponse struct { Result *anypb.Any `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` // contains filtered or unexported fields }
func (*ExecResponse) Descriptor
deprecated
func (*ExecResponse) Descriptor() ([]byte, []int)
Deprecated: Use ExecResponse.ProtoReflect.Descriptor instead.
func (*ExecResponse) GetResult ¶
func (x *ExecResponse) GetResult() *anypb.Any
func (*ExecResponse) ProtoMessage ¶
func (*ExecResponse) ProtoMessage()
func (*ExecResponse) ProtoReflect ¶
func (x *ExecResponse) ProtoReflect() protoreflect.Message
func (*ExecResponse) Reset ¶
func (x *ExecResponse) Reset()
func (*ExecResponse) String ¶
func (x *ExecResponse) String() string
type FilterParams ¶
type FilterParams struct { Table string `protobuf:"bytes,1,opt,name=table,proto3" json:"table,omitempty"` Filter *anypb.Any `protobuf:"bytes,2,opt,name=filter,proto3" json:"filter,omitempty"` // contains filtered or unexported fields }
func (*FilterParams) Descriptor
deprecated
func (*FilterParams) Descriptor() ([]byte, []int)
Deprecated: Use FilterParams.ProtoReflect.Descriptor instead.
func (*FilterParams) GetFilter ¶
func (x *FilterParams) GetFilter() *anypb.Any
func (*FilterParams) GetTable ¶
func (x *FilterParams) GetTable() string
func (*FilterParams) ProtoMessage ¶
func (*FilterParams) ProtoMessage()
func (*FilterParams) ProtoReflect ¶
func (x *FilterParams) ProtoReflect() protoreflect.Message
func (*FilterParams) Reset ¶
func (x *FilterParams) Reset()
func (*FilterParams) String ¶
func (x *FilterParams) String() string
type IdParams ¶
type IdParams struct { Table string `protobuf:"bytes,1,opt,name=table,proto3" json:"table,omitempty"` Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` // contains filtered or unexported fields }
func (*IdParams) Descriptor
deprecated
func (*IdParams) ProtoMessage ¶
func (*IdParams) ProtoMessage()
func (*IdParams) ProtoReflect ¶
func (x *IdParams) ProtoReflect() protoreflect.Message
type PostgresClient ¶
type PostgresClient interface { GetById(ctx context.Context, in *IdParams, opts ...grpc.CallOption) (*RecordResponse, error) Get(ctx context.Context, in *FilterParams, opts ...grpc.CallOption) (*RecordResponse, error) Find(ctx context.Context, in *FilterParams, opts ...grpc.CallOption) (*RecordsResponse, error) Create(ctx context.Context, in *CreateParams, opts ...grpc.CallOption) (*RecordResponse, error) Update(ctx context.Context, in *UpdateParams, opts ...grpc.CallOption) (*RecordResponse, error) Delete(ctx context.Context, in *IdParams, opts ...grpc.CallOption) (*DeleteResponse, error) Query(ctx context.Context, in *QueryParams, opts ...grpc.CallOption) (*QueryResponse, error) Exec(ctx context.Context, in *ExecParams, opts ...grpc.CallOption) (*ExecResponse, error) }
PostgresClient is the client API for Postgres service.
For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.
func NewPostgresClient ¶
func NewPostgresClient(cc grpc.ClientConnInterface) PostgresClient
type PostgresServer ¶
type PostgresServer interface { GetById(context.Context, *IdParams) (*RecordResponse, error) Get(context.Context, *FilterParams) (*RecordResponse, error) Find(context.Context, *FilterParams) (*RecordsResponse, error) Create(context.Context, *CreateParams) (*RecordResponse, error) Update(context.Context, *UpdateParams) (*RecordResponse, error) Delete(context.Context, *IdParams) (*DeleteResponse, error) Query(context.Context, *QueryParams) (*QueryResponse, error) Exec(context.Context, *ExecParams) (*ExecResponse, error) // contains filtered or unexported methods }
PostgresServer is the server API for Postgres service. All implementations must embed UnimplementedPostgresServer for forward compatibility
type QueryParams ¶
type QueryParams struct { Query string `protobuf:"bytes,1,opt,name=query,proto3" json:"query,omitempty"` Args []*anypb.Any `protobuf:"bytes,2,rep,name=args,proto3" json:"args,omitempty"` // contains filtered or unexported fields }
func (*QueryParams) Descriptor
deprecated
func (*QueryParams) Descriptor() ([]byte, []int)
Deprecated: Use QueryParams.ProtoReflect.Descriptor instead.
func (*QueryParams) GetArgs ¶
func (x *QueryParams) GetArgs() []*anypb.Any
func (*QueryParams) GetQuery ¶
func (x *QueryParams) GetQuery() string
func (*QueryParams) ProtoMessage ¶
func (*QueryParams) ProtoMessage()
func (*QueryParams) ProtoReflect ¶
func (x *QueryParams) ProtoReflect() protoreflect.Message
func (*QueryParams) Reset ¶
func (x *QueryParams) Reset()
func (*QueryParams) String ¶
func (x *QueryParams) String() string
type QueryResponse ¶
type QueryResponse struct { Result *anypb.Any `protobuf:"bytes,1,opt,name=result,proto3" json:"result,omitempty"` // contains filtered or unexported fields }
func (*QueryResponse) Descriptor
deprecated
func (*QueryResponse) Descriptor() ([]byte, []int)
Deprecated: Use QueryResponse.ProtoReflect.Descriptor instead.
func (*QueryResponse) GetResult ¶
func (x *QueryResponse) GetResult() *anypb.Any
func (*QueryResponse) ProtoMessage ¶
func (*QueryResponse) ProtoMessage()
func (*QueryResponse) ProtoReflect ¶
func (x *QueryResponse) ProtoReflect() protoreflect.Message
func (*QueryResponse) Reset ¶
func (x *QueryResponse) Reset()
func (*QueryResponse) String ¶
func (x *QueryResponse) String() string
type RecordResponse ¶
type RecordResponse struct { Record *anypb.Any `protobuf:"bytes,1,opt,name=record,proto3" json:"record,omitempty"` // contains filtered or unexported fields }
func (*RecordResponse) Descriptor
deprecated
func (*RecordResponse) Descriptor() ([]byte, []int)
Deprecated: Use RecordResponse.ProtoReflect.Descriptor instead.
func (*RecordResponse) GetRecord ¶
func (x *RecordResponse) GetRecord() *anypb.Any
func (*RecordResponse) ProtoMessage ¶
func (*RecordResponse) ProtoMessage()
func (*RecordResponse) ProtoReflect ¶
func (x *RecordResponse) ProtoReflect() protoreflect.Message
func (*RecordResponse) Reset ¶
func (x *RecordResponse) Reset()
func (*RecordResponse) String ¶
func (x *RecordResponse) String() string
type RecordsResponse ¶
type RecordsResponse struct { Records []*RecordResponse `protobuf:"bytes,1,rep,name=records,proto3" json:"records,omitempty"` // contains filtered or unexported fields }
func (*RecordsResponse) Descriptor
deprecated
func (*RecordsResponse) Descriptor() ([]byte, []int)
Deprecated: Use RecordsResponse.ProtoReflect.Descriptor instead.
func (*RecordsResponse) GetRecords ¶
func (x *RecordsResponse) GetRecords() []*RecordResponse
func (*RecordsResponse) ProtoMessage ¶
func (*RecordsResponse) ProtoMessage()
func (*RecordsResponse) ProtoReflect ¶
func (x *RecordsResponse) ProtoReflect() protoreflect.Message
func (*RecordsResponse) Reset ¶
func (x *RecordsResponse) Reset()
func (*RecordsResponse) String ¶
func (x *RecordsResponse) String() string
type UnimplementedPostgresServer ¶
type UnimplementedPostgresServer struct { }
UnimplementedPostgresServer must be embedded to have forward compatible implementations.
func (UnimplementedPostgresServer) Create ¶
func (UnimplementedPostgresServer) Create(context.Context, *CreateParams) (*RecordResponse, error)
func (UnimplementedPostgresServer) Delete ¶
func (UnimplementedPostgresServer) Delete(context.Context, *IdParams) (*DeleteResponse, error)
func (UnimplementedPostgresServer) Exec ¶
func (UnimplementedPostgresServer) Exec(context.Context, *ExecParams) (*ExecResponse, error)
func (UnimplementedPostgresServer) Find ¶
func (UnimplementedPostgresServer) Find(context.Context, *FilterParams) (*RecordsResponse, error)
func (UnimplementedPostgresServer) Get ¶
func (UnimplementedPostgresServer) Get(context.Context, *FilterParams) (*RecordResponse, error)
func (UnimplementedPostgresServer) GetById ¶
func (UnimplementedPostgresServer) GetById(context.Context, *IdParams) (*RecordResponse, error)
func (UnimplementedPostgresServer) Query ¶
func (UnimplementedPostgresServer) Query(context.Context, *QueryParams) (*QueryResponse, error)
func (UnimplementedPostgresServer) Update ¶
func (UnimplementedPostgresServer) Update(context.Context, *UpdateParams) (*RecordResponse, error)
type UnsafePostgresServer ¶
type UnsafePostgresServer interface {
// contains filtered or unexported methods
}
UnsafePostgresServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to PostgresServer will result in compilation errors.
type UpdateParams ¶
type UpdateParams struct { Table string `protobuf:"bytes,1,opt,name=table,proto3" json:"table,omitempty"` Id string `protobuf:"bytes,2,opt,name=id,proto3" json:"id,omitempty"` Record *anypb.Any `protobuf:"bytes,3,opt,name=record,proto3" json:"record,omitempty"` // contains filtered or unexported fields }
func (*UpdateParams) Descriptor
deprecated
func (*UpdateParams) Descriptor() ([]byte, []int)
Deprecated: Use UpdateParams.ProtoReflect.Descriptor instead.
func (*UpdateParams) GetId ¶
func (x *UpdateParams) GetId() string
func (*UpdateParams) GetRecord ¶
func (x *UpdateParams) GetRecord() *anypb.Any
func (*UpdateParams) GetTable ¶
func (x *UpdateParams) GetTable() string
func (*UpdateParams) ProtoMessage ¶
func (*UpdateParams) ProtoMessage()
func (*UpdateParams) ProtoReflect ¶
func (x *UpdateParams) ProtoReflect() protoreflect.Message
func (*UpdateParams) Reset ¶
func (x *UpdateParams) Reset()
func (*UpdateParams) String ¶
func (x *UpdateParams) String() string