You are here

class JalaliDatePass in PersianTools 8

Replaces the date service by a persian date.

Hierarchy

  • class \Drupal\jalalidate\JalaliDatePass implements \Symfony\Component\DependencyInjection\Compiler\CompilerPassInterface

Expanded class hierarchy of JalaliDatePass

File

jalalidate/src/JalaliDatePass.php, line 10

Namespace

Drupal\jalalidate
View source
class JalaliDatePass implements CompilerPassInterface {

  /**
   * Replaces the date service by a persian date.
   *
   * @param \Symfony\Component\DependencyInjection\ContainerBuilder $container
   *   The container to process.
   */
  public function process(ContainerBuilder $container) {
    $definition = $container
      ->getDefinition('date');
    $definition
      ->setClass('Drupal\\jalalidate\\JalaliDateFormatter');
  }

}

Members

Namesort descending Modifiers Type Description Overrides
JalaliDatePass::process public function * Replaces the date service by a persian date. * *