thesis/clock

Thesis Clock

Fund package maintenance!
www.tinkoff.ru/cf/5MqZQas2dk7

Installs: 10

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 2

Forks: 0

Open Issues: 0

pkg:composer/thesis/clock

0.1.0 2025-05-09 14:33 UTC

This package is auto-updated.

Last update: 2025-10-09 15:21:55 UTC


README

PHP Version Requirement GitHub Release Code Coverage Mutation testing badge

Installation

composer require thesis/clock

Usage

WallClock is a basic implementation of the Psr\Clock\ClockInterface that returns the current wall-clock time.

use Thesis\Time\WallClock;

$clock = new WallClock();

echo $clock->now()->format('c'); // Outputs current time in ISO 8601 format

Or with a specific timezone:

$clock = new WallClock(new DateTimeZone('Europe/Moscow'));

echo $clock->now()->format('c'); // Outputs Moscow time in ISO 8601 format