Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 1109509
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T02:14:48+00:00 2026-05-17T02:14:48+00:00

First of all this is all just concept, I have no actual programming done

  • 0

First of all this is all just concept, I have no actual programming done yet. This is the situation:

I have a Class A which uses the Filesystemwatcher to watch for changes in a folder. (using events)

Then I have a ‘Collection Class’ B which has a List of A’s.

Now what I want to happen is as follows,

A Change happens with the folder, A detects this and sends a message to B, B transfers this message to Class C. Class C then begins a method which updates the GUI. (What changes were made etc..)

Now I have searched and thought pretty long on this subject, but can’t find the solution. But, I have found 2 design patterns:

Mediator and Observer.

As a software engineer I have to some degree once made the Observer pattern so I know some of the basics there.

Now to my questions:

  • What pattern is best to use in this situation?

  • How do I make it so that B transmits the message to C?

  • Do I need custom Events / delegates to make A transmit data to B or can I use the Built-in events?

P.S.: I’m using C# as my programming language.

edit: Thanks to everyone for helping me, votes are on the way.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T02:14:48+00:00Added an answer on May 17, 2026 at 2:14 am

    For what I make out of this, there are a bunch of ‘A’ objects that pass on events asynchronously to a single B, that in turn passes that info on to a single C.

    So, let B contain and observe the A’s and let C observe B.

    If you got a lot of A’s, you might want to have B do some gathering/caching of A’s events before notifying C. Especially if C is serving a user interface.

    Side note: don’t over-patternize your software. Try to be open-minded and always find the simplest and easiest solution. Only use a pattern where its appropriate, and not just because it’s possible. I have seen many people throwing in proxies, command-patterns, observers, MVC’s, mediators etc, where they were unneccesary.

    Good luck.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

First of all: I understand, why this warning is existing, I just can't explain
First of all this is my markup: <div class=first></div> <div class=second></div> <div class=second></div> <div
First of all: This question is not directly programming related. However, the problem only
first of all: this is not the same as this . The ModelBackend has
first of all this is my third question about web services here and i
Well, first of all sorry about this question it must be pretty straight forward
Maybe it's a similar beginning, but it's true. first of all sorry if this
First of all there is probably a question like this already but i couldn't
First of all I'm not sure this is even possible, however I need to
First of all I don't know if this is the right approach. I want

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.