orgstat-0.0.3: Statistics visualizer for org-mode

Safe HaskellNone
LanguageHaskell2010

OrgStat.Ast

Description

Abstract syntax tree for org.

Synopsis

Documentation

data Clock Source #

Org clock representation -- a pair of time in UTC. Should be local time in fact, but we'll assume that UTC timestamps support in org will be added at some point. For now all tags are to be read in local time.

Constructors

Clock 

Fields

Instances

Eq Clock Source # 

Methods

(==) :: Clock -> Clock -> Bool #

(/=) :: Clock -> Clock -> Bool #

Ord Clock Source # 

Methods

compare :: Clock -> Clock -> Ordering #

(<) :: Clock -> Clock -> Bool #

(<=) :: Clock -> Clock -> Bool #

(>) :: Clock -> Clock -> Bool #

(>=) :: Clock -> Clock -> Bool #

max :: Clock -> Clock -> Clock #

min :: Clock -> Clock -> Clock #

Show Clock Source # 

Methods

showsPrec :: Int -> Clock -> ShowS #

show :: Clock -> String #

showList :: [Clock] -> ShowS #

data Org Source #

Main datatype of org AST. It may contain some metadata if needed (e.g. current node depth, children number etc). Content of headers is ignored.

Constructors

Org 

Instances

Eq Org Source # 

Methods

(==) :: Org -> Org -> Bool #

(/=) :: Org -> Org -> Bool #

Show Org Source # 

Methods

showsPrec :: Int -> Org -> ShowS #

show :: Org -> String #

showList :: [Org] -> ShowS #

fmapOrgLens :: ASetter' Org a -> (a -> a) -> Org -> Org Source #

Functor-like fmap on field chosen by lens.

traverseTree :: Traversal' Org Org Source #

Traverses node and subnodes, all recursively

mergeClocks :: Org -> Org Source #

Merges task clocks that have less then 2m delta between them into one.