Safe Haskell | None |
---|---|
Language | Haskell2010 |
Defines the top-level HTML types and parser functions.
Synopsis
- data HTMLOptions = HTMLOptions {}
- data HTMLResult = HTMLResult {}
- data HTMLError = HTMLError {
- htmlErrorText :: !Text
- data HTMLNode
- = HTMLDocument {
- htmlDocumentName :: !Text
- htmlDocumentChildren :: ![HTMLNode]
- | HTMLDoctype {
- htmlDoctypeName :: !Text
- htmlDoctypePublicID :: !(Maybe Text)
- htmlDoctypeSystemID :: !(Maybe Text)
- | HTMLFragment {
- htmlFragmentName :: !Text
- htmlFragmentChildren :: ![HTMLNode]
- | HTMLElement { }
- | HTMLTemplate { }
- | HTMLText {
- htmlTextData :: !Text
- | HTMLComment {
- htmlCommentData :: !Text
- = HTMLDocument {
- data HTMLAttr = HTMLAttr {}
- data HTMLNamespace
- data HTMLAttrNamespace
- htmlParse :: HTMLOptions -> Text -> Either HTMLError HTMLResult
- htmlParseEasy :: Text -> HTMLNode
- htmlFragment :: HTMLOptions -> Text -> Either HTMLError HTMLResult
- htmlDefaultDocument :: HTMLNode
- htmlDefaultDoctype :: HTMLNode
- htmlDefaultFragment :: HTMLNode
- htmlDefaultElement :: HTMLNode
- htmlDefaultTemplate :: HTMLNode
- htmlDefaultText :: HTMLNode
- htmlDefaultComment :: HTMLNode
- htmlAttr :: Text -> Text -> HTMLAttr
- htmlElem :: Text -> [HTMLAttr] -> [HTMLNode] -> HTMLNode
- htmlText :: Text -> HTMLNode
Documentation
data HTMLOptions Source #
Defines options for the HTML parser.
HTMLOptions | |
|
Instances
Eq HTMLOptions Source # | |
Defined in Zenacy.HTML.Internal.HTML (==) :: HTMLOptions -> HTMLOptions -> Bool # (/=) :: HTMLOptions -> HTMLOptions -> Bool # | |
Ord HTMLOptions Source # | |
Defined in Zenacy.HTML.Internal.HTML compare :: HTMLOptions -> HTMLOptions -> Ordering # (<) :: HTMLOptions -> HTMLOptions -> Bool # (<=) :: HTMLOptions -> HTMLOptions -> Bool # (>) :: HTMLOptions -> HTMLOptions -> Bool # (>=) :: HTMLOptions -> HTMLOptions -> Bool # max :: HTMLOptions -> HTMLOptions -> HTMLOptions # min :: HTMLOptions -> HTMLOptions -> HTMLOptions # | |
Show HTMLOptions Source # | |
Defined in Zenacy.HTML.Internal.HTML showsPrec :: Int -> HTMLOptions -> ShowS # show :: HTMLOptions -> String # showList :: [HTMLOptions] -> ShowS # | |
Default HTMLOptions Source # | Defines default options. |
Defined in Zenacy.HTML.Internal.HTML def :: HTMLOptions # |
data HTMLResult Source #
Defines an HTML parser result.
HTMLResult | |
|
Instances
Eq HTMLResult Source # | |
Defined in Zenacy.HTML.Internal.HTML (==) :: HTMLResult -> HTMLResult -> Bool # (/=) :: HTMLResult -> HTMLResult -> Bool # | |
Ord HTMLResult Source # | |
Defined in Zenacy.HTML.Internal.HTML compare :: HTMLResult -> HTMLResult -> Ordering # (<) :: HTMLResult -> HTMLResult -> Bool # (<=) :: HTMLResult -> HTMLResult -> Bool # (>) :: HTMLResult -> HTMLResult -> Bool # (>=) :: HTMLResult -> HTMLResult -> Bool # max :: HTMLResult -> HTMLResult -> HTMLResult # min :: HTMLResult -> HTMLResult -> HTMLResult # | |
Show HTMLResult Source # | |
Defined in Zenacy.HTML.Internal.HTML showsPrec :: Int -> HTMLResult -> ShowS # show :: HTMLResult -> String # showList :: [HTMLResult] -> ShowS # | |
Default HTMLResult Source # | Defines a default result. |
Defined in Zenacy.HTML.Internal.HTML def :: HTMLResult # |
An HTML error type.
HTMLError | |
|
Defines the model type for an HTML document.
HTMLDocument | |
| |
HTMLDoctype | |
| |
HTMLFragment | |
| |
HTMLElement | |
| |
HTMLTemplate | |
| |
HTMLText | |
| |
HTMLComment | |
|
An HTML element attribute type.
data HTMLNamespace Source #
An HTML namespace type.
Instances
Eq HTMLNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types (==) :: HTMLNamespace -> HTMLNamespace -> Bool # (/=) :: HTMLNamespace -> HTMLNamespace -> Bool # | |
Ord HTMLNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types compare :: HTMLNamespace -> HTMLNamespace -> Ordering # (<) :: HTMLNamespace -> HTMLNamespace -> Bool # (<=) :: HTMLNamespace -> HTMLNamespace -> Bool # (>) :: HTMLNamespace -> HTMLNamespace -> Bool # (>=) :: HTMLNamespace -> HTMLNamespace -> Bool # max :: HTMLNamespace -> HTMLNamespace -> HTMLNamespace # min :: HTMLNamespace -> HTMLNamespace -> HTMLNamespace # | |
Show HTMLNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types showsPrec :: Int -> HTMLNamespace -> ShowS # show :: HTMLNamespace -> String # showList :: [HTMLNamespace] -> ShowS # | |
Default HTMLNamespace Source # | Defines a default namespace. |
Defined in Zenacy.HTML.Internal.Types def :: HTMLNamespace # |
data HTMLAttrNamespace Source #
An HTML attribute namespace type.
Instances
Eq HTMLAttrNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types (==) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # (/=) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # | |
Ord HTMLAttrNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types compare :: HTMLAttrNamespace -> HTMLAttrNamespace -> Ordering # (<) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # (<=) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # (>) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # (>=) :: HTMLAttrNamespace -> HTMLAttrNamespace -> Bool # max :: HTMLAttrNamespace -> HTMLAttrNamespace -> HTMLAttrNamespace # min :: HTMLAttrNamespace -> HTMLAttrNamespace -> HTMLAttrNamespace # | |
Show HTMLAttrNamespace Source # | |
Defined in Zenacy.HTML.Internal.Types showsPrec :: Int -> HTMLAttrNamespace -> ShowS # show :: HTMLAttrNamespace -> String # showList :: [HTMLAttrNamespace] -> ShowS # | |
Default HTMLAttrNamespace Source # | Defines a default attribute namespace. |
Defined in Zenacy.HTML.Internal.Types |
htmlParse :: HTMLOptions -> Text -> Either HTMLError HTMLResult Source #
Parses an HTML document.
htmlParseEasy :: Text -> HTMLNode Source #
Parses an HTML document the easy way.
htmlFragment :: HTMLOptions -> Text -> Either HTMLError HTMLResult Source #
Parses an HTML fragment.
htmlDefaultDocument :: HTMLNode Source #
Defines a default document.
htmlDefaultDoctype :: HTMLNode Source #
Defines a default document type.
htmlDefaultFragment :: HTMLNode Source #
Defines a default document fragment.
htmlDefaultElement :: HTMLNode Source #
Defines a default element.
htmlDefaultTemplate :: HTMLNode Source #
Defines a default template.
htmlDefaultText :: HTMLNode Source #
Defines a default text.
htmlDefaultComment :: HTMLNode Source #
Defines a default comment.