-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/

-- | Quasi-quoters for XML and HTML Documents
--   
--   Please see README.md.
@package xml-html-qq
@version 0.1.0.1

module Text.XMLHTML.Internal

-- | Create a QuasiQuoter for Exps.
createExpQuasiQuoter :: (String -> Q Exp) -> QuasiQuoter

-- | This function handles errors that occur when a Document can't
--   be parsed.
--   
--   This function throws an error with an explanation of what
--   happened.
handleParseDocErr :: String -> String -> String -> SomeException -> a
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.Doctype
instance Language.Haskell.TH.Syntax.Lift Text.XML.Document
instance Language.Haskell.TH.Syntax.Lift Text.XML.Element
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.ExternalID
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.Instruction
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.Miscellaneous
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.Name
instance Language.Haskell.TH.Syntax.Lift Text.XML.Node
instance Language.Haskell.TH.Syntax.Lift Data.XML.Types.Prologue

-- | This module provides a quasi-quoter for XML Documents. See the
--   xml function for some examples.
--   
--   The difference between Text.XML.QQ and Text.HTML.QQ is
--   the function that is used to parse the input String into a
--   Document.
--   
--   xml uses parseText to parse the input String.
--   parseText returns an error on a malformed document. This is
--   generally what you want for XML documents.
--   
--   html uses DOM.parseLT' to parse the input String.
--   parseLT will parse any HTML document, skipping parts of the
--   document that are malformed. This is generally what you want for HTML
--   documents.
module Text.XML.QQ

-- | This QuasiQuoter produces XML Documents.
--   
--   This QuasiQuoter produces expressions of type Either
--   SomeException Document. It produces a
--   Left SomeException when the input string cannot
--   be parsed into an XML Document.
--   
--   Here's a simple example of using it:
--   
--   
--   >>> [xml|<html></html>|] :: Either SomeException Document
--   Right (Document {documentPrologue = Prologue {prologueBefore = [], prologueDoctype = Nothing, prologueAfter = []}, documentRoot = Element {elementName = Name {nameLocalName = "html", nameNamespace = Nothing, namePrefix = Nothing}, elementAttributes = fromList [], elementNodes = []}, documentEpilogue = []})
--   
--   
--   Internally, this function is using the heterocephalus package.
--   This means you can use variable interpolation, as well as
--   forall, if, and case control statements.
--   Checkout the heterocephalus README for more info.
--   
--   
--   >>> let a = "hello world"
--   
--   >>> [xml|<html>#{a}</html>|]
--   Right ...
--   
--   
--   Here's an example of invalue XML that will produce a Left
--   value:
--   
--   
--   >>> [xml|<html </html>|]
--   Left ...
--   
--   
--   Here's an example of a template that can be parsed as an HTML
--   Document, but not as an XML Document:
--   
--   
--   >>> [xml|<html><br></html>|]
--   Left ...
--   
xml :: QuasiQuoter

-- | This function is just like xml, but produces expressions of
--   type Document.
--   
--   If your input string cannot be parsed into a valid Document, an
--   error will be thrown at runtime with error.
--   
--   This function is nice to use in GHCi or tests, but should NOT
--   be used in production code.
--   
--   Here's a simple example of using it:
--   
--   
--   >>> [xmlUnsafe|<html></html>|] :: Document
--   Document ...
--   
xmlUnsafe :: QuasiQuoter

-- | This function is similar to xml, but doesn't allow variable
--   interpolation or control statements. It produces expressions of type
--   Document.
--   
--   An error will be thrown at compile-time if the input string cannot be
--   parsed into a Document.
--   
--   Unlike xmlUnsafe, this function is safe to use in production
--   code.
--   
--   Here's a simple example of using it:
--   
--   
--   >>> [xmlRaw|<html></html>|] :: Document
--   Document ...
--   
xmlRaw :: QuasiQuoter
data Document

-- | The SomeException type is the root of the exception type
--   hierarchy. When an exception of type e is thrown, behind the
--   scenes it is encapsulated in a SomeException.
data SomeException

-- | This module provides a quasi-quoter for HTML Documents. See the
--   html function for some examples.
--   
--   See Text.XML.QQ for an explanation of the difference between
--   Text.HTML.QQ and Text.XML.QQ.
module Text.HTML.QQ

-- | This QuasiQuoter produces HTML Documents.
--   
--   This QuasiQuoter produces expressions of type Document.
--   
--   Here's a simple example of using it:
--   
--   
--   >>> [html|<html></html>|] :: Document
--   Document {documentPrologue = Prologue {prologueBefore = [], prologueDoctype = Nothing, prologueAfter = []}, documentRoot = Element {elementName = Name {nameLocalName = "html", nameNamespace = Nothing, namePrefix = Nothing}, elementAttributes = fromList [], elementNodes = []}, documentEpilogue = []}
--   
--   
--   Internally, this function is using the heterocephalus package.
--   This means you can use variable interpolation, as well as
--   forall, if, and case control statements.
--   Checkout the heterocephalus README for more info.
--   
--   
--   >>> let a = "hello world"
--   
--   >>> [html|<html>#{a}</html>|]
--   Document ...
--   
--   
--   Even invalid HTML will still parse.
--   
--   
--   >>> [html|<html </html>|]
--   Document ...
--   
--   
--   Here's an example of a template that can be parsed as an HTML
--   Document, but not as an XML Document:
--   
--   
--   >>> [html|<html><br></html>|]
--   Document ...
--   
html :: QuasiQuoter

-- | This function is the same as html, but doesn't allow variable
--   interpolation or control statements. It also produces expressions of
--   type Document.
--   
--   Here's a simple example of using it:
--   
--   
--   >>> [htmlRaw|<html></html>|] :: Document
--   Document ...
--   
htmlRaw :: QuasiQuoter
data Document
