diff options
Diffstat (limited to 'lib/VarnishMib/MIBTable.pm')
-rw-r--r-- | lib/VarnishMib/MIBTable.pm | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/lib/VarnishMib/MIBTable.pm b/lib/VarnishMib/MIBTable.pm index 6aa959f..da0ca19 100644 --- a/lib/VarnishMib/MIBTable.pm +++ b/lib/VarnishMib/MIBTable.pm | |||
@@ -1,12 +1,28 @@ | |||
1 | # This file is part of varnish-mib -*- automake -*- | ||
2 | # Copyright (C) 2018 Sergey Poznyakoff | ||
3 | # | ||
4 | # varnish-mib is free software; you can redistribute it and/or modify | ||
5 | # it under the terms of the GNU General Public License as published by | ||
6 | # the Free Software Foundation; either version 3, or (at your option) | ||
7 | # any later version. | ||
8 | # | ||
9 | # varnish-mib is distributed in the hope that it will be useful, | ||
10 | # but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
11 | # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
12 | # GNU General Public License for more details. | ||
13 | # | ||
14 | # You should have received a copy of the GNU General Public License | ||
15 | # along with varnish-mib. If not, see <http://www.gnu.org/licenses/>. | ||
16 | |||
1 | package VarnishMib::MIBTable; | 17 | package VarnishMib::MIBTable; |
2 | use strict; | 18 | use strict; |
3 | use warnings; | 19 | use warnings; |
4 | use parent 'VarnishMib::HashTable'; | 20 | use parent 'VarnishMib::HashTable'; |
5 | use Carp; | 21 | use Carp; |
6 | 22 | ||
7 | sub new { | 23 | sub new { |
8 | my ($class, $type, $table, %args) = @_; | 24 | my ($class, $type, $table, %args) = @_; |
9 | my @oids = | 25 | my @oids = |
10 | sort { $table->{$a}[1] cmp $table->{$b}[1] } | 26 | sort { $table->{$a}[1] cmp $table->{$b}[1] } |
11 | grep { $table->{$_}[0] eq 'DICT' } keys %{$table}; | 27 | grep { $table->{$_}[0] eq 'DICT' } keys %{$table}; |
12 | 28 | ||