ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilLikeMetaDataSearch Class Reference
+ Inheritance diagram for ilLikeMetaDataSearch:
+ Collaboration diagram for ilLikeMetaDataSearch:

Public Member Functions

 ilLikeMetaDataSearch (&$qp_obj)
 Constructor public.
 __createKeywordWhereCondition ()
 __createContributeWhereCondition ()
 __createTitleWhereCondition ()
 __createDescriptionWhereCondition ()
- Public Member Functions inherited from ilMetaDataSearch
 ilMetaDataSearch (&$qp_obj)
 Constructor public.
 setMode ($a_mode)
 Define meta elements to search.
 getMode ()
performSearch ()
 __createInStatement ()
 __searchContribute ()
 __searchKeywords ()
 __searchTitles ()
 __searchDescriptions ()
- Public Member Functions inherited from ilAbstractSearch
 ilAbstractSearch (&$qp_obj)
 Constructor public.
 setFields ($a_fields)
 Set fields to search.
 getFields ()
 Get fields to search.
 setFilter ($a_filter)
 set object type to search in
 setIdFilter ($a_id_filter)
 Set id filter Filters search by given object id.
 getIdFilter ()
 Get Id filter.
 appendToFilter ($a_type)
 Append object type to filter.
 getFilter ()
 get object type to search in
 __createLocateString ()
 build locate string in case of AND search
 __prepareFound (&$row)

Additional Inherited Members

- Data Fields inherited from ilMetaDataSearch
 $mode = ''
 $query_parser = null
 $db = null

Detailed Description

Definition at line 37 of file class.ilLikeMetaDataSearch.php.

Member Function Documentation

ilLikeMetaDataSearch::__createContributeWhereCondition ( )

Definition at line 70 of file class.ilLikeMetaDataSearch.php.

References $ilDB.

{
global $ilDB;
$concat = ' entity ';
$where = " WHERE (";
$counter = 0;
foreach($this->query_parser->getQuotedWords() as $word)
{
if($counter++)
{
$where .= "OR";
}
#$where .= $concat;
#$where .= (" LIKE ('%".$word."%')");
$where .= $ilDB->like($concat,'text','%'.$word.'%');
}
return $where.') ';
}
ilLikeMetaDataSearch::__createDescriptionWhereCondition ( )

Definition at line 120 of file class.ilLikeMetaDataSearch.php.

References $ilDB.

{
global $ilDB;
$concat = ' description ';
$where = " WHERE (";
$counter = 0;
foreach($this->query_parser->getQuotedWords() as $word)
{
if($counter++)
{
$where .= "OR";
}
#$where .= $concat;
#$where .= (" LIKE ('%".$word."%')");
$where .= $ilDB->like($concat,'text','%'.$word.'%');
}
return $where.') ';
}
ilLikeMetaDataSearch::__createKeywordWhereCondition ( )

Definition at line 50 of file class.ilLikeMetaDataSearch.php.

References $ilDB.

{
global $ilDB;
$concat = ' keyword ';
$where = " WHERE (";
$counter = 0;
foreach($this->query_parser->getQuotedWords() as $word)
{
if($counter++)
{
$where .= "OR";
}
$where .= $ilDB->like($concat,'text','%'.$word.'%');
#$where .= $concat;
#$where .= (" LIKE ('%".$word."%')");
}
return $where.') ';
}
ilLikeMetaDataSearch::__createTitleWhereCondition ( )

Definition at line 89 of file class.ilLikeMetaDataSearch.php.

References $ilDB.

{
global $ilDB;
/*
$concat = ' CONCAT(title,coverage) '; // broken if coverage is null
// DONE: fix coverage search
$concat = ' title ';
*/
$concat = $ilDB->concat(
array(
array('title','text'),
array('coverage','text')));
$where = " WHERE (";
$counter = 0;
foreach($this->query_parser->getQuotedWords() as $word)
{
if($counter++)
{
$where .= "OR";
}
#$where .= $concat;
#$where .= (" LIKE ('%".$word."%')");
$where .= $ilDB->like($concat,'text','%'.$word.'%');
}
return $where.' )';
}
ilLikeMetaDataSearch::ilLikeMetaDataSearch ( $qp_obj)

Constructor public.

Definition at line 44 of file class.ilLikeMetaDataSearch.php.

References ilMetaDataSearch\ilMetaDataSearch().

{
}

+ Here is the call graph for this function:


The documentation for this class was generated from the following file: