ILIAS  release_8 Revision v8.19
All Data Structures Namespaces Files Functions Variables Modules Pages
arSelect Class Reference

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V. More...

+ Inheritance diagram for arSelect:
+ Collaboration diagram for arSelect:

Public Member Functions

 asSQLStatement (ActiveRecord $activeRecord, ilDBInterface $db)
 
 getTableName ()
 
 setTableName (string $table_name)
 
 getAs ()
 
 setAs (string $as)
 
 getFieldName ()
 
 setFieldName (string $field_name)
 
- Public Member Functions inherited from arStatement
 asSQLStatement (ActiveRecord $activeRecord, ilDBInterface $db)
 
 getTableNameAs ()
 
 setTableNameAs (string $table_name_as)
 

Protected Attributes

string $table_name = ''
 
string $as = ''
 
string $field_name = ''
 
- Protected Attributes inherited from arStatement
string $table_name_as = ''
 

Additional Inherited Members

- Protected Member Functions inherited from arStatement
 wrapFields (array $fields, ilDBInterface $db)
 
 wrapField (string $field, ilDBInterface $db)
 

Detailed Description

This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Learning e.V.

ILIAS is licensed with the GPL-3.0, see https://www.gnu.org/licenses/gpl-3.0.en.html You should have received a copy of said license along with the source code, too.

If this is not the case or you just want to try ILIAS, you'll find us at: https://www.ilias.de https://github.com/ILIAS-eLearning Class arSelect

Author
Fabian Schmid fs@st.nosp@m.uder.nosp@m.-raim.nosp@m.ann..nosp@m.ch
Version
2.0.7

Definition at line 24 of file class.arSelect.php.

Member Function Documentation

◆ asSQLStatement()

arSelect::asSQLStatement ( ActiveRecord  $activeRecord,
ilDBInterface  $db 
)

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

References getAs(), getFieldName(), getTableName(), and arStatement\wrapField().

30  : string
31  {
32  $return = '';
33  if ($this->getTableName() !== '' && $this->getTableName() !== '0') {
34  $return .= $this->getTableName() . '.';
35  }
36  $return .= $this->wrapField($this->getFieldName(), $db);
37  if ($this->getAs() && $this->getFieldName() !== '*') {
38  $return .= ' AS ' . $this->getAs();
39  }
40 
41  return $return;
42  }
wrapField(string $field, ilDBInterface $db)
+ Here is the call graph for this function:

◆ getAs()

arSelect::getAs ( )

Definition at line 54 of file class.arSelect.php.

References $as.

Referenced by asSQLStatement().

54  : string
55  {
56  return $this->as;
57  }
string $as
+ Here is the caller graph for this function:

◆ getFieldName()

arSelect::getFieldName ( )

Definition at line 64 of file class.arSelect.php.

References $field_name.

Referenced by asSQLStatement().

64  : string
65  {
66  return $this->field_name;
67  }
string $field_name
+ Here is the caller graph for this function:

◆ getTableName()

arSelect::getTableName ( )

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

References $table_name.

Referenced by asSQLStatement().

44  : string
45  {
46  return $this->table_name;
47  }
string $table_name
+ Here is the caller graph for this function:

◆ setAs()

arSelect::setAs ( string  $as)

Definition at line 59 of file class.arSelect.php.

References $as.

59  : void
60  {
61  $this->as = $as;
62  }
string $as

◆ setFieldName()

arSelect::setFieldName ( string  $field_name)

Definition at line 69 of file class.arSelect.php.

References $field_name.

69  : void
70  {
71  $this->field_name = $field_name;
72  }
string $field_name

◆ setTableName()

arSelect::setTableName ( string  $table_name)

Definition at line 49 of file class.arSelect.php.

References $table_name.

49  : void
50  {
51  $this->table_name = $table_name;
52  }
string $table_name

Field Documentation

◆ $as

string arSelect::$as = ''
protected

Definition at line 27 of file class.arSelect.php.

Referenced by getAs(), and setAs().

◆ $field_name

string arSelect::$field_name = ''
protected

Definition at line 28 of file class.arSelect.php.

Referenced by getFieldName(), and setFieldName().

◆ $table_name

string arSelect::$table_name = ''
protected

Definition at line 26 of file class.arSelect.php.

Referenced by getTableName(), and setTableName().


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