castor/context
最新稳定版本:1.1.0
Composer 安装命令:
composer require castor/context
包简介
Context information passing abstraction for PHP
README 文档
README
Context passing abstraction for modern PHP projects, inspired in Golang's context package.
Installation
composer require castor/context
Quick Start
<?php use Castor\Context; // This is a default base context $ctx = Context\nil(); // This returns a new context with the passed values stored $ctx = Context\withValue($ctx, 'foo', 'bar'); // Later in the call stack echo $ctx->value('foo'); // Prints: bar
To learn about the rationale behind this library, best practices when using it and implementation examples, check the documentation.
统计信息
- 总下载量: 40
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 1
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: BSD-3-Clause
- 更新时间: 2022-10-03