On 2011-07-28 at 14:11:19, Peter Suter wrote:
> ...
>> How about naming?  I presume all the trac.* namespace belongs to the
>> Trac project (core, wiki, etc.).
>
> Right.
> 
>> Is there a guide for creating new namespace?
> I'm not aware of a guide specific to Trac. There are probably many
> guides for namespaces (in Python) in general.
> 
>> Can I start a tracpm (Trac project management) top level and
>> build in it?  (Is the "trac" prefix there redundant?
> 
> I'd say just pick something similar to you plugin name, or anything
you
> think will not conflict with other plugins or common Python libraries.
> http://www.google.com/search?q="import+tracpm"+or+"from+tracpm"; comes
up
> empty, so that seems safe.
> ...

Still looking for a good model, I see
http://trac.edgewall.org/wiki/TracDev/PluginDevelopment/ExtensionPoints
mentions
trac.db.api.IDatabaseConnector and the source (line 176 of
http://trac.edgewall.org/browser/trunk/trac/db/api.py) says:

  class IDatabaseConnector(Interface):

So where does the namespace (trac.db.api) that prefixes the function
name come from?

-- 
You received this message because you are subscribed to the Google Groups "Trac 
Development" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/trac-dev?hl=en.

Reply via email to