org.activiti.engine.impl.util
类 CollectionUtil

java.lang.Object
  继承者 org.activiti.engine.impl.util.CollectionUtil

public class CollectionUtil
extends Object

helper/convience methods for working with collections.

作者:
Joram Barrez

方法摘要
static Map<String,Object> map(Object... objects)
          Helper method to easily create a map.
static Map<String,Object> singletonMap(String key, Object value)
          Helper method that creates a singleton map.
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

方法详细信息

singletonMap

public static Map<String,Object> singletonMap(String key,
                                              Object value)
Helper method that creates a singleton map. Alternative for Collections.singletonMap(), since that method returns a generic typed map depending on the input type, but we often need a map.


map

public static Map<String,Object> map(Object... objects)
Helper method to easily create a map. Takes as input a varargs containing the key1, value1, key2, value2, etc. Note: altough an Object, we will cast the key to String internally.



Copyright © 2013 Alfresco. All rights reserved.