xml-basic-0.0.1: Basics for XML/HTML representation and processing

Text.HTML.Basic.Tag

Description

We do not define a tag data type here, since this is too much bound to the particular use (e.g. list or tree structure). However we define a tag name and several

Synopsis

Documentation

newtype Name ident Source

Constructors

Name 

Fields

unname :: ident
 

Instances

Eq ident => Eq (Name ident) 
Ord ident => Ord (Name ident) 
Show ident => Show (Name ident) 
Tag ident => C (Name ident) 

doctype :: Tag name => Name nameSource

cdata :: Tag name => Name nameSource

isEmpty :: (Tag name, Ord name) => Name name -> BoolSource

Check whether a HTML tag is empty.

isSloppy :: (Tag name, Ord name) => Name name -> BoolSource

Some tags, namely those for text styles like FONT, B, I, are used quite sloppily. That is, they are not terminated or not terminated in the right order. We close them implicitly, if another tag closes and ignore non-matching closing tags.

isInnerOf :: (Tag name, Ord name) => Name name -> Name name -> BoolSource

closes :: (Tag name, Ord name) => Name name -> Name name -> BoolSource