comparison flys-client/src/main/java/de/intevation/flys/client/server/ArtifactServiceImpl.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 fba76f4afca9
comparison
equal deleted inserted replaced
1424:8974e220b193 1425:bc06a671ef60
26 26
27 /** 27 /**
28 * Creates new Artifacts based on a given Recommendation and factory. 28 * Creates new Artifacts based on a given Recommendation and factory.
29 * <b>Note, that all the work is done in ArtifactHelper!</b> 29 * <b>Note, that all the work is done in ArtifactHelper!</b>
30 * 30 *
31 * @param serverUrl The URL of the ArtifactServer.
32 * @param locale The locale used for HTTP request. 31 * @param locale The locale used for HTTP request.
33 * @param factory The factory that is used to create the new Artifact. 32 * @param factory The factory that is used to create the new Artifact.
34 * 33 *
35 * @return a new Artifact. 34 * @return a new Artifact.
36 */ 35 */
37 public Artifact create( 36 public Artifact create(
38 String serverUrl,
39 String locale, 37 String locale,
40 String factory, 38 String factory,
41 Recommendation recom 39 Recommendation recom
42 ) 40 )
43 throws ServerException 41 throws ServerException
44 { 42 {
45 logger.info("ArtifactServiceImpl.create"); 43 logger.info("ArtifactServiceImpl.create");
46 44
47 return ArtifactHelper.createArtifact(serverUrl, locale, factory, recom); 45 String url = getServletContext().getInitParameter("server-url");
46
47 return ArtifactHelper.createArtifact(url, locale, factory, recom);
48 } 48 }
49 } 49 }
50 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : 50 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org