2 Module : Gargantext.Database.Schema.NodeNode_NodeNode
4 Copyright : (c) CNRS, 2017-Present
5 License : AGPL + CECILL v3
6 Maintainer : team@gargantext.org
7 Stability : experimental
12 {-# OPTIONS_GHC -fno-warn-orphans #-}
14 {-# LANGUAGE Arrows #-}
15 {-# LANGUAGE FunctionalDependencies #-}
16 {-# LANGUAGE QuasiQuotes #-}
17 {-# LANGUAGE TemplateHaskell #-}
19 module Gargantext.Database.Schema.NodeNode where
21 import Data.Maybe (Maybe)
22 import Gargantext.Core.Types
23 import Gargantext.Database.Schema.Prelude
24 import Gargantext.Prelude
27 data NodeNode_NodeNodePoly nn1 nn2 weight
28 = NodeNode_NodeNode { _nnnn_nn1_id :: !nn1
29 , _nnnn_nn2_id :: !nn2
30 , _nnnn_weight :: !weight
33 type NodeNodeWrite = NodeNodePoly (Column (PGInt4))
35 (Maybe (Column (PGFloat8)))
37 type NodeNodeRead = NodeNodePoly (Column (PGInt4))
39 (Maybe (Column (PGFloat8)))
41 type NodeNodeReadNull = NodeNodePoly (Column (Nullable PGInt4))
42 (Column (Nullable PGInt4))
43 (Column (Nullable PGFloat8))
45 type NodeNode_NodeNode = NodeNode_NodeNodePoly Int Int (Maybe Double)
47 $(makeAdaptorAndInstance "pNodeNode_NodeNode" ''NodeNode_NodeNodePoly)
48 makeLenses ''NodeNode_NodeNodePoly
50 nodeNode_NodeNodeTable :: Table NodeNode_NodeNodeWrite NodeNode_NodeNodeRead
51 nodeNode_NodeNodeTable =
52 Table "nodesnodes_nodesnodes"
54 NodeNode_NodeNode { _nnnn_nn1_id = required "nn1_id"
55 , _nnnn_nn2_id = required "nn2_id"
56 , _nnnn_weight = optional "weight"