commons-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From brit...@apache.org
Subject svn commit: r949864 [33/48] - in /websites/production/commons/content/proper/commons-lang: ./ apidocs/ apidocs/org/apache/commons/lang3/ apidocs/org/apache/commons/lang3/builder/ apidocs/org/apache/commons/lang3/time/ apidocs/src-html/org/apache/common...
Date Fri, 01 May 2015 20:55:53 GMT
Modified: websites/production/commons/content/proper/commons-lang/xref-test/org/apache/commons/lang3/ArrayUtilsTest.html
==============================================================================
--- websites/production/commons/content/proper/commons-lang/xref-test/org/apache/commons/lang3/ArrayUtilsTest.html (original)
+++ websites/production/commons/content/proper/commons-lang/xref-test/org/apache/commons/lang3/ArrayUtilsTest.html Fri May  1 20:55:51 2015
@@ -2126,1546 +2126,2287 @@
 <a class="jxr_linenumber" name="L2118" href="#L2118">2118</a>         assertEquals(<strong class="jxr_keyword">null</strong>, array);
 <a class="jxr_linenumber" name="L2119" href="#L2119">2119</a>     }
 <a class="jxr_linenumber" name="L2120" href="#L2120">2120</a>     
-<a class="jxr_linenumber" name="L2121" href="#L2121">2121</a> 
-<a class="jxr_linenumber" name="L2122" href="#L2122">2122</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2123" href="#L2123">2123</a>     @Test
-<a class="jxr_linenumber" name="L2124" href="#L2124">2124</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOf() {
-<a class="jxr_linenumber" name="L2125" href="#L2125">2125</a>         <strong class="jxr_keyword">final</strong> Object[] array = <strong class="jxr_keyword">new</strong> Object[] { <span class="jxr_string">"0"</span>, <span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span> };
-<a class="jxr_linenumber" name="L2126" href="#L2126">2126</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">null</strong>, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2127" href="#L2127">2127</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2128" href="#L2128">2128</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">new</strong> Object[0], <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2129" href="#L2129">2129</a>         assertEquals(0, ArrayUtils.indexOf(array, <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2130" href="#L2130">2130</a>         assertEquals(1, ArrayUtils.indexOf(array, <span class="jxr_string">"1"</span>));
-<a class="jxr_linenumber" name="L2131" href="#L2131">2131</a>         assertEquals(2, ArrayUtils.indexOf(array, <span class="jxr_string">"2"</span>));
-<a class="jxr_linenumber" name="L2132" href="#L2132">2132</a>         assertEquals(3, ArrayUtils.indexOf(array, <span class="jxr_string">"3"</span>));
-<a class="jxr_linenumber" name="L2133" href="#L2133">2133</a>         assertEquals(4, ArrayUtils.indexOf(array, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2134" href="#L2134">2134</a>         assertEquals(-1, ArrayUtils.indexOf(array, <span class="jxr_string">"notInArray"</span>));
+<a class="jxr_linenumber" name="L2121" href="#L2121">2121</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
+<a class="jxr_linenumber" name="L2122" href="#L2122">2122</a>     @Test
+<a class="jxr_linenumber" name="L2123" href="#L2123">2123</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapChar() {
+<a class="jxr_linenumber" name="L2124" href="#L2124">2124</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2125" href="#L2125">2125</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2126" href="#L2126">2126</a>         assertArrayEquals(<strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {3, 2, 1}, array);
+<a class="jxr_linenumber" name="L2127" href="#L2127">2127</a>         
+<a class="jxr_linenumber" name="L2128" href="#L2128">2128</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2129" href="#L2129">2129</a>         ArrayUtils.swap(array, 0, 0);
+<a class="jxr_linenumber" name="L2130" href="#L2130">2130</a>         assertArrayEquals(<strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3}, array);
+<a class="jxr_linenumber" name="L2131" href="#L2131">2131</a>         
+<a class="jxr_linenumber" name="L2132" href="#L2132">2132</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2133" href="#L2133">2133</a>         ArrayUtils.swap(array, 1, 0);
+<a class="jxr_linenumber" name="L2134" href="#L2134">2134</a>         assertArrayEquals(<strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {2, 1, 3}, array);
 <a class="jxr_linenumber" name="L2135" href="#L2135">2135</a>     }
-<a class="jxr_linenumber" name="L2136" href="#L2136">2136</a> 
+<a class="jxr_linenumber" name="L2136" href="#L2136">2136</a>     
 <a class="jxr_linenumber" name="L2137" href="#L2137">2137</a>     @Test
-<a class="jxr_linenumber" name="L2138" href="#L2138">2138</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfWithStartIndex() {
-<a class="jxr_linenumber" name="L2139" href="#L2139">2139</a>         <strong class="jxr_keyword">final</strong> Object[] array = <strong class="jxr_keyword">new</strong> Object[] { <span class="jxr_string">"0"</span>, <span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span> };
-<a class="jxr_linenumber" name="L2140" href="#L2140">2140</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">null</strong>, <strong class="jxr_keyword">null</strong>, 2));
-<a class="jxr_linenumber" name="L2141" href="#L2141">2141</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">new</strong> Object[0], <span class="jxr_string">"0"</span>, 0));
-<a class="jxr_linenumber" name="L2142" href="#L2142">2142</a>         assertEquals(-1, ArrayUtils.indexOf(<strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span>, 2));
-<a class="jxr_linenumber" name="L2143" href="#L2143">2143</a>         assertEquals(5, ArrayUtils.indexOf(array, <span class="jxr_string">"0"</span>, 2));
-<a class="jxr_linenumber" name="L2144" href="#L2144">2144</a>         assertEquals(-1, ArrayUtils.indexOf(array, <span class="jxr_string">"1"</span>, 2));
-<a class="jxr_linenumber" name="L2145" href="#L2145">2145</a>         assertEquals(2, ArrayUtils.indexOf(array, <span class="jxr_string">"2"</span>, 2));
-<a class="jxr_linenumber" name="L2146" href="#L2146">2146</a>         assertEquals(3, ArrayUtils.indexOf(array, <span class="jxr_string">"3"</span>, 2));
-<a class="jxr_linenumber" name="L2147" href="#L2147">2147</a>         assertEquals(4, ArrayUtils.indexOf(array, <strong class="jxr_keyword">null</strong>, 2));
-<a class="jxr_linenumber" name="L2148" href="#L2148">2148</a>         assertEquals(-1, ArrayUtils.indexOf(array, <span class="jxr_string">"notInArray"</span>, 2));
-<a class="jxr_linenumber" name="L2149" href="#L2149">2149</a>         
-<a class="jxr_linenumber" name="L2150" href="#L2150">2150</a>         assertEquals(4, ArrayUtils.indexOf(array, <strong class="jxr_keyword">null</strong>, -1));
-<a class="jxr_linenumber" name="L2151" href="#L2151">2151</a>         assertEquals(-1, ArrayUtils.indexOf(array, <strong class="jxr_keyword">null</strong>, 8));
-<a class="jxr_linenumber" name="L2152" href="#L2152">2152</a>         assertEquals(-1, ArrayUtils.indexOf(array, <span class="jxr_string">"0"</span>, 8));
-<a class="jxr_linenumber" name="L2153" href="#L2153">2153</a>     }
-<a class="jxr_linenumber" name="L2154" href="#L2154">2154</a> 
-<a class="jxr_linenumber" name="L2155" href="#L2155">2155</a>     @Test
-<a class="jxr_linenumber" name="L2156" href="#L2156">2156</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOf() {
-<a class="jxr_linenumber" name="L2157" href="#L2157">2157</a>         <strong class="jxr_keyword">final</strong> Object[] array = <strong class="jxr_keyword">new</strong> Object[] { <span class="jxr_string">"0"</span>, <span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span> };
-<a class="jxr_linenumber" name="L2158" href="#L2158">2158</a>         assertEquals(-1, ArrayUtils.lastIndexOf(<strong class="jxr_keyword">null</strong>, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2159" href="#L2159">2159</a>         assertEquals(-1, ArrayUtils.lastIndexOf(<strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2160" href="#L2160">2160</a>         assertEquals(5, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2161" href="#L2161">2161</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"1"</span>));
-<a class="jxr_linenumber" name="L2162" href="#L2162">2162</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"2"</span>));
-<a class="jxr_linenumber" name="L2163" href="#L2163">2163</a>         assertEquals(3, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"3"</span>));
-<a class="jxr_linenumber" name="L2164" href="#L2164">2164</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2165" href="#L2165">2165</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"notInArray"</span>));
+<a class="jxr_linenumber" name="L2138" href="#L2138">2138</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapCharRange() {
+<a class="jxr_linenumber" name="L2139" href="#L2139">2139</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2140" href="#L2140">2140</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2141" href="#L2141">2141</a>         assertEquals(3, array[0]);
+<a class="jxr_linenumber" name="L2142" href="#L2142">2142</a>         assertEquals(4, array[1]);
+<a class="jxr_linenumber" name="L2143" href="#L2143">2143</a>         assertEquals(1, array[2]);
+<a class="jxr_linenumber" name="L2144" href="#L2144">2144</a>         assertEquals(2, array[3]);
+<a class="jxr_linenumber" name="L2145" href="#L2145">2145</a>     }
+<a class="jxr_linenumber" name="L2146" href="#L2146">2146</a> 
+<a class="jxr_linenumber" name="L2147" href="#L2147">2147</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2148" href="#L2148">2148</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapCharOutOfRange() {
+<a class="jxr_linenumber" name="L2149" href="#L2149">2149</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2150" href="#L2150">2150</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2151" href="#L2151">2151</a>     }
+<a class="jxr_linenumber" name="L2152" href="#L2152">2152</a> 
+<a class="jxr_linenumber" name="L2153" href="#L2153">2153</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2154" href="#L2154">2154</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapCharOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2155" href="#L2155">2155</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2156" href="#L2156">2156</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2157" href="#L2157">2157</a>     }
+<a class="jxr_linenumber" name="L2158" href="#L2158">2158</a>     
+<a class="jxr_linenumber" name="L2159" href="#L2159">2159</a>     @Test
+<a class="jxr_linenumber" name="L2160" href="#L2160">2160</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapFloat() {
+<a class="jxr_linenumber" name="L2161" href="#L2161">2161</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2162" href="#L2162">2162</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2163" href="#L2163">2163</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2164" href="#L2164">2164</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2165" href="#L2165">2165</a>         assertEquals(1, array[2], 0);
 <a class="jxr_linenumber" name="L2166" href="#L2166">2166</a>     }
 <a class="jxr_linenumber" name="L2167" href="#L2167">2167</a> 
 <a class="jxr_linenumber" name="L2168" href="#L2168">2168</a>     @Test
-<a class="jxr_linenumber" name="L2169" href="#L2169">2169</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfWithStartIndex() {
-<a class="jxr_linenumber" name="L2170" href="#L2170">2170</a>         <strong class="jxr_keyword">final</strong> Object[] array = <strong class="jxr_keyword">new</strong> Object[] { <span class="jxr_string">"0"</span>, <span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span> };
-<a class="jxr_linenumber" name="L2171" href="#L2171">2171</a>         assertEquals(-1, ArrayUtils.lastIndexOf(<strong class="jxr_keyword">null</strong>, <strong class="jxr_keyword">null</strong>, 2));
-<a class="jxr_linenumber" name="L2172" href="#L2172">2172</a>         assertEquals(-1, ArrayUtils.lastIndexOf(<strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span>, 2));
-<a class="jxr_linenumber" name="L2173" href="#L2173">2173</a>         assertEquals(0, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"0"</span>, 2));
-<a class="jxr_linenumber" name="L2174" href="#L2174">2174</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"1"</span>, 2));
-<a class="jxr_linenumber" name="L2175" href="#L2175">2175</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"2"</span>, 2));
-<a class="jxr_linenumber" name="L2176" href="#L2176">2176</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"3"</span>, 2));
-<a class="jxr_linenumber" name="L2177" href="#L2177">2177</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"3"</span>, -1));
-<a class="jxr_linenumber" name="L2178" href="#L2178">2178</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, <strong class="jxr_keyword">null</strong>, 5));
-<a class="jxr_linenumber" name="L2179" href="#L2179">2179</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <strong class="jxr_keyword">null</strong>, 2));
-<a class="jxr_linenumber" name="L2180" href="#L2180">2180</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"notInArray"</span>, 5));
-<a class="jxr_linenumber" name="L2181" href="#L2181">2181</a>         
-<a class="jxr_linenumber" name="L2182" href="#L2182">2182</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, <strong class="jxr_keyword">null</strong>, -1));
-<a class="jxr_linenumber" name="L2183" href="#L2183">2183</a>         assertEquals(5, ArrayUtils.lastIndexOf(array, <span class="jxr_string">"0"</span>, 88));
-<a class="jxr_linenumber" name="L2184" href="#L2184">2184</a>     }
-<a class="jxr_linenumber" name="L2185" href="#L2185">2185</a> 
-<a class="jxr_linenumber" name="L2186" href="#L2186">2186</a>     @Test
-<a class="jxr_linenumber" name="L2187" href="#L2187">2187</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testContains() {
-<a class="jxr_linenumber" name="L2188" href="#L2188">2188</a>         <strong class="jxr_keyword">final</strong> Object[] array = <strong class="jxr_keyword">new</strong> Object[] { <span class="jxr_string">"0"</span>, <span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <strong class="jxr_keyword">null</strong>, <span class="jxr_string">"0"</span> };
-<a class="jxr_linenumber" name="L2189" href="#L2189">2189</a>         assertFalse(ArrayUtils.contains(<strong class="jxr_keyword">null</strong>, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2190" href="#L2190">2190</a>         assertFalse(ArrayUtils.contains(<strong class="jxr_keyword">null</strong>, <span class="jxr_string">"1"</span>));
-<a class="jxr_linenumber" name="L2191" href="#L2191">2191</a>         assertTrue(ArrayUtils.contains(array, <span class="jxr_string">"0"</span>));
-<a class="jxr_linenumber" name="L2192" href="#L2192">2192</a>         assertTrue(ArrayUtils.contains(array, <span class="jxr_string">"1"</span>));
-<a class="jxr_linenumber" name="L2193" href="#L2193">2193</a>         assertTrue(ArrayUtils.contains(array, <span class="jxr_string">"2"</span>));
-<a class="jxr_linenumber" name="L2194" href="#L2194">2194</a>         assertTrue(ArrayUtils.contains(array, <span class="jxr_string">"3"</span>));
-<a class="jxr_linenumber" name="L2195" href="#L2195">2195</a>         assertTrue(ArrayUtils.contains(array, <strong class="jxr_keyword">null</strong>));
-<a class="jxr_linenumber" name="L2196" href="#L2196">2196</a>         assertFalse(ArrayUtils.contains(array, <span class="jxr_string">"notInArray"</span>));
+<a class="jxr_linenumber" name="L2169" href="#L2169">2169</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapFloatRange() {
+<a class="jxr_linenumber" name="L2170" href="#L2170">2170</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2171" href="#L2171">2171</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2172" href="#L2172">2172</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2173" href="#L2173">2173</a>         assertEquals(4, array[1], 0);
+<a class="jxr_linenumber" name="L2174" href="#L2174">2174</a>         assertEquals(1, array[2], 0);
+<a class="jxr_linenumber" name="L2175" href="#L2175">2175</a>         assertEquals(2, array[3], 0);
+<a class="jxr_linenumber" name="L2176" href="#L2176">2176</a>     }
+<a class="jxr_linenumber" name="L2177" href="#L2177">2177</a> 
+<a class="jxr_linenumber" name="L2178" href="#L2178">2178</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2179" href="#L2179">2179</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapFloatOutOfRange() {
+<a class="jxr_linenumber" name="L2180" href="#L2180">2180</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2181" href="#L2181">2181</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2182" href="#L2182">2182</a>     }
+<a class="jxr_linenumber" name="L2183" href="#L2183">2183</a> 
+<a class="jxr_linenumber" name="L2184" href="#L2184">2184</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2185" href="#L2185">2185</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapFloatOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2186" href="#L2186">2186</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2187" href="#L2187">2187</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2188" href="#L2188">2188</a>     }
+<a class="jxr_linenumber" name="L2189" href="#L2189">2189</a>     
+<a class="jxr_linenumber" name="L2190" href="#L2190">2190</a>     @Test
+<a class="jxr_linenumber" name="L2191" href="#L2191">2191</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapDouble() {
+<a class="jxr_linenumber" name="L2192" href="#L2192">2192</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2193" href="#L2193">2193</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2194" href="#L2194">2194</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2195" href="#L2195">2195</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2196" href="#L2196">2196</a>         assertEquals(1, array[2], 0);
 <a class="jxr_linenumber" name="L2197" href="#L2197">2197</a>     }
-<a class="jxr_linenumber" name="L2198" href="#L2198">2198</a>     
-<a class="jxr_linenumber" name="L2199" href="#L2199">2199</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2200" href="#L2200">2200</a>     @Test
-<a class="jxr_linenumber" name="L2201" href="#L2201">2201</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfLong() {
-<a class="jxr_linenumber" name="L2202" href="#L2202">2202</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2203" href="#L2203">2203</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0));
-<a class="jxr_linenumber" name="L2204" href="#L2204">2204</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2205" href="#L2205">2205</a>         assertEquals(0, ArrayUtils.indexOf(array, 0));
-<a class="jxr_linenumber" name="L2206" href="#L2206">2206</a>         assertEquals(1, ArrayUtils.indexOf(array, 1));
-<a class="jxr_linenumber" name="L2207" href="#L2207">2207</a>         assertEquals(2, ArrayUtils.indexOf(array, 2));
-<a class="jxr_linenumber" name="L2208" href="#L2208">2208</a>         assertEquals(3, ArrayUtils.indexOf(array, 3));
-<a class="jxr_linenumber" name="L2209" href="#L2209">2209</a>         assertEquals(-1, ArrayUtils.indexOf(array, 99));
-<a class="jxr_linenumber" name="L2210" href="#L2210">2210</a>     }
-<a class="jxr_linenumber" name="L2211" href="#L2211">2211</a> 
-<a class="jxr_linenumber" name="L2212" href="#L2212">2212</a>     @Test
-<a class="jxr_linenumber" name="L2213" href="#L2213">2213</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfLongWithStartIndex() {
-<a class="jxr_linenumber" name="L2214" href="#L2214">2214</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2215" href="#L2215">2215</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2216" href="#L2216">2216</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2217" href="#L2217">2217</a>         assertEquals(4, ArrayUtils.indexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2218" href="#L2218">2218</a>         assertEquals(-1, ArrayUtils.indexOf(array, 1, 2));
-<a class="jxr_linenumber" name="L2219" href="#L2219">2219</a>         assertEquals(2, ArrayUtils.indexOf(array, 2, 2));
-<a class="jxr_linenumber" name="L2220" href="#L2220">2220</a>         assertEquals(3, ArrayUtils.indexOf(array, 3, 2));
-<a class="jxr_linenumber" name="L2221" href="#L2221">2221</a>         assertEquals(3, ArrayUtils.indexOf(array, 3, -1));
-<a class="jxr_linenumber" name="L2222" href="#L2222">2222</a>         assertEquals(-1, ArrayUtils.indexOf(array, 99, 0));
-<a class="jxr_linenumber" name="L2223" href="#L2223">2223</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0, 6));
-<a class="jxr_linenumber" name="L2224" href="#L2224">2224</a>     }
-<a class="jxr_linenumber" name="L2225" href="#L2225">2225</a> 
-<a class="jxr_linenumber" name="L2226" href="#L2226">2226</a>     @Test
-<a class="jxr_linenumber" name="L2227" href="#L2227">2227</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfLong() {
-<a class="jxr_linenumber" name="L2228" href="#L2228">2228</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2229" href="#L2229">2229</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 0));
-<a class="jxr_linenumber" name="L2230" href="#L2230">2230</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2231" href="#L2231">2231</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 0));
-<a class="jxr_linenumber" name="L2232" href="#L2232">2232</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 1));
-<a class="jxr_linenumber" name="L2233" href="#L2233">2233</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 2));
-<a class="jxr_linenumber" name="L2234" href="#L2234">2234</a>         assertEquals(3, ArrayUtils.lastIndexOf(array, 3));
-<a class="jxr_linenumber" name="L2235" href="#L2235">2235</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 99));
-<a class="jxr_linenumber" name="L2236" href="#L2236">2236</a>     }
-<a class="jxr_linenumber" name="L2237" href="#L2237">2237</a> 
-<a class="jxr_linenumber" name="L2238" href="#L2238">2238</a>     @Test
-<a class="jxr_linenumber" name="L2239" href="#L2239">2239</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfLongWithStartIndex() {
-<a class="jxr_linenumber" name="L2240" href="#L2240">2240</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2241" href="#L2241">2241</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2242" href="#L2242">2242</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2243" href="#L2243">2243</a>         assertEquals(0, ArrayUtils.lastIndexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2244" href="#L2244">2244</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 1, 2));
-<a class="jxr_linenumber" name="L2245" href="#L2245">2245</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 2, 2));
-<a class="jxr_linenumber" name="L2246" href="#L2246">2246</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 3, 2));
-<a class="jxr_linenumber" name="L2247" href="#L2247">2247</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 3, -1));
-<a class="jxr_linenumber" name="L2248" href="#L2248">2248</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 99, 4));
-<a class="jxr_linenumber" name="L2249" href="#L2249">2249</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 0, 88));
+<a class="jxr_linenumber" name="L2198" href="#L2198">2198</a> 
+<a class="jxr_linenumber" name="L2199" href="#L2199">2199</a>     @Test
+<a class="jxr_linenumber" name="L2200" href="#L2200">2200</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapDoubleRange() {
+<a class="jxr_linenumber" name="L2201" href="#L2201">2201</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2202" href="#L2202">2202</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2203" href="#L2203">2203</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2204" href="#L2204">2204</a>         assertEquals(4, array[1], 0);
+<a class="jxr_linenumber" name="L2205" href="#L2205">2205</a>         assertEquals(1, array[2], 0);
+<a class="jxr_linenumber" name="L2206" href="#L2206">2206</a>         assertEquals(2, array[3], 0);
+<a class="jxr_linenumber" name="L2207" href="#L2207">2207</a>     }
+<a class="jxr_linenumber" name="L2208" href="#L2208">2208</a> 
+<a class="jxr_linenumber" name="L2209" href="#L2209">2209</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2210" href="#L2210">2210</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapDoubleOutOfRange() {
+<a class="jxr_linenumber" name="L2211" href="#L2211">2211</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2212" href="#L2212">2212</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2213" href="#L2213">2213</a>     }
+<a class="jxr_linenumber" name="L2214" href="#L2214">2214</a> 
+<a class="jxr_linenumber" name="L2215" href="#L2215">2215</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2216" href="#L2216">2216</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapDoubleOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2217" href="#L2217">2217</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2218" href="#L2218">2218</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2219" href="#L2219">2219</a>     }
+<a class="jxr_linenumber" name="L2220" href="#L2220">2220</a>     
+<a class="jxr_linenumber" name="L2221" href="#L2221">2221</a>     @Test
+<a class="jxr_linenumber" name="L2222" href="#L2222">2222</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapInt() {
+<a class="jxr_linenumber" name="L2223" href="#L2223">2223</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2224" href="#L2224">2224</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2225" href="#L2225">2225</a>         assertEquals(3, array[0]);
+<a class="jxr_linenumber" name="L2226" href="#L2226">2226</a>         assertEquals(2, array[1]);
+<a class="jxr_linenumber" name="L2227" href="#L2227">2227</a>         assertEquals(1, array[2]);
+<a class="jxr_linenumber" name="L2228" href="#L2228">2228</a>     }
+<a class="jxr_linenumber" name="L2229" href="#L2229">2229</a> 
+<a class="jxr_linenumber" name="L2230" href="#L2230">2230</a>     @Test
+<a class="jxr_linenumber" name="L2231" href="#L2231">2231</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapIntRange() {
+<a class="jxr_linenumber" name="L2232" href="#L2232">2232</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2233" href="#L2233">2233</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2234" href="#L2234">2234</a>         assertEquals(3, array[0]);
+<a class="jxr_linenumber" name="L2235" href="#L2235">2235</a>         assertEquals(4, array[1]);
+<a class="jxr_linenumber" name="L2236" href="#L2236">2236</a>         assertEquals(1, array[2]);
+<a class="jxr_linenumber" name="L2237" href="#L2237">2237</a>         assertEquals(2, array[3]);
+<a class="jxr_linenumber" name="L2238" href="#L2238">2238</a>     }
+<a class="jxr_linenumber" name="L2239" href="#L2239">2239</a>     
+<a class="jxr_linenumber" name="L2240" href="#L2240">2240</a>     @Test
+<a class="jxr_linenumber" name="L2241" href="#L2241">2241</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapIntExchangedOffsets() {
+<a class="jxr_linenumber" name="L2242" href="#L2242">2242</a>         <strong class="jxr_keyword">int</strong>[] array;
+<a class="jxr_linenumber" name="L2243" href="#L2243">2243</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2244" href="#L2244">2244</a>         ArrayUtils.swap(array, 0, 1, 2);
+<a class="jxr_linenumber" name="L2245" href="#L2245">2245</a>         assertArrayEquals(<strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {2, 3, 1}, array);
+<a class="jxr_linenumber" name="L2246" href="#L2246">2246</a>         
+<a class="jxr_linenumber" name="L2247" href="#L2247">2247</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2248" href="#L2248">2248</a>         ArrayUtils.swap(array, 1, 0, 2);
+<a class="jxr_linenumber" name="L2249" href="#L2249">2249</a>         assertArrayEquals(<strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {2, 3, 1}, array);
 <a class="jxr_linenumber" name="L2250" href="#L2250">2250</a>     }
 <a class="jxr_linenumber" name="L2251" href="#L2251">2251</a> 
-<a class="jxr_linenumber" name="L2252" href="#L2252">2252</a>     @Test
-<a class="jxr_linenumber" name="L2253" href="#L2253">2253</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testContainsLong() {
-<a class="jxr_linenumber" name="L2254" href="#L2254">2254</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2255" href="#L2255">2255</a>         assertFalse(ArrayUtils.contains(array, 1));
-<a class="jxr_linenumber" name="L2256" href="#L2256">2256</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2257" href="#L2257">2257</a>         assertTrue(ArrayUtils.contains(array, 0));
-<a class="jxr_linenumber" name="L2258" href="#L2258">2258</a>         assertTrue(ArrayUtils.contains(array, 1));
-<a class="jxr_linenumber" name="L2259" href="#L2259">2259</a>         assertTrue(ArrayUtils.contains(array, 2));
-<a class="jxr_linenumber" name="L2260" href="#L2260">2260</a>         assertTrue(ArrayUtils.contains(array, 3));
-<a class="jxr_linenumber" name="L2261" href="#L2261">2261</a>         assertFalse(ArrayUtils.contains(array, 99));
+<a class="jxr_linenumber" name="L2252" href="#L2252">2252</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2253" href="#L2253">2253</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapIntOutOfRange() {
+<a class="jxr_linenumber" name="L2254" href="#L2254">2254</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2255" href="#L2255">2255</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2256" href="#L2256">2256</a>     }
+<a class="jxr_linenumber" name="L2257" href="#L2257">2257</a> 
+<a class="jxr_linenumber" name="L2258" href="#L2258">2258</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2259" href="#L2259">2259</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapIntOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2260" href="#L2260">2260</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2261" href="#L2261">2261</a>         ArrayUtils.swap(array, 0, 2, 2);
 <a class="jxr_linenumber" name="L2262" href="#L2262">2262</a>     }
 <a class="jxr_linenumber" name="L2263" href="#L2263">2263</a>     
-<a class="jxr_linenumber" name="L2264" href="#L2264">2264</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2265" href="#L2265">2265</a>     @Test
-<a class="jxr_linenumber" name="L2266" href="#L2266">2266</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfInt() {
-<a class="jxr_linenumber" name="L2267" href="#L2267">2267</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2268" href="#L2268">2268</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0));
-<a class="jxr_linenumber" name="L2269" href="#L2269">2269</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2270" href="#L2270">2270</a>         assertEquals(0, ArrayUtils.indexOf(array, 0));
-<a class="jxr_linenumber" name="L2271" href="#L2271">2271</a>         assertEquals(1, ArrayUtils.indexOf(array, 1));
-<a class="jxr_linenumber" name="L2272" href="#L2272">2272</a>         assertEquals(2, ArrayUtils.indexOf(array, 2));
-<a class="jxr_linenumber" name="L2273" href="#L2273">2273</a>         assertEquals(3, ArrayUtils.indexOf(array, 3));
-<a class="jxr_linenumber" name="L2274" href="#L2274">2274</a>         assertEquals(-1, ArrayUtils.indexOf(array, 99));
-<a class="jxr_linenumber" name="L2275" href="#L2275">2275</a>     }
-<a class="jxr_linenumber" name="L2276" href="#L2276">2276</a> 
-<a class="jxr_linenumber" name="L2277" href="#L2277">2277</a>     @Test
-<a class="jxr_linenumber" name="L2278" href="#L2278">2278</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfIntWithStartIndex() {
-<a class="jxr_linenumber" name="L2279" href="#L2279">2279</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2280" href="#L2280">2280</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2281" href="#L2281">2281</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2282" href="#L2282">2282</a>         assertEquals(4, ArrayUtils.indexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2283" href="#L2283">2283</a>         assertEquals(-1, ArrayUtils.indexOf(array, 1, 2));
-<a class="jxr_linenumber" name="L2284" href="#L2284">2284</a>         assertEquals(2, ArrayUtils.indexOf(array, 2, 2));
-<a class="jxr_linenumber" name="L2285" href="#L2285">2285</a>         assertEquals(3, ArrayUtils.indexOf(array, 3, 2));
-<a class="jxr_linenumber" name="L2286" href="#L2286">2286</a>         assertEquals(3, ArrayUtils.indexOf(array, 3, -1));
-<a class="jxr_linenumber" name="L2287" href="#L2287">2287</a>         assertEquals(-1, ArrayUtils.indexOf(array, 99, 0));
-<a class="jxr_linenumber" name="L2288" href="#L2288">2288</a>         assertEquals(-1, ArrayUtils.indexOf(array, 0, 6));
-<a class="jxr_linenumber" name="L2289" href="#L2289">2289</a>     }
-<a class="jxr_linenumber" name="L2290" href="#L2290">2290</a> 
-<a class="jxr_linenumber" name="L2291" href="#L2291">2291</a>     @Test
-<a class="jxr_linenumber" name="L2292" href="#L2292">2292</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfInt() {
-<a class="jxr_linenumber" name="L2293" href="#L2293">2293</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2294" href="#L2294">2294</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 0));
-<a class="jxr_linenumber" name="L2295" href="#L2295">2295</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2296" href="#L2296">2296</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 0));
-<a class="jxr_linenumber" name="L2297" href="#L2297">2297</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 1));
-<a class="jxr_linenumber" name="L2298" href="#L2298">2298</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 2));
-<a class="jxr_linenumber" name="L2299" href="#L2299">2299</a>         assertEquals(3, ArrayUtils.lastIndexOf(array, 3));
-<a class="jxr_linenumber" name="L2300" href="#L2300">2300</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 99));
-<a class="jxr_linenumber" name="L2301" href="#L2301">2301</a>     }
-<a class="jxr_linenumber" name="L2302" href="#L2302">2302</a> 
-<a class="jxr_linenumber" name="L2303" href="#L2303">2303</a>     @Test
-<a class="jxr_linenumber" name="L2304" href="#L2304">2304</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfIntWithStartIndex() {
-<a class="jxr_linenumber" name="L2305" href="#L2305">2305</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2306" href="#L2306">2306</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2307" href="#L2307">2307</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2308" href="#L2308">2308</a>         assertEquals(0, ArrayUtils.lastIndexOf(array, 0, 2));
-<a class="jxr_linenumber" name="L2309" href="#L2309">2309</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 1, 2));
-<a class="jxr_linenumber" name="L2310" href="#L2310">2310</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 2, 2));
-<a class="jxr_linenumber" name="L2311" href="#L2311">2311</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 3, 2));
-<a class="jxr_linenumber" name="L2312" href="#L2312">2312</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 3, -1));
-<a class="jxr_linenumber" name="L2313" href="#L2313">2313</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 99));
-<a class="jxr_linenumber" name="L2314" href="#L2314">2314</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 0, 88));
-<a class="jxr_linenumber" name="L2315" href="#L2315">2315</a>     }
-<a class="jxr_linenumber" name="L2316" href="#L2316">2316</a> 
-<a class="jxr_linenumber" name="L2317" href="#L2317">2317</a>     @Test
-<a class="jxr_linenumber" name="L2318" href="#L2318">2318</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testContainsInt() {
-<a class="jxr_linenumber" name="L2319" href="#L2319">2319</a>         <strong class="jxr_keyword">int</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2320" href="#L2320">2320</a>         assertFalse(ArrayUtils.contains(array, 1));
-<a class="jxr_linenumber" name="L2321" href="#L2321">2321</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">int</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2322" href="#L2322">2322</a>         assertTrue(ArrayUtils.contains(array, 0));
-<a class="jxr_linenumber" name="L2323" href="#L2323">2323</a>         assertTrue(ArrayUtils.contains(array, 1));
-<a class="jxr_linenumber" name="L2324" href="#L2324">2324</a>         assertTrue(ArrayUtils.contains(array, 2));
-<a class="jxr_linenumber" name="L2325" href="#L2325">2325</a>         assertTrue(ArrayUtils.contains(array, 3));
-<a class="jxr_linenumber" name="L2326" href="#L2326">2326</a>         assertFalse(ArrayUtils.contains(array, 99));
-<a class="jxr_linenumber" name="L2327" href="#L2327">2327</a>     }
-<a class="jxr_linenumber" name="L2328" href="#L2328">2328</a>     
-<a class="jxr_linenumber" name="L2329" href="#L2329">2329</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2330" href="#L2330">2330</a>     @Test
-<a class="jxr_linenumber" name="L2331" href="#L2331">2331</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfShort() {
-<a class="jxr_linenumber" name="L2332" href="#L2332">2332</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2333" href="#L2333">2333</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 0));
-<a class="jxr_linenumber" name="L2334" href="#L2334">2334</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2335" href="#L2335">2335</a>         assertEquals(0, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 0));
-<a class="jxr_linenumber" name="L2336" href="#L2336">2336</a>         assertEquals(1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 1));
-<a class="jxr_linenumber" name="L2337" href="#L2337">2337</a>         assertEquals(2, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 2));
-<a class="jxr_linenumber" name="L2338" href="#L2338">2338</a>         assertEquals(3, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 3));
-<a class="jxr_linenumber" name="L2339" href="#L2339">2339</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 99));
-<a class="jxr_linenumber" name="L2340" href="#L2340">2340</a>     }
-<a class="jxr_linenumber" name="L2341" href="#L2341">2341</a> 
-<a class="jxr_linenumber" name="L2342" href="#L2342">2342</a>     @Test
-<a class="jxr_linenumber" name="L2343" href="#L2343">2343</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfShortWithStartIndex() {
-<a class="jxr_linenumber" name="L2344" href="#L2344">2344</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2345" href="#L2345">2345</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 2));
-<a class="jxr_linenumber" name="L2346" href="#L2346">2346</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2347" href="#L2347">2347</a>         assertEquals(4, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 2));
-<a class="jxr_linenumber" name="L2348" href="#L2348">2348</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 1, 2));
-<a class="jxr_linenumber" name="L2349" href="#L2349">2349</a>         assertEquals(2, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 2, 2));
-<a class="jxr_linenumber" name="L2350" href="#L2350">2350</a>         assertEquals(3, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 3, 2));
-<a class="jxr_linenumber" name="L2351" href="#L2351">2351</a>         assertEquals(3, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 3, -1));
-<a class="jxr_linenumber" name="L2352" href="#L2352">2352</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 99, 0));
-<a class="jxr_linenumber" name="L2353" href="#L2353">2353</a>         assertEquals(-1, ArrayUtils.indexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 6));
-<a class="jxr_linenumber" name="L2354" href="#L2354">2354</a>     }
-<a class="jxr_linenumber" name="L2355" href="#L2355">2355</a> 
-<a class="jxr_linenumber" name="L2356" href="#L2356">2356</a>     @Test
-<a class="jxr_linenumber" name="L2357" href="#L2357">2357</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfShort() {
-<a class="jxr_linenumber" name="L2358" href="#L2358">2358</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2359" href="#L2359">2359</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 0));
-<a class="jxr_linenumber" name="L2360" href="#L2360">2360</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2361" href="#L2361">2361</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 0));
-<a class="jxr_linenumber" name="L2362" href="#L2362">2362</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 1));
-<a class="jxr_linenumber" name="L2363" href="#L2363">2363</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 2));
-<a class="jxr_linenumber" name="L2364" href="#L2364">2364</a>         assertEquals(3, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 3));
-<a class="jxr_linenumber" name="L2365" href="#L2365">2365</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 99));
-<a class="jxr_linenumber" name="L2366" href="#L2366">2366</a>     }
-<a class="jxr_linenumber" name="L2367" href="#L2367">2367</a> 
-<a class="jxr_linenumber" name="L2368" href="#L2368">2368</a>     @Test
-<a class="jxr_linenumber" name="L2369" href="#L2369">2369</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfShortWithStartIndex() {
-<a class="jxr_linenumber" name="L2370" href="#L2370">2370</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2371" href="#L2371">2371</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 2));
-<a class="jxr_linenumber" name="L2372" href="#L2372">2372</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2373" href="#L2373">2373</a>         assertEquals(0, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 2));
-<a class="jxr_linenumber" name="L2374" href="#L2374">2374</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 1, 2));
-<a class="jxr_linenumber" name="L2375" href="#L2375">2375</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 2, 2));
-<a class="jxr_linenumber" name="L2376" href="#L2376">2376</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 3, 2));
-<a class="jxr_linenumber" name="L2377" href="#L2377">2377</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 3, -1));
-<a class="jxr_linenumber" name="L2378" href="#L2378">2378</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 99));
-<a class="jxr_linenumber" name="L2379" href="#L2379">2379</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, (<strong class="jxr_keyword">short</strong>) 0, 88));
-<a class="jxr_linenumber" name="L2380" href="#L2380">2380</a>     }
-<a class="jxr_linenumber" name="L2381" href="#L2381">2381</a> 
-<a class="jxr_linenumber" name="L2382" href="#L2382">2382</a>     @Test
-<a class="jxr_linenumber" name="L2383" href="#L2383">2383</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testContainsShort() {
-<a class="jxr_linenumber" name="L2384" href="#L2384">2384</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2385" href="#L2385">2385</a>         assertFalse(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 1));
-<a class="jxr_linenumber" name="L2386" href="#L2386">2386</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2387" href="#L2387">2387</a>         assertTrue(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 0));
-<a class="jxr_linenumber" name="L2388" href="#L2388">2388</a>         assertTrue(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 1));
-<a class="jxr_linenumber" name="L2389" href="#L2389">2389</a>         assertTrue(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 2));
-<a class="jxr_linenumber" name="L2390" href="#L2390">2390</a>         assertTrue(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 3));
-<a class="jxr_linenumber" name="L2391" href="#L2391">2391</a>         assertFalse(ArrayUtils.contains(array, (<strong class="jxr_keyword">short</strong>) 99));
+<a class="jxr_linenumber" name="L2264" href="#L2264">2264</a>     @Test
+<a class="jxr_linenumber" name="L2265" href="#L2265">2265</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapLong() {
+<a class="jxr_linenumber" name="L2266" href="#L2266">2266</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2267" href="#L2267">2267</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2268" href="#L2268">2268</a>         assertEquals(3, array[0]);
+<a class="jxr_linenumber" name="L2269" href="#L2269">2269</a>         assertEquals(2, array[1]);
+<a class="jxr_linenumber" name="L2270" href="#L2270">2270</a>         assertEquals(1, array[2]);
+<a class="jxr_linenumber" name="L2271" href="#L2271">2271</a>     }
+<a class="jxr_linenumber" name="L2272" href="#L2272">2272</a> 
+<a class="jxr_linenumber" name="L2273" href="#L2273">2273</a>     @Test
+<a class="jxr_linenumber" name="L2274" href="#L2274">2274</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapLongRange() {
+<a class="jxr_linenumber" name="L2275" href="#L2275">2275</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2276" href="#L2276">2276</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2277" href="#L2277">2277</a>         assertEquals(3, array[0]);
+<a class="jxr_linenumber" name="L2278" href="#L2278">2278</a>         assertEquals(4, array[1]);
+<a class="jxr_linenumber" name="L2279" href="#L2279">2279</a>         assertEquals(1, array[2]);
+<a class="jxr_linenumber" name="L2280" href="#L2280">2280</a>         assertEquals(2, array[3]);
+<a class="jxr_linenumber" name="L2281" href="#L2281">2281</a>     }
+<a class="jxr_linenumber" name="L2282" href="#L2282">2282</a> 
+<a class="jxr_linenumber" name="L2283" href="#L2283">2283</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2284" href="#L2284">2284</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapLongOutOfRange() {
+<a class="jxr_linenumber" name="L2285" href="#L2285">2285</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2286" href="#L2286">2286</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2287" href="#L2287">2287</a>     }
+<a class="jxr_linenumber" name="L2288" href="#L2288">2288</a> 
+<a class="jxr_linenumber" name="L2289" href="#L2289">2289</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2290" href="#L2290">2290</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapLongOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2291" href="#L2291">2291</a>         <strong class="jxr_keyword">long</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">long</strong>[] {1, 2, 3};
+<a class="jxr_linenumber" name="L2292" href="#L2292">2292</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2293" href="#L2293">2293</a>     }
+<a class="jxr_linenumber" name="L2294" href="#L2294">2294</a> 
+<a class="jxr_linenumber" name="L2295" href="#L2295">2295</a>     @Test
+<a class="jxr_linenumber" name="L2296" href="#L2296">2296</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapObject() {
+<a class="jxr_linenumber" name="L2297" href="#L2297">2297</a>         String[] array = <strong class="jxr_keyword">new</strong> String[] {<span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>};
+<a class="jxr_linenumber" name="L2298" href="#L2298">2298</a>         ArrayUtils.swap(array, 0, 2);
+<a class="jxr_linenumber" name="L2299" href="#L2299">2299</a>         assertEquals(<span class="jxr_string">"3"</span>, array[0]);
+<a class="jxr_linenumber" name="L2300" href="#L2300">2300</a>         assertEquals(<span class="jxr_string">"2"</span>, array[1]);
+<a class="jxr_linenumber" name="L2301" href="#L2301">2301</a>         assertEquals(<span class="jxr_string">"1"</span>, array[2]);
+<a class="jxr_linenumber" name="L2302" href="#L2302">2302</a>     }
+<a class="jxr_linenumber" name="L2303" href="#L2303">2303</a> 
+<a class="jxr_linenumber" name="L2304" href="#L2304">2304</a>     @Test
+<a class="jxr_linenumber" name="L2305" href="#L2305">2305</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapObjectRange() {
+<a class="jxr_linenumber" name="L2306" href="#L2306">2306</a>         String[] array = <strong class="jxr_keyword">new</strong> String[] {<span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>, <span class="jxr_string">"4"</span>};
+<a class="jxr_linenumber" name="L2307" href="#L2307">2307</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2308" href="#L2308">2308</a>         assertEquals(<span class="jxr_string">"3"</span>, array[0]);
+<a class="jxr_linenumber" name="L2309" href="#L2309">2309</a>         assertEquals(<span class="jxr_string">"4"</span>, array[1]);
+<a class="jxr_linenumber" name="L2310" href="#L2310">2310</a>         assertEquals(<span class="jxr_string">"1"</span>, array[2]);
+<a class="jxr_linenumber" name="L2311" href="#L2311">2311</a>         assertEquals(<span class="jxr_string">"2"</span>, array[3]);
+<a class="jxr_linenumber" name="L2312" href="#L2312">2312</a>     }
+<a class="jxr_linenumber" name="L2313" href="#L2313">2313</a> 
+<a class="jxr_linenumber" name="L2314" href="#L2314">2314</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2315" href="#L2315">2315</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapObjectOutOfRange() {
+<a class="jxr_linenumber" name="L2316" href="#L2316">2316</a>         String[] array = <strong class="jxr_keyword">new</strong> String[] {<span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>};
+<a class="jxr_linenumber" name="L2317" href="#L2317">2317</a>         ArrayUtils.swap(array, 0, 3);
+<a class="jxr_linenumber" name="L2318" href="#L2318">2318</a>     }
+<a class="jxr_linenumber" name="L2319" href="#L2319">2319</a> 
+<a class="jxr_linenumber" name="L2320" href="#L2320">2320</a>     @Test(expected = ArrayIndexOutOfBoundsException.<strong class="jxr_keyword">class</strong>)
+<a class="jxr_linenumber" name="L2321" href="#L2321">2321</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testSwapObjectOutOfRangeLen() {
+<a class="jxr_linenumber" name="L2322" href="#L2322">2322</a>         String[] array = <strong class="jxr_keyword">new</strong> String[] {<span class="jxr_string">"1"</span>, <span class="jxr_string">"2"</span>, <span class="jxr_string">"3"</span>};
+<a class="jxr_linenumber" name="L2323" href="#L2323">2323</a>         ArrayUtils.swap(array, 0, 2, 2);
+<a class="jxr_linenumber" name="L2324" href="#L2324">2324</a>     }
+<a class="jxr_linenumber" name="L2325" href="#L2325">2325</a> 
+<a class="jxr_linenumber" name="L2326" href="#L2326">2326</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
+<a class="jxr_linenumber" name="L2327" href="#L2327">2327</a>     @Test
+<a class="jxr_linenumber" name="L2328" href="#L2328">2328</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftDouble() {
+<a class="jxr_linenumber" name="L2329" href="#L2329">2329</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2330" href="#L2330">2330</a>         ArrayUtils.shift(array, 1);
+<a class="jxr_linenumber" name="L2331" href="#L2331">2331</a>         assertEquals(4, array[0], 0);
+<a class="jxr_linenumber" name="L2332" href="#L2332">2332</a>         assertEquals(1, array[1], 0);
+<a class="jxr_linenumber" name="L2333" href="#L2333">2333</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2334" href="#L2334">2334</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2335" href="#L2335">2335</a>         ArrayUtils.shift(array, -1);
+<a class="jxr_linenumber" name="L2336" href="#L2336">2336</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2337" href="#L2337">2337</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2338" href="#L2338">2338</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2339" href="#L2339">2339</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2340" href="#L2340">2340</a>         ArrayUtils.shift(array, 5);
+<a class="jxr_linenumber" name="L2341" href="#L2341">2341</a>         assertEquals(4, array[0], 0);
+<a class="jxr_linenumber" name="L2342" href="#L2342">2342</a>         assertEquals(1, array[1], 0);
+<a class="jxr_linenumber" name="L2343" href="#L2343">2343</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2344" href="#L2344">2344</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2345" href="#L2345">2345</a>         ArrayUtils.shift(array, -3);
+<a class="jxr_linenumber" name="L2346" href="#L2346">2346</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2347" href="#L2347">2347</a>         assertEquals(4, array[1], 0);
+<a class="jxr_linenumber" name="L2348" href="#L2348">2348</a>         assertEquals(1, array[2], 0);
+<a class="jxr_linenumber" name="L2349" href="#L2349">2349</a>         assertEquals(2, array[3], 0);
+<a class="jxr_linenumber" name="L2350" href="#L2350">2350</a>     }
+<a class="jxr_linenumber" name="L2351" href="#L2351">2351</a> 
+<a class="jxr_linenumber" name="L2352" href="#L2352">2352</a>     @Test
+<a class="jxr_linenumber" name="L2353" href="#L2353">2353</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftRangeDouble() {
+<a class="jxr_linenumber" name="L2354" href="#L2354">2354</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3, 4, 5};
+<a class="jxr_linenumber" name="L2355" href="#L2355">2355</a>         ArrayUtils.shift(array, 1, 3, 1);
+<a class="jxr_linenumber" name="L2356" href="#L2356">2356</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2357" href="#L2357">2357</a>         assertEquals(3, array[1], 0);
+<a class="jxr_linenumber" name="L2358" href="#L2358">2358</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2359" href="#L2359">2359</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2360" href="#L2360">2360</a>         assertEquals(5, array[4], 0);
+<a class="jxr_linenumber" name="L2361" href="#L2361">2361</a>         ArrayUtils.shift(array, 1, 4, 2);
+<a class="jxr_linenumber" name="L2362" href="#L2362">2362</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2363" href="#L2363">2363</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2364" href="#L2364">2364</a>         assertEquals(4, array[2], 0);
+<a class="jxr_linenumber" name="L2365" href="#L2365">2365</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2366" href="#L2366">2366</a>         assertEquals(5, array[4], 0);
+<a class="jxr_linenumber" name="L2367" href="#L2367">2367</a>     }
+<a class="jxr_linenumber" name="L2368" href="#L2368">2368</a> 
+<a class="jxr_linenumber" name="L2369" href="#L2369">2369</a>     @Test
+<a class="jxr_linenumber" name="L2370" href="#L2370">2370</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftRangeNoElemDouble() {
+<a class="jxr_linenumber" name="L2371" href="#L2371">2371</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2372" href="#L2372">2372</a>         ArrayUtils.shift(array, 1, 1, 1);
+<a class="jxr_linenumber" name="L2373" href="#L2373">2373</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2374" href="#L2374">2374</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2375" href="#L2375">2375</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2376" href="#L2376">2376</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2377" href="#L2377">2377</a>     }
+<a class="jxr_linenumber" name="L2378" href="#L2378">2378</a> 
+<a class="jxr_linenumber" name="L2379" href="#L2379">2379</a>     @Test
+<a class="jxr_linenumber" name="L2380" href="#L2380">2380</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftAllDouble() {
+<a class="jxr_linenumber" name="L2381" href="#L2381">2381</a>         <strong class="jxr_keyword">double</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">double</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2382" href="#L2382">2382</a>         ArrayUtils.shift(array, 4);
+<a class="jxr_linenumber" name="L2383" href="#L2383">2383</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2384" href="#L2384">2384</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2385" href="#L2385">2385</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2386" href="#L2386">2386</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2387" href="#L2387">2387</a>         ArrayUtils.shift(array, -4);
+<a class="jxr_linenumber" name="L2388" href="#L2388">2388</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2389" href="#L2389">2389</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2390" href="#L2390">2390</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2391" href="#L2391">2391</a>         assertEquals(4, array[3], 0);
 <a class="jxr_linenumber" name="L2392" href="#L2392">2392</a>     }
 <a class="jxr_linenumber" name="L2393" href="#L2393">2393</a>     
-<a class="jxr_linenumber" name="L2394" href="#L2394">2394</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2395" href="#L2395">2395</a>     @Test
-<a class="jxr_linenumber" name="L2396" href="#L2396">2396</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfChar() {
-<a class="jxr_linenumber" name="L2397" href="#L2397">2397</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2398" href="#L2398">2398</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'a'));
-<a class="jxr_linenumber" name="L2399" href="#L2399">2399</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] { 'a', 'b', 'c', 'd', 'a' };
-<a class="jxr_linenumber" name="L2400" href="#L2400">2400</a>         assertEquals(0, ArrayUtils.indexOf(array, 'a'));
-<a class="jxr_linenumber" name="L2401" href="#L2401">2401</a>         assertEquals(1, ArrayUtils.indexOf(array, 'b'));
-<a class="jxr_linenumber" name="L2402" href="#L2402">2402</a>         assertEquals(2, ArrayUtils.indexOf(array, 'c'));
-<a class="jxr_linenumber" name="L2403" href="#L2403">2403</a>         assertEquals(3, ArrayUtils.indexOf(array, 'd'));
-<a class="jxr_linenumber" name="L2404" href="#L2404">2404</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'e'));
-<a class="jxr_linenumber" name="L2405" href="#L2405">2405</a>     }
-<a class="jxr_linenumber" name="L2406" href="#L2406">2406</a> 
-<a class="jxr_linenumber" name="L2407" href="#L2407">2407</a>     @Test
-<a class="jxr_linenumber" name="L2408" href="#L2408">2408</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfCharWithStartIndex() {
-<a class="jxr_linenumber" name="L2409" href="#L2409">2409</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2410" href="#L2410">2410</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'a', 2));
-<a class="jxr_linenumber" name="L2411" href="#L2411">2411</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] { 'a', 'b', 'c', 'd', 'a' };
-<a class="jxr_linenumber" name="L2412" href="#L2412">2412</a>         assertEquals(4, ArrayUtils.indexOf(array, 'a', 2));
-<a class="jxr_linenumber" name="L2413" href="#L2413">2413</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'b', 2));
-<a class="jxr_linenumber" name="L2414" href="#L2414">2414</a>         assertEquals(2, ArrayUtils.indexOf(array, 'c', 2));
-<a class="jxr_linenumber" name="L2415" href="#L2415">2415</a>         assertEquals(3, ArrayUtils.indexOf(array, 'd', 2));
-<a class="jxr_linenumber" name="L2416" href="#L2416">2416</a>         assertEquals(3, ArrayUtils.indexOf(array, 'd', -1));
-<a class="jxr_linenumber" name="L2417" href="#L2417">2417</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'e', 0));
-<a class="jxr_linenumber" name="L2418" href="#L2418">2418</a>         assertEquals(-1, ArrayUtils.indexOf(array, 'a', 6));
-<a class="jxr_linenumber" name="L2419" href="#L2419">2419</a>     }
-<a class="jxr_linenumber" name="L2420" href="#L2420">2420</a> 
-<a class="jxr_linenumber" name="L2421" href="#L2421">2421</a>     @Test
-<a class="jxr_linenumber" name="L2422" href="#L2422">2422</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfChar() {
-<a class="jxr_linenumber" name="L2423" href="#L2423">2423</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2424" href="#L2424">2424</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'a'));
-<a class="jxr_linenumber" name="L2425" href="#L2425">2425</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] { 'a', 'b', 'c', 'd', 'a' };
-<a class="jxr_linenumber" name="L2426" href="#L2426">2426</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 'a'));
-<a class="jxr_linenumber" name="L2427" href="#L2427">2427</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 'b'));
-<a class="jxr_linenumber" name="L2428" href="#L2428">2428</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 'c'));
-<a class="jxr_linenumber" name="L2429" href="#L2429">2429</a>         assertEquals(3, ArrayUtils.lastIndexOf(array, 'd'));
-<a class="jxr_linenumber" name="L2430" href="#L2430">2430</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'e'));
-<a class="jxr_linenumber" name="L2431" href="#L2431">2431</a>     }
-<a class="jxr_linenumber" name="L2432" href="#L2432">2432</a> 
-<a class="jxr_linenumber" name="L2433" href="#L2433">2433</a>     @Test
-<a class="jxr_linenumber" name="L2434" href="#L2434">2434</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testLastIndexOfCharWithStartIndex() {
-<a class="jxr_linenumber" name="L2435" href="#L2435">2435</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2436" href="#L2436">2436</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'a', 2));
-<a class="jxr_linenumber" name="L2437" href="#L2437">2437</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] { 'a', 'b', 'c', 'd', 'a' };
-<a class="jxr_linenumber" name="L2438" href="#L2438">2438</a>         assertEquals(0, ArrayUtils.lastIndexOf(array, 'a', 2));
-<a class="jxr_linenumber" name="L2439" href="#L2439">2439</a>         assertEquals(1, ArrayUtils.lastIndexOf(array, 'b', 2));
-<a class="jxr_linenumber" name="L2440" href="#L2440">2440</a>         assertEquals(2, ArrayUtils.lastIndexOf(array, 'c', 2));
-<a class="jxr_linenumber" name="L2441" href="#L2441">2441</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'd', 2));
-<a class="jxr_linenumber" name="L2442" href="#L2442">2442</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'd', -1));
-<a class="jxr_linenumber" name="L2443" href="#L2443">2443</a>         assertEquals(-1, ArrayUtils.lastIndexOf(array, 'e'));
-<a class="jxr_linenumber" name="L2444" href="#L2444">2444</a>         assertEquals(4, ArrayUtils.lastIndexOf(array, 'a', 88));
-<a class="jxr_linenumber" name="L2445" href="#L2445">2445</a>     }
-<a class="jxr_linenumber" name="L2446" href="#L2446">2446</a> 
-<a class="jxr_linenumber" name="L2447" href="#L2447">2447</a>     @Test
-<a class="jxr_linenumber" name="L2448" href="#L2448">2448</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testContainsChar() {
-<a class="jxr_linenumber" name="L2449" href="#L2449">2449</a>         <strong class="jxr_keyword">char</strong>[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2450" href="#L2450">2450</a>         assertFalse(ArrayUtils.contains(array, 'b'));
-<a class="jxr_linenumber" name="L2451" href="#L2451">2451</a>         array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">char</strong>[] { 'a', 'b', 'c', 'd', 'a' };
-<a class="jxr_linenumber" name="L2452" href="#L2452">2452</a>         assertTrue(ArrayUtils.contains(array, 'a'));
-<a class="jxr_linenumber" name="L2453" href="#L2453">2453</a>         assertTrue(ArrayUtils.contains(array, 'b'));
-<a class="jxr_linenumber" name="L2454" href="#L2454">2454</a>         assertTrue(ArrayUtils.contains(array, 'c'));
-<a class="jxr_linenumber" name="L2455" href="#L2455">2455</a>         assertTrue(ArrayUtils.contains(array, 'd'));
-<a class="jxr_linenumber" name="L2456" href="#L2456">2456</a>         assertFalse(ArrayUtils.contains(array, 'e'));
-<a class="jxr_linenumber" name="L2457" href="#L2457">2457</a>     }
-<a class="jxr_linenumber" name="L2458" href="#L2458">2458</a>     
-<a class="jxr_linenumber" name="L2459" href="#L2459">2459</a>     <em class="jxr_comment">//-----------------------------------------------------------------------</em>
-<a class="jxr_linenumber" name="L2460" href="#L2460">2460</a>     @Test
-<a class="jxr_linenumber" name="L2461" href="#L2461">2461</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfByte() {
-<a class="jxr_linenumber" name="L2462" href="#L2462">2462</a>         byte[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2463" href="#L2463">2463</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 0));
-<a class="jxr_linenumber" name="L2464" href="#L2464">2464</a>         array = <strong class="jxr_keyword">new</strong> byte[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2465" href="#L2465">2465</a>         assertEquals(0, ArrayUtils.indexOf(array, (byte) 0));
-<a class="jxr_linenumber" name="L2466" href="#L2466">2466</a>         assertEquals(1, ArrayUtils.indexOf(array, (byte) 1));
-<a class="jxr_linenumber" name="L2467" href="#L2467">2467</a>         assertEquals(2, ArrayUtils.indexOf(array, (byte) 2));
-<a class="jxr_linenumber" name="L2468" href="#L2468">2468</a>         assertEquals(3, ArrayUtils.indexOf(array, (byte) 3));
-<a class="jxr_linenumber" name="L2469" href="#L2469">2469</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 99));
-<a class="jxr_linenumber" name="L2470" href="#L2470">2470</a>     }
-<a class="jxr_linenumber" name="L2471" href="#L2471">2471</a> 
-<a class="jxr_linenumber" name="L2472" href="#L2472">2472</a>     @Test
-<a class="jxr_linenumber" name="L2473" href="#L2473">2473</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testIndexOfByteWithStartIndex() {
-<a class="jxr_linenumber" name="L2474" href="#L2474">2474</a>         byte[] array = <strong class="jxr_keyword">null</strong>;
-<a class="jxr_linenumber" name="L2475" href="#L2475">2475</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 0, 2));
-<a class="jxr_linenumber" name="L2476" href="#L2476">2476</a>         array = <strong class="jxr_keyword">new</strong> byte[] { 0, 1, 2, 3, 0 };
-<a class="jxr_linenumber" name="L2477" href="#L2477">2477</a>         assertEquals(4, ArrayUtils.indexOf(array, (byte) 0, 2));
-<a class="jxr_linenumber" name="L2478" href="#L2478">2478</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 1, 2));
-<a class="jxr_linenumber" name="L2479" href="#L2479">2479</a>         assertEquals(2, ArrayUtils.indexOf(array, (byte) 2, 2));
-<a class="jxr_linenumber" name="L2480" href="#L2480">2480</a>         assertEquals(3, ArrayUtils.indexOf(array, (byte) 3, 2));
-<a class="jxr_linenumber" name="L2481" href="#L2481">2481</a>         assertEquals(3, ArrayUtils.indexOf(array, (byte) 3, -1));
-<a class="jxr_linenumber" name="L2482" href="#L2482">2482</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 99, 0));
-<a class="jxr_linenumber" name="L2483" href="#L2483">2483</a>         assertEquals(-1, ArrayUtils.indexOf(array, (byte) 0, 6));
+<a class="jxr_linenumber" name="L2394" href="#L2394">2394</a>     @Test
+<a class="jxr_linenumber" name="L2395" href="#L2395">2395</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftFloat() {
+<a class="jxr_linenumber" name="L2396" href="#L2396">2396</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2397" href="#L2397">2397</a>         ArrayUtils.shift(array, 1);
+<a class="jxr_linenumber" name="L2398" href="#L2398">2398</a>         assertEquals(4, array[0], 0);
+<a class="jxr_linenumber" name="L2399" href="#L2399">2399</a>         assertEquals(1, array[1], 0);
+<a class="jxr_linenumber" name="L2400" href="#L2400">2400</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2401" href="#L2401">2401</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2402" href="#L2402">2402</a>         ArrayUtils.shift(array, -1);
+<a class="jxr_linenumber" name="L2403" href="#L2403">2403</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2404" href="#L2404">2404</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2405" href="#L2405">2405</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2406" href="#L2406">2406</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2407" href="#L2407">2407</a>         ArrayUtils.shift(array, 5);
+<a class="jxr_linenumber" name="L2408" href="#L2408">2408</a>         assertEquals(4, array[0], 0);
+<a class="jxr_linenumber" name="L2409" href="#L2409">2409</a>         assertEquals(1, array[1], 0);
+<a class="jxr_linenumber" name="L2410" href="#L2410">2410</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2411" href="#L2411">2411</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2412" href="#L2412">2412</a>         ArrayUtils.shift(array, -3);
+<a class="jxr_linenumber" name="L2413" href="#L2413">2413</a>         assertEquals(3, array[0], 0);
+<a class="jxr_linenumber" name="L2414" href="#L2414">2414</a>         assertEquals(4, array[1], 0);
+<a class="jxr_linenumber" name="L2415" href="#L2415">2415</a>         assertEquals(1, array[2], 0);
+<a class="jxr_linenumber" name="L2416" href="#L2416">2416</a>         assertEquals(2, array[3], 0);
+<a class="jxr_linenumber" name="L2417" href="#L2417">2417</a>     }
+<a class="jxr_linenumber" name="L2418" href="#L2418">2418</a> 
+<a class="jxr_linenumber" name="L2419" href="#L2419">2419</a>     @Test
+<a class="jxr_linenumber" name="L2420" href="#L2420">2420</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftRangeFloat() {
+<a class="jxr_linenumber" name="L2421" href="#L2421">2421</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3, 4, 5};
+<a class="jxr_linenumber" name="L2422" href="#L2422">2422</a>         ArrayUtils.shift(array, 1, 3, 1);
+<a class="jxr_linenumber" name="L2423" href="#L2423">2423</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2424" href="#L2424">2424</a>         assertEquals(3, array[1], 0);
+<a class="jxr_linenumber" name="L2425" href="#L2425">2425</a>         assertEquals(2, array[2], 0);
+<a class="jxr_linenumber" name="L2426" href="#L2426">2426</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2427" href="#L2427">2427</a>         assertEquals(5, array[4], 0);
+<a class="jxr_linenumber" name="L2428" href="#L2428">2428</a>         ArrayUtils.shift(array, 1, 4, 2);
+<a class="jxr_linenumber" name="L2429" href="#L2429">2429</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2430" href="#L2430">2430</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2431" href="#L2431">2431</a>         assertEquals(4, array[2], 0);
+<a class="jxr_linenumber" name="L2432" href="#L2432">2432</a>         assertEquals(3, array[3], 0);
+<a class="jxr_linenumber" name="L2433" href="#L2433">2433</a>         assertEquals(5, array[4], 0);
+<a class="jxr_linenumber" name="L2434" href="#L2434">2434</a>     }
+<a class="jxr_linenumber" name="L2435" href="#L2435">2435</a> 
+<a class="jxr_linenumber" name="L2436" href="#L2436">2436</a>     @Test
+<a class="jxr_linenumber" name="L2437" href="#L2437">2437</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftRangeNoElemFloat() {
+<a class="jxr_linenumber" name="L2438" href="#L2438">2438</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2439" href="#L2439">2439</a>         ArrayUtils.shift(array, 1, 1, 1);
+<a class="jxr_linenumber" name="L2440" href="#L2440">2440</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2441" href="#L2441">2441</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2442" href="#L2442">2442</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2443" href="#L2443">2443</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2444" href="#L2444">2444</a>     }
+<a class="jxr_linenumber" name="L2445" href="#L2445">2445</a> 
+<a class="jxr_linenumber" name="L2446" href="#L2446">2446</a>     @Test
+<a class="jxr_linenumber" name="L2447" href="#L2447">2447</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftAllFloat() {
+<a class="jxr_linenumber" name="L2448" href="#L2448">2448</a>         <strong class="jxr_keyword">float</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">float</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2449" href="#L2449">2449</a>         ArrayUtils.shift(array, 4);
+<a class="jxr_linenumber" name="L2450" href="#L2450">2450</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2451" href="#L2451">2451</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2452" href="#L2452">2452</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2453" href="#L2453">2453</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2454" href="#L2454">2454</a>         ArrayUtils.shift(array, -4);
+<a class="jxr_linenumber" name="L2455" href="#L2455">2455</a>         assertEquals(1, array[0], 0);
+<a class="jxr_linenumber" name="L2456" href="#L2456">2456</a>         assertEquals(2, array[1], 0);
+<a class="jxr_linenumber" name="L2457" href="#L2457">2457</a>         assertEquals(3, array[2], 0);
+<a class="jxr_linenumber" name="L2458" href="#L2458">2458</a>         assertEquals(4, array[3], 0);
+<a class="jxr_linenumber" name="L2459" href="#L2459">2459</a>     }
+<a class="jxr_linenumber" name="L2460" href="#L2460">2460</a>     
+<a class="jxr_linenumber" name="L2461" href="#L2461">2461</a>     @Test
+<a class="jxr_linenumber" name="L2462" href="#L2462">2462</a>     <strong class="jxr_keyword">public</strong> <strong class="jxr_keyword">void</strong> testShiftShort() {
+<a class="jxr_linenumber" name="L2463" href="#L2463">2463</a>         <strong class="jxr_keyword">short</strong>[] array = <strong class="jxr_keyword">new</strong> <strong class="jxr_keyword">short</strong>[] {1, 2, 3, 4};
+<a class="jxr_linenumber" name="L2464" href="#L2464">2464</a>         ArrayUtils.shift(array, 1);
+<a class="jxr_linenumber" name="L2465" href="#L2465">2465</a>         assertEquals(4, array[0]);
+<a class="jxr_linenumber" name="L2466" href="#L2466">2466</a>         assertEquals(1, array[1]);
+<a class="jxr_linenumber" name="L2467" href="#L2467">2467</a>         assertEquals(2, array[2]);
+<a class="jxr_linenumber" name="L2468" href="#L2468">2468</a>         assertEquals(3, array[3]);
+<a class="jxr_linenumber" name="L2469" href="#L2469">2469</a>         ArrayUtils.shift(array, -1);

[... 3101 lines stripped ...]


Mime
View raw message