[MERGE] key-length GraphIndex adapter

Robert Collins robertc at robertcollins.net
Thu Aug 9 06:51:09 BST 2007


On Thu, 2007-08-09 at 00:10 -0400, Aaron Bentley wrote:


> > It does add a uniform prefix to keys
> 
> - From the perspective of a caller, the prefix will never appear in the
> output.  So from that perspective, it is stripping the prefix.
> 
> > I'd like the name to:
> >  - indicate that it implements the GraphIndex protocol (its not a plain
> > Index - it is Graph aware)
> >  - indicate that its not an index on its own, rather an adapter to tweak
> > the behaviour of another index
> > 
> > I'm happy to add Filtering or Filtered to the name...
> > GraphIndexPrefixFilteringAdapter ?



> I think that legibility is suffering for the sake of total accuracy.

PrefixFilteredIndexAdapter? is what you suggested, and I'd be
comfortable with PrefixFilteredGraphIndexAdapter. The reason I don't
want to use PrefixFilteredIndexAdapter is that there is room to have a
class PrefixFilteredIndexAdapter which deals with simple indices -
key:value only, which will be faster than the GraphIndex code in the
current class.

> >>   That might actually
> >> be sensible, if you were trying to make knit/weave repos provide an
> >> interface similar to pack-based repos.
> > 
> > The adapter is used to provide a knit interface to pack based repos, so
> > it is exactly that, though the other way around from what you
> > suggest :).
> 
> I knew what it was for.

Perhaps I misunderstood what you were meaning then?

-Rob
-- 
GPG key available at: <http://www.robertcollins.net/keys.txt>.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part
Url : https://lists.ubuntu.com/archives/bazaar/attachments/20070809/ecbcd2a2/attachment.pgp 


More information about the bazaar mailing list