<?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/"
	xmlns:georss="http://www.georss.org/georss" xmlns:geo="http://www.w3.org/2003/01/geo/wgs84_pos#" xmlns:media="http://search.yahoo.com/mrss/"
		>
<channel>
	<title>Comments on: Mapping Action Script objects to Java objects</title>
	<atom:link href="http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/feed/" rel="self" type="application/rss+xml" />
	<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/</link>
	<description></description>
	<lastBuildDate>Mon, 16 Nov 2009 08:57:21 +0000</lastBuildDate>
	<generator>http://wordpress.com/</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: kalondar</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27825</link>
		<dc:creator>kalondar</dc:creator>
		<pubDate>Wed, 04 Nov 2009 12:46:57 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27825</guid>
		<description>Simple solution for below exception when you using List list in your java code:
(for OurDTOFlex in flex side)

&quot;ClassCastException : flex.messaging.io.amf.ASObject cannot be cast to ourpackage.OurDTO&quot;

Just type this whenever in flex side:

var dummy:OurDTOFlex = new OurDTOFlex ();

Strange but it works :)</description>
		<content:encoded><![CDATA[<p>Simple solution for below exception when you using List list in your java code:<br />
(for OurDTOFlex in flex side)</p>
<p>&#8220;ClassCastException : flex.messaging.io.amf.ASObject cannot be cast to ourpackage.OurDTO&#8221;</p>
<p>Just type this whenever in flex side:</p>
<p>var dummy:OurDTOFlex = new OurDTOFlex ();</p>
<p>Strange but it works <img src='http://s.wordpress.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sujit Reddy G</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27449</link>
		<dc:creator>Sujit Reddy G</dc:creator>
		<pubDate>Fri, 28 Aug 2009 13:59:25 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27449</guid>
		<description>Hi Ivan,

You should be writing a labelFunction to handle this case. Please find details at this URL http://livedocs.adobe.com/flex/3/langref/mx/controls/listClasses/ListBase.html#labelFunction

Hope this helps.</description>
		<content:encoded><![CDATA[<p>Hi Ivan,</p>
<p>You should be writing a labelFunction to handle this case. Please find details at this URL <a href="http://livedocs.adobe.com/flex/3/langref/mx/controls/listClasses/ListBase.html#labelFunction" rel="nofollow">http://livedocs.adobe.com/flex/3/langref/mx/controls/listClasses/ListBase.html#labelFunction</a></p>
<p>Hope this helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sujit Reddy G</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27424</link>
		<dc:creator>Sujit Reddy G</dc:creator>
		<pubDate>Fri, 28 Aug 2009 12:52:26 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27424</guid>
		<description>Hi Jesse,

Please try sharing your Java and AS3 VO classes.</description>
		<content:encoded><![CDATA[<p>Hi Jesse,</p>
<p>Please try sharing your Java and AS3 VO classes.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ivan Yiu</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27370</link>
		<dc:creator>Ivan Yiu</dc:creator>
		<pubDate>Tue, 18 Aug 2009 15:00:03 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27370</guid>
		<description>I&#039;ve problem on the nested remote object also.

I want to populate the object in a DataGrid, say:
Class Person {
Address address;
String name;
}

The name can be retrieve by using datafield=&quot;name&quot;.

But when I use datafield=&quot;address.street&quot;, the output is empty, please kindly help...</description>
		<content:encoded><![CDATA[<p>I&#8217;ve problem on the nested remote object also.</p>
<p>I want to populate the object in a DataGrid, say:<br />
Class Person {<br />
Address address;<br />
String name;<br />
}</p>
<p>The name can be retrieve by using datafield=&#8221;name&#8221;.</p>
<p>But when I use datafield=&#8221;address.street&#8221;, the output is empty, please kindly help&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jesse</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27287</link>
		<dc:creator>Jesse</dc:creator>
		<pubDate>Mon, 27 Jul 2009 14:55:23 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27287</guid>
		<description>Hi, thank you so much for this blog posting.  It has been a great help.  

I have got my flex remoting up and running, but I am having a problem with collections.  I have data that is more or less in a tree like structure.  The class that gets sent from the server to flex has ArrayList&#039;s of other classes.  

These lists have data in them when the server method returns, but on the flex side they have length = 0.  The classes in the lists are also mapped to actionscript classes.  The List fields themselves are mapped in actionscript as ArrayCollection&#039;s. 

Other&#039;s have posted similar issues, but I have not seen a comment post that explains a resolution.  Any help would be greatly appreciated... this blog post has helped me a lot already!  Thanks.</description>
		<content:encoded><![CDATA[<p>Hi, thank you so much for this blog posting.  It has been a great help.  </p>
<p>I have got my flex remoting up and running, but I am having a problem with collections.  I have data that is more or less in a tree like structure.  The class that gets sent from the server to flex has ArrayList&#8217;s of other classes.  </p>
<p>These lists have data in them when the server method returns, but on the flex side they have length = 0.  The classes in the lists are also mapped to actionscript classes.  The List fields themselves are mapped in actionscript as ArrayCollection&#8217;s. </p>
<p>Other&#8217;s have posted similar issues, but I have not seen a comment post that explains a resolution.  Any help would be greatly appreciated&#8230; this blog post has helped me a lot already!  Thanks.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: manu</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27230</link>
		<dc:creator>manu</dc:creator>
		<pubDate>Mon, 20 Jul 2009 06:02:17 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27230</guid>
		<description>I have used blazeds+flex builder in my project where i have to collect around more than 100000 records from the database. Data brought to the client as list of java bean object through remoting where there is   an action script object corresponding to java bean as explained in this blog.  But the problem is that it takes more than a minute to bring data from the server to the client. Is there anyway to display data in a datagrid as the data is coming from the server.

With thanks
Manu</description>
		<content:encoded><![CDATA[<p>I have used blazeds+flex builder in my project where i have to collect around more than 100000 records from the database. Data brought to the client as list of java bean object through remoting where there is   an action script object corresponding to java bean as explained in this blog.  But the problem is that it takes more than a minute to bring data from the server to the client. Is there anyway to display data in a datagrid as the data is coming from the server.</p>
<p>With thanks<br />
Manu</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Luigi</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27082</link>
		<dc:creator>Luigi</dc:creator>
		<pubDate>Fri, 03 Jul 2009 13:35:56 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-27082</guid>
		<description>Hello, I&#039;ve a similar problem mapping java class in flex.
I&#039;d like to map a java inner class in a flex class as follow:

[code]
package myPack;

public class MyClass {

    public String a;

    MyClass() {
    }

    public Class MySubClass {
        public String b;

        MySubClass() {
        }

    }

}
[/code]

And this is the flex class:

[code]
package
{
    
    [RemoteClass(alias=&quot;myPack.MyClass$MySubClass&quot;)] 
    public class MySubClass
    {
        public function MySubClass()
        {
        }

        public var b:String;

    }
}
[/code]

But I got this error message:
2009-07-03 15:33:26,531 INFO  [STDOUT] [Flex] 07/03/2009 15:33:26.531 [ERROR] [Endpoint.AMF] Unable to create a new instance of type &#039;myPack.MyClass$MySubClass&#039;.
flex.messaging.MessageException: Unable to create a new instance of type &#039;myPack.MyClass$MySubClass&#039;. Types cannot be instantiated without a public, no arguments constructor.
	at flex.messaging.util.ClassUtil.createDefaultInstance(ClassUtil.java:143)
	at flex.messaging.io.AbstractProxy.createInstance(AbstractProxy.java:86)
	at flex.messaging.io.amf.Amf3Input.readScriptObject(Amf3Input.java:409)
[etc]

Suggestion? Thanks in advance</description>
		<content:encoded><![CDATA[<p>Hello, I&#8217;ve a similar problem mapping java class in flex.<br />
I&#8217;d like to map a java inner class in a flex class as follow:</p>
<pre class="brush: plain;">
package myPack;

public class MyClass {

    public String a;

    MyClass() {
    }

    public Class MySubClass {
        public String b;

        MySubClass() {
        }

    }

}
</pre>
<p>And this is the flex class:</p>
<pre class="brush: plain;">
package
{

    [RemoteClass(alias="myPack.MyClass$MySubClass")]
    public class MySubClass
    {
        public function MySubClass()
        {
        }

        public var b:String;

    }
}
</pre>
<p>But I got this error message:<br />
2009-07-03 15:33:26,531 INFO  [STDOUT] [Flex] 07/03/2009 15:33:26.531 [ERROR] [Endpoint.AMF] Unable to create a new instance of type &#8216;myPack.MyClass$MySubClass&#8217;.<br />
flex.messaging.MessageException: Unable to create a new instance of type &#8216;myPack.MyClass$MySubClass&#8217;. Types cannot be instantiated without a public, no arguments constructor.<br />
	at flex.messaging.util.ClassUtil.createDefaultInstance(ClassUtil.java:143)<br />
	at flex.messaging.io.AbstractProxy.createInstance(AbstractProxy.java:86)<br />
	at flex.messaging.io.amf.Amf3Input.readScriptObject(Amf3Input.java:409)<br />
[etc]</p>
<p>Suggestion? Thanks in advance</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: udaychow</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-25260</link>
		<dc:creator>udaychow</dc:creator>
		<pubDate>Fri, 12 Jun 2009 10:39:37 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-25260</guid>
		<description>Hi Sujit,

              I had seen your blog very recently and very much impressed with ur blogs.I had seen ur code ,communication between flex and java with remoteobject and Blaze.I tried exactly with ur code by copy pasre, but unable to get the output.Currently im using Flex Builder 3.0 with WTP.Can u just help me out in this regard.My mail id is udayshankar.tummala@gmail.com</description>
		<content:encoded><![CDATA[<p>Hi Sujit,</p>
<p>              I had seen your blog very recently and very much impressed with ur blogs.I had seen ur code ,communication between flex and java with remoteobject and Blaze.I tried exactly with ur code by copy pasre, but unable to get the output.Currently im using Flex Builder 3.0 with WTP.Can u just help me out in this regard.My mail id is <a href="mailto:udayshankar.tummala@gmail.com">udayshankar.tummala@gmail.com</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sandeep Reddy</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-23403</link>
		<dc:creator>Sandeep Reddy</dc:creator>
		<pubDate>Fri, 29 May 2009 13:53:32 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-23403</guid>
		<description>Hi Sujit,

I am using RemoteObject calls in flex. When I am returning a custom object (which contains two list properties) to the flex i am getting null as the response at flex side.
What could be done to resolve the above problem.
Similer posts i have seen above but i didn&#039;e see any answers for the same.
Can you replay on the same.
Thanks in advance.</description>
		<content:encoded><![CDATA[<p>Hi Sujit,</p>
<p>I am using RemoteObject calls in flex. When I am returning a custom object (which contains two list properties) to the flex i am getting null as the response at flex side.<br />
What could be done to resolve the above problem.<br />
Similer posts i have seen above but i didn&#8217;e see any answers for the same.<br />
Can you replay on the same.<br />
Thanks in advance.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jan</title>
		<link>http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-22412</link>
		<dc:creator>Jan</dc:creator>
		<pubDate>Wed, 20 May 2009 09:59:34 +0000</pubDate>
		<guid isPermaLink="false">http://sujitreddyg.wordpress.com/2008/01/16/mapping-action-script-objects-to-java-objects/#comment-22412</guid>
		<description>Hello,

For all you people who are having collections of ASObjects on the server side :

I had the same issue. In my case it seemed to be caused by the fact that when I sent it from server to client, I did not actively use the items in the collection. This meant (I think) that the objects in there were never properly transformed to their flex-side counterpart. When being sent back to the server, this caused them to become (or remain?) ASObjects.

When I iterated through the collection on the flex-side, casting them to their flex-side types, all worked fine later on when going back to the server:

for (var i:Number = 0; i &lt; objecta.objectbcollection.length; i++)
			var objectb:Objectb = Objectb(objecta.objectbcollection.getItemAt(i));

Interested to see if this works for you.</description>
		<content:encoded><![CDATA[<p>Hello,</p>
<p>For all you people who are having collections of ASObjects on the server side :</p>
<p>I had the same issue. In my case it seemed to be caused by the fact that when I sent it from server to client, I did not actively use the items in the collection. This meant (I think) that the objects in there were never properly transformed to their flex-side counterpart. When being sent back to the server, this caused them to become (or remain?) ASObjects.</p>
<p>When I iterated through the collection on the flex-side, casting them to their flex-side types, all worked fine later on when going back to the server:</p>
<p>for (var i:Number = 0; i &lt; objecta.objectbcollection.length; i++)<br />
			var objectb:Objectb = Objectb(objecta.objectbcollection.getItemAt(i));</p>
<p>Interested to see if this works for you.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
