code: public static <T> Number count(T[] self, @ClosureParams(FirstParam.Component.class) Closure closure) {
          return count((Iterable)Arrays.asList(self), closure);
      }
docs: Counts the number of occurrences which satisfy the given closure from inside this array.
  
  @param self  the array within which we count the number of occurrences
  @param closure a closure condition
  @return the number of occurrences
  @since 1.8.0