Download the PHP package cxx/param-inject without Composer

On this page you can find all versions of the php package cxx/param-inject. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package param-inject

Param-Inject

使用依赖注入提供请求参数注入功能,可更直观的处理客户端数据

Install

Thinkphp >= 6.0

Laravel >= 5.0

composer require cxx/param-inject

Start

  1. 添加服务(支持tp和laravel)

    服务使用方式请查看官方文档(Thinkphp, Laravel)

    Thinkphp:Cxx\ParamInject\ThinkParamService

    Laravel:Cxx\ParamInject\LaravelParamService

  2. 创建参数类(命名空间随意,只要能被加载)

  3. 使用

    控制器中

    在路由闭包中也类似

    使用方式在ThinkphpLaravel中一致

类型注释集合

注意:有时在类型转换时会发生和预期的结果不一致的情况,详见类型转换的判别

基础类型

示例 备注
@var int 或 @var integer 整形
@var string 字符串
@var bool 或 @var boolean 布尔类型
@var float 或 @var double 浮点型
@var mixed 此类型不会对数据进行转换

以上类型支持数组形式 如@var int[] @var int[][]

复合类型

示例 备注
@var Test 对象类型,Test是继承Cxx\ParamInject\Param的对象
@var Test[] 对象数组类型

对象类型里面的属性可以是基础类型还可以是复合类型


All versions of param-inject with dependencies

PHP Build Version
Package Version
Requires php Version >=7.2.0,<7.5.0
roave/better-reflection Version ^4.3
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package cxx/param-inject contains the following files

Loading the files please wait ....