From 4375b45289596f985735b648ef09cc2aa4d768bb Mon Sep 17 00:00:00 2001 From: Matt Sergeant Date: Mon, 7 Jun 2004 18:48:13 +0000 Subject: [PATCH] Docs git-svn-id: https://svn.perl.org/qpsmtpd/trunk@237 958fd67b-6ff1-0310-b445-bb7760255be9 --- lib/Qpsmtpd/Connection.pm | 62 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/lib/Qpsmtpd/Connection.pm b/lib/Qpsmtpd/Connection.pm index 11765bc..569cf76 100644 --- a/lib/Qpsmtpd/Connection.pm +++ b/lib/Qpsmtpd/Connection.pm @@ -59,3 +59,65 @@ sub notes { } 1; + +__END__ + +=head1 NAME + +Qpsmtpd::Connection - A single SMTP connection + +=head1 SYNOPSIS + + my $rdns = $qp->connection->remote_host; + my $ip = $qp->connection->remote_ip; + +=head1 DESCRIPTION + +This class contains details about an individual SMTP connection. A +connection lasts the lifetime of a TCP connection to the SMTP server. + +See also L which is a class containing details +about an individual SMTP transaction. A transaction lasts from +C to the end of the C marker, or a C command, +whichever comes first, whereas a connection lasts until the client +disconnects. + +=head1 API + +These API docs assume you already have a connection object. See the +source code if you need to construct one. You can access the connection +object via the C object's C<< $qp->connection >> method. + +=head2 remote_host( ) + +The remote host connecting to the server as looked up via reverse dns. + +=head2 remote_ip( ) + +The remote IP address of the connecting host. + +=head2 remote_info( ) + +If your server does an ident lookup on the remote host, this is the +identity of the remote client. + +=head2 hello( ) + +Either C<"helo"> or C<"ehlo"> depending on how the remote client +greeted your server. + +NOTE: This field is empty during the helo or ehlo hooks, it is only +set after a successful return from those hooks. + +=head2 hello_host( ) + +The host name specified in the C or C command. + +NOTE: This field is empty during the helo or ehlo hooks, it is only +set after a successful return from those hooks. + +=head2 notes($key [, $value]) + +Connection-wide notes, used for passing data between plugins. + +=cut