Package conary :: Module conarycfg :: Class ConaryConfiguration
[hide private]
[frames] | no frames]

Class ConaryConfiguration

source code

    lib.cfg._Config --+        
                      |        
     lib.cfg.ConfigFile --+    
                          |    
lib.cfg.SectionedConfigFile --+
                              |
                             ConaryConfiguration

Nested Classes [hide private]
  _defaultSectionType
Conary uses context to let the value of particular config parameters be set based on a keyword that can be set at the command line.
Instance Methods [hide private]
 
__init__(self, readConfigFiles=False, ignoreErrors=False, readProxyValuesFirst=True)
Initialize a ConaryConfiguration object
source code
 
_getProxies(self) source code
 
readEntitlementDirectory(self) source code
 
readFiles(self) source code
 
setContext(self, name)
Copy the config values from the context named name (if any) into the main config file.
source code
 
getContext(self, name) source code
 
displayContext(self, out=None) source code
 
_writeSection(self, name, options)
Determine whether to write the given section
source code
 
requireInstallLabelPath(self) source code
 
_resetSigMap(self) source code
 
initializeFlavors(self)
Initialize flavor preferences based on files typically found in /etc/conary/arch (archDirs) and /etc/conary/use
source code

Inherited from lib.cfg.SectionedConfigFile: addConfigOption, configLine, getSection, hasSection, includeConfigFile, iterSectionNames, iterSections, read, readUrl, setSection

Inherited from lib.cfg.SectionedConfigFile (private): _addSection, _write

Inherited from lib.cfg.ConfigFile: configKey, ignoreUrlIncludes, isUrl, limitToKeys, readObject, setIgnoreErrors

Inherited from lib.cfg.ConfigFile (private): _openPath, _openUrl

Inherited from lib.cfg._Config: __contains__, __getitem__, __setitem__, addAlias, addDirective, addListener, display, displayKey, getDefaultValue, getDisplayOption, isDefault, items, iteritems, iterkeys, itervalues, keys, resetToDefault, setDisplayOptions, setValue, store, storeKey, values, writeToFile

Inherited from lib.cfg._Config (private): _initDisplayOptions, _writeKey

Class Methods [hide private]
Class Variables [hide private]
  _allowNewSections = True

Inherited from lib.cfg.SectionedConfigFile (private): _cfgTypes

Inherited from lib.cfg._Config (private): _keyLocation, _optionParams

Method Details [hide private]

__init__(self, readConfigFiles=False, ignoreErrors=False, readProxyValuesFirst=True)
(Constructor)

source code 
Initialize a ConaryConfiguration object
Parameters:
  • readConfigFiles (bool) - If True, read /etc/conaryrc and entitlements files
  • ignoreErrors (bool) - If True, ParseError exceptions will not be raised
  • readProxyValuesFirst (bool) - If True, parse local config files for proxy settings and apply them before further configuration.
Raises:
  • ParseError - Raised if configuration syntax is invalid and ignoreErrors is False.
Overrides: lib.cfg.SectionedConfigFile.__init__

_getProxies(self)

source code 
Overrides: lib.cfg.ConfigFile._getProxies

setContext(self, name)

source code 
Copy the config values from the context named name (if any) into the main config file. Returns False if not such config file found.

_writeSection(self, name, options)

source code 
Determine whether to write the given section
Overrides: lib.cfg.SectionedConfigFile._writeSection
(inherited documentation)

initializeFlavors(self)

source code 
Initialize flavor preferences based on files typically found in /etc/conary/arch (archDirs) and /etc/conary/use
Raises:
  • RuntimeError - Raised if use flags conflict in a way which cannot be reconciled (see deps.DependencyClass.MergeFlags)