code: public static <T> MutableShortCollection collectShort(
              Iterable<T> iterable,
              ShortFunction<? super T> shortFunction)
      {
          if (iterable instanceof MutableCollection)
          {
              return ((MutableCollection<T>) iterable).collectShort(shortFunction);
          }
          if (iterable instanceof ArrayList)
          {
              return ArrayListIterate.collectShort((ArrayList<T>) iterable, shortFunction);
          }
          if (iterable instanceof List)
          {
              return ListIterate.collectShort((List<T>) iterable, shortFunction);
          }
          if (iterable != null)
          {
              return IterableIterate.collectShort(iterable, shortFunction);
          }
          throw new IllegalArgumentException("Cannot perform a collectShort on null");
      }
docs: Returns a new {@code short} collection with the results of applying the specified shortFunction for each element of the iterable.
  <p>
  Example using a Java 8 lambda expression:
  <pre>
  MutableShortCollection shorts =
  Iterate.<b>collectShort</b>(people, person -> person.getNumberOfJunkMailItemsReceivedPerMonth());
  </pre>
  <p>
  Example using an anonymous inner class:
  <pre>
  MutableShortCollection shorts =
  Iterate.<b>collectShort</b>(people,
  new ShortFunction&lt;Person&gt;()
  {
  public short shortValueOf(Person person)
  {
  return person.getNumberOfJunkMailItemsReceivedPerMonth();
  }
  });
  </pre>