ILIAS  release_5-3 Revision v5.3.23-19-g915713cf615
ilADTDatePresentationBridge Class Reference
+ Inheritance diagram for ilADTDatePresentationBridge:
+ Collaboration diagram for ilADTDatePresentationBridge:

Public Member Functions

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

Protected Member Functions

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

Additional Inherited Members

- Protected Attributes inherited from ilADTPresentationBridge
 $adt
 
 $decorator
 

Detailed Description

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

Member Function Documentation

◆ getHTML()

ilADTDatePresentationBridge::getHTML ( )

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

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

13  {
14  if (!$this->getADT()->isNull()) {
15  // :TODO: relative dates?
16 
17  return $this->decorate(ilDatePresentation::formatDate($this->getADT()->getDate()));
18  }
19  }
static formatDate(ilDateTime $date, $a_skip_day=false, $a_include_wd=false)
Format a date public.
decorate($a_value)
Decorate value.
+ Here is the call graph for this function:

◆ getSortable()

ilADTDatePresentationBridge::getSortable ( )

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

References ilADTPresentationBridge\getADT(), and IL_CAL_UNIX.

22  {
23  if (!$this->getADT()->isNull()) {
24  return (int) $this->getADT()->getDate()->get(IL_CAL_UNIX);
25  }
26  }
const IL_CAL_UNIX
+ Here is the call graph for this function:

◆ isValidADT()

ilADTDatePresentationBridge::isValidADT ( ilADT  $a_adt)
protected

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

8  {
9  return ($a_adt instanceof ilADTDate);
10  }

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