code: public static long deepMemoryUsageOfAll(Instrumentation inst, final Collection<? extends java.lang.Object> objs, final int referenceFilter) throws IOException {
  	long total = 0L;
  	final Set<Integer> counted = new HashSet<Integer>(objs.size() * 4);
  	for (final Object o: objs) {
  	    total += deepMemoryUsageOf0(inst, counted, o, referenceFilter);
  	}
  	return total;
      }
docs: Returns an estimation, in bytes, of the memory usage of the given objects plus (recursively)
  objects referenced via non-static references from any of those objects. Which references are
  traversed depends on the VisibilityFilter passed in. If two or more of the given objects
  reference the same Object X, then the memory used by Object X will only be counted once. However,
  the method guarantees that the memory for a given object (either in the passed-in collection or
  found while traversing the object graphs from those objects) will not be counted more than once.
  The estimate for each individual object is provided by the running JVM and is likely to be as
  accurate a measure as can be reasonably made by the running Java program. It will generally
  include memory taken up for "housekeeping" of that object.
  
  @param objs The collection of objects whose memory usage is to be totalled.
  @param referenceFilter Specifies which references are to be recursively included in the resulting
  count (ALL,PRIVATE_ONLY,NON_PUBLIC,NONE).
  @return An estimate, in bytes, of the total heap memory taken up by the obejcts in objs and,
  recursively, objects referenced by any of those objects that match the VisibilityFilter
  criterion.
  @throws IOException