-- Hoogle documentation, generated by Haddock -- See Hoogle, http://www.haskell.org/hoogle/ -- | Parse OpenStreetMap files -- -- Parse OpenStreetMap http://osm.org/ files using HXT into data -- structures. The Data.Geo.OSM module is the core module that exports -- all others. @package OSM @version 0.5.1 module Data.Geo.OSM.Accessor.Accessor using :: (a -> d) -> (c -> a -> b) -> (d -> c) -> a -> b module Data.Geo.OSM.Accessor.Public class Public a public :: Public a => a -> Bool setPublic :: Public a => Bool -> a -> a usingPublic :: Public a => (Bool -> Bool) -> a -> a -- | Values with a zoom string accessor. module Data.Geo.OSM.Accessor.Zoom class Zoom a zoom :: Zoom a => a -> String setZoom :: Zoom a => String -> a -> a usingZoom :: Zoom a => (String -> String) -> a -> a -- | Values with a visible boolean accessor. module Data.Geo.OSM.Accessor.Visible class Visible a visible :: Visible a => a -> Bool setVisible :: Visible a => Bool -> a -> a makeVisible :: Visible a => a -> a makeInvisible :: Visible a => a -> a usingVisible :: Visible a => (Bool -> Bool) -> a -> a -- | Values with a v string accessor. module Data.Geo.OSM.Accessor.V class V a v :: V a => a -> String setV :: V a => String -> a -> a usingV :: V a => (String -> String) -> a -> a -- | Values with a version string accessor. module Data.Geo.OSM.Accessor.Version class Version a b | a -> b version :: Version a b => a -> b setVersion :: Version a b => b -> a -> a usingVersion :: Version a b => (b -> b) -> a -> a -- | Values with a user optional string accessor. module Data.Geo.OSM.Accessor.User class User a b | a -> b user :: User a b => a -> b setUser :: User a b => b -> a -> a usingUser :: User a b => (b -> b) -> a -> a -- | Values with a uid optional string accessor. module Data.Geo.OSM.Accessor.Uid class Uid a uid :: Uid a => a -> Maybe String setUid :: Uid a => Maybe String -> a -> a setUid' :: Uid a => String -> a -> a usingUid :: Uid a => (Maybe String -> Maybe String) -> a -> a usingUid' :: Uid a => (String -> String) -> a -> a -- | Values with a timestamp optional string accessor. module Data.Geo.OSM.Accessor.Timestamp class Timestamp a b | a -> b timestamp :: Timestamp a b => a -> b setTimestamp :: Timestamp a b => b -> a -> a usingTimestamp :: Timestamp a b => (b -> b) -> a -> a -- | Values with a role string accessor. module Data.Geo.OSM.Accessor.Role class Role a role :: Role a => a -> String setRole :: Role a => String -> a -> a usingRole :: Role a => (String -> String) -> a -> a -- | Values with a ref string accessor. module Data.Geo.OSM.Accessor.Ref class Ref a ref :: Ref a => a -> String setRef :: Ref a => String -> a -> a usingRef :: Ref a => (String -> String) -> a -> a -- | Values with a per_page string accessor. module Data.Geo.OSM.Accessor.PerPage class PerPage a perPage :: PerPage a => a -> String setPerPage :: PerPage a => String -> a -> a usingPerPage :: PerPage a => (String -> String) -> a -> a module Data.Geo.OSM.Accessor.Pending class Pending a pending :: Pending a => a -> Bool setPending :: Pending a => Bool -> a -> a usingPending :: Pending a => (Bool -> Bool) -> a -> a -- | Values with a origin optional string accessor. module Data.Geo.OSM.Accessor.Origin class Origin a origin :: Origin a => a -> Maybe String setOrigin :: Origin a => Maybe String -> a -> a setOrigin' :: Origin a => String -> a -> a usingOrigin :: Origin a => (Maybe String -> Maybe String) -> a -> a usingOrigin' :: Origin a => (String -> String) -> a -> a module Data.Geo.OSM.Accessor.Name class Name a name :: Name a => a -> String setName :: Name a => String -> a -> a usingName :: Name a => (String -> String) -> a -> a -- | Values with a minlon string accessor. module Data.Geo.OSM.Accessor.Minlon class Minlon a minlon :: Minlon a => a -> String setMinlon :: Minlon a => String -> a -> a usingMinlon :: Minlon a => (String -> String) -> a -> a -- | Values with a minlat string accessor. module Data.Geo.OSM.Accessor.Minlat class Minlat a minlat :: Minlat a => a -> String setMinlat :: Minlat a => String -> a -> a usingMinlat :: Minlat a => (String -> String) -> a -> a -- | Values with a minimum string accessor. module Data.Geo.OSM.Accessor.Minimum class Minimum a minimum :: Minimum a => a -> String setMinimum :: Minimum a => String -> a -> a usingMinimum :: Minimum a => (String -> String) -> a -> a module Data.Geo.OSM.Accessor.Maxlon class Maxlon a maxlon :: Maxlon a => a -> String setMaxlon :: Maxlon a => String -> a -> a usingMaxlon :: Maxlon a => (String -> String) -> a -> a -- | Values with a maxlat string accessor. module Data.Geo.OSM.Accessor.Maxlat class Maxlat a maxlat :: Maxlat a => a -> String setMaxlat :: Maxlat a => String -> a -> a usingMaxlat :: Maxlat a => (String -> String) -> a -> a -- | Values with a maximum string accessor. module Data.Geo.OSM.Accessor.Maximum class Maximum a maximum :: Maximum a => a -> String setMaximum :: Maximum a => String -> a -> a usingMaximum :: Maximum a => (String -> String) -> a -> a -- | Values with a lon string accessor. module Data.Geo.OSM.Accessor.Lon class Lon a lon :: Lon a => a -> String setLon :: Lon a => String -> a -> a usingLon :: Lon a => (String -> String) -> a -> a -- | Values with a lat string accessor. module Data.Geo.OSM.Accessor.Lat class Lat a lat :: Lat a => a -> String setLat :: Lat a => String -> a -> a usingLat :: Lat a => (String -> String) -> a -> a -- | Values with a k string accessor. module Data.Geo.OSM.Accessor.K class K a k :: K a => a -> String setK :: K a => String -> a -> a usingK :: K a => (String -> String) -> a -> a -- | Values with a id string accessor. module Data.Geo.OSM.Accessor.Id class Id a id' :: Id a => a -> String setId :: Id a => String -> a -> a updateId :: Id a => (String -> String) -> a -> a -- | Values with a generator optional string accessor. module Data.Geo.OSM.Accessor.Generator class Generator a generator :: Generator a => a -> Maybe String setGenerator :: Generator a => Maybe String -> a -> a setGenerator' :: Generator a => String -> a -> a usingGenerator :: Generator a => (Maybe String -> Maybe String) -> a -> a usingGenerator' :: Generator a => (String -> String) -> a -> a -- | Values with a display_name string accessor. module Data.Geo.OSM.Accessor.DisplayName class DisplayName a displayName :: DisplayName a => a -> String setDisplayName :: DisplayName a => String -> a -> a usingDisplayName :: DisplayName a => (String -> String) -> a -> a -- | Values with a changeset optional string accessor. module Data.Geo.OSM.Accessor.Changeset class Changeset a changeset :: Changeset a => a -> Maybe String setChangeset :: Changeset a => Maybe String -> a -> a setChangeset' :: Changeset a => String -> a -> a usingChangeset :: Changeset a => (Maybe String -> Maybe String) -> a -> a usingChangeset' :: Changeset a => (String -> String) -> a -> a -- | Values with a box string accessor. module Data.Geo.OSM.Accessor.Box class Box a box :: Box a => a -> String setBox :: Box a => String -> a -> a usingBox :: Box a => (String -> String) -> a -> a -- | Values with a account_created string accessor. module Data.Geo.OSM.Accessor.AccountCreated class AccountCreated a accountCreated :: AccountCreated a => a -> String setAccountCreated :: AccountCreated a => String -> a -> a usingAccountCreated :: AccountCreated a => (String -> String) -> a -> a -- | The waynodes element of a OSM file. module Data.Geo.OSM.Waynodes -- | The waynodes element of a OSM file. data Waynodes -- | Constructs a waynodes with maximum. waynodes :: String -> Waynodes instance Eq Waynodes instance Maximum Waynodes instance Show Waynodes instance XmlPickler Waynodes -- | Values with a waynodes string accessor. module Data.Geo.OSM.Accessor.Wnodes class Wnodes a wnodes :: Wnodes a => a -> Waynodes setWnodes :: Wnodes a => Waynodes -> a -> a usingWnodes :: Wnodes a => (Waynodes -> Waynodes) -> a -> a -- | The version element of a OSM file. module Data.Geo.OSM.VersionE -- | The version element of a OSM file. data VersionE -- | Constructs a version with minimum and maximum. versionE :: String -> String -> VersionE instance Eq VersionE instance Maximum VersionE instance Minimum VersionE instance Show VersionE instance XmlPickler VersionE -- | The tracepoints element of a OSM file. module Data.Geo.OSM.Tracepoints -- | The tracepoints element of a OSM file. data Tracepoints -- | Constructs a tracepoints with per_page. tracepoints :: String -> Tracepoints instance Eq Tracepoints instance PerPage Tracepoints instance Show Tracepoints instance XmlPickler Tracepoints -- | Values with a tracepoints string accessor. module Data.Geo.OSM.Accessor.Tpoints class Tpoints a tpoints :: Tpoints a => a -> Tracepoints setTpoints :: Tpoints a => Tracepoints -> a -> a usingTpoints :: Tpoints a => (Tracepoints -> Tracepoints) -> a -> a -- | The tag element of a OSM file. module Data.Geo.OSM.Tag -- | The tag element of a OSM file. data Tag -- | Constructs a tag with a key and value. tag :: String -> String -> Tag instance Eq Tag instance V Tag instance K Tag instance Show Tag instance XmlPickler Tag -- | Values with a tags accessor that is a list of tags. module Data.Geo.OSM.Accessor.Tags class Tags a tags :: Tags a => a -> [Tag] setTags :: Tags a => [Tag] -> a -> a setTag :: Tags a => Tag -> a -> a usingTags :: Tags a => ([Tag] -> [Tag]) -> a -> a usingTag :: Tags a => (Tag -> Tag) -> a -> a usingTag' :: Tags a => ((String, String) -> (String, String)) -> a -> a tagMap :: Tags a => a -> Map String String tagValue :: Tags a => a -> String -> Maybe String hasTagValue :: Tags a => String -> String -> a -> Bool -- | The common attributes between the node, way and -- relation elements. module Data.Geo.OSM.NWRCommon -- | The common attributes between the node, way and -- relation elements. data NWRCommon -- | Constructs with id, list of tags, changeset, visible, user&uid and -- timestamp. nwrCommon :: String -> [Tag] -> Maybe String -> Bool -> (Maybe String, Maybe String) -> Maybe String -> NWRCommon instance Eq NWRCommon instance Timestamp NWRCommon (Maybe String) instance Uid NWRCommon instance User NWRCommon (Maybe String) instance Visible NWRCommon instance Changeset NWRCommon instance Tags NWRCommon instance Id NWRCommon instance Show NWRCommon instance XmlPickler NWRCommon -- | The preferences element of a OSM file. module Data.Geo.OSM.Preferences -- | The preferences element of a OSM file. data Preferences -- | Constructs a preferences with tags. preferences :: [Tag] -> Preferences instance Eq Preferences instance Tags Preferences instance Show Preferences instance XmlPickler Preferences -- | The node element of a OSM file. module Data.Geo.OSM.Node -- | The node element of a OSM file. data Node -- | Constructs a node with a lat, lon, id, list of tags, changeset, -- visible, user&uid and timestamp. node :: String -> String -> String -> [Tag] -> Maybe String -> Bool -> (Maybe String, Maybe String) -> Maybe String -> Node instance Eq Node instance Timestamp Node (Maybe String) instance Uid Node instance User Node (Maybe String) instance Visible Node instance Changeset Node instance Tags Node instance Id Node instance Lon Node instance Lat Node instance Show Node instance XmlPickler Node -- | The nd element of a OSM file. module Data.Geo.OSM.Nd -- | The nd element of a OSM file. data Nd -- | Constructs a nd with a ref. nd :: String -> Nd instance Eq Nd instance Ref Nd instance Show Nd instance XmlPickler Nd -- | Values with a nd accessor that is a list of Nd. module Data.Geo.OSM.Accessor.Nds class Nds a nds :: Nds a => a -> [Nd] setNds :: Nds a => [Nd] -> a -> a setNd :: Nds a => Nd -> a -> a usingNds :: Nds a => ([Nd] -> [Nd]) -> a -> a usingNd :: Nds a => (Nd -> Nd) -> a -> a -- | The way element of a OSM file. module Data.Geo.OSM.Way -- | The way element of a OSM file. data Way -- | Constructs a way with a list of nds, id, list of tags, changeset, -- visible, user&uid and timestamp. way :: [Nd] -> String -> [Tag] -> Maybe String -> Bool -> (Maybe String, Maybe String) -> Maybe String -> Way instance Eq Way instance Timestamp Way (Maybe String) instance Uid Way instance User Way (Maybe String) instance Visible Way instance Changeset Way instance Tags Way instance Id Way instance Nds Way instance Show Way instance XmlPickler Way -- | The type attribute of a member element of a OSM -- file. module Data.Geo.OSM.MemberType -- | The type attribute of a member element of a OSM -- file. data MemberType -- | Folds a member-type (catamorphism). foldMemberType :: MemberType -> x -> x -> x -> x -- | Constructs a member-type that is a way. wayType :: MemberType -- | Constructs a member-type that is a node. nodeType :: MemberType -- | Constructs a member-type that is a relation. relationType :: MemberType instance Eq MemberType instance Show MemberType instance XmlPickler MemberType -- | Values with a type accessor. module Data.Geo.OSM.Accessor.Mtype class Mtype a mtype :: Mtype a => a -> MemberType setMtype :: Mtype a => MemberType -> a -> a usingMtype :: Mtype a => (MemberType -> MemberType) -> a -> a -- | The member element of a OSM file. module Data.Geo.OSM.Member -- | The member element of a OSM file. data Member -- | Constructs a member with a type, ref and role. member :: MemberType -> String -> String -> Member instance Eq Member instance Role Member instance Ref Member instance Mtype Member instance Show Member instance XmlPickler Member -- | Values with a member accessor that is a list of -- Member. module Data.Geo.OSM.Accessor.Members class Members a members :: Members a => a -> [Member] setMembers :: Members a => [Member] -> a -> a setMember :: Members a => Member -> a -> a usingMembers :: Members a => ([Member] -> [Member]) -> a -> a usingMember :: Members a => (Member -> Member) -> a -> a -- | The relation element of a OSM file. module Data.Geo.OSM.Relation -- | The relation element of a OSM file. data Relation -- | Constructs a relation with a list of members, id, list of tags, -- changeset, visible, user&uid and timestamp. relation :: [Member] -> String -> [Tag] -> Maybe String -> Bool -> (Maybe String, Maybe String) -> Maybe String -> Relation instance Eq Relation instance Timestamp Relation (Maybe String) instance Uid Relation instance User Relation (Maybe String) instance Visible Relation instance Changeset Relation instance Tags Relation instance Id Relation instance Members Relation instance Show Relation instance XmlPickler Relation -- | The node, way, or relation element of a OSM -- file. module Data.Geo.OSM.NodeWayRelation -- | The node, way, or relation element of a OSM -- file. data NodeWayRelation -- | Folds a node-way-relation (catamorphism). foldNodeWayRelation :: NodeWayRelation -> (Node -> x) -> (Way -> x) -> (Relation -> x) -> x -- | Construct a way element value. way' :: Way -> NodeWayRelation -- | Construct a relation element value. relation' :: Relation -> NodeWayRelation -- | Construct a node element value. node' :: Node -> NodeWayRelation -- | Returns whether the node, way or relation -- element is a node. isNode :: NodeWayRelation -> Bool -- | Returns whether the node, way or relation -- element is a way. isWay :: NodeWayRelation -> Bool -- | Returns whether the node, way or relation -- element is a relation. isRelation :: NodeWayRelation -> Bool instance Eq NodeWayRelation instance Show NodeWayRelation instance XmlPickler NodeWayRelation -- | Values with a nwrs accessor that is a list of -- NodeWayRelation. module Data.Geo.OSM.Accessor.NodeWayRelations class NodeWayRelations a nwrs :: NodeWayRelations a => a -> [NodeWayRelation] setNwrs :: NodeWayRelations a => [NodeWayRelation] -> a -> a setNwr :: NodeWayRelations a => NodeWayRelation -> a -> a usingNwrs :: NodeWayRelations a => ([NodeWayRelation] -> [NodeWayRelation]) -> a -> a usingNwr :: NodeWayRelations a => (NodeWayRelation -> NodeWayRelation) -> a -> a usingNode :: NodeWayRelations a => (Node -> Node) -> a -> a usingWay :: NodeWayRelations a => (Way -> Way) -> a -> a usingRelation :: NodeWayRelations a => (Relation -> Relation) -> a -> a nodes :: NodeWayRelations a => a -> [Node] ways :: NodeWayRelations a => a -> [Way] relations :: NodeWayRelations a => a -> [Relation] -- | The home element of a OSM file. module Data.Geo.OSM.Home -- | The home element of a OSM file. data Home -- | Constructs a home with lat, lon and zoom. home :: String -> String -> String -> Home instance Eq Home instance Zoom Home instance Lon Home instance Lat Home instance Show Home instance XmlPickler Home -- | Values with a home optional string accessor. module Data.Geo.OSM.Accessor.Hm class Hm a hm :: Hm a => a -> Maybe Home setHm :: Hm a => Maybe Home -> a -> a setHm' :: Hm a => Home -> a -> a usingHm :: Hm a => (Maybe Home -> Maybe Home) -> a -> a usingHm' :: Hm a => (Home -> Home) -> a -> a -- | The user element of a OSM file. module Data.Geo.OSM.UserE -- | The user element of a OSM file. data UserE -- | Constructs a user with an optional home, display_name and -- account_created. userE :: Maybe Home -> String -> String -> UserE instance Eq UserE instance AccountCreated UserE instance DisplayName UserE instance Hm UserE instance Show UserE instance XmlPickler UserE -- | The gpx_file element of a OSM file. module Data.Geo.OSM.GpxFile -- | The gpx_file element of a OSM file. data GpxFile -- | Constructs a gpx_file with an id, name, lat, lon, user, -- public, pending and timestamp. gpxFile :: String -> String -> String -> String -> String -> Bool -> Bool -> String -> GpxFile instance Eq GpxFile instance Timestamp GpxFile String instance Pending GpxFile instance Public GpxFile instance User GpxFile String instance Lon GpxFile instance Lat GpxFile instance Name GpxFile instance Id GpxFile instance Show GpxFile instance XmlPickler GpxFile -- | The changeset element of a OSM file. module Data.Geo.OSM.ChangesetE -- | The changeset element of a OSM file. data ChangesetE -- | Constructs a changeset with tags. changesetE :: [Tag] -> ChangesetE instance Eq ChangesetE instance Tags ChangesetE instance Show ChangesetE instance XmlPickler ChangesetE -- | The bounds element of a OSM file. module Data.Geo.OSM.Bounds -- | The bounds element of a OSM file. data Bounds -- | Constructs a bounds with a minlat, minlon, maxlat, maxlon and origin -- attributes. bounds :: String -> String -> String -> String -> Maybe String -> Bounds instance Eq Bounds instance Origin Bounds instance Maxlon Bounds instance Maxlat Bounds instance Minlon Bounds instance Minlat Bounds instance Show Bounds instance XmlPickler Bounds -- | The bound element of a OSM file. module Data.Geo.OSM.Bound -- | The bound element of a OSM file. data Bound -- | Constructs a bound with a box and origin attributes. bound :: String -> Maybe String -> Bound instance Eq Bound instance Origin Bound instance Box Bound instance Show Bound instance XmlPickler Bound -- | Values with a bounds accessor which is either empty, a -- Bound or a Bounds. module Data.Geo.OSM.Accessor.BoundOrs class BoundOrs a boundOrs :: BoundOrs a => a -> x -> (Bound -> x) -> (Bounds -> x) -> x setBoundOrs :: BoundOrs a => Maybe (Either Bound Bounds) -> a -> a setBound :: BoundOrs a => Bound -> a -> a setBounds :: BoundOrs a => Bounds -> a -> a usingBoundOrs :: BoundOrs a => a -> (Maybe (Either Bound Bounds) -> Maybe (Either Bound Bounds)) -> a -- | The area element of a OSM file. module Data.Geo.OSM.Area -- | The area element of a OSM file. data Area -- | Constructs a area with maximum. area :: String -> Area instance Eq Area instance Maximum Area instance Show Area instance XmlPickler Area -- | Values with a area string accessor. module Data.Geo.OSM.Accessor.Ar class Ar a ar :: Ar a => a -> Area setAr :: Ar a => Area -> a -> a usingArea :: Ar a => (Area -> Area) -> a -> a -- | The api element of a OSM file. module Data.Geo.OSM.Api -- | The api element of a OSM file. data Api -- | Constructs a api with version, area, tracepoints and -- waynodes. api :: VersionE -> Area -> Tracepoints -> Waynodes -> Api instance Eq Api instance Wnodes Api instance Tpoints Api instance Ar Api instance Version Api VersionE instance Show Api instance XmlPickler Api -- | The children elements of the osm element of a OSM file. module Data.Geo.OSM.OSMChildren -- | The children elements of the osm element of a OSM file. data OSMChildren -- | A user element. osmUser :: UserE -> OSMChildren -- | A gpx_file element. osmGpxFile :: GpxFile -> OSMChildren -- | A api element. osmApi :: Api -> OSMChildren -- | A changeset element. osmChangeset :: ChangesetE -> OSMChildren -- | A list of node, way or relation elements. osmNodeWayRelation :: [NodeWayRelation] -> OSMChildren -- | Folds OSM child elements (catamorphism). foldOSMChildren :: (UserE -> a) -> (Preferences -> a) -> (GpxFile -> a) -> (Api -> a) -> (ChangesetE -> a) -> ([NodeWayRelation] -> a) -> OSMChildren -> a instance Eq OSMChildren instance Show OSMChildren instance XmlPickler OSMChildren -- | The osm element of a OSM file, which is the root element. -- http://wiki.openstreetmap.org/wiki/API_v0.6/DTD module Data.Geo.OSM.OSM -- | The osm element of a OSM file, which is the root element. data OSM -- | Constructs a osm with a version, bound or bounds, and node attributes -- and way or relation elements. osm :: String -> Maybe String -> Maybe (Either Bound Bounds) -> OSMChildren -> OSM -- | Reads an OSM file into a list of OSM values removing -- whitespace. readOsmFile :: FilePath -> IO [OSM] -- | Reads 0 or more OSM files into a list of OSM values removing -- whitespace. readOsmFiles :: [FilePath] -> IO [OSM] -- | Reads a OSM file removing whitespace, executes the given function on -- the XML, then writes the given file with indentation. interactOSMIO :: (OSM -> IO OSM) -> FilePath -> FilePath -> IO () -- | Reads a OSM file removing whitespace, executes the given functions on -- the XML, then writes the given file with indentation. interactsOSMIO :: Foldable t => t (OSM -> IO OSM) -> FilePath -> FilePath -> IO () -- | Reads a OSM file, executes the given function on the XML, then writes -- the given file. interactOSMIO' :: (OSM -> IO OSM) -> SysConfigList -> FilePath -> SysConfigList -> FilePath -> IO () -- | Reads a OSM file, executes the given functions on the XML, then writes -- the given file. interactsOSMIO' :: Foldable t => t (OSM -> IO OSM) -> SysConfigList -> FilePath -> SysConfigList -> FilePath -> IO () -- | Reads a OSM file removing whitespace, executes the given function on -- the XML, then writes the given file with indentation. interactOSM :: (OSM -> OSM) -> FilePath -> FilePath -> IO () -- | Reads a OSM file removing whitespace, executes the given functions on -- the XML, then writes the given file with indentation. interactsOSM :: Foldable t => t (OSM -> OSM) -> FilePath -> FilePath -> IO () -- | Reads a OSM file, executes the given function on the XML, then writes -- the given file. interactOSM' :: (OSM -> OSM) -> SysConfigList -> FilePath -> SysConfigList -> FilePath -> IO () -- | Reads a OSM file, executes the given functions on the XML, then writes -- the given file. interactsOSM' :: Foldable t => t (OSM -> OSM) -> SysConfigList -> FilePath -> SysConfigList -> FilePath -> IO () instance Eq OSM instance NodeWayRelations OSM instance BoundOrs OSM instance Generator OSM instance Version OSM String instance Show OSM instance XmlPickler OSM -- | OpenStreetMap API v0.6 DTD -- http://wiki.openstreetmap.org/wiki/API_v0.6/DTD module Data.Geo.OSM