Thread View: borland.public.jbuilder.opentools
14 messages
14 total messages
Started by Jesper Sundien
Wed, 06 Apr 2005 13:54
jbuilder diff
Author: Jesper Sundien
Date: Wed, 06 Apr 2005 13:54
Date: Wed, 06 Apr 2005 13:54
8 lines
1028 bytes
1028 bytes
Hi, How can I access JBuilder's diff tool from within my OpenTool? I need to do a diff on two files and process the result. Thanks - Jesper
Re: jbuilder diff
Author: Bill Joy
Date: Thu, 07 Apr 2005 01:06
Date: Thu, 07 Apr 2005 01:06
19 lines
1484 bytes
1484 bytes
What "diff tool" are you talking about? The one in the History viewer is automatic if your VCS implementation handles the getRevisions() call. It should return a Vector with RevisionInfo instances. (There is also a VCS.getSource() which takes a RevisionInfo as a parameter.) "Jesper Sundien" <jesper.sundien@micronic.se> wrote in message news:4253ea07$1@newsgroups.borland.com... > Hi, > > How can I access JBuilder's diff tool from within my OpenTool? I need to > do a diff on two files and process the result. > > Thanks > > - Jesper >
Re: jbuilder diff
Author: Jesper Sundien
Date: Thu, 07 Apr 2005 06:23
Date: Thu, 07 Apr 2005 06:23
33 lines
1998 bytes
1998 bytes
I want to do a diff on two files (two revisions of a file) to be able to generate a new file that I can use in the Merge panel in the History view. What I wonder is if there is some way to access the diff engine JBuilder uses from within my OpenTool. Is there a method that takes for instance two (or three) Urls and returns the diff? Thanks -Jesper "Bill Joy" <wcjoy@pacbell.net> wrote in message news:42548796$1@newsgroups.borland.com... > What "diff tool" are you talking about? > > The one in the History viewer is automatic if your VCS implementation > handles the getRevisions() call. It should return a Vector with > RevisionInfo instances. (There is also a VCS.getSource() which takes a > RevisionInfo as a parameter.) > > > "Jesper Sundien" <jesper.sundien@micronic.se> wrote in message > news:4253ea07$1@newsgroups.borland.com... >> Hi, >> >> How can I access JBuilder's diff tool from within my OpenTool? I need to >> do a diff on two files and process the result. >> >> Thanks >> >> - Jesper >> > >
Re: jbuilder diff
Author: Shane Duan
Date: Thu, 07 Apr 2005 06:40
Date: Thu, 07 Apr 2005 06:40
17 lines
1628 bytes
1628 bytes
http://info.borland.com/techpubs/jbuilder/jbuilderx/opentools/ref/OpenToolsAPI/com/borland/primetime/util/Diff.html This is the API for JBuilderX. JBuilder2005 has quite a different but much nicer version of this class. Shane Jesper Sundien wrote: > I want to do a diff on two files (two revisions of a file) to be able to > generate a new file that I can use in the Merge panel in the History view. > What I wonder is if there is some way to access the diff engine JBuilder > uses from within my OpenTool. Is there a method that takes for instance two > (or three) Urls and returns the diff? > > Thanks > -Jesper > >
Re: jbuilder diff
Author: Jesper Sundien
Date: Thu, 07 Apr 2005 10:54
Date: Thu, 07 Apr 2005 10:54
25 lines
1902 bytes
1902 bytes
Thank you very much!! Too bad the Diff API for JBuilder2005 is undocumented.. -Jesper "Shane Duan" <shane.duan@gmail.com> wrote in message news:4254d5c9$1@newsgroups.borland.com... > http://info.borland.com/techpubs/jbuilder/jbuilderx/opentools/ref/OpenToolsAPI/com/borland/primetime/util/Diff.html > > This is the API for JBuilderX. JBuilder2005 has quite a different but > much nicer version of this class. > > Shane > > Jesper Sundien wrote: >> I want to do a diff on two files (two revisions of a file) to be able to >> generate a new file that I can use in the Merge panel in the History >> view. What I wonder is if there is some way to access the diff engine >> JBuilder uses from within my OpenTool. Is there a method that takes for >> instance two (or three) Urls and returns the diff? >> >> Thanks >> -Jesper >>
Re: jbuilder diff
Author: Shane Duan
Date: Thu, 07 Apr 2005 18:41
Date: Thu, 07 Apr 2005 18:41
41 lines
2714 bytes
2714 bytes
Hmm... I just noticed that this class was moved into diff package in JBuilder2005, making it out of the scope of PrimeTime OpenTools API. Not sure why, though. However, one of the reason that I said it was better was because the API was quite clear. JBuilder allows you to open up class files by showing the methods (without implementation). If you just open it up and poke around, you should be able to get a fairly good idea of it. I am actually working on a diff opentool for JBuilder, because side-by-side diff is so popular and useful nowadays and I am missing that while working with JBuilder. So make sure you check in to our project page (https://jbuilder-opentools.dev.java.net/) Wiki pages for additional updates and stuff. Jesper Sundien wrote: > Thank you very much!! Too bad the Diff API for JBuilder2005 is > undocumented.. > > -Jesper > > > "Shane Duan" <shane.duan@gmail.com> wrote in message > news:4254d5c9$1@newsgroups.borland.com... > >>http://info.borland.com/techpubs/jbuilder/jbuilderx/opentools/ref/OpenToolsAPI/com/borland/primetime/util/Diff.html >> >>This is the API for JBuilderX. JBuilder2005 has quite a different but >>much nicer version of this class. >> >>Shane >> >>Jesper Sundien wrote: >> >>>I want to do a diff on two files (two revisions of a file) to be able to >>>generate a new file that I can use in the Merge panel in the History >>>view. What I wonder is if there is some way to access the diff engine >>>JBuilder uses from within my OpenTool. Is there a method that takes for >>>instance two (or three) Urls and returns the diff? >>> >>>Thanks >>>-Jesper >>> > >
Re: jbuilder diff
Author: Jesper Sundien
Date: Fri, 08 Apr 2005 12:57
Date: Fri, 08 Apr 2005 12:57
60 lines
3365 bytes
3365 bytes
Thanks,
it seems to work now, but I get an exception while invoking the Diff.diff()
method:
java.lang.Exception
at com.borland.primetime.util.diff.Diff.a(Unknown Source)
at com.borland.primetime.util.diff.Diff.diff(Unknown Source)
at com.borland.primetime.util.diff.Diff.diff(Unknown Source)
I can still access the DiffMapEntries, any thoughts?
-Jesper
"Shane Duan" <shane.duan@gmail.com> wrote in message
news:42557ec8$1@newsgroups.borland.com...
> Hmm... I just noticed that this class was moved into diff package in
> JBuilder2005, making it out of the scope of PrimeTime OpenTools API. Not
> sure why, though.
>
> However, one of the reason that I said it was better was because the API
> was quite clear. JBuilder allows you to open up class files by showing
> the methods (without implementation). If you just open it up and poke
> around, you should be able to get a fairly good idea of it.
>
> I am actually working on a diff opentool for JBuilder, because
> side-by-side diff is so popular and useful nowadays and I am missing that
> while working with JBuilder. So make sure you check in to our project
> page (https://jbuilder-opentools.dev.java.net/) Wiki pages for additional
> updates and stuff.
>
> Jesper Sundien wrote:
>> Thank you very much!! Too bad the Diff API for JBuilder2005 is
>> undocumented..
>>
>> -Jesper
>>
>>
>> "Shane Duan" <shane.duan@gmail.com> wrote in message
>> news:4254d5c9$1@newsgroups.borland.com...
>>
>>>http://info.borland.com/techpubs/jbuilder/jbuilderx/opentools/ref/OpenToolsAPI/com/borland/primetime/util/Diff.html
>>>
>>>This is the API for JBuilderX. JBuilder2005 has quite a different but
>>>much nicer version of this class.
>>>
>>>Shane
>>>
>>>Jesper Sundien wrote:
>>>
>>>>I want to do a diff on two files (two revisions of a file) to be able to
>>>>generate a new file that I can use in the Merge panel in the History
>>>>view. What I wonder is if there is some way to access the diff engine
>>>>JBuilder uses from within my OpenTool. Is there a method that takes for
>>>>instance two (or three) Urls and returns the diff?
>>>>
>>>>Thanks
>>>>-Jesper
>>>>
>>
Re: jbuilder diff
Author: Shane Duan
Date: Fri, 08 Apr 2005 18:10
Date: Fri, 08 Apr 2005 18:10
19 lines
1654 bytes
1654 bytes
Odd. An "Exception" rather than anything specific? How did you invoke it, exactly? Jesper Sundien wrote: > Thanks, > it seems to work now, but I get an exception while invoking the Diff.diff() > method: > > java.lang.Exception > at com.borland.primetime.util.diff.Diff.a(Unknown Source) > at com.borland.primetime.util.diff.Diff.diff(Unknown Source) > at com.borland.primetime.util.diff.Diff.diff(Unknown Source) > > I can still access the DiffMapEntries, any thoughts? > > -Jesper > >
Re: jbuilder diff
Author: Jesper Sundien
Date: Mon, 11 Apr 2005 06:31
Date: Mon, 11 Apr 2005 06:31
37 lines
2286 bytes
2286 bytes
The Exeption is thrown while invoking: Diff diff = new Diff(); boolean b = diff.diff(new BufferedReader(new FileReader(file),new BufferedReader(new StringReader(string)))); When i examine the DiffMap (diff.getDiffMap()) it seems to contain the correct diff. Looks like the exeption is thrown in the private method 'a'. It is a non-specific "Exception" that is generated. Do I have to initialize or set-up the diff object before invoking the diff() method? /Jesper "Shane Duan" <shane.duan@gmail.com> wrote in message news:4256c922$1@newsgroups.borland.com... > Odd. An "Exception" rather than anything specific? > > How did you invoke it, exactly? > > Jesper Sundien wrote: >> Thanks, >> it seems to work now, but I get an exception while invoking the >> Diff.diff() method: >> >> java.lang.Exception >> at com.borland.primetime.util.diff.Diff.a(Unknown Source) >> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >> >> I can still access the DiffMapEntries, any thoughts? >> >> -Jesper >>
Re: jbuilder diff
Author: Shane Duan
Date: Mon, 11 Apr 2005 19:39
Date: Mon, 11 Apr 2005 19:39
24 lines
1927 bytes
1927 bytes
Is there anything printed out in the console while this happened? Other than that I really cannot explain why a non-specific exception was thrown. Jesper Sundien wrote: > The Exeption is thrown while invoking: > > Diff diff = new Diff(); > boolean b = diff.diff(new BufferedReader(new FileReader(file),new > BufferedReader(new StringReader(string)))); > > When i examine the DiffMap (diff.getDiffMap()) it seems to contain the > correct diff. Looks like the exeption is thrown in the private method 'a'. > > It is a non-specific "Exception" that is generated. > > Do I have to initialize or set-up the diff object before invoking the diff() > method? > > /Jesper > >
Re: jbuilder diff
Author: Bill Joy
Date: Tue, 12 Apr 2005 00:20
Date: Tue, 12 Apr 2005 00:20
49 lines
2892 bytes
2892 bytes
It indicates that you have not called Diff.setComparator() before doing the diff. There are two implementation classes provided (and you can write your own SequenceComparator implementation): OnpCompare and OldOnpCompare. If you do not choose, you get an exception and OldOnpCompare is used. "Jesper Sundien" <jesper.sundien@micronic.se> wrote in message news:425a19d0@newsgroups.borland.com... > The Exeption is thrown while invoking: > > Diff diff = new Diff(); > boolean b = diff.diff(new BufferedReader(new FileReader(file),new > BufferedReader(new StringReader(string)))); > > When i examine the DiffMap (diff.getDiffMap()) it seems to contain the > correct diff. Looks like the exeption is thrown in the private method 'a'. > > It is a non-specific "Exception" that is generated. > > Do I have to initialize or set-up the diff object before invoking the > diff() method? > > /Jesper > > > "Shane Duan" <shane.duan@gmail.com> wrote in message > news:4256c922$1@newsgroups.borland.com... >> Odd. An "Exception" rather than anything specific? >> >> How did you invoke it, exactly? >> >> Jesper Sundien wrote: >>> Thanks, >>> it seems to work now, but I get an exception while invoking the >>> Diff.diff() method: >>> >>> java.lang.Exception >>> at com.borland.primetime.util.diff.Diff.a(Unknown Source) >>> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >>> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >>> >>> I can still access the DiffMapEntries, any thoughts? >>> >>> -Jesper >>> >
Re: jbuilder diff
Author: Shane Duan
Date: Tue, 12 Apr 2005 01:02
Date: Tue, 12 Apr 2005 01:02
14 lines
1735 bytes
1735 bytes
Ah... Thanks Bill for explaining the mystery. Maybe Diff constructor should be changed to require a comparator, then? Bill Joy wrote: > It indicates that you have not called Diff.setComparator() before doing the > diff. > > There are two implementation classes provided (and you can write your own > SequenceComparator implementation): OnpCompare and OldOnpCompare. > > If you do not choose, you get an exception and OldOnpCompare is used. > >
Re: jbuilder diff
Author: Jesper Sundien
Date: Tue, 12 Apr 2005 06:17
Date: Tue, 12 Apr 2005 06:17
59 lines
3145 bytes
3145 bytes
Thank you very much! What is the difference between OnpCompare and OldOnpCompare? /Jesper "Bill Joy" <wcjoy@pacbell.net> wrote in message news:425b1433$1@newsgroups.borland.com... > It indicates that you have not called Diff.setComparator() before doing > the diff. > > There are two implementation classes provided (and you can write your own > SequenceComparator implementation): OnpCompare and OldOnpCompare. > > If you do not choose, you get an exception and OldOnpCompare is used. > > > "Jesper Sundien" <jesper.sundien@micronic.se> wrote in message > news:425a19d0@newsgroups.borland.com... >> The Exeption is thrown while invoking: >> >> Diff diff = new Diff(); >> boolean b = diff.diff(new BufferedReader(new FileReader(file),new >> BufferedReader(new StringReader(string)))); >> >> When i examine the DiffMap (diff.getDiffMap()) it seems to contain the >> correct diff. Looks like the exeption is thrown in the private method >> 'a'. >> >> It is a non-specific "Exception" that is generated. >> >> Do I have to initialize or set-up the diff object before invoking the >> diff() method? >> >> /Jesper >> >> >> "Shane Duan" <shane.duan@gmail.com> wrote in message >> news:4256c922$1@newsgroups.borland.com... >>> Odd. An "Exception" rather than anything specific? >>> >>> How did you invoke it, exactly? >>> >>> Jesper Sundien wrote: >>>> Thanks, >>>> it seems to work now, but I get an exception while invoking the >>>> Diff.diff() method: >>>> >>>> java.lang.Exception >>>> at com.borland.primetime.util.diff.Diff.a(Unknown Source) >>>> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >>>> at com.borland.primetime.util.diff.Diff.diff(Unknown Source) >>>> >>>> I can still access the DiffMapEntries, any thoughts? >>>> >>>> -Jesper >>>> >> > >
Re: jbuilder diff
Author: Shane Duan
Date: Tue, 12 Apr 2005 16:35
Date: Tue, 12 Apr 2005 16:35
11 lines
1699 bytes
1699 bytes
As the name indicates, the earlier version uses the algorithm in OldOnpCompare, which has some issues. When JBuilder diff was redesigned, this algorithm was rewritten into OnpCompare. O(np) Compare is a diff algorithm that you should be able to find on the internet. Jesper Sundien wrote: > Thank you very much! What is the difference between OnpCompare and > OldOnpCompare? > > /Jesper >
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads