jsaddle-0.9.9.2: Interface for JavaScript that works with GHCJS and GHC
Safe HaskellSafe-Inferred
LanguageHaskell2010

GHCJS.Marshal

Documentation

class FromJSVal a where Source #

Minimal complete definition

Nothing

Methods

fromJSVal :: JSVal -> JSM (Maybe a) Source #

default fromJSVal :: (Generic a, GFromJSVal (Rep a ())) => JSVal -> JSM (Maybe a) Source #

fromJSValUnchecked :: JSVal -> JSM a Source #

fromJSValListOf :: JSVal -> JSM (Maybe [a]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [a] Source #

Instances

Instances details
FromJSVal Value Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Int16 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Int32 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Int8 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Word16 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Word32 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Word8 Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal JSString Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

FromJSVal JSVal Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Text Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

FromJSVal () Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Bool Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Char Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

FromJSVal Double Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Float Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Int Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal Word Source # 
Instance details

Defined in GHCJS.Marshal

FromJSVal a => FromJSVal (Maybe a) Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

FromJSVal a => FromJSVal [a] Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

(FromJSVal a, FromJSVal b) => FromJSVal (a, b) Source # 
Instance details

Defined in GHCJS.Marshal

(FromJSVal a, FromJSVal b, FromJSVal c) => FromJSVal (a, b, c) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c)] Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d) => FromJSVal (a, b, c, d) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d)] Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e) => FromJSVal (a, b, c, d, e) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e)] Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f) => FromJSVal (a, b, c, d, e, f) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f)] Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f, FromJSVal g) => FromJSVal (a, b, c, d, e, f, g) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f, g)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f, g) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f, g)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f, g)] Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f, FromJSVal g, FromJSVal h) => FromJSVal (a, b, c, d, e, f, g, h) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f, g, h)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f, g, h) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f, g, h)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f, g, h)] Source #

class ToJSVal a where Source #

Minimal complete definition

Nothing

Methods

toJSVal :: a -> JSM JSVal Source #

default toJSVal :: (Generic a, GToJSVal (Rep a ())) => a -> JSM JSVal Source #

toJSValListOf :: [a] -> JSM JSVal Source #

Instances

Instances details
ToJSVal Value Source #

Makes a JSON value

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Int16 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Int32 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Int8 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Word16 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Word32 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Word8 Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal JSString Source #

Makes a JavaScript string

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal JSVal Source #

If we already have a JSVal we are fine

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Function Source # 
Instance details

Defined in Language.Javascript.JSaddle.Object

ToJSVal JSCallAsFunction Source #

A callback to Haskell can be used as a JavaScript value. This will create an anonymous JavaScript function object. Use function to create one with a name.

Instance details

Defined in Language.Javascript.JSaddle.Object

ToJSVal Object Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal JSNull Source #

Makes a null JavaScript value

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal JSUndefined Source #

Makes an undefined JavaScript value

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal JSValue Source #

Makes a JavaScript value from a JSValue ADT.

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Text Source #

Makes a JavaScript string

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Bool Source #

Make a JavaScript boolean value

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Char Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Double Source #

Makes a JavaScript number

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Float Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Int Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal Word Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal v => ToJSVal (JSM v) Source #

JSVal can be made by evaluating a function in JSM as long as it returns something we can make into a JSVal.

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal a => ToJSVal (Maybe a) Source #

Makes a JSVal or null JavaScript value

Instance details

Defined in Language.Javascript.JSaddle.Value

ToJSVal a => ToJSVal [a] Source # 
Instance details

Defined in Language.Javascript.JSaddle.Value

Methods

toJSVal :: [a] -> JSM JSVal Source #

toJSValListOf :: [[a]] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b) => ToJSVal (a, b) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b) -> JSM JSVal Source #

toJSValListOf :: [(a, b)] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b, ToJSVal c) => ToJSVal (a, b, c) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b, c) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c)] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d) => ToJSVal (a, b, c, d) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b, c, d) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d)] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e) => ToJSVal (a, b, c, d, e) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b, c, d, e) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e)] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e, ToJSVal f) => ToJSVal (a, b, c, d, e, f) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b, c, d, e, f) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e, f)] -> JSM JSVal Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e, ToJSVal f, ToJSVal g) => ToJSVal (a, b, c, d, e, f, g) Source # 
Instance details

Defined in GHCJS.Marshal

Methods

toJSVal :: (a, b, c, d, e, f, g) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e, f, g)] -> JSM JSVal Source #

Orphan instances

FromJSVal Value Source # 
Instance details

FromJSVal Int16 Source # 
Instance details

FromJSVal Int32 Source # 
Instance details

FromJSVal Int8 Source # 
Instance details

FromJSVal Word16 Source # 
Instance details

FromJSVal Word32 Source # 
Instance details

FromJSVal Word8 Source # 
Instance details

FromJSVal JSVal Source # 
Instance details

FromJSVal () Source # 
Instance details

FromJSVal Bool Source # 
Instance details

FromJSVal Double Source # 
Instance details

FromJSVal Float Source # 
Instance details

FromJSVal Int Source # 
Instance details

FromJSVal Word Source # 
Instance details

(FromJSVal a, FromJSVal b) => FromJSVal (a, b) Source # 
Instance details

(ToJSVal a, ToJSVal b) => ToJSVal (a, b) Source # 
Instance details

Methods

toJSVal :: (a, b) -> JSM JSVal Source #

toJSValListOf :: [(a, b)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c) => FromJSVal (a, b, c) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c)] Source #

(ToJSVal a, ToJSVal b, ToJSVal c) => ToJSVal (a, b, c) Source # 
Instance details

Methods

toJSVal :: (a, b, c) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d) => FromJSVal (a, b, c, d) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d)] Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d) => ToJSVal (a, b, c, d) Source # 
Instance details

Methods

toJSVal :: (a, b, c, d) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e) => FromJSVal (a, b, c, d, e) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e)] Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e) => ToJSVal (a, b, c, d, e) Source # 
Instance details

Methods

toJSVal :: (a, b, c, d, e) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f) => FromJSVal (a, b, c, d, e, f) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f)] Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e, ToJSVal f) => ToJSVal (a, b, c, d, e, f) Source # 
Instance details

Methods

toJSVal :: (a, b, c, d, e, f) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e, f)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f, FromJSVal g) => FromJSVal (a, b, c, d, e, f, g) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f, g)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f, g) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f, g)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f, g)] Source #

(ToJSVal a, ToJSVal b, ToJSVal c, ToJSVal d, ToJSVal e, ToJSVal f, ToJSVal g) => ToJSVal (a, b, c, d, e, f, g) Source # 
Instance details

Methods

toJSVal :: (a, b, c, d, e, f, g) -> JSM JSVal Source #

toJSValListOf :: [(a, b, c, d, e, f, g)] -> JSM JSVal Source #

(FromJSVal a, FromJSVal b, FromJSVal c, FromJSVal d, FromJSVal e, FromJSVal f, FromJSVal g, FromJSVal h) => FromJSVal (a, b, c, d, e, f, g, h) Source # 
Instance details

Methods

fromJSVal :: JSVal -> JSM (Maybe (a, b, c, d, e, f, g, h)) Source #

fromJSValUnchecked :: JSVal -> JSM (a, b, c, d, e, f, g, h) Source #

fromJSValListOf :: JSVal -> JSM (Maybe [(a, b, c, d, e, f, g, h)]) Source #

fromJSValUncheckedListOf :: JSVal -> JSM [(a, b, c, d, e, f, g, h)] Source #