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

Re: JavaHL info2 problem

From: Mark Phippard <markphip_at_gmail.com>
Date: Tue, 28 Aug 2012 13:18:58 -0400

On Tue, Aug 28, 2012 at 1:14 PM, Marcin Porwit <mporwit_at_salesforce.com> wrote:

> I'm calling the non-deprecated version of info2:
> http://subversion.apache.org/docs/javahl/1.7/org/tigris/subversion/javahl/SVNClientInterface.html#info2(java.lang.String, org.tigris.subversion.javahl.Revision, org.tigris.subversion.javahl.Revision, int, java.lang.String[], org.tigris.subversion.javahl.InfoCallback)
>
> You're right in that it looks like it is treating the URL as a local file system path… and yes, I'm passing in null for both the Revsion and pegRevision arguments. What should I be passing in instead? The svn info from the command line does not take a revision -- does it pass one in implicitly?

Yes. The command line is implicitly passing Revision.HEAD for both of
those arguments. I would also pass Depth.Empty for the depth.

The first call to the API that gives you the URL, should also give you
the Revision of the item in the working copy. It would be safer to
use that Revision object for the revision and pegRevision. That way
if the item has been renamed/deleted or moved in the HEAD revision
your API call will still work correctly.

-- 
Thanks
Mark Phippard
http://markphip.blogspot.com/
Received on 2012-08-28 19:19:30 CEST

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

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