Versions in this module Expand all Collapse all v0 v0.9.0 Dec 1, 2024 Changes in this version + const BaseURL + var DefaultDatasource = &Datasource + func Changeset(ctx context.Context, id osm.ChangesetID) (*osm.Changeset, error) + func ChangesetDownload(ctx context.Context, id osm.ChangesetID) (*osm.Change, error) + func ChangesetWithDiscussion(ctx context.Context, id osm.ChangesetID) (*osm.Changeset, error) + func Map(ctx context.Context, bounds *osm.Bounds, opts ...FeatureOption) (*osm.OSM, error) + func Node(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (*osm.Node, error) + func NodeHistory(ctx context.Context, id osm.NodeID) (osm.Nodes, error) + func NodeRelations(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (osm.Relations, error) + func NodeVersion(ctx context.Context, id osm.NodeID, v int) (*osm.Node, error) + func NodeWays(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (osm.Ways, error) + func Nodes(ctx context.Context, ids []osm.NodeID, opts ...FeatureOption) (osm.Nodes, error) + func Note(ctx context.Context, id osm.NoteID) (*osm.Note, error) + func Notes(ctx context.Context, bounds *osm.Bounds, opts ...NotesOption) (osm.Notes, error) + func NotesSearch(ctx context.Context, query string, opts ...NotesOption) (osm.Notes, error) + func Relation(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (*osm.Relation, error) + func RelationFull(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (*osm.OSM, error) + func RelationHistory(ctx context.Context, id osm.RelationID) (osm.Relations, error) + func RelationRelations(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (osm.Relations, error) + func RelationVersion(ctx context.Context, id osm.RelationID, v int) (*osm.Relation, error) + func Relations(ctx context.Context, ids []osm.RelationID, opts ...FeatureOption) (osm.Relations, error) + func User(ctx context.Context, id osm.UserID) (*osm.User, error) + func Way(ctx context.Context, id osm.WayID, opts ...FeatureOption) (*osm.Way, error) + func WayFull(ctx context.Context, id osm.WayID, opts ...FeatureOption) (*osm.OSM, error) + func WayHistory(ctx context.Context, id osm.WayID) (osm.Ways, error) + func WayRelations(ctx context.Context, id osm.WayID, opts ...FeatureOption) (osm.Relations, error) + func WayVersion(ctx context.Context, id osm.WayID, v int) (*osm.Way, error) + func Ways(ctx context.Context, ids []osm.WayID, opts ...FeatureOption) (osm.Ways, error) + type Datasource struct + BaseURL string + Client *http.Client + Limiter RateLimiter + func NewDatasource(client *http.Client) *Datasource + func (ds *Datasource) Changeset(ctx context.Context, id osm.ChangesetID) (*osm.Changeset, error) + func (ds *Datasource) ChangesetDownload(ctx context.Context, id osm.ChangesetID) (*osm.Change, error) + func (ds *Datasource) ChangesetWithDiscussion(ctx context.Context, id osm.ChangesetID) (*osm.Changeset, error) + func (ds *Datasource) Map(ctx context.Context, bounds *osm.Bounds, opts ...FeatureOption) (*osm.OSM, error) + func (ds *Datasource) Node(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (*osm.Node, error) + func (ds *Datasource) NodeHistory(ctx context.Context, id osm.NodeID) (osm.Nodes, error) + func (ds *Datasource) NodeRelations(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (osm.Relations, error) + func (ds *Datasource) NodeVersion(ctx context.Context, id osm.NodeID, v int) (*osm.Node, error) + func (ds *Datasource) NodeWays(ctx context.Context, id osm.NodeID, opts ...FeatureOption) (osm.Ways, error) + func (ds *Datasource) Nodes(ctx context.Context, ids []osm.NodeID, opts ...FeatureOption) (osm.Nodes, error) + func (ds *Datasource) NotFound(err error) bool + func (ds *Datasource) Note(ctx context.Context, id osm.NoteID) (*osm.Note, error) + func (ds *Datasource) Notes(ctx context.Context, bounds *osm.Bounds, opts ...NotesOption) (osm.Notes, error) + func (ds *Datasource) NotesSearch(ctx context.Context, query string, opts ...NotesOption) (osm.Notes, error) + func (ds *Datasource) Relation(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (*osm.Relation, error) + func (ds *Datasource) RelationFull(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (*osm.OSM, error) + func (ds *Datasource) RelationHistory(ctx context.Context, id osm.RelationID) (osm.Relations, error) + func (ds *Datasource) RelationRelations(ctx context.Context, id osm.RelationID, opts ...FeatureOption) (osm.Relations, error) + func (ds *Datasource) RelationVersion(ctx context.Context, id osm.RelationID, v int) (*osm.Relation, error) + func (ds *Datasource) Relations(ctx context.Context, ids []osm.RelationID, opts ...FeatureOption) (osm.Relations, error) + func (ds *Datasource) User(ctx context.Context, id osm.UserID) (*osm.User, error) + func (ds *Datasource) Way(ctx context.Context, id osm.WayID, opts ...FeatureOption) (*osm.Way, error) + func (ds *Datasource) WayFull(ctx context.Context, id osm.WayID, opts ...FeatureOption) (*osm.OSM, error) + func (ds *Datasource) WayHistory(ctx context.Context, id osm.WayID) (osm.Ways, error) + func (ds *Datasource) WayRelations(ctx context.Context, id osm.WayID, opts ...FeatureOption) (osm.Relations, error) + func (ds *Datasource) WayVersion(ctx context.Context, id osm.WayID, v int) (*osm.Way, error) + func (ds *Datasource) Ways(ctx context.Context, ids []osm.WayID, opts ...FeatureOption) (osm.Ways, error) + type FeatureOption interface + func At(t time.Time) FeatureOption + type ForbiddenError struct + URL string + func (e *ForbiddenError) Error() string + type GoneError struct + URL string + func (e *GoneError) Error() string + type NotFoundError struct + URL string + func (e *NotFoundError) Error() string + type NotesOption interface + func Limit(num int) NotesOption + func MaxDaysClosed(num int) NotesOption + type RateLimiter interface + Wait func(context.Context) error + type RequestURITooLongError struct + URL string + func (e *RequestURITooLongError) Error() string + type UnexpectedStatusCodeError struct + Code int + URL string + func (e *UnexpectedStatusCodeError) Error() string