osmpbfdb

package module
v0.0.0-...-3920edc Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2024 License: Apache-2.0 Imports: 18 Imported by: 0

Documentation

Overview

Package syncpool provides a generic wrapper around sync.Pool

Index

Constants

This section is empty.

Variables

View Source
var ErrNotFound = errors.New("object not found")

Functions

This section is empty.

Types

type DB

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

A Decoder reads and decodes OpenStreetMap PBF data from an input stream.

func OpenDB

func OpenDB(ctx context.Context, r io.ReaderAt) (*DB, error)

newDecoder returns a new decoder that reads from r.

func (*DB) Close

func (dec *DB) Close() error

func (*DB) GetNode

func (db *DB) GetNode(id osm.NodeID) (*osm.Node, error)

func (*DB) GetRelation

func (db *DB) GetRelation(id osm.RelationID) (*osm.Relation, error)

func (*DB) GetWay

func (db *DB) GetWay(id osm.WayID) (*osm.Way, error)
type Header struct {
	Bounds               *osm.Bounds
	RequiredFeatures     []string
	OptionalFeatures     []string
	WritingProgram       string
	Source               string
	ReplicationTimestamp time.Time
	ReplicationSeqNum    uint64
	ReplicationBaseURL   string
}

Header contains the contents of the header in the pbf file.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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