GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  AGENT::TRANSPORT (3)

.ds Aq ’

NAME

Agent::Transport - the Transportable Agent Perl module

CONTENTS

SYNOPSIS



  use Agent;

  my $t = new Agent::Transport(
        Medium => $name,
        Address => $addr
        ...
  );
  ...
  my $data = $t->recv( [%args] );



DESCRIPTION

This package provides a standard interface to different transport mediums. Agent::Transport does not contain any transport code itself; it contains a constructor, and code that autoloads the appropriate transport methods.

CONSTRUCTOR

new( %args ) new() must be passed at least a Medium. The Address argument is strongly recomended (and should be required in most cases), as it’s best not to let the system make assumptions. new() decides which Transport package to use base upon the Medium specified. Address is the destination in that medium. Any other arguments will be documented in the Agent::Transport subclasses (such as Agent::Transport::TCP).

STANDARD API METHODS

These methods are implemented in all transport subclasses.
$t->recv() recv attempts to retrieve a message (from said address, over said transport medium). Returns the data if called in a scalar context, or a list containing ($data, $from_address) if called in an array context. Returns nothing (i.e. sv_null or an empty list) if unsuccessful.
$t->transport() Returns the transport medium over which the object communicates.
$t->address() Returns the primary address at which the object can be reached.
$t->aliases() Returns a list of addresses at which the object can be reached.

STANDARD SUBROUTINES

send( %args ) send too must be passed a Medium and an Address. In addition, it also needs a Message as either an anonymous array or a reference to an array.
valid_address( %args ) This checks to see if the Address provided is valid within the Medium specified by checking the syntax of the address. It does not check to see whether or not said address exists. Returns the address if successful, or nothing otherwise.

SEE ALSO

Agent, Agent::Transport::*

AUTHOR

Steve Purkis <spurkis@engsoc.carleton.ca>

COPYRIGHT

Copyright (c) 1998 Steve Purkis. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.

THANKS

The perl5-agents mailing list.
Search for    or go to Top of page |  Section 3 |  Main Index


perl v5.20.3 AGENT::TRANSPORT (3) 1998-10-25

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.