[ 
https://issues.apache.org/jira/browse/COLLECTIONS-767?focusedWorklogId=496075&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-496075
 ]

ASF GitHub Bot logged work on COLLECTIONS-767:
----------------------------------------------

                Author: ASF GitHub Bot
            Created on: 06/Oct/20 17:57
            Start Date: 06/Oct/20 17:57
    Worklog Time Spent: 10m 
      Work Description: Amita-Pradhan commented on a change in pull request 
#188:
URL: 
https://github.com/apache/commons-collections/pull/188#discussion_r500490142



##########
File path: src/main/java/org/apache/commons/collections4/MapBuilder.java
##########
@@ -0,0 +1,115 @@
+package org.apache.commons.collections4;
+
+import org.apache.commons.collections4.map.HashedMap;
+
+import java.util.*;
+
+/**
+ * Defines an Helper Builder that generates a {@code Map}
+ * A Builder class to help decide which type of map to use based on simple 
requirements.
+ * Currently It takes care of only basic types of Maps and can be extended to 
different types of Maps available in the ecosystem.
+ *
+ * <pre>{@code
+ * Map builderMap = new 
MapBuilder().setIterationOrder(MapBuilder.KeyOrder.INSERTION_ORDER).build();
+ * builderMap.put("A", 1);
+ * builderMap.put("X", 24);
+ * builderMap.put("B", 2);
+ * builderMap.put("Y", 26);
+ * }</pre>
+ *
+ * @author Amita Pradhan
+ */
+public class MapBuilder {
+
+    private Comparator comparator;
+    private KeyOrder iterationOrder;
+    private boolean synchronizedMap;
+    private boolean immutable;
+    private Map data;
+
+    public MapBuilder() {

Review comment:
       Done @garydgregory . Fixed the header check and checkstyle errors.




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Issue Time Tracking
-------------------

    Worklog Id:     (was: 496075)
    Time Spent: 0.5h  (was: 20m)

> A MapBuilder to help decide which type to Map to use
> ----------------------------------------------------
>
>                 Key: COLLECTIONS-767
>                 URL: https://issues.apache.org/jira/browse/COLLECTIONS-767
>             Project: Commons Collections
>          Issue Type: New Feature
>          Components: Collection, Map
>            Reporter: Amita Pradhan
>            Priority: Trivial
>          Time Spent: 0.5h
>  Remaining Estimate: 0h
>
> Currently there are whole lot of options available wrt to maps and usually 
> one has to search for the type of Map that meets the requirements or to 
> convert their existing data into required format. A MapBuilder that can just 
> return me my required Map and reduce the searching effort.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to