ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
arJoinCollection Class Reference

Class arJoinCollection. More...

+ Inheritance diagram for arJoinCollection:
+ Collaboration diagram for arJoinCollection:

Public Member Functions

 getSaveTableName (arJoin $statement)
 
 add (arStatement $statement)
 
 asSQLStatement ()
 
 asORACLEStatement ()
 
 getJoins ()
 
- Public Member Functions inherited from arStatementCollection
 add (arStatement $statement)
 
 hasStatements ()
 
 asSQLStatement ()
 
 asORACLEStatement ()
 
 setAr ($ar)
 
 getAr ()
 
 setStatements ($statements)
 
 getStatements ()
 

Protected Attributes

 $table_names = array()
 
- Protected Attributes inherited from arStatementCollection
 $statements = array()
 
 $ar
 

Additional Inherited Members

- Static Protected Attributes inherited from arStatementCollection
static $cache = array()
 

Detailed Description

Class arJoinCollection.

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

Definition at line 11 of file class.arJoinCollection.php.

Member Function Documentation

◆ add()

arJoinCollection::add ( arStatement  $statement)
Parameters
arStatement$statement

Reimplemented from arStatementCollection.

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

45 {
46 $statement->setTableNameAs($this->getSaveTableName($statement));
47 $this->table_names[] = $statement->getTableName();
48 parent::add($statement);
49 }
add()
Definition: add.php:2
getSaveTableName(arJoin $statement)
setTableNameAs($table_name_as)

References add(), getSaveTableName(), and arStatement\setTableNameAs().

+ Here is the call graph for this function:

◆ asORACLEStatement()

arJoinCollection::asORACLEStatement ( )
Returns
string

Reimplemented from arStatementCollection.

Definition at line 71 of file class.arJoinCollection.php.

72 {
73 $return = '';
74 if ($this->hasStatements()) {
75 foreach ($this->getJoins() as $join) {
76 $return .= $join->asORACLEStatement($this->getAr());
77 }
78 }
79
80 return $return;
81 }

References arStatementCollection\getAr(), getJoins(), and arStatementCollection\hasStatements().

+ Here is the call graph for this function:

◆ asSQLStatement()

arJoinCollection::asSQLStatement ( )
Returns
string

Reimplemented from arStatementCollection.

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

56 {
57 $return = '';
58 if ($this->hasStatements()) {
59 foreach ($this->getJoins() as $join) {
60 $return .= $join->asSQLStatement($this->getAr());
61 }
62 }
63
64 return $return;
65 }

References arStatementCollection\getAr(), getJoins(), and arStatementCollection\hasStatements().

+ Here is the call graph for this function:

◆ getJoins()

arJoinCollection::getJoins ( )
Returns
arJoin[]

Definition at line 87 of file class.arJoinCollection.php.

References arStatementCollection\$statements.

Referenced by asORACLEStatement(), and asSQLStatement().

+ Here is the caller graph for this function:

◆ getSaveTableName()

arJoinCollection::getSaveTableName ( arJoin  $statement)
Parameters
arJoin$statement
Returns
string

Definition at line 25 of file class.arJoinCollection.php.

26 {
27 $table_name = $statement->getTableName();
28 if (in_array($table_name, $this->table_names)) {
29 $vals = array_count_values($this->table_names);
30 $next = $vals[$table_name] + 1;
31 $statement->setFullNames(true);
32 $statement->setIsMapped(true);
33
34 return $table_name . '_' . $next;
35 } else {
36 return $table_name;
37 }
38 }
setIsMapped($is_mapped)
setFullNames($full_names)
getTableName()

References arJoin\getTableName(), arJoin\setFullNames(), and arJoin\setIsMapped().

Referenced by add().

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

Field Documentation

◆ $table_names

arJoinCollection::$table_names = array()
protected

Definition at line 17 of file class.arJoinCollection.php.


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