Ticket #291 (new defect)

Opened 7 months ago

Last modified 6 months ago

UnknownClassAlias: flex.messaging.io.ArrayList

Reported by: thijs Owned by: nick
Priority: major Milestone: Flex Messaging
Component: Remoting Version: 0.3.1
Keywords: Cc:

Description (last modified by thijs) (diff)

While trying the following code (see attached swf):

import mx.collections.ArrayList;

public function useRemoteObject():void {
   employeeRO = new RemoteObject();
   employeeRO.destination = "GenericDestination";
   employeeRO.setData.addEventListener("result", getListResultHandler);
   employeeRO.addEventListener("fault", faultHandler);
                
   var test:ArrayList = new ArrayList();
   employeeRO.setData(test);
}

I'm getting this error:

   File "/Users/thijstriemstra/Sites/pyamf/pyamf/branches/fds/pyamf/amf3.py", line 1067, in _getClassDefinition
    class_def = ClassDefinition(self.readString(), encoding=ref & 0x03)
  File "/Users/thijstriemstra/Sites/pyamf/pyamf/branches/fds/pyamf/amf3.py", line 548, in __init__
    self.alias = pyamf.get_class_alias(alias)
  File "/Users/thijstriemstra/Sites/pyamf/pyamf/branches/fds/pyamf/__init__.py", line 807, in get_class_alias
    return load_class(klass)
  File "/Users/thijstriemstra/Sites/pyamf/pyamf/branches/fds/pyamf/__init__.py", line 743, in load_class
    klass = loader(alias)
  File "/Users/thijstriemstra/Sites/pyamf/pyamf/branches/fds/pyamf/__init__.py", line 968, in flex_loader
    raise UnknownClassAlias, alias
UnknownClassAlias: flex.messaging.io.ArrayList

With the following "fix":

class ArrayList(ArrayCollection):
    """
    """
    pass

pyamf.register_class(ArrayCollection, 'flex.messaging.io.ArrayList',
    metadata=['external', 'amf3'])

Attachments

Login.swf (226.2 KB) - added by thijs 7 months ago.

Change History

Changed 7 months ago by thijs

Changed 7 months ago by thijs

  • description modified (diff)

Changed 6 months ago by thijs

  • milestone changed from 0.3.2 to Flex Messaging
Note: See TracTickets for help on using tickets.