IPDevice::RouterBase::PrefixlistEntry
use IPDevice::RouterBase::PrefixlistEntry; my $entry = new IPDevice::RouterBase::PrefixlistEntry; $entry->set_prefix('192.168.0.0/22'); $entry->set_ge(20); $entry->set_le(24); print "Prefix matches!\n" if $entry->match('192.168.1.12');
This module provides routines for storing informations regarding a single IP prefix list entry.
Object constructor. Valid arguments: none.
Defines the sequence number of the entry.
Returns the sequence number of the entry.
Check & set the IP prefix.
Returns the IP prefix.
Set the IP network address.
Returns the IP network address.
Set the IP prefix mask.
Returns the IP prefix mask.
Set the IP prefix length.
Returns the IP prefix length.
Defines whether this prefix is explicitly allowed or explicitly denied.
Returns whether this prefix is explicitly allowed or explicitly denied. Returns either 'permit' or 'deny'.
Defines, until which prefixlength this item will match (less-equal settings).
Returns an integer indicating to which prefixlength this item will match (less-equal setting).
Defines, until which prefixlength this item will match (greater-equal setting).
Returns an integer indicating to which prefixlength this item will match (greater-equal settings).
Returns TRUE if the given prefix matches this prefix, otherwise FALSE.
Returns TRUE if the ip address is in the range of this prefix, otherwise FALSE.
Copyright (c) 2004 Samuel Abels. All rights reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Samuel Abels <spam debain org>
To install IPDevice::IPv4, copy and paste the appropriate command in to your terminal.
cpanm
cpanm IPDevice::IPv4
CPAN shell
perl -MCPAN -e shell install IPDevice::IPv4
For more information on module installation, please visit the detailed CPAN module installation guide.