2017 © Pedro Peláez
 

joomla-package datetime

Joomla DateTime Package

image

joomla/datetime

Joomla DateTime Package

  • Sunday, April 8, 2018
  • by mbabker
  • Repository
  • 9 Watchers
  • 4 Stars
  • 935 Installations
  • PHP
  • 1 Dependents
  • 0 Suggesters
  • 2 Forks
  • 3 Open issues
  • 2 Versions
  • 4 % Grown

The README.md

The DateTime Package

Build Status Scrutinizer Code Quality Code Coverage, (*1)

Latest Stable Version Total Downloads Latest Unstable Version License, (*2)

This is a DateTime package built for the Joomla! Framework during Google Summer of Code 2014. The main goal for this library was to create a DateTime object as an Immutable Value Object., (*3)

Immutability

If you know how to use PHP DateTime object then you know almost everything about that package. Before you start using it you need to know one more thing - this DateTime is immutable. To explain what immutability means let's take a look at an example:, (*4)

$start = new DateTime('2014-08-24');
$end = $start->addDays(2);

echo $start->format('Y-m-d');  // 2014-08-24
echo $end->format('Y-m-d');    // 2014-08-26

Every method of DateTime is returning a new object and is not changing the current one. That's the most important thing what you have to know., (*5)

Usage

Credits

Jens Segers for their approach to translations, (*6)

Installation via Composer

Add "joomla/datetime": "~2.0" to the require block in your composer.json and then run composer install., (*7)

{
    "require": {
        "joomla/datetime": "~2.0"
    }
}

Alternatively, you can simply run the following from the command line:, (*8)

composer require joomla/date "~2.0"

The Versions

08/04 2018

dev-master

9999999-dev https://github.com/joomla-framework/datetime

Joomla DateTime Package

  Sources   Download

LGPL-2.1+

The Requires

 

The Development Requires

framework datetime joomla

18/09 2014

2.0.0

2.0.0.0 https://github.com/joomla-framework/datetime

Joomla DateTime Package

  Sources   Download

LGPL-2.1+

The Requires

 

The Development Requires

framework datetime joomla