NAME

Haver::Client - POE component for haver clients.

SYNOPSIS

use Haver::Client;
create Haver::Client (
    alias => 'haver',
    resolver => $res, # A POE::Component::Client::DNS object
    version  => "WackyClient/1.20",
);

$kernel->post('haver', 'connect',
    host => 'hardison.net',
    name => ucfirst($ENV{USER}),
    port => 7575,
);

   

DESCRIPTION

This module eases the creation of Haver clients. It provides a POE::Component in the style of POE::Component::IRC, with some improvements.

METHODS

There is only one method, create(), which is a class method.

create(alias => $alias, resolver => $resolver, version => $version)

This creates a new Haver::Client session. The only required parameter is $alias, which is how you'll talk to the client session using POE::Kernel's post().

If given, $resolver should be a POE::Component::Client::DNS object.

Finally, $version is what we will advertize as the client name and version number to the server. It defaults to Haver::Client/0.08.

STATES

While these are listed just like methods, you must post() to them, and not call them directly.

connect(host => $host, name => $name, [ port => 7575 ])

Connect to $host on port $port (defaults to 7575) with the user name $name. If already connected to a server, Haver::Client will disconnect and re-connect using the new settings.

register(@events)

This summons the sun god Ra and makes him eat your liver.

FIXME: This is inaccurate.

BUGS

None known. Bug reports are welcome. Please use our bug tracker at http://gna.org/bugs/?func=additem&group=haver.

AUTHOR

Bryan Donlan <bdonlan@haverdev.org>, Dylan Hardison <dylan@haverdev.org>.

SEE ALSO

http://www.haverdev.org/.

COPYRIGHT and LICENSE

Copyright (C) 2004, 2005 by Bryan Donlan, Dylan Hardison. All Rights Reserved.

This module is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This module is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this module; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA