code: public static Map<Integer, PrimaryKey> constructPrimaryKeyMap(Collection<PrimaryKey> aPrimaryKeys)
  	{
  		if (aPrimaryKeys == null)
  			return null;
  
  		Map<Integer, PrimaryKey> map = new HashMap<Integer, PrimaryKey>(aPrimaryKeys.size());
  		PrimaryKey primaryKey = null;
  		for (Iterator<PrimaryKey> i = aPrimaryKeys.iterator(); i.hasNext();)
  		{
  			primaryKey = (PrimaryKey) i.next();
  			map.put(Integer.valueOf(primaryKey.getPrimaryKey()), primaryKey);
  		}
  		return map;
  	}
docs: construct map for collection of criteria object where the key is
  Criteria.getId
  
  @param aPrimaryKeys
  the primary keys
  @return the map Criteria is the value and Criteria.getId is the key