Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/peekandpoke/php-types
Basic types for PHP like Enums, LocalDate etc
https://github.com/peekandpoke/php-types
Last synced: about 2 months ago
JSON representation
Basic types for PHP like Enums, LocalDate etc
- Host: GitHub
- URL: https://github.com/peekandpoke/php-types
- Owner: PeekAndPoke
- Created: 2017-05-15T21:26:13.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-08-20T20:15:00.000Z (over 6 years ago)
- Last Synced: 2024-11-16T09:46:46.034Z (about 2 months ago)
- Language: PHP
- Size: 40 KB
- Stars: 2
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.MD
Awesome Lists containing this project
README
[![Code Coverage](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/badges/coverage.png?b=master)](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/?branch=master)
[![Scrutinizer Code Quality](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/?branch=master)
[![Build Status](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/badges/build.png?b=master)](https://scrutinizer-ci.com/g/PeekAndPoke/php-types/build-status/master)# Why PHP-Types
There are some types that PHP does not provide as part of the language, e.g.:
- Enums
- LocalDate (a date object that enforces creation WITH timezone)
# TODO
( ) LocalDate::isSameDay
( ) LocalDate::isSameWeek
( ) LocalDate::isSameMonth
( ) LocalDate::isSameYear
( ) LocalDate::isSameDecade
( ) LocalDate::isSameCentury
( ) LocalDate::isSameMillennium
( ) extract all DST (daylight saving time aware methods from LocalDate)
$date->dst()->getShift()
$date->dst()->modifyByDays()
...