Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- content :: HasContent x x' => Lens x x' (Content x) (Content x')
- contents :: HasContents x x' => Lens x x' (Seq (Contents x)) (Seq (Contents x'))
- tag :: HasTag x => Optic' (TagOpticKind x) NoIx x (Tag (Annotation x))
- name :: (HasTag x, JoinKinds (TagOpticKind x) A_Lens k) => Optic' k NoIx x Text
- annotation :: HasAnnotation x x' => Lens x x' (Annotation x) (Annotation x')
- metadata :: HasMetadata x => Optic' (MetadataOpticKind x) NoIx x Metadata
- atSetting :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Text -> Optic' k NoIx m (Maybe Text)
- hasProperty :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Text -> Optic' k NoIx m Bool
- properties :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Optic' k NoIx m (Set Text)
- settings :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Optic' k NoIx m (Map Text Text)
- fork :: CanFork x => Prism' x (Fork x)
- plain :: CanBePlain x => Prism' x (Plain x)
- paragraph :: Prism' (Block ann) (Paragraph ann)
- blockTag :: Prism' (Block ann) (BlockTag ann)
- allParagraphs :: HasManyParagraphs x => Traversal' x (Paragraph (Annotation x))
- allPlainBlocks :: HasManyPlainBlocks x => Traversal' x (Tagged (PlainBlock (Annotation x)))
- allPlainInlines :: HasManyPlainInlines x => Traversal' x (Fragment (Annotation x))
- allAnnotations :: HasManyAnnotations x x' => Traversal x x' (Annotation x) (Annotation x')
- allTags :: HasManyTags x => Traversal' x (Tag (Annotation x))
- allInlineTags :: HasManyTags x => Traversal' x (Tag (Annotation x))
- allBlockTags :: HasManyBlockTags x => Traversal' x (Tag (Annotation x))
- allMetadata :: HasManyMetadata x => Traversal' x Metadata
- tagless :: CanBeTagless a => KindOfText txt -> AffineFold a txt
- taglessContent :: CanHaveTaglessContent a => KindOfText t -> AffineFold a t
- data KindOfText txt where
- TextLine :: KindOfText Text
- TextStanza :: KindOfText (Seq Text)
- TextParagraphs :: KindOfText (Seq (Seq Text))
Lenses
tag :: HasTag x => Optic' (TagOpticKind x) NoIx x (Tag (Annotation x)) Source #
Annotation
annotation :: HasAnnotation x x' => Lens x x' (Annotation x) (Annotation x') Source #
Metadata
metadata :: HasMetadata x => Optic' (MetadataOpticKind x) NoIx x Metadata Source #
atSetting :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Text -> Optic' k NoIx m (Maybe Text) Source #
Select a setting from an item attached to metadata. Returns Nothing
if no value is set.
hasProperty :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Text -> Optic' k NoIx m Bool Source #
Check if a property is attached to an item with metadata. Using this optic as a setter will add a property if set to True
and remove the property when set to False
.
properties :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Optic' k NoIx m (Set Text) Source #
Fetch all properties from items which contain metadata.
settings :: (HasMetadata m, JoinKinds (MetadataOpticKind m) A_Lens k) => Optic' k NoIx m (Map Text Text) Source #
Fetch all settings defined on items which contain metadata.
Prisms
Traversals
allParagraphs :: HasManyParagraphs x => Traversal' x (Paragraph (Annotation x)) Source #
allPlainBlocks :: HasManyPlainBlocks x => Traversal' x (Tagged (PlainBlock (Annotation x))) Source #
allPlainInlines :: HasManyPlainInlines x => Traversal' x (Fragment (Annotation x)) Source #
Annotation
allAnnotations :: HasManyAnnotations x x' => Traversal x x' (Annotation x) (Annotation x') Source #
Tags
allTags :: HasManyTags x => Traversal' x (Tag (Annotation x)) Source #
allInlineTags :: HasManyTags x => Traversal' x (Tag (Annotation x)) Source #
allBlockTags :: HasManyBlockTags x => Traversal' x (Tag (Annotation x)) Source #
Metadata
allMetadata :: HasManyMetadata x => Traversal' x Metadata Source #
Affine folds
tagless :: CanBeTagless a => KindOfText txt -> AffineFold a txt Source #
taglessContent :: CanHaveTaglessContent a => KindOfText t -> AffineFold a t Source #
data KindOfText txt where Source #
TextLine :: KindOfText Text | |
TextStanza :: KindOfText (Seq Text) | |
TextParagraphs :: KindOfText (Seq (Seq Text)) |