You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ca...@apache.org on 2018/10/02 16:56:55 UTC

[royale-asjs] branch develop updated: New RemoteObjectAMFTestBasic

This is an automated email from the ASF dual-hosted git repository.

carlosrovira pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git


The following commit(s) were added to refs/heads/develop by this push:
     new ac7258a  New RemoteObjectAMFTestBasic
ac7258a is described below

commit ac7258a44352aae7aeb87b8298b4306145af050f
Author: Carlos Rovira <ca...@apache.org>
AuthorDate: Tue Oct 2 18:56:48 2018 +0200

    New RemoteObjectAMFTestBasic
---
 .../RemoteObjectAMFTestBasic.as3proj               |  89 +++++++++
 .../royale/RemoteObjectAMFTestBasic/asconfig.json  |  31 ++++
 examples/royale/RemoteObjectAMFTestBasic/build.xml |  73 ++++++++
 examples/royale/RemoteObjectAMFTestBasic/pom.xml   | 104 +++++++++++
 .../src/main/config/compile-app-config.xml         |  21 +++
 .../src/main/resources/styles.css                  |  30 +++
 .../src/main/royale/App.mxml                       | 203 +++++++++++++++++++++
 .../main/royale/valueObjects/ClientValueObject.as  |  41 +++++
 .../src/main/royale/valueObjects/Product.as        |  90 +++++++++
 .../src/main/royale/valueObjects/Taxonomy.as       |  52 ++++++
 .../src/main/royale/valueObjects/Zone.as           |  52 ++++++
 11 files changed, 786 insertions(+)

diff --git a/examples/royale/RemoteObjectAMFTestBasic/RemoteObjectAMFTestBasic.as3proj b/examples/royale/RemoteObjectAMFTestBasic/RemoteObjectAMFTestBasic.as3proj
new file mode 100644
index 0000000..7c25b46
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/RemoteObjectAMFTestBasic.as3proj
@@ -0,0 +1,89 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<project>
+  <output>
+    <movie version="11"/>
+    <movie disabled="False"/>
+    <movie height="600"/>
+    <movie fps="60"/>
+    <movie background="#FFFFFF"/>
+    <movie path="bin-debug/App.swf"/>
+    <movie width="800"/>
+    <movie input=""/>
+  </output>
+  &lt;!-- Other classes to be compiled into your SWF --&gt;
+  <classpaths>
+    <class path="src/main/royale"/>
+  </classpaths>
+  <moonshineResourcePaths></moonshineResourcePaths>
+  <build>
+    <option customSDK=""/>
+    <option strict="True"/>
+    <option accessible="False"/>
+    <option useNetwork="True"/>
+    <option allowSourcePathOverlap="False"/>
+    <option useResourceBundleMetadata="True"/>
+    <option benchmark="False"/>
+    <option warnings="True"/>
+    <option additional=""/>
+    <option es="False"/>
+    <option locale=""/>
+    <option loadConfig=""/>
+    <option linkReport=""/>
+    <option optimize="False"/>
+    <option verboseStackTraces="False"/>
+    <option staticLinkRSL="False"/>
+    <option showBindingWarnings="True"/>
+    <option compilerConstants=""/>
+    <option showDeprecationWarnings="True"/>
+    <option antBuildPath="build/build.xml"/>
+    <option showActionScriptWarnings="True"/>
+    <option showUnusedTypeSelectorWarnings="True"/>
+  </build>
+  <includeLibraries></includeLibraries>
+  <libraryPaths></libraryPaths>
+  <externalLibraryPaths></externalLibraryPaths>
+  <rslPaths></rslPaths>
+  <intrinsics></intrinsics>
+  <library></library>
+  <compileTargets>
+    <compile path="src/main/royale/App.mxml"/>
+  </compileTargets>
+  <hiddenPaths></hiddenPaths>
+  <preBuildCommand>null</preBuildCommand>
+  <postBuildCommand alwaysRun="False">null</postBuildCommand>
+  <options>
+    <option defaultBuildTargets=""/>
+    <option testMovie=""/>
+    <option testMovieCommand=""/>
+    <option showHiddenPaths="False"/>
+  </options>
+  <moonshineRunCustomization>
+    <option deviceSimulator="null"/>
+    <option targetPlatform="2"/>
+    <option projectType="2"/>
+    <option launchMethod="Simulator"/>
+    <option urlToLaunch=""/>
+    <deviceSimulator>null</deviceSimulator>
+    <certAndroid>null</certAndroid>
+    <certIos>null</certIos>
+    <certIosProvisioning>null</certIosProvisioning>
+  </moonshineRunCustomization>
+</project>
\ No newline at end of file
diff --git a/examples/royale/RemoteObjectAMFTestBasic/asconfig.json b/examples/royale/RemoteObjectAMFTestBasic/asconfig.json
new file mode 100644
index 0000000..4b6259e
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/asconfig.json
@@ -0,0 +1,31 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+{
+    "config": "royale",
+    "compilerOptions": {
+        "debug": false,
+        "targets": ["JSRoyale","SWF"],
+        "source-map": true
+    },
+    "additionalOptions": "-remove-circulars -js-output-optimization=skipAsCoercions",
+    "files":
+    [
+        "src/main/royale/App.mxml"
+    ]
+}
diff --git a/examples/royale/RemoteObjectAMFTestBasic/build.xml b/examples/royale/RemoteObjectAMFTestBasic/build.xml
new file mode 100644
index 0000000..c3e96d5
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/build.xml
@@ -0,0 +1,73 @@
+<?xml version="1.0"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+
+
+<project name="RemoteObjectAMFTestBasic" default="main" basedir=".">
+    <property name="ROYALE_HOME" location="../../.."/>
+    <property name="example" value="App" />
+    
+    <property file="${ROYALE_HOME}/env.properties"/>
+    <property environment="env"/>
+    <property file="${ROYALE_HOME}/build.properties"/>
+    <property name="ROYALE_HOME" value="${ROYALE_HOME}"/>
+    <!-- <property name="opt1_arg" value="-html-template=${basedir}/src/main/resources/mdl-js-index-template.html" /> -->
+
+    <include file="${basedir}/../../build_example.xml" />
+    
+    <target name="main" depends="clean,build_example.compile" description="Clean build of ${example}">
+        <!--
+        <mkdir dir="${basedir}/bin/js-debug/assets" />
+        <copy todir="${basedir}/bin/js-debug/assets" >
+            <fileset dir="${basedir}/src/main/resources/assets">
+                <include name="**" />
+            </fileset>
+        </copy>
+        <mkdir dir="${basedir}/bin/js-release/assets" />
+        <copy todir="${basedir}/bin/js-release/assets" >
+            <fileset dir="${basedir}/src/main/resources/assets">
+                <include name="**" />
+            </fileset>
+        </copy>
+        <replace file="${basedir}/bin/js-debug/index.html" token="${primary}" value="indigo" />
+        <replace file="${basedir}/bin/js-debug/index.html" token="${accent}" value="pink" />
+        <replace file="${basedir}/bin/js-release/index.html" token="${primary}" value="indigo" />
+        <replace file="${basedir}/bin/js-release/index.html" token="${accent}" value="pink" />
+         -->
+    </target>
+    
+    <target name="clean">
+        <delete dir="${basedir}/bin" failonerror="false" />
+        <delete dir="${basedir}/bin-debug" failonerror="false" />
+        <delete dir="${basedir}/bin-release" failonerror="false" />
+        <delete dir="${basedir}/target" failonerror="false" />
+    </target>
+   
+   <target name="examine" depends="build_example.get.browser">
+       <property name="which" value="debug" />
+       <echo message="Choose from dropdown, get quote, click on checkbox to see if TextArea appears and disappears, click on radio buttons to see if other labels change via data binding"/>
+       <exec executable="${browser}" dir="${basedir}/bin-${which}" failonerror="true">
+           <arg value="${basedir}/bin-${which}/${example}.html"/>
+       </exec>
+       <exec executable="${browser}" dir="${basedir}/bin/js-${which}" failonerror="true">
+           <arg value="${basedir}/bin/js-${which}/index.html"/>
+       </exec>
+   </target>
+   
+</project>
diff --git a/examples/royale/RemoteObjectAMFTestBasic/pom.xml b/examples/royale/RemoteObjectAMFTestBasic/pom.xml
new file mode 100644
index 0000000..376d853
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/pom.xml
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
+  <modelVersion>4.0.0</modelVersion>
+
+  <parent>
+    <groupId>org.apache.royale.examples</groupId>
+    <artifactId>examples-royale</artifactId>
+    <version>0.9.4-SNAPSHOT</version>
+  </parent>
+
+  <artifactId>RemoteObjectAMFTestBasic</artifactId>
+  <version>0.9.4-SNAPSHOT</version>
+  <packaging>swf</packaging>
+
+  <name>Apache Royale: Examples: Royale: RemoteObjectAMFTestBasic</name>
+
+  <build>
+    <sourceDirectory>src/main/royale</sourceDirectory>
+    <resources>
+      <resource>
+        <directory>src/main/resources</directory>
+        <filtering>true</filtering>
+      </resource>
+    </resources>
+    <plugins>
+      <plugin>
+        <groupId>org.apache.royale.compiler</groupId>
+        <artifactId>royale-maven-plugin</artifactId>
+        <extensions>true</extensions>
+        <configuration>
+          <mainClass>App.mxml</mainClass>
+          <targets>SWF, JSRoyale</targets>
+          <debug>true</debug>
+        </configuration>
+      </plugin>
+      <plugin>
+        <groupId>org.apache.maven.plugins</groupId>
+        <artifactId>maven-war-plugin</artifactId>
+      </plugin>
+      <plugin>
+        <groupId>org.codehaus.mojo</groupId>
+        <artifactId>build-helper-maven-plugin</artifactId>
+      </plugin>
+    </plugins>
+  </build>
+
+  <dependencies>
+    <dependency>
+      <groupId>com.adobe.flash.framework</groupId>
+      <artifactId>playerglobal</artifactId>
+      <version>${flash.version}</version>
+      <type>swc</type>
+      <scope>provided</scope>
+    </dependency>
+      
+    <dependency>
+      <groupId>org.apache.royale.framework</groupId>
+      <artifactId>Network</artifactId>
+      <version>0.9.4-SNAPSHOT</version>
+      <type>swc</type>
+      <classifier>swf</classifier>
+    </dependency>
+    <dependency>
+      <groupId>org.apache.royale.framework</groupId>
+      <artifactId>Network</artifactId>
+      <version>0.9.4-SNAPSHOT</version>
+      <type>swc</type>
+      <classifier>js</classifier>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.royale.framework</groupId>
+        <artifactId>Reflection</artifactId>
+        <version>0.9.4-SNAPSHOT</version>
+        <type>swc</type>
+        <classifier>swf</classifier>
+    </dependency>
+    <dependency>
+        <groupId>org.apache.royale.framework</groupId>
+        <artifactId>Reflection</artifactId>
+        <version>0.9.4-SNAPSHOT</version>
+        <type>swc</type>
+        <classifier>js</classifier>
+    </dependency>
+  </dependencies>
+
+</project>
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/config/compile-app-config.xml b/examples/royale/RemoteObjectAMFTestBasic/src/main/config/compile-app-config.xml
new file mode 100644
index 0000000..6427e54
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/config/compile-app-config.xml
@@ -0,0 +1,21 @@
+<!--
+
+  Licensed to the Apache Software Foundation (ASF) under one or more
+  contributor license agreements.  See the NOTICE file distributed with
+  this work for additional information regarding copyright ownership.
+  The ASF licenses this file to You under the Apache License, Version 2.0
+  (the "License"); you may not use this file except in compliance with
+  the License.  You may obtain a copy of the License at
+
+      http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing, software
+  distributed under the License is distributed on an "AS IS" BASIS,
+  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+  See the License for the specific language governing permissions and
+  limitations under the License.
+
+-->
+<royale-config>
+    <remove-circulars>true</remove-circulars>
+</royale-config>
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/resources/styles.css b/examples/royale/RemoteObjectAMFTestBasic/src/main/resources/styles.css
new file mode 100644
index 0000000..d5ecf0c
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/resources/styles.css
@@ -0,0 +1,30 @@
+/*
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+*/
+
+@namespace "http://www.w3.org/1999/xhtml";
+
+.Application
+{
+    padding: 10px;
+	margin: 10px;
+}
+
+	
\ No newline at end of file
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/App.mxml b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/App.mxml
new file mode 100644
index 0000000..809970b
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/App.mxml
@@ -0,0 +1,203 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+
+Licensed to the Apache Software Foundation (ASF) under one or more
+contributor license agreements.  See the NOTICE file distributed with
+this work for additional information regarding copyright ownership.
+The ASF licenses this file to You under the Apache License, Version 2.0
+(the "License"); you may not use this file except in compliance with
+the License.  You may obtain a copy of the License at
+
+http://www.apache.org/licenses/LICENSE-2.0
+
+Unless required by applicable law or agreed to in writing, software
+distributed under the License is distributed on an "AS IS" BASIS,
+WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+See the License for the specific language governing permissions and
+limitations under the License.
+
+-->
+<js:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
+               xmlns:js="library://ns.apache.org/royale/basic"
+               xmlns:html="library://ns.apache.org/royale/html"
+               xmlns:local="*">
+
+    <fx:Style source="../../main/resources/styles.css"/>
+
+    <fx:Script>
+		<![CDATA[
+			import org.apache.royale.net.events.FaultEvent;
+			import org.apache.royale.net.events.ResultEvent;
+            import valueObjects.ClientValueObject;
+            import valueObjects.Product;
+            import valueObjects.Zone;
+            import org.apache.royale.collections.ArrayList;
+            import org.apache.royale.net.remoting.messages.RoyaleClient;
+
+            protected function sendName():void
+			{
+                service.send("echo", [name_txt.text]);
+			}
+
+            protected function sendNameSimple():void
+			{
+                simpleService.send("echo", [nameSimple_txt.text]);
+			}
+			
+			private function onResult(evt:ResultEvent):void
+			{
+				trace("[Client:" + RoyaleClient.getInstance().id + "] Result= " + evt.data);
+
+                var zone:Zone;
+
+				if (evt.data is String)
+					received.text = "Received: " + evt.data;
+                else if (evt.data is Zone)
+                {
+                    zone = evt.data as Zone;
+                    received3.text = "Received: zone " + zone.id + " is '" + zone.name + "'";
+                }
+				else if (evt.data is Product)
+                {
+                    var product:Product = evt.data as Product;
+                    received3.text = "Received: product name is '" + product.name + "', product description is '" + product.description + "'. product taxonomy type is '" + product.taxonomy.type + "' and product taxonomy description is '" + product.taxonomy.description + "' zones: " ;
+
+                    var len:int = product.zones.length;
+                    var index:int;
+                    for(index = 0; index < len; index++)
+                    {
+                        zone = product.zones[index];
+                        received3.text += "[" + zone.id + ", " + zone.name + "], ";
+                    }
+
+                    received3.text += " flavors: ";
+
+                    len = product.flavors.length;
+                    for(index = 0; index < len; index++)
+                    {
+                        received3.text += "[" + product.flavors[index] + "], ";
+                    }
+                } else
+              	{
+                    var arr:ArrayList = new ArrayList(evt.data as Array);
+                    list.dataProvider = arr;
+				}
+			}
+			
+            private function onResultSimple(evt:ResultEvent):void
+			{
+				if (evt.data is String)
+					receivedSimple.text = "Received Simple: " + evt.data;
+            }
+
+			private function onFault(evt:FaultEvent):void
+			{
+                trace("[Client:" + RoyaleClient.getInstance().id + "] Fault= " + evt.message);
+				for(var key:String in evt["message"])
+				{
+					var element:Object = evt["message"][key];
+					trace(key + ", " + element);					
+				}
+				//trace("Fault = " + evt.message);
+			}
+
+			protected function getVOs():void
+			{
+                service.send("getObjectArray1", []);
+			}
+
+            protected function getSomeZone():void
+			{
+                service.send("getSomeZone", []);
+			}
+            
+            protected function getSomeProduct():void
+			{
+                service.send("getSomeProduct", []);
+			}
+
+            protected function reportChange():void
+            {
+                var vo:ClientValueObject = list.selectedItem as ClientValueObject;
+                received2.text = "Selected: " + vo.id;
+            }
+			
+            protected function getSomeCompressedProduct():void
+			{
+                compressedService.send("getSomeCompressedProduct", []);
+			}
+		]]>
+	</fx:Script>
+
+    <js:beads>
+        <js:ClassAliasBead />
+        <!-- use this with BlazeDS, LCDS, CF -->
+        <js:RemoteObject id="service" result="onResult(event)" fault="onFault(event)"
+                         endPoint = "http://localhost:8080/messagebroker/websocket-amf"
+                         destination = "exampleService"/>
+        <js:CompressedRemoteObject id="compressedService" result="onResult(event)" fault="onFault(event)"
+                         endPoint = "http://localhost:8080/messagebroker/websocket-amf"
+                         destination = "compressedService"/>
+        <!-- use this wih AMFPHP or oother basic implementations -->
+        <js:SimpleRemoteObject id="simpleService" result="onResultSimple(event)" fault="onFault(event)"
+                         endPoint = "http://localhost:8080/messagebroker/websocket-amf"
+                         destination = "exampleService"/>
+    </js:beads>
+
+    <js:initialView>
+        <js:View>
+            <js:beads>
+                <js:VerticalLayout/>
+            </js:beads>
+
+            <html:H3 text="RemoteObject AMF Test"/>
+
+            <js:Panel width="400">
+                <js:Group>
+                    <js:beads>
+                        <js:HorizontalLayout/>
+                    </js:beads>
+                    <js:TextInput id="name_txt">
+                        <j:beads>
+                            <js:TextPromptBead prompt="Name to send via AMF"/>
+                        </j:beads>
+                    </js:TextInput>
+                    <js:TextButton text="Send to Name"  click="sendName()"/>
+                </js:Group>
+
+                <js:Label id="received" text="Received:"/>
+            </js:Panel>
+
+            <js:Panel width="400">
+                <js:Group>
+                    <js:beads>
+                        <j:HorizontalLayout/>
+                    </js:beads>
+                    <js:TextInput id="nameSimple_txt">
+                        <j:beads>
+                            <j:TextPrompt prompt="Name via Simple RO"/>
+                        </j:beads>
+                    </j:TextInput>
+                    <js:Button text="Send SimpleRO" click="sendNameSimple()"/>
+                </js:Group>
+
+                <js:Label id="receivedSimple" text="Received Simple:"/>
+            </js:Panel>
+
+            <js:Panel width="400">
+                <js:TextButton text="Get Array of ValueObjects" click="getVOs()" width="100%"/>
+                <jx:List id="list" labelField="id" width="100%" height="200" 
+                            change="reportChange()"/>
+                <jx:Label id="received2" text="Selected:"/>
+            </js:Panel>
+            
+            <js:Panel width="400">
+                <j:TextButton text="Get Some Product" click="getSomeProduct()"/>
+                <j:TextButton text="Get Some Compressed Product" click="getSomeCompressedProduct()"/>
+                <js:Label id="received3" text="Received:"/>
+            </js:Panel>
+
+        </js:View>
+    </js:initialView>
+    
+</js:Application>
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/ClientValueObject.as b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/ClientValueObject.as
new file mode 100644
index 0000000..002e74b
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/ClientValueObject.as
@@ -0,0 +1,41 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package valueObjects
+{
+    [RemoteClass(alias="org.apache.royale.amfsamples.valueobjects.ServerCustomType")]
+	public class ClientValueObject
+	{
+		public function ClientValueObject()
+		{
+		}
+
+		private var _id:String;
+
+        public function get id():String
+        {
+            return _id;
+        }
+        
+        public function set id(value:String):void
+        {
+            _id = value;
+        }
+
+	}
+}
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Product.as b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Product.as
new file mode 100644
index 0000000..ce296c2
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Product.as
@@ -0,0 +1,90 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package valueObjects
+{
+    [RemoteClass(alias="org.apache.royale.amfsamples.valueobjects.Product")]
+	public class Product
+	{
+		public function Product()
+		{
+		}
+
+		private var _name:String;
+
+        public function get name():String
+        {
+            return _name;
+        }
+        
+        public function set name(value:String):void
+        {
+            _name = value;
+        }
+
+        private var _description:String;
+
+        public function get description():String
+        {
+            return _description;
+        }
+        
+        public function set description(value:String):void
+        {
+            _description = value;
+        }
+
+        private var _taxonomy:Taxonomy;
+
+        public function get taxonomy():Taxonomy
+        {
+            return _taxonomy;
+        }
+        
+        public function set taxonomy(value:Taxonomy):void
+        {
+            _taxonomy = value;
+        }
+
+        // collection of zones (Zone), we can use Array and ArrayList
+        private var _zones:Array;
+
+        public function get zones():Array
+        {
+            return _zones;
+        }
+        
+        public function set zones(value:Array):void
+        {
+            _zones = value;
+        }
+
+        private var _flavors:Array = null;
+
+        public function get flavors():Array
+        {
+            return _flavors;
+        }
+        
+        public function set flavors(value:Array):void
+        {
+            _flavors = value;
+        }
+
+	}
+}
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Taxonomy.as b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Taxonomy.as
new file mode 100644
index 0000000..0c26bc5
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Taxonomy.as
@@ -0,0 +1,52 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package valueObjects
+{
+    [RemoteClass(alias="org.apache.royale.amfsamples.valueobjects.Taxonomy")]
+	public class Taxonomy
+	{
+		public function Taxonomy()
+		{
+		}
+
+		private var _type:String;
+
+        public function get type():String
+        {
+            return _type;
+        }
+        
+        public function set type(value:String):void
+        {
+            _type = value;
+        }
+
+        private var _description:String;
+
+        public function get description():String
+        {
+            return _description;
+        }
+        
+        public function set description(value:String):void
+        {
+            _description = value;
+        }
+	}
+}
diff --git a/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Zone.as b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Zone.as
new file mode 100644
index 0000000..fb4f6a9
--- /dev/null
+++ b/examples/royale/RemoteObjectAMFTestBasic/src/main/royale/valueObjects/Zone.as
@@ -0,0 +1,52 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+package valueObjects
+{
+    [RemoteClass(alias="org.apache.royale.amfsamples.valueobjects.Zone")]
+	public class Zone
+	{
+		public function Zone()
+		{
+		}
+
+		private var _id:int;
+
+        public function get id():int
+        {
+            return _id;
+        }
+        
+        public function set id(value:int):void
+        {
+            _id = value;
+        }
+
+        private var _name:String;
+
+        public function get name():String
+        {
+            return _name;
+        }
+        
+        public function set name(value:String):void
+        {
+            _name = value;
+        }
+	}
+}