ILIAS  Release_5_0_x_branch Revision 61816
 All Data Structures Namespaces Files Functions Variables Groups Pages
ilADTSearchBridgeSingle Class Reference
+ Inheritance diagram for ilADTSearchBridgeSingle:
+ Collaboration diagram for ilADTSearchBridgeSingle:

Public Member Functions

 getADT ()
 Get ADT.
 isNull ()
 Is null ?
 isValid ()
 validate ()
 Validate current data.
- Public Member Functions inherited from ilADTSearchBridge
 __construct (ilADTDefinition $a_adt_def)
 Constructor.
 setForm (ilPropertyFormGUI $a_form)
 Set form.
 getForm ()
 Get form.
 setElementId ($a_value)
 Set element id (aka form field)
 getElementId ()
 Get element id.
 setTitle ($a_value)
 Set title (aka form field caption)
 getTitle ()
 Get title.
 setTableGUI (ilTable2GUI $a_table)
 Set table gui (for filter mode)
 getTableGUI ()
 Get table gui.
 loadFilter ()
 Load filter value(s) into ADT.
 addToForm ()
 Add ADT-specific fields to form.
 importFromPost (array $a_post=null)
 Import values from (search) form request POST data.
 getSQLCondition ($a_element_id)
 Get SQL condition for current value(s)
 isInCondition (ilADT $a_adt)
 Compare directly against ADT.
 getSerializedValue ()
 Get current value(s) in serialized form (for easy persisting)
 setSerializedValue ($a_value)
 Set current value(s) in serialized form (for easy persisting)

Protected Member Functions

 setDefinition (ilADTDefinition $a_adt_def)
 Set ADT definition.
- Protected Member Functions inherited from ilADTSearchBridge
 isValidADTDefinition (ilADTDefinition $a_adt_def)
 Check if given ADT definition is valid.
 writeFilter ($a_value=null)
 Write value(s) to filter store (in session)
 readFilter ()
 Load value(s) from filter store (in session)
 addToParentElement (ilFormPropertyGUI $a_field)
 Add form field to parent element.
 addToElementId ($a_add)
 Add sub-element.
 shouldBeImportedFromPost ($a_post)
 Check if incoming values should be imported at all.
 extractPostValues (array $a_post=null)
 Extract data from (post) values.

Protected Attributes

 $adt
- Protected Attributes inherited from ilADTSearchBridge
 $form
 $table_gui
 $table_filter_fields
 $id
 $title
 $info

Detailed Description

Definition at line 5 of file class.ilADTSearchBridgeSingle.php.

Member Function Documentation

ilADTSearchBridgeSingle::getADT ( )

Get ADT.

Returns
ilADT

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

References $adt.

Referenced by ilADTFloatSearchBridgeSingle\addToForm(), ilADTIntegerSearchBridgeSingle\addToForm(), ilADTEnumSearchBridgeSingle\addToForm(), ilADTLocationSearchBridgeSingle\addToForm(), ilADTTextSearchBridgeSingle\addToForm(), ilADTDateTimeSearchBridgeSingle\addToForm(), ilADTDateSearchBridgeSingle\addToForm(), ilADTEnumSearchBridgeMulti\addToForm(), ilAdvancedMDFieldDefinitionSelectMulti\findBySingleValue(), ilADTIntegerSearchBridgeSingle\getSerializedValue(), ilADTEnumSearchBridgeSingle\getSerializedValue(), ilADTDateSearchBridgeSingle\getSerializedValue(), ilADTDateTimeSearchBridgeSingle\getSerializedValue(), ilADTEnumSearchBridgeMulti\getSerializedValue(), ilADTTextSearchBridgeSingle\getSerializedValue(), ilADTLocationSearchBridgeSingle\getSerializedValue(), ilADTIntegerSearchBridgeSingle\getSQLCondition(), ilADTFloatSearchBridgeSingle\getSQLCondition(), ilADTTextSearchBridgeSingle\getSQLCondition(), ilADTEnumSearchBridgeSingle\getSQLCondition(), ilADTEnumSearchBridgeMulti\getSQLCondition(), ilADTDateTimeSearchBridgeSingle\getSQLCondition(), ilADTDateSearchBridgeSingle\getSQLCondition(), ilADTLocationSearchBridgeSingle\getSQLCondition(), ilADTIntegerSearchBridgeSingle\importFromPost(), ilADTFloatSearchBridgeSingle\importFromPost(), ilADTTextSearchBridgeSingle\importFromPost(), ilADTEnumSearchBridgeSingle\importFromPost(), ilADTEnumSearchBridgeMulti\importFromPost(), ilADTDateSearchBridgeSingle\importFromPost(), ilADTDateTimeSearchBridgeSingle\importFromPost(), ilADTLocationSearchBridgeSingle\importFromPost(), ilADTIntegerSearchBridgeSingle\isInCondition(), ilADTFloatSearchBridgeSingle\isInCondition(), ilADTEnumSearchBridgeSingle\isInCondition(), ilADTDateTimeSearchBridgeSingle\isInCondition(), ilADTDateSearchBridgeSingle\isInCondition(), ilADTEnumSearchBridgeMulti\isInCondition(), ilADTTextSearchBridgeSingle\isInCondition(), isNull(), isValid(), ilADTEnumSearchBridgeSingle\loadFilter(), ilADTTextSearchBridgeSingle\loadFilter(), ilADTDateTimeSearchBridgeSingle\loadFilter(), ilADTEnumSearchBridgeMulti\loadFilter(), ilADTEnumSearchBridgeSingle\setSerializedValue(), ilADTDateSearchBridgeSingle\setSerializedValue(), ilADTDateTimeSearchBridgeSingle\setSerializedValue(), ilADTEnumSearchBridgeMulti\setSerializedValue(), ilADTTextSearchBridgeSingle\setSerializedValue(), ilADTLocationSearchBridgeSingle\setSerializedValue(), and validate().

{
return $this->adt;
}

+ Here is the caller graph for this function:

ilADTSearchBridgeSingle::setDefinition ( ilADTDefinition  $a_adt_def)
protected

Set ADT definition.

Parameters
ilADTDefinition$a_adt_def

Reimplemented from ilADTSearchBridge.

Reimplemented in ilADTSearchBridgeMulti.

Definition at line 9 of file class.ilADTSearchBridgeSingle.php.

References ilADTFactory\getInstance(), and ilADTSearchBridge\isValidADTDefinition().

{
if($this->isValidADTDefinition($a_adt_def))
{
$this->adt = ilADTFactory::getInstance()->getInstanceByDefinition($a_adt_def);
return;
}
throw new Exception('ilADTSearchBridge type mismatch.');
}

+ Here is the call graph for this function:

ilADTSearchBridgeSingle::validate ( )

Validate current data.

Returns
bool

Reimplemented from ilADTSearchBridge.

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

References getADT(), ilADTSearchBridge\getElementId(), ilADTSearchBridge\getForm(), and isValid().

{
if(!$this->isValid())
{
$tmp = array();
$mess = $this->getADT()->getValidationErrors();
foreach($mess as $error_code)
{
$tmp[] = $this->getADT()->translateErrorCode($error_code);
}
$field = $this->getForm()->getItemByPostvar($this->getElementId());
$field->setAlert(implode("<br />", $tmp));
return false;
}
return true;
}

+ Here is the call graph for this function:

Field Documentation

ilADTSearchBridgeSingle::$adt
protected

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