|
| HAppS.Data.Default | | Portability | Not portable | | Stability | experimental | | Maintainer | AlexJacobson@HAppS.org |
|
|
|
|
|
| Description |
| Provides default values for Haskell datatypes. |
|
| Synopsis |
|
|
|
|
| The interface |
|
|
The Default class provides a defaultValue value, which is the default value for that type. There is no instance for arbitrary types by default, but if you declare an instance without providing the value then one will be built using the first constructor. defaultValue is used to provide values for any arguments of the constructor. If you want an instance for all types then import HAppS.Data.Default.Generic. | | | Methods | | | Instances | | Default Bool | | Default Char | | Default Double | | Default Float | | Default Int | | Default Int8 | | Default Int16 | | Default Int32 | | Default Int64 | | Default Integer | | Default Word | | Default Word8 | | Default Word16 | | Default Word32 | | Default Word64 | | Default () | | Default ByteString | | Default Nil | | Default Element | | Default K | | Default W | | Default Pass | | Default User | | Default UserInfo | | Default Word | | Default Published | | Default Updated | | Default Email | | Default Uri | | Default Content | | Default Summary | | Default Subtitle | | Default Title | | Default Id | | Default Label | | Default Scheme | | Default Term | | Default Category | | Default Name | | Default Contributor | | Default Author | | Default Entry | | Default Feed | | Default a => Default ([] a) | | Default a => Default (ForeignPtr a) | | Default a => Default (Maybe a) | | Default t[aiaw] => Default (Proxy t[aiaw]) | | (Default a, Default b) => Default (Either a b) | | (Default a, Default b) => Default ((,) a b) | | (Default a[a4NS], Default b[a4NT]) => Default (Couple a[a4NS] b[a4NT]) | | (Default a, Default b, Default c) => Default ((,,) a b c) | | (Default a, Default b, Default c, Default d) => Default ((,,,) a b c d) |
|
|
|
| Writing your own instances |
|
|
| This is the defaultValue that is used in an instance if you don't specify one. It may be a useful building block when writing your own instances. |
|
| Advanced usage |
|
|
| When writing your own generic functions for Default you may need to access the class method through this datatype rather than directly. | | Constructors | | Instances | |
|
|
|
| When writing your own generic functions for Default you may need this, the proxy value. |
|
| Produced by Haddock version 2.4.2 |