Safe Haskell | Safe |
---|---|

Language | Haskell2010 |

- newtype T time label = Cons {}
- type Interval time label = ((time, time), label)
- empty :: T time label
- null :: T time label -> Bool
- singleton :: (time, time) -> label -> T time label
- fromAdjacentChunks :: Num time => [(time, label)] -> T time label
- lift :: ([Interval time0 label0] -> [Interval time1 label1]) -> T time0 label0 -> T time1 label1
- lift2 :: ([Interval time0 label0] -> [Interval time1 label1] -> [Interval time2 label2]) -> T time0 label0 -> T time1 label1 -> T time2 label2
- formatTime :: RealFrac time => time -> String
- mapTime :: (time0 -> time1) -> T time0 label -> T time1 label
- mapWithTime :: ((time, time) -> label0 -> label1) -> T time label0 -> T time label1
- realTimes :: Fractional time => time -> T Int label -> T time label
- mask :: Ord time => (time, time) -> T time label -> T time label
- zipWithList :: (label0 -> label1 -> label2) -> [label0] -> T time label1 -> T time label2
- writeFile :: RealFrac time => FilePath -> T time String -> IO ()
- writeFileInt :: RealFrac time => time -> FilePath -> T Int String -> IO ()
- parseTime :: Fractional time => String -> Maybe time
- readFile :: Fractional time => FilePath -> IO (T time String)

# Documentation

fromAdjacentChunks :: Num time => [(time, label)] -> T time label Source #

lift :: ([Interval time0 label0] -> [Interval time1 label1]) -> T time0 label0 -> T time1 label1 Source #

lift2 :: ([Interval time0 label0] -> [Interval time1 label1] -> [Interval time2 label2]) -> T time0 label0 -> T time1 label1 -> T time2 label2 Source #

formatTime :: RealFrac time => time -> String Source #

Format the times using a comma, which is certainly only correct in German locale.

mapTime :: (time0 -> time1) -> T time0 label -> T time1 label Source #

You must make sure, that the time mapping function preserves the order. This is not checked.

mapWithTime :: ((time, time) -> label0 -> label1) -> T time label0 -> T time label1 Source #

zipWithList :: (label0 -> label1 -> label2) -> [label0] -> T time label1 -> T time label2 Source #