@hackage download0.3.2
High-level file download based on URLs
Installation
Dependencies (5)
Dependents (6)
@hackage/usb-id-database, @hackage/black-jewel, @hackage/acme-everything, @hackage/hackage-sparks, @hackage/hackage2hwn, @hackage/implicit
High-level file download based on URLs
Download web content as strict bytestring, strings, HTML tags, XML, RSS or Atom feeds or JSON, via HTTP, FTP or file protocols, using a URL interface.
Importing the library:
import Network.Download
Loading a webpage as a ByteString:
doc <- openURI "http://haskell.org"
Loading from a file:
doc <- openURI "file:///tmp/A.hs"
Loading a HTML page as a list of tags:
tags <- openAsTags "http://haskell.org"
Loading a HTML page as XML:
tags <- openAsXML "http://haskell.org"
Loading an RSS or Atom feed:
feed <- openAsFeed "http://haskell.org"
These data types can the be processed further with the XML, Feed and TagSoup libraries.