473,471 Members | 1,881 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Plugin architecture

COM has many facilities to assist with creating an application with Plugin
support, for example, component categories to determine what components to
load, the OLE specification and interfaces to allow negotiation of menus and
screen real estate.

Does .NET have any inherent Plugin support or specifications? Is there any
recommended way to add Plugin support to a .NET application?

Thanks,
Aaron Queenan.
Jul 21 '05 #1
4 2191
"Aaron Queenan" <aq*********************@contingent.com.au> wrote in message
news:ej**************@TK2MSFTNGP10.phx.gbl...
COM has many facilities to assist with creating an application with Plugin
support, for example, component categories to determine what components to
load, the OLE specification and interfaces to allow negotiation of menus and screen real estate.

Does .NET have any inherent Plugin support or specifications? Is there any recommended way to add Plugin support to a .NET application?


You can use fully qualified type names and the Activator to dynamically load
types that implement specific interfaces, is that what you are looking for?

-- Bob
Jul 21 '05 #2
"Bob Provencher" <bp*********@incurrent.com> wrote in message
news:Oz**************@TK2MSFTNGP12.phx.gbl...
"Aaron Queenan" <aq*********************@contingent.com.au> wrote in message news:ej**************@TK2MSFTNGP10.phx.gbl...
COM has many facilities to assist with creating an application with Plugin support, for example, component categories to determine what components to load, the OLE specification and interfaces to allow negotiation of menus and
screen real estate.

Does .NET have any inherent Plugin support or specifications? Is there

any
recommended way to add Plugin support to a .NET application?


You can use fully qualified type names and the Activator to dynamically

load types that implement specific interfaces, is that what you are looking

for?

Partially.

That would provide a generic way to create the object, but it doesn't
provide mechanism for objects to register as offering a particular service,
or enumerating such objects, or providing a mechanism for extending the user
interface of the host.

Thanks,
Aaron.
Jul 21 '05 #3

"Aaron Queenan" <aq*********************@contingent.com.au> wrote in message
news:%2***************@TK2MSFTNGP11.phx.gbl...
"Bob Provencher" <bp*********@incurrent.com> wrote in message
news:Oz**************@TK2MSFTNGP12.phx.gbl...
"Aaron Queenan" <aq*********************@contingent.com.au> wrote in

message
news:ej**************@TK2MSFTNGP10.phx.gbl...
> COM has many facilities to assist with creating an application with Plugin > support, for example, component categories to determine what components to > load, the OLE specification and interfaces to allow negotiation of
> menus

and
> screen real estate.
>
> Does .NET have any inherent Plugin support or specifications? Is there

any
> recommended way to add Plugin support to a .NET application?


You can use fully qualified type names and the Activator to dynamically

load
types that implement specific interfaces, is that what you are looking

for?

Partially.

That would provide a generic way to create the object, but it doesn't
provide mechanism for objects to register as offering a particular
service,
or enumerating such objects, or providing a mechanism for extending the
user
interface of the host.


There is no such system in existance. You will have to write your own. While
it is possible to implement atleast most of the OLE standard, writing your
own will probably entail far less work than implementing all the OLE code
that would be required anyway(considering there are no wizards).

However, to load a component is relativly easy, Activator and reflection
makes locating components based on derivation and attributes *very* simple.
Ideally you would just use a folder or a config file that points to the
assembly and let the engine detect proper types.
Jul 21 '05 #4
We implemented plugins by attributing each DLL that contains plug-ins with
our PublishPlugInAttribute(string uri, Type type)

On startup, our app enumerates all DLLs in the app directory and reflects
upon these attributes. We then build hashtables of the URI->Type, and the
interfaces that each plug-in supports.

Once this info has been built, the app simply enumerates all plug-in URIs
that implement an interface, and create them using the associated URI. This
lowers the binding between application components - new items can be dropped
in independantly, and the coupling between them is defined by the interfaces
alone.

You can also have a DirectoryWatcher that detect plug-ins that are installed
when your app is running.

Good luck!

Paul Wardle.
"Aaron Queenan" <aq*********************@contingent.com.au> wrote in message
news:%2***************@TK2MSFTNGP11.phx.gbl...
"Bob Provencher" <bp*********@incurrent.com> wrote in message
news:Oz**************@TK2MSFTNGP12.phx.gbl...
"Aaron Queenan" <aq*********************@contingent.com.au> wrote in message
news:ej**************@TK2MSFTNGP10.phx.gbl...
COM has many facilities to assist with creating an application with Plugin support, for example, component categories to determine what
components to load, the OLE specification and interfaces to allow negotiation of
menus and
screen real estate.

Does .NET have any inherent Plugin support or specifications? Is
there any
recommended way to add Plugin support to a .NET application?
You can use fully qualified type names and the Activator to dynamically

load
types that implement specific interfaces, is that what you are looking

for?

Partially.

That would provide a generic way to create the object, but it doesn't
provide mechanism for objects to register as offering a particular

service, or enumerating such objects, or providing a mechanism for extending the user interface of the host.

Thanks,
Aaron.

Jul 21 '05 #5

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

Similar topics

4
by: Jer | last post by:
Hi all, I am trying to get plugins working in my application. I am using the approach of writing an interface and then implementing that interface in each plugin. I would like to be able to...
2
by: Chua Wen Ching | last post by:
Hi there, I had some doubts on creatings plugins. As most example on the internet shows how to write plugins onto a plugin host which is normally a windows form program. 1) Can i replace...
5
by: Tamir Khason | last post by:
Friends, maybe someone knows good references for .NET plugin based program architecture. E.g I want to be able to "put" class library(dll) in some place (where I do not the name of the class, but...
2
by: Matt | last post by:
I'm hoping someone can steer me in the right direction to try to do the following: I am developing an application where we receive files from customers. Right now we receive a variety of...
3
by: CSharpNewBie | last post by:
Hi I am looking to create a Plugin Architecture. I looked at this extend or enhance the User Interface (UI) article http://www.codeproject.com/csharp/extensibleui.asp and It looks good and I...
1
by: Craig Buchanan | last post by:
I am building an application to help researcher record the outcomes of their studies. These outcomes are document across a number of paper forms. The information documented on these forms varies...
0
by: Craig Buchanan | last post by:
I am building an application to help researcher record the outcomes of their studies. These outcomes are document across a number of paper forms. The information documented on these forms varies...
0
by: Dan Dorey | last post by:
I'm in the midst of creating a plugin framework with the goal of making it as easy as possible for myself and other developers to both create new plugins and work with existing ones. Each plugin...
4
by: anglozaxxon | last post by:
I'm making a program that consists of a main engine + plugins. Both are in Python. My question is, how do I go about importing arbitrary code and have it be able to use the engine's functions,...
1
by: Olie | last post by:
I was quite surprised to find virtually nothing about this but I may have been searching for the wrong thing. I want to know the best way to provide a programming interface to a plugin. I...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
1
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...
0
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...
0
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,...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
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 ...
0
muto222
php
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

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.