Documentation
¶
Index ¶
- Constants
- Variables
- func NewUserServiceHandler(svc UserServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
- type CreateBulkUserRequest
- func (*CreateBulkUserRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateBulkUserRequest) GetRows() []*CreateBulkUserRow
- func (*CreateBulkUserRequest) ProtoMessage()
- func (x *CreateBulkUserRequest) ProtoReflect() protoreflect.Message
- func (x *CreateBulkUserRequest) Reset()
- func (x *CreateBulkUserRequest) String() string
- type CreateBulkUserResponse
- func (*CreateBulkUserResponse) Descriptor() ([]byte, []int)deprecated
- func (x *CreateBulkUserResponse) GetRows() []*User
- func (*CreateBulkUserResponse) ProtoMessage()
- func (x *CreateBulkUserResponse) ProtoReflect() protoreflect.Message
- func (x *CreateBulkUserResponse) Reset()
- func (x *CreateBulkUserResponse) String() string
- type CreateBulkUserRow
- func (*CreateBulkUserRow) Descriptor() ([]byte, []int)deprecated
- func (x *CreateBulkUserRow) GetAge() int32
- func (x *CreateBulkUserRow) GetApiKey() []byte
- func (x *CreateBulkUserRow) GetEmail() string
- func (x *CreateBulkUserRow) GetIsActive() bool
- func (x *CreateBulkUserRow) GetLoginCount() int64
- func (x *CreateBulkUserRow) GetName() string
- func (x *CreateBulkUserRow) GetPassword() string
- func (x *CreateBulkUserRow) GetPreferences() string
- func (x *CreateBulkUserRow) GetRating() float64
- func (*CreateBulkUserRow) ProtoMessage()
- func (x *CreateBulkUserRow) ProtoReflect() protoreflect.Message
- func (x *CreateBulkUserRow) Reset()
- func (x *CreateBulkUserRow) String() string
- type CreateUserRequest
- func (*CreateUserRequest) Descriptor() ([]byte, []int)deprecated
- func (x *CreateUserRequest) GetAge() int32
- func (x *CreateUserRequest) GetApiKey() []byte
- func (x *CreateUserRequest) GetEmail() string
- func (x *CreateUserRequest) GetIsActive() bool
- func (x *CreateUserRequest) GetLoginCount() int64
- func (x *CreateUserRequest) GetName() string
- func (x *CreateUserRequest) GetPassword() string
- func (x *CreateUserRequest) GetPreferences() string
- func (x *CreateUserRequest) GetRating() float64
- func (*CreateUserRequest) ProtoMessage()
- func (x *CreateUserRequest) ProtoReflect() protoreflect.Message
- func (x *CreateUserRequest) Reset()
- func (x *CreateUserRequest) String() string
- func (r *CreateUserRequest) Validate() error
- type DeleteAllUserRequest
- type DeleteUserRequest
- type GetUserByEmailRequest
- func (*GetUserByEmailRequest) Descriptor() ([]byte, []int)deprecated
- func (x *GetUserByEmailRequest) GetEmail() string
- func (*GetUserByEmailRequest) ProtoMessage()
- func (x *GetUserByEmailRequest) ProtoReflect() protoreflect.Message
- func (x *GetUserByEmailRequest) Reset()
- func (x *GetUserByEmailRequest) String() string
- type GetUserByIdRequest
- type ListActiveRequest
- func (*ListActiveRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListActiveRequest) GetIsActive() bool
- func (x *ListActiveRequest) GetLimit() int32
- func (x *ListActiveRequest) GetOffset() int32
- func (*ListActiveRequest) ProtoMessage()
- func (x *ListActiveRequest) ProtoReflect() protoreflect.Message
- func (x *ListActiveRequest) Reset()
- func (x *ListActiveRequest) String() string
- type ListActiveResponse
- func (*ListActiveResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListActiveResponse) GetRows() []*User
- func (*ListActiveResponse) ProtoMessage()
- func (x *ListActiveResponse) ProtoReflect() protoreflect.Message
- func (x *ListActiveResponse) Reset()
- func (x *ListActiveResponse) String() string
- type ListAllUserRequest
- type ListAllUserResponse
- func (*ListAllUserResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListAllUserResponse) GetRows() []*User
- func (*ListAllUserResponse) ProtoMessage()
- func (x *ListAllUserResponse) ProtoReflect() protoreflect.Message
- func (x *ListAllUserResponse) Reset()
- func (x *ListAllUserResponse) String() string
- type ListUserFilterByAgeNameRequest
- func (*ListUserFilterByAgeNameRequest) Descriptor() ([]byte, []int)deprecated
- func (x *ListUserFilterByAgeNameRequest) GetLimit() int32
- func (x *ListUserFilterByAgeNameRequest) GetMaxAge() int32
- func (x *ListUserFilterByAgeNameRequest) GetMinAge() int32
- func (x *ListUserFilterByAgeNameRequest) GetName() string
- func (x *ListUserFilterByAgeNameRequest) GetOffset() int32
- func (*ListUserFilterByAgeNameRequest) ProtoMessage()
- func (x *ListUserFilterByAgeNameRequest) ProtoReflect() protoreflect.Message
- func (x *ListUserFilterByAgeNameRequest) Reset()
- func (x *ListUserFilterByAgeNameRequest) String() string
- type ListUserFilterByAgeNameResponse
- func (*ListUserFilterByAgeNameResponse) Descriptor() ([]byte, []int)deprecated
- func (x *ListUserFilterByAgeNameResponse) GetRows() []*User
- func (x *ListUserFilterByAgeNameResponse) GetTotalSize() int64
- func (*ListUserFilterByAgeNameResponse) ProtoMessage()
- func (x *ListUserFilterByAgeNameResponse) ProtoReflect() protoreflect.Message
- func (x *ListUserFilterByAgeNameResponse) Reset()
- func (x *ListUserFilterByAgeNameResponse) String() string
- type UnimplementedUserServiceHandler
- func (UnimplementedUserServiceHandler) CreateBulkUser(context.Context, *connect.Request[CreateBulkUserRequest]) (*connect.Response[CreateBulkUserResponse], error)
- func (UnimplementedUserServiceHandler) CreateUser(context.Context, *connect.Request[CreateUserRequest]) (*connect.Response[User], error)
- func (UnimplementedUserServiceHandler) DeleteAllUser(context.Context, *connect.Request[DeleteAllUserRequest]) (*connect.Response[emptypb.Empty], error)
- func (UnimplementedUserServiceHandler) DeleteUser(context.Context, *connect.Request[DeleteUserRequest]) (*connect.Response[emptypb.Empty], error)
- func (UnimplementedUserServiceHandler) GetUserByEmail(context.Context, *connect.Request[GetUserByEmailRequest]) (*connect.Response[User], error)
- func (UnimplementedUserServiceHandler) GetUserById(context.Context, *connect.Request[GetUserByIdRequest]) (*connect.Response[User], error)
- func (UnimplementedUserServiceHandler) ListActive(context.Context, *connect.Request[ListActiveRequest]) (*connect.Response[ListActiveResponse], error)
- func (UnimplementedUserServiceHandler) ListAllUser(context.Context, *connect.Request[ListAllUserRequest]) (*connect.Response[ListAllUserResponse], error)
- func (UnimplementedUserServiceHandler) ListUserFilterByAgeName(context.Context, *connect.Request[ListUserFilterByAgeNameRequest]) (*connect.Response[ListUserFilterByAgeNameResponse], error)
- func (UnimplementedUserServiceHandler) UpdateUser(context.Context, *connect.Request[UpdateUserRequest]) (*connect.Response[User], error)
- type UpdateUserRequest
- func (*UpdateUserRequest) Descriptor() ([]byte, []int)deprecated
- func (x *UpdateUserRequest) GetAge() int32
- func (x *UpdateUserRequest) GetEmail() string
- func (x *UpdateUserRequest) GetId() int32
- func (x *UpdateUserRequest) GetIsActive() bool
- func (x *UpdateUserRequest) GetLoginCount() int64
- func (x *UpdateUserRequest) GetName() string
- func (x *UpdateUserRequest) GetPassword() string
- func (x *UpdateUserRequest) GetPreferences() string
- func (x *UpdateUserRequest) GetRating() float64
- func (*UpdateUserRequest) ProtoMessage()
- func (x *UpdateUserRequest) ProtoReflect() protoreflect.Message
- func (x *UpdateUserRequest) Reset()
- func (x *UpdateUserRequest) String() string
- func (r *UpdateUserRequest) Validate() error
- type User
- func (*User) Descriptor() ([]byte, []int)deprecated
- func (x *User) GetAge() int32
- func (x *User) GetApiKey() []byte
- func (x *User) GetCreatedAt() *timestamppb.Timestamp
- func (x *User) GetEmail() string
- func (x *User) GetId() int32
- func (x *User) GetIsActive() bool
- func (x *User) GetLoginCount() int64
- func (x *User) GetName() string
- func (x *User) GetPreferences() string
- func (x *User) GetRating() float64
- func (x *User) GetUpdatedAt() *timestamppb.Timestamp
- func (*User) ProtoMessage()
- func (x *User) ProtoReflect() protoreflect.Message
- func (x *User) Reset()
- func (x *User) String() string
- type UserServiceClient
- type UserServiceHandler
- type ValidateInterceptor
- func (i *ValidateInterceptor) WrapStreamingClient(next connect.StreamingClientFunc) connect.StreamingClientFunc
- func (i *ValidateInterceptor) WrapStreamingHandler(next connect.StreamingHandlerFunc) connect.StreamingHandlerFunc
- func (i *ValidateInterceptor) WrapUnary(next connect.UnaryFunc) connect.UnaryFunc
Constants ¶
const ( // UserServiceCreateUserProcedure is the fully-qualified name of the UserService's CreateUser RPC. UserServiceCreateUserProcedure = "/proto.UserService/CreateUser" // UserServiceGetUserByIdProcedure is the fully-qualified name of the UserService's GetUserById RPC. UserServiceGetUserByIdProcedure = "/proto.UserService/GetUserById" // UserServiceUpdateUserProcedure is the fully-qualified name of the UserService's UpdateUser RPC. UserServiceUpdateUserProcedure = "/proto.UserService/UpdateUser" // UserServiceDeleteUserProcedure is the fully-qualified name of the UserService's DeleteUser RPC. UserServiceDeleteUserProcedure = "/proto.UserService/DeleteUser" // UserServiceCreateBulkUserProcedure is the fully-qualified name of the UserService's // CreateBulkUser RPC. UserServiceCreateBulkUserProcedure = "/proto.UserService/CreateBulkUser" // UserServiceGetUserByEmailProcedure is the fully-qualified name of the UserService's // GetUserByEmail RPC. UserServiceGetUserByEmailProcedure = "/proto.UserService/GetUserByEmail" // UserServiceListAllUserProcedure is the fully-qualified name of the UserService's ListAllUser RPC. UserServiceListAllUserProcedure = "/proto.UserService/ListAllUser" // UserServiceDeleteAllUserProcedure is the fully-qualified name of the UserService's DeleteAllUser // RPC. UserServiceDeleteAllUserProcedure = "/proto.UserService/DeleteAllUser" // UserServiceListActiveProcedure is the fully-qualified name of the UserService's ListActive RPC. UserServiceListActiveProcedure = "/proto.UserService/ListActive" // UserServiceListUserFilterByAgeNameProcedure is the fully-qualified name of the UserService's // ListUserFilterByAgeName RPC. UserServiceListUserFilterByAgeNameProcedure = "/proto.UserService/ListUserFilterByAgeName" )
These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.
Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.
const (
// UserServiceName is the fully-qualified name of the UserService service.
UserServiceName = "proto.UserService"
)
Variables ¶
var File_schema_proto protoreflect.FileDescriptor
Functions ¶
func NewUserServiceHandler ¶
func NewUserServiceHandler(svc UserServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
NewUserServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.
By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.
Types ¶
type CreateBulkUserRequest ¶
type CreateBulkUserRequest struct {
Rows []*CreateBulkUserRow `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
// contains filtered or unexported fields
}
func (*CreateBulkUserRequest) Descriptor
deprecated
func (*CreateBulkUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateBulkUserRequest.ProtoReflect.Descriptor instead.
func (*CreateBulkUserRequest) GetRows ¶ added in v0.0.5
func (x *CreateBulkUserRequest) GetRows() []*CreateBulkUserRow
func (*CreateBulkUserRequest) ProtoMessage ¶
func (*CreateBulkUserRequest) ProtoMessage()
func (*CreateBulkUserRequest) ProtoReflect ¶
func (x *CreateBulkUserRequest) ProtoReflect() protoreflect.Message
func (*CreateBulkUserRequest) Reset ¶
func (x *CreateBulkUserRequest) Reset()
func (*CreateBulkUserRequest) String ¶
func (x *CreateBulkUserRequest) String() string
type CreateBulkUserResponse ¶
type CreateBulkUserResponse struct {
Rows []*User `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
// contains filtered or unexported fields
}
func (*CreateBulkUserResponse) Descriptor
deprecated
func (*CreateBulkUserResponse) Descriptor() ([]byte, []int)
Deprecated: Use CreateBulkUserResponse.ProtoReflect.Descriptor instead.
func (*CreateBulkUserResponse) GetRows ¶ added in v0.0.5
func (x *CreateBulkUserResponse) GetRows() []*User
func (*CreateBulkUserResponse) ProtoMessage ¶
func (*CreateBulkUserResponse) ProtoMessage()
func (*CreateBulkUserResponse) ProtoReflect ¶
func (x *CreateBulkUserResponse) ProtoReflect() protoreflect.Message
func (*CreateBulkUserResponse) Reset ¶
func (x *CreateBulkUserResponse) Reset()
func (*CreateBulkUserResponse) String ¶
func (x *CreateBulkUserResponse) String() string
type CreateBulkUserRow ¶ added in v0.0.5
type CreateBulkUserRow struct {
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
// Full name, e.g. "Jane Doe"
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Age *int32 `protobuf:"varint,4,opt,name=age,proto3,oneof" json:"age,omitempty"`
Password string `protobuf:"bytes,5,opt,name=password,proto3" json:"password,omitempty"`
ApiKey []byte `protobuf:"bytes,6,opt,name=api_key,json=apiKey,proto3,oneof" json:"api_key,omitempty"`
IsActive *bool `protobuf:"varint,7,opt,name=is_active,json=isActive,proto3,oneof" json:"is_active,omitempty"`
LoginCount *int64 `protobuf:"varint,8,opt,name=login_count,json=loginCount,proto3,oneof" json:"login_count,omitempty"`
Rating *float64 `protobuf:"fixed64,9,opt,name=rating,proto3,oneof" json:"rating,omitempty"`
// UI preferences, e.g. {"theme":"dark"}
Preferences *string `protobuf:"bytes,10,opt,name=preferences,proto3,oneof" json:"preferences,omitempty"`
// contains filtered or unexported fields
}
func (*CreateBulkUserRow) Descriptor
deprecated
added in
v0.0.5
func (*CreateBulkUserRow) Descriptor() ([]byte, []int)
Deprecated: Use CreateBulkUserRow.ProtoReflect.Descriptor instead.
func (*CreateBulkUserRow) GetAge ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetAge() int32
func (*CreateBulkUserRow) GetApiKey ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetApiKey() []byte
func (*CreateBulkUserRow) GetEmail ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetEmail() string
func (*CreateBulkUserRow) GetIsActive ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetIsActive() bool
func (*CreateBulkUserRow) GetLoginCount ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetLoginCount() int64
func (*CreateBulkUserRow) GetName ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetName() string
func (*CreateBulkUserRow) GetPassword ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetPassword() string
func (*CreateBulkUserRow) GetPreferences ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetPreferences() string
func (*CreateBulkUserRow) GetRating ¶ added in v0.0.5
func (x *CreateBulkUserRow) GetRating() float64
func (*CreateBulkUserRow) ProtoMessage ¶ added in v0.0.5
func (*CreateBulkUserRow) ProtoMessage()
func (*CreateBulkUserRow) ProtoReflect ¶ added in v0.0.5
func (x *CreateBulkUserRow) ProtoReflect() protoreflect.Message
func (*CreateBulkUserRow) Reset ¶ added in v0.0.5
func (x *CreateBulkUserRow) Reset()
func (*CreateBulkUserRow) String ¶ added in v0.0.5
func (x *CreateBulkUserRow) String() string
type CreateUserRequest ¶
type CreateUserRequest struct {
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
// Full name, e.g. "Jane Doe"
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Age *int32 `protobuf:"varint,4,opt,name=age,proto3,oneof" json:"age,omitempty"`
Password string `protobuf:"bytes,5,opt,name=password,proto3" json:"password,omitempty"`
ApiKey []byte `protobuf:"bytes,6,opt,name=api_key,json=apiKey,proto3,oneof" json:"api_key,omitempty"`
IsActive *bool `protobuf:"varint,7,opt,name=is_active,json=isActive,proto3,oneof" json:"is_active,omitempty"`
LoginCount *int64 `protobuf:"varint,8,opt,name=login_count,json=loginCount,proto3,oneof" json:"login_count,omitempty"`
Rating *float64 `protobuf:"fixed64,9,opt,name=rating,proto3,oneof" json:"rating,omitempty"`
// UI preferences, e.g. {"theme":"dark"}
Preferences *string `protobuf:"bytes,10,opt,name=preferences,proto3,oneof" json:"preferences,omitempty"`
// contains filtered or unexported fields
}
func (*CreateUserRequest) Descriptor
deprecated
func (*CreateUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use CreateUserRequest.ProtoReflect.Descriptor instead.
func (*CreateUserRequest) GetAge ¶
func (x *CreateUserRequest) GetAge() int32
func (*CreateUserRequest) GetApiKey ¶
func (x *CreateUserRequest) GetApiKey() []byte
func (*CreateUserRequest) GetEmail ¶
func (x *CreateUserRequest) GetEmail() string
func (*CreateUserRequest) GetIsActive ¶
func (x *CreateUserRequest) GetIsActive() bool
func (*CreateUserRequest) GetLoginCount ¶
func (x *CreateUserRequest) GetLoginCount() int64
func (*CreateUserRequest) GetName ¶
func (x *CreateUserRequest) GetName() string
func (*CreateUserRequest) GetPassword ¶
func (x *CreateUserRequest) GetPassword() string
func (*CreateUserRequest) GetPreferences ¶
func (x *CreateUserRequest) GetPreferences() string
func (*CreateUserRequest) GetRating ¶
func (x *CreateUserRequest) GetRating() float64
func (*CreateUserRequest) ProtoMessage ¶
func (*CreateUserRequest) ProtoMessage()
func (*CreateUserRequest) ProtoReflect ¶
func (x *CreateUserRequest) ProtoReflect() protoreflect.Message
func (*CreateUserRequest) Reset ¶
func (x *CreateUserRequest) Reset()
func (*CreateUserRequest) String ¶
func (x *CreateUserRequest) String() string
func (*CreateUserRequest) Validate ¶
func (r *CreateUserRequest) Validate() error
type DeleteAllUserRequest ¶
type DeleteAllUserRequest struct {
// contains filtered or unexported fields
}
func (*DeleteAllUserRequest) Descriptor
deprecated
func (*DeleteAllUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteAllUserRequest.ProtoReflect.Descriptor instead.
func (*DeleteAllUserRequest) ProtoMessage ¶
func (*DeleteAllUserRequest) ProtoMessage()
func (*DeleteAllUserRequest) ProtoReflect ¶
func (x *DeleteAllUserRequest) ProtoReflect() protoreflect.Message
func (*DeleteAllUserRequest) Reset ¶
func (x *DeleteAllUserRequest) Reset()
func (*DeleteAllUserRequest) String ¶
func (x *DeleteAllUserRequest) String() string
type DeleteUserRequest ¶
type DeleteUserRequest struct {
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
// contains filtered or unexported fields
}
func (*DeleteUserRequest) Descriptor
deprecated
func (*DeleteUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use DeleteUserRequest.ProtoReflect.Descriptor instead.
func (*DeleteUserRequest) GetId ¶ added in v0.0.6
func (x *DeleteUserRequest) GetId() int32
func (*DeleteUserRequest) ProtoMessage ¶
func (*DeleteUserRequest) ProtoMessage()
func (*DeleteUserRequest) ProtoReflect ¶
func (x *DeleteUserRequest) ProtoReflect() protoreflect.Message
func (*DeleteUserRequest) Reset ¶
func (x *DeleteUserRequest) Reset()
func (*DeleteUserRequest) String ¶
func (x *DeleteUserRequest) String() string
type GetUserByEmailRequest ¶
type GetUserByEmailRequest struct {
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
// contains filtered or unexported fields
}
func (*GetUserByEmailRequest) Descriptor
deprecated
func (*GetUserByEmailRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetUserByEmailRequest.ProtoReflect.Descriptor instead.
func (*GetUserByEmailRequest) GetEmail ¶
func (x *GetUserByEmailRequest) GetEmail() string
func (*GetUserByEmailRequest) ProtoMessage ¶
func (*GetUserByEmailRequest) ProtoMessage()
func (*GetUserByEmailRequest) ProtoReflect ¶
func (x *GetUserByEmailRequest) ProtoReflect() protoreflect.Message
func (*GetUserByEmailRequest) Reset ¶
func (x *GetUserByEmailRequest) Reset()
func (*GetUserByEmailRequest) String ¶
func (x *GetUserByEmailRequest) String() string
type GetUserByIdRequest ¶ added in v0.0.6
type GetUserByIdRequest struct {
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
// contains filtered or unexported fields
}
func (*GetUserByIdRequest) Descriptor
deprecated
added in
v0.0.6
func (*GetUserByIdRequest) Descriptor() ([]byte, []int)
Deprecated: Use GetUserByIdRequest.ProtoReflect.Descriptor instead.
func (*GetUserByIdRequest) GetId ¶ added in v0.0.6
func (x *GetUserByIdRequest) GetId() int32
func (*GetUserByIdRequest) ProtoMessage ¶ added in v0.0.6
func (*GetUserByIdRequest) ProtoMessage()
func (*GetUserByIdRequest) ProtoReflect ¶ added in v0.0.6
func (x *GetUserByIdRequest) ProtoReflect() protoreflect.Message
func (*GetUserByIdRequest) Reset ¶ added in v0.0.6
func (x *GetUserByIdRequest) Reset()
func (*GetUserByIdRequest) String ¶ added in v0.0.6
func (x *GetUserByIdRequest) String() string
type ListActiveRequest ¶
type ListActiveRequest struct {
Limit int32 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"`
Offset int32 `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
IsActive bool `protobuf:"varint,3,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"`
// contains filtered or unexported fields
}
func (*ListActiveRequest) Descriptor
deprecated
func (*ListActiveRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListActiveRequest.ProtoReflect.Descriptor instead.
func (*ListActiveRequest) GetIsActive ¶
func (x *ListActiveRequest) GetIsActive() bool
func (*ListActiveRequest) GetLimit ¶
func (x *ListActiveRequest) GetLimit() int32
func (*ListActiveRequest) GetOffset ¶
func (x *ListActiveRequest) GetOffset() int32
func (*ListActiveRequest) ProtoMessage ¶
func (*ListActiveRequest) ProtoMessage()
func (*ListActiveRequest) ProtoReflect ¶
func (x *ListActiveRequest) ProtoReflect() protoreflect.Message
func (*ListActiveRequest) Reset ¶
func (x *ListActiveRequest) Reset()
func (*ListActiveRequest) String ¶
func (x *ListActiveRequest) String() string
type ListActiveResponse ¶
type ListActiveResponse struct {
Rows []*User `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
// contains filtered or unexported fields
}
func (*ListActiveResponse) Descriptor
deprecated
func (*ListActiveResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListActiveResponse.ProtoReflect.Descriptor instead.
func (*ListActiveResponse) GetRows ¶ added in v0.0.5
func (x *ListActiveResponse) GetRows() []*User
func (*ListActiveResponse) ProtoMessage ¶
func (*ListActiveResponse) ProtoMessage()
func (*ListActiveResponse) ProtoReflect ¶
func (x *ListActiveResponse) ProtoReflect() protoreflect.Message
func (*ListActiveResponse) Reset ¶
func (x *ListActiveResponse) Reset()
func (*ListActiveResponse) String ¶
func (x *ListActiveResponse) String() string
type ListAllUserRequest ¶
type ListAllUserRequest struct {
// contains filtered or unexported fields
}
func (*ListAllUserRequest) Descriptor
deprecated
func (*ListAllUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListAllUserRequest.ProtoReflect.Descriptor instead.
func (*ListAllUserRequest) ProtoMessage ¶
func (*ListAllUserRequest) ProtoMessage()
func (*ListAllUserRequest) ProtoReflect ¶
func (x *ListAllUserRequest) ProtoReflect() protoreflect.Message
func (*ListAllUserRequest) Reset ¶
func (x *ListAllUserRequest) Reset()
func (*ListAllUserRequest) String ¶
func (x *ListAllUserRequest) String() string
type ListAllUserResponse ¶
type ListAllUserResponse struct {
Rows []*User `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
// contains filtered or unexported fields
}
func (*ListAllUserResponse) Descriptor
deprecated
func (*ListAllUserResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListAllUserResponse.ProtoReflect.Descriptor instead.
func (*ListAllUserResponse) GetRows ¶ added in v0.0.5
func (x *ListAllUserResponse) GetRows() []*User
func (*ListAllUserResponse) ProtoMessage ¶
func (*ListAllUserResponse) ProtoMessage()
func (*ListAllUserResponse) ProtoReflect ¶
func (x *ListAllUserResponse) ProtoReflect() protoreflect.Message
func (*ListAllUserResponse) Reset ¶
func (x *ListAllUserResponse) Reset()
func (*ListAllUserResponse) String ¶
func (x *ListAllUserResponse) String() string
type ListUserFilterByAgeNameRequest ¶
type ListUserFilterByAgeNameRequest struct {
Limit int32 `protobuf:"varint,1,opt,name=limit,proto3" json:"limit,omitempty"`
Offset int32 `protobuf:"varint,2,opt,name=offset,proto3" json:"offset,omitempty"`
MinAge int32 `protobuf:"varint,3,opt,name=min_age,json=minAge,proto3" json:"min_age,omitempty"`
MaxAge int32 `protobuf:"varint,4,opt,name=max_age,json=maxAge,proto3" json:"max_age,omitempty"`
Name string `protobuf:"bytes,5,opt,name=name,proto3" json:"name,omitempty"`
// contains filtered or unexported fields
}
func (*ListUserFilterByAgeNameRequest) Descriptor
deprecated
func (*ListUserFilterByAgeNameRequest) Descriptor() ([]byte, []int)
Deprecated: Use ListUserFilterByAgeNameRequest.ProtoReflect.Descriptor instead.
func (*ListUserFilterByAgeNameRequest) GetLimit ¶
func (x *ListUserFilterByAgeNameRequest) GetLimit() int32
func (*ListUserFilterByAgeNameRequest) GetMaxAge ¶
func (x *ListUserFilterByAgeNameRequest) GetMaxAge() int32
func (*ListUserFilterByAgeNameRequest) GetMinAge ¶
func (x *ListUserFilterByAgeNameRequest) GetMinAge() int32
func (*ListUserFilterByAgeNameRequest) GetName ¶
func (x *ListUserFilterByAgeNameRequest) GetName() string
func (*ListUserFilterByAgeNameRequest) GetOffset ¶
func (x *ListUserFilterByAgeNameRequest) GetOffset() int32
func (*ListUserFilterByAgeNameRequest) ProtoMessage ¶
func (*ListUserFilterByAgeNameRequest) ProtoMessage()
func (*ListUserFilterByAgeNameRequest) ProtoReflect ¶
func (x *ListUserFilterByAgeNameRequest) ProtoReflect() protoreflect.Message
func (*ListUserFilterByAgeNameRequest) Reset ¶
func (x *ListUserFilterByAgeNameRequest) Reset()
func (*ListUserFilterByAgeNameRequest) String ¶
func (x *ListUserFilterByAgeNameRequest) String() string
type ListUserFilterByAgeNameResponse ¶
type ListUserFilterByAgeNameResponse struct {
Rows []*User `protobuf:"bytes,1,rep,name=rows,proto3" json:"rows,omitempty"`
TotalSize int64 `protobuf:"varint,2,opt,name=total_size,json=totalSize,proto3" json:"total_size,omitempty"`
// contains filtered or unexported fields
}
func (*ListUserFilterByAgeNameResponse) Descriptor
deprecated
func (*ListUserFilterByAgeNameResponse) Descriptor() ([]byte, []int)
Deprecated: Use ListUserFilterByAgeNameResponse.ProtoReflect.Descriptor instead.
func (*ListUserFilterByAgeNameResponse) GetRows ¶ added in v0.0.5
func (x *ListUserFilterByAgeNameResponse) GetRows() []*User
func (*ListUserFilterByAgeNameResponse) GetTotalSize ¶ added in v0.0.5
func (x *ListUserFilterByAgeNameResponse) GetTotalSize() int64
func (*ListUserFilterByAgeNameResponse) ProtoMessage ¶
func (*ListUserFilterByAgeNameResponse) ProtoMessage()
func (*ListUserFilterByAgeNameResponse) ProtoReflect ¶
func (x *ListUserFilterByAgeNameResponse) ProtoReflect() protoreflect.Message
func (*ListUserFilterByAgeNameResponse) Reset ¶
func (x *ListUserFilterByAgeNameResponse) Reset()
func (*ListUserFilterByAgeNameResponse) String ¶
func (x *ListUserFilterByAgeNameResponse) String() string
type UnimplementedUserServiceHandler ¶
type UnimplementedUserServiceHandler struct{}
UnimplementedUserServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedUserServiceHandler) CreateBulkUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) CreateBulkUser(context.Context, *connect.Request[CreateBulkUserRequest]) (*connect.Response[CreateBulkUserResponse], error)
func (UnimplementedUserServiceHandler) CreateUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) CreateUser(context.Context, *connect.Request[CreateUserRequest]) (*connect.Response[User], error)
func (UnimplementedUserServiceHandler) DeleteAllUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) DeleteUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) GetUserByEmail ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) GetUserByEmail(context.Context, *connect.Request[GetUserByEmailRequest]) (*connect.Response[User], error)
func (UnimplementedUserServiceHandler) GetUserById ¶ added in v0.0.6
func (UnimplementedUserServiceHandler) GetUserById(context.Context, *connect.Request[GetUserByIdRequest]) (*connect.Response[User], error)
func (UnimplementedUserServiceHandler) ListActive ¶
func (UnimplementedUserServiceHandler) ListActive(context.Context, *connect.Request[ListActiveRequest]) (*connect.Response[ListActiveResponse], error)
func (UnimplementedUserServiceHandler) ListAllUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) ListAllUser(context.Context, *connect.Request[ListAllUserRequest]) (*connect.Response[ListAllUserResponse], error)
func (UnimplementedUserServiceHandler) ListUserFilterByAgeName ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) ListUserFilterByAgeName(context.Context, *connect.Request[ListUserFilterByAgeNameRequest]) (*connect.Response[ListUserFilterByAgeNameResponse], error)
func (UnimplementedUserServiceHandler) UpdateUser ¶ added in v0.0.5
func (UnimplementedUserServiceHandler) UpdateUser(context.Context, *connect.Request[UpdateUserRequest]) (*connect.Response[User], error)
type UpdateUserRequest ¶
type UpdateUserRequest struct {
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
// Full name, e.g. "Jane Doe"
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Age *int32 `protobuf:"varint,4,opt,name=age,proto3,oneof" json:"age,omitempty"`
Password *string `protobuf:"bytes,5,opt,name=password,proto3,oneof" json:"password,omitempty"`
IsActive *bool `protobuf:"varint,7,opt,name=is_active,json=isActive,proto3,oneof" json:"is_active,omitempty"`
LoginCount *int64 `protobuf:"varint,8,opt,name=login_count,json=loginCount,proto3,oneof" json:"login_count,omitempty"`
Rating *float64 `protobuf:"fixed64,9,opt,name=rating,proto3,oneof" json:"rating,omitempty"`
// UI preferences, e.g. {"theme":"dark"}
Preferences *string `protobuf:"bytes,10,opt,name=preferences,proto3,oneof" json:"preferences,omitempty"`
// contains filtered or unexported fields
}
func (*UpdateUserRequest) Descriptor
deprecated
func (*UpdateUserRequest) Descriptor() ([]byte, []int)
Deprecated: Use UpdateUserRequest.ProtoReflect.Descriptor instead.
func (*UpdateUserRequest) GetAge ¶
func (x *UpdateUserRequest) GetAge() int32
func (*UpdateUserRequest) GetEmail ¶
func (x *UpdateUserRequest) GetEmail() string
func (*UpdateUserRequest) GetId ¶ added in v0.0.6
func (x *UpdateUserRequest) GetId() int32
func (*UpdateUserRequest) GetIsActive ¶
func (x *UpdateUserRequest) GetIsActive() bool
func (*UpdateUserRequest) GetLoginCount ¶
func (x *UpdateUserRequest) GetLoginCount() int64
func (*UpdateUserRequest) GetName ¶
func (x *UpdateUserRequest) GetName() string
func (*UpdateUserRequest) GetPassword ¶
func (x *UpdateUserRequest) GetPassword() string
func (*UpdateUserRequest) GetPreferences ¶
func (x *UpdateUserRequest) GetPreferences() string
func (*UpdateUserRequest) GetRating ¶
func (x *UpdateUserRequest) GetRating() float64
func (*UpdateUserRequest) ProtoMessage ¶
func (*UpdateUserRequest) ProtoMessage()
func (*UpdateUserRequest) ProtoReflect ¶
func (x *UpdateUserRequest) ProtoReflect() protoreflect.Message
func (*UpdateUserRequest) Reset ¶
func (x *UpdateUserRequest) Reset()
func (*UpdateUserRequest) String ¶
func (x *UpdateUserRequest) String() string
func (*UpdateUserRequest) Validate ¶
func (r *UpdateUserRequest) Validate() error
type User ¶
type User struct {
Id int32 `protobuf:"varint,1,opt,name=id,proto3" json:"id,omitempty"`
Email string `protobuf:"bytes,2,opt,name=email,proto3" json:"email,omitempty"`
// Full name, e.g. "Jane Doe"
Name string `protobuf:"bytes,3,opt,name=name,proto3" json:"name,omitempty"`
Age *int32 `protobuf:"varint,4,opt,name=age,proto3,oneof" json:"age,omitempty"`
ApiKey []byte `protobuf:"bytes,6,opt,name=api_key,json=apiKey,proto3" json:"api_key,omitempty"`
IsActive bool `protobuf:"varint,7,opt,name=is_active,json=isActive,proto3" json:"is_active,omitempty"`
LoginCount int64 `protobuf:"varint,8,opt,name=login_count,json=loginCount,proto3" json:"login_count,omitempty"`
Rating float64 `protobuf:"fixed64,9,opt,name=rating,proto3" json:"rating,omitempty"`
// UI preferences, e.g. {"theme":"dark"}
Preferences string `protobuf:"bytes,10,opt,name=preferences,proto3" json:"preferences,omitempty"`
CreatedAt *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=created_at,json=createdAt,proto3" json:"created_at,omitempty"`
UpdatedAt *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=updated_at,json=updatedAt,proto3" json:"updated_at,omitempty"`
// contains filtered or unexported fields
}
User represents as user entity
func (*User) Descriptor
deprecated
func (*User) GetCreatedAt ¶
func (x *User) GetCreatedAt() *timestamppb.Timestamp
func (*User) GetIsActive ¶
func (*User) GetLoginCount ¶
func (*User) GetPreferences ¶
func (*User) GetUpdatedAt ¶
func (x *User) GetUpdatedAt() *timestamppb.Timestamp
func (*User) ProtoMessage ¶
func (*User) ProtoMessage()
func (*User) ProtoReflect ¶
func (x *User) ProtoReflect() protoreflect.Message
type UserServiceClient ¶
type UserServiceClient interface {
CreateUser(context.Context, *connect.Request[CreateUserRequest]) (*connect.Response[User], error)
GetUserById(context.Context, *connect.Request[GetUserByIdRequest]) (*connect.Response[User], error)
UpdateUser(context.Context, *connect.Request[UpdateUserRequest]) (*connect.Response[User], error)
DeleteUser(context.Context, *connect.Request[DeleteUserRequest]) (*connect.Response[emptypb.Empty], error)
// re-importing the same users overwrites the row that shares the email
CreateBulkUser(context.Context, *connect.Request[CreateBulkUserRequest]) (*connect.Response[CreateBulkUserResponse], error)
// Look up a user by email address
GetUserByEmail(context.Context, *connect.Request[GetUserByEmailRequest]) (*connect.Response[User], error)
ListAllUser(context.Context, *connect.Request[ListAllUserRequest]) (*connect.Response[ListAllUserResponse], error)
DeleteAllUser(context.Context, *connect.Request[DeleteAllUserRequest]) (*connect.Response[emptypb.Empty], error)
ListActive(context.Context, *connect.Request[ListActiveRequest]) (*connect.Response[ListActiveResponse], error)
ListUserFilterByAgeName(context.Context, *connect.Request[ListUserFilterByAgeNameRequest]) (*connect.Response[ListUserFilterByAgeNameResponse], error)
}
UserServiceClient is a client for the proto.UserService service.
func NewUserServiceClient ¶
func NewUserServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) UserServiceClient
NewUserServiceClient constructs a client for the proto.UserService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.
The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).
type UserServiceHandler ¶
type UserServiceHandler interface {
CreateUser(context.Context, *connect.Request[CreateUserRequest]) (*connect.Response[User], error)
GetUserById(context.Context, *connect.Request[GetUserByIdRequest]) (*connect.Response[User], error)
UpdateUser(context.Context, *connect.Request[UpdateUserRequest]) (*connect.Response[User], error)
DeleteUser(context.Context, *connect.Request[DeleteUserRequest]) (*connect.Response[emptypb.Empty], error)
// re-importing the same users overwrites the row that shares the email
CreateBulkUser(context.Context, *connect.Request[CreateBulkUserRequest]) (*connect.Response[CreateBulkUserResponse], error)
// Look up a user by email address
GetUserByEmail(context.Context, *connect.Request[GetUserByEmailRequest]) (*connect.Response[User], error)
ListAllUser(context.Context, *connect.Request[ListAllUserRequest]) (*connect.Response[ListAllUserResponse], error)
DeleteAllUser(context.Context, *connect.Request[DeleteAllUserRequest]) (*connect.Response[emptypb.Empty], error)
ListActive(context.Context, *connect.Request[ListActiveRequest]) (*connect.Response[ListActiveResponse], error)
ListUserFilterByAgeName(context.Context, *connect.Request[ListUserFilterByAgeNameRequest]) (*connect.Response[ListUserFilterByAgeNameResponse], error)
}
UserServiceHandler is an implementation of the proto.UserService service.
type ValidateInterceptor ¶
type ValidateInterceptor struct{}
ValidateInterceptor calls the generated Validate() method on any request message that implements it
func NewValidateInterceptor ¶
func NewValidateInterceptor() *ValidateInterceptor
func (*ValidateInterceptor) WrapStreamingClient ¶
func (i *ValidateInterceptor) WrapStreamingClient(next connect.StreamingClientFunc) connect.StreamingClientFunc
WrapStreamingClient implements connect.Interceptor.
func (*ValidateInterceptor) WrapStreamingHandler ¶
func (i *ValidateInterceptor) WrapStreamingHandler(next connect.StreamingHandlerFunc) connect.StreamingHandlerFunc
WrapStreamingHandler implements connect.Interceptor.