<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>web development helpdesk &#187; array</title>
	<atom:link href="http://helpdesk.objects.com.au/tag/array/feed" rel="self" type="application/rss+xml" />
	<link>http://helpdesk.objects.com.au</link>
	<description>objects quality - the visible difference</description>
	<lastBuildDate>Sun, 17 Jul 2011 12:27:36 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.1.4</generator>
		<item>
		<title>Shuffle a Java array</title>
		<link>http://helpdesk.objects.com.au/java/shuffle-a-java-array?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=shuffle-a-java-array</link>
		<comments>http://helpdesk.objects.com.au/java/shuffle-a-java-array#comments</comments>
		<pubDate>Fri, 26 Nov 2010 22:06:38 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[arrays]]></category>
		<category><![CDATA[collections]]></category>
		<category><![CDATA[random]]></category>
		<category><![CDATA[shuffle]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1672</guid>
		<description><![CDATA[Sometimes we need to shuffle the oder of elements in a list or array, like shuffling a deck of cards. The Collections utility class has a shuffle() method that achieves this for List&#8217;s, but what about arrays. There is no corresponding shuffle() method in the Arrays class, surely we don&#8217;t need to loop through the [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/shuffle-a-java-array/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to get Class object for an array</title>
		<link>http://helpdesk.objects.com.au/java/how-to-get-class-object-for-an-array?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-get-class-object-for-an-array</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-get-class-object-for-an-array#comments</comments>
		<pubDate>Sat, 23 Oct 2010 04:04:17 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[class]]></category>
		<category><![CDATA[reflection]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1600</guid>
		<description><![CDATA[Arrays in Java are actually Objects and sometimes we need to get the Class instance for an array object. An example would be when using reflection to get a method that takes an array as an argument. Here&#8217;s an example for getting the Class instance for a string array. Class arrayClass = String[].class; Related posts: [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-get-class-object-for-an-array/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to sort Java array using custom ordering</title>
		<link>http://helpdesk.objects.com.au/java/how-to-sort-java-array-using-custom-ordering?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-sort-java-array-using-custom-ordering</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-sort-java-array-using-custom-ordering#comments</comments>
		<pubDate>Thu, 04 Mar 2010 01:30:08 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[comparable]]></category>
		<category><![CDATA[comparator]]></category>
		<category><![CDATA[sort]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1415</guid>
		<description><![CDATA[Java provides a convenient Arrays.sort() method to sort an array of Object&#8217;s. The Objects in the array are required to implement the Comparable interface and the compareTo() method is used to compare Objects. When an alternate sort order is needed you can do that using a Comparator which is passed to the sort() call. The [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-sort-java-array-using-custom-ordering/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to convert byte array to long</title>
		<link>http://helpdesk.objects.com.au/java/how-to-convert-byte-array-to-long?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-convert-byte-array-to-long</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-convert-byte-array-to-long#comments</comments>
		<pubDate>Tue, 17 Nov 2009 21:25:27 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[byte array]]></category>
		<category><![CDATA[conversion]]></category>
		<category><![CDATA[long]]></category>
		<category><![CDATA[representation]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1291</guid>
		<description><![CDATA[The following code can be used to convert a byte array (containing the bytes of a long) into a long. public static long byteArrayToLong(byte[] bytes) { long l = 0; for (int i=0; i&#60;8; i++) { l &#60;&#60;= 8; l ^= (long) bytes[i] &#38; 0xff; } return l; } This is the reverse of &#8220;How [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-convert-byte-array-to-long/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Search a byte array for a byte sequence</title>
		<link>http://helpdesk.objects.com.au/java/search-a-byte-array-for-a-byte-sequence?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=search-a-byte-array-for-a-byte-sequence</link>
		<comments>http://helpdesk.objects.com.au/java/search-a-byte-array-for-a-byte-sequence#comments</comments>
		<pubDate>Fri, 02 Oct 2009 06:15:15 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[byte]]></category>
		<category><![CDATA[match]]></category>
		<category><![CDATA[Pattern]]></category>
		<category><![CDATA[search]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1237</guid>
		<description><![CDATA[The Knuth-Morris-Pratt Pattern Matching Algorithm can be used to search a byte array. public class KPM { /** * Search the data byte array for the first occurrence * of the byte array pattern. */ public static int indexOf(byte[] data, byte[] pattern) { int[] failure = computeFailure(pattern); int j = 0; for (int i = [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/search-a-byte-array-for-a-byte-sequence/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to convert a long to a byte array</title>
		<link>http://helpdesk.objects.com.au/java/how-to-convert-a-long-to-a-byte-array?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-convert-a-long-to-a-byte-array</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-convert-a-long-to-a-byte-array#comments</comments>
		<pubDate>Fri, 15 May 2009 23:03:23 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[byte array]]></category>
		<category><![CDATA[conversion]]></category>
		<category><![CDATA[long]]></category>
		<category><![CDATA[representation]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1161</guid>
		<description><![CDATA[The following code can be used to extract the 8 bytes from a long value and return them as a byte array public static byte[] longToByteArray(long data) { return new byte[] { (byte)((data &#62;&#62; 56) &#38; 0xff), (byte)((data &#62;&#62; 48) &#38; 0xff), (byte)((data &#62;&#62; 40) &#38; 0xff), (byte)((data &#62;&#62; 32) &#38; 0xff), (byte)((data &#62;&#62; 24) [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-convert-a-long-to-a-byte-array/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Calculating breakdown of change</title>
		<link>http://helpdesk.objects.com.au/java/calculating-breakdown-of-change?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=calculating-breakdown-of-change</link>
		<comments>http://helpdesk.objects.com.au/java/calculating-breakdown-of-change#comments</comments>
		<pubDate>Sun, 03 May 2009 23:00:00 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[change]]></category>
		<category><![CDATA[Currency]]></category>
		<category><![CDATA[loop]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=1375</guid>
		<description><![CDATA[Following shows how to use a loop to determine the breakdown of change for a given amount, minimising the number of notes and coins used. int[] denominations = { 500, 200, 100, 50, 20, 10, 5, 2, 1 }; int amount = 687; int[] count = new int[denominations.length]; for (int i=0; i&#60;denominations.length; i++) { while [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/calculating-breakdown-of-change/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to map an array using hibernate?</title>
		<link>http://helpdesk.objects.com.au/java/how-to-map-an-array-using-hibernate?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-map-an-array-using-hibernate</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-map-an-array-using-hibernate#comments</comments>
		<pubDate>Mon, 20 Apr 2009 10:12:45 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[hibernate]]></category>
		<category><![CDATA[mapping]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=907</guid>
		<description><![CDATA[The mapping configuration can vary a little depending on the exact relationship involved but the following example should give you an isea what is required. In this example there is a one-to-many relationship to the objects in the array. The Parent class has array of Child instances as a property. public class Parent { private [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-map-an-array-using-hibernate/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to convert an array to a String?</title>
		<link>http://helpdesk.objects.com.au/java/how-to-convert-an-array-to-a-string?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-convert-an-array-to-a-string</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-convert-an-array-to-a-string#comments</comments>
		<pubDate>Thu, 05 Feb 2009 02:38:49 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[arrays]]></category>
		<category><![CDATA[convert]]></category>
		<category><![CDATA[string]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=758</guid>
		<description><![CDATA[The Arrays class has a set of helper toString methods for converting an array to a string representation. String representation = Arrays.toString(array); This will work for all array types. For Objects it uses the toString() method of the type to convert array elements. If you need more control how the array is represented then you [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-convert-an-array-to-a-string/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>How to check if two Java arrays are equal?</title>
		<link>http://helpdesk.objects.com.au/java/how-to-check-if-two-java-arrays-are-equal?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=how-to-check-if-two-java-arrays-are-equal</link>
		<comments>http://helpdesk.objects.com.au/java/how-to-check-if-two-java-arrays-are-equal#comments</comments>
		<pubDate>Fri, 30 Jan 2009 09:00:07 +0000</pubDate>
		<dc:creator>objects</dc:creator>
				<category><![CDATA[java]]></category>
		<category><![CDATA[array]]></category>
		<category><![CDATA[arrays]]></category>
		<category><![CDATA[equals]]></category>

		<guid isPermaLink="false">http://helpdesk.objects.com.au/?p=720</guid>
		<description><![CDATA[The Arrays class includes methods for testing the equality of two array. Two arrays are considered equal if both arrays contain the same number of elements, and all corresponding pairs of elements in the two arrays are equal. if (Arrays.equals(array1, array2)) { // array1 and array2 contain the same elements in the same order } [...]]]></description>
		<wfw:commentRss>http://helpdesk.objects.com.au/java/how-to-check-if-two-java-arrays-are-equal/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

