473,626 Members | 3,201 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Strategy in developing Modular application

Hi All,

I am developing a Windows based application that consists of several
different modules. These modules are effectively separate from each other
yet share information in a common database. I would like to be able deliver
specific modules depending on what the needs of the client are. Some
clients may only need Module A and B, while others may need the
functionality in Module D.
What I am trying to figure out is the best way to go about designing a
modular application? Do developers generally ship modules as separate
libraries? If so, what is the best way to see if another module is
installed? A registry key perhaps? I am in the planning stages now and
would be grateful for any suggestions. Thank you.

- Derek
Nov 13 '05 #1
1 9934
Derek,
I would recommend a Plugin pattern:

http://www.martinfowler.com/eaaCatalog/plugin.html

Basically how TraceListeners are implemented in the Framework.

Each 'module' is located in its own class library. One or more classes in
each library implement a specific interface (IPlugin for example) The
specific interface can be either an interface or an abstract base class.

Within the app.config file (or web.config for web apps) have entries that
identify the plugins. Generally I use custom sections within my app.config
to identify the list of plugins. I either use a custom section handler to
read the list of plugins (or just one plugin). Or I use
NameValueSectio nHandler. Inheriting from
System.Configur ation.Dictonary SectionHandler works well in that you can
override the KeyAttributeNam e & ValueAttributeN ame. I normally make
KeyAttributeNam e=Plugin (where Plugin is actually interface name) and
ValueAttributeN ame=Type. I will also use sectionGroups in my app.config to
help organize it. Within the value attribute I store the name of the class,
in the format 'namespace.clas s, assembly' as that's what GetType expects.

I will use System.Type.Get Type on the above value attribute, giving me a
Type object. I then use System.Activato r.CreateInstanc e with the above Type
object to create an instance of the plugin, this allows me to define
constructors to the plugins if needed. Because the plug in implements the
specific interface I get early binding.

For the project I am currently working on, even the UI uses plugins, the
main executable is a minimalist shell that just starts the plug in loader
code, which happens to be in a class library... The app actually has
different categories of plugins (data layer plugins, business logic plugins,
UI plugins). I use an abstract base class for each kind of plugin as the
abstract base class has the factory method to load & manage the plugins.

I organize my app similar to:
myapp.exe - the main executable
myapp.exe.confi g - configuration, list of plugins
myapp.framework .dll - contains the plugin interfaces
myapp.plugin1.d ll - contains the first plugin

I've been considering defining a custom installer that would create the
respective entries in my app.config file for a specific plugin. This would
allow easier deployment. I would install the class library & run installutil
to have it register the plugin in the app.config. Its on my list to define,
I just have not got to it.

The publishers in the Microsoft Data Exception block may be a good example.

Hope this helps
Jay

"Derek" <de***@wubbafis h.net> wrote in message
news:1k******** *************** ******@40tude.n et...
Hi All,

I am developing a Windows based application that consists of several
different modules. These modules are effectively separate from each other
yet share information in a common database. I would like to be able deliver specific modules depending on what the needs of the client are. Some
clients may only need Module A and B, while others may need the
functionality in Module D.
What I am trying to figure out is the best way to go about designing a
modular application? Do developers generally ship modules as separate
libraries? If so, what is the best way to see if another module is
installed? A registry key perhaps? I am in the planning stages now and
would be grateful for any suggestions. Thank you.

- Derek

Nov 13 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
1215
by: Wole | last post by:
I'm working on a project that requires a Web client with a graphical user interface. The client would run in a Web browser. When a user clicks a button in the client application a message is sent to the server application which in turn notifies all the other clients as to which button has been pressed. Should I develop the client applications as ActiveX EXE, ActiveX DLL, or and ActiveX document? Can anybody give me some code examples,...
1
1730
by: aj | last post by:
hi i am a newbi to python and developing a web application what do u all think is the best application framework for developing web application in python. I want a framework that supports templates,database connectivity, is available for both unix and windows ,and ofcourse is easy to learn. Zope Quixote Draco or others
7
1579
by: Saso Zagoranski | last post by:
Hi! I mentioned this in my other post today but at that time I though I had it all figured out. When I got a reply regarding my other questing I saw that I don't :) Here's my problem: I would like to have an application where I would write the core and the users could write
2
3164
by: Hernán Freschi | last post by:
Hi all. I'm writing a program which I would like to make "modular", that is, being able to add plug-ins for new functions. Basically, the plug-ins will add new MenuItems to the main MenuBar. How can I make that kind of thing? Regards, Hernán Freschi
2
1151
by: Peter Kubicsek | last post by:
Hi I need help. I'm trying to write modular APP which have only basic interfaces to work with database, and etc. All specific code will be in modules (dll's), which can be loaded/unloaded from main app. I know how to write this modules with IDTExtensibility2 interface, but don't know how to write application interface which can work with addins (modules). Can someone eplain me way how to do this? I want something like in Office App,...
4
1152
by: Vivek Sharma | last post by:
Hi There, I am about to develop a windows application. I was wondering if there is any set of general guidelines I should be following when developing a windows application? Is there a preference of writing SQL queries within the application rather than Stored Procedures? Please help Thanks
0
1019
by: Leif K-Brooks | last post by:
I'm writing an application with PostgreSQL as the database which I would like to be as modular as possible. It will have various modules, each of which will have their own database schema. A module with users might define a user table, but an RPG module would want the user table to have a column for money. I don't want the users module to know about the RPG module beforehand, so it can't have the money column. Should the RPG module...
22
2977
by: Wildemar Wildenburger | last post by:
To make it short: Is there something like this already? There seem to loads of python frameworks for Web-Apps, but I have a hard time finding one for desktop-apps. I imagine it wouldn't be too hard (if still time consuming) whipping up something simple myself, but I thought, I'd ask here before diving into it. greets wildemar
0
8196
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,...
0
8705
Oralloy
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...
0
8637
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8364
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,...
0
8504
tracyyun
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...
0
7193
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6125
isladogs
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...
1
1808
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1511
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.