orgmode-parse-0.0.1.2: A parser and writer for org-mode flavored documents.

Stabilitystable
MaintainerParnell Springmeyer <parnell@digitalmentat.com>
Safe HaskellNone

Data.OrgMode.Parse.Attoparsec.PropertyDrawer

Description

Parsing combinators for org-mode entry property drawers.

Synopsis

Documentation

data Heading Source

Constructors

Heading 

Fields

level :: Int
 
priority :: Maybe Priority
 
state :: Maybe State
 
title :: Text.Text
 
keywords :: [Keyword]
 

Instances

Eq Heading 
Show Heading 

data Priority Source

Constructors

A 
B 
C 
Unknown 

Instances

Eq Priority 
Ord Priority 
Read Priority 
Show Priority 

newtype State Source

Constructors

State Text.Text 

Instances

Eq State 
Show State 

newtype Keyword Source

Constructors

Keyword Text.Text 

Instances

Eq Keyword 
Ord Keyword 
Show Keyword 

newtype PropertyDrawer k v Source

Constructors

PropertyDrawer (HashMap k v) 

Instances

(Eq k, Eq v) => Eq (PropertyDrawer k v) 
(Show k, Show v) => Show (PropertyDrawer k v) 

drawer :: TP.Parser Text.Text (PropertyDrawer Text.Text Text.Text)Source

Parse a property drawer.

 :PROPERTIES:
 :DATE: [2014-12-14 11:00]
 :NOTE: Something really crazy happened today!
 :END:

property :: TP.Parser Text.Text (Text.Text, Text.Text)Source

Parse a property of a drawer.

Properties *must* be a `:KEY: value` pair, the key can be of any case and contain any characters except for newlines and colons (since they delimit the start and end of the key).