Module

Data.Table.Internal

Package
purescript-tables
Repository
colehaus/purescript-tables

#Table Source

newtype Table rowId columnId cell

Constructors

Instances

#MissingCell Source

newtype MissingCell rowId columnId

Constructors

Instances

#valid Source

valid :: forall cell columnId rowId. Hashable rowId => Hashable columnId => Table rowId columnId cell -> Either (HashSet (MissingCell rowId columnId)) Unit

#mk Source

mk :: forall columnId rowId cell. Hashable rowId => Hashable columnId => HashMap (Tuple rowId columnId) cell -> Either (HashSet (MissingCell rowId columnId)) (Table rowId columnId cell)

#vectors Source

vectors :: forall columnId rowId cell id. Hashable id => Hashable rowId => Hashable columnId => Hashable cell => (Tuple rowId columnId -> id) -> Table rowId columnId cell -> HashSet (HashMap (Tuple rowId columnId) cell)

#vectors' Source

vectors' :: forall columnId rowId cell idr id. Hashable id => Hashable idr => (Tuple rowId columnId -> id) -> (Tuple rowId columnId -> idr) -> Table rowId columnId cell -> HashMap id (HashMap idr cell)

#vector Source

vector :: forall cell columnId rowId rid id. Eq id => Hashable rid => (Tuple rowId columnId -> id) -> (Tuple rowId columnId -> rid) -> Table rowId columnId cell -> id -> HashMap rid cell

#mapVectors Source

mapVectors :: forall idr id cell2 cell1 columnId rowId. Hashable id => Hashable rowId => Hashable columnId => Hashable cell1 => Hashable idr => (Tuple rowId columnId -> id) -> (Tuple rowId columnId -> idr) -> (id -> idr -> Tuple rowId columnId) -> (HashMap idr cell1 -> HashMap idr cell2) -> Table rowId columnId cell1 -> Either (HashSet (MissingCell rowId columnId)) (Table rowId columnId cell2)

The mapping function should preserve the length of the list. If it doesn't, you'll end up