hxt-7.3: A collection of tools for processing XML with Haskell.ContentsIndex
Text.XML.HXT.Arrow.Pickle.Schema
Portabilityportable
Stabilityexperimental
MaintainerUwe Schmidt (uwe@fh-wedel.de)
Description

Version : $Id$

Datatypes and functions for building a content model for XML picklers. A schema is part of every pickler and can be used to derive a corrensponding DTD (or Relax NG schema). This schema further enables checking the picklers.

Synopsis
data Schema
= Any
| PCData SchemaRestriction
| CData Kind SchemaRestriction
| Option Schema
| Seq [Schema]
| Alt [Schema]
| Rep Int Int Schema
| Element Name Schema
| Attribute Name Schema
| ElemRef Name
type Name = String
type Kind = String
type Schemas = [Schema]
data SchemaRestriction
= FixedValue String
| DTDAttrType String
| ValEnum [String]
| RegEx String
| XmlSchemaType String
isScElem :: Schema -> Bool
isScElemRef :: Schema -> Bool
isScPCData :: Schema -> Bool
isScCData :: Schema -> Bool
isScSARE :: Schema -> Bool
emptyText :: SchemaRestriction
noneEmptyText :: SchemaRestriction
restrictRegEx :: String -> SchemaRestriction
restrictDTDAttrType :: String -> SchemaRestriction
restrictEnum :: [String] -> SchemaRestriction
restrictOption :: SchemaRestriction -> SchemaRestriction
scEmpty :: Schema
scRequiredAttr :: SchemaRestriction -> Schema
scImpliedAttr :: SchemaRestriction -> Schema
scFixedCData :: String -> Schema
scRestrict :: SchemaRestriction -> Schema -> Schema
scSeq :: Schema -> Schema -> Schema
scSeqs :: [Schema] -> Schema
scNull :: Schema
scAlt :: Schema -> Schema -> Schema
scAlts :: [Schema] -> Schema
scOption :: Schema -> Schema
scList :: Int -> Int -> Schema -> Schema
scElem :: String -> Schema -> Schema
scAttr :: String -> Schema -> Schema
Documentation
data Schema
The datatype for modelling the structure of an
Constructors
Any
PCData SchemaRestriction
CData Kind SchemaRestriction
Option Schema
Seq [Schema]
Alt [Schema]
Rep Int Int Schema
Element Name Schema
Attribute Name Schema
ElemRef Name
show/hide Instances
type Name = String
type Kind = String
type Schemas = [Schema]
data SchemaRestriction
Constructors
FixedValue String
DTDAttrType String
ValEnum [String]
RegEx String
XmlSchemaType String
show/hide Instances
isScElem :: Schema -> Bool
isScElemRef :: Schema -> Bool
isScPCData :: Schema -> Bool
isScCData :: Schema -> Bool
isScSARE :: Schema -> Bool
emptyText :: SchemaRestriction
noneEmptyText :: SchemaRestriction
restrictRegEx :: String -> SchemaRestriction
restrictDTDAttrType :: String -> SchemaRestriction
restrictEnum :: [String] -> SchemaRestriction
restrictOption :: SchemaRestriction -> SchemaRestriction
scEmpty :: Schema
scRequiredAttr :: SchemaRestriction -> Schema
scImpliedAttr :: SchemaRestriction -> Schema
scFixedCData :: String -> Schema
scRestrict :: SchemaRestriction -> Schema -> Schema
scSeq :: Schema -> Schema -> Schema
scSeqs :: [Schema] -> Schema
scNull :: Schema
scAlt :: Schema -> Schema -> Schema
scAlts :: [Schema] -> Schema
scOption :: Schema -> Schema
scList :: Int -> Int -> Schema -> Schema
scElem :: String -> Schema -> Schema
scAttr :: String -> Schema -> Schema
Produced by Haddock version 0.8