Safe Haskell | None |
---|---|
Language | Haskell2010 |
- data Location b t
- type QueryParam = (String, Maybe String)
- class ToPath sym base type' | sym -> base type' where
- class ToLocation sym base type' | sym -> base type' where
- class PathAppend right base type' where
- addParent :: Location Rel t -> Location Rel t
- delParent :: Location Rel t -> Location Rel t
- fromPath :: Path b t -> Location b t
- locPath :: Location b t -> Path b t
- setFileExt :: Maybe String -> Location b File -> Location b File
- addFileExt :: String -> Location b File -> Location b File
- delFileExt :: Location b File -> Location b File
- getFileExt :: Location b File -> Maybe String
- setQuery :: [QueryParam] -> Location b t -> Location b t
- addQuery :: QueryParam -> Location b t -> Location b t
- (<&>) :: Location b t -> QueryParam -> Location b t
- addQueries :: [QueryParam] -> Location b t -> Location b t
- delQuery :: Location b t -> Location b t
- getQuery :: Location b t -> [QueryParam]
- setFragment :: Maybe String -> Location b t -> Location b t
- addFragment :: String -> Location b t -> Location b t
- (<#>) :: Location b t -> String -> Location b t
- delFragment :: Location b t -> Location b t
Types
A location for some base and type - internally uses Path
.
Classes
class ToPath sym base type' | sym -> base type' where Source #
Convenience typeclass for symbolic, stringless routes - make an instance for your own data type to use your constructors as route-referencing symbols.
toPath :: MonadThrow m => sym -> m (Path base type') Source #
class ToLocation sym base type' | sym -> base type' where Source #
Convenience typeclass for symbolic, stringless routes - make an instance for your own data type to use your constructors as route-referencing symbols.
toLocation :: MonadThrow m => sym -> m (Location base type') Source #
Combinators
Append
class PathAppend right base type' where Source #
Parent Accessors
Path
fromPath :: Path b t -> Location b t Source #
This should be your entry point for creating a Location
.
File Extensions
Query Parameters
addQueries :: [QueryParam] -> Location b t -> Location b t Source #
getQuery :: Location b t -> [QueryParam] Source #
Fragment
delFragment :: Location b t -> Location b t Source #