Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/server/CollectionItemAttributeServiceImpl.java @ 1425:bc06a671ef60
Removed the URL parameter from service calls. The service
implementations read the URL from the web.xml config file now.
flys-client/trunk@3367 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Raimund Renkert <raimund.renkert@intevation.de> |
---|---|
date | Thu, 08 Dec 2011 09:12:27 +0000 |
parents | ab8eb2f544f2 |
children | 4a6814be92ba |
comparison
equal
deleted
inserted
replaced
1424:8974e220b193 | 1425:bc06a671ef60 |
---|---|
46 | 46 |
47 | 47 |
48 public CollectionItemAttribute getCollectionItemAttribute( | 48 public CollectionItemAttribute getCollectionItemAttribute( |
49 Collection collection, | 49 Collection collection, |
50 String artifact, | 50 String artifact, |
51 String url, | |
52 String locale) | 51 String locale) |
53 throws ServerException | 52 throws ServerException |
54 { | 53 { |
55 logger.info( | 54 logger.info( |
56 "CollectionItemAttributeServiceImpl.getCollectionItemAttribute"); | 55 "CollectionItemAttributeServiceImpl.getCollectionItemAttribute"); |
56 | |
57 String url = getServletContext().getInitParameter("server-url"); | |
57 | 58 |
58 Document requestDoc = XMLUtils.newDocument(); | 59 Document requestDoc = XMLUtils.newDocument(); |
59 | 60 |
60 XMLUtils.ElementCreator ec = new XMLUtils.ElementCreator( | 61 XMLUtils.ElementCreator ec = new XMLUtils.ElementCreator( |
61 requestDoc, | 62 requestDoc, |
91 | 92 |
92 | 93 |
93 public void setCollectionItemAttribute( | 94 public void setCollectionItemAttribute( |
94 Collection collection, | 95 Collection collection, |
95 String artifact, | 96 String artifact, |
96 String url, | |
97 String locale, | 97 String locale, |
98 CollectionItemAttribute attributes) | 98 CollectionItemAttribute attributes) |
99 throws ServerException | 99 throws ServerException |
100 { | 100 { |
101 logger.info( | 101 logger.info( |
102 "CollectionItemAttributeServiceImpl.setCollectionItemAttribute"); | 102 "CollectionItemAttributeServiceImpl.setCollectionItemAttribute"); |
103 | |
104 String url = getServletContext().getInitParameter("server-url"); | |
103 | 105 |
104 Document doc = writeXML(attributes, artifact); | 106 Document doc = writeXML(attributes, artifact); |
105 | 107 |
106 try { | 108 try { |
107 HttpClient client = new HttpClientImpl(url, locale); | 109 HttpClient client = new HttpClientImpl(url, locale); |