'''
Created on Nov 20, 2011
Modified on Aug 31, 2012
@version: 0.11
@author: Dilum Bandara
@email: dilumb@engr.colostate.edu
@copyright: Copyright(c) 2011, Dilum Bandara
@license: GPL
'''

from DES import DES
from LPHash import LPHash
from ReadData import ReadData
import Config


APPS = {}           #Application layer for both weather stations & end users
OVERLAY = {}        #List of peers
UNDERLAY = {}       #List of underlay nodes
BOOTSTRAP = []      #List of overlay nodes to used for bootstrapping
pendingNodes = []   #Nodes pending to be added to overlay

EVENTS = DES() #Discrete event engine
HASH = LPHash(Config.SENSOR_NAMES, Config.NUM_DIMENSIONS, Config.NUM_BITS, \
                 Config.SIZE_TORUS, Config.SFC_MAP_FILE)

IN_DATA = ReadData(Config.W_STATION_FILE, Config.S_READING_FILE, \
                   Config.QUERY_FILE) #Input data

advStart = -1   #Time that advertising sensors will start
queStart = -1   #Time that issuing queries will start