On Sat, Dec 20, 2008 at 08:16:03AM -0800, C. Titus Brown wrote:
-> 
-> On Fri, Dec 19, 2008 at 05:58:14PM -0800, Istvan Albert wrote:
-> -> On Dec 19, 6:03 pm, Christopher Lee <[email protected]> wrote:
-> -> 
-> -> > - I'd like to keep the interface for accessing this as simple as
-> -> > possible, e.g. to access the namespace object, the user need do
-> -> > nothing more than type
-> -> > from pygr import Data
-> -> > I guess you were suggesting a two step process to access the namespace
-> -> > object:
-> -> > import pygr
-> -> > data = pygr.Data()
-> -> 
-> -> Maybe it could be made even be simpler than the way it currently
-> -> works. Meaning that the default pygr.Data instance is constructed upon
-> -> importing pygr. One may use that in most cases or make their own with
-> -> some aptly named and customizable constructor. For example the default
-> -> Data would in fact correspond to an initialization like this:
-> -> 
-> -> Data = pygr.DataPath( rcfile='.pygrdata', namespaces=["Bio", "Test"],
-> -> layers=["my", "here"] ) ()
-> 
-> This makes sense to me, too.  It would also help in testing pygr.Data,
-> because you wouldn't be at the mercy of the import framework details for
-> reloading/mocking/stubbing.
-> 
-> Unfortunately, you can't do
-> 
->      from pygr.Data.x.y.z import a
-> 
-> if pygr.Data is not a module, though :(.  There may be a way around
-> this, but I haven't run across it; does anyone know?

Err, now that I think about it pygr already does something like this...

--t
-- 
C. Titus Brown, [email protected]

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"pygr-dev" 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/pygr-dev?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to