code: public static boolean containsInstance(Collection<?> collection, Object element) {
          if (collection != null) {
              for (Object candidate : collection) {
                  if (candidate == element) {
                      return true;
                  }
              }
          }
          return false;
      }
docs: Check whether the given Collection contains the given element instance. <p>Enforces the given instance to be
  present, rather than returning {@code true} for an equal element as well.
  
  @param collection the Collection to check.
  @param element the element to look for.
  
  @return {@code true} if found, {@code false} else.