[MXD2map-commits] r238:e672f5134d6e
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Tue Aug 9 12:06:19 CEST 2011
details: http://hg.intevation.org/geospatial/mxd2map/rev/e672f5134d6e
changeset: 238:e672f5134d6e
user: raimund renkert <raimund.renkert at intevation.de>
date: Mon Aug 08 17:06:17 2011 +0200
description:
Remove all non numeric chars from port string.
diffstat:
ChangeLog | 5 +++++
src/java/de/intevation/mxd/writer/MapScriptWriter.java | 15 ++++++++++++++-
2 files changed, 19 insertions(+), 1 deletions(-)
diffs (39 lines):
diff -r 4f6356a908e1 -r e672f5134d6e ChangeLog
--- a/ChangeLog Fri Aug 05 10:03:56 2011 +0200
+++ b/ChangeLog Mon Aug 08 17:06:17 2011 +0200
@@ -1,3 +1,8 @@
+2011-08-08 Raimund Renkert <raimund.renkert at intevation.de>
+
+ * src/java/de/intevation/mxd/writer/MapScriptWriter.java:
+ Remove all non numeric chars from port string.
+
2011-07-22 Stephan Holl <stephan.holl at intevation.de>
* website/download-de.htm4, website/index.htm4: repaired broken
diff -r 4f6356a908e1 -r e672f5134d6e src/java/de/intevation/mxd/writer/MapScriptWriter.java
--- a/src/java/de/intevation/mxd/writer/MapScriptWriter.java Fri Aug 05 10:03:56 2011 +0200
+++ b/src/java/de/intevation/mxd/writer/MapScriptWriter.java Mon Aug 08 17:06:17 2011 +0200
@@ -281,9 +281,22 @@
" Setting to \"sde\" as default.");
database_auth = "sde";
}
+
+ String port = layerElement.getAttribute("instance");
+ StringBuffer strBuff = new StringBuffer();
+ char c;
+
+ for (int j = 0; j < port.length() ; j++) {
+ c = port.charAt(j);
+
+ if(Character.isDigit(c)) {
+ strBuff.append(c);
+ }
+ }
+
layer.setConnection(
layerElement.getAttribute("server") + "," +
- "port:" + layerElement.getAttribute("instance") + "," +
+ "port:" + strBuff.toString() + "," +
database_auth + "," +
layerElement.getAttribute("user") + ",<PASSWORD>");
layer.setData(
More information about the MXD2map-commits
mailing list