| Safe Haskell | Safe-Inferred |
|---|---|
| Language | Haskell2010 |
Commonmark.Types
Contents
Synopsis
- newtype Format = Format Text
- data ListSpacing
- data ListType
- = BulletList !Char
- | OrderedList !Int !EnumeratorType !DelimiterType
- data DelimiterType
- data EnumeratorType
- class (Monoid a, Show a, Rangeable a, HasAttributes a) => IsInline a where
- class (Monoid b, Show b, Rangeable b, IsInline il, HasAttributes b) => IsBlock il b | b -> il where
- paragraph :: il -> b
- plain :: il -> b
- thematicBreak :: b
- blockQuote :: b -> b
- codeBlock :: Text -> Text -> b
- heading :: Int -> il -> b
- rawBlock :: Format -> Text -> b
- referenceLinkDefinition :: Text -> (Text, Text) -> b
- list :: ListType -> ListSpacing -> [b] -> b
- newtype SourceRange = SourceRange {
- unSourceRange :: [(SourcePos, SourcePos)]
- class Rangeable a where
- ranged :: SourceRange -> a -> a
- type Attribute = (Text, Text)
- type Attributes = [Attribute]
- class HasAttributes a where
- addAttributes :: Attributes -> a -> a
- class ToPlainText a where
- toPlainText :: a -> Text
- sourceColumn :: SourcePos -> Column
- sourceLine :: SourcePos -> Line
- sourceName :: SourcePos -> SourceName
- data SourcePos
Documentation
Constructors
| Format Text |
Instances
| Data Format Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Format -> c Format gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Format dataTypeOf :: Format -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Format) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Format) gmapT :: (forall b. Data b => b -> b) -> Format -> Format gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Format -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Format -> r gmapQ :: (forall d. Data d => d -> u) -> Format -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> Format -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> Format -> m Format gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Format -> m Format gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Format -> m Format | |
| Show Format Source # | |
| Eq Format Source # | |
data ListSpacing Source #
Instances
| Data ListSpacing Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ListSpacing -> c ListSpacing gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ListSpacing toConstr :: ListSpacing -> Constr dataTypeOf :: ListSpacing -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ListSpacing) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ListSpacing) gmapT :: (forall b. Data b => b -> b) -> ListSpacing -> ListSpacing gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ListSpacing -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ListSpacing -> r gmapQ :: (forall d. Data d => d -> u) -> ListSpacing -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> ListSpacing -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> ListSpacing -> m ListSpacing gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ListSpacing -> m ListSpacing gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ListSpacing -> m ListSpacing | |
| Show ListSpacing Source # | |
Defined in Commonmark.Types Methods showsPrec :: Int -> ListSpacing -> ShowS show :: ListSpacing -> String showList :: [ListSpacing] -> ShowS | |
| Eq ListSpacing Source # | |
Defined in Commonmark.Types | |
| Ord ListSpacing Source # | |
Defined in Commonmark.Types Methods compare :: ListSpacing -> ListSpacing -> Ordering (<) :: ListSpacing -> ListSpacing -> Bool (<=) :: ListSpacing -> ListSpacing -> Bool (>) :: ListSpacing -> ListSpacing -> Bool (>=) :: ListSpacing -> ListSpacing -> Bool max :: ListSpacing -> ListSpacing -> ListSpacing min :: ListSpacing -> ListSpacing -> ListSpacing | |
Constructors
| BulletList !Char | |
| OrderedList !Int !EnumeratorType !DelimiterType |
Instances
| Data ListType Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> ListType -> c ListType gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c ListType toConstr :: ListType -> Constr dataTypeOf :: ListType -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c ListType) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c ListType) gmapT :: (forall b. Data b => b -> b) -> ListType -> ListType gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> ListType -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> ListType -> r gmapQ :: (forall d. Data d => d -> u) -> ListType -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> ListType -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> ListType -> m ListType gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> ListType -> m ListType gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> ListType -> m ListType | |
| Show ListType Source # | |
| Eq ListType Source # | |
| Ord ListType Source # | |
data DelimiterType Source #
Instances
| Data DelimiterType Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> DelimiterType -> c DelimiterType gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c DelimiterType toConstr :: DelimiterType -> Constr dataTypeOf :: DelimiterType -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c DelimiterType) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c DelimiterType) gmapT :: (forall b. Data b => b -> b) -> DelimiterType -> DelimiterType gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> DelimiterType -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> DelimiterType -> r gmapQ :: (forall d. Data d => d -> u) -> DelimiterType -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> DelimiterType -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> DelimiterType -> m DelimiterType gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> DelimiterType -> m DelimiterType gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> DelimiterType -> m DelimiterType | |
| Show DelimiterType Source # | |
Defined in Commonmark.Types Methods showsPrec :: Int -> DelimiterType -> ShowS show :: DelimiterType -> String showList :: [DelimiterType] -> ShowS | |
| Eq DelimiterType Source # | |
Defined in Commonmark.Types | |
| Ord DelimiterType Source # | |
Defined in Commonmark.Types Methods compare :: DelimiterType -> DelimiterType -> Ordering (<) :: DelimiterType -> DelimiterType -> Bool (<=) :: DelimiterType -> DelimiterType -> Bool (>) :: DelimiterType -> DelimiterType -> Bool (>=) :: DelimiterType -> DelimiterType -> Bool max :: DelimiterType -> DelimiterType -> DelimiterType min :: DelimiterType -> DelimiterType -> DelimiterType | |
data EnumeratorType Source #
Constructors
| Decimal | |
| UpperAlpha | |
| LowerAlpha | |
| UpperRoman | |
| LowerRoman |
Instances
| Data EnumeratorType Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> EnumeratorType -> c EnumeratorType gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c EnumeratorType toConstr :: EnumeratorType -> Constr dataTypeOf :: EnumeratorType -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c EnumeratorType) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c EnumeratorType) gmapT :: (forall b. Data b => b -> b) -> EnumeratorType -> EnumeratorType gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> EnumeratorType -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> EnumeratorType -> r gmapQ :: (forall d. Data d => d -> u) -> EnumeratorType -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> EnumeratorType -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> EnumeratorType -> m EnumeratorType gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> EnumeratorType -> m EnumeratorType gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> EnumeratorType -> m EnumeratorType | |
| Show EnumeratorType Source # | |
Defined in Commonmark.Types Methods showsPrec :: Int -> EnumeratorType -> ShowS show :: EnumeratorType -> String showList :: [EnumeratorType] -> ShowS | |
| Eq EnumeratorType Source # | |
Defined in Commonmark.Types Methods (==) :: EnumeratorType -> EnumeratorType -> Bool (/=) :: EnumeratorType -> EnumeratorType -> Bool | |
| Ord EnumeratorType Source # | |
Defined in Commonmark.Types Methods compare :: EnumeratorType -> EnumeratorType -> Ordering (<) :: EnumeratorType -> EnumeratorType -> Bool (<=) :: EnumeratorType -> EnumeratorType -> Bool (>) :: EnumeratorType -> EnumeratorType -> Bool (>=) :: EnumeratorType -> EnumeratorType -> Bool max :: EnumeratorType -> EnumeratorType -> EnumeratorType min :: EnumeratorType -> EnumeratorType -> EnumeratorType | |
class (Monoid a, Show a, Rangeable a, HasAttributes a) => IsInline a where Source #
Methods
escapedChar :: Char -> a Source #
Arguments
| :: Text | Destination |
| -> Text | Title |
| -> a | Link description |
| -> a |
Arguments
| :: Text | Source |
| -> Text | Title |
| -> a | Description |
| -> a |
Instances
| Rangeable (Html a) => IsInline (Html a) Source # | |
Defined in Commonmark.Html Methods str :: Text -> Html a Source # entity :: Text -> Html a Source # escapedChar :: Char -> Html a Source # emph :: Html a -> Html a Source # strong :: Html a -> Html a Source # link :: Text -> Text -> Html a -> Html a Source # image :: Text -> Text -> Html a -> Html a Source # | |
| (IsInline a, Semigroup a) => IsInline (WithSourceMap a) Source # | |
Defined in Commonmark.SourceMap Methods lineBreak :: WithSourceMap a Source # softBreak :: WithSourceMap a Source # str :: Text -> WithSourceMap a Source # entity :: Text -> WithSourceMap a Source # escapedChar :: Char -> WithSourceMap a Source # emph :: WithSourceMap a -> WithSourceMap a Source # strong :: WithSourceMap a -> WithSourceMap a Source # link :: Text -> Text -> WithSourceMap a -> WithSourceMap a Source # image :: Text -> Text -> WithSourceMap a -> WithSourceMap a Source # code :: Text -> WithSourceMap a Source # rawInline :: Format -> Text -> WithSourceMap a Source # | |
class (Monoid b, Show b, Rangeable b, IsInline il, HasAttributes b) => IsBlock il b | b -> il where Source #
Methods
thematicBreak :: b Source #
blockQuote :: b -> b Source #
codeBlock :: Text -> Text -> b Source #
Arguments
| :: Int | Level |
| -> il | text |
| -> b |
rawBlock :: Format -> Text -> b Source #
referenceLinkDefinition Source #
Arguments
| :: Text | Label |
| -> (Text, Text) | Destination, title |
| -> b |
list :: ListType -> ListSpacing -> [b] -> b Source #
Instances
newtype SourceRange Source #
Constructors
| SourceRange | |
Fields
| |
Instances
| Monoid SourceRange Source # | |
Defined in Commonmark.Types | |
| Semigroup SourceRange Source # | |
Defined in Commonmark.Types Methods (<>) :: SourceRange -> SourceRange -> SourceRange sconcat :: NonEmpty SourceRange -> SourceRange stimes :: Integral b => b -> SourceRange -> SourceRange | |
| Data SourceRange Source # | |
Defined in Commonmark.Types Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SourceRange -> c SourceRange gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SourceRange toConstr :: SourceRange -> Constr dataTypeOf :: SourceRange -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c SourceRange) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SourceRange) gmapT :: (forall b. Data b => b -> b) -> SourceRange -> SourceRange gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SourceRange -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SourceRange -> r gmapQ :: (forall d. Data d => d -> u) -> SourceRange -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> SourceRange -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> SourceRange -> m SourceRange gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SourceRange -> m SourceRange gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SourceRange -> m SourceRange | |
| Show SourceRange Source # | |
Defined in Commonmark.Types Methods showsPrec :: Int -> SourceRange -> ShowS show :: SourceRange -> String showList :: [SourceRange] -> ShowS | |
| Eq SourceRange Source # | |
Defined in Commonmark.Types | |
| Ord SourceRange Source # | |
Defined in Commonmark.Types Methods compare :: SourceRange -> SourceRange -> Ordering (<) :: SourceRange -> SourceRange -> Bool (<=) :: SourceRange -> SourceRange -> Bool (>) :: SourceRange -> SourceRange -> Bool (>=) :: SourceRange -> SourceRange -> Bool max :: SourceRange -> SourceRange -> SourceRange min :: SourceRange -> SourceRange -> SourceRange | |
| Rangeable (Html SourceRange) Source # | |
Defined in Commonmark.Html Methods ranged :: SourceRange -> Html SourceRange -> Html SourceRange Source # | |
class Rangeable a where Source #
Methods
ranged :: SourceRange -> a -> a Source #
Instances
| Rangeable (Html SourceRange) Source # | |
Defined in Commonmark.Html Methods ranged :: SourceRange -> Html SourceRange -> Html SourceRange Source # | |
| Rangeable (Html ()) Source # | |
Defined in Commonmark.Html | |
| (Rangeable a, Monoid a, Show a) => Rangeable (WithSourceMap a) Source # | |
Defined in Commonmark.SourceMap Methods ranged :: SourceRange -> WithSourceMap a -> WithSourceMap a Source # | |
type Attributes = [Attribute] Source #
class HasAttributes a where Source #
Methods
addAttributes :: Attributes -> a -> a Source #
Instances
| HasAttributes (Html a) Source # | |
Defined in Commonmark.Html Methods addAttributes :: Attributes -> Html a -> Html a Source # | |
| HasAttributes (WithSourceMap a) Source # | |
Defined in Commonmark.SourceMap Methods addAttributes :: Attributes -> WithSourceMap a -> WithSourceMap a Source # | |
class ToPlainText a where Source #
Methods
toPlainText :: a -> Text Source #
Instances
| ToPlainText (Html a) Source # | |
Defined in Commonmark.Html Methods toPlainText :: Html a -> Text Source # | |
| ToPlainText a => ToPlainText (WithSourceMap a) Source # | |
Defined in Commonmark.SourceMap Methods toPlainText :: WithSourceMap a -> Text Source # | |
Re-exports
sourceColumn :: SourcePos -> Column #
sourceLine :: SourcePos -> Line #
sourceName :: SourcePos -> SourceName #
Instances
| Data SourcePos # | |
Defined in Text.Parsec.Pos Methods gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> SourcePos -> c SourcePos gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c SourcePos toConstr :: SourcePos -> Constr dataTypeOf :: SourcePos -> DataType dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c SourcePos) dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c SourcePos) gmapT :: (forall b. Data b => b -> b) -> SourcePos -> SourcePos gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> SourcePos -> r gmapQr :: forall r r'. (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> SourcePos -> r gmapQ :: (forall d. Data d => d -> u) -> SourcePos -> [u] gmapQi :: Int -> (forall d. Data d => d -> u) -> SourcePos -> u gmapM :: Monad m => (forall d. Data d => d -> m d) -> SourcePos -> m SourcePos gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> SourcePos -> m SourcePos gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> SourcePos -> m SourcePos | |
| Show SourcePos # | |
| Eq SourcePos # | |
| Ord SourcePos # | |
Defined in Text.Parsec.Pos | |