Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/server/GetArtifactServiceImpl.java @ 229:924da6695800
Each service is now called with the name of the current locale to set the request object's locale manually in the HttpClient.
flys-client/trunk@1681 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 14 Apr 2011 07:53:01 +0000 |
parents | f03c34bec364 |
children | ab8eb2f544f2 |
comparison
equal
deleted
inserted
replaced
228:bbe32496dc84 | 229:924da6695800 |
---|---|
34 public static final String XPATH_RESULT = "/art:result/text()"; | 34 public static final String XPATH_RESULT = "/art:result/text()"; |
35 | 35 |
36 public static final String OPERATION_FAILURE = "FAILED"; | 36 public static final String OPERATION_FAILURE = "FAILED"; |
37 | 37 |
38 | 38 |
39 public Artifact getArtifact(String serverUrl, String uuid, String hash) | 39 public Artifact getArtifact( |
40 String url, | |
41 String locale, | |
42 String uuid, | |
43 String hash) | |
40 throws ServerException | 44 throws ServerException |
41 { | 45 { |
46 System.out.println("GetArtifactServiceImpl.getArtifact"); | |
47 | |
42 Document describe = ClientProtocolUtils.newDescribeDocument( | 48 Document describe = ClientProtocolUtils.newDescribeDocument( |
43 uuid, hash, true); | 49 uuid, hash, true); |
44 | 50 |
45 HttpClient client = new HttpClientImpl(serverUrl); | 51 HttpClient client = new HttpClientImpl(url, locale); |
46 | 52 |
47 try { | 53 try { |
48 Document description = (Document) client.describe( | 54 Document description = (Document) client.describe( |
49 new de.intevation.artifacts.httpclient.objects.Artifact( | 55 new de.intevation.artifacts.httpclient.objects.Artifact( |
50 uuid, hash), | 56 uuid, hash), |