parameters: (name, value=None)
return_statement: return value
docstring: Returns content of a configuration variable. It will first search in user defined configuration.
      If it can't find it it will go into settings file and finaly constant variables provided with
      Booktype source.
  
      @type name: C{string}
      @param: Name of the variable
  
      @type value: C{object}
      @param: Default value if it can't find defined variable.
  
      @type: C{object}
      @return: Returns the content of the variable
docstring_summary: Returns content of a configuration variable. It will first search in user defined configuration.
      If it can't find it it will go into settings file and finaly constant variables provided with
      Booktype source.
docstring_tokens: Returns content of a configuration variable . It will first search in user defined configuration . If it can t find it it will go into settings file and finaly constant variables provided with Booktype source .
function: def get_configuration(name, value=None):
      """
      Returns content of a configuration variable. It will first search in user defined configuration.
      If it can't find it it will go into settings file and finaly constant variables provided with
      Booktype source.
  
      @type name: C{string}
      @param: Name of the variable
  
      @type value: C{object}
      @param: Default value if it can't find defined variable.
  
      @type: C{object}
      @return: Returns the content of the variable
      """
  
      # Check if we have it in the configuration file
      if hasattr(settings, 'BOOKTYPE_CONFIG'):
          try:
              settings.BOOKTYPE_CONFIG = load_configuration()
          except ConfigurationError:
              pass
  
          if settings.BOOKTYPE_CONFIG is not None and name in settings.BOOKTYPE_CONFIG:
              return settings.BOOKTYPE_CONFIG[name]
  
      # Check if we have it in the settings file
      if hasattr(settings, name):
          return getattr(settings, name)
  
      if hasattr(constants, name):
          return getattr(constants, name)
  
      return value
function_tokens: def get_configuration ( name , value = None ) : # Check if we have it in the configuration file if hasattr ( settings , 'BOOKTYPE_CONFIG' ) : try : settings . BOOKTYPE_CONFIG = load_configuration ( ) except ConfigurationError : pass if settings . BOOKTYPE_CONFIG is not None and name in settings . BOOKTYPE_CONFIG : return settings . BOOKTYPE_CONFIG [ name ] # Check if we have it in the settings file if hasattr ( settings , name ) : return getattr ( settings , name ) if hasattr ( constants , name ) : return getattr ( constants , name ) return value