code: public static String arrayAwareToString(Object o) {
  		if (o == null) {
  			return "null";
  		}
  		if (o.getClass().isArray()) {
  			return arrayToString(o);
  		}
  
  		return o.toString();
  	}
docs: This method calls {@link Object#toString()} on the given object, unless the
  object is an array. In that case, it will use the {@link #arrayToString(Object)}
  method to create a string representation of the array that includes all contained
  elements.
  
  @param o The object for which to create the string representation.
  @return The string representation of the object.