On 10/30/16, 7:26 AM, "Harbs" <[email protected]> wrote:

>FWIW, I don’t think it makes sense to implement
>readObject,writeObject,inflate and deflate in the core class the way
>Flash ByteArray has it. It will require a lot of code as dependencies. It
>probably makes more sense to have utility classes for this functionality
>to make it “pay as you go”.

Good point about the dependencies.  It occurs to me that PAYG might be
better implemented as subclasses of a ByteArray/BinaryData that doesn't
support the objects and compression.  Or else you will have to cheat
because I would guess that the implementation shouldn't have to call
writeByte/readByte and should just have access to the underlying bytes.

So, a org.apache.flex.utils.ByteArray may only support simple types, and a
org.apache.flex.utils.AMFByteArray could support AMF encode/decode via
readObject/writeObject.

-Alex

Reply via email to