annotate artifacts/src/main/java/org/dive4elements/river/artifacts/model/AnnotationsFactory.java @ 5863:4897a58c8746

River artifacts: Added new copyright headers.
author Sascha L. Teichmann <teichmann@intevation.de>
date Sun, 28 Apr 2013 14:40:59 +0200
parents 5aa05a7a34b7
children af13ceeba52a
rev   line source
5863
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
1 /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
2 * Software engineering by Intevation GmbH
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
3 *
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
4 * This file is Free Software under the GNU AGPL (>=v3)
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out the
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
6 * documentation coming with Dive4Elements River for details.
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
7 */
4897a58c8746 River artifacts: Added new copyright headers.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
8
5831
bd047b71ab37 Repaired internal references
Sascha L. Teichmann <teichmann@intevation.de>
parents: 4048
diff changeset
9 package org.dive4elements.river.artifacts.model;
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
10
1031
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
11 import java.math.BigDecimal;
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
12
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
13 import java.util.List;
644
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
14 import java.util.Iterator;
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
15 import java.util.Collections;
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
16
5831
bd047b71ab37 Repaired internal references
Sascha L. Teichmann <teichmann@intevation.de>
parents: 4048
diff changeset
17 import org.dive4elements.river.backend.SessionHolder;
bd047b71ab37 Repaired internal references
Sascha L. Teichmann <teichmann@intevation.de>
parents: 4048
diff changeset
18 import org.dive4elements.river.model.Annotation;
bd047b71ab37 Repaired internal references
Sascha L. Teichmann <teichmann@intevation.de>
parents: 4048
diff changeset
19 import org.dive4elements.river.model.River;
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
20
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
21 import org.hibernate.Session;
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
22 import org.hibernate.Query;
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
23
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
24 /**
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
25 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a>
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
26 */
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
27 public class AnnotationsFactory {
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
28
1031
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
29 /**
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
30 * Get Annotations which do not have a "b" ("to")-value set.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
31 *
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
32 * @param river name of the river of interest.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
33 *
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
34 * @return List of Annotations for river which have only "a" ("from")
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
35 * value set.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
36 */
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
37 public static List<Annotation> getPointAnnotations(String river) {
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
38 Session session = SessionHolder.HOLDER.get();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
39
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
40 Query query = session.createQuery(
1925
01f2473e362d Fixed flys/411 (Oracle max expressions for annotations query).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1924
diff changeset
41 "from Annotation as an " +
01f2473e362d Fixed flys/411 (Oracle max expressions for annotations query).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1924
diff changeset
42 "where an.range.b = null and an.range.river.name=:name " +
01f2473e362d Fixed flys/411 (Oracle max expressions for annotations query).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1924
diff changeset
43 "order by range.a");
01f2473e362d Fixed flys/411 (Oracle max expressions for annotations query).
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1924
diff changeset
44 query.setParameter("name", river);
1031
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
45 return query.list();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
46 }
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
47
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
48
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
49 public static List<Annotation> getAnnotations(River river) {
311
ea3a438a7021 Backend access: Static methods are using the SessionHolder, too.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 301
diff changeset
50 Session session = SessionHolder.HOLDER.get();
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
51
311
ea3a438a7021 Backend access: Static methods are using the SessionHolder, too.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 301
diff changeset
52 Query query = session.createQuery(
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
53 "from Annotation as an where an.range.river = :river" +
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
54 " order by an.range.a");
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
55 query.setParameter("river", river);
311
ea3a438a7021 Backend access: Static methods are using the SessionHolder, too.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 301
diff changeset
56 return query.list();
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
57 }
644
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
58
2063
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
59
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
60 public static Annotation getAnnotation(String river, double km) {
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
61 Session session = SessionHolder.HOLDER.get();
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
62
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
63 Query query = session.createQuery(
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
64 "from Annotation as a " +
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
65 "where a.range.river.name = :river AND a.range.a = :km");
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
66
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
67 query.setParameter("river", river);
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
68 query.setParameter("km", BigDecimal.valueOf(km));
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
69
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
70 List<Annotation> result = query.list();
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
71
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
72 return result != null && result.size() > 0 ? result.get(0) : null;
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
73 }
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
74
97a25b54eea3 Part 1 of #125: added a description for a location to the WaterlevelExport.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 1925
diff changeset
75
1031
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
76 /**
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
77 * Get minimal "a" ("from") and maximal "b" ("to") value of annotations'
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
78 * ranges of a river.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
79 *
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
80 * @param river name of the river of interest.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
81 *
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
82 * @return Array containing minimal "a" and max "b" value of any
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
83 * annotation stored for the given river.
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
84 */
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
85 public static double[] getAnnotationsBreadth(String river) {
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
86 Session session = SessionHolder.HOLDER.get();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
87
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
88 Query minAQuery = session.createQuery(
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
89 "select min(a), max(b) from Range where river.name=:name");
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
90 minAQuery.setParameter("name", river);
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
91
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
92 double[] minAmaxB = {0.0f, 0.0f};
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
93 Object[] row = (Object[]) minAQuery.list().iterator().next();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
94 minAmaxB[0] = ((BigDecimal) row[0]).doubleValue();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
95 minAmaxB[1] = ((BigDecimal) row[1]).doubleValue();
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
96 return minAmaxB;
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
97 }
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
98
bcef54a563ea Added functionality to query range and point-annotations only to
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 644
diff changeset
99
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
100 public static Iterator<Annotation> getAnnotationsIterator(
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
101 String riverName
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
102 ) {
644
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
103 Session session = SessionHolder.HOLDER.get();
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
104
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
105 Query riverQuery = session.createQuery(
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
106 "from River where name = :name");
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
107 riverQuery.setParameter("name", riverName);
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
108 List<River> rivers = riverQuery.list();
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
109 if (rivers.isEmpty()) {
3785
a5f65e8983be Merged revisions 5501-5502,5504-5508,5511-5513,5516-5519 via svnmerge from
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents: 2063
diff changeset
110 return Collections.<Annotation>emptyList().iterator();
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
111 }
644
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
112
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
113 Query query = session.createQuery(
1924
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
114 "from Annotation as an" +
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
115 " where an.range.river = :river order by an.range.a");
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
116 query.setParameter("river", rivers.get(0));
57b03b3ab15c Optimize query to fix annotations fetching on oracle, by Sascha Teichmann.
Felix Wolfsteller <felix.wolfsteller@intevation.de>
parents: 1031
diff changeset
117
644
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
118 return (Iterator<Annotation>)query.iterate();
02c0cce0e469 Introduce a cache for the distance-info service
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 332
diff changeset
119 }
301
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
120 }
1a00cb4998a8 Implemented a service that retrieves distance information for a specific river.
Ingo Weinzierl <ingo.weinzierl@intevation.de>
parents:
diff changeset
121 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :

http://dive4elements.wald.intevation.org