=head1 NAME

OpenFrame::Slots - Information about OpenFrame Slots

=head1 OVERVIEW

OpenFrame Slot functionality is designed as a pipe where transmogrification
takes place.  An I<OpenFrame::AbstractRequest> object is poured into the top, and
when it comes out of the bottom it should be an I<OpenFrame::AbstractResponse>, that
contains all the information that is needed by any server to deliver
content to a browser.  In between the top and the bottom of the pipe functionality
is executed in a serial fashion.  Futhermore, it is possible to alter the slot pipeline
at runtime, by returning a class name (string) from a slot.  The class name given will
be placed at the end of the slot pipeline, and will inherit the configuration from the
slot that created placed it there.  

=head1 EXAMPLE

  package OpenFrame::Slot::MyRequestNoter;

  use strict;
  use warnings::register;

  use OpenFrame::Slot;
  use base qw ( OpenFrame::Slot );

  sub what {
    return ['OpenFrame::AbstractRequest'];
  }

  sub action {
    my $self = shift;
    my $conf = shift;
    my $req  = shift;

    warnings::warn("URL Requested is: " . $req->uri()->as_string());
  }

  1;

=head1 WHAT'S IN A SLOT

Any slot should inherit from the I<OpenFrame::Slot> class.  This provides the 
basic functionality that a slot needs to get going.  However, from any given
slot there should be two methods that programmers need to concern themselves
with, I<what()> and I<action()>.

=head2 what()

The I<what()> method returns an array reference containing the classes that 
any given slot needs to function.  For instance, the packaged class 
C<OpenFrame::Slot::Session> requires an OpenFrame::AbstractRequest object
in order to perform its action, and therefore returns it inside an array
when its I<what()> method is called.

=head2 action()

The I<action()> method takes the parameters that you specify in the I<what()>
method as well as a the config that the slot is installed with and does something 
with them.  If it returns an object then that object gets kept for future use by 
other slots.  For example, the I<OpenFrame::Slot::Session> class returns both an 
I<OpenFrame::Session> object and a I<OpenFrame::AbstractCookie> object, that are later used by other
slots.  If the I<action()> method returns a string, that string is interpreted
as being another slot to go on the end of the slot pipeline.  The action 
method can return values as a single scalar, or as a list. In the case of a 
list of Slots to be executed they go onto the pipeline in the same order as
the I<action()> method returns them.

=head1 NOTES

=head1 AUTHOR

James A. Duncan <jduncan@fotango.com>

=cut