Documentation ¶
Index ¶
- type Location
- type LocationEventHandler
- type LocationValidateRequest
- type LocationValidationResponseV1
- type LocationValidationSubscriber
- func (s *LocationValidationSubscriber) Connect(ctx context.Context, worker subscriptions.Worker) error
- func (s *LocationValidationSubscriber) ProcessEvents(ctx context.Context, sub *esdb.PersistentSubscription, workerID int) error
- func (s *LocationValidationSubscriber) When(ctx context.Context, evt eventstore.Event) error
- type ValidatedAddress
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Location ¶
type Location struct { Country string `json:"country"` CountryCodeA2 string `json:"countryCodeA2"` CountryCodeA3 string `json:"countryCodeA3"` Region string `json:"region"` Locality string `json:"locality"` Address string `json:"address"` Address2 string `json:"address2"` Zip string `json:"zip"` AddressType string `json:"addressType"` HouseNumber string `json:"houseNumber"` PostalCode string `json:"postalCode"` PlusFour string `json:"plusFour"` Commercial bool `json:"commercial"` Predirection string `json:"predirection"` District string `json:"district"` Street string `json:"street"` Latitude *float64 `json:"latitude"` Longitude *float64 `json:"longitude"` TimeZone string `json:"timeZone"` UtcOffset *float64 `json:"utcOffset"` }
type LocationEventHandler ¶
type LocationEventHandler struct {
// contains filtered or unexported fields
}
func NewLocationEventHandler ¶
func NewLocationEventHandler(services *service.Services, log logger.Logger, cfg *config.Config, grpcClients *grpc_client.Clients) *LocationEventHandler
func (*LocationEventHandler) ExtractAndEnrichLocation ¶
func (*LocationEventHandler) OnLocationCreate ¶
func (h *LocationEventHandler) OnLocationCreate(ctx context.Context, evt eventstore.Event) error
type LocationValidateRequest ¶
type LocationValidationResponseV1 ¶
type LocationValidationResponseV1 struct { Address *ValidatedAddress `json:"address"` Valid bool `json:"valid"` Error *string `json:"error"` }
type LocationValidationSubscriber ¶
type LocationValidationSubscriber struct {
// contains filtered or unexported fields
}
func (*LocationValidationSubscriber) Connect ¶
func (s *LocationValidationSubscriber) Connect(ctx context.Context, worker subscriptions.Worker) error
func (*LocationValidationSubscriber) ProcessEvents ¶
func (s *LocationValidationSubscriber) ProcessEvents(ctx context.Context, sub *esdb.PersistentSubscription, workerID int) error
func (*LocationValidationSubscriber) When ¶
func (s *LocationValidationSubscriber) When(ctx context.Context, evt eventstore.Event) error
type ValidatedAddress ¶
type ValidatedAddress struct { Country string `json:"country"` Region string `json:"region"` District string `json:"district"` Locality string `json:"locality"` Street string `json:"street"` Zip string `json:"zip"` PostalCode string `json:"postalCode"` AddressLine1 string `json:"addressLine1"` AddressLine2 string `json:"addressLine2"` AddressType string `json:"addressType"` HouseNumber string `json:"houseNumber"` PlusFour string `json:"plusFour"` Commercial bool `json:"commercial"` Predirection string `json:"predirection"` Latitude *float64 `json:"latitude"` Longitude *float64 `json:"longitude"` TimeZone string `json:"timeZone"` UtcOffset int `json:"utcOffset"` }
Click to show internal directories.
Click to hide internal directories.