parameters: ()
return_statement: return projectSetting
docstring: @rtype: ProjectSetting
function: def getProjectSetting():
      """
      @rtype: ProjectSetting
      """
      global projectSetting
      if projectSetting != None:
          return projectSetting
  
      projectSetting = cache.get('anafora_project_setting')
      if projectSetting == None:
          parseFile = os.path.join(settings.ANAFORA_PROJECT_FILE_ROOT, settings.ANAFORA_PROJECT_SETTING_FILENAME)
          if os.path.isfile(parseFile) != True:
              from django.core.exceptions import ImpoperlyConfigured
              raise ImproperlyConfigured, "Error loading ANAFORA_PROJECT_SETTING_FILENAME in web/settings.py file. Please check the value of ANAFORA_PROJECT_FILE_ROOT, ANAFORA_PROJECT_SETTING_FILENAME accordingly"
          projectSetting = ProjectSetting()
          projectSetting.parseFromFile(parseFile)
          cache.set('anafora_project_setting', projectSetting)
  
      return projectSetting
function_tokens: def getProjectSetting ( ) : global projectSetting if projectSetting != None : return projectSetting projectSetting = cache . get ( 'anafora_project_setting' ) if projectSetting == None : parseFile = os . path . join ( settings . ANAFORA_PROJECT_FILE_ROOT , settings . ANAFORA_PROJECT_SETTING_FILENAME ) if os . path . isfile ( parseFile ) != True : from django . core . exceptions import ImpoperlyConfigured raise ImproperlyConfigured , "Error loading ANAFORA_PROJECT_SETTING_FILENAME in web/settings.py file. Please check the value of ANAFORA_PROJECT_FILE_ROOT, ANAFORA_PROJECT_SETTING_FILENAME accordingly" projectSetting = ProjectSetting ( ) projectSetting . parseFromFile ( parseFile ) cache . set ( 'anafora_project_setting' , projectSetting ) return projectSetting