← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 20445: Commons, javadoc

 

------------------------------------------------------------
revno: 20445
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Thu 2015-10-01 16:47:02 +0200
message:
  Commons, javadoc
modified:
  dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/AppendingHashMap.java
  dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/EnumMapWrapper.java
  dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/MimicingHashMap.java
  dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/util/PageRange.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-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/AppendingHashMap.java'
--- dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/AppendingHashMap.java	2015-06-16 17:57:23 +0000
+++ dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/AppendingHashMap.java	2015-10-01 14:47:02 +0000
@@ -44,6 +44,14 @@
      */
     private static final long serialVersionUID = 2579976271277075017L;
 
+    /**
+     * Appends the content of the value the existing content when 
+     * inserted, or inserts as usual if no entries match the key.
+     * 
+     * @param key the key.
+     * @param value the value.
+     * @return the new value.
+     */
     @Override
     public String put( K key, String value )
     {

=== modified file 'dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/EnumMapWrapper.java'
--- dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/EnumMapWrapper.java	2015-06-15 13:44:20 +0000
+++ dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/EnumMapWrapper.java	2015-10-01 14:47:02 +0000
@@ -50,6 +50,12 @@
         this.map = map;
     }
     
+    /**
+     * Gets the value with the given key.
+     * 
+     * @param key the key.
+     * @return the value.
+     */
     public T getValue( String key )
     {
         return map.get( Enum.valueOf( enumType, key ) );

=== modified file 'dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/MimicingHashMap.java'
--- dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/MimicingHashMap.java	2015-06-16 17:57:23 +0000
+++ dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/collection/MimicingHashMap.java	2015-10-01 14:47:02 +0000
@@ -38,6 +38,12 @@
 public class MimicingHashMap<K, V>
     extends HashMap<K, V>
 {
+    /**
+     * Returns the given key.
+     * 
+     * @param key the key.
+     * @return the given key.
+     */
     @Override
     @SuppressWarnings( "unchecked" )
     public V get( Object key )

=== modified file 'dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/util/PageRange.java'
--- dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/util/PageRange.java	2015-10-01 13:14:27 +0000
+++ dhis-2/dhis-support/dhis-support-commons/src/main/java/org/hisp/dhis/commons/util/PageRange.java	2015-10-01 14:47:02 +0000
@@ -67,12 +67,24 @@
         this.values = values;
     }
     
+    /**
+     * Sets page size.
+     * 
+     * @param pageSize the page size.
+     * @return this object.
+     */
     public PageRange setPageSize( int pageSize )
     {
         this.pageSize = pageSize;
         return this;
     }
     
+    /**
+     * Sets number of pages.
+     * 
+     * @param pages the number of pages.
+     * @return this object.
+     */
     public PageRange setPages( int pages )
     {
         this.pageSize = (int) Math.ceil( (double) values / pages );