07-24-06 06:11 PM
I've been braving the FDS waters trying to see what it's like over there and
I thought I'd supply my FMS brethren with an example. Here's a question I
posed to an Adobe engineer and the response:
4. is there a way to send a message from the server to one specific client?
In Flashcom, we'd just do Client.call( "someMethod", resultObj, "arg1",
"arg2" ). Would we need each client to subscribe to a destination using a
selector with the client id or is there an easier way?
*Yes, If the clients are subscribed to a destination, you can push a message
to them. Usually this would involve writing a
flex.messaging.services.messaging.adapters.MessagingAdapter subclass for a
given destination. Have the clients subscribe to this destination. Your
MessagingAdapter subclass can access the
flex.messaging.service.MessageService via the protected "service" member
variable (that gets cast into a MessageService from a Service). This
instance has a method called:*
* *
* public void pushMessageToClients(Set subscriberIds, Message message,
boolean evalSelector)*
I'm such a masochist I'm actually going to try to do that. I'll let you know
how it goes.
BTW, if anyone wants to know how to push data to the client like you would
with SharedObjects, I managed to get that working.
-Tom
________________________________________
_______
FlashComm-1Ss2GqJETD3yZ38Mhd3e/9ZfFG6BLHNm@public.gmane.org
To change your subscription options or search the archive:
http://chattyfig.figleaf.com/mailman/listinfo/flashcomm
Brought to you by Fig Leaf Software
Premier Authorized Adobe Consulting and Training
http://www.figleaf.com
http://training.figleaf.com
[ Post a follow-up to this message ]
|