code: public static <T> MutableBooleanCollection collectBoolean(
              Iterable<T> iterable,
              BooleanFunction<? super T> booleanFunction)
      {
          if (iterable instanceof MutableCollection)
          {
              return ((MutableCollection<T>) iterable).collectBoolean(booleanFunction);
          }
          if (iterable instanceof ArrayList)
          {
              return ArrayListIterate.collectBoolean((ArrayList<T>) iterable, booleanFunction);
          }
          if (iterable instanceof List)
          {
              return ListIterate.collectBoolean((List<T>) iterable, booleanFunction);
          }
          if (iterable != null)
          {
              return IterableIterate.collectBoolean(iterable, booleanFunction);
          }
          throw new IllegalArgumentException("Cannot perform a collectBoolean on null");
      }
docs: Returns a new primitive {@code boolean} collection with the results of applying the specified booleanFunction for each element of the iterable.
  <p>
  Example using Java 8 lambda:
  <pre>
  MutableBooleanCollection voters =
  Iterable.<b>collectBoolean</b>(people, person -> person.canVote());
  </pre>
  <p>
  Example using anonymous inner class:
  <pre>
  MutableBooleanCollection voters =
  Iterate.<b>collectBoolean</b>(people,
  new BooleanFunction&lt;Person&gt;()
  {
  public boolean booleanValueOf(Person person)
  {
  return person.canVote();
  }
  });
  </pre>