# 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
                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY10","68fe6fd7-611a-50cf-a020-aebb5f222618")
                        })
lightbank7_3 = LIG(l, 'Light Bank 3', {
                        'LO_REL' : BACnetREL( "Low Relay", "/WS86011/RELAY05","bbb2b35a-4bba-504a-a904-ace590e86449"),
                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY04","e25a1409-f2ac-585c-92d2-f712126d3321")
                        })
lightbank7_4 = LIG(l, 'Light Bank 4', {
                        'LO_REL' : BACnetREL( "Low Relay", "/WS86011/RELAY07","9c3b8e2a-b5cc-58fe-b408-264ad767daf9"),
                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY06","2ceedbb3-571e-501a-a3b4-aaab6d79c30f")
                      })


if 'Sutardja Dai Hall' in gis.buildings:
    sdh_floor4 = gis.buildings['Sutardja Dai Hall']['Floor 4']
    lightbank4_1.add_area(sdh_floor4['Zone 1'])
    lightbank4_2.add_area(sdh_floor4['Zone 2'])
    lightbank4_3.add_area(sdh_floor4['Zone 3'])
    lightbank4_4.add_area(sdh_floor4['Zone 4'])
    lightbank4_5.add_area(sdh_floor4['Zone 5'])

    sdh_floor6 = gis.buildings['Sutardja Dai Hall']['Floor 6']
    lightbank6_1.add_area(sdh_floor6['Zone 1'])

    sdh_floor7 = gis.buildings['Sutardja Dai Hall']['Floor 7']
    lightbank7_1.add_area(sdh_floor7['Zone 1'])
    lightbank7_2.add_area(sdh_floor7['Zone 2'])
    lightbank7_3.add_area(sdh_floor7['Zone 3'])
    lightbank7_4.add_area(sdh_floor7['Zone 4'])

#Air Handler 1

# 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

                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY10","68fe6fd7-611a-50cf-a020-aebb5f222618")
                        })
lightbank7_3 = LIG(l, 'Light Bank 3', {
                        'LO_REL' : BACnetREL( "Low Relay", "/WS86011/RELAY05","bbb2b35a-4bba-504a-a904-ace590e86449"),
                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY04","e25a1409-f2ac-585c-92d2-f712126d3321")
                        })
lightbank7_4 = LIG(l, 'Light Bank 4', {
                        'LO_REL' : BACnetREL( "Low Relay", "/WS86011/RELAY07","9c3b8e2a-b5cc-58fe-b408-264ad767daf9"),
                        'HI_REL' : BACnetREL( "High Relay", "/WS86011/RELAY06","2ceedbb3-571e-501a-a3b4-aaab6d79c30f")
                      })


if 'Sutardja Dai Hall' in gis.buildings:
    sdh_floor4 = gis.buildings['Sutardja Dai Hall']['Floor 4']
    lightbank4_1.add_area(sdh_floor4['Zone 1'])
    lightbank4_2.add_area(sdh_floor4['Zone 2'])
    lightbank4_3.add_area(sdh_floor4['Zone 3'])
    lightbank4_4.add_area(sdh_floor4['Zone 4'])
    lightbank4_5.add_area(sdh_floor4['Zone 5'])

    sdh_floor6 = gis.buildings['Sutardja Dai Hall']['Floor 6']
    lightbank6_1.add_area(sdh_floor6['Zone 1'])

    sdh_floor7 = gis.buildings['Sutardja Dai Hall']['Floor 7']
    lightbank7_1.add_area(sdh_floor7['Zone 1'])
    lightbank7_2.add_area(sdh_floor7['Zone 2'])
    lightbank7_3.add_area(sdh_floor7['Zone 3'])
    lightbank7_4.add_area(sdh_floor7['Zone 4'])

#Air Handler 1

hvac = Relational('HVAC')