-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathOMAPI.pm
More file actions
115 lines (73 loc) · 2.21 KB
/
OMAPI.pm
File metadata and controls
115 lines (73 loc) · 2.21 KB
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
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
package DHCP::OMAPI;
use 5.006;
use strict;
use warnings;
require DynaLoader;
use DHCP::OMAPI::Connection;
use DHCP::OMAPI::Object;
our @ISA = qw(DynaLoader);
sub CONST {
my ($constname, $arg) = @_;
my $val = constant($constname, $arg ? $arg : 0);
return $val;
}
our $VERSION = '0.01';
bootstrap DHCP::OMAPI $VERSION;
BEGIN: { DHCP::OMAPI::Handle->initialize(); }
=head1 NAME
DHCP::OMAPI - A module for manipulating DHCP via the OMAPI interface
=head1 SYNOPSIS
use DHCP::OMAPI;
my $connection = new DHCP::OMAPI::Connection( host => $host,
port => 50004,
keyfile => "dhcp_monitor.key" );
if($connection) {
my $failover = DHCP::OMAPI::Object::Failover->fetch( $connection,
"name" => "dhcpd_failover"
);
if($failover) {
foreach my $a ($failover->attributes()) {
printf "%s: %s\n",$a,$failover->get($a);
}
}
}
=head1 DESCRIPTION
Stub documentation for DHCP::OMAPI, created by h2xs. It looks like the
author of the extension was negligent enough to leave the stub
unedited.
Blah blah blah.
=head1 METHODS
=head2 new DHCP::OMAPI()
=over
Constructor.
=cut
sub new {
my $self = shift;
my $class = ref $self || $self;
my %me = @_;
$self = bless \%me,$class;
$self->{_handle} = DHCP::OMAPI::Handle->new();
$self->init();
return $self;
}
sub error {
my $self = shift;
my $result = shift;
DHCP::OMAPI::Handle->result_totext($result);
}
1;
__END__
=head1 SEE ALSO
L<DHCP::OMAPI::Connection>
L<DHCP::OMAPI::Object>
There is no mailing list for this module yet.
There is no website for this module yet.
=head1 AUTHOR
Operational Support Services - SUNY Buffalo
oss-unix@buffalo.edu
=head1 COPYRIGHT AND LICENSE
Copyright (C) 2004 by OSS/CIT - SUNY Buffalo
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.3 or,
at your option, any later version of Perl 5 you may have available.
=cut