| Copyright | (c) Hideyuki Tanaka, 2009-2015 |
|---|---|
| License | BSD3 |
| Maintainer | tanaka.hideyuki@gmail.com |
| Stability | experimental |
| Portability | portable |
| Safe Haskell | None |
| Language | Haskell2010 |
Data.MessagePack.Object
Description
MessagePack object definition
- data Object
- = ObjectNil
- | ObjectBool !Bool
- | ObjectInt !Int
- | ObjectFloat !Float
- | ObjectDouble !Double
- | ObjectStr !Text
- | ObjectBin !ByteString
- | ObjectArray !(Vector Object)
- | ObjectMap !(Vector (Object, Object))
- | ObjectExt !Word8 !ByteString
- class MessagePack a where
- toObject :: a -> Object
- fromObject :: Object -> Maybe a
MessagePack Object
Object Representation of MessagePack data.
Constructors
| ObjectNil | represents nil |
| ObjectBool !Bool | represents true or false |
| ObjectInt !Int | represents an integer |
| ObjectFloat !Float | represents a floating point number |
| ObjectDouble !Double | represents a floating point number |
| ObjectStr !Text | extending Raw type represents a UTF-8 string |
| ObjectBin !ByteString | extending Raw type represents a byte array |
| ObjectArray !(Vector Object) | represents a sequence of objects |
| ObjectMap !(Vector (Object, Object)) | represents key-value pairs of objects |
| ObjectExt !Word8 !ByteString | represents a tuple of an integer and a byte array where the integer represents type information and the byte array represents data. |
MessagePack Serializable Types
class MessagePack a where Source
Instances