← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 2423: Minor fixed

 

------------------------------------------------------------
revno: 2423
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2010-10-22 18:27:16 +0200
message:
  Minor fixed
modified:
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java
  dhis-2/dhis-api/src/main/java/org/hisp/dhis/i18n/I18nFormat.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/hibernate/HibernateDataElementStore.java
  dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java
  dhis-2/dhis-support/dhis-support-external/src/main/java/org/hisp/dhis/external/configuration/DefaultConfigurationManager.java
  dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/dbms/HibernateDbmsManager.java
  dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/database/HibernateDatabaseInfoProvider.java


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java	2010-10-14 08:14:12 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/dataelement/DataElementCategoryOptionCombo.java	2010-10-22 16:27:16 +0000
@@ -35,7 +35,6 @@
 import java.util.Set;
 
 import org.apache.commons.lang.StringEscapeUtils;
-import org.apache.commons.lang.StringUtils;
 import org.hisp.dhis.common.IdentifiableObject;
 import org.hisp.dhis.dimension.DimensionOption;
 import org.hisp.dhis.dimension.DimensionOptionElement;

=== modified file 'dhis-2/dhis-api/src/main/java/org/hisp/dhis/i18n/I18nFormat.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/i18n/I18nFormat.java	2010-10-21 11:06:26 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/i18n/I18nFormat.java	2010-10-22 16:27:16 +0000
@@ -31,12 +31,10 @@
 import java.text.DateFormatSymbols;
 import java.text.ParseException;
 import java.text.SimpleDateFormat;
-import java.util.Calendar;
 import java.util.Date;
 import java.util.ResourceBundle;
 
 import org.hisp.dhis.period.Period;
-import org.hisp.dhis.period.QuarterlyPeriodType;
 
 /**
  * @author Pham Thi Thuy

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/hibernate/HibernateDataElementStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/hibernate/HibernateDataElementStore.java	2010-10-22 08:42:25 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/dataelement/hibernate/HibernateDataElementStore.java	2010-10-22 16:27:16 +0000
@@ -497,6 +497,8 @@
         }
     }
 
+    @Override
+    @SuppressWarnings("unchecked")
     public Collection<DataElement> getAllDataElements( int from, int to )
     {
         Session session = sessionFactory.getCurrentSession();
@@ -512,14 +514,6 @@
 
     public int getNumberOfDataElements()
     {
-        // Session session = sessionFactory.getCurrentSession();
-        //
-        // Criteria criteria = session.createCriteria( DataElement.class );
-        // criteria.setCacheable( true );
-        // criteria.setProjection( Projections.rowCount() ).uniqueResult();
-        //
-        // return ((Number) criteria).intValue();
-
         String sql = "select count(*) from DataElement";
         Query query = sessionFactory.getCurrentSession().createQuery( sql );
         Number countResult = (Number) query.uniqueResult();
@@ -527,13 +521,12 @@
         return countResult.intValue();
     }
 
-    @Override
     public int countNumberOfSearchDataElementByName( String key )
     {
         return searchDataElementByName( key ).size();
     }
 
-    @Override
+    @SuppressWarnings("unchecked")
     public Collection<DataElement> searchDataElementByName( String key, int from, int to )
     {
         Session session = sessionFactory.getCurrentSession();

=== modified file 'dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java'
--- dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java	2010-10-05 11:04:35 +0000
+++ dhis-2/dhis-services/dhis-service-core/src/main/java/org/hisp/dhis/user/hibernate/HibernateUserStore.java	2010-10-22 16:27:16 +0000
@@ -117,12 +117,12 @@
 
         return session.createQuery( "from User" ).list();
     }
-    
+
+    @SuppressWarnings( "unchecked" )
     public Collection<User> getAllUsers( int from, int to )
     {
         Session session = sessionFactory.getCurrentSession();
 
-
         return session.createQuery( "from User" ).setFirstResult( from ).setMaxResults( to ).list();
     }
 

=== modified file 'dhis-2/dhis-support/dhis-support-external/src/main/java/org/hisp/dhis/external/configuration/DefaultConfigurationManager.java'
--- dhis-2/dhis-support/dhis-support-external/src/main/java/org/hisp/dhis/external/configuration/DefaultConfigurationManager.java	2010-09-17 12:11:18 +0000
+++ dhis-2/dhis-support/dhis-support-external/src/main/java/org/hisp/dhis/external/configuration/DefaultConfigurationManager.java	2010-10-22 16:27:16 +0000
@@ -31,8 +31,6 @@
 import java.io.InputStream;
 import java.io.OutputStream;
 
-import org.springframework.stereotype.Component;
-
 import com.thoughtworks.xstream.XStream;
 
 /**

=== modified file 'dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/dbms/HibernateDbmsManager.java'
--- dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/dbms/HibernateDbmsManager.java	2010-09-17 12:11:18 +0000
+++ dhis-2/dhis-support/dhis-support-hibernate/src/main/java/org/hisp/dhis/dbms/HibernateDbmsManager.java	2010-10-22 16:27:16 +0000
@@ -34,7 +34,6 @@
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.jdbc.BadSqlGrammarException;
 import org.springframework.jdbc.core.JdbcTemplate;
-import org.springframework.stereotype.Component;
 
 /**
  * @author Lars Helge Overland

=== modified file 'dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/database/HibernateDatabaseInfoProvider.java'
--- dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/database/HibernateDatabaseInfoProvider.java	2010-09-17 12:11:18 +0000
+++ dhis-2/dhis-support/dhis-support-system/src/main/java/org/hisp/dhis/system/database/HibernateDatabaseInfoProvider.java	2010-10-22 16:27:16 +0000
@@ -32,7 +32,6 @@
 import org.hibernate.cfg.Configuration;
 import org.hisp.dhis.hibernate.HibernateConfigurationProvider;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Component;
 
 /**
  * @author Lars Helge Overland