persistence

package
v0.0.0-...-253b529 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2021 License: Apache-2.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GeoJsonPoint

type GeoJsonPoint struct {
	// Always "Point"
	Type        string     `bson:"type"`
	Coordinates [2]float64 `bson:"coordinates"`
}

type Store

type Store struct {
	Id           primitive.ObjectID             `bson:"_id"`
	Store        string                         `bson:"store"`
	Country      string                         `bson:"country"`
	ZipCode      string                         `bson:"zip"`
	City         string                         `bson:"city"`
	Street       string                         `bson:"street"`
	Coordinates  GeoJsonPoint                   `bson:"coordinates"`
	ObjectType   string                         `bson:"object_type"`
	OpeningHours openinghours.OpeningHours      `bson:"opening_hours"`
	ExtraHours   openinghours.ExtraOpeningHours `bson:"extra_hours"`
	ImportTime   time.Time                      `bson:"import_time"`
}

type StoreRepository

type StoreRepository struct {
	// contains filtered or unexported fields
}

func NewStoreRepository

func NewStoreRepository(client *mongodb.Client) (*StoreRepository, error)

func (*StoreRepository) IngestStores

func (r *StoreRepository) IngestStores(ctx context.Context, stores []Store) error

Jump to

Keyboard shortcuts

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