Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to design extensible software (plugin architecture)? [closed]

I need some resources that talk about how to design your software to be extensible, i.e. so that other people can write add-ons/plug-ins that adds functionality to it.

What do you recommend? Any books out there that discuss the subject?
I would prefer something that's short and to the point; a bit of theory and a bunch of concrete examples.

I'm not targeting a specific language, I want to be able to understand the core idea so that I can implement it in any language.

And for the same reason, I prefer not to do it using a framework that someone else built (unless the framework is not very high-level, i.e. doesn't hide too much), at the moment I only want to educate myself on the subject and experiment with various ways to implement it. Plus, a framework usually assumes user's knowledge about the subject.

UPDATE

I'm not asking about OOP or allowing my classes to be inherited. I'm talking about designing an application that will be deployed on a system, such that it can be extended by third-party add-ons AFTER its been deployed.

For example, Notepad++ has a plug-in architecture where you can place a .dll file in the plugins folder, and it adds functionality to the application that wasn't there, such as color-picking, or snippet insertion, or many other things (a wide range of functionality).

like image 242
hasen Avatar asked Nov 27 '08 08:11

hasen


People also ask

How do you create extensible software?

In an ideal extensible system, adding new behavior involves strictly adding new code without changing existing code. Adding new behavior to an extensible system means adding new classes, methods, functions, or data that encapsulate the new behavior (figure1).

What is plugin architecture?

A plug-in is a bundle that adds functionality to an application, called the host application, through some well-defined architecture for extensibility. This allows third-party developers to add functionality to an application without having access to the source code.

What is extensible design?

In software engineering, extensibility is defined as “the quality of being designed to allow the addition of new capabilities or functionality.” It is a measure of the ability to extend a system and the level of effort required to implement the extensions.

How do plugin systems work?

Plugins allow you to write subprograms that then hook into or are attached to a larger program. These subprograms then run, modifying or adding to the behavior of the running program. In order to write a plugin, the program itself has to be written (or hacked) to support the plugin.


1 Answers

IF we're talking .NET, try Scripting .NET applications with VBScript over on CodeProject. Lots of concrete examples there.

Below are sites implementing various application extension techniques

  • ClearScript - Makes V8, VBScript and JScript available to .NET apps
  • CS-Script - The C# Script Engine
  • Plugin Architecture using C#
  • Opinio plugin architecture
  • Notes on the Eclipse Plug-in Architecture
  • Plug-in Architecture Framework for Beginners
  • Gecko plugin architecture
  • Fungimol plugin architecture
like image 192
bugmagnet Avatar answered Sep 23 '22 06:09

bugmagnet