changeset 5564:a2da78fdbec0

Removed obsolete imports.
author Sascha L. Teichmann <teichmann@intevation.de>
date Fri, 05 Apr 2013 08:59:35 +0200 (2013-04-05)
parents 673f68bb19a4
children a44a3f997ec8
files flys-backend/src/main/java/de/intevation/flys/backend/SessionFactoryProvider.java flys-backend/src/main/java/de/intevation/flys/importer/parsers/SedimentDensityParser.java
diffstat 2 files changed, 13 insertions(+), 24 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/src/main/java/de/intevation/flys/backend/SessionFactoryProvider.java	Thu Apr 04 18:15:35 2013 +0200
+++ b/flys-backend/src/main/java/de/intevation/flys/backend/SessionFactoryProvider.java	Fri Apr 05 08:59:35 2013 +0200
@@ -1,16 +1,7 @@
 package de.intevation.flys.backend;
 
-import java.lang.management.ManagementFactory;
-
 import java.util.Properties;
 
-import javax.management.InstanceAlreadyExistsException;
-import javax.management.MBeanRegistrationException;
-import javax.management.MBeanServer;
-import javax.management.MalformedObjectNameException;
-import javax.management.NotCompliantMBeanException;
-import javax.management.ObjectName;
-
 import org.apache.log4j.Logger;
 
 import org.hibernate.SessionFactory;
@@ -20,14 +11,12 @@
 
 import org.hibernate.impl.SessionFactoryImpl;
 
-import org.hibernate.jmx.StatisticsService;
-
 public final class SessionFactoryProvider
 {
     private static Logger log = Logger.getLogger(SessionFactoryProvider.class);
 
-    public static final boolean ENABLE_JMX =
-        Boolean.getBoolean("flys.backend.enablejmx");
+    //public static final boolean ENABLE_JMX =
+    //    Boolean.getBoolean("flys.backend.enablejmx");
 
     private static SessionFactory flysSessionFactory;
     private static SessionFactory sedDBSessionFactory;
@@ -66,19 +55,22 @@
 
         SessionFactory factory = cfg.buildSessionFactory();
 
+        /*
         if (ENABLE_JMX) {
             registerAsMBean(factory);
         }
         else {
             log.info("No JMX support for hibernate.");
         }
+        */
 
         return factory;
     }
 
+    /** XXX: Commented out till it is configured correctly.
     public static void registerAsMBean(SessionFactory factory) {
 
-        /* XXX: Commented out till it is configured correctly.
+        // 
 
         StatisticsService statsMBean = new StatisticsService();
         statsMBean.setSessionFactory(factory);
@@ -104,8 +96,8 @@
         catch (NotCompliantMBeanException ncmbe) {
             log.warn(ncmbe, ncmbe);
         }
-        */
     }
+    */
 
     public static Configuration createConfiguration() {
         return createConfiguration(FLYSCredentials.getInstance());
@@ -116,7 +108,7 @@
     ) {
         Configuration cfg = new Configuration();
 
-        for (Class clazz: credentials.getClasses()) {
+        for (Class<?> clazz: credentials.getClasses()) {
             cfg.addAnnotatedClass(clazz);
         }
 
--- a/flys-backend/src/main/java/de/intevation/flys/importer/parsers/SedimentDensityParser.java	Thu Apr 04 18:15:35 2013 +0200
+++ b/flys-backend/src/main/java/de/intevation/flys/importer/parsers/SedimentDensityParser.java	Fri Apr 05 08:59:35 2013 +0200
@@ -1,5 +1,9 @@
 package de.intevation.flys.importer.parsers;
 
+import de.intevation.flys.importer.ImportDepth;
+import de.intevation.flys.importer.ImportSedimentDensity;
+import de.intevation.flys.importer.ImportSedimentDensityValue;
+
 import java.io.File;
 import java.io.IOException;
 
@@ -9,20 +13,13 @@
 import java.text.ParseException;
 
 import java.util.ArrayList;
-import java.util.Calendar;
-import java.util.Date;
 import java.util.List;
+
 import java.util.regex.Matcher;
 import java.util.regex.Pattern;
 
 import org.apache.log4j.Logger;
 
-import de.intevation.flys.importer.ImportDepth;
-import de.intevation.flys.importer.ImportSedimentDensity;
-import de.intevation.flys.importer.ImportSedimentDensityValue;
-import de.intevation.flys.utils.DateGuesser;
-
-
 public class SedimentDensityParser extends LineParser {
 
     private static final Logger log =

http://dive4elements.wald.intevation.org