I just started to use Zend_Amf
and thus far I'm really happy with it for sending objects from Flash to the server.
Sending my objects from the server back to my Flash environment is causing me a slight headache. My PHP objects mostly contain private properties that have a custom getter and setter method.
How do I make Zend_Amf
aware of these properties? When sending objects from the server back to PHP it just tries. Is there an annotation for this like @property
?
Any help is much appreciated, for now I'll try to convert the object to an stdClass
instance with a $_ecplicitType
value.
Asked
Active
Viewed 440 times
1

Rufinus
- 29,200
- 6
- 68
- 84

Marijn Huizendveld
- 791
- 2
- 7
- 23
-
The final solution for this was simply to move to `Sabre_Amf`. Using `Sabre_Amf_Typed_Object` wrapper and a simple `toArray()` method on my models. The whole seems a lot more efficient... – Marijn Huizendveld May 04 '10 at 13:07
-
In retrospect, using the magic function `__isset()` might do the job... – Marijn Huizendveld Jun 04 '10 at 09:49