diff artifacts/src/main/java/org/dive4elements/river/artifacts/states/HWSBarriersState.java @ 8202:e4606eae8ea5

sed src/**/*.java 's/logger/log/g'
author Sascha L. Teichmann <teichmann@intevation.de>
date Fri, 05 Sep 2014 12:58:17 +0200
parents a56fe3bc6700
children 5e38e2924c07
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/states/HWSBarriersState.java	Fri Sep 05 12:54:58 2014 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/states/HWSBarriersState.java	Fri Sep 05 12:58:17 2014 +0200
@@ -37,8 +37,8 @@
 extends DefaultState
 {
 
-    /** The logger that is used in this class.*/
-    private static Logger logger = Logger.getLogger(HWSBarriersState.class);
+    /** The log that is used in this class.*/
+    private static Logger log = Logger.getLogger(HWSBarriersState.class);
     private static final String HWS_SHAPEFILE_LINES = "hws-lines.shp";
     private static final String HWS_SHAPEFILE_POINTS = "hws-points.shp";
 
@@ -83,7 +83,7 @@
         File artifactDir = getDirectory(artifact);
 
         if (artifactDir == null) {
-            logger.error("Could not create directory for HWS shapefile!");
+            log.error("Could not create directory for HWS shapefile!");
             return null;
         }
 
@@ -166,7 +166,7 @@
                                 proj.indexOf("\"]]"));
                     }
                     else {
-                        logger.warn("Could not read EPSG code from shapefile.");
+                        log.warn("Could not read EPSG code from shapefile.");
                         return null;
                     }
                     if (type.contains("Line")) {
@@ -188,7 +188,7 @@
                         FloodMapState.WSPLGEN_USER_RGD);
                 }
                 catch (IOException e) {
-                    logger.warn("No mapfile for user-rgd created!");
+                    log.warn("No mapfile for user-rgd created!");
                 }
             }
         }
@@ -198,7 +198,7 @@
     private boolean extractUserShp(File dir) {
         File archive = new File(dir, FloodMapState.WSPLGEN_USER_RGD_ZIP);
         boolean exists = archive.exists();
-        logger.debug("Zip file exists: " + exists);
+        log.debug("Zip file exists: " + exists);
         if (exists) {
             try {
                 File tmpDir = new File(dir, "usr_tmp");
@@ -207,7 +207,7 @@
                 return true;
             }
             catch (IOException ioe) {
-                logger.warn("Zip archive " + dir + "/"
+                log.warn("Zip archive " + dir + "/"
                     + FloodMapState.WSPLGEN_USER_RGD_ZIP + " could not be extracted.");
                 return false;
             }
@@ -241,7 +241,7 @@
                         FileTools.copyFile(file, new File(target, FloodMapState.WSPLGEN_USER_RGD + "." + suffix));
                     }
                     catch (IOException ioe) {
-                        logger.warn ("Error while copying file " + file.getName());
+                        log.warn ("Error while copying file " + file.getName());
                         return true;
                     }
                 }
@@ -256,7 +256,7 @@
     @Override
     public void endOfLife(Artifact artifact, Object callContext) {
         super.endOfLife(artifact, callContext);
-        logger.info("ScenarioSelect.endOfLife: " + artifact.identifier());
+        log.info("ScenarioSelect.endOfLife: " + artifact.identifier());
 
         D4EArtifact flys = (D4EArtifact) artifact;
         removeDirectory(flys);
@@ -275,14 +275,14 @@
         File artifactDir = new File(shapePath, artifact.identifier());
 
         if (artifactDir.exists()) {
-            logger.debug("Delete directory: " + artifactDir.getAbsolutePath());
+            log.debug("Delete directory: " + artifactDir.getAbsolutePath());
             boolean success = FileTools.deleteRecursive(artifactDir);
             if (!success) {
-                logger.warn("could not remove dir '" + artifactDir + "'");
+                log.warn("could not remove dir '" + artifactDir + "'");
             }
         }
         else {
-            logger.debug("There is no directory to remove.");
+            log.debug("There is no directory to remove.");
         }
     }
 

http://dive4elements.wald.intevation.org