You are here

public function DatexObject::setIntlArgs in Datex 7.2

Generate arguments passed to INTL formatter.

1 call to DatexObject::setIntlArgs()
DatexObject::setUseINTL in datex_api/datex_api.class.inc
Set whether to use PHP-Intl or not.

File

datex_api/datex_api.class.inc, line 834
Provides an API to work with dates.

Class

DatexObject
Base class for localized DateTime.

Code

public function setIntlArgs($a1 = NULL, $a2 = NULL, $a3 = NULL, $a4 = NULL) {
  $default_intl_args = $this
    ->getIntlArgs();
  $this->intlArgs = array();
  foreach (func_get_args() as $index => $arg) {
    if ($arg === NULL) {
      $this->intlArgs[$index] = $default_intl_args[$index];
    }
    else {
      $this->intlArgs[$index] = $arg;
    }
  }
  $this->intlArgs = $default_intl_args;
}