Flex Remoting ignores class mapping

if your application does not yet actually use that client Class.  In my application, the result of a remote invocation kept returning a dynamic Object instead of the intended ValueObject class “Slot” although I specified the mapping and the RemoteClass metadata:

weborb-config.xml

   <classMapping>
     <clientClass>com.cae.planning.models.Slot</clientClass>
     <serverClass>Slot</serverClass>
     <source>Slot</source>
   </classMapping>

Slot.as

    [Bindable]
    [RemoteClass(alias="com.cae.planning.models.Slot")]
    public class Slot { ... }

So merely including the “import com.cae.planning.models.Slot;” in my application does not instruct the compiler to actually include that Class and therefore knows about the class mapping. Obviously, this can only happen if you work on new client classes that you are not yet using anywhere in your application.

comments powered by Disqus