Mercurial > dive4elements > river
comparison backend/src/main/java/org/dive4elements/river/importer/ImportTimeInterval.java @ 8856:5e38e2924c07 3.2.x
Fix code style.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Thu, 18 Jan 2018 20:12:01 +0100 |
parents | 4c3ccf2b0304 |
children | 0a5239a1e46e |
comparison
equal
deleted
inserted
replaced
8855:d7c005e12af0 | 8856:5e38e2924c07 |
---|---|
74 this.stopTime = stopTime; | 74 this.stopTime = stopTime; |
75 } | 75 } |
76 | 76 |
77 public TimeInterval getPeer() { | 77 public TimeInterval getPeer() { |
78 if (peer == null) { | 78 if (peer == null) { |
79 Session session = ImporterSession.getInstance().getDatabaseSession(); | 79 Session session = ImporterSession.getInstance() |
80 .getDatabaseSession(); | |
80 if (startTime == null) { | 81 if (startTime == null) { |
81 log.error("Null Start time will be ignored."); | 82 log.error("Null Start time will be ignored."); |
82 } | 83 } |
83 Query query; | 84 Query query; |
84 if (stopTime == null) { | 85 if (stopTime == null) { |
85 query = session.createQuery( | 86 query = session.createQuery( |
86 "from TimeInterval where startTime=:a and stopTime is null"); | 87 "from TimeInterval " |
88 + "where startTime=:a and stopTime is null"); | |
87 } | 89 } |
88 else { | 90 else { |
89 query = session.createQuery( | 91 query = session.createQuery( |
90 "from TimeInterval where startTime=:a and stopTime=:b"); | 92 "from TimeInterval where startTime=:a and stopTime=:b"); |
91 query.setParameter("b", stopTime); | 93 query.setParameter("b", stopTime); |