Module

Foreign.Index

This module defines a type class for types which act like property indices.

#Index

class Index :: Type -> (Type -> Type) -> Constraintclass Index i m | i -> m where

This type class identifies types that act like property indices.

The canonical instances are for Strings and Ints.

Members

Instances

#Indexable

class Indexable :: Type -> (Type -> Type) -> Constraintclass Indexable a m | a -> m where

Members

Instances

#readProp

readProp :: forall m. Monad m => String -> Foreign -> ExceptT (NonEmptyList ForeignError) m Foreign

Attempt to read a value from a foreign value property

#readIndex

readIndex :: forall m. Monad m => Int -> Foreign -> ExceptT (NonEmptyList ForeignError) m Foreign

Attempt to read a value from a foreign value at the specified numeric index

#(!)

Operator alias for Foreign.Index.ix (left-associative / precedence 9)

Modules