ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
arJoin Class Reference

Class arJoin. More...

+ Inheritance diagram for arJoin:
+ Collaboration diagram for arJoin:

Public Member Functions

 asSQLStatement (ActiveRecord $ar)
 setLeft ()
 setRght ()
 setInner ()
 setFields ($fields)
 getFields ()
 setOnFirstField ($on_first_field)
 getOnFirstField ()
 setOnSecondField ($on_second_field)
 getOnSecondField ()
 setOperator ($operator)
 getOperator ()
 setTableName ($table_name)
 getTableName ()
 setType ($type)
 getType ()
 setBothExternal ($both_external)
 getBothExternal ()
 setFullNames ($full_names)
 getFullNames ()
 isIsMapped ()
 setIsMapped ($is_mapped)
- Public Member Functions inherited from arStatement
 getTableNameAs ()
 setTableNameAs ($table_name_as)

Data Fields

const TYPE_NORMAL = self::TYPE_INNER
const TYPE_LEFT = 'LEFT'
const TYPE_RIGHT = 'RIGHT'
const TYPE_INNER = 'INNER'

Protected Attributes

 $type = self::TYPE_NORMAL
 $table_name = ''
 $fields = array( '*' )
 $operator= '='
 $on_first_field = ''
 $on_second_field = ''
 $full_names = false
 $both_external = false
 $is_mapped = false
- Protected Attributes inherited from arStatement
 $table_name_as = ''

Detailed Description

Class arJoin.

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.arJoin.php.

Member Function Documentation

arJoin::asSQLStatement ( ActiveRecord  $ar)
Parameters
ActiveRecord$ar
Returns
string

Reimplemented from arStatement.

Definition at line 60 of file class.arJoin.php.

References getBothExternal(), ActiveRecord\getConnectorContainerName(), getOnFirstField(), getOnSecondField(), getOperator(), getTableName(), arStatement\getTableNameAs(), and getType().

{
$return = ' ' . $this->getType() . ' ';
$return .= ' JOIN ' . $this->getTableName() . ' AS ' . $this->getTableNameAs();
if ($this->getBothExternal()) {
$return .= ' ON ' . $this->getOnFirstField() . ' ' . $this->getOperator() . ' ';
} else {
$return .= ' ON ' . $ar->getConnectorContainerName() . '.' . $this->getOnFirstField() . ' ' . $this->getOperator() . ' ';
}
$return .= $this->getTableNameAs() . '.' . $this->getOnSecondField();
return $return;
}

+ Here is the call graph for this function:

arJoin::getBothExternal ( )
Returns
boolean

Definition at line 196 of file class.arJoin.php.

References $both_external.

Referenced by asSQLStatement().

{
}

+ Here is the caller graph for this function:

arJoin::getFields ( )
Returns
array

Definition at line 100 of file class.arJoin.php.

References $fields.

{
return $this->fields;
}
arJoin::getFullNames ( )
Returns
boolean

Definition at line 212 of file class.arJoin.php.

References $full_names.

{
}
arJoin::getOnFirstField ( )
Returns
string

Definition at line 116 of file class.arJoin.php.

References $on_first_field.

Referenced by asSQLStatement().

{
}

+ Here is the caller graph for this function:

arJoin::getOnSecondField ( )
Returns
string

Definition at line 132 of file class.arJoin.php.

References $on_second_field.

Referenced by asSQLStatement().

+ Here is the caller graph for this function:

arJoin::getOperator ( )
Returns
string

Definition at line 148 of file class.arJoin.php.

Referenced by asSQLStatement().

{
return $this->operator;
}

+ Here is the caller graph for this function:

arJoin::getTableName ( )
Returns
string

Definition at line 164 of file class.arJoin.php.

References $table_name.

Referenced by asSQLStatement(), and arJoinCollection\getSaveTableName().

{
}

+ Here is the caller graph for this function:

arJoin::getType ( )
Returns
string

Definition at line 180 of file class.arJoin.php.

References $type.

Referenced by asSQLStatement().

{
return $this->type;
}

+ Here is the caller graph for this function:

arJoin::isIsMapped ( )
Returns
boolean

Definition at line 220 of file class.arJoin.php.

References $is_mapped.

{
}
arJoin::setBothExternal (   $both_external)
Parameters
boolean$both_external

Definition at line 188 of file class.arJoin.php.

References $both_external.

{
$this->both_external = $both_external;
}
arJoin::setFields (   $fields)
Parameters
array$fields

Definition at line 92 of file class.arJoin.php.

References $fields, and fields.

{
$this->fields = $fields;
}
arJoin::setFullNames (   $full_names)
Parameters
boolean$full_names

Definition at line 204 of file class.arJoin.php.

References $full_names.

Referenced by arJoinCollection\getSaveTableName().

{
$this->full_names = $full_names;
}

+ Here is the caller graph for this function:

arJoin::setInner ( )

Definition at line 84 of file class.arJoin.php.

References setType().

{
$this->setType(self::TYPE_INNER);
}

+ Here is the call graph for this function:

arJoin::setIsMapped (   $is_mapped)
Parameters
boolean$is_mapped

Definition at line 228 of file class.arJoin.php.

References $is_mapped.

Referenced by arJoinCollection\getSaveTableName().

{
$this->is_mapped = $is_mapped;
}

+ Here is the caller graph for this function:

arJoin::setLeft ( )

Definition at line 74 of file class.arJoin.php.

References setType().

{
$this->setType(self::TYPE_LEFT);
}

+ Here is the call graph for this function:

arJoin::setOnFirstField (   $on_first_field)
Parameters
string$on_first_field

Definition at line 108 of file class.arJoin.php.

References $on_first_field.

{
$this->on_first_field = $on_first_field;
}
arJoin::setOnSecondField (   $on_second_field)
Parameters
string$on_second_field

Definition at line 124 of file class.arJoin.php.

References $on_second_field.

{
$this->on_second_field = $on_second_field;
}
arJoin::setOperator (   $operator)
Parameters
string$operator

Definition at line 140 of file class.arJoin.php.

{
$this->operator = $operator;
}
arJoin::setRght ( )

Definition at line 79 of file class.arJoin.php.

References setType().

{
$this->setType(self::TYPE_RIGHT);
}

+ Here is the call graph for this function:

arJoin::setTableName (   $table_name)
Parameters
string$table_name

Definition at line 156 of file class.arJoin.php.

References $table_name.

{
$this->table_name = $table_name;
}
arJoin::setType (   $type)
Parameters
string$type

Definition at line 172 of file class.arJoin.php.

References $type.

Referenced by setInner(), setLeft(), and setRght().

{
$this->type = $type;
}

+ Here is the caller graph for this function:

Field Documentation

arJoin::$both_external = false
protected

Definition at line 48 of file class.arJoin.php.

Referenced by getBothExternal(), and setBothExternal().

arJoin::$fields = array( '*' )
protected

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

Referenced by getFields(), and setFields().

arJoin::$full_names = false
protected

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

Referenced by getFullNames(), and setFullNames().

arJoin::$is_mapped = false
protected

Definition at line 52 of file class.arJoin.php.

Referenced by isIsMapped(), and setIsMapped().

arJoin::$on_first_field = ''
protected

Definition at line 36 of file class.arJoin.php.

Referenced by getOnFirstField(), and setOnFirstField().

arJoin::$on_second_field = ''
protected

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

Referenced by getOnSecondField(), and setOnSecondField().

arJoin::$operator= '='
protected

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

arJoin::$table_name = ''
protected

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

Referenced by getTableName(), and setTableName().

arJoin::$type = self::TYPE_NORMAL
protected

Definition at line 20 of file class.arJoin.php.

Referenced by getType(), and setType().

const arJoin::TYPE_INNER = 'INNER'

Definition at line 16 of file class.arJoin.php.

Referenced by ActiveRecordList\innerjoin().

const arJoin::TYPE_LEFT = 'LEFT'

Definition at line 14 of file class.arJoin.php.

Referenced by ActiveRecordList\leftjoin().

const arJoin::TYPE_NORMAL = self::TYPE_INNER

Definition at line 13 of file class.arJoin.php.

const arJoin::TYPE_RIGHT = 'RIGHT'

Definition at line 15 of file class.arJoin.php.


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