zipcode

package
v0.0.0-...-103f8c7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 24, 2023 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handlers

type Handlers struct {
	Service Service
}

Handlers some description

func (*Handlers) AddHandlers

func (h *Handlers) AddHandlers(r *mux.Router)

AddHandlers some description

func (*Handlers) FetchAddressByZipcode

func (h *Handlers) FetchAddressByZipcode(w http.ResponseWriter, r *http.Request)

FetchAddressByZipcode function for returns the address corresponding to the zipcode

type Service

type Service interface {
	FetchAddressByZipcode(zipcode string) (*models.Address, error)
}

Service represents zipcode application interface

func New

func New(session *mongo.Client) Service

New initialize new zipcode service

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL