File: Select.pm

package info (click to toggle)
libnet-dns-perl 0.19-0.1
  • links: PTS
  • area: main
  • in suites: woody
  • size: 544 kB
  • ctags: 323
  • sloc: perl: 5,191; makefile: 54
file content (43 lines) | stat: -rw-r--r-- 558 bytes parent folder | download
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
package Net::DNS::Select;

use Net::DNS;
use IO::Select;
use Carp;

use strict;
use vars qw($VERSION);

# $Id: Select.pm,v 1.1 2000/11/10 16:17:51 mfuhr Exp mfuhr $
$VERSION = $Net::DNS::Version;

sub new {
	my ($class, $os, @socks) = @_;

	if ($os eq "microsoft") {
		return bless \@socks, $class;
	}
	else {
		return IO::Select->new(@socks);
	}
}

sub add {
	my ($self, @handles) = @_;
	push @$self, @handles;
}

sub remove {
	# not implemented
}

sub handles {
	my $self = shift;
	return @$self;
}

sub can_read {
	my $self = shift;
	return @$self;
}

1;