Documentation ¶
Index ¶
- Variables
- func NewPrayerEndpoints() []*api.Endpoint
- func RegisterPrayerHandler(s server.Server, hdlr PrayerHandler, opts ...server.HandlerOption) error
- type PrayerHandler
- type PrayerService
- type PrayerTime
- func (*PrayerTime) Descriptor() ([]byte, []int)deprecated
- func (x *PrayerTime) GetAsr() string
- func (x *PrayerTime) GetDate() string
- func (x *PrayerTime) GetFajr() string
- func (x *PrayerTime) GetIsha() string
- func (x *PrayerTime) GetMaghrib() string
- func (x *PrayerTime) GetSunrise() string
- func (x *PrayerTime) GetZuhr() string
- func (*PrayerTime) ProtoMessage()
- func (x *PrayerTime) ProtoReflect() protoreflect.Message
- func (x *PrayerTime) Reset()
- func (x *PrayerTime) String() string
- type TimesRequest
- func (*TimesRequest) Descriptor() ([]byte, []int)deprecated
- func (x *TimesRequest) GetDate() string
- func (x *TimesRequest) GetDays() int32
- func (x *TimesRequest) GetLatitude() float64
- func (x *TimesRequest) GetLocation() string
- func (x *TimesRequest) GetLongitude() float64
- func (*TimesRequest) ProtoMessage()
- func (x *TimesRequest) ProtoReflect() protoreflect.Message
- func (x *TimesRequest) Reset()
- func (x *TimesRequest) String() string
- type TimesResponse
- func (*TimesResponse) Descriptor() ([]byte, []int)deprecated
- func (x *TimesResponse) GetDate() string
- func (x *TimesResponse) GetDays() int32
- func (x *TimesResponse) GetLatitude() float64
- func (x *TimesResponse) GetLocation() string
- func (x *TimesResponse) GetLongitude() float64
- func (x *TimesResponse) GetTimes() []*PrayerTime
- func (*TimesResponse) ProtoMessage()
- func (x *TimesResponse) ProtoReflect() protoreflect.Message
- func (x *TimesResponse) Reset()
- func (x *TimesResponse) String() string
Constants ¶
This section is empty.
Variables ¶
View Source
var File_proto_prayer_proto protoreflect.FileDescriptor
Functions ¶
func NewPrayerEndpoints ¶
func RegisterPrayerHandler ¶
func RegisterPrayerHandler(s server.Server, hdlr PrayerHandler, opts ...server.HandlerOption) error
Types ¶
type PrayerHandler ¶
type PrayerHandler interface {
Times(context.Context, *TimesRequest, *TimesResponse) error
}
type PrayerService ¶
type PrayerService interface {
Times(ctx context.Context, in *TimesRequest, opts ...client.CallOption) (*TimesResponse, error)
}
func NewPrayerService ¶
func NewPrayerService(name string, c client.Client) PrayerService
type PrayerTime ¶
type PrayerTime struct { // date for prayer times in YYYY-MM-DD format Date string `protobuf:"bytes,1,opt,name=date,proto3" json:"date,omitempty"` // fajr time Fajr string `protobuf:"bytes,2,opt,name=fajr,proto3" json:"fajr,omitempty"` // time of sunrise Sunrise string `protobuf:"bytes,3,opt,name=sunrise,proto3" json:"sunrise,omitempty"` // zuhr time Zuhr string `protobuf:"bytes,4,opt,name=zuhr,proto3" json:"zuhr,omitempty"` // asr time Asr string `protobuf:"bytes,5,opt,name=asr,proto3" json:"asr,omitempty"` // maghrib time Maghrib string `protobuf:"bytes,6,opt,name=maghrib,proto3" json:"maghrib,omitempty"` // isha time Isha string `protobuf:"bytes,7,opt,name=isha,proto3" json:"isha,omitempty"` // contains filtered or unexported fields }
func (*PrayerTime) Descriptor
deprecated
func (*PrayerTime) Descriptor() ([]byte, []int)
Deprecated: Use PrayerTime.ProtoReflect.Descriptor instead.
func (*PrayerTime) GetAsr ¶
func (x *PrayerTime) GetAsr() string
func (*PrayerTime) GetDate ¶
func (x *PrayerTime) GetDate() string
func (*PrayerTime) GetFajr ¶
func (x *PrayerTime) GetFajr() string
func (*PrayerTime) GetIsha ¶
func (x *PrayerTime) GetIsha() string
func (*PrayerTime) GetMaghrib ¶
func (x *PrayerTime) GetMaghrib() string
func (*PrayerTime) GetSunrise ¶
func (x *PrayerTime) GetSunrise() string
func (*PrayerTime) GetZuhr ¶
func (x *PrayerTime) GetZuhr() string
func (*PrayerTime) ProtoMessage ¶
func (*PrayerTime) ProtoMessage()
func (*PrayerTime) ProtoReflect ¶
func (x *PrayerTime) ProtoReflect() protoreflect.Message
func (*PrayerTime) Reset ¶
func (x *PrayerTime) Reset()
func (*PrayerTime) String ¶
func (x *PrayerTime) String() string
type TimesRequest ¶
type TimesRequest struct { // optional date in YYYY-MM-DD format, otherwise uses today Date string `protobuf:"bytes,1,opt,name=date,proto3" json:"date,omitempty"` // number of days to request times for Days int32 `protobuf:"varint,2,opt,name=days,proto3" json:"days,omitempty"` // location to retrieve prayer times for. // this can be a specific address, city, etc Location string `protobuf:"bytes,3,opt,name=location,proto3" json:"location,omitempty"` // optional latitude used in place of location Latitude float64 `protobuf:"fixed64,4,opt,name=latitude,proto3" json:"latitude,omitempty"` // optional longitude used in place of location Longitude float64 `protobuf:"fixed64,5,opt,name=longitude,proto3" json:"longitude,omitempty"` // contains filtered or unexported fields }
func (*TimesRequest) Descriptor
deprecated
func (*TimesRequest) Descriptor() ([]byte, []int)
Deprecated: Use TimesRequest.ProtoReflect.Descriptor instead.
func (*TimesRequest) GetDate ¶
func (x *TimesRequest) GetDate() string
func (*TimesRequest) GetDays ¶
func (x *TimesRequest) GetDays() int32
func (*TimesRequest) GetLatitude ¶
func (x *TimesRequest) GetLatitude() float64
func (*TimesRequest) GetLocation ¶
func (x *TimesRequest) GetLocation() string
func (*TimesRequest) GetLongitude ¶
func (x *TimesRequest) GetLongitude() float64
func (*TimesRequest) ProtoMessage ¶
func (*TimesRequest) ProtoMessage()
func (*TimesRequest) ProtoReflect ¶
func (x *TimesRequest) ProtoReflect() protoreflect.Message
func (*TimesRequest) Reset ¶
func (x *TimesRequest) Reset()
func (*TimesRequest) String ¶
func (x *TimesRequest) String() string
type TimesResponse ¶
type TimesResponse struct { // date of request Date string `protobuf:"bytes,1,opt,name=date,proto3" json:"date,omitempty"` // number of days Days int32 `protobuf:"varint,2,opt,name=days,proto3" json:"days,omitempty"` // location for the request Location string `protobuf:"bytes,3,opt,name=location,proto3" json:"location,omitempty"` // latitude of location Latitude float64 `protobuf:"fixed64,4,opt,name=latitude,proto3" json:"latitude,omitempty"` // longitude of location Longitude float64 `protobuf:"fixed64,5,opt,name=longitude,proto3" json:"longitude,omitempty"` // prayer times for the given location Times []*PrayerTime `protobuf:"bytes,6,rep,name=times,proto3" json:"times,omitempty"` // contains filtered or unexported fields }
func (*TimesResponse) Descriptor
deprecated
func (*TimesResponse) Descriptor() ([]byte, []int)
Deprecated: Use TimesResponse.ProtoReflect.Descriptor instead.
func (*TimesResponse) GetDate ¶
func (x *TimesResponse) GetDate() string
func (*TimesResponse) GetDays ¶
func (x *TimesResponse) GetDays() int32
func (*TimesResponse) GetLatitude ¶
func (x *TimesResponse) GetLatitude() float64
func (*TimesResponse) GetLocation ¶
func (x *TimesResponse) GetLocation() string
func (*TimesResponse) GetLongitude ¶
func (x *TimesResponse) GetLongitude() float64
func (*TimesResponse) GetTimes ¶
func (x *TimesResponse) GetTimes() []*PrayerTime
func (*TimesResponse) ProtoMessage ¶
func (*TimesResponse) ProtoMessage()
func (*TimesResponse) ProtoReflect ¶
func (x *TimesResponse) ProtoReflect() protoreflect.Message
func (*TimesResponse) Reset ¶
func (x *TimesResponse) Reset()
func (*TimesResponse) String ¶
func (x *TimesResponse) String() string
Click to show internal directories.
Click to hide internal directories.