Portability | Portable (Cookbook) |
---|---|
Stability | Stable |
Maintainer | nathanpisarski@gmail.com |
Safe Haskell | Safe-Inferred |
Q2Api is the user-facing part of Quill. It has all the functions necessar to Create, Read, Update, and Delete information from the database, and turn a database back into a Quill-readable string.
- getQuillName :: Quill -> String
- getQuillBody :: Quill -> Element String
- getQuill :: [Quill] -> String -> QuillStatus Quill
- lookUp :: [Quill] -> (String, String) -> QuillStatus String
- removeQuill :: [Quill] -> String -> [Quill]
- removeItem :: [Quill] -> (String, String) -> QuillStatus [Quill]
- addQuill :: [Quill] -> Quill -> [Quill]
- addItem :: [Quill] -> QuillAddition -> QuillStatus [Quill]
- qMap :: QuillStatus [Quill] -> ([Quill] -> QuillStatus [Quill]) -> QuillStatus [Quill]
- changeItem :: [Quill] -> QuillAddition -> QuillStatus [Quill]
- toString :: Quill -> String
Documentation
getQuillName :: Quill -> StringSource
Get the name of a Quill.
getQuillBody :: Quill -> Element StringSource
Return the element of the Quill, specifically useful for lists.
getQuill :: [Quill] -> String -> QuillStatus QuillSource
Find a quill in the database by name, returning it or a possible error type.
lookUp :: [Quill] -> (String, String) -> QuillStatus StringSource
Look up the value of a Quill TABLE. Will produce an error on a list.
removeQuill :: [Quill] -> String -> [Quill]Source
Remove a quill from the database by name.
removeItem :: [Quill] -> (String, String) -> QuillStatus [Quill]Source
Remove an item from a Quill within a database. Works aggressively, meaning it removes all copies to help sanitize QuillMultiples out.
addItem :: [Quill] -> QuillAddition -> QuillStatus [Quill]Source
Add a QuillAddition to the databse. QuillAddition is a safe encapsulation of list and table values.
qMap :: QuillStatus [Quill] -> ([Quill] -> QuillStatus [Quill]) -> QuillStatus [Quill]Source
Map a Quill function.
changeItem :: [Quill] -> QuillAddition -> QuillStatus [Quill]Source
Change an item within the database using a Quill addition. Wrapper of addItem and removeItem.