ubc/ltcommons
最新稳定版本:0.1.1
Composer 安装命令:
composer require ubc/ltcommons
包简介
UBC LT Commons
关键字:
README 文档
README
Install
composer require ubc/ltcommons
Usage
Plain PHP
require 'vendor/autoload.php'; // Bootstrap the JMS custom annotations for Object to Json mapping \Doctrine\Common\Annotations\AnnotationRegistry::registerAutoloadNamespace( 'JMS\Serializer\Annotation', dirname(__FILE__).'/vendor/jms/serializer/src' ); $base_url = 'http://sisapi.example.com'; $username = 'service_username'; $password = 'service_password'; $providerFactory = new DataProviderFactory(); $providerFactory->addProvider(new SISDataProvider( $base_url, new GuzzleClient(), new HttpBasic($username, $password), new JMSSerializer() )); $service = new DepartmentCodeService($providerFactory); $codes = $service->getDepartmentCodes(); $student = $service->getStudentById('12345678');
Using with Symfony 2
Please checkout LtCommons bundle
Run Tests
composer install
vendor/bin/phpunit
统计信息
- 总下载量: 431
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 0
- 点击次数: 0
- 依赖项目数: 1
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2014-12-15