public function getValuesForFieldInPolicy($sec, $ptype, $fieldIndex)
    {
        $values = [];

        if (!isset($this->model[$sec][$ptype])) {
            return $values;
        }

        foreach ($this->model[$sec][$ptype]->policy as $rule) {
            $values[] = $rule[$fieldIndex];
        }

        Util::arrayRemoveDuplicates($values);

        return $values;
    }
public function getValuesForFieldInPolicy($sec, $ptype, $fieldIndex)
    {
        $values = [];

        if (!isset($this->model[$sec][$ptype])) {
            return $values;
        }

        foreach ($this->model[$sec][$ptype]->policy as $rule) {
            $values[] = $rule[$fieldIndex];
        }

        Util::arrayRemoveDuplicates($values);

        return $values;
    }
public function getValuesForFieldInPolicy ( $ sec , $ ptype , $ fieldIndex ) { $ values = [ ] ; if ( ! isset ( $ this -> model [ $ sec ] [ $ ptype ] ) ) { return $ values ; } foreach ( $ this -> model [ $ sec ] [ $ ptype ] -> policy as $ rule ) { $ values [ ] = $ rule [ $ fieldIndex ] ; } Util :: arrayRemoveDuplicates ( $ values ) ; return $ values ; }
gets all values for a field for all rules in a policy, duplicated values are removed.

@param string $sec
@param string $ptype
@param int    $fieldIndex

@return array
gets all values for a field for all rules in a policy duplicated values are removed .