Home | Wiki | OI 1.x Docs | OI 2.x Docs |
OpenInteract2::Controller::ManageBoxes - Mixin methods for managing boxes
use base qw( OpenInteract2::Controller::ManageBoxes );
If a controller wants to keep track of boxes it should add this class to its ISA.
init_boxes()
Initializes the internal variable for tracking boxes. Should be called
from the implementing class's init()
method.
add_box( [ \%box | $box_action ] )
Adds a box. This can be with a hashref of information \%box
or you
can create an action based on a box and add it.
Returns: information added
get_box( $name )
Return the box action or information with name $name
. Since each
name must be unique you will get at most one box.
If no $name
specified, returns nothing
get_boxes()
Returns an arrayref of all boxes added during this request. They're not in any predictable order.
remove_box( $name )
Removes the box associated with $name
.
If no $name
specified, throws an exception. Otherwise returns the
information previously in $name
.
None known.
Nothing known.
Copyright (c) 2002-2003 Chris Winters. All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Chris Winters <chris@cwinters.com>
Generated from the OpenInteract 1.99_03 source.