Thanks for the article, it was very good, my problem is more specifically
the implementation of a pattern like that with Axis. I am trying to prove
its workability with a simple stateful session bean:
public class CounterEJB implements SessionBean {
private int count = 0 ;
public void reset() {
count = 0 ;
}
public int add(int i) {
count += i ;
return count ;
}
/*
* ----- cut Session Bean Required Methods cut -----
*/
}
The bean home defines a single create() method and its remote interface
declares reset() and add(int i).
I have deployed this EJB as a web service using the Axis EJB provider and
modified the WSDL2Java output to maintain the session. This all functions
correctly, the SWING client can submit a value, it is added to 'count' and
the cumulative result is returned.
What I would like to have is the CounterEBJ trigger an event when 'count'
changes that the SWING interface can observe and then update its display,
only problem is I'm a bit stumped as to how this should work :-(
Any pointers would be really helpful
Evan
----- Original Message -----
From: <[EMAIL PROTECTED]>
To: <[EMAIL PROTECTED]>; "Evan Jehu" <[EMAIL PROTECTED]>
Sent: Monday, April 01, 2002 13:23
Subject: Re: Observer/Observed Pattern
> Hi Evan,
>
> There is a good tutorial at following location.
> Have a look..
> http://www.artima.com/designtechniques/eventgen.html
>
> I hope this helps.
>
> Cheers
> Rajesh Mittal
>
>
>
>
>
> "Evan Jehu" <[EMAIL PROTECTED]> on 01 Apr 2002 17:35
>
> Please respond to [EMAIL PROTECTED]; Please respond to "Evan Jehu"
> <[EMAIL PROTECTED]>
>
>
>
> To: [EMAIL PROTECTED]
>
>
> cc:
> (bcc: Rajesh Mittal/HBUS/HSBC)
> Subject: Observer/Observed Pattern
>
>
>
>
****************************************************************************
> This message originated from the Internet. Its originator may or
> may not be who they claim to be and the information contained in
> the message and any attachments may or may not be accurate.
>
****************************************************************************
>
> I am new to SOAP/Axis and was wondering if anyone has implemented the
> Observer/Observed pattern. I would like to use this pattern with a remote
> SWING interface and am unsure how it would be programmed. Any
> thoughts/hints would be great :-)
>
> Evan
>
>
>
>
>
>
>
>
>
> ********************************************************************
> This message and any attachments are confidential to the ordinary
> user of the e-mail address to which it was addressed and may also
> be privileged. If you are not the addressee you may not copy,
> forward, disclose or use any part of the message or its
> attachments and if you have received this message in error, please
> notify the sender immediately by return e-mail and delete it from
> your system.
>
> Internet communications cannot be guaranteed to be secure or
> error-free as information could be intercepted, corrupted, lost,
> arrive late or contain viruses. The sender therefore does not
> accept liability for any errors or omissions in the context of
> this message which arise as a result of Internet transmission.
>
> Any opinions contained in this message are those of the author and
> are not given or endorsed by the HSBC Group company or office
> through which this message is sent unless otherwise clearly
> indicated in this message and the authority of the author to so
> bind the HSBC entity referred to is duly verified.
>
> ********************************************************************