Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Implement Interface Refactor Snippet required

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
andre.horst Posted - Mar 02 2011 : 08:19:14 AM
There is no editable code snippet for the refactor "Implement Interface". The default creates an implementation like

throw std::exception("The method or operation is not implemented.") ;

but i want to change this code.

Btw: The "Implement Interface" Window does not show "<" or ">" of template return values and it is not visible which methods already implemented.
6   L A T E S T    R E P L I E S    (Newest First)
sean Posted - Mar 16 2016 : 12:04:55 AM
case=55728 is fixed in build 2093
support Posted - Mar 17 2011 : 11:45:22 PM
case=55727 is fixed in build 1845
feline Posted - Mar 03 2011 : 11:28:30 AM
I did wonder about visibility with Implement Interface, since there are always going to be cases where you want a different / unexpected visibility. But asking VA to do something that seems reasonable by default seems fair. Then for the cases that are different VA Outline should be able to help.

You make a good point about the visibility of the inheritance, I have put a note onto the case about this, thank you
andre.horst Posted - Mar 03 2011 : 04:24:46 AM
Thanks for the quick reply.

Oh, yes there is the snippet, thank you.

Yes, I use WinXP SP3 and you are right Ii can not select the list-items.

The angle brackets are also wrong in method arguments , but the reason for the problem is probably the same.

I am not sure if the original visibility in the inheritance is the right way to implement it, because I can inherit a whole "public" interface as "protected" for example. Therefor the visibility of the inheritance should be the most important thing.
feline Posted - Mar 02 2011 : 11:32:05 PM
Implement Interface uses the VA Snippet "Refactor Create From Usage Method Body", so you can simply edit this snippet.

Which OS are you using? The dialog should show already implemented methods greyed out, but fails to do so under winXP. But you are unable to select them, which is something.

I am seeing the problem with angle brackets and a template return type:

case=55727

Public methods becoming private, it looks like the implemented methods are simply placed at the end of the class, so they end up with what ever visibility this position gives them. So I have put in a feature request to respect the visibility of the original virtual methods:

case=55728

For now you can use VA Outline to re-order the declarations in the class, to give them the required visibility.
andre.horst Posted - Mar 02 2011 : 08:22:18 AM
There was another point I was wondering about I just forgot to tell. If I inherit "public" the methods are placed in the "private" section. This would be nice if I had inherited "private". I would not call the actual behavior a bug, but a change request.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000