Documentation ¶
Index ¶
- Constants
- func NewBusinessHoursServiceHandler(svc BusinessHoursServiceHandler, opts ...connect_go.HandlerOption) (string, http.Handler)
- type BusinessHoursServiceClient
- type BusinessHoursServiceHandler
- type UnimplementedBusinessHoursServiceHandler
- func (UnimplementedBusinessHoursServiceHandler) AddIntervalToBusinessHours(context.Context, ...) (*connect_go.Response[businesshours.AddIntervalToBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) DeleteBusinessHours(context.Context, *connect_go.Request[businesshours.DeleteBusinessHoursRequest]) (*connect_go.Response[businesshours.DeleteBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) EvaluateBusinessHours(context.Context, ...) (*connect_go.Response[businesshours.EvaluateBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) GetBusinessHours(context.Context, *connect_go.Request[businesshours.GetBusinessHoursRequest]) (*connect_go.Response[businesshours.GetBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) ListBusinessHours(context.Context, *connect_go.Request[businesshours.ListBusinessHoursRequest]) (*connect_go.Response[businesshours.ListBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) RemoveIntervalFromBusinessHours(context.Context, ...) (*connect_go.Response[businesshours.RemoveIntervalFromBusinessHoursResponse], ...)
- func (UnimplementedBusinessHoursServiceHandler) SetBusinessHours(context.Context, *connect_go.Request[businesshours.SetBusinessHoursRequest]) (*connect_go.Response[businesshours.SetBusinessHoursResponse], error)
- func (UnimplementedBusinessHoursServiceHandler) UpdateBusinessHoursInfo(context.Context, ...) (*connect_go.Response[businesshours.UpdateBusinessHoursInfoResponse], error)
Constants ¶
const ( // BusinessHoursServiceListBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's ListBusinessHours RPC. BusinessHoursServiceListBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/ListBusinessHours" // BusinessHoursServiceGetBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's GetBusinessHours RPC. BusinessHoursServiceGetBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/GetBusinessHours" // BusinessHoursServiceSetBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's SetBusinessHours RPC. BusinessHoursServiceSetBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/SetBusinessHours" // BusinessHoursServiceAddIntervalToBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's AddIntervalToBusinessHours RPC. BusinessHoursServiceAddIntervalToBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/AddIntervalToBusinessHours" // BusinessHoursServiceRemoveIntervalFromBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's RemoveIntervalFromBusinessHours RPC. BusinessHoursServiceRemoveIntervalFromBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/RemoveIntervalFromBusinessHours" // BusinessHoursServiceUpdateBusinessHoursInfoProcedure is the fully-qualified name of the // BusinessHoursService's UpdateBusinessHoursInfo RPC. BusinessHoursServiceUpdateBusinessHoursInfoProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/UpdateBusinessHoursInfo" // BusinessHoursServiceDeleteBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's DeleteBusinessHours RPC. BusinessHoursServiceDeleteBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/DeleteBusinessHours" // BusinessHoursServiceEvaluateBusinessHoursProcedure is the fully-qualified name of the // BusinessHoursService's EvaluateBusinessHours RPC. BusinessHoursServiceEvaluateBusinessHoursProcedure = "/api.v1alpha1.org.businesshours.BusinessHoursService/EvaluateBusinessHours" )
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 (
// BusinessHoursServiceName is the fully-qualified name of the BusinessHoursService service.
BusinessHoursServiceName = "api.v1alpha1.org.businesshours.BusinessHoursService"
)
Variables ¶
This section is empty.
Functions ¶
func NewBusinessHoursServiceHandler ¶
func NewBusinessHoursServiceHandler(svc BusinessHoursServiceHandler, opts ...connect_go.HandlerOption) (string, http.Handler)
NewBusinessHoursServiceHandler 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 BusinessHoursServiceClient ¶
type BusinessHoursServiceClient interface { // ListBusinessHours returns all business hours for an Org. ListBusinessHours(context.Context, *connect_go.Request[businesshours.ListBusinessHoursRequest]) (*connect_go.Response[businesshours.ListBusinessHoursResponse], error) // GetBusinessHours returns the business hours for the ID. GetBusinessHours(context.Context, *connect_go.Request[businesshours.GetBusinessHoursRequest]) (*connect_go.Response[businesshours.GetBusinessHoursResponse], error) // SetBusinessHours initializes a business hours object SetBusinessHours(context.Context, *connect_go.Request[businesshours.SetBusinessHoursRequest]) (*connect_go.Response[businesshours.SetBusinessHoursResponse], error) // AddIntervalToBusinessHours adds a day interval to a business hours object AddIntervalToBusinessHours(context.Context, *connect_go.Request[businesshours.AddIntervalToBusinessHoursRequest]) (*connect_go.Response[businesshours.AddIntervalToBusinessHoursResponse], error) // RemoveIntervalFromBusinessHours removes a day interval from a business hours object RemoveIntervalFromBusinessHours(context.Context, *connect_go.Request[businesshours.RemoveIntervalFromBusinessHoursRequest]) (*connect_go.Response[businesshours.RemoveIntervalFromBusinessHoursResponse], error) // UpdateBusinessHoursInfo updates the general info of a business hours object UpdateBusinessHoursInfo(context.Context, *connect_go.Request[businesshours.UpdateBusinessHoursInfoRequest]) (*connect_go.Response[businesshours.UpdateBusinessHoursInfoResponse], error) // DeleteBusinessHours removes business hours. DeleteBusinessHours(context.Context, *connect_go.Request[businesshours.DeleteBusinessHoursRequest]) (*connect_go.Response[businesshours.DeleteBusinessHoursResponse], error) // EvaluateBusinessHours determines whether or not the current time is within a business hours day interval EvaluateBusinessHours(context.Context, *connect_go.Request[businesshours.EvaluateBusinessHoursRequest]) (*connect_go.Response[businesshours.EvaluateBusinessHoursResponse], error) }
BusinessHoursServiceClient is a client for the api.v1alpha1.org.businesshours.BusinessHoursService service.
func NewBusinessHoursServiceClient ¶
func NewBusinessHoursServiceClient(httpClient connect_go.HTTPClient, baseURL string, opts ...connect_go.ClientOption) BusinessHoursServiceClient
NewBusinessHoursServiceClient constructs a client for the api.v1alpha1.org.businesshours.BusinessHoursService 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 BusinessHoursServiceHandler ¶
type BusinessHoursServiceHandler interface { // ListBusinessHours returns all business hours for an Org. ListBusinessHours(context.Context, *connect_go.Request[businesshours.ListBusinessHoursRequest]) (*connect_go.Response[businesshours.ListBusinessHoursResponse], error) // GetBusinessHours returns the business hours for the ID. GetBusinessHours(context.Context, *connect_go.Request[businesshours.GetBusinessHoursRequest]) (*connect_go.Response[businesshours.GetBusinessHoursResponse], error) // SetBusinessHours initializes a business hours object SetBusinessHours(context.Context, *connect_go.Request[businesshours.SetBusinessHoursRequest]) (*connect_go.Response[businesshours.SetBusinessHoursResponse], error) // AddIntervalToBusinessHours adds a day interval to a business hours object AddIntervalToBusinessHours(context.Context, *connect_go.Request[businesshours.AddIntervalToBusinessHoursRequest]) (*connect_go.Response[businesshours.AddIntervalToBusinessHoursResponse], error) // RemoveIntervalFromBusinessHours removes a day interval from a business hours object RemoveIntervalFromBusinessHours(context.Context, *connect_go.Request[businesshours.RemoveIntervalFromBusinessHoursRequest]) (*connect_go.Response[businesshours.RemoveIntervalFromBusinessHoursResponse], error) // UpdateBusinessHoursInfo updates the general info of a business hours object UpdateBusinessHoursInfo(context.Context, *connect_go.Request[businesshours.UpdateBusinessHoursInfoRequest]) (*connect_go.Response[businesshours.UpdateBusinessHoursInfoResponse], error) // DeleteBusinessHours removes business hours. DeleteBusinessHours(context.Context, *connect_go.Request[businesshours.DeleteBusinessHoursRequest]) (*connect_go.Response[businesshours.DeleteBusinessHoursResponse], error) // EvaluateBusinessHours determines whether or not the current time is within a business hours day interval EvaluateBusinessHours(context.Context, *connect_go.Request[businesshours.EvaluateBusinessHoursRequest]) (*connect_go.Response[businesshours.EvaluateBusinessHoursResponse], error) }
BusinessHoursServiceHandler is an implementation of the api.v1alpha1.org.businesshours.BusinessHoursService service.
type UnimplementedBusinessHoursServiceHandler ¶
type UnimplementedBusinessHoursServiceHandler struct{}
UnimplementedBusinessHoursServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedBusinessHoursServiceHandler) AddIntervalToBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) AddIntervalToBusinessHours(context.Context, *connect_go.Request[businesshours.AddIntervalToBusinessHoursRequest]) (*connect_go.Response[businesshours.AddIntervalToBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) DeleteBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) DeleteBusinessHours(context.Context, *connect_go.Request[businesshours.DeleteBusinessHoursRequest]) (*connect_go.Response[businesshours.DeleteBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) EvaluateBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) EvaluateBusinessHours(context.Context, *connect_go.Request[businesshours.EvaluateBusinessHoursRequest]) (*connect_go.Response[businesshours.EvaluateBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) GetBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) GetBusinessHours(context.Context, *connect_go.Request[businesshours.GetBusinessHoursRequest]) (*connect_go.Response[businesshours.GetBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) ListBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) ListBusinessHours(context.Context, *connect_go.Request[businesshours.ListBusinessHoursRequest]) (*connect_go.Response[businesshours.ListBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) RemoveIntervalFromBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) RemoveIntervalFromBusinessHours(context.Context, *connect_go.Request[businesshours.RemoveIntervalFromBusinessHoursRequest]) (*connect_go.Response[businesshours.RemoveIntervalFromBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) SetBusinessHours ¶
func (UnimplementedBusinessHoursServiceHandler) SetBusinessHours(context.Context, *connect_go.Request[businesshours.SetBusinessHoursRequest]) (*connect_go.Response[businesshours.SetBusinessHoursResponse], error)
func (UnimplementedBusinessHoursServiceHandler) UpdateBusinessHoursInfo ¶
func (UnimplementedBusinessHoursServiceHandler) UpdateBusinessHoursInfo(context.Context, *connect_go.Request[businesshours.UpdateBusinessHoursInfoRequest]) (*connect_go.Response[businesshours.UpdateBusinessHoursInfoResponse], error)