Commits

Anonymous committed 3b99696

renamed "configDict" into "configMap" for cons

Comments (0)

Files changed (2)

 
 import cpg, thread, _cputil, _cpconfig, _cphttpserver, time
 
-def start(configFile = None, parsedConfigFile = None, configDict = {}, initOnly = 0):
+def start(configFile = None, parsedConfigFile = None, configMap = {}, initOnly = 0):
     """
         Main function. All it does is this:
             - read/parse config file if any
             - create response and request objects
-            - creates HTTP server based on configFile and configDict
+            - creates HTTP server based on configFile and configMap
             - start HTTP server
 
         Input: There are 2 ways to pass config options:
             - Let CherryPy parse a config file (configFile)
-            - Pass the options as a dictionary (configDict)
+            - Pass the options as a dictionary (configMap)
     """
 
     # cpg.configOption contains an EmptyClass instance with all the configuration option
     elif parsedConfigFile:
         _cpconfig.parseConfigFile(parsedConfigFile = parsedConfigFile)
 
-    if configDict:
-        for key, value in configDict.items():
+    if configMap:
+        for key, value in configMap.items():
             setattr(cpg.configOption, key, value)
 
     # Output config options
     # sys.path.append(r"C:\Tmp\PEAK\src")
     from wsgiref.simple_server import WSGIServer, WSGIRequestHandler
      # Read the CherryPy config file and initialize some variables
-    wsgiapp.init(configDict = {'socketPort': 8000, 'sessionStorageType': 'ram'})
+    wsgiapp.init(configMap = {'socketPort': 8000, 'sessionStorageType': 'ram'})
     server_address = ("", 8000)
     httpd = WSGIServer(server_address, WSGIRequestHandler)
     httpd.set_app(wsgiapp.wsgiApp)