Safe Haskell | None |
---|---|
Language | Haskell98 |
Helper functions for binding ffi, encoding, decoding via messagepack
Documentation
toMsg :: ComponentClass o => o -> ByteString Source #
fromMsg :: ComponentClass o => ByteString -> Maybe o Source #
mkMsgFun :: FunPtr MsgFunction -> MsgFunction Source #
mkMsgFunPtr :: MsgFunction -> IO (FunPtr MsgFunction) Source #
callMsgFunction :: FunPtr MsgFunction -> Ptr () -> Word64 -> ByteString -> IO Int Source #
callInitFunction :: FunPtr InitFunction -> Ptr () -> IO Int Source #
type EntityDestroyFunction = Ptr () -> IO () Source #
type EntityDataReleaseFunction = Ptr () -> IO () Source #
mkEntityDataReleaseFunction :: FunPtr EntityDataReleaseFunction -> EntityDataReleaseFunction Source #
mkObjectLibSystemCreateFunction :: FunPtr ObjectLibSystemCreateFunction -> ObjectLibSystemCreateFunction Source #
mkObjectLibSystemAddEntityFunction :: FunPtr ObjectLibSystemAddEntityFunction -> ObjectLibSystemAddEntityFunction Source #
type ObjectLibSystemStepFunction = Ptr () -> IO () Source #
mkObjectLibSystemStepFunction :: FunPtr ObjectLibSystemStepFunction -> ObjectLibSystemStepFunction Source #
mkCallbackSystemCreateFunction :: FunPtr CallbackSystemCreateFunction -> CallbackSystemCreateFunction Source #
type CallbackSystemRegisterReceiverFunction = Ptr () -> Ptr () -> Word64 -> FunPtr (Ptr () -> Word64 -> Ptr CChar -> Word32 -> IO Word32) -> IO () Source #
mkCallbackSystemRegisterReceiverFunction :: FunPtr CallbackSystemRegisterReceiverFunction -> CallbackSystemRegisterReceiverFunction Source #
type CallbackSystemStepFunction = Ptr () -> IO () Source #
mkCallbackSystemStepFunction :: FunPtr CallbackSystemStepFunction -> CallbackSystemStepFunction Source #
data EntityInterface Source #
type CStringCLen i = (CString, i) Source #
unsafeUseAsCStringLen' :: Integral i => ByteString -> (CStringCLen i -> IO a) -> IO a Source #
entityCreate :: ByteString -> IO (Ptr ()) Source #
entityDestroy :: Ptr () -> IO () Source #
entityDataRead :: Ptr () -> IO ByteString Source #
entityDataRelease :: Ptr () -> IO () Source #
objectLibSystemCreate :: IO (Ptr ()) Source #
objectLibSystemStep :: Ptr () -> IO () Source #
callbackSystemCreate :: IO (Ptr ()) Source #
callbackSystemRegisterReceiver :: Ptr () -> Ptr () -> Word64 -> FunPtr (Ptr () -> Word64 -> Ptr CChar -> Word32 -> IO Word32) -> IO () Source #
callbackSystemStep :: Ptr () -> IO () Source #