ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
class.arWhereCollection.php
Go to the documentation of this file.
1 <?php
2 
25 {
26  public function asSQLStatement(ilDBInterface $db): string
27  {
28  $return = '';
29  if ($this->hasStatements()) {
30  $return .= ' WHERE ';
31  $wheres = $this->getWheres();
32  $last = end($wheres);
33  foreach ($wheres as $where) {
34  $return .= $where->asSQLStatement($this->getAr(), $db);
35  if ($where !== $last) {
36  $return .= ' ' . $where->getLink() . ' ';
37  }
38  }
39  }
40 
41  return $return;
42  }
43 
47  public function getWheres(): array
48  {
49  return $this->statements;
50  }
51 }
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
asSQLStatement(ilDBInterface $db)