Does jQuery have a method for checking all values of an array to see if they meet some criteria?
<p>I'm looking for something similar to Groovy's <a href="http://groovy.codehaus.org/groovy-jdk/java/lang/Object.html#every%28%29" rel="nofollow">every()</a> method, which tests every element of a list if it meets some criteria.  If they all meet the criteria, the function returns true.  Otherwise, false.  I've tried something like this:</p>

<pre><code>var arr = [1, 0, 1, 0, 1, 1];
var allOnes = $.grep(arr, function(ind) { 
                   return this == 1;
               }).length == arr.length;
</code></pre>

<p>..but its not very clean.  I haven't had any luck while searching through the API.  Is using <code>grep()</code> the only way to do it? </p>
