Click here to Skip to main content
15,919,341 members
Home / Discussions / C#
   

C#

 
QuestionRe: VB6 COM Interface Question Pin
MSBassSinger9-Oct-08 6:17
professionalMSBassSinger9-Oct-08 6:17 
RantRe: VB6 COM Interface Question Pin
Paul Conrad9-Oct-08 7:08
professionalPaul Conrad9-Oct-08 7:08 
AnswerRe: VB6 COM Interface Question Pin
MSBassSinger9-Oct-08 7:54
professionalMSBassSinger9-Oct-08 7:54 
QuestionAll these event handlers Pin
Dewald9-Oct-08 3:56
Dewald9-Oct-08 3:56 
AnswerRe: All these event handlers Pin
DaveyM699-Oct-08 4:43
professionalDaveyM699-Oct-08 4:43 
GeneralRe: All these event handlers Pin
Dewald9-Oct-08 5:11
Dewald9-Oct-08 5:11 
AnswerRe: All these event handlers Pin
led mike9-Oct-08 4:47
led mike9-Oct-08 4:47 
AnswerRe: All these event handlers Pin
S. Senthil Kumar9-Oct-08 5:00
S. Senthil Kumar9-Oct-08 5:00 
The event mechanism looks ok for the receiving part, but it looks a bit awkard for the sending part. Usually, people think of events as things that are optional i.e., you can subscribe if you're interested. People also implicitly associate it with multiple listeners. All of which fit in nicely when receiving data - multiple clients could listen to FramingEngine if they want to etc..

But sending the message is different - you don't want to have a SendMessage event with zero subscribers, do you? Do you anticipate multiple subscribers sending messages?

OTOH, I think of an interface, like
interface IFrameEngine
{
   event MessageReceived;
   void SendMessage(...);    
}


and have message engine hold a reference to this interface. The dependencies are only one way i.e., MessageEngine depends on IFrameEngine.

Just my 2 cents Smile | :)

Regards
Senthil [MVP - Visual C#]
_____________________________
My Home Page |My Blog | My Articles | My Flickr | WinMacro

GeneralRe: All these event handlers Pin
Dewald9-Oct-08 5:20
Dewald9-Oct-08 5:20 
GeneralRe: All these event handlers Pin
S. Senthil Kumar9-Oct-08 5:34
S. Senthil Kumar9-Oct-08 5:34 
GeneralRe: All these event handlers Pin
Dewald9-Oct-08 23:02
Dewald9-Oct-08 23:02 
QuestionIncluding c# v2.0 library in a c# v1.1 library. [modified] Pin
Spoon659-Oct-08 2:40
Spoon659-Oct-08 2:40 
AnswerRe: Including c# v2.0 library in a c# v1.3 library. Pin
Pete O'Hanlon9-Oct-08 3:00
mvePete O'Hanlon9-Oct-08 3:00 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Spoon659-Oct-08 3:08
Spoon659-Oct-08 3:08 
AnswerRe: Including c# v2.0 library in a c# v1.1 library. Pin
Guffa9-Oct-08 3:12
Guffa9-Oct-08 3:12 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Spoon659-Oct-08 3:52
Spoon659-Oct-08 3:52 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Dave Kreskowiak9-Oct-08 5:24
mveDave Kreskowiak9-Oct-08 5:24 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Spoon659-Oct-08 22:11
Spoon659-Oct-08 22:11 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Spoon6513-Oct-08 22:37
Spoon6513-Oct-08 22:37 
GeneralRe: Including c# v2.0 library in a c# v1.1 library. Pin
Dave Kreskowiak14-Oct-08 1:52
mveDave Kreskowiak14-Oct-08 1:52 
AnswerRe: Including c# v2.0 library in a c# v1.1 library. Pin
Dan Neely9-Oct-08 4:06
Dan Neely9-Oct-08 4:06 
QuestionTabular crystal reports using query not through wizard Pin
tanvir20909-Oct-08 2:11
tanvir20909-Oct-08 2:11 
JokeRe: Tabular crystal reports using query not through wizard Pin
nelsonpaixao9-Oct-08 13:46
nelsonpaixao9-Oct-08 13:46 
QuestionStartUpForm / Splashscreen - Crossthreading / InvalidoperationException Pin
Piratenwichtl20009-Oct-08 0:25
Piratenwichtl20009-Oct-08 0:25 
AnswerRe: StartUpForm / Splashscreen - Crossthreading / InvalidoperationException Pin
S. Senthil Kumar9-Oct-08 3:53
S. Senthil Kumar9-Oct-08 3:53 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.