This file is indexed.

/usr/share/php/irods/prods/src/RODSKeyValPair.class.php is in php-irods-prods 3.3.0~beta1-2ubuntu1.

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
49
50
<?php
/**
 * RODS keyval type class. This class is conresponding to iRODS's keyval type
 * @author Sifang Lu <sifang@sdsc.edu>
 * @copyright Copyright &copy; 2007, TBD
 * @package RODSConn
 */


require_once("autoload.inc.php");

class RODSKeyValPair
{
    private $keys;
    private $vals;

    public function __construct(array $arr = array())
    {
        $this->keys = array_keys($arr);
        $this->vals = array_values($arr);
    }

    public function addPair($key, $val)
    {
        $this->keys[] = $key;
        $this->vals[] = $val;
    }

    /**
     * Make a RP_KeyValPair
     * @return RP_KeyValPair a RP_KeyValPair object
     */
    public function makePacket()
    {
        return new RP_KeyValPair(count($this->keys), $this->keys, $this->vals);
    }

    /**
     * make a RODSKeyValPair from a RP_KeyValPair
     */
    public static function fromPacket(RP_KeyValPair $RP_KeyValPair)
    {
        $new_keyval = new RODSKeyValPair();
        $new_keyval->keys = $RP_KeyValPair->keyWord;
        $new_keyval->vals = $RP_KeyValPair->svalue;
        return $new_keyval;
    }
}

?>