[Red5] Testing AMF3 value objects in Java
Tyler Kocheran
rfkrocktk at gmail.com
Fri May 8 18:19:55 PDT 2009
What's the best way to synchronously test the serialization of objects in
AMF with Red5? I assumed that the best thing to do would be to create a
org.red5.io.amf3.ByteArray object and pass it by hand to my objects via
their read/writeExternal methods. What *should* I be doing? Should I
manually create DataInput and DataOutput objects and pass them back and
forth? I basically want to test that my serialization works for given
objects like so:
ByteArray byteArray = new ByteArray();
MyObject object1 = new MyObject();
object1.setId(11);
object.writeExternal(byteArray);
MyObject object2 = new MyObject();
object2.readExternal(byteArray);
assertTrue(object2.getId() == object1.getId());
Any tips from the true masters? :)
--
And do this, knowing the time, that now it is high time to awake out of
sleep;
for now our salvation is nearer than when we first believed.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://osflash.org/pipermail/red5_osflash.org/attachments/20090508/7f6a656f/attachment.html>
More information about the Red5
mailing list