This file is indexed.

/usr/lib/perl5/TFBS/_Iterator/_SiteSetIterator.pm is in libtfbs-perl 0.6.0+dfsg-1.

This file is owned by root:root, with mode 0o644.

The actual contents of the file can be viewed below.

 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
package TFBS::_Iterator::_SiteSetIterator;

use vars '@ISA';
use strict;
use Carp;
use TFBS::_Iterator;

@ISA = qw(TFBS::_Iterator);


sub _sort  {
    my ($self, $sort_by) = @_;
    $sort_by or $sort_by = $self->{_sort_by} or  $sort_by = 'name';

    # we can sort by name, start, end, score
    my %sort_fn = 
	(start => sub  { $a->start() <=> $b->start() 
			 || $a->pattern->name() cmp $b->pattern->name()
			 || $a->strand() <=> $b->strand()
		       },
	 end   => sub  { $a->end()   <=> $b->end()   
			 || $a->pattern->name() cmp $b->pattern->name()
			 || $a->strand() <=> $b->strand()
		       },
	 ID  => sub  { $a->pattern->ID() cmp $b->pattern->ID()
			 || $a->start() <=> $b->start() 
			 || $a->end()   <=> $b->end()   
			 || $a->strand() <=> $b->strand()
		       },
	 name  => sub  { $a->pattern->name() cmp $b->pattern->name()
			 || $a->start() <=> $b->start() 
			 || $a->end()   <=> $b->end()   
			 || $a->strand() <=> $b->strand()
		       },
	 score => sub {  $b->score()   <=> $a->score()
			 || $a->pattern->name() cmp $b->pattern->name()
			 || $a->strand() <=> $b->strand()
		      }
	);
			 
    if (defined (my $sort_function = $sort_fn{lc $sort_by})) {
	$self->{'_iterator_array_ref'} =
	    [ sort $sort_function @{$self->{'_orig_array_ref'}} ];
    }
    else  {
	$self->throw("Cannot sort ".ref($self)." object by '$sort_by'.");
    }
}