Thursday, June 3, 2010

Test driving the Plug-in

Let's try out our newly installed spring plug-in. Did it work?

Yes! Under new, project, other, "Spring" appears. Instead of creating a new project, though, I'm going to convert the chapter 2 hello world project I imported to a spring project. Just right-click it and select "add spring project nature".

Ok, you have to do some monkeying around to actually see the spring view of a bean xml file.

First, right click project to get properties. There is a "Spring" section. On the right panel, click "enable project specific settings". There is a "Beans Support" entry. Click on that, and there you will see a whole "Beans Support" panel on the right. Just add your "beans.xml" to it, and you will now be able to right click on it and "show in" Spring Explorer.

Actually, that's a bit disappointing. It pretty much shows a node/value view of the bean. I pretty much prefer editing the vanilla text. But it may come in handy.

Also, if you right click on the root bean, you can see a dependency graph, which shows the beans in the xml and the beans which have been injected into them as a dependency graph.

The context-assist ctrl+space for property names in bean.xml didn't work for me...

And the bean property validation didn't work. Oh, well.

The main point is I got preview of a what and how to use the Spring plug-in. I don't think it will make a major difference, but I may be wrong.

No comments:

Post a Comment