code: public static Object getValue(final Object iObject, final int iIndex) {
      if (iObject == null)
        return null;
  
      if (!isMultiValue(iObject))
        return null;
  
      if (iIndex > getSize(iObject))
        return null;
  
      try {
        if (iObject instanceof List<?>)
          return ((List<?>) iObject).get(iIndex);
        else if (iObject instanceof Set<?>) {
          int i = 0;
          for (Object o : ((Set<?>) iObject)) {
            if (i++ == iIndex) {
              return o;
            }
          }
        } else if (iObject instanceof Map<?, ?>) {
          int i = 0;
          for (Object o : ((Map<?, ?>) iObject).values()) {
            if (i++ == iIndex) {
              return o;
            }
          }
        } else if (iObject.getClass().isArray())
          return Array.get(iObject, 0);
      } catch (Exception e) {
        // IGNORE IT
        OLogManager.instance().debug(iObject, "Error on reading the first item of the Multi-value field '%s'", iObject);
      }
      return null;
    }
docs: Returns the iIndex item of the Multi-value object (array, collection or map)
  
  @param iObject
  Multi-value object (array, collection or map)
  @param iIndex
  integer as the position requested
  @return The first item if any