Please note that there is an update to the plugin!
I started to implement a ReSharper plugin to support NHibernate mapping files. It runs with ReSharper 4.0 only, so you need to get one of the nightly EAP builds from here.
Please note that the plugin is in a very early state and far away from complete. What we have so far is analysis of .hbm.xml files:
- Name and type of mapped class is verified
- Id name and type is verified
- Property names and types are verified (not the access attribute!)
- many-to-one and one-to-one names and types are verified
- Component names and types are verified, including properties and nested components
- Subclass names are verified
Pease note that the access attribute is not evaluated, so mapped properties have to exist as a property in the mapped class. I will work on this next and will support the standard access methods like field.pascalcase-m-underscore.
After finishing the analysis stage I will start to implement features like navigation (for example from mapped property to mapping file), refactoring (support for rename class/property/field beeing the most wanted) and quick-fixes (for example map this property).
I will release the plugin as open source later. First I have to check many things with JetBrains (for example how to do automated unit tests) and have to clean up the code.
For those of you who can’t wait, here is the download link. You will find a little batch script that copies the plugin files. Please close VS2008 before copying.
Feel free to contact me for feedback, bug reports and feature requests.