comparison gnv-artifacts/src/main/java/de/intevation/gnv/utils/WKTUtils.java @ 778:9a828e5a2390

Removed trailing whitespace gnv-artifacts/trunk@851 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Sascha L. Teichmann <sascha.teichmann@intevation.de>
date Mon, 29 Mar 2010 07:58:51 +0000
parents 0563389138bb
children 2cea76f1112e
comparison
equal deleted inserted replaced
777:8009961db1cb 778:9a828e5a2390
120 .append(')'); 120 .append(')');
121 return sb.toString(); 121 return sb.toString();
122 } 122 }
123 123
124 public static final String indexBox( 124 public static final String indexBox(
125 java.awt.Point a, 125 java.awt.Point a,
126 java.awt.Point b, 126 java.awt.Point b,
127 String iName, 127 String iName,
128 String jName 128 String jName
129 ) { 129 ) {
130 int minI = Math.min(a.x, b.x) - 1; 130 int minI = Math.min(a.x, b.x) - 1;
171 171
172 ArrayList<Object []> missingPoints = 172 ArrayList<Object []> missingPoints =
173 new ArrayList<Object []>(); 173 new ArrayList<Object []>();
174 174
175 createIJKPoints(coords, meshid, ijkQueryID, points, missingPoints); 175 createIJKPoints(coords, meshid, ijkQueryID, points, missingPoints);
176 176
177 String additionWhere = null; 177 String additionWhere = null;
178 178
179 if (missingPoints.size() == coords.length) { 179 if (missingPoints.size() == coords.length) {
180 log.debug("cannot create index buffer"); 180 log.debug("cannot create index buffer");
181 } 181 }
209 List<java.awt.Point> points = new ArrayList<java.awt.Point>(coords.length); 209 List<java.awt.Point> points = new ArrayList<java.awt.Point>(coords.length);
210 210
211 ArrayList<Object []> missingPoints = new ArrayList<Object []>(); 211 ArrayList<Object []> missingPoints = new ArrayList<Object []>();
212 212
213 createIJKPoints(coords, meshid, ijkQueryID, points, missingPoints); 213 createIJKPoints(coords, meshid, ijkQueryID, points, missingPoints);
214 214
215 String additionWhere = TRUE_EXPRESSION; 215 String additionWhere = TRUE_EXPRESSION;
216 216
217 if (missingPoints.size() == coords.length) { 217 if (missingPoints.size() == coords.length) {
218 log.debug("cannot create index buffer"); 218 log.debug("cannot create index buffer");
219 } 219 }
222 coords, points, missingPoints); 222 coords, points, missingPoints);
223 223
224 if (!remainsMissingPoints) { 224 if (!remainsMissingPoints) {
225 // TODO: Make Tablenames and Columns Configurable 225 // TODO: Make Tablenames and Columns Configurable
226 IndexBuffer ib = new IndexBuffer( 226 IndexBuffer ib = new IndexBuffer(
227 points, 227 points,
228 I_NAME, 228 I_NAME,
229 J_NAME ); 229 J_NAME );
230 additionWhere = ib.toWhereClause(); 230 additionWhere = ib.toWhereClause();
231 log.debug("Additional Where Clause = "+additionWhere); 231 log.debug("Additional Where Clause = "+additionWhere);
232 } 232 }
233 } // if generate index filter 233 } // if generate index filter
308 String meshid, 308 String meshid,
309 String ijkQueryID, 309 String ijkQueryID,
310 List<java.awt.Point> points, 310 List<java.awt.Point> points,
311 ArrayList<Object []> missingPoints 311 ArrayList<Object []> missingPoints
312 ) 312 )
313 throws QueryException 313 throws QueryException
314 { 314 {
315 boolean debug = log.isDebugEnabled(); 315 boolean debug = log.isDebugEnabled();
316 316
317 QueryExecutor queryExecutor = QueryExecutorFactory 317 QueryExecutor queryExecutor = QueryExecutorFactory
318 .getInstance() 318 .getInstance()
319 .getQueryExecutor(); 319 .getQueryExecutor();
320 320
321 for (int i = 0; i < coords.length; i++) { 321 for (int i = 0; i < coords.length; i++) {
322 322
323 String wkt = toWKT(coords[i]); 323 String wkt = toWKT(coords[i]);
324 324
325 Collection<Result> result = queryExecutor.executeQuery( 325 Collection<Result> result = queryExecutor.executeQuery(

http://dive4elements.wald.intevation.org