when generating a web service client in netbeans 6.9 I would like the ability to dynamically load the soap endpoint url from a config (Properties) file (e.g. dev vrs production urls). How can I accomplish that as netbeans ask for a literal url and then hard codes that url into multiple objects.
Asked
Active
Viewed 315 times
1 Answers
0
URL url = this.getClass().getResource("/package/dir/propFile.properties");
prop = new Properties();
prop.load(new FileInputStream(new File(url.getFile())));

Piyush Mattoo
- 15,454
- 6
- 47
- 56
-
this would be greate, if the jax-rpc netbeans plugin didn't automatically generate hard coded url's :( – Lance Caraccioli Apr 04 '11 at 14:47