| Safe Haskell | None |
|---|---|
| Language | GHC2021 |
Ondim.Advanced
Description
This module is for advanced users. Generally speaking, you should only use this module if you want to define new targets (formats) or customize existing ones.
Documentation
class (Typeable t, Expansible t) => OndimNode t where Source #
Minimal complete definition
Nothing
Methods
identify :: t -> Maybe Text Source #
Returns the name of the node as defined by the OndimNode instance.
attributes :: t -> Ondim s [Attribute] Source #
Returns a list of attributes of the node as defined by the OndimNode instance.
Returns the children of the node as defined by the OndimNode instance.
castFrom :: OndimNode a => Maybe (a -> [t]) Source #
renderNode :: Maybe (t -> LByteString) Source #
Converts the node to a LByteString as defined by the OndimNode instance.
nodeAsText :: Maybe (t -> Text) Source #
Instances
| OndimNode Attribute Source # | |
| OndimNode LByteString Source # | |
Defined in Ondim.Internal.Class Methods identify :: LByteString -> Maybe Text Source # attributes :: LByteString -> Ondim s [Attribute] Source # children :: LByteString -> [LByteString] Source # castFrom :: OndimNode a => Maybe (a -> [LByteString]) Source # renderNode :: Maybe (LByteString -> LByteString) Source # nodeAsText :: Maybe (LByteString -> Text) Source # | |
| OndimNode Text Source # | |
Defined in Ondim.Internal.Class | |
| (OndimNode a, Expansible (t a), Foldable t, Typeable t) => OndimNode (t a) Source # | |
Defined in Ondim.Internal.Class | |
class Expansible t where Source #
Instances
| Expansible Attribute Source # | |
Defined in Ondim.Internal.Class | |
| Expansible LByteString Source # | |
Defined in Ondim.Internal.Class Methods expandSubs :: LByteString -> Ondim s LByteString Source # | |
| Expansible Text Source # | |
Defined in Ondim.Internal.Class | |
| OndimNode t => Expansible (Seq t) Source # | |
Defined in Ondim.Internal.Core | |
| OndimNode t => Expansible [t] Source # | |
Defined in Ondim.Internal.Core Methods expandSubs :: [t] -> Ondim s [t] Source # | |