|
by: George Carl |
last post by:
Perhaps this is a dumb question, but I've tried Google and the newsgroups, and can't figure out a satisfactory answer yet
I'd like to make publish/subscribe scenario where the publishing object is a couple of layers removed from the subscriber. The publisher fires an event and doesn't know who (if anyone) is listening. The subscriber, on the other hand, wants the information, but doesn't want to know who published it (to fully decouple the...
|
by: Zach |
last post by:
Re the example I code below.
I have tried to make a very consise example
of events / eventshandling;
would you please comment?
(Don't tell me to read a book.)
Thanks,
Zach.
|
by: SKumar |
last post by:
Hello:
I am trying to implement a publish/subscribe model for an applications
I am working on. I would very greatful if anybody could offer me some
suggestions.
The application basically is a connectivity applications like dial,
VPN and wireless.
Ideally I would like to have a service where all these connectivity
componenets can send/publish their statuses to...and I would like to
|
by: Mirano |
last post by:
Hello.
I need to implement the publish/subscribe architecture where class B
(server) does not have a reference to class A (which is in a client), but
class B still has to subscribe to the event raised by the class A.
Here's the problem: Class A implements the interface IClient that is on the
server, everything's fine. When the method Foo of the class A is executed,
the event is raised, passing SomeData as a reference. Now, in order to...
|
by: HL |
last post by:
The requirement is to send some information to other objects. The objects to
whom the information has to be sent is not available at compile time. The
names of the types (objects) will be provided through an external file in
which case we can use reflection to create objects of that type at run time.
Case 1:
The methods of those types can be invoked through reflection.
Case 2:
The caller can publish certain events. The types (objects)...
|
|
by: anonymous.user0 |
last post by:
The way I understand it, if I have an object Listener that has
registered as a listener for some event Event that's produced by an
object Emitter, as long as Emitter is still allocated Listener will
stay alive. Is this correct?
If this is correct, I've got a problem. Let's say I've got an object
Customer that has an PurchaseList (Collection) of Purchase objects.
Now, these Purchase objects were pulled from a datasource Datasource.
The...
|
by: Daniel |
last post by:
Hey guys
When you hook an event (c# 2.0 syntax): myEvent += MyMethodToFire;
You need to also unsubscribe it to avoid a resource leak so that the object
it is in gets garbage collected like so : myEvent -= MyMethodToFire;
That's all fine, but when you use visual studio to create events for objects
it never creates an unsubscribing reference, so is it puting in resource
leaks? Or is this being cleared somewhere that i am not seeing?
|
by: MikeT |
last post by:
This may sound very elementary, but can you trap when your object is
set to null within the object?
I have created a class that registers an event from an object passed
in the constructor. When my object is destroyed, I want my object to
un-register this event. If I don't then the object would never be
destroyed until the object I passed in the constructor is destroyed.
I have implemented a Dispose(), Dispose(bool), and ~Finalize...
|
by: raylopez99 |
last post by:
I understand delegates (static and non-static) and I agree they are
very useful, and that the "Forms" used in the Windows .NET API could
not work without them. That said, I'm curious as to how many heavy
duty pro programmers in this newsgroup have actually used a delegate
in their code, say in the last year of coding. By "use" I mean
constructed a delegate and using it in an Event Source class and an
Event Receiver class.
Interfaces...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
|
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: tracyyun |
last post by:
Dear forum friends,
With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
|
|
by: muto222 |
last post by:
How can i add a mobile payment intergratation into php mysql website.
|