承接 tomkirsch/microtime 相关项目开发

从需求分析到上线部署,全程专人跟进,保证项目质量与交付效率

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

tomkirsch/microtime

最新稳定版本:v1.0

Composer 安装命令:

composer create-project tomkirsch/microtime

包简介

CodeIgniter4 Microtime

README 文档

README

Extends CI's Time class to provide microseconds. Any methods that pass hour, seconds, etc. now have microsecond int as the last arg. PHP's format for microseconds is .u MySQL field should be DATETIME(6)

use Tomkirsch\MicroTime\MicroTime;

$time = new MicroTime();
$time->setMicrosecond(6666);
print $time; // 2024-04-22 04:12:22.6666

Casting in Entities

use Tomkirsch\MicroTime\MicroTime;

class Transaction extends Entity{
    protected $castHandlers = [
        "microtime" => MicroTimeCast::class,
    ];
    protected $casts = [
		'trans_date'		=> 'microtime',
	];
}

统计信息

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

GitHub 信息

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

其他信息

  • 授权协议: Unknown
  • 更新时间: 2024-10-17