Package gofer :: Package agent :: Module plugin :: Class PluginDescriptor
[hide private]
[frames] | no frames]

Class PluginDescriptor

source code

                     object --+            
                              |            
iniparse.config.ConfigNamespace --+        
                                  |        
             iniparse.ini.INIConfig --+    
                                      |    
                            config.Base --+
                                          |
                                         PluginDescriptor

Provides a plugin descriptor

Instance Methods [hide private]
list
__requires(self)
Get the list of declared required plugins.
source code
 
write(self)
Write the descriptor to the filesystem Written to: __path__.
source code

Inherited from config.Base: __init__

Inherited from iniparse.ini.INIConfig: __delitem__, __iter__, __setitem__, __str__, __unicode__

Inherited from iniparse.ini.INIConfig (private): _getitem, _new_namespace, _parse, _readfp

Inherited from iniparse.config.ConfigNamespace: __contains__, __delattr__, __getattr__, __getitem__, __setattr__, __setstate__

Inherited from object: __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __sizeof__, __subclasshook__

Class Methods [hide private]
 
__mkdir(cls) source code
list
load(cls)
Load the plugin descriptors.
source code
 
__list(cls) source code
list
__sort(cls, descriptors)
Sort descriptors based on defined dependencies.
source code
Class Variables [hide private]
  ROOT = '/etc/gofer/plugins'

Inherited from iniparse.ini.INIConfig (private): _bom, _data, _defaults, _line_types, _optionxformsource, _optionxformvalue, _parse_exc, _sections, _sectionxformsource, _sectionxformvalue

Properties [hide private]

Inherited from iniparse.ini.INIConfig (private): _optionxform, _sectionxform

Inherited from object: __class__

Method Details [hide private]

load(cls)
Class Method

source code 

Load the plugin descriptors.

Returns: list
A list of descriptors.

__sort(cls, descriptors)
Class Method

source code 

Sort descriptors based on defined dependencies. Dependencies defined by [main].requires

Parameters:
  • descriptors (list) - A list of descriptor tuples (name,descriptor)
Returns: list
The sorted list

__requires(self)

source code 

Get the list of declared required plugins.

Returns: list
A list of plugin names.