annotate gwt-client/src/main/java/org/dive4elements/river/client/server/DeleteCollectionServiceImpl.java @ 8203:238fc722f87a

sed 's/logger/log/g' src/**/*.java
author Sascha L. Teichmann <teichmann@intevation.de>
date Fri, 05 Sep 2014 13:19:22 +0200
parents ea9eef426962
children 0a5239a1e46e
rev   line source
5861
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
1 /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
2 * Software engineering by Intevation GmbH
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
3 *
5993
ea9eef426962 Removed trailing whitespace.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5861
diff changeset
4 * This file is Free Software under the GNU AGPL (>=v3)
5861
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out the
5993
ea9eef426962 Removed trailing whitespace.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5861
diff changeset
6 * documentation coming with Dive4Elements River for details.
5861
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
7 */
172338b1407f GWT client: Added copyright header.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
8
5835
821a02bbfb4e Fixed internal java dependencies
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5834
diff changeset
9 package org.dive4elements.river.client.server;
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
10
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
11 import org.w3c.dom.Document;
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
12
1367
ab8eb2f544f2 Replaced stdout and stderr logging with log4j loggers in server classes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 599
diff changeset
13 import org.apache.log4j.Logger;
ab8eb2f544f2 Replaced stdout and stderr logging with log4j loggers in server classes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 599
diff changeset
14
5835
821a02bbfb4e Fixed internal java dependencies
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5834
diff changeset
15 import org.dive4elements.artifacts.common.utils.ClientProtocolUtils;
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
16
5835
821a02bbfb4e Fixed internal java dependencies
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5834
diff changeset
17 import org.dive4elements.river.client.shared.exceptions.ServerException;
821a02bbfb4e Fixed internal java dependencies
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5834
diff changeset
18 import org.dive4elements.river.client.shared.model.Collection;
821a02bbfb4e Fixed internal java dependencies
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5834
diff changeset
19 import org.dive4elements.river.client.client.services.DeleteCollectionService;
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
20
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
21
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
22 /**
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
23 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a>
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
24 */
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
25 public class DeleteCollectionServiceImpl
599
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
26 extends DoCollectionAction
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
27 implements DeleteCollectionService
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
28 {
8203
238fc722f87a sed 's/logger/log/g' src/**/*.java
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5993
diff changeset
29 private static final Logger log =
1367
ab8eb2f544f2 Replaced stdout and stderr logging with log4j loggers in server classes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 599
diff changeset
30 Logger.getLogger(DeleteCollectionServiceImpl.class);
ab8eb2f544f2 Replaced stdout and stderr logging with log4j loggers in server classes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 599
diff changeset
31
ab8eb2f544f2 Replaced stdout and stderr logging with log4j loggers in server classes.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 599
diff changeset
32
599
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
33 public static final String XPATH_RESULT = "/art:result/text()";
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
34 public static final String OPERATION_FAILURE = "FAILED";
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
35
1425
bc06a671ef60 Removed the URL parameter from service calls. The service
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1367
diff changeset
36 public void delete(Collection c)
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
37 throws ServerException
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
38 {
8203
238fc722f87a sed 's/logger/log/g' src/**/*.java
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5993
diff changeset
39 log.info("Delete collection: " + c.identifier());
599
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
40
1425
bc06a671ef60 Removed the URL parameter from service calls. The service
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1367
diff changeset
41 String url = getServletContext().getInitParameter("server-url");
bc06a671ef60 Removed the URL parameter from service calls. The service
Raimund Renkert <raimund.renkert@intevation.de>
parents: 1367
diff changeset
42
599
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
43 Document del = ClientProtocolUtils.newDeleteCollectionDocument();
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
44
1dbffe4c6d12 Implemented the RPC stubs to set the TTL and name of a collection and to delete an existing collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 598
diff changeset
45 doAction(c, del, url);
598
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
46 }
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
47 }
031357c3e23e Added stubs to set the name and ttl of a collection and to delete a collection.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
48 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org