clippings/date-utils
最新稳定版本:0.4.0
Composer 安装命令:
composer require clippings/date-utils
包简介
Utility for date spans
README 文档
README
Utility for days and date spans
Installation
Install via composer
composer require clippings/date-utils
Usage
$span = new DaysSpan(new Days(20), new Days(40)); $start = new DateTime('today'); $dates = $span->toDateTimeSpan($start); echo $dates->humanize(); // For week days $span = new WeekDaysSpan(new WeekDays(20), new WeekDays(40)); $start = new DateTime('today'); $dates = $span->toDateTimeSpan($start); // For business with support of lists of holidays $holidays = new Holidays([ new DateTime('<Holiday 1>'), new DateTime('<Holiday 2>'), ]); $span = new BusinessDaysSpan(new BusinessDays(20, $holidays), new BusinessDays(40, $holidays)); $start = new DateTime('today'); $dates = $span->toDateTimeSpan($start);
License
Copyright (c) 2015, Clippings Ltd. Developed by Ivan Kerin
Under BSD-3-Clause license, read LICENSE file.
统计信息
- 总下载量: 92.26k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 1
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2015-06-24