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

Public Member Functions

 getHTML ()
 Get HTML presentation.
 getSortable ()
 Get sortable value presentation.
- Public Member Functions inherited from ilADTPresentationBridge
 __construct (ilADT $a_adt)
 Constructor.
 getADT ()
 Get ADT.
 getList ()
 Get list presentation.

Protected Member Functions

 isValidADT (ilADT $a_adt)
 Check if given ADT is valid.
- Protected Member Functions inherited from ilADTPresentationBridge
 setADT (ilADT $a_adt)
 Set ADT.

Additional Inherited Members

- Protected Attributes inherited from ilADTPresentationBridge
 $adt

Detailed Description

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

Member Function Documentation

ilADTDatePresentationBridge::getHTML ( )

Get HTML presentation.

Returns
string

Reimplemented from ilADTPresentationBridge.

Definition at line 12 of file class.ilADTDatePresentationBridge.php.

References ilDatePresentation\formatDate(), and ilADTPresentationBridge\getADT().

{
if(!$this->getADT()->isNull())
{
// :TODO: relative dates?
return ilDatePresentation::formatDate($this->getADT()->getDate());
}
}

+ Here is the call graph for this function:

ilADTDatePresentationBridge::getSortable ( )

Get sortable value presentation.

Returns
mixed

Reimplemented from ilADTPresentationBridge.

Definition at line 22 of file class.ilADTDatePresentationBridge.php.

References ilADTPresentationBridge\getADT(), and IL_CAL_UNIX.

{
if(!$this->getADT()->isNull())
{
return (int)$this->getADT()->getDate()->get(IL_CAL_UNIX);
}
}

+ Here is the call graph for this function:

ilADTDatePresentationBridge::isValidADT ( ilADT  $a_adt)
protected

Check if given ADT is valid.

:TODO: This could be avoided with type-specifc constructors :TODO: bridge base class?

Parameters
ilADT$a_adt

Reimplemented from ilADTPresentationBridge.

Definition at line 7 of file class.ilADTDatePresentationBridge.php.

{
return ($a_adt instanceof ilADTDate);
}

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