Class MapUtils


  • public class MapUtils
    extends java.lang.Object
    MapUtils provides convenience methods for accessing a java.util.Map
    Author:
    Jaime Meritt (jmeritt@sonicsoftware.com), Richard Chung (rchung@sonicsoftware.com), Dave Chappell (chappell@sonicsoftware.com)
    • Constructor Summary

      Constructors 
      Constructor Description
      MapUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static boolean removeBooleanProperty​(java.util.Map properties, java.lang.String key, boolean defaultValue)
      Returns a boolean property from a Map and removes it.
      static int removeIntProperty​(java.util.Map properties, java.lang.String key, int defaultValue)
      Returns an int property from a Map and removes it.
      static long removeLongProperty​(java.util.Map properties, java.lang.String key, long defaultValue)
      Returns a long property from a Map and removes it.
      static java.lang.Object removeObjectProperty​(java.util.Map properties, java.lang.String key, java.lang.Object defaultValue)
      Returns an Object property from a Map and removes it.
      static java.lang.String removeStringProperty​(java.util.Map properties, java.lang.String key, java.lang.String defaultValue)
      Returns a String property from a Map and removes it.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • MapUtils

        public MapUtils()
    • Method Detail

      • removeIntProperty

        public static int removeIntProperty​(java.util.Map properties,
                                            java.lang.String key,
                                            int defaultValue)
        Returns an int property from a Map and removes it.
        Parameters:
        properties -
        key -
        defaultValue -
        Returns:
      • removeLongProperty

        public static long removeLongProperty​(java.util.Map properties,
                                              java.lang.String key,
                                              long defaultValue)
        Returns a long property from a Map and removes it.
        Parameters:
        properties -
        key -
        defaultValue -
        Returns:
      • removeStringProperty

        public static java.lang.String removeStringProperty​(java.util.Map properties,
                                                            java.lang.String key,
                                                            java.lang.String defaultValue)
        Returns a String property from a Map and removes it.
        Parameters:
        properties -
        key -
        defaultValue -
        Returns:
      • removeBooleanProperty

        public static boolean removeBooleanProperty​(java.util.Map properties,
                                                    java.lang.String key,
                                                    boolean defaultValue)
        Returns a boolean property from a Map and removes it.
        Parameters:
        properties -
        key -
        defaultValue -
        Returns:
      • removeObjectProperty

        public static java.lang.Object removeObjectProperty​(java.util.Map properties,
                                                            java.lang.String key,
                                                            java.lang.Object defaultValue)
        Returns an Object property from a Map and removes it.
        Parameters:
        properties -
        key -
        defaultValue -
        Returns: