Lucene path filter.
More...
Public Member Functions |
| __construct ($a_root) |
| Constructor.
|
| filter ($a_ref_id) |
| Return whether a object reference is valid or not.
|
Protected Member Functions |
| init () |
| Read valid reference ids.
|
Detailed Description
Lucene path filter.
- Author
- Stefan Meyer meyer.nosp@m.@lei.nosp@m.fos.c.nosp@m.om
- Version
- $Id$
Definition at line 34 of file class.ilLucenePathFilter.php.
Constructor & Destructor Documentation
ilLucenePathFilter::__construct |
( |
|
$a_root | ) |
|
Member Function Documentation
ilLucenePathFilter::filter |
( |
|
$a_ref_id | ) |
|
Return whether a object reference is valid or not.
- Parameters
-
int | $a_ref_id | reference id of object in question |
- Returns
- boolean
Implements ilLuceneResultFilter.
Definition at line 56 of file class.ilLucenePathFilter.php.
{
if($this->root == ROOT_FOLDER_ID)
{
return true;
}
return in_array($a_ref_id,$this->subnodes);
}
ilLucenePathFilter::init |
( |
| ) |
|
|
protected |
Read valid reference ids.
- Returns
Definition at line 69 of file class.ilLucenePathFilter.php.
Referenced by __construct().
{
global $tree;
if($this->root == ROOT_FOLDER_ID) {
$this->subnodes = array();
}
else
{
$node = $tree->getNodeData($this->root);
$this->subnodes = $tree->getSubTree($node,false);
}
}
Field Documentation
ilLucenePathFilter::$root = ROOT_FOLDER_ID |
|
protected |
ilLucenePathFilter::$subnodes = array() |
|
protected |
The documentation for this class was generated from the following file: