[Zope-PAS] using plugins programmatically

Janko Hauser jhauser at zscout.de
Mon Feb 7 08:06:54 EST 2005


Lennart Regebro schrieb:
> Janko Hauser wrote:
>
>>Another question regarding PAS. As I understand it, the plugins
>>mechanism is mainly used for TTW configuration.
>
>>The current path to use PAS in code is:
>
> "Use"?
>
>>- instantiate a PAS instance, which automatically instantiates the
>>  pluginregistry.
>>
>>- import the addmethods of the plugins one likes to use
>>
>>- add these plugins
>>
>>- configure the plugins to register themself for the various
>>  interfaces.
>>
>>So in the code I use the plugin-mechanism only in the last step. Is
>>this the right way, or do I miss something?
>
>
> Are you trying to create and configure a PAS instance programatically?
> Is that what you mean with "use"? In that casse, I would say yes, thats
> the way to do it.
>
Yes, sorry, I had written this in the mail before. I'm adding a PAS
in the code, which sets up a site. I have managed this. In the code it
all looked rather explicit, and I had the feeling, that I bypassing
the plugin mechanism somehow. So I asked.

Thanks for the confirmation.

__Janko




More information about the Zope-PAS mailing list