o ckF[— ã@sNdZddlZddlZddlZGdd„deƒZd dd„Zdd„Zd a d d „Z dS) a Implements plugin related api. To define a new plugin just subclass Plugin, like this. class AuthPlugin(Plugin): pass Then start creating subclasses of your new plugin. class MyFancyAuth(AuthPlugin): capability = ['sign', 'vmac'] The actual interface is duck typed. éNc@s eZdZdZgZedd„ƒZdS)ÚPluginzBase class for all plugins.cCs|D] }||jvr dSqdS)zMReturns true if the requested capability is supported by this plugin FT)Ú capability)ÚclsÚrequested_capabilityÚc©rú-/usr/lib/python3/dist-packages/boto/plugin.pyÚ is_capable1s  ÿzPlugin.is_capableN)Ú__name__Ú __module__Ú __qualname__Ú__doc__rÚ classmethodr rrrrr,s rcCs2|sg}g}| ¡D] }| |¡r| |¡q |S©N)Ú__subclasses__r Úappend)rrÚresultÚhandlerrrrÚ get_plugin;s   €rcCsftj |¡\}}tj |¡\}}t ||g¡\}}}zt ||||¡W|r*| ¡SS|r2| ¡wwr)ÚosÚpathÚsplitÚsplitextÚimpÚ find_moduleÚ load_moduleÚclose)ÚfilenamerÚnameÚextÚfileÚdatarrrÚ_import_moduleEs ÿ ÿr"FcCsNtrdSda| dd¡sdS| dd¡}t tj |d¡¡D]}t|ƒqdS)NTrÚplugin_directoryz*.py)Ú_plugin_loadedÚ has_optionÚgetÚglobrrÚjoinr")ÚconfigÚ directoryr rrrÚ load_pluginsSs   ÿr+r) r r'rÚos.pathrÚobjectrrr"r$r+rrrrÚs