Override rename action in eclipse

≯℡__Kan透↙ 提交于 2019-12-10 17:19:18

问题


I am new to eclipse plugin development. I am in the need of overriding the rename dialog for the files in a specific custom project. Say I am having a file "sample.abcd" in the custom project that has its own perspectives, natures and builders. So whenever i try to rename this file, I am getting a rename dialog with the file extension. I want to override this dialog displaying only the file name just like a java project rename action does. Can you point me to any resource, how to do it ? Thanks


回答1:


You have to implement a rename refactoring participant. Its "enablement" condition specifies under which circumstances it shall be involved (you would have to check for your specific file extension).

A longer explanation can also be found in Eclipse rename/refactoring override.



来源:https://stackoverflow.com/questions/13173188/override-rename-action-in-eclipse

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!