[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: delta_dirs(), meet delta_dirs()

From: C. Michael Pilato <cmpilato_at_collab.net>
Date: 2006-03-09 17:52:33 CET

Malcolm Rowe wrote:
>>So, +1 on reimplementing svn_repos_dir_delta() in terms of the reporter
>>code if you can. If you can't, we'll deprecate it and replace its only
>>two known uses with a new, concise function that just drives an editor
>>like a 'checkout' of a transaction would.
>>
>
>
> The latter sounds like an excellent idea, though I'm not _entirely_
> sure what the concise function you're talking about would look like
> (though that's probably because I don't understand what mod_dav_svn is
> doing with it).

It'd look more like a generic tree walker:

   def do_dir(path):
      entries = svn_fs_dir_entries(path)
      for entry in entries:
         do_stuff(path + / + entry)
      if is_dir(path + / + entry)
         do_dir(path + / + entry)

There'd be no "delta" code, as there's nothing to compare against. So
all the "is this child from txn A also in txn B?" stuff from dir_delta
is gone, as is all the "are we ignoring ancestry?" stuff, and ... well,
the code would just get much, much simpler.

As was pointed out, though, there might be folks depending on the
svn_repos_dir_delta API though, so removing it might not be a viable option.

-- 
C. Michael Pilato <cmpilato@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand

Received on Thu Mar 9 17:56:31 2006

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.