File: dummy.pm

package info (click to toggle)
libnet-proxy-perl 0.12-5
  • links: PTS
  • area: main
  • in suites: squeeze, wheezy
  • size: 304 kB
  • ctags: 66
  • sloc: perl: 777; sh: 84; makefile: 44
file content (61 lines) | stat: -rw-r--r-- 1,110 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
package Net::Proxy::Connector::dummy;
use strict;
use warnings;

use Net::Proxy::Connector;
our @ISA = qw( Net::Proxy::Connector );

# IN
sub listen { }

sub accept_from { }

# OUT
sub connect { }

# READ
sub read_from { return '' }

# WRITE
sub write_to { }

1;

__END__

=head1 NAME

Net::Proxy::Connector::dummy - Dummy Net::Proxy connector

=head1 DESCRIPTION

C<Net::Proxy::Connecter::dummy> is a C<Net::Proxy::Connector>
that does I<nothing>. It doesn't listen for incoming connections
and does connect to other hosts.

Future connectors may have their C<accept_from()> method also
handle the connection to a remote host. In this case, C<dummy>
may be used as an 'out' connector.

You could also use the source code of this module as a template
for writing new C<Net::Proxy::Connector> classes.

=head1 CONNECTOR OPTIONS

None.

=head1 AUTHOR

Philippe 'BooK' Bruhat, C<< <book@cpan.org> >>.

=head1 COPYRIGHT

Copyright 2006 Philippe 'BooK' Bruhat, All Rights Reserved.

=head1 LICENSE

This program is free software; you can redistribute it and/or modify it
under the same terms as Perl itself.

=cut