The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

Win32::Girder::IEvent::Server - Perl API to the Win32 Girder Internet Events Server

SYNOPSIS

        use Win32::Girder::IEvent::Server;
        my $gs = Win32::Girder::IEvent::Server->new();
        my $event = $gs->wait_for_event();

DESCRIPTION

Girder is a Windows automation tool, originally designed to receive commands from IR remote controls. The server is used for receiving 'Event Strings' from a Girder instance or a compatible client.

METHODS

Win32::Girder::IEvent::Server->new([ARGS]);

Create a new server object. The server object inherits the IO::Socket::INET object and so the constructor can take all the IO::Socket::INET methods. However the only relavent ones are:

( LocalPort => $port )

The port on which to run the server. Defaults to 1024 if not specified.

Girder specific parameters are:

( PassWord => $mypass )

The password needed for access to the server. Defaults to 'NewDefPWD'. Note that passwords are NOT sent plain text accross the wire.

my $event = $gs->wait_for_event([timeout]);

Wait for a client to send an event, or until the optional timeout. Returns the event_sting received. Waiting is implemented using select() and will only work on platforms supporting select(). Timeout is in seconds with the same resolution as select().

$gs->handle_events();

This function is usefull if you do not want to block on a wait_for_events() call. You can select() (for read) on the server object, and when there is something to read, you call handle_events(). It returns the $event_sting if there was one, or undef if there was some other activity (usually a client connect or disconnect).

$gs->close();

Politly shut down the server, dropping all active clients first.

AUTHOR

This module is Copyright (c) 2002 Gavin Brock gbrock@cpan.org. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

The Girder application is Copyright (c) Ron Bessems. Please see the 'copying.txt' that came with your copy of Girder or visit http://www.girder.nl for contact information.

SEE ALSO

The Girder home page http://www.girder.nl

Win32::Girder::IEvent::Client.

IO::Socket::INET.