On Jan 13, 7:04 pm, Christopher Lee <[email protected]> wrote:
> - by analogy to sys.path (an interface to PYTHONPATH), create a  
> pygr.Data.path object that acts as a list of the resource databases  
> (an interface to PYGRDATAPATH).

I am a little uncertain what a root.object meant in your post. I
assume it is a pygr.Data() class instance created the pygr module
namespace, that may have various attributes and methods. This implies
that we may ourselves create such instances that may be customized and
more importantly exist in a scope. It is probably best if the class
had a close() method that could be called explicitly and would close
all resources. This method should also be called from the destructor,
but that is not guaranteed to be called.

In general I think it would be best if we had the option of passing
the pygrdatapath as a parameter to the constructor and be able to
configure the instance upon construction. The default behavior would
be the same as now, reading out the 'PYGRDATAPATH' environment
variable.

The same with the namespaces and/or layers. Have a number of sane
names added by default, if someone wants different namespaces, they
can configure them either in the constructor or (if that gets too
overloaded) via some helper methods (of course that means turning off
the defaults as well).

> resource database from the list in pygr.Data.path, or create / open a  
> new resource database by calling an appropriate constructor.  The  
> interface for saving to a specific resource database object will be  
> the same as the generic interface.

I would need to see an example to understand and be able to comment
more meaningfully but it sounds good.

> - split the ResourceFinder class into separate pieces for storing the  
> list of resource databases (described above as pygr.Data.path); the  
> cache of currently loaded resources; the queue of resources that the  
> user has queued for saving but not yet committed.

I don't really know how this works internally, so I shouldn't say much
here.

Istvan
--~--~---------~--~----~------------~-------~--~----~
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