Home > Archive > PERL POE > January 2008 > Fiddling with session once instantiated
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
| Author |
Fiddling with session once instantiated
|
|
| Alejandro Imass 2008-01-10, 7:38 pm |
| Hi,
Is there a "standard" way to add or modify inline or object states once
a session is up and running?
Problem:
I am specializing POE::Component::Client::Stomp but this class does not
offer a way to add object methods with the spawn method it uses to
initialize. Therefore, I cannot post to this session and callback one of
my extended methods, forcing me to either setup another session to
handle these extensions or to call the method directly (of my derived
class) which sucks because it's not event-based.
Thanks,
Alejandro Imass
| |
| Kidney Bingos 2008-01-10, 7:38 pm |
| On Thu, Jan 10, 2008 at 02:59:54PM -0400, Alejandro Imass wrote:
> Hi,
>
> Is there a "standard" way to add or modify inline or object states once
> a session is up and running?
>
> Problem:
>
> I am specializing POE::Component::Client::Stomp but this class does not
> offer a way to add object methods with the spawn method it uses to
> initialize. Therefore, I cannot post to this session and callback one of
> my extended methods, forcing me to either setup another session to
> handle these extensions or to call the method directly (of my derived
> class) which sucks because it's not event-based.
>
> Thanks,
> Alejandro Imass
The POE Kernel has the state() method for registering and changing methods
on the fly.
--
Chris Williams
aka BinGOs
PGP ID 0x4658671F
http://www.gumbynet.org.uk
==========================
|
|
|
|
|