ILIAS  trunk Revision v11.0_alpha-3011-gc6b235a2e85
ilTestSearch Class Reference
+ Inheritance diagram for ilTestSearch:
+ Collaboration diagram for ilTestSearch:

Public Member Functions

 __searchTestIntroduction ()
 
 __searchTestTitle ()
 
 __searchSurveyIntroduction ()
 
 __searchSurveyTitle ()
 
 performSearch ()
 
- Public Member Functions inherited from ilAbstractSearch
 __construct (ilQueryParser $qp_obj)
 
 setFields (array $a_fields)
 
 getFields ()
 
 setFilter (array $a_filter)
 
 setIdFilter (array $a_id_filter)
 
 getIdFilter ()
 
 appendToFilter (string $a_type)
 
 getFilter ()
 
 __createLocateString ()
 
 __prepareFound (object $row)
 
 performSearch ()
 

Additional Inherited Members

- Protected Member Functions inherited from ilAbstractSearch
 getValidObjectTypes (ilObjectDefinition $object_definition)
 
- Protected Attributes inherited from ilAbstractSearch
ilDBInterface $db
 
ilQueryParser $query_parser
 
ilSearchResult $search_result
 
array $object_types = []
 

Detailed Description

Definition at line 30 of file class.ilTestSearch.php.

Member Function Documentation

◆ __searchSurveyIntroduction()

ilTestSearch::__searchSurveyIntroduction ( )

Definition at line 77 of file class.ilTestSearch.php.

78 {
79 $this->setFields(array('introduction'));
80
81 $where = $this->__createWhereCondition();
82 $locate = $this->__createLocateString();
83
84 $query = "SELECT obj_fi " .
85 $locate .
86 "FROM svy_svy " .
87 $where;
88
89 $res = $this->db->query($query);
90 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
91 $this->search_result->addEntry(
92 (int) $row->obj_fi,
93 'svy',
94 $this->__prepareFound($row)
95 );
96 }
98 }
setFields(array $a_fields)
ilSearchResult $search_result
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
$res
Definition: ltiservices.php:69

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

Referenced by performSearch().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ __searchSurveyTitle()

ilTestSearch::__searchSurveyTitle ( )

Definition at line 99 of file class.ilTestSearch.php.

100 {
101 $this->setFields(array('title','description'));
102
103 $where = $this->__createWhereCondition();
104 $locate = $this->__createLocateString();
105
106 $query = "SELECT obj_fi " .
107 $locate .
108 "FROM svy_question " .
109 $where;
110
111 $res = $this->db->query($query);
112 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
113 $this->search_result->addEntry(
114 (int) $row->obj_fi,
115 'spl',
116 $this->__prepareFound($row)
117 );
118 }
120 }

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

Referenced by performSearch().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ __searchTestIntroduction()

ilTestSearch::__searchTestIntroduction ( )

Definition at line 32 of file class.ilTestSearch.php.

33 {
34 $this->setFields(array('introduction'));
35
36 $where = $this->__createWhereCondition();
37 $locate = $this->__createLocateString();
38
39 $query = "SELECT obj_fi " .
40 $locate .
41 "FROM tst_tests " .
42 $where;
43
44 $res = $this->db->query($query);
45 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
46 $this->search_result->addEntry(
47 (int) $row->obj_fi,
48 'tst',
49 $this->__prepareFound($row)
50 );
51 }
53 }

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

Referenced by performSearch().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ __searchTestTitle()

ilTestSearch::__searchTestTitle ( )

Definition at line 55 of file class.ilTestSearch.php.

56 {
57 $this->setFields(array('title','description'));
58
59 $where = $this->__createWhereCondition();
60 $locate = $this->__createLocateString();
61
62 $query = "SELECT obj_fi " .
63 $locate .
64 "FROM qpl_questions " .
65 $where;
66
67 $res = $this->db->query($query);
68 while ($row = $res->fetchRow(ilDBConstants::FETCHMODE_OBJECT)) {
69 $this->search_result->addEntry(
70 (int) $row->obj_fi,
71 'qpl',
72 $this->__prepareFound($row)
73 );
74 }
76 }

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

Referenced by performSearch().

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ performSearch()

ilTestSearch::performSearch ( )

Reimplemented from ilAbstractSearch.

Definition at line 123 of file class.ilTestSearch.php.

124 {
125 $this->__searchTestTitle();
127 $this->__searchSurveyTitle();
130 }

References ilAbstractSearch\$search_result, __searchSurveyIntroduction(), __searchSurveyTitle(), __searchTestIntroduction(), and __searchTestTitle().

+ Here is the call graph for this function:

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