abdelrahmanelmaghraby/exif-reader
最新稳定版本:0.1.0
Composer 安装命令:
composer require abdelrahmanelmaghraby/exif-reader
包简介
A simple, straightforward and fully typed, Exif reader library
README 文档
README
This is a simple, straightforward and fully typed Exif reader library. It's based on exif_read_data PHP function, but it avoids a lot of headaches. It requires the Exif extension to be installed.
The simplest way to install it is through Composer:
$ composer require abdelrahmanelmaghraby/exif-reader
To use it, it's as simple as this:
$exifReader = new Reader(); try { $exifData = $exifReader->read('/tests/images/with-coordinates.jpg'); } catch (CannotReadExifData $e) { echo 'Cannot read exif data: ' . $e->getMessage(); } echo $exifData->getCameraData()->getMaker(); // Sony echo $exifData->getCameraData()->getModel(); // F5121 echo $exifData->getFileData()->getTakenDate(); // 2017-06-09 18:43:32 echo $exifData->getGeoLocation()->getLatitude(); // 64.25784 echo $exifData->getGeoLocation()->getLongitude(); // -21.121168
Running the project and contributing
The library comes with a Docker setup. To build the containers:
$ make setup
To run the pipeline (static analysis, tests, mutations) for a specific PHP version:
$ make php72-pipeline $ make php73-pipeline $ make php74-pipeline
统计信息
- 总下载量: 14
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2023-05-29