<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Actionscript Vector class initialization with a source Array</title>
	<atom:link href="http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/</link>
	<description>Objective C, iOS and more programming stuff</description>
	<lastBuildDate>Fri, 03 Feb 2012 17:32:12 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: INS</title>
		<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/comment-page-1/#comment-47587</link>
		<dc:creator>INS</dc:creator>
		<pubDate>Mon, 26 Dec 2011 16:03:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=367#comment-47587</guid>
		<description>How about this?
var vector:Vector. = new [&quot;v1&quot;, &quot;v2&quot;, &quot;v3&quot;];

A bit shorter than this one.
var vector:Vector. = Vector.([&quot;v1&quot;, &quot;v2&quot;, &quot;v3&quot;]);</description>
		<content:encoded><![CDATA[<p>How about this?<br />
var vector:Vector. = new ["v1", "v2", "v3"];</p>
<p>A bit shorter than this one.<br />
var vector:Vector. = Vector.(["v1", "v2", "v3"]);</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Marius</title>
		<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/comment-page-1/#comment-12372</link>
		<dc:creator>Marius</dc:creator>
		<pubDate>Tue, 16 Nov 2010 20:15:33 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=367#comment-12372</guid>
		<description>Thanks very much, saved me time when I rewrote a 2D Array into a Vector.&lt;Vector.&gt;.
Otherwise I&#039;d have had to feed my World-Vector from an Array which sounded awkward to me ;-)</description>
		<content:encoded><![CDATA[<p>Thanks very much, saved me time when I rewrote a 2D Array into a Vector.&lt;Vector.&gt;.<br />
Otherwise I&#8217;d have had to feed my World-Vector from an Array which sounded awkward to me ;-)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gary Paluk</title>
		<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/comment-page-1/#comment-4436</link>
		<dc:creator>Gary Paluk</dc:creator>
		<pubDate>Sun, 03 Jan 2010 21:36:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=367#comment-4436</guid>
		<description>Please note, the type declairations were stripped out of the example code given above. The first example was cast as String and the second example were cast as uint.

Gary Paluk aka RipX</description>
		<content:encoded><![CDATA[<p>Please note, the type declairations were stripped out of the example code given above. The first example was cast as String and the second example were cast as uint.</p>
<p>Gary Paluk aka RipX</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gary Paluk</title>
		<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/comment-page-1/#comment-4418</link>
		<dc:creator>Gary Paluk</dc:creator>
		<pubDate>Sun, 03 Jan 2010 00:58:29 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=367#comment-4418</guid>
		<description>BEWARE of instantiating your Vectors in this way as it exhibits random casting behaviours and using an incorrect datatype will NOT throw a compile Error, it will sometimes silently cast the datatype to that specified in the Vector and default to its construction value. Also, compilers will generally give you the Vector specified data type API (as expected) causing invalid method invocation and potential bugs.

The following two examples show this in action:

var vector:Vector. = Vector.( [&quot;hello&quot;, new Point4d(), &quot;world&quot;] );
trace( vector[1] );

The above code traces the toString(): String return value contained in my Point4d object, however:

var vector:Vector. = Vector.( [ 5, new Point4d(), 4] );
trace( vector[1] );

traces 0

Yikes, to conclude, if you want compile type data type checking and no silent hidden data casting, avoid this at all costs.

Gary Paluk aka RipX</description>
		<content:encoded><![CDATA[<p>BEWARE of instantiating your Vectors in this way as it exhibits random casting behaviours and using an incorrect datatype will NOT throw a compile Error, it will sometimes silently cast the datatype to that specified in the Vector and default to its construction value. Also, compilers will generally give you the Vector specified data type API (as expected) causing invalid method invocation and potential bugs.</p>
<p>The following two examples show this in action:</p>
<p>var vector:Vector. = Vector.( ["hello", new Point4d(), "world"] );<br />
trace( vector[1] );</p>
<p>The above code traces the toString(): String return value contained in my Point4d object, however:</p>
<p>var vector:Vector. = Vector.( [ 5, new Point4d(), 4] );<br />
trace( vector[1] );</p>
<p>traces 0</p>
<p>Yikes, to conclude, if you want compile type data type checking and no silent hidden data casting, avoid this at all costs.</p>
<p>Gary Paluk aka RipX</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: JaneRadriges</title>
		<link>http://www.daveoncode.com/2009/04/06/actionscript-vector-class-initialization-with-a-source-array/comment-page-1/#comment-2189</link>
		<dc:creator>JaneRadriges</dc:creator>
		<pubDate>Sat, 13 Jun 2009 20:30:03 +0000</pubDate>
		<guid isPermaLink="false">http://www.daveoncode.com/?p=367#comment-2189</guid>
		<description>The best information i have found exactly here. Keep going Thank you</description>
		<content:encoded><![CDATA[<p>The best information i have found exactly here. Keep going Thank you</p>
]]></content:encoded>
	</item>
</channel>
</rss>

