views:

27

answers:

1

I'm debugging some xml returned from a URL and am using Eclipse's editor and XML validation to find problems. Currently that involves saving the XML returned from the URL and opening it in Eclipse, which is really tedious.

Is there a way to more directly load the contents of a URL into an editor window in Eclipse?

+1  A: 

Well, I think there's no direct way to load a URL's returned contents into a basic Eclipse IDE editor by default. Sure you can create an editor that handles this, but then you'll need to know Eclipse RCP :) Maybe there are some plugins that do the same, unfortunately I'm not aware of any.

If you save the contents to a file then open that file in Eclipse, validate it and then overwrite it from the outside of Eclipse and refresh the project, Eclipse will find out that the file was modified and needs to update it's contents inside the editor. This might save you some clicking time.

Or, why don't you create a small project/application that gets the contents, validates it and then saves the contents into a file? You open the response file with the XML, run the project and eclipse will update the file's contents (or at least show that it changed, so press F5). This might save some time as you don't have to switch back and forth from Eclipse and the command line/browser.

Tamás Mezei
Thanks for the tips. :)It's one of those things that I need to do it often enough and in different enough situations that it would be more work to automate it than to to deal with it manually. That is of course, unless something already exists.
Rog