Database.hs
1 {-| 2 Module : Gargantext.Database 3 Description : Tools for Database 4 Copyright : (c) CNRS, 2017-Present 5 License : AGPL + CECILL v3 6 Maintainer : team@gargantext.org 7 Stability : experimental 8 Portability : POSIX 9 10 All Database related stuff here. 11 12 Target: just import this module and nothing else to work with 13 Gargantext's database. 14 15 Database Schema: 16 https://dl.gargantext.org/2023-06-09-gargantext-db-graph.svg 17 18 -} 19 20 21 module Gargantext.Database ( module Gargantext.Database.Prelude 22 , module Gargantext.Database.Schema.NodeNode 23 , insertDB 24 -- , module Gargantext.Database.Bashql 25 ) 26 where 27 28 import Gargantext.Prelude 29 import Gargantext.Database.Prelude (DBCmd) -- (connectGargandb) 30 31 -- import Gargantext.Database.Schema.Node 32 -- import Gargantext.Database.Query.Table.Node 33 34 import Gargantext.Database.Schema.NodeNode -- (NodeNode(..)) 35 import Gargantext.Database.Query.Table.NodeNode 36 37 38 class InsertDB a where 39 insertDB :: a -> DBCmd err Int 40 41 {- 42 class DeleteDB a where 43 deleteDB :: a -> DBCmd err Int 44 -} 45 46 instance InsertDB [NodeNode] where 47 insertDB = insertNodeNode 48 49 50 {- 51 instance InsertDB [Node a] where 52 insertDB = insertNodes' 53 54 instance InsertDB [NodeNodeNgram] where 55 insertDB = ... 56 57 58 -}