ILIAS  release_5-2 Revision v5.2.25-18-g3f80b828510
ilExerciseSearch Class Reference
+ Inheritance diagram for ilExerciseSearch:
+ Collaboration diagram for ilExerciseSearch:

Public Member Functions

performSearch ()
 
- Public Member Functions inherited from ilAbstractSearch
 __construct ($qp_obj)
 Constructor public. More...
 
 setFields ($a_fields)
 Set fields to search. More...
 
 getFields ()
 Get fields to search. More...
 
 setFilter ($a_filter)
 set object type to search in More...
 
 setIdFilter ($a_id_filter)
 Set id filter Filters search by given object id. More...
 
 getIdFilter ()
 Get Id filter. More...
 
 appendToFilter ($a_type)
 Append object type to filter. More...
 
 getFilter ()
 get object type to search in More...
 
 __createLocateString ()
 build locate string in case of AND search More...
 
 __prepareFound (&$row)
 
performSearch ()
 

Additional Inherited Members

- Data Fields inherited from ilAbstractSearch
 $db = null
 
 $query_parser = null
 
 $search_result = null
 
 $object_types
 

Detailed Description

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

Member Function Documentation

◆ performSearch()

& ilExerciseSearch::performSearch ( )

Definition at line 40 of file class.ilExerciseSearch.php.

References $query, $res, $row, ilAbstractSearch\$search_result, ilAbstractSearch\__createLocateString(), array, ilDBConstants\FETCHMODE_OBJECT, and ilAbstractSearch\setFields().

41  {
42  $this->setFields(array('instruction','title'));
43 
44  $where = $this->__createWhereCondition();
45  $locate = $this->__createLocateString();
46 
47  $query = "SELECT exc_id, id ".
48  $locate.
49  "FROM exc_assignment ".
50  $where;
51 
52  $res = $this->db->query($query);
53  while($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT))
54  {
55  $this->search_result->addEntry($row->exc_id,'exc',$this->__prepareFound($row),$row->id);
56  }
57  return $this->search_result;
58  }
__createLocateString()
build locate string in case of AND search
setFields($a_fields)
Set fields to search.
Create styles array
The data for the language used.
+ Here is the call graph for this function:

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