effectra/clock 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

effectra/clock

最新稳定版本:v1.0.0

Composer 安装命令:

composer require effectra/clock

包简介

The Effectra Clock package.

README 文档

README

This is a PHP class named Effectra\Clock that implements the Psr\Clock\Clock interface. It provides a simple and standard way to retrieve the current time and timestamp in PHP applications.

Features

  • Implements the Psr\Clock\ClockInterface interface
  • Provides the now() method to retrieve the current time as a DateTimeImmutable object
  • Offers the timestamp() method to retrieve the current timestamp as an integer

Usage

// Create a new instance of the Clock class
$clock = new \Effectra\Clock\Clock();

// Get the current time as a DateTimeImmutable object
$currentDateTime = $clock->now();

// Get the current timestamp as an integer
$currentTimestamp = $clock->timestamp();

Contributing

Contributions are welcome! If you encounter any issues or have suggestions for improvements, please feel free to submit a pull request or open an issue on the GitHub repository.

License

This package is open-source and available under the MIT License. "# clock"

统计信息

  • 总下载量: 26
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 1
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2023-06-19