<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
		<id>http://wbex.ru/index.php?action=history&amp;feed=atom&amp;title=JavaScript_Tutorial%2FArray%2FEvery</id>
		<title>JavaScript Tutorial/Array/Every - История изменений</title>
		<link rel="self" type="application/atom+xml" href="http://wbex.ru/index.php?action=history&amp;feed=atom&amp;title=JavaScript_Tutorial%2FArray%2FEvery"/>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;action=history"/>
		<updated>2026-04-04T20:19:49Z</updated>
		<subtitle>История изменений этой страницы в вики</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=10919&amp;oldid=prev</id>
		<title>67.169.97.192 в 11:08, 28 мая 2011</title>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=10919&amp;oldid=prev"/>
				<updated>2011-05-28T11:08:34Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Версия 11:08, 28 мая 2011&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l370&quot; &gt;Строка 370:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Строка 370:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; var sExec = &amp;quot;this.splice(&amp;quot;;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; var sExec = &amp;quot;this.splice(&amp;quot;;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; var aArgs = &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;new Array();&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; var aArgs = &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;[&lt;/ins&gt;0, &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;0]&lt;/ins&gt;.&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;concat&lt;/ins&gt;(arguments);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;#160; &amp;#160; for (var i=&lt;/del&gt;0,&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;l=arguments&lt;/del&gt;.&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;length; i &amp;lt; l; i++) {&lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;#160; &amp;#160; &amp;#160; &amp;#160; aArgs.push&lt;/del&gt;(&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;quot;&lt;/del&gt;arguments&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;[&amp;quot;+i+&amp;quot;]&amp;quot;&lt;/del&gt;);&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;&amp;#160; &amp;#160; } &lt;/del&gt;&lt;/div&gt;&lt;/td&gt;&lt;td colspan=&quot;2&quot;&gt;&amp;#160;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &amp;#160;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;−&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #ffe49c; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &lt;del class=&quot;diffchange diffchange-inline&quot;&gt;eval(&amp;quot;this&lt;/del&gt;.splice(&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;0&lt;/del&gt;,&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;0,&amp;quot; + &lt;/del&gt;aArgs&lt;del class=&quot;diffchange diffchange-inline&quot;&gt;.join(&amp;quot;,&amp;quot;) + &amp;quot;)&amp;quot;&lt;/del&gt;);&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;+&lt;/td&gt;&lt;td style=&quot;color:black; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;#160;&amp;#160; &amp;#160; &lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;Array.prototype&lt;/ins&gt;.splice&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;.apply&lt;/ins&gt;(&lt;ins class=&quot;diffchange diffchange-inline&quot;&gt;this&lt;/ins&gt;, aArgs);&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;};&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;};&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/*&lt;/div&gt;&lt;/td&gt;&lt;td class='diff-marker'&gt;&amp;#160;&lt;/td&gt;&lt;td style=&quot;background-color: #f9f9f9; color: #333333; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #e6e6e6; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;/*&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>67.169.97.192</name></author>	</entry>

	<entry>
		<id>http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=9799&amp;oldid=prev</id>
		<title>Admin: 1 версия</title>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=9799&amp;oldid=prev"/>
				<updated>2010-05-26T08:25:26Z</updated>
		
		<summary type="html">&lt;p&gt;1 версия&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Версия 08:25, 26 мая 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=9798&amp;oldid=prev</id>
		<title> в 18:52, 25 мая 2010</title>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=JavaScript_Tutorial/Array/Every&amp;diff=9798&amp;oldid=prev"/>
				<updated>2010-05-25T18:52:57Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Using every method from zArray Library==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;javascript&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;!DOCTYPE HTML PUBLIC &amp;quot;-//W3C//DTD HTML 4.0 Transitional//EN&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;html&amp;gt;&lt;br /&gt;
    &amp;lt;head&amp;gt;&lt;br /&gt;
        &amp;lt;title&amp;gt;every() Example 1&amp;lt;/title&amp;gt;&lt;br /&gt;
        &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
/*------------------------------------------------------------------------------&lt;br /&gt;
 * JavaScript zArray Library&lt;br /&gt;
 * Version 1.1&lt;br /&gt;
 * by Nicholas C. Zakas, http://www.nczonline.net/&lt;br /&gt;
 * Copyright (c) 2004-2005 Nicholas C. Zakas. All Rights Reserved.&lt;br /&gt;
 *&lt;br /&gt;
 * This program is free software; you can redistribute it and/or modify&lt;br /&gt;
 * it under the terms of the GNU Lesser General Public License as published by&lt;br /&gt;
 * the Free Software Foundation; either version 2.1 of the License, or&lt;br /&gt;
 * (at your option) any later version.&lt;br /&gt;
 *&lt;br /&gt;
 * This program is distributed in the hope that it will be useful,&lt;br /&gt;
 * but WITHOUT ANY WARRANTY; without even the implied warranty of&lt;br /&gt;
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the&lt;br /&gt;
 * GNU Lesser General Public License for more details.&lt;br /&gt;
 *&lt;br /&gt;
 * You should have received a copy of the GNU Lesser General Public License&lt;br /&gt;
 * along with this program; if not, write to the Free Software&lt;br /&gt;
 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA&lt;br /&gt;
 *------------------------------------------------------------------------------&lt;br /&gt;
 */ &lt;br /&gt;
var aCheckMethods = new Array(&amp;quot;concat&amp;quot;, &amp;quot;push&amp;quot;, &amp;quot;pop&amp;quot;, &amp;quot;every&amp;quot;, &amp;quot;some&amp;quot;, &amp;quot;forEach&amp;quot;,&lt;br /&gt;
                              &amp;quot;filter&amp;quot;, &amp;quot;map&amp;quot;, &amp;quot;indexOf&amp;quot;, &amp;quot;lastIndexOf&amp;quot;, &amp;quot;slice&amp;quot;,&lt;br /&gt;
                              &amp;quot;splice&amp;quot;, &amp;quot;shift&amp;quot;, &amp;quot;unshift&amp;quot;);&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Appends any number of items onto the end of the array.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.append = function () {&lt;br /&gt;
    for (var i=0; i &amp;lt; arguments.length; i++) {&lt;br /&gt;
        this[this.length] = arguments[i];&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Creates a copy of the array and returns it.&lt;br /&gt;
 * @return A copy of the array.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.clone = function () /*:Array*/ {&lt;br /&gt;
    return this.concat();&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Determines if a given item is in the array.&lt;br /&gt;
 * @param vItem The item to insert.&lt;br /&gt;
 * @return True if found, false if not.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.contains = function (vItem /*:variant*/) /*:boolean*/ {&lt;br /&gt;
    return this.indexOf(vItem)&amp;gt;-1;&lt;br /&gt;
};&lt;br /&gt;
&lt;br /&gt;
/**&lt;br /&gt;
 * Runs a function on each item in the array and returns a result.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param fnTest The function to run on each value.&lt;br /&gt;
 * @param oThis The object that the function belongs to or null for a global &lt;br /&gt;
 *              function. &lt;br /&gt;
 * @return True if the function evaluates to true for each item in the array,&lt;br /&gt;
 *         false if even one returns false.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._every = function (fnTest /*:Function*/, oThis /*:Object*/)/*:boolean*/ {&lt;br /&gt;
    if (this.length &amp;gt; 0) {&lt;br /&gt;
        var bResult = true;&lt;br /&gt;
        oThis = oThis || window;&lt;br /&gt;
        oThis.__everyFunc__ = fnTest;&lt;br /&gt;
        &lt;br /&gt;
        for (var i=0, l=this.length; i &amp;lt; l &amp;amp;&amp;amp; bResult; i++) {&lt;br /&gt;
            bResult = bResult &amp;amp;&amp;amp; oThis.__everyFunc__(this[i], i, this);&lt;br /&gt;
        }&lt;br /&gt;
        &lt;br /&gt;
        oThis.__everyFunc__ = null;&lt;br /&gt;
        &lt;br /&gt;
        return bResult;&lt;br /&gt;
    } else {&lt;br /&gt;
        return true;   //fix(1.02): changed from false&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Runs a function on each item and returns an array.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param fnTest The function to run on each item.&lt;br /&gt;
 * @param oThis The object that the function belongs to or null for a global &lt;br /&gt;
 *              function.&lt;br /&gt;
 * @return An array made up of all the items that returned true for the function.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._filter= function (fnTest /*:Function*/, oThis /*:Object*/)/*:Array*/ {&lt;br /&gt;
    &lt;br /&gt;
    var aResult /*:Array*/ = new Array();&lt;br /&gt;
    oThis = oThis || window;&lt;br /&gt;
    oThis.__filterFunc__ = fnTest;&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
        if (oThis.__filterFunc__(this[i], i, this)) {&lt;br /&gt;
           aResult.push(this[i]);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    oThis.__filterFunc__ = null;&lt;br /&gt;
    &lt;br /&gt;
    return aResult;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Runs a function on each item in the array and returns a result.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param fnExec The function to run on each value.&lt;br /&gt;
 * @param oThis The object that the function belongs to or null for a global &lt;br /&gt;
 *              function.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._forEach = function (fnExec /*:Function*/, oThis /*:Object*/) {&lt;br /&gt;
    &lt;br /&gt;
    oThis = oThis || window;&lt;br /&gt;
    oThis.__forEachFunc__ = fnExec;&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
        oThis.__forEachFunc__(this[i], i, this);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    oThis.__forEachFunc__ = null;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Returns the index of the first occurrance in the array.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param vItem The item to locate in the array.&lt;br /&gt;
 * @param iStart The item to start looking from (optional). &lt;br /&gt;
 * @return The index of the item in the array if found or -1 if not found.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._indexOf = function (vItem /*:Variant*/, iStart /*:int*/)/*:int*/ {&lt;br /&gt;
    if (iStart == null) {&lt;br /&gt;
        iStart = 0;&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    for (var i=iStart, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
        if (this[i] == vItem) {&lt;br /&gt;
            return i;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    return -1;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Inserts an item into the array at the given position.&lt;br /&gt;
 * @param vItem The item to insert.&lt;br /&gt;
 * @param iIndex The index to insert the item into.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.insertAt = function (vItem /*:variant*/, iIndex /*:int*/) /*:variant*/ {&lt;br /&gt;
    this.splice(iIndex, 0, vItem);&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Inserts an item into the array before the given item.&lt;br /&gt;
 * @param vItem The item to insert.&lt;br /&gt;
 * @param vBeforeItem The item to insert before.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.insertBefore = function (vItem /*:variant*/, vBeforeItem /*:variant*/) /*:variant*/ {&lt;br /&gt;
    this.insertAt(vItem, this.indexOf(vBeforeItem));&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Returns the last index of the first occurrance in the array.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param vItem The item to locate in the array.&lt;br /&gt;
 * @param iStart The index of the item to start at.&lt;br /&gt;
 * @return The last index of the item in the array if found or -1 if not found.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._lastIndexOf = function (vItem /*:Variant*/, iStart /*:int*/)/*:int*/ {&lt;br /&gt;
    if (iStart == null || iStart &amp;gt;= this.length) {&lt;br /&gt;
        iStart = this.length-1;&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    for (var i=iStart; i &amp;gt;= 0; i--) {&lt;br /&gt;
        if (this[i] == vItem) {&lt;br /&gt;
            return i;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    return -1;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Runs a function on each item and returns an array.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param fnExec The function to run on each item.&lt;br /&gt;
 * @param oThis The object that the function belongs to or null for a global&lt;br /&gt;
 *              function.&lt;br /&gt;
 * @return An array made up of all the items that returned true for the function.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._map = function (fnExec /*:Function*/, oThis /*:Object*/)/*:Array*/ {&lt;br /&gt;
    &lt;br /&gt;
    var aResult /*:Array*/ = new Array();&lt;br /&gt;
    oThis = oThis || window;&lt;br /&gt;
    oThis.__mapFunc__ = fnExec;&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
        aResult.push(oThis.__mapFunc__(this[i], i, this));&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    oThis.__mapFunc__ = null;&lt;br /&gt;
    &lt;br /&gt;
    return aResult;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Pops off the last item in the array and returns it.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 * @return The last item in the array.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._pop = function ()/*:variant*/ {&lt;br /&gt;
    var oItem /*:Variant*/ = null;&lt;br /&gt;
    &lt;br /&gt;
    if (this.length &amp;gt; 0) {&lt;br /&gt;
        oItem = this[this.length-1];&lt;br /&gt;
        this.length--;&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    return oItem;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Pushes any number of items onto the end of the array.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._push = Array.prototype.append;&lt;br /&gt;
/**&lt;br /&gt;
 * Removes the array item matching the given item.&lt;br /&gt;
 * @param vItem the item to remove.&lt;br /&gt;
 * @return The removed item.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.remove = function (vItem /*:variant*/) /*:variant*/ {&lt;br /&gt;
    this.removeAt(this.indexOf(vItem));    &lt;br /&gt;
    return vItem;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Removes the array item in the given position.&lt;br /&gt;
 * @param iIndex The index of the item to remove.&lt;br /&gt;
 * @return The removed item.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.removeAt = function (iIndex /*:int*/) /*:variant*/ {&lt;br /&gt;
    var vItem = this[iIndex];&lt;br /&gt;
    if (vItem) {&lt;br /&gt;
        this.splice(iIndex, 1);&lt;br /&gt;
    }&lt;br /&gt;
    return vItem;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Creates an array composed of the indicated items in the current array.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 * @param iStart The first item to copy.&lt;br /&gt;
 * @param iStop The index after the last item to copy.&lt;br /&gt;
 * @return An array containing all items in the original array between the given&lt;br /&gt;
 *         indices.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._slice = function (iStart /*:int*/, iStop /*:int*/)/*:Array*/ {&lt;br /&gt;
 &lt;br /&gt;
    var aResult /*:Array*/ = new Array();&lt;br /&gt;
    iStop = iStop || this.length;&lt;br /&gt;
    &lt;br /&gt;
    for (var i=iStart; i &amp;lt; iStop; i++) {&lt;br /&gt;
        aResult.push(this[i]);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    return aResult;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Removes the first item in the array and returns it.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 * @return The first item in the array.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._shift = function ()/*:variant*/ {&lt;br /&gt;
 &lt;br /&gt;
    var vItem = this[0];&lt;br /&gt;
    if (vItem) {&lt;br /&gt;
        this.splice(0,1);&lt;br /&gt;
    }&lt;br /&gt;
    return vItem;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Runs a function on each item in the array and returns a result.&lt;br /&gt;
 * Defined in Mozilla 1.8 Core JavaScript&lt;br /&gt;
 * @param fnTest The function to run on each value.&lt;br /&gt;
 * @return True if the function evaluates to true for any one item, false if not.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._some= function (fnTest /*:Function*/, oThis /*:Object*/)/*:boolean*/ {&lt;br /&gt;
    &lt;br /&gt;
    oThis = oThis || window;&lt;br /&gt;
    oThis.__someFunc__ = fnTest;&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
        if (oThis.__someFunc__(this[i], i, this)) {&lt;br /&gt;
           return true;&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    oThis.__someFunc__ = null;&lt;br /&gt;
    &lt;br /&gt;
    return false;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Alters the array by removing specified items and inserting others.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 * @param iIndex The index at which to begin altering the array.&lt;br /&gt;
 * @param iLength The number of items to remove.&lt;br /&gt;
 * @param vItem[] The items to insert in place of the removed items.&lt;br /&gt;
 * @return An array containing all removed items.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._splice = function (iIndex /*:int*/, iLength /*:int*/)/*:Array*/ {&lt;br /&gt;
 &lt;br /&gt;
    var aResult /*:Array*/ = new Array();&lt;br /&gt;
    var aRemoved /*: Array */ = new Array();&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0; i &amp;lt; iIndex; i++){&lt;br /&gt;
        aResult.push(this[i]);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    for (var i=iIndex; i &amp;lt; iIndex+iLength; i++) {&lt;br /&gt;
       aRemoved.push(this[i]);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    if (arguments.length &amp;gt; 2) {&lt;br /&gt;
        for (var i=2; i &amp;lt; arguments.length; i++) {&lt;br /&gt;
            aResult.push(arguments[i]);&lt;br /&gt;
        }&lt;br /&gt;
    }&lt;br /&gt;
    for (var i=iIndex+iLength; i &amp;lt; this.length; i++) {&lt;br /&gt;
        aResult.push(this[i]);&lt;br /&gt;
    }&lt;br /&gt;
    &lt;br /&gt;
    for (var i=0; i &amp;lt; aResult.length; i++) {&lt;br /&gt;
        this[i] = aResult[i];&lt;br /&gt;
    }&lt;br /&gt;
    this.length = aResult.length;&lt;br /&gt;
    &lt;br /&gt;
    return aRemoved;&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Adds all the items in the array and returns the result.&lt;br /&gt;
 * @param fnConvert An optional function to run on each item before adding.&lt;br /&gt;
 * @param oThis The object that the function belongs to or null for a global &lt;br /&gt;
 *              function. &lt;br /&gt;
 * @return The result of adding all of the array items together.&lt;br /&gt;
 */&lt;br /&gt;
Array.prototype.sum = function (fnConvert /*:Function*/, oThis /*:Object*/)/*:variant*/ {&lt;br /&gt;
    if (this.length &amp;gt; 0) {&lt;br /&gt;
        var vResult = null;&lt;br /&gt;
        oThis = oThis || window;&lt;br /&gt;
        oThis.__sumFunc__ = fnConvert || function (vVal) { return vVal; };&lt;br /&gt;
        &lt;br /&gt;
        vResult = oThis.__sumFunc__(this[0], 0, this);&lt;br /&gt;
        &lt;br /&gt;
        for (var i=1, l=this.length; i &amp;lt; l; i++) {&lt;br /&gt;
            vResult += oThis.__sumFunc__(this[i], i, this);&lt;br /&gt;
        }&lt;br /&gt;
        &lt;br /&gt;
        oThis.__sumFunc__ = null;&lt;br /&gt;
        &lt;br /&gt;
        return vResult;&lt;br /&gt;
    } else {&lt;br /&gt;
        return null;&lt;br /&gt;
    }&lt;br /&gt;
};&lt;br /&gt;
/**&lt;br /&gt;
 * Places the given items at the beginning of the array.&lt;br /&gt;
 * Defined in ECMA-262 3rd Edition.&lt;br /&gt;
 * @param vItem[] Items to add into the &lt;br /&gt;
 */&lt;br /&gt;
Array.prototype._unshift = function () {&lt;br /&gt;
    var sExec = &amp;quot;this.splice(&amp;quot;;&lt;br /&gt;
    &lt;br /&gt;
    var aArgs = new Array();&lt;br /&gt;
    for (var i=0,l=arguments.length; i &amp;lt; l; i++) {&lt;br /&gt;
        aArgs.push(&amp;quot;arguments[&amp;quot;+i+&amp;quot;]&amp;quot;);&lt;br /&gt;
    } &lt;br /&gt;
    &lt;br /&gt;
    eval(&amp;quot;this.splice(0,0,&amp;quot; + aArgs.join(&amp;quot;,&amp;quot;) + &amp;quot;)&amp;quot;);&lt;br /&gt;
};&lt;br /&gt;
/*&lt;br /&gt;
 * Assign the necessary methods.&lt;br /&gt;
 */&lt;br /&gt;
for (var i=0; i &amp;lt; aCheckMethods.length; i++) {&lt;br /&gt;
    if(!Array.prototype[aCheckMethods[i]]) {&lt;br /&gt;
        Array.prototype[aCheckMethods[i]] = Array.prototype[&amp;quot;_&amp;quot;+aCheckMethods[i]];&lt;br /&gt;
    }&lt;br /&gt;
}&lt;br /&gt;
        &lt;br /&gt;
        &amp;lt;/script&amp;gt;&lt;br /&gt;
    &amp;lt;/head&amp;gt;&lt;br /&gt;
    &amp;lt;body&amp;gt;        &lt;br /&gt;
        &amp;lt;h1&amp;gt;every() Example 1&amp;lt;/h1&amp;gt;&lt;br /&gt;
        &amp;lt;script type=&amp;quot;text/javascript&amp;quot;&amp;gt;&lt;br /&gt;
            function isBigEnough(vValue, iIndex, aValues) {&lt;br /&gt;
              return (vValue &amp;gt;= 10);&lt;br /&gt;
            }&lt;br /&gt;
            alert([12, 5, 8, 130, 44].every(isBigEnough));&lt;br /&gt;
            // is false&lt;br /&gt;
            alert([12, 54, 18, 130, 44].every(isBigEnough));&lt;br /&gt;
            // is true&lt;br /&gt;
        &amp;lt;/script&amp;gt;&lt;br /&gt;
        &amp;lt;P&amp;gt;This example checks two arrays to see if every number is&lt;br /&gt;
        greater than or equal to 10.&amp;lt;/p&amp;gt;        &lt;br /&gt;
    &amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
			</entry>

	</feed>