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

Re: svn commit: r25253 - trunk/subversion/bindings/swig/ruby/svn

From: Kouhei Sutou <kou_at_cozmixng.org>
Date: 2007-06-02 03:48:19 CEST

Hi,

> Do we really want aliases here? Wouldn't changing the API names be
> sufficient?

Does it mean we only need mergeinfo and merge_info is
needless? If it's true, I can't agree with you. merge_info
is more Rubyish name rather than mergeinfo because many Ruby
scripts use '_' between words. Rubyist will use merge_info
not mergeinfo. mergeinfo exists just only for respecting
original Subversion API.

Thanks,

--
kou
> On Fri, 01 Jun 2007, joeswatosh@tigris.org wrote:
> 
> > Author: joeswatosh
> > Date: Fri Jun  1 06:08:26 2007
> > New Revision: 25253
> > 
> > Log:
> > keeping up with the merge_info to mergeinfo changes
> > 
> > * subversion/bindings/swig/ruby/svn/fs.rb
> >  new aliases mergeinfo for merge_info and change_mergeinfo for 
> >  change_merge_info
> >  (merge_info):
> >  call Fs.get_mergeinfo instead of Fs.get_merge_info.
> >  (change_merge_info):
> >  call Fs.change_mergeinfo instead of Fs.change_merge_info.
> > 
> > * subversion/bindings/swig/ruby/svn/ra.rb
> >  new aliases mergeinfo for merge_info
> >  (merge_info):
> >  call Ra.get_mergeinfo instead of Ra.get_merge_info.
> > 
> > * subversion/bindings/swig/ruby/svn/repos.rb
> >  (merge_info):
> >  call Repos.fs_get_mergeinfo instead of Repos.fs_get_merge_info.
> > 
> > 
> > Modified:
> >    trunk/subversion/bindings/swig/ruby/svn/fs.rb
> >    trunk/subversion/bindings/swig/ruby/svn/ra.rb
> >    trunk/subversion/bindings/swig/ruby/svn/repos.rb
> > 
> > Modified: trunk/subversion/bindings/swig/ruby/svn/fs.rb
> > URL: http://svn.collab.net/viewvc/svn/trunk/subversion/bindings/swig/ruby/svn/fs.rb?pathrev=25253&r1=25252&r2=25253
> > ==============================================================================
> > --- trunk/subversion/bindings/swig/ruby/svn/fs.rb	(original)
> > +++ trunk/subversion/bindings/swig/ruby/svn/fs.rb	Fri Jun  1 06:08:26 2007
> > @@ -498,12 +498,14 @@
> >  
> >        def merge_info(paths, include_parents=true)
> >          paths = [paths] unless paths.is_a?(Array)
> > -        Fs.get_merge_info(self, paths, include_parents)
> > +        Fs.get_mergeinfo(self, paths, include_parents)
> >        end
> > +      alias_method :mergeinfo, :merge_info
> >  
> >        def change_merge_info(path, info)
> > -        Fs.change_merge_info(self, path, info)
> > +        Fs.change_mergeinfo(self, path, info)
> >        end
> > +      alias_method :change_mergeinfo, :change_merge_info
> >      end
> >  
> >      History = SWIG::TYPE_p_svn_fs_history_t
> > 
> > Modified: trunk/subversion/bindings/swig/ruby/svn/ra.rb
> > URL: http://svn.collab.net/viewvc/svn/trunk/subversion/bindings/swig/ruby/svn/ra.rb?pathrev=25253&r1=25252&r2=25253
> > ==============================================================================
> > --- trunk/subversion/bindings/swig/ruby/svn/ra.rb	(original)
> > +++ trunk/subversion/bindings/swig/ruby/svn/ra.rb	Fri Jun  1 06:08:26 2007
> > @@ -247,7 +247,7 @@
> >        def merge_info(paths, revision=nil, include_parents=true)
> >          paths = [paths] unless paths.is_a?(Array)
> >          revision ||= Svn::Core::INVALID_REVNUM
> > -        info = Ra.get_merge_info(self, paths, revision, include_parents)
> > +        info = Ra.get_mergeinfo(self, paths, revision, include_parents)
> >          unless info.nil?
> >            info.each_key do |key|
> >              info[key] = Core::MergeInfo.new(info[key])
> > @@ -255,6 +255,7 @@
> >          end
> >          info
> >        end
> > +      alias_method :mergeinfo, :merge_info
> >  
> >        private
> >        def props_filter(props)
> > 
> > Modified: trunk/subversion/bindings/swig/ruby/svn/repos.rb
> > URL: http://svn.collab.net/viewvc/svn/trunk/subversion/bindings/swig/ruby/svn/repos.rb?pathrev=25253&r1=25252&r2=25253
> > ==============================================================================
> > --- trunk/subversion/bindings/swig/ruby/svn/repos.rb	(original)
> > +++ trunk/subversion/bindings/swig/ruby/svn/repos.rb	Fri Jun  1 06:08:26 2007
> > @@ -366,11 +366,12 @@
> >            paths = [path]
> >          end
> >          revision ||= Svn::Core::INVALID_REVNUM
> > -        results = Repos.fs_get_merge_info(self, paths, revision,
> > +        results = Repos.fs_get_mergeinfo(self, paths, revision,
> >                                            include_parents, authz_read_func)
> >          results = results[path] if path
> >          results
> >        end
> > +      alias_method :mergeinfo, :merge_info
> >  
> >        private
> >        def setup_report_baton(baton)
> > 
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: svn-unsubscribe@subversion.tigris.org
> > For additional commands, e-mail: svn-help@subversion.tigris.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sat Jun 2 03:48:37 2007

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.