NAME
Zoidberg::Fish - Base class for loadable Zoidberg plugins
SYNOPSIS
package My::Dynamic::ZoidPlugin
use base 'Zoidberg::Fish';
DESCRIPTION
Base class for loadable Zoidberg plugins. Has many stubs
to provide compatibility with Zoidberg
Once this base class is used your module looks and smells
like fish -- Zoidberg WILL eat it.
See the user documentation on how to load these objects
into Zoidberg.
METHODS
new($parent, \%config, $zoid_name)
$self->{parent} a reference to parent Zoidberg object
$self->{config} hash with some config
$self->{zoid_name} name as known by parent object
init()
To be overloaded, should be called by parent object.
Do things like loading files, opening sockets here.
parent()
Returns a reference to the Zoidberg object
print()
Convenience method for calling ->parent->print
config()
Return the config hash
event($event_name, @_)
This method is called by the parent when an event is broadcasted
broadcast_event($event_name, @_)
Calls ->parent->broadcast_event
register_event($event_name)
Register an event with the parent object.
When the event occurs, the `event' method will be called, with at least one argument: the event name.
unregister_event($event_name)
Unregister self for event $event_name
unregister_all_events()
Unregister self for all events
registered_events()
List events self is registered for
help()
Stub help function, should return a string
with dynamic content for the zoidberg help system.
round_up()
Is called when the plugin is unloaded or when sudden DESTROY occurs.
To be overloaded, do things like saving files, closing sockets here
AUTHOR
R.L. Zwart, <carlos@caremail.nl>
Copyright (c) 2002 Raoul L. Zwart. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.