[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
Re: [jdt-dev] RenameSupport
|
The method RenameSupport.perform(...) is of type 'void' so it returns nothing, but when I press 'Cancel' I get java.lang.InterruptedException. Can I safely assume that if I get InterruptedException that always means that the user pressed 'Cancel'? Because, if the case is different and the exception is result of something else I should handle it differently. If there are different possible reasons for InterruptedException exception, perhaps the method 'perform(...)' should throw different exception types - subclasses of InterruptedException, perhaps something like CancelPressedException and some others for the different cases ... Just a thought ...
Regrads,
S.
-----Original Message-----
From: jdt-dev-bounces@xxxxxxxxxxx [mailto:jdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Markus Keller
Sent: Tuesday, May 17, 2011 3:30 PM
To: Eclipse JDT general developers list.
Subject: Re: [jdt-dev] RenameSupport
Check the return value and the exceptions thrown by the RenameSupport
method you use. If it doesn't work as expected, please file a bug.
Note that "post-rename operations" are better implemented as a
RenameParticipant (then you don't have to deal with this situation).
HTH,
Markus
From:
"Dimov, Stefan" <stefan.dimov@xxxxxxx>
To:
"jdt-dev@xxxxxxxxxxx" <jdt-dev@xxxxxxxxxxx>
Date:
2011-05-17 13:14
Subject:
[jdt-dev] RenameSupport
Hi,
I?m using org.eclipse.jdt.ui.refactoring.RenameSupport in order to invoke
programmatically renaming of a method. It works, but if the class has some
compilation error, then a dialog appears, which warns the user that the
result might not be correct. This is ok, but I couldn?t figure out how to
get in my code if the user clicked ?Continue? or ?Cancel?. It?s necessary,
because my code has to perform some post-rename operations. Any clue?
Regrads,
Stefan
_______________________________________________
jdt-dev mailing list
jdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jdt-dev
_______________________________________________
jdt-dev mailing list
jdt-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/jdt-dev