I have an application which resides in the system tray, and instead of the standard ‘polling’ method (check the server at X sec interval for updates) I wish to use a push notification system. So when there’s an update, all clients will receive a message and they will do their task. The webserver will be Debian with Apache and PHP.
My target platform is .NET 3.5, so how would this be done? The Observer Design Pattern will not work (due to it’s being .NET 4.0 or higher).
You have to create two interfaces and their derived concrete classes. Your service will create IObservable, IObserver and ApplicationErrorState.
Your client will create class and will derive ErrorMessageSync from IObserver.
Here is my example which displays errors and is created with .Net 3.5.
P.S. You can also use delegates
This is UML for this approach.