Kevin L. Esteb > XAS-0.04 > XAS::Lib::Net::Client

Download:
XAS-0.04.tar.gz

Dependencies

Annotate this POD

View/Report Bugs
Module Version: 0.02   Source   Latest Release: XAS-0.07

NAME ^

XAS::Lib::Net::Client - The network client interface for the XAS environment

SYNOPSIS ^

 my $rpc = XAS::Lib::Net::Client->new(
   -port => 9505,
   -host => 'localhost',
 };

DESCRIPTION ^

This module implements a simple text orientated nework protocol. All "packets" will have an explict "\012\015" appended. This delineates the "packets" and is network netural. No attempt is made to decipher these "packets".

METHODS ^

new

This initilaizes the module and can take three parameters. It doesn't actually make a network connection.

-port

The port number to attach too.

-host

The host to use for the connection. This can be an IP address or a hostname.

-timeout

An optional timeout, it defaults to 60 seconds.

connect

Connect to the defined socket.

disconnect

Disconnect from the defined socket.

put($packet)

This writes a "packet" to the socket.

$packet

The "packet" to send over the socket.

get

This reads a "packet" from the socket.

SEE ALSO ^

XAS

AUTHOR ^

Kevin L. Esteb, <kevin@kesteb.us>

COPYRIGHT AND LICENSE ^

Copyright (C) 2012 by Kevin L. Esteb

This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.8 or, at your option, any later version of Perl 5 you may have available.

syntax highlighting: