# Path: node.py
# class Relational(Container):
# 
#   def __init__(self, name, objects=[]):
#     self.domain_name = name
#     self.uid = uuid.uuid4()
#     Container.__init__(self, objects)
# 
#   def get_name(self):
#     return self.domain_name


from node import Relational
from generic_objects import *
from bacnet_devices import *
from smap import archiver
from smap.archiver import client
import networkx as nx
import sys
import gis
import node_types
import smap
#            'SUP_AIR_FAN': BACnetFAN('Supply Air Fan','BACnet point name'),
#            'SUP_AIR_FLW_SEN': BACnetSEN('Supply Air Flow Sensor','BACnet point name'),
#            'SUP_AIR_TMP_SEN': BACnetSEN('Supply Air Temp Sensor','BACnet point name'),
#            'SUP_AIR_PRS_SEN': BACnetSEN('Supply Air Pressure Sensor','BACnet point name'),
#          })
#ah2['OUT_AIR_DMP'].add_child(ah2['OUT_AIR_TMP_SEN'])
#ah2['OUT_AIR_TMP_SEN'].add_child(ah2['MIX_AIR_TMP_SEN'])
#ah2['MIX_AIR_TMP_SEN'].add_child(ah2['COO_VLV'])
#ah2['COO_VLV'].add_child(ah2['SUP_AIR_FAN'])
#ah2['SUP_AIR_FAN'].add_child(ah2['SUP_AIR_FLW_SEN'])
#ah2['SUP_AIR_FLW_SEN'].add_child(ah2['SUP_AIR_TMP_SEN'])
#ah2['SUP_AIR_TMP_SEN'].add_child(ah2['SUP_AIR_PRS_SEN'])
#ah2['RET_FAN'].add_child(ah2['EXH_AIR_DMP'])
#ah2['RET_AIR_PRS_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_FLW_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_HUM_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_TMP_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_DMP'].add_child(ah2['RET_AIR_TMP_SEN'])
#ah2['RET_FAN'].add_child(ah2['MIX_AIR_TMP_SEN'])
#
#Cold Water Loop 
cwl = CWL(hvac, 'Cold Water Loop', {
            'CON_WAT_COO_TOW': BACnetTOW('Condensed Water Cooling Tower','BACNet point name'),
            'CON_WAT_SUP_TMP_SEN': BACnetSEN('Condensed Water Supply Temp Sensor','BACNet point name'),
            'CON_WAT_PMP': BACnetPMP('Condensed Water Pump','BACNet point name'),
            'CON_CHL_WAT_CHR': BACnetCHR('Condensed to Chilled Water Chiller','BACNet point name'),
            'CON_WAT_RET_TMP_SEN': BACnetSEN('Condensed Water Return Temp Sensor','BACNet point name'),
            'CHL_WAT_SUP_TMP_SEN': BACnetSEN('Chilled Water Supply Temp Sensor','BACNet point name'),
            'CHL_WAT_RET_TMP_SEN':  BACnetSEN('Chilled Water Return Temp Sensor','BACNet point name'),
            'CHL_WAT_PMP': BACnetPMP('Chilled Water Pump','BACNet point name'),

# Path: node.py
# class Relational(Container):
# 
#   def __init__(self, name, objects=[]):
#     self.domain_name = name
#     self.uid = uuid.uuid4()
#     Container.__init__(self, objects)
# 
#   def get_name(self):
#     return self.domain_name


# Path: sdh_demo.py
from node import Relational
from generic_objects import *
from bacnet_devices import *
from smap import archiver
from smap.archiver import client
import networkx as nx
import sys
import gis
import node_types
import smap

#            'SUP_AIR_FAN': BACnetFAN('Supply Air Fan','BACnet point name'),
#            'SUP_AIR_FLW_SEN': BACnetSEN('Supply Air Flow Sensor','BACnet point name'),
#            'SUP_AIR_TMP_SEN': BACnetSEN('Supply Air Temp Sensor','BACnet point name'),
#            'SUP_AIR_PRS_SEN': BACnetSEN('Supply Air Pressure Sensor','BACnet point name'),
#          })
#ah2['OUT_AIR_DMP'].add_child(ah2['OUT_AIR_TMP_SEN'])
#ah2['OUT_AIR_TMP_SEN'].add_child(ah2['MIX_AIR_TMP_SEN'])
#ah2['MIX_AIR_TMP_SEN'].add_child(ah2['COO_VLV'])
#ah2['COO_VLV'].add_child(ah2['SUP_AIR_FAN'])
#ah2['SUP_AIR_FAN'].add_child(ah2['SUP_AIR_FLW_SEN'])
#ah2['SUP_AIR_FLW_SEN'].add_child(ah2['SUP_AIR_TMP_SEN'])
#ah2['SUP_AIR_TMP_SEN'].add_child(ah2['SUP_AIR_PRS_SEN'])
#ah2['RET_FAN'].add_child(ah2['EXH_AIR_DMP'])
#ah2['RET_AIR_PRS_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_FLW_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_HUM_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_TMP_SEN'].add_child(ah2['RET_FAN'])
#ah2['RET_AIR_DMP'].add_child(ah2['RET_AIR_TMP_SEN'])
#ah2['RET_FAN'].add_child(ah2['MIX_AIR_TMP_SEN'])
#
#Cold Water Loop 
cwl = CWL(hvac, 'Cold Water Loop', {
            'CON_WAT_COO_TOW': BACnetTOW('Condensed Water Cooling Tower','BACNet point name'),
            'CON_WAT_SUP_TMP_SEN': BACnetSEN('Condensed Water Supply Temp Sensor','BACNet point name'),
            'CON_WAT_PMP': BACnetPMP('Condensed Water Pump','BACNet point name'),
            'CON_CHL_WAT_CHR': BACnetCHR('Condensed to Chilled Water Chiller','BACNet point name'),
            'CON_WAT_RET_TMP_SEN': BACnetSEN('Condensed Water Return Temp Sensor','BACNet point name'),
            'CHL_WAT_SUP_TMP_SEN': BACnetSEN('Chilled Water Supply Temp Sensor','BACNet point name'),
            'CHL_WAT_RET_TMP_SEN':  BACnetSEN('Chilled Water Return Temp Sensor','BACNet point name'),
            'CHL_WAT_PMP': BACnetPMP('Chilled Water Pump','BACNet point name'),

            'CHL_WAT_PRS_DIF_SEN':  BACnetSEN('Chilled Water Pressure Difference Sensor','BACNet point name'),