Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

Ovid (2709)

Ovid
  (email not shown publicly)
http://publius-ovidius.livejournal.com/
AOL IM: ovidperl (Add Buddy, Send Message)

Stuff with the Perl Foundation. A couple of patches in the Perl core. A few CPAN modules. That about sums it up.

Journal of Ovid (2709)

Sunday September 30, 2007
01:53 PM

Is Moose a Framework?

[ #34572 ]

According to Wikipedia, a software framework is (emphasis mine):

A software framework is a re-usable design for a software system (or subsystem). A software framework may include support programs, code libraries, a scripting language, or other software to help develop and glue together the different components of a software project. Various parts of the framework may be exposed through an API.

I don't think that this is a great definition, but at its core, a software framework seems to be a system which factors out some of the common components of an application and allows developers to focus on the application logic. It appears that people strongly disagree with me. BrowserUK stated:

(IMO) the key element of a framework is that it provides the structure of an application and leaves the application programmer to fill in the details of the specific application.

This sounds suspiciously close to my definition, but as far as I can tell, the key point is that most people feel that frameworks are targeted at specific types of applications (Web sites, ORMs like Hibernate), rather than at general types of applications. By this distinction, Stevan Little's excellent Moose distribution is not a framework, even though I see it as a "Perl 6 OO framework for Perl 5". Because it's general-purpose, it doesn't get to call itself a framework. Never mind it is a "reusable design for a software system", it doesn't get to belong to the framework club.

In the Perlmonks thread I linked to earlier, tye made a distinction between "application framework" and "library framework", though he didn't see the latter as being a useful term. I think I'm inclined to agree with him on that now. Though part of me balks at saying "general purpose code is not allowed to be a framework", I think I'll bow to consensus and agree that I was wrong. Oops.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • I personally think that the word "framework" is a heavily overloaded term these days. If I were to give my own definition (which is surely not the correct one, only how I personally view them) it would be "a collection of software libraries that you work /within/ to create an application". By "within" I mean that the set of libraries tends to envelop your code in such a way that the end user/consumer of your code rarely has direct connection with your code itself, but instead iteracts with some layer of th

  • A library proves a piece of functionality that can be dropped into a program.

    A framework defines the outside boundaries of the problem to be solved, and assists in the solution.

    Library is like this...

    Framework is like this

    |-->FRAMEWORK...PROBLEM...FRAMEWORK--|

    The key distinction here for me is that if you use a bad library, you can swap it out for a better one.

    If you hit the limits of your framework, you are in much bigger trouble.
  • As far as consensus is concerned, FWIW let me tell you that I agree with you. Or is that the "old" you, now?

    --
    -- # This prints: Just another Perl hacker, seek DATA,15,0 and print q... ; __END__