models

package
v0.0.0-...-f2ef526 Latest Latest
Warning

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

Go to latest
Published: Sep 2, 2014 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DbSingaporeFacts = "singapore-facts"
)

Functions

func Collection

func Collection(session *mgo.Session, name string) *mgo.Collection

Types

type Geo

type Geo struct {
	Type        string     `json:"type" bson:"type"`
	Coordinates [2]float64 `json:"coordinates" bson:"coordinates"`
}

type Poi

type Poi struct {
	Id    bson.ObjectId `json:"id" bson:"_id"`
	Layer string        `json:"layer", bson:"layar"`
	Loc   Geo           `json:"loc", bson:"loc"`
}

func GetPoisByLayer

func GetPoisByLayer(session *mgo.Session, layers []string) (pois []Poi, err error)

Jump to

Keyboard shortcuts

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