Plugin Framework

Discussion in 'Perl Misc' started by Vikas, Sep 28, 2003.

  1. Vikas

    Vikas Guest

    Hi,

    I have been programming in Perl for long and at number of places I come
    across modules which say they follow a plugin framework and anyone can
    plug their plugins (codes) into their software.

    Can anyone give me pointers as to how to develop such a software which
    supports plugin framework . I mean can I read articles or tutorials about
    it somewhere?

    Thanks,
    Vikas.
    Vikas, Sep 28, 2003
    #1
    1. Advertising

  2. Vikas

    pkent Guest

    In article <>,
    Vikas <> wrote:

    > I have been programming in Perl for long and at number of places I come
    > across modules which say they follow a plugin framework and anyone can
    > plug their plugins (codes) into their software.
    >
    > Can anyone give me pointers as to how to develop such a software which
    > supports plugin framework . I mean can I read articles or tutorials about
    > it somewhere?


    I don't know of any good tutorials etc on the subject but here's what
    general info I've learnt about such plugin architectures from building
    and using them:

    * plugins are loaded on demand
    * plugins are generally best modelled as classes, so you load the plugin
    class and instantiate a plugin object of that class
    * plugins conform to a specified API. Some methods may be mandatory,
    some may be optional, and so on, but there must be some standard to work
    with
    * the API can be as simple or as complex as you need. One class of
    plugins I wrote has one constructor method (returns a new object), and
    one object method (returns 1 or 0) :)
    * Inheritance can be very useful. E.g. an X::Y factory class produces
    X::Y::Foo and X::Y::Bar (etc..) objects, and those objects inherit some
    methods from X::Y, maybe things such as debugging routines, file I/O,
    and so on.

    If you've got any more details about the kind of plugins and application
    you want to write there's probably some more specific pointers.

    P

    --
    pkent 77 at yahoo dot, er... what's the last bit, oh yes, com
    Remove the tea to reply
    pkent, Sep 28, 2003
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. PilotYid
    Replies:
    1
    Views:
    606
    Andrew Thompson
    Oct 31, 2005
  2. Marcin Cenkier
    Replies:
    1
    Views:
    5,385
    Marcin Cenkier
    Apr 12, 2006
  3. William

    C++ plugin framework

    William, Apr 25, 2004, in forum: C++
    Replies:
    1
    Views:
    3,228
    Claudio Puviani
    Apr 25, 2004
  4. Jimmy
    Replies:
    0
    Views:
    494
    Jimmy
    Mar 15, 2007
  5. Replies:
    1
    Views:
    711
Loading...

Share This Page