Use Zend-Mime instead of PEAR package. PHP 7. (#900)
* Using Auzre Store SDK for parsing mime types.
* Test.
* Fix PHPCS errors.
* Fix PHPCS errors.
* Fix PHPCS
* Using Zend/Mime to parse mime.
* HHVM
* update php-cs-fixer
* Update composer.lock.
* Remove php-cs-fixer
* Revert "Remove php-cs-fixer"
This reverts commit 0446375e1d
.
* Remove HHVM
* A link to package.
* Chanegelog.
* Minor fix.
* Remove pear/mail_mime-decode
* Remove unused 'use'.
* Examples.
This commit is contained in:
Родитель
04bd2038ec
Коммит
8af9ef5894
|
@ -11,3 +11,4 @@ phpcs-checkstyle.tmp
|
|||
composer.phar
|
||||
.vscode/
|
||||
.idea/
|
||||
examples/MediaServices/IndexerOutput/
|
||||
|
|
|
@ -1,7 +1,8 @@
|
|||
language: php
|
||||
|
||||
php:
|
||||
- '5.6'
|
||||
- '5.6'
|
||||
- '7.0'
|
||||
|
||||
sudo: false
|
||||
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
[![Build Status](https://travis-ci.org/Azure/azure-sdk-for-php.svg?branch=master)](https://travis-ci.org/Azure/azure-sdk-for-php)
|
||||
[![Latest Stable Version](https://poser.pugx.org/microsoft/windowsazure/v/stable)](https://packagist.org/packages/microsoft/windowsazure)
|
||||
|
||||
# Microsoft Azure SDK for PHP
|
||||
|
||||
|
|
|
@ -11,7 +11,9 @@
|
|||
- the `sendContext()` function from `\WindowsAzure\Common\Internal\RestProxy` is replaced by `sendHttpContext()`.
|
||||
- the `send()` function from `\WindowsAzure\MediaServices\MediaServicesRestProxy` is replaced by `sendHttp()`.
|
||||
- `\WindowsAzure\Common\Internal\Http\BatchResponse` constructor the first parameter is `Response`.
|
||||
- Using `zendframework/zend-mime` instead of `pear/mail_mime-decode`.
|
||||
- Switch to PHP 5.6.
|
||||
- Support for PHP 7.
|
||||
|
||||
Windows Azure SDK For PHP 0.4.5, 2016-09-26
|
||||
-------------------------------------------
|
||||
|
|
|
@ -13,10 +13,11 @@
|
|||
"php": ">=5.6",
|
||||
"pear/net_url2": "^2.2",
|
||||
"pear/mail_mime": "^1.10",
|
||||
"pear/mail_mime-decode": "^1.5",
|
||||
"firebase/php-jwt": "^4.0",
|
||||
"microsoft/azure-storage": "^0.10",
|
||||
"guzzlehttp/guzzle": "^6.2"
|
||||
"guzzlehttp/guzzle": "^6.2",
|
||||
"zendframework/zend-mime": "^2.6",
|
||||
"zendframework/zend-mail": "^2.7"
|
||||
},
|
||||
"require-dev": {
|
||||
"mikey179/vfsStream": "^1.6",
|
||||
|
@ -28,7 +29,7 @@
|
|||
"phpmd/phpmd": "^2.4",
|
||||
"squizlabs/php_codesniffer": "^2.6",
|
||||
"mayflower/php-codebrowser": "^1.1",
|
||||
"friendsofphp/php-cs-fixer": "^1.11"
|
||||
"friendsofphp/php-cs-fixer": "^1.12.2"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": { "WindowsAzure\\": "src/" }
|
||||
|
|
|
@ -4,9 +4,36 @@
|
|||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"hash": "1322f36ca1ec6918e236bdc25bcf213d",
|
||||
"content-hash": "3c5ee171f7a43decbb7508ab4601529e",
|
||||
"hash": "022590081c5eedb29b3fdd2782e1c057",
|
||||
"content-hash": "6b5f52c375b78345ca3fa8b30c04ccd9",
|
||||
"packages": [
|
||||
{
|
||||
"name": "container-interop/container-interop",
|
||||
"version": "1.1.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/container-interop/container-interop.git",
|
||||
"reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/container-interop/container-interop/zipball/fc08354828f8fd3245f77a66b9e23a6bca48297e",
|
||||
"reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e",
|
||||
"shasum": ""
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Interop\\Container\\": "src/Interop/Container/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"description": "Promoting the interoperability of container objects (DIC, SL, etc.)",
|
||||
"time": "2014-12-30 15:22:37"
|
||||
},
|
||||
{
|
||||
"name": "firebase/php-jwt",
|
||||
"version": "v4.0.0",
|
||||
|
@ -372,54 +399,6 @@
|
|||
"homepage": "http://pear.php.net/package/Mail_Mime",
|
||||
"time": "2015-09-13 12:42:41"
|
||||
},
|
||||
{
|
||||
"name": "pear/mail_mime-decode",
|
||||
"version": "1.5.5.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/dreamfactorysoftware/Mail_mimeDecode.git",
|
||||
"reference": "a53c1ce051b212e23f7f67ea8d31015640de1129"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/dreamfactorysoftware/Mail_mimeDecode/zipball/a53c1ce051b212e23f7f67ea8d31015640de1129",
|
||||
"reference": "a53c1ce051b212e23f7f67ea8d31015640de1129",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"pear/pear_exception": "*"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "*"
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-0": {
|
||||
"Mail_mimeDecode": ""
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"include-path": [
|
||||
"./"
|
||||
],
|
||||
"license": [
|
||||
"BSD-2-Clause"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Cipriano Groenendal",
|
||||
"email": "cipri@php.net",
|
||||
"role": "Lead"
|
||||
},
|
||||
{
|
||||
"name": "Aleksander Machniak",
|
||||
"email": "alec@php.net",
|
||||
"role": "Lead"
|
||||
}
|
||||
],
|
||||
"description": "More info available on: http://pear.php.net/package/Mail_mimeDecode",
|
||||
"time": "2014-04-15 19:29:16"
|
||||
},
|
||||
{
|
||||
"name": "pear/net_url2",
|
||||
"version": "v2.2.1",
|
||||
|
@ -629,6 +608,347 @@
|
|||
"response"
|
||||
],
|
||||
"time": "2016-08-06 14:39:51"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-hydrator",
|
||||
"version": "1.1.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-hydrator.git",
|
||||
"reference": "22652e1661a5a10b3f564cf7824a2206cf5a4a65"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-hydrator/zipball/22652e1661a5a10b3f564cf7824a2206cf5a4a65",
|
||||
"reference": "22652e1661a5a10b3f564cf7824a2206cf5a4a65",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-stdlib": "^2.7 || ^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"squizlabs/php_codesniffer": "^2.0@dev",
|
||||
"zendframework/zend-eventmanager": "^2.6.2 || ^3.0",
|
||||
"zendframework/zend-filter": "^2.6",
|
||||
"zendframework/zend-inputfilter": "^2.6",
|
||||
"zendframework/zend-serializer": "^2.6.1",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-eventmanager": "^2.6.2 || ^3.0, to support aggregate hydrator usage",
|
||||
"zendframework/zend-filter": "^2.6, to support naming strategy hydrator usage",
|
||||
"zendframework/zend-serializer": "^2.6.1, to use the SerializableStrategy",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3, to support hydrator plugin manager usage"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-release-1.0": "1.0-dev",
|
||||
"dev-release-1.1": "1.1-dev",
|
||||
"dev-master": "2.0-dev",
|
||||
"dev-develop": "2.1-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Hydrator\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-hydrator",
|
||||
"keywords": [
|
||||
"hydrator",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-02-18 22:38:26"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-loader",
|
||||
"version": "2.5.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-loader.git",
|
||||
"reference": "c5fd2f071bde071f4363def7dea8dec7393e135c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-loader/zipball/c5fd2f071bde071f4363def7dea8dec7393e135c",
|
||||
"reference": "c5fd2f071bde071f4363def7dea8dec7393e135c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.23"
|
||||
},
|
||||
"require-dev": {
|
||||
"fabpot/php-cs-fixer": "1.7.*",
|
||||
"phpunit/phpunit": "~4.0"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.5-dev",
|
||||
"dev-develop": "2.6-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Loader\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-loader",
|
||||
"keywords": [
|
||||
"loader",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2015-06-03 14:05:47"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-mail",
|
||||
"version": "2.7.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-mail.git",
|
||||
"reference": "2e817b58ebaa2b422a25d854106a91f74b6a7976"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-mail/zipball/2e817b58ebaa2b422a25d854106a91f74b6a7976",
|
||||
"reference": "2e817b58ebaa2b422a25d854106a91f74b6a7976",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-loader": "^2.5",
|
||||
"zendframework/zend-mime": "^2.5",
|
||||
"zendframework/zend-stdlib": "^2.7 || ^3.0",
|
||||
"zendframework/zend-validator": "^2.6"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^4.8",
|
||||
"squizlabs/php_codesniffer": "^2.3.1",
|
||||
"zendframework/zend-config": "^2.6",
|
||||
"zendframework/zend-crypt": "^2.6",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-crypt": "Crammd5 support in SMTP Auth",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3 when using SMTP to deliver messages"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.7-dev",
|
||||
"dev-develop": "2.8-dev"
|
||||
},
|
||||
"zf": {
|
||||
"component": "Zend\\Mail",
|
||||
"config-provider": "Zend\\Mail\\ConfigProvider"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Mail\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"description": "provides generalized functionality to compose and send both text and MIME-compliant multipart e-mail messages",
|
||||
"homepage": "https://github.com/zendframework/zend-mail",
|
||||
"keywords": [
|
||||
"mail",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-05-09 21:52:30"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-mime",
|
||||
"version": "2.6.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-mime.git",
|
||||
"reference": "340769c3d962ac4d9d3cf9da7e75419368e56fcc"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-mime/zipball/340769c3d962ac4d9d3cf9da7e75419368e56fcc",
|
||||
"reference": "340769c3d962ac4d9d3cf9da7e75419368e56fcc",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-stdlib": "^2.7 || ^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"fabpot/php-cs-fixer": "1.7.*",
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"zendframework/zend-mail": "^2.6"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-mail": "Zend\\Mail component"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.6-dev",
|
||||
"dev-develop": "2.7-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Mime\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-mime",
|
||||
"keywords": [
|
||||
"mime",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-04-20 21:02:01"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-stdlib",
|
||||
"version": "2.7.7",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-stdlib.git",
|
||||
"reference": "0e44eb46788f65e09e077eb7f44d2659143bcc1f"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-stdlib/zipball/0e44eb46788f65e09e077eb7f44d2659143bcc1f",
|
||||
"reference": "0e44eb46788f65e09e077eb7f44d2659143bcc1f",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-hydrator": "~1.1"
|
||||
},
|
||||
"require-dev": {
|
||||
"athletic/athletic": "~0.1",
|
||||
"fabpot/php-cs-fixer": "1.7.*",
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"zendframework/zend-config": "~2.5",
|
||||
"zendframework/zend-eventmanager": "~2.5",
|
||||
"zendframework/zend-filter": "~2.5",
|
||||
"zendframework/zend-inputfilter": "~2.5",
|
||||
"zendframework/zend-serializer": "~2.5",
|
||||
"zendframework/zend-servicemanager": "~2.5"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-eventmanager": "To support aggregate hydrator usage",
|
||||
"zendframework/zend-filter": "To support naming strategy hydrator usage",
|
||||
"zendframework/zend-serializer": "Zend\\Serializer component",
|
||||
"zendframework/zend-servicemanager": "To support hydrator plugin manager usage"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-release-2.7": "2.7-dev",
|
||||
"dev-master": "3.0-dev",
|
||||
"dev-develop": "3.1-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Stdlib\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-stdlib",
|
||||
"keywords": [
|
||||
"stdlib",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-04-12 21:17:31"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-validator",
|
||||
"version": "2.8.1",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-validator.git",
|
||||
"reference": "8ec9f57a717dd37340308aa632f148a2c2be1cfc"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-validator/zipball/8ec9f57a717dd37340308aa632f148a2c2be1cfc",
|
||||
"reference": "8ec9f57a717dd37340308aa632f148a2c2be1cfc",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"container-interop/container-interop": "^1.1",
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-stdlib": "^2.7 || ^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"fabpot/php-cs-fixer": "1.7.*",
|
||||
"phpunit/phpunit": "^4.0",
|
||||
"zendframework/zend-cache": "^2.6.1",
|
||||
"zendframework/zend-config": "^2.6",
|
||||
"zendframework/zend-db": "^2.7",
|
||||
"zendframework/zend-filter": "^2.6",
|
||||
"zendframework/zend-http": "^2.5.4",
|
||||
"zendframework/zend-i18n": "^2.6",
|
||||
"zendframework/zend-math": "^2.6",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3",
|
||||
"zendframework/zend-session": "^2.6.2",
|
||||
"zendframework/zend-uri": "^2.5"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-db": "Zend\\Db component",
|
||||
"zendframework/zend-filter": "Zend\\Filter component, required by the Digits validator",
|
||||
"zendframework/zend-i18n": "Zend\\I18n component to allow translation of validation error messages as well as to use the various Date validators",
|
||||
"zendframework/zend-i18n-resources": "Translations of validator messages",
|
||||
"zendframework/zend-math": "Zend\\Math component",
|
||||
"zendframework/zend-servicemanager": "Zend\\ServiceManager component to allow using the ValidatorPluginManager and validator chains",
|
||||
"zendframework/zend-session": "Zend\\Session component",
|
||||
"zendframework/zend-uri": "Zend\\Uri component, required by the Uri and Sitemap\\Loc validators"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.8-dev",
|
||||
"dev-develop": "2.9-dev"
|
||||
},
|
||||
"zf": {
|
||||
"component": "Zend\\Validator",
|
||||
"config-provider": "Zend\\Validator\\ConfigProvider"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Validator\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"description": "provides a set of commonly needed validators",
|
||||
"homepage": "https://github.com/zendframework/zend-validator",
|
||||
"keywords": [
|
||||
"validator",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-06-23 13:44:31"
|
||||
}
|
||||
],
|
||||
"packages-dev": [
|
||||
|
@ -750,64 +1070,37 @@
|
|||
],
|
||||
"time": "2012-12-19 10:50:58"
|
||||
},
|
||||
{
|
||||
"name": "container-interop/container-interop",
|
||||
"version": "1.1.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/container-interop/container-interop.git",
|
||||
"reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/container-interop/container-interop/zipball/fc08354828f8fd3245f77a66b9e23a6bca48297e",
|
||||
"reference": "fc08354828f8fd3245f77a66b9e23a6bca48297e",
|
||||
"shasum": ""
|
||||
},
|
||||
"type": "library",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Interop\\Container\\": "src/Interop/Container/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"description": "Promoting the interoperability of container objects (DIC, SL, etc.)",
|
||||
"time": "2014-12-30 15:22:37"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/annotations",
|
||||
"version": "v1.2.7",
|
||||
"version": "v1.3.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/annotations.git",
|
||||
"reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535"
|
||||
"reference": "30e07cf03edc3cd3ef579d0dd4dd8c58250799a5"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/annotations/zipball/f25c8aab83e0c3e976fd7d19875f198ccf2f7535",
|
||||
"reference": "f25c8aab83e0c3e976fd7d19875f198ccf2f7535",
|
||||
"url": "https://api.github.com/repos/doctrine/annotations/zipball/30e07cf03edc3cd3ef579d0dd4dd8c58250799a5",
|
||||
"reference": "30e07cf03edc3cd3ef579d0dd4dd8c58250799a5",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"doctrine/lexer": "1.*",
|
||||
"php": ">=5.3.2"
|
||||
"php": "^5.6 || ^7.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"doctrine/cache": "1.*",
|
||||
"phpunit/phpunit": "4.*"
|
||||
"phpunit/phpunit": "^5.6.1"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.3.x-dev"
|
||||
"dev-master": "1.4.x-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-0": {
|
||||
"Doctrine\\Common\\Annotations\\": "lib/"
|
||||
"psr-4": {
|
||||
"Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
|
@ -843,7 +1136,7 @@
|
|||
"docblock",
|
||||
"parser"
|
||||
],
|
||||
"time": "2015-08-31 12:32:49"
|
||||
"time": "2016-10-24 11:45:47"
|
||||
},
|
||||
{
|
||||
"name": "doctrine/instantiator",
|
||||
|
@ -3346,7 +3639,7 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/config",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/config.git",
|
||||
|
@ -3399,16 +3692,16 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/console",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/console.git",
|
||||
"reference": "d7a5a88178f94dcc29531ea4028ea614e35452d4"
|
||||
"reference": "7350016c8abcab897046f1aead2b766b84d3eff8"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/console/zipball/d7a5a88178f94dcc29531ea4028ea614e35452d4",
|
||||
"reference": "d7a5a88178f94dcc29531ea4028ea614e35452d4",
|
||||
"url": "https://api.github.com/repos/symfony/console/zipball/7350016c8abcab897046f1aead2b766b84d3eff8",
|
||||
"reference": "7350016c8abcab897046f1aead2b766b84d3eff8",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -3456,7 +3749,7 @@
|
|||
],
|
||||
"description": "Symfony Console Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-09-28 00:10:16"
|
||||
"time": "2016-10-06 01:43:09"
|
||||
},
|
||||
{
|
||||
"name": "symfony/debug",
|
||||
|
@ -3517,16 +3810,16 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/dependency-injection",
|
||||
"version": "v3.1.5",
|
||||
"version": "v3.1.6",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/dependency-injection.git",
|
||||
"reference": "8fa4be9a36f41e49b0c3969678c41c81ed463816"
|
||||
"reference": "c578891216090069cd6d2e573402e13e39b3ad5c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/8fa4be9a36f41e49b0c3969678c41c81ed463816",
|
||||
"reference": "8fa4be9a36f41e49b0c3969678c41c81ed463816",
|
||||
"url": "https://api.github.com/repos/symfony/dependency-injection/zipball/c578891216090069cd6d2e573402e13e39b3ad5c",
|
||||
"reference": "c578891216090069cd6d2e573402e13e39b3ad5c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -3573,20 +3866,20 @@
|
|||
],
|
||||
"description": "Symfony DependencyInjection Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-09-24 15:56:48"
|
||||
"time": "2016-10-24 15:52:44"
|
||||
},
|
||||
{
|
||||
"name": "symfony/event-dispatcher",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/event-dispatcher.git",
|
||||
"reference": "889983a79a043dfda68f38c38b6dba092dd49cd8"
|
||||
"reference": "25c576abd4e0f212e678fe8b2bd9a9a98c7ea934"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/889983a79a043dfda68f38c38b6dba092dd49cd8",
|
||||
"reference": "889983a79a043dfda68f38c38b6dba092dd49cd8",
|
||||
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/25c576abd4e0f212e678fe8b2bd9a9a98c7ea934",
|
||||
"reference": "25c576abd4e0f212e678fe8b2bd9a9a98c7ea934",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -3633,7 +3926,7 @@
|
|||
],
|
||||
"description": "Symfony EventDispatcher Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-07-28 16:56:28"
|
||||
"time": "2016-10-13 01:43:15"
|
||||
},
|
||||
{
|
||||
"name": "symfony/filesystem",
|
||||
|
@ -3686,7 +3979,7 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/finder",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/finder.git",
|
||||
|
@ -3794,7 +4087,7 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/process",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/process.git",
|
||||
|
@ -3843,7 +4136,7 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/stopwatch",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/stopwatch.git",
|
||||
|
@ -3956,16 +4249,16 @@
|
|||
},
|
||||
{
|
||||
"name": "symfony/validator",
|
||||
"version": "v2.8.12",
|
||||
"version": "v2.8.13",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/validator.git",
|
||||
"reference": "bbd771ada2317a13acaba1e72e8d6e175bd1de18"
|
||||
"reference": "987bf3a7d585680773bc79f6cf3d9e78340cb02c"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/validator/zipball/bbd771ada2317a13acaba1e72e8d6e175bd1de18",
|
||||
"reference": "bbd771ada2317a13acaba1e72e8d6e175bd1de18",
|
||||
"url": "https://api.github.com/repos/symfony/validator/zipball/987bf3a7d585680773bc79f6cf3d9e78340cb02c",
|
||||
"reference": "987bf3a7d585680773bc79f6cf3d9e78340cb02c",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -4025,20 +4318,20 @@
|
|||
],
|
||||
"description": "Symfony Validator Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-10-03 17:30:13"
|
||||
"time": "2016-10-19 22:37:24"
|
||||
},
|
||||
{
|
||||
"name": "symfony/yaml",
|
||||
"version": "v3.1.5",
|
||||
"version": "v3.1.6",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/yaml.git",
|
||||
"reference": "368b9738d4033c8b93454cb0dbd45d305135a6d3"
|
||||
"reference": "7ff51b06c6c3d5cc6686df69004a42c69df09e27"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/yaml/zipball/368b9738d4033c8b93454cb0dbd45d305135a6d3",
|
||||
"reference": "368b9738d4033c8b93454cb0dbd45d305135a6d3",
|
||||
"url": "https://api.github.com/repos/symfony/yaml/zipball/7ff51b06c6c3d5cc6686df69004a42c69df09e27",
|
||||
"reference": "7ff51b06c6c3d5cc6686df69004a42c69df09e27",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -4074,7 +4367,7 @@
|
|||
],
|
||||
"description": "Symfony Yaml Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2016-09-25 08:27:07"
|
||||
"time": "2016-10-24 18:41:13"
|
||||
},
|
||||
{
|
||||
"name": "theseer/fdomdocument",
|
||||
|
@ -4118,16 +4411,16 @@
|
|||
},
|
||||
{
|
||||
"name": "twig/twig",
|
||||
"version": "v1.26.1",
|
||||
"version": "v1.27.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/twigphp/Twig.git",
|
||||
"reference": "a09d8ee17ac1cfea29ed60c83960ad685c6a898d"
|
||||
"reference": "3c6c0033fd3b5679c6e1cb60f4f9766c2b424d97"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/twigphp/Twig/zipball/a09d8ee17ac1cfea29ed60c83960ad685c6a898d",
|
||||
"reference": "a09d8ee17ac1cfea29ed60c83960ad685c6a898d",
|
||||
"url": "https://api.github.com/repos/twigphp/Twig/zipball/3c6c0033fd3b5679c6e1cb60f4f9766c2b424d97",
|
||||
"reference": "3c6c0033fd3b5679c6e1cb60f4f9766c2b424d97",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
|
@ -4140,7 +4433,7 @@
|
|||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.26-dev"
|
||||
"dev-master": "1.27-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
|
@ -4175,7 +4468,7 @@
|
|||
"keywords": [
|
||||
"templating"
|
||||
],
|
||||
"time": "2016-10-05 18:57:41"
|
||||
"time": "2016-10-25 19:17:17"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-cache",
|
||||
|
@ -4416,64 +4709,6 @@
|
|||
],
|
||||
"time": "2016-04-18 18:32:43"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-hydrator",
|
||||
"version": "1.1.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-hydrator.git",
|
||||
"reference": "22652e1661a5a10b3f564cf7824a2206cf5a4a65"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-hydrator/zipball/22652e1661a5a10b3f564cf7824a2206cf5a4a65",
|
||||
"reference": "22652e1661a5a10b3f564cf7824a2206cf5a4a65",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-stdlib": "^2.7 || ^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"squizlabs/php_codesniffer": "^2.0@dev",
|
||||
"zendframework/zend-eventmanager": "^2.6.2 || ^3.0",
|
||||
"zendframework/zend-filter": "^2.6",
|
||||
"zendframework/zend-inputfilter": "^2.6",
|
||||
"zendframework/zend-serializer": "^2.6.1",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-eventmanager": "^2.6.2 || ^3.0, to support aggregate hydrator usage",
|
||||
"zendframework/zend-filter": "^2.6, to support naming strategy hydrator usage",
|
||||
"zendframework/zend-serializer": "^2.6.1, to use the SerializableStrategy",
|
||||
"zendframework/zend-servicemanager": "^2.7.5 || ^3.0.3, to support hydrator plugin manager usage"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-release-1.0": "1.0-dev",
|
||||
"dev-release-1.1": "1.1-dev",
|
||||
"dev-master": "2.0-dev",
|
||||
"dev-develop": "2.1-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Hydrator\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-hydrator",
|
||||
"keywords": [
|
||||
"hydrator",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-02-18 22:38:26"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-i18n",
|
||||
"version": "2.7.3",
|
||||
|
@ -4700,65 +4935,6 @@
|
|||
],
|
||||
"time": "2016-09-01 19:03:15"
|
||||
},
|
||||
{
|
||||
"name": "zendframework/zend-stdlib",
|
||||
"version": "2.7.7",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zendframework/zend-stdlib.git",
|
||||
"reference": "0e44eb46788f65e09e077eb7f44d2659143bcc1f"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zendframework/zend-stdlib/zipball/0e44eb46788f65e09e077eb7f44d2659143bcc1f",
|
||||
"reference": "0e44eb46788f65e09e077eb7f44d2659143bcc1f",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": "^5.5 || ^7.0",
|
||||
"zendframework/zend-hydrator": "~1.1"
|
||||
},
|
||||
"require-dev": {
|
||||
"athletic/athletic": "~0.1",
|
||||
"fabpot/php-cs-fixer": "1.7.*",
|
||||
"phpunit/phpunit": "~4.0",
|
||||
"zendframework/zend-config": "~2.5",
|
||||
"zendframework/zend-eventmanager": "~2.5",
|
||||
"zendframework/zend-filter": "~2.5",
|
||||
"zendframework/zend-inputfilter": "~2.5",
|
||||
"zendframework/zend-serializer": "~2.5",
|
||||
"zendframework/zend-servicemanager": "~2.5"
|
||||
},
|
||||
"suggest": {
|
||||
"zendframework/zend-eventmanager": "To support aggregate hydrator usage",
|
||||
"zendframework/zend-filter": "To support naming strategy hydrator usage",
|
||||
"zendframework/zend-serializer": "Zend\\Serializer component",
|
||||
"zendframework/zend-servicemanager": "To support hydrator plugin manager usage"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-release-2.7": "2.7-dev",
|
||||
"dev-master": "3.0-dev",
|
||||
"dev-develop": "3.1-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Zend\\Stdlib\\": "src/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"BSD-3-Clause"
|
||||
],
|
||||
"homepage": "https://github.com/zendframework/zend-stdlib",
|
||||
"keywords": [
|
||||
"stdlib",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2016-04-12 21:17:31"
|
||||
},
|
||||
{
|
||||
"name": "zetacomponents/base",
|
||||
"version": "1.9",
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once '../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
spl_autoload_register(
|
||||
function ($class) {
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
|
@ -22,7 +22,7 @@
|
|||
*
|
||||
* @link https://github.com/windowsazure/azure-sdk-for-php
|
||||
*/
|
||||
require_once __DIR__.'/../vendor/autoload.php';
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
|
||||
use WindowsAzure\Common\ServicesBuilder;
|
||||
use WindowsAzure\Common\Internal\MediaServicesSettings;
|
||||
|
|
12
phpcs.xml
12
phpcs.xml
|
@ -8,10 +8,14 @@
|
|||
<rule ref="Generic.CodeAnalysis.UnconditionalIfStatement"/>
|
||||
<rule ref="Generic.CodeAnalysis.UnnecessaryFinalModifier"/>
|
||||
|
||||
<rule ref="Generic.Files.LineLength"/>
|
||||
<rule ref="Generic.Files.LineLength">
|
||||
<properties>
|
||||
<property name="lineLimit" value="120"/>
|
||||
<property name="absoluteLineLimit" value="0"/>
|
||||
</properties>
|
||||
</rule>
|
||||
|
||||
<rule ref="Generic.Formatting.DisallowMultipleStatements"/>
|
||||
<rule ref="Generic.Formatting.MultipleStatementAlignment"/>
|
||||
|
||||
<rule ref="Generic.Metrics.CyclomaticComplexity"/>
|
||||
<rule ref="Generic.Metrics.NestingLevel"/>
|
||||
|
@ -23,7 +27,5 @@
|
|||
<rule ref="Generic.PHP.NoSilencedErrors"/>
|
||||
|
||||
<rule ref="Generic.WhiteSpace.DisallowTabIndent"/>
|
||||
<!--
|
||||
<rule ref="PEAR"/>
|
||||
-->
|
||||
|
||||
</ruleset>
|
||||
|
|
|
@ -29,6 +29,8 @@ use function GuzzleHttp\Psr7\parse_response;
|
|||
use WindowsAzure\Common\Internal\Validate;
|
||||
use WindowsAzure\Common\ServiceException;
|
||||
use GuzzleHttp\Psr7\Response;
|
||||
use Zend\Mime\Message;
|
||||
use Zend\Mime\Part;
|
||||
|
||||
/**
|
||||
* Batch response parser.
|
||||
|
@ -52,21 +54,39 @@ class BatchResponse
|
|||
*/
|
||||
private $_responses = [];
|
||||
|
||||
/**
|
||||
* @param string $contentType
|
||||
* @return string
|
||||
*/
|
||||
private static function getBoundary($contentType) {
|
||||
$match = '';
|
||||
preg_match('/boundary=(.*)/', $contentType, $match);
|
||||
return str_replace('"', '', $match[1]);
|
||||
}
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param Response $response HTTP response
|
||||
* @param BatchRequest $request Source batch request object
|
||||
* @param Response $response HTTP response
|
||||
* @param BatchRequest|null $request Source batch request object
|
||||
*/
|
||||
public function __construct(Response $response , BatchRequest $request = null)
|
||||
public function __construct(Response $response, BatchRequest $request = null)
|
||||
{
|
||||
$content = (string)$response->getBody();
|
||||
$contentType = HttpClient::getResponseHeaders($response)['content-type'];
|
||||
$boundary = self::getBoundary($contentType);
|
||||
$mimeBody = Message::createFromMessage($content, $boundary);
|
||||
|
||||
$params['include_bodies'] = true;
|
||||
$params['input'] = $content;
|
||||
$mimeDecoder = new \Mail_mimeDecode($content);
|
||||
$structure = $mimeDecoder->decode($params);
|
||||
$parts = $structure->parts;
|
||||
/** @var Part[] $allParts */
|
||||
$allParts = [];
|
||||
$mimeParts = $mimeBody->getParts();
|
||||
foreach ($mimeParts as $mimePart) {
|
||||
$partBoundary = self::getBoundary($mimePart->getType());
|
||||
$partMessage = Message::createFromMessage($mimePart->getContent(), $partBoundary);
|
||||
$allParts = array_merge($allParts, $partMessage->getParts());
|
||||
}
|
||||
|
||||
/** @var HttpCallContext[]|null $requestContexts */
|
||||
$requestContexts = null;
|
||||
|
||||
if ($request != null) {
|
||||
|
@ -75,14 +95,14 @@ class BatchResponse
|
|||
'WindowsAzure\Common\Internal\Http\BatchRequest',
|
||||
'request'
|
||||
);
|
||||
// array of HttpCallContext
|
||||
$requestContexts = $request->getContexts();
|
||||
}
|
||||
|
||||
$i = 0;
|
||||
foreach ($parts as $part) {
|
||||
if (!empty($part->body)) {
|
||||
$response = parse_response($part->body);
|
||||
foreach ($allParts as $part) {
|
||||
$body = $part->getContent();
|
||||
if (!empty($body)) {
|
||||
$response = parse_response($body);
|
||||
|
||||
$this->_responses[] = $response;
|
||||
|
||||
|
|
|
@ -397,8 +397,6 @@ class HttpClient implements IHttpClient
|
|||
* @param string $message The detailed message (if any)
|
||||
* @param array $expected The expected status codes
|
||||
*
|
||||
* @static
|
||||
*
|
||||
* @throws ServiceException
|
||||
*/
|
||||
public static function throwIfError($actual, $reason, $message, array $expected)
|
||||
|
@ -411,12 +409,13 @@ class HttpClient implements IHttpClient
|
|||
/**
|
||||
* @param ResponseInterface $response
|
||||
*
|
||||
* @return array an array of headers
|
||||
* @return string[]
|
||||
*/
|
||||
public static function getResponseHeaders(ResponseInterface $response)
|
||||
{
|
||||
$responseHeaderArray = $response->getHeaders();
|
||||
|
||||
/** @var string[] $responseHeaders */
|
||||
$responseHeaders = [];
|
||||
|
||||
foreach ($responseHeaderArray as $key => $value) {
|
||||
|
|
|
@ -572,10 +572,10 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Get content key authorization policy.
|
||||
*
|
||||
* @param \WindowsAzure\MediaServices\Models\ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy ContentKeyAuthorizationPolicies data or
|
||||
* content key authorization policy Id
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy ContentKeyAuthorizationPolicies data
|
||||
* or content key authorization policy Id
|
||||
*
|
||||
* @return \WindowsAzure\MediaServices\Models\ContentKeyAuthorizationPolicy
|
||||
* @return ContentKeyAuthorizationPolicy
|
||||
*/
|
||||
public function getContentKeyAuthorizationPolicy($contentKeyAuthorizationPolicy);
|
||||
|
||||
|
@ -589,15 +589,16 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Update content key authorization policy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy New content key authorization policy data with valid id
|
||||
* @param ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy New content key authorization policy data
|
||||
* with valid id
|
||||
*/
|
||||
public function updateContentKeyAuthorizationPolicy(ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy);
|
||||
|
||||
/**
|
||||
* Delete content key authorization policy.
|
||||
*
|
||||
* @param \WindowsAzure\MediaServices\Models\ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy Models\ContentKeyAuthorizationPolicy data or
|
||||
* content key authorization policy Id
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy ContentKeyAuthorizationPolicy data or
|
||||
* content key authorization policy Id
|
||||
*/
|
||||
public function deleteContentKeyAuthorizationPolicy($contentKeyAuthorizationPolicy);
|
||||
|
||||
|
@ -615,8 +616,9 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Get content key authorization option by id.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions ContentKeyAuthorizationPolicies data or
|
||||
* content key authorization policy Id
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions ContentKeyAuthorizationPolicies data
|
||||
* or content key authorization policy
|
||||
* Id
|
||||
*
|
||||
* @return ContentKeyAuthorizationPolicyOption
|
||||
*/
|
||||
|
@ -632,10 +634,12 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Update content key authorization options.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions New content key authorization options data with
|
||||
* valid id
|
||||
* @param ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions New content key authorization options
|
||||
* data with valid id
|
||||
*/
|
||||
public function updateContentKeyAuthorizationPolicyOption(ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions);
|
||||
public function updateContentKeyAuthorizationPolicyOption(
|
||||
ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions
|
||||
);
|
||||
|
||||
/**
|
||||
* Delete content key authorization policy.
|
||||
|
@ -658,16 +662,24 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Link ContentKeyAuthorizationPolicyOption to ContentKeyAuthorizationPolicy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to link a ContentKeyAuthorizationPolicy or ContentKeyAuthorizationPolicyOption id
|
||||
* @param string $policy ContentKeyAuthorizationPolicy to link or ContentKeyAuthorizationPolicy id
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to link a
|
||||
* ContentKeyAuthorizationPolicy or
|
||||
* ContentKeyAuthorizationPolicyOption id
|
||||
*
|
||||
* @param string $policy ContentKeyAuthorizationPolicy to link or
|
||||
* ContentKeyAuthorizationPolicy id
|
||||
*/
|
||||
public function linkOptionToContentKeyAuthorizationPolicy($options, $policy);
|
||||
|
||||
/**
|
||||
* Remove ContentKeyAuthorizationPolicyOption from ContentKeyAuthorizationPolicy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to remove from ContentKeyAuthorizationPolicy or ContentKeyAuthorizationPolicyOption id
|
||||
* @param ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to remove or ContentKeyAuthorizationPolicy id
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to remove from
|
||||
* ContentKeyAuthorizationPolicy or
|
||||
* ContentKeyAuthorizationPolicyOption id
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to remove or
|
||||
* ContentKeyAuthorizationPolicy id
|
||||
*/
|
||||
public function removeOptionsFromContentKeyAuthorizationPolicy($options, $policy);
|
||||
|
||||
|
@ -706,16 +718,14 @@ interface IMediaServices extends FilterableService
|
|||
/**
|
||||
* Delete asset delivery policy.
|
||||
*
|
||||
* @param \WindowsAzure\MediaServices\Models\AssetDeliveryPolicy|string $assetDeliveryPolicy Models\AssetDeliveryPolicy data or
|
||||
* asset delivery policy Id
|
||||
* @param AssetDeliveryPolicy|string $assetDeliveryPolicy AssetDeliveryPolicy data or asset delivery policy Id
|
||||
*/
|
||||
public function deleteAssetDeliveryPolicy($assetDeliveryPolicy);
|
||||
|
||||
/**
|
||||
* Get AssetDeliveryPolicy list linked to an Asset.
|
||||
*
|
||||
* @param \WindowsAzure\MediaServices\Models\Asset|string $asset Asset data or
|
||||
* Asset Id to retrieve the linked delivery policies
|
||||
* @param Asset|string $asset Asset data or Asset Id to retrieve the linked delivery policies
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
|
|
|
@ -378,7 +378,8 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
* Get entity list.
|
||||
*
|
||||
* @param string $path REST path
|
||||
* @param array $queryParams URL query parameters. An example is $queryParams = ['$top' => 20, '$skip' => 40] to support paging
|
||||
* @param array $queryParams URL query parameters. An example is $queryParams = ['$top' => 20, '$skip' => 40] to
|
||||
* support paging
|
||||
*
|
||||
* @return Entity[]
|
||||
*/
|
||||
|
@ -2173,11 +2174,9 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Rebind ContentKey.
|
||||
*
|
||||
* @param Models\ContentKey|string $contentKey An ContentKey data or
|
||||
* ContentKey Id
|
||||
* @param string $x509Certificate X.509 certificate (with only
|
||||
* the public key) that was used to encrypt the clear storage encryption/common
|
||||
* protection content keys
|
||||
* @param ContentKey|string $contentKey An ContentKey data or ContentKey Id
|
||||
* @param string $x509Certificate X.509 certificate (with only the public key) that was used to encrypt
|
||||
* the clear storage encryption/common protection content keys
|
||||
*
|
||||
* @return string Content key
|
||||
*/
|
||||
|
@ -2315,8 +2314,8 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Get content key authorization policy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy ContentKeyAuthorizationPolicies data or
|
||||
* content key authorization policy Id
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationPolicy ContentKeyAuthorizationPolicies data
|
||||
* or content key authorization policy Id
|
||||
*
|
||||
* @return ContentKeyAuthorizationPolicy
|
||||
*/
|
||||
|
@ -2327,7 +2326,9 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
'WindowsAzure\MediaServices\Models\ContentKeyAuthorizationPolicy'
|
||||
);
|
||||
|
||||
return ContentKeyAuthorizationPolicy::createFromOptions($this->_getEntity("ContentKeyAuthorizationPolicies('{$contentKeyAuthorizationPolicyId}')"));
|
||||
return ContentKeyAuthorizationPolicy::createFromOptions(
|
||||
$this->_getEntity("ContentKeyAuthorizationPolicies('{$contentKeyAuthorizationPolicyId}')")
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2350,12 +2351,15 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Update content key authorization policy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy New content key authorization policy data with
|
||||
* valid id
|
||||
* @param ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy New content key authorization policy data
|
||||
* with valid id
|
||||
*/
|
||||
public function updateContentKeyAuthorizationPolicy(ContentKeyAuthorizationPolicy $contentKeyAuthorizationPolicy)
|
||||
{
|
||||
$this->_updateEntity($contentKeyAuthorizationPolicy, "ContentKeyAuthorizationPolicies('{$contentKeyAuthorizationPolicy->getId()}')");
|
||||
$this->_updateEntity(
|
||||
$contentKeyAuthorizationPolicy,
|
||||
"ContentKeyAuthorizationPolicies('{$contentKeyAuthorizationPolicy->getId()}')"
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2384,14 +2388,17 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
public function createContentKeyAuthorizationPolicyOption(
|
||||
ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions)
|
||||
{
|
||||
return ContentKeyAuthorizationPolicyOption::createFromOptions($this->_createEntity($contentKeyAuthorizationOptions, 'ContentKeyAuthorizationPolicyOptions'));
|
||||
return ContentKeyAuthorizationPolicyOption::createFromOptions(
|
||||
$this->_createEntity($contentKeyAuthorizationOptions, 'ContentKeyAuthorizationPolicyOptions')
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Get content key authorization option by id.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions ContentKeyAuthorizationPolicies data or
|
||||
* content key authorization policy Id
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions ContentKeyAuthorizationPolicies data
|
||||
* or content key authorization policy
|
||||
* Id
|
||||
*
|
||||
* @return ContentKeyAuthorizationPolicyOption
|
||||
*/
|
||||
|
@ -2402,7 +2409,9 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
'WindowsAzure\MediaServices\Models\ContentKeyAuthorizationPolicyOption'
|
||||
);
|
||||
|
||||
return ContentKeyAuthorizationPolicyOption::createFromOptions($this->_getEntity("ContentKeyAuthorizationPolicyOptions('{$contentKeyAuthorizationOptionsId}')"));
|
||||
return ContentKeyAuthorizationPolicyOption::createFromOptions(
|
||||
$this->_getEntity("ContentKeyAuthorizationPolicyOptions('{$contentKeyAuthorizationOptionsId}')")
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -2425,8 +2434,8 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Update content key authorization options.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions New content key authorization options data with
|
||||
* valid id
|
||||
* @param ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions New content key authorization options
|
||||
* data with valid id
|
||||
*/
|
||||
public function updateContentKeyAuthorizationPolicyOption(
|
||||
ContentKeyAuthorizationPolicyOption $contentKeyAuthorizationOptions)
|
||||
|
@ -2440,7 +2449,7 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Delete content key authorization policy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions Models\ContentKeyAuthorizationPolicy data or
|
||||
* @param ContentKeyAuthorizationPolicy|string $contentKeyAuthorizationOptions ContentKeyAuthorizationPolicy data or
|
||||
* content key authorization policy Id
|
||||
*/
|
||||
public function deleteContentKeyAuthorizationPolicyOption($contentKeyAuthorizationOptions)
|
||||
|
@ -2481,8 +2490,11 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Link ContentKeyAuthorizationPolicyOption to ContentKeyAuthorizationPolicy.
|
||||
*
|
||||
* @param Models\ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to link a ContentKeyAuthorizationPolicy or ContentKeyAuthorizationPolicyOption id
|
||||
* @param Models\ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to link or ContentKeyAuthorizationPolicy id
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to link a
|
||||
* ContentKeyAuthorizationPolicy or
|
||||
* ContentKeyAuthorizationPolicyOption id
|
||||
* @param ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to link or
|
||||
* ContentKeyAuthorizationPolicy id
|
||||
*/
|
||||
public function linkOptionToContentKeyAuthorizationPolicy($options, $policy)
|
||||
{
|
||||
|
@ -2532,8 +2544,11 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
/**
|
||||
* Remove ContentKeyAuthorizationPolicyOption from ContentKeyAuthorizationPolicy.
|
||||
*
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to remove from ContentKeyAuthorizationPolicy or ContentKeyAuthorizationPolicyOption id
|
||||
* @param ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to remove or ContentKeyAuthorizationPolicy id
|
||||
* @param ContentKeyAuthorizationPolicyOption|string $options ContentKeyAuthorizationPolicyOption to remove from
|
||||
* ContentKeyAuthorizationPolicy or
|
||||
* ContentKeyAuthorizationPolicyOption id
|
||||
* @param ContentKeyAuthorizationPolicy|string $policy ContentKeyAuthorizationPolicy to remove or
|
||||
* ContentKeyAuthorizationPolicy id
|
||||
*/
|
||||
public function removeOptionsFromContentKeyAuthorizationPolicy($options, $policy)
|
||||
{
|
||||
|
@ -3017,7 +3032,8 @@ class MediaServicesRestProxy extends ServiceRestProxy implements IMediaServices
|
|||
* @param Channel|string $channel Channel data or channel Id
|
||||
* @param string $duration The duration, in seconds, of the commercial break
|
||||
* @param string $cueId Unique ID for the commercial break
|
||||
* @param string $showSlate Indicates to the live encoder within the Channel that it needs to switch to the default slate image during the commercial break
|
||||
* @param string $showSlate Indicates to the live encoder within the Channel that it needs to switch to the
|
||||
* default slate image during the commercial break
|
||||
*
|
||||
* @return Operation
|
||||
*/
|
||||
|
|
|
@ -209,7 +209,9 @@ class Channel
|
|||
|
||||
if (!empty($options['CrossSiteAccessPolicies'])) {
|
||||
Validate::isArray($options['CrossSiteAccessPolicies'], 'options[CrossSiteAccessPolicies]');
|
||||
$this->_crossSiteAccessPolicies = CrossSiteAccessPolicies::createFromOptions($options['CrossSiteAccessPolicies']);
|
||||
$this->_crossSiteAccessPolicies = CrossSiteAccessPolicies::createFromOptions(
|
||||
$options['CrossSiteAccessPolicies']
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($options['EncodingType'])) {
|
||||
|
|
|
@ -58,7 +58,8 @@ class AgcAndColorStripeRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Automatic Gain Control (AGC) and Color Stripe control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Automatic Gain Control (AGC) and Color Stripe control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @return int ConfigurationData
|
||||
*/
|
||||
|
@ -68,7 +69,8 @@ class AgcAndColorStripeRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Automatic Gain Control (AGC) and Color Stripe control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Automatic Gain Control (AGC) and Color Stripe control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @param int $value ConfigurationData
|
||||
*/
|
||||
|
|
|
@ -58,9 +58,11 @@ class ContentKeySpecs
|
|||
* Defines client robustness requirements for playback.
|
||||
* 1 - Software-based whitebox crypto is required.
|
||||
* 2 - Software crypto and an obfuscated decoder is required.
|
||||
* 3 - The key material and crypto operations must be performed within a hardware backed trusted execution environment.
|
||||
* 3 - The key material and crypto operations must be performed within a hardware backed trusted execution
|
||||
* environment.
|
||||
* 4 - The crypto and decoding of content must be performed within a hardware backed trusted execution environment.
|
||||
* 5 - The crypto, decoding and all handling of the media (compressed and uncompressed) must be handled within a hardware backed trusted execution environment.
|
||||
* 5 - The crypto, decoding and all handling of the media (compressed and uncompressed) must be handled within a
|
||||
* hardware backed trusted execution environment.
|
||||
*
|
||||
* @var int
|
||||
*/
|
||||
|
|
|
@ -44,23 +44,31 @@ class ErrorMessages
|
|||
|
||||
const UNCOMPRESSED_DIGITAL_VIDEO_OPL_VALUE_ERROR = 'The value can only be set to null, 100, 250, 270, or 300.';
|
||||
|
||||
const BEGIN_DATE_AND_RELATIVE_BEGIN_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR = 'Set BeginDate or RelativeBeginDate but not both';
|
||||
const BEGIN_DATE_AND_RELATIVE_BEGIN_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR =
|
||||
'Set BeginDate or RelativeBeginDate but not both';
|
||||
|
||||
const EXPIRATION_DATE_AND_RELATIVE_EXPIRATION_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR = 'Set ExpirationDate or RelativeExpirationDate but not both';
|
||||
const EXPIRATION_DATE_AND_RELATIVE_EXPIRATION_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR =
|
||||
'Set ExpirationDate or RelativeExpirationDate but not both';
|
||||
|
||||
const PLAY_READY_PLAY_RIGHT_REQUIRED = 'Each PlayReadyLicenseTemplate in the PlayReadyLicenseResponseTemplate must have a PlayReadyPlayRight';
|
||||
const PLAY_READY_PLAY_RIGHT_REQUIRED =
|
||||
'Each PlayReadyLicenseTemplate in the PlayReadyLicenseResponseTemplate must have a PlayReadyPlayRight';
|
||||
|
||||
const PLAY_READY_CONTENT_KEY_REQUIRED = 'Each PlayReadyLicenseTemplate in the PlayReadyLicenseResponseTemplate must have either a ContentEncryptionKeyFromHeader or a ContentEncryptionKeyFromKeyIdentifier';
|
||||
const PLAY_READY_CONTENT_KEY_REQUIRED =
|
||||
'Each PlayReadyLicenseTemplate in the PlayReadyLicenseResponseTemplate must have either a ContentEncryptionKeyFromHeader or a ContentEncryptionKeyFromKeyIdentifier';
|
||||
|
||||
const INVALID_TWO_BIT_CONFIGURATION_DATA = 'ConfigurationData must be 0, 1, 2, or 3';
|
||||
|
||||
const GRACE_PERIOD_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE = 'GracePeriod cannot be set on Non Persistent licenses.';
|
||||
const GRACE_PERIOD_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE =
|
||||
'GracePeriod cannot be set on Non Persistent licenses.';
|
||||
|
||||
const FIRST_PLAY_EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE = 'FirstPlayExpiration cannot be set on the PlayRight of a Non Persistent license.';
|
||||
const FIRST_PLAY_EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE =
|
||||
'FirstPlayExpiration cannot be set on the PlayRight of a Non Persistent license.';
|
||||
|
||||
const EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE = 'ExpirationDate cannot be set on Non Persistent licenses.';
|
||||
const EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE =
|
||||
'ExpirationDate cannot be set on Non Persistent licenses.';
|
||||
|
||||
const DIGITAL_VIDEO_ONLY_MUTUALLY_EXCLUSIVE_WITH_PASSING_TO_UNKNOWN_OUTPUT_ERROR = 'PlayReady does not allow passing to unknown outputs if the DigitalVideoOnlyContentRestriction is enabled.';
|
||||
const DIGITAL_VIDEO_ONLY_MUTUALLY_EXCLUSIVE_WITH_PASSING_TO_UNKNOWN_OUTPUT_ERROR =
|
||||
'PlayReady does not allow passing to unknown outputs if the DigitalVideoOnlyContentRestriction is enabled.';
|
||||
|
||||
const COMPRESSED_DIGITAL_VIDEO_OPL_VALUE_ERROR = 'The value can only be set to null, 400, or 500.';
|
||||
|
||||
|
@ -68,7 +76,8 @@ class ErrorMessages
|
|||
|
||||
const BEGIN_DATE_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE = 'BeginDate cannot be set on Non Persistent licenses.';
|
||||
|
||||
const AT_LEAST_ONE_LICENSE_TEMPLATE_REQUIRED = 'A PlayReadyLicenseResponseTemplate must have at least one PlayReadyLicenseTemplate';
|
||||
const AT_LEAST_ONE_LICENSE_TEMPLATE_REQUIRED =
|
||||
'A PlayReadyLicenseResponseTemplate must have at least one PlayReadyLicenseTemplate';
|
||||
|
||||
const ANALOG_VIDEO_OPL_VALUE_ERROR = 'The value can only be set to null, 100, 150, or 200.';
|
||||
}
|
||||
|
|
|
@ -67,10 +67,10 @@ class ExplicitAnalogTelevisionRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Controls whether the Explicit Analog Television Output Restriction is enforced on a Best Effort basis or not. If true,
|
||||
* then the PlayReady client must make its best effort to enforce the restriction but can allow video content to flow to
|
||||
* Analog Television Outputs if it cannot support the restriction. If false, the PlayReady client must enforce the restriction.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Controls whether the Explicit Analog Television Output Restriction is enforced on a Best Effort basis or not. If
|
||||
* true, then the PlayReady client must make its best effort to enforce the restriction but can allow video content
|
||||
* to flow to Analog Television Outputs if it cannot support the restriction. If false, the PlayReady client must
|
||||
* enforce the restriction. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return bool BestEffort
|
||||
*/
|
||||
|
@ -80,10 +80,10 @@ class ExplicitAnalogTelevisionRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Controls whether the Explicit Analog Television Output Restriction is enforced on a Best Effort basis or not. If true,
|
||||
* then the PlayReady client must make its best effort to enforce the restriction but can allow video content to flow to
|
||||
* Analog Television Outputs if it cannot support the restriction. If false, the PlayReady client must enforce the restriction.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Controls whether the Explicit Analog Television Output Restriction is enforced on a Best Effort basis or not. If
|
||||
* true, then the PlayReady client must make its best effort to enforce the restriction but can allow video content
|
||||
* to flow to Analog Television Outputs if it cannot support the restriction. If false, the PlayReady client must
|
||||
* enforce the restriction. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param bool $value BestEffort
|
||||
*/
|
||||
|
@ -93,7 +93,8 @@ class ExplicitAnalogTelevisionRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Explicit Analog Television Output Restriction control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Explicit Analog Television Output Restriction control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @return int ConfigurationData
|
||||
*/
|
||||
|
@ -103,7 +104,8 @@ class ExplicitAnalogTelevisionRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Explicit Analog Television Output Restriction control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Explicit Analog Television Output Restriction control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @param int $value ConfigurationData
|
||||
*/
|
||||
|
|
|
@ -59,7 +59,9 @@ class MediaServicesLicenseTemplateSerializer
|
|||
throw new \RuntimeException("This is not a PlayReadyLicenseResponseTemplate, it is a '{$xml->getName()}'");
|
||||
}
|
||||
if (!isset($xml->LicenseTemplates)) {
|
||||
throw new \RuntimeException("The PlayReadyLicenseResponseTemplate must contains an 'LicenseTemplates' element");
|
||||
throw new \RuntimeException(
|
||||
"The PlayReadyLicenseResponseTemplate must contains an 'LicenseTemplates' element"
|
||||
);
|
||||
}
|
||||
|
||||
// decoding
|
||||
|
@ -118,33 +120,42 @@ class MediaServicesLicenseTemplateSerializer
|
|||
throw new \RuntimeException(ErrorMessages::PLAY_READY_CONTENT_KEY_REQUIRED);
|
||||
}
|
||||
|
||||
$licensePlayRight = $license->getPlayRight();
|
||||
// A PlayReady license must have at least one Right in it. Today we only
|
||||
// support the PlayRight so it is required. In the future we might support
|
||||
// other types of rights (CopyRight, perhaps an extensible Right, whatever)
|
||||
// so we enforce this in code and not in the DataContract itself.
|
||||
if ($license->getPlayRight() == null) {
|
||||
if ($licensePlayRight == null) {
|
||||
throw new \RuntimeException(ErrorMessages::PLAY_READY_PLAY_RIGHT_REQUIRED);
|
||||
}
|
||||
|
||||
// Per the PlayReady Compliance rules (section 3.8 - Output Control for Unknown Outputs), passing content to
|
||||
// unknown output is prohibited if the DigitalVideoOnlyContentRestriction is enabled.
|
||||
if ($license->getPlayRight()->getDigitalVideoOnlyContentRestriction()) {
|
||||
if (($license->getPlayRight()->getAllowPassingVideoContentToUnknownOutput() == UnknownOutputPassingOption::ALLOWED) ||
|
||||
($license->getPlayRight()->getAllowPassingVideoContentToUnknownOutput() == UnknownOutputPassingOption::ALLOWED_WITH_VIDEO_CONSTRICTION)) {
|
||||
throw new \RuntimeException(ErrorMessages::DIGITAL_VIDEO_ONLY_MUTUALLY_EXCLUSIVE_WITH_PASSING_TO_UNKNOWN_OUTPUT_ERROR);
|
||||
// Per the PlayReady Compliance rules (section 3.8 - Output Control for Unknown Outputs), passing content
|
||||
// to unknown output is prohibited if the DigitalVideoOnlyContentRestriction is enabled.
|
||||
if ($licensePlayRight->getDigitalVideoOnlyContentRestriction()) {
|
||||
if (($licensePlayRight->getAllowPassingVideoContentToUnknownOutput() ==
|
||||
UnknownOutputPassingOption::ALLOWED) ||
|
||||
($licensePlayRight->getAllowPassingVideoContentToUnknownOutput() ==
|
||||
UnknownOutputPassingOption::ALLOWED_WITH_VIDEO_CONSTRICTION)) {
|
||||
throw new \RuntimeException(
|
||||
ErrorMessages::DIGITAL_VIDEO_ONLY_MUTUALLY_EXCLUSIVE_WITH_PASSING_TO_UNKNOWN_OUTPUT_ERROR
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
// License template should not have both BeginDate and RelativeBeginDate set.
|
||||
// Only one of these two values should be set.
|
||||
if (($license->getBeginDate() != null) && ($license->getRelativeBeginDate() != null)) {
|
||||
throw new \RuntimeException(ErrorMessages::BEGIN_DATE_AND_RELATIVE_BEGIN_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR);
|
||||
throw new \RuntimeException(
|
||||
ErrorMessages::BEGIN_DATE_AND_RELATIVE_BEGIN_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR
|
||||
);
|
||||
}
|
||||
|
||||
// License template should not have both ExpirationDate and RelativeExpirationDate set.
|
||||
// Only one of these two values should be set.
|
||||
if (($license->getExpirationDate() != null) && ($license->getRelativeExpirationDate() != null)) {
|
||||
throw new \RuntimeException(ErrorMessages::EXPIRATION_DATE_AND_RELATIVE_EXPIRATION_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR);
|
||||
throw new \RuntimeException(
|
||||
ErrorMessages::EXPIRATION_DATE_AND_RELATIVE_EXPIRATION_DATE_CANNOTBE_SET_SIMULTANEOUSLY_ERROR
|
||||
);
|
||||
}
|
||||
|
||||
if ($license->getLicenseType() == PlayReadyLicenseType::NON_PERSISTENT) {
|
||||
|
@ -153,7 +164,9 @@ class MediaServicesLicenseTemplateSerializer
|
|||
// to the error will say "LicenseGenerationFailure: FirstPlayExpiration can not be set on Non
|
||||
// Persistent license PlayRight."
|
||||
if ($license->getPlayRight()->getFirstPlayExpiration() != null) {
|
||||
throw new \RuntimeException(ErrorMessages::FIRST_PLAY_EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE);
|
||||
throw new \RuntimeException(
|
||||
ErrorMessages::FIRST_PLAY_EXPIRATION_CANNOT_BE_SET_ON_NON_PERSISTENT_LICENSE
|
||||
);
|
||||
}
|
||||
|
||||
// The PlayReady Rights Manager SDK will return an error if you try to specify a license
|
||||
|
@ -233,7 +246,9 @@ class MediaServicesLicenseTemplateSerializer
|
|||
}
|
||||
|
||||
if ($template->getRelativeExpirationDate() != null) {
|
||||
$writer->writeElement('RelativeExpirationDate', self::getSpecString($template->getRelativeExpirationDate()));
|
||||
$writer->writeElement(
|
||||
'RelativeExpirationDate', self::getSpecString($template->getRelativeExpirationDate())
|
||||
);
|
||||
}
|
||||
|
||||
$writer->endElement();
|
||||
|
@ -249,12 +264,16 @@ class MediaServicesLicenseTemplateSerializer
|
|||
|
||||
if ($playright->getAgcAndColorStripeRestriction() != null) {
|
||||
$writer->startElement('AgcAndColorStripeRestriction');
|
||||
$writer->writeElement('ConfigurationData', $playright->getAgcAndColorStripeRestriction()->getConfigurationData());
|
||||
$writer->writeElement(
|
||||
'ConfigurationData', $playright->getAgcAndColorStripeRestriction()->getConfigurationData()
|
||||
);
|
||||
$writer->endElement();
|
||||
}
|
||||
|
||||
if ($playright->getAllowPassingVideoContentToUnknownOutput()) {
|
||||
$writer->writeElement('AllowPassingVideoContentToUnknownOutput', $playright->getAllowPassingVideoContentToUnknownOutput());
|
||||
$writer->writeElement(
|
||||
'AllowPassingVideoContentToUnknownOutput', $playright->getAllowPassingVideoContentToUnknownOutput()
|
||||
);
|
||||
}
|
||||
|
||||
if ($playright->getAnalogVideoOpl() > 0) {
|
||||
|
@ -422,20 +441,31 @@ class MediaServicesLicenseTemplateSerializer
|
|||
}
|
||||
|
||||
if (isset($xmlElement->ScmsRestriction) && isset($xmlElement->ScmsRestriction->ConfigurationData)) {
|
||||
$result->setScmsRestriction(new ScmsRestriction(intval((string) $xmlElement->ScmsRestriction->ConfigurationData)));
|
||||
$result->setScmsRestriction(
|
||||
new ScmsRestriction(intval((string) $xmlElement->ScmsRestriction->ConfigurationData))
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->AgcAndColorStripeRestriction) && isset($xmlElement->AgcAndColorStripeRestriction->ConfigurationData)) {
|
||||
$result->setAgcAndColorStripeRestriction(new AgcAndColorStripeRestriction(intval((string) $xmlElement->AgcAndColorStripeRestriction->ConfigurationData)));
|
||||
if (isset($xmlElement->AgcAndColorStripeRestriction) &&
|
||||
isset($xmlElement->AgcAndColorStripeRestriction->ConfigurationData)) {
|
||||
$result->setAgcAndColorStripeRestriction(
|
||||
new AgcAndColorStripeRestriction(
|
||||
intval((string) $xmlElement->AgcAndColorStripeRestriction->ConfigurationData)
|
||||
)
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->ExplicitAnalogTelevisionOutputRestriction) && isset($xmlElement->ExplicitAnalogTelevisionOutputRestriction->ConfigurationData)) {
|
||||
if (isset($xmlElement->ExplicitAnalogTelevisionOutputRestriction) &&
|
||||
isset($xmlElement->ExplicitAnalogTelevisionOutputRestriction->ConfigurationData)) {
|
||||
$bestEffort = false;
|
||||
if (isset($xmlElement->ExplicitAnalogTelevisionOutputRestriction->BestEffort)) {
|
||||
$bestEffort = $xmlElement->ExplicitAnalogTelevisionOutputRestriction->BestEffort == 'true';
|
||||
}
|
||||
$configurationData = intval((string) $xmlElement->ExplicitAnalogTelevisionOutputRestriction->ConfigurationData);
|
||||
$result->setExplicitAnalogTelevisionOutputRestriction(new ExplicitAnalogTelevisionRestriction($configurationData, $bestEffort));
|
||||
$configurationData =
|
||||
intval((string) $xmlElement->ExplicitAnalogTelevisionOutputRestriction->ConfigurationData);
|
||||
$result->setExplicitAnalogTelevisionOutputRestriction(
|
||||
new ExplicitAnalogTelevisionRestriction($configurationData, $bestEffort)
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->DigitalVideoOnlyContentRestriction)) {
|
||||
|
@ -443,15 +473,21 @@ class MediaServicesLicenseTemplateSerializer
|
|||
}
|
||||
|
||||
if (isset($xmlElement->ImageConstraintForAnalogComponentVideoRestriction)) {
|
||||
$result->setImageConstraintForAnalogComponentVideoRestriction($xmlElement->ImageConstraintForAnalogComponentVideoRestriction == 'true');
|
||||
$result->setImageConstraintForAnalogComponentVideoRestriction(
|
||||
$xmlElement->ImageConstraintForAnalogComponentVideoRestriction == 'true'
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->ImageConstraintForAnalogComputerMonitorRestriction)) {
|
||||
$result->setImageConstraintForAnalogComputerMonitorRestriction($xmlElement->ImageConstraintForAnalogComputerMonitorRestriction == 'true');
|
||||
$result->setImageConstraintForAnalogComputerMonitorRestriction(
|
||||
$xmlElement->ImageConstraintForAnalogComputerMonitorRestriction == 'true'
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->AllowPassingVideoContentToUnknownOutput)) {
|
||||
$result->setAllowPassingVideoContentToUnknownOutput((string) $xmlElement->AllowPassingVideoContentToUnknownOutput);
|
||||
$result->setAllowPassingVideoContentToUnknownOutput(
|
||||
(string) $xmlElement->AllowPassingVideoContentToUnknownOutput
|
||||
);
|
||||
}
|
||||
|
||||
if (isset($xmlElement->UncompressedDigitalVideoOpl)) {
|
||||
|
|
|
@ -113,8 +113,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Controls whether test devices can use the license or not. If true, the MinimumSecurityLevel property of the license
|
||||
* is set to 150. If false (the default), the MinimumSecurityLevel property of the license is set to 2000.
|
||||
* Controls whether test devices can use the license or not. If true, the MinimumSecurityLevel property of the
|
||||
* license is set to 150. If false (the default), the MinimumSecurityLevel property of the license is set to 2000.
|
||||
*
|
||||
* @return bool AllowTestDevices
|
||||
*/
|
||||
|
@ -124,8 +124,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Controls whether test devices can use the license or not. If true, the MinimumSecurityLevel property of the license
|
||||
* is set to 150. If false (the default), the MinimumSecurityLevel property of the license is set to 2000.
|
||||
* Controls whether test devices can use the license or not. If true, the MinimumSecurityLevel property of the
|
||||
* license is set to 150. If false (the default), the MinimumSecurityLevel property of the license is set to 2000.
|
||||
*
|
||||
* @param bool $value AllowTestDevices
|
||||
*/
|
||||
|
@ -135,8 +135,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the starting DateTime that the license is valid. Attempts to use the license before this date and time will
|
||||
* result in an error on the client.
|
||||
* Configures the starting DateTime that the license is valid. Attempts to use the license before this date and
|
||||
* time will result in an error on the client.
|
||||
*
|
||||
* @return \DateTime BeginDate
|
||||
*/
|
||||
|
@ -146,8 +146,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the starting DateTime that the license is valid. Attempts to use the license before this date and time will
|
||||
* result in an error on the client.
|
||||
* Configures the starting DateTime that the license is valid. Attempts to use the license before this date and
|
||||
* time will result in an error on the client.
|
||||
*
|
||||
* @param \DateTime $value BeginDate
|
||||
*/
|
||||
|
@ -157,8 +157,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the DateTime value when the the license expires. Attempts to use the license after this date and time will
|
||||
* result in an error on the client.
|
||||
* Configures the DateTime value when the the license expires. Attempts to use the license after this date and time
|
||||
* will result in an error on the client.
|
||||
*
|
||||
* @return \DateTime ExpirationDate
|
||||
*/
|
||||
|
@ -168,8 +168,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the DateTime value when the the license expires. Attempts to use the license after this date and time will
|
||||
* result in an error on the client.
|
||||
* Configures the DateTime value when the the license expires. Attempts to use the license after this date and time
|
||||
* will result in an error on the client.
|
||||
*
|
||||
* @param \DateTime $value ExpirationDate
|
||||
*/
|
||||
|
@ -179,9 +179,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures starting DateTime value when the license is valid. Attempts to use the license before this date and time
|
||||
* will result in an error on the client. The DateTime value is calculated as DateTime.UtcNow + RelativeBeginDate when
|
||||
* the license is issued.
|
||||
* Configures starting DateTime value when the license is valid. Attempts to use the license before this date and
|
||||
* time will result in an error on the client. The DateTime value is calculated as
|
||||
* DateTime.UtcNow + RelativeBeginDate when the license is issued.
|
||||
*
|
||||
* @return \DateInterval RelativeBeginDate
|
||||
*/
|
||||
|
@ -191,9 +191,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures starting DateTime value when the license is valid. Attempts to use the license before this date and time
|
||||
* will result in an error on the client. The DateTime value is calculated as DateTime.UtcNow + RelativeBeginDate when
|
||||
* the license is issued.
|
||||
* Configures starting DateTime value when the license is valid. Attempts to use the license before this date and
|
||||
* time will result in an error on the client. The DateTime value is calculated as
|
||||
* DateTime.UtcNow + RelativeBeginDate when the license is issued.
|
||||
*
|
||||
* @param \DateInterval $value RelativeBeginDate
|
||||
*/
|
||||
|
@ -203,9 +203,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the DateTime value when the license expires. Attempts to use the license after this date and time will result
|
||||
* in an error on the client. The DateTime value is calculated as DateTime.UtcNow + RelativeExpirationDate when the license
|
||||
* is issued.
|
||||
* Configures the DateTime value when the license expires. Attempts to use the license after this date and time
|
||||
* will result in an error on the client. The DateTime value is calculated as
|
||||
* DateTime.UtcNow + RelativeExpirationDate when the license is issued.
|
||||
*
|
||||
* @return \DateInterval RelativeExpirationDate
|
||||
*/
|
||||
|
@ -215,9 +215,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the DateTime value when the license expires. Attempts to use the license after this date and time will result
|
||||
* in an error on the client. The DateTime value is calculated as DateTime.UtcNow + RelativeExpirationDate when the license
|
||||
* is issued.
|
||||
* Configures the DateTime value when the license expires. Attempts to use the license after this date and time
|
||||
* will result in an error on the client. The DateTime value is calculated as
|
||||
* DateTime.UtcNow + RelativeExpirationDate when the license is issued.
|
||||
*
|
||||
* @param \DateInterval $value RelativeExpirationDate
|
||||
*/
|
||||
|
@ -227,8 +227,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Grace Period setting of the PlayReady license. This setting affects how DateTime based restrictions are
|
||||
* evaluated on certain devices in the situation that the devices secure clock becomes unset.
|
||||
* Configures the Grace Period setting of the PlayReady license. This setting affects how DateTime based
|
||||
* restrictions are evaluated on certain devices in the situation that the devices secure clock becomes unset.
|
||||
*
|
||||
* @return \DateInterval GracePeriod
|
||||
*/
|
||||
|
@ -238,8 +238,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Grace Period setting of the PlayReady license. This setting affects how DateTime based restrictions are
|
||||
* evaluated on certain devices in the situation that the devices secure clock becomes unset.
|
||||
* Configures the Grace Period setting of the PlayReady license. This setting affects how DateTime based
|
||||
* restrictions are evaluated on certain devices in the situation that the devices secure clock becomes unset.
|
||||
*
|
||||
* @param \DateInterval $value GracePeriod
|
||||
*/
|
||||
|
@ -249,8 +249,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the PlayRight of the PlayReady license. This Right gives the client the ability to play back the content.
|
||||
* The PlayRight also allows configuring restrictions specific to playback. This Right is required.
|
||||
* Configures the PlayRight of the PlayReady license. This Right gives the client the ability to play back the
|
||||
* content. The PlayRight also allows configuring restrictions specific to playback. This Right is required.
|
||||
*
|
||||
* @return PlayReadyPlayRight PlayReadyPlayRight
|
||||
*/
|
||||
|
@ -260,8 +260,8 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the PlayRight of the PlayReady license. This Right gives the client the ability to play back the content.
|
||||
* The PlayRight also allows configuring restrictions specific to playback. This Right is required.
|
||||
* Configures the PlayRight of the PlayReady license. This Right gives the client the ability to play back the
|
||||
* content. The PlayRight also allows configuring restrictions specific to playback. This Right is required.
|
||||
*
|
||||
* @param PlayReadyPlayRight $value PlayReadyPlayRight
|
||||
*/
|
||||
|
@ -271,9 +271,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures whether the license is persistent (saved in persistent storage on the client) or non-persistent (only held in
|
||||
* memory while the player is using the license). Persistent licenses are typically used to allow offline playback of the
|
||||
* content.
|
||||
* Configures whether the license is persistent (saved in persistent storage on the client) or non-persistent (only
|
||||
* held in memory while the player is using the license). Persistent licenses are typically used to allow offline
|
||||
* playback of the content.
|
||||
*
|
||||
* @return string LicenseType
|
||||
*/
|
||||
|
@ -283,9 +283,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures whether the license is persistent (saved in persistent storage on the client) or non-persistent (only held in
|
||||
* memory while the player is using the license). Persistent licenses are typically used to allow offline playback of the
|
||||
* content.
|
||||
* Configures whether the license is persistent (saved in persistent storage on the client) or non-persistent (only
|
||||
* held in memory while the player is using the license). Persistent licenses are typically used to allow offline
|
||||
* playback of the content.
|
||||
*
|
||||
* @param string $value LicenseType
|
||||
*/
|
||||
|
@ -295,9 +295,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the content key in the license. This is typically set to an instance of the ContentEncryptionKeyFromHeader
|
||||
* object to allow the template to be applied to multiple content keys and have the content header tell the license
|
||||
* server the exact key to embed in the license issued to the client.
|
||||
* Specifies the content key in the license. This is typically set to an instance of the
|
||||
* ContentEncryptionKeyFromHeader object to allow the template to be applied to multiple content keys and have the
|
||||
* content header tell the license server the exact key to embed in the license issued to the client.
|
||||
*
|
||||
* @return PlayReadyContentKey PlayReadyContentKey
|
||||
*/
|
||||
|
@ -307,9 +307,9 @@ class PlayReadyLicenseTemplate
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the content key in the license. This is typically set to an instance of the ContentEncryptionKeyFromHeader
|
||||
* object to allow the template to be applied to multiple content keys and have the content header tell the license
|
||||
* server the exact key to embed in the license issued to the client.
|
||||
* Specifies the content key in the license. This is typically set to an instance of the
|
||||
* ContentEncryptionKeyFromHeader object to allow the template to be applied to multiple content keys and have the
|
||||
* content header tell the license server the exact key to embed in the license issued to the client.
|
||||
*
|
||||
* @param PlayReadyContentKey $value PlayReadyContentKey
|
||||
*/
|
||||
|
|
|
@ -181,8 +181,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures Automatic Gain Control (AGC) and Color Stripe in the license. These are a form of video output protection.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Configures Automatic Gain Control (AGC) and Color Stripe in the license. These are a form of video output
|
||||
* protection. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return AgcAndColorStripeRestriction AgcAndColorStripeRestriction
|
||||
*/
|
||||
|
@ -192,8 +192,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures Automatic Gain Control (AGC) and Color Stripe in the license. These are a form of video output protection.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Configures Automatic Gain Control (AGC) and Color Stripe in the license. These are a form of video output
|
||||
* protection. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param AgcAndColorStripeRestriction $value AgcAndColorStripeRestriction
|
||||
*/
|
||||
|
@ -203,8 +203,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Explicit Analog Television Output Restriction in the license. This is a form of video output protection.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Explicit Analog Television Output Restriction in the license. This is a form of video output
|
||||
* protection. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return ExplicitAnalogTelevisionRestriction ExplicitAnalogTelevisionRestriction
|
||||
*/
|
||||
|
@ -214,8 +214,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Explicit Analog Television Output Restriction in the license. This is a form of video output protection.
|
||||
* For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Explicit Analog Television Output Restriction in the license. This is a form of video output
|
||||
* protection. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param ExplicitAnalogTelevisionRestriction $value ExplicitAnalogTelevisionRestriction
|
||||
*/
|
||||
|
@ -249,9 +249,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Enables the Image Constraint For Analog Component Video Restriction in the license. This is a form of video output protection
|
||||
* which requires the player constrain the resolution of the video portion of the content when outputting it over an Analog
|
||||
* Component Video Output. For further details see the PlayReady Compliance Rules.
|
||||
* Enables the Image Constraint For Analog Component Video Restriction in the license. This is a form of video
|
||||
* output protection which requires the player constrain the resolution of the video portion of the content when
|
||||
* outputting it over an Analog Component Video Output. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return bool ImageConstraintForAnalogComponentVideoRestriction
|
||||
*/
|
||||
|
@ -261,9 +261,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Enables the Image Constraint For Analog Component Video Restriction in the license. This is a form of video output protection
|
||||
* which requires the player constrain the resolution of the video portion of the content when outputting it over an Analog
|
||||
* Component Video Output. For further details see the PlayReady Compliance Rules.
|
||||
* Enables the Image Constraint For Analog Component Video Restriction in the license. This is a form of video
|
||||
* output protection which requires the player constrain the resolution of the video portion of the content when
|
||||
* outputting it over an Analog Component Video Output. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param bool $value ImageConstraintForAnalogComponentVideoRestriction
|
||||
*/
|
||||
|
@ -273,9 +273,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Enables the Image Constraint For Analog Computer Monitor Restriction in the license. This is a form of video output protection
|
||||
* which requires the player constrain the resolution of the video portion of the content when outputting it over an Analog
|
||||
* Computer Monitor Output. For further details see the PlayReady Compliance Rules.
|
||||
* Enables the Image Constraint For Analog Computer Monitor Restriction in the license. This is a form of video
|
||||
* output protection which requires the player constrain the resolution of the video portion of the content when
|
||||
* outputting it over an Analog Computer Monitor Output. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return bool ImageConstraintForAnalogComputerMonitorRestriction
|
||||
*/
|
||||
|
@ -285,9 +285,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Enables the Image Constraint For Analog Computer Monitor Restriction in the license. This is a form of video output protection
|
||||
* which requires the player constrain the resolution of the video portion of the content when outputting it over an Analog
|
||||
* Computer Monitor Output. For further details see the PlayReady Compliance Rules.
|
||||
* Enables the Image Constraint For Analog Computer Monitor Restriction in the license. This is a form of video
|
||||
* output protection which requires the player constrain the resolution of the video portion of the content when
|
||||
* outputting it over an Analog Computer Monitor Output. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param bool $value ImageConstraintForAnalogComputerMonitorRestriction
|
||||
*/
|
||||
|
@ -297,8 +297,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* This property configures Unknown output handling settings of the license. These settings tell the PlayReady DRM runtime
|
||||
* how it should handle unknown video outputs. For further details see the PlayReady Compliance Rules.
|
||||
* This property configures Unknown output handling settings of the license. These settings tell the PlayReady DRM
|
||||
* runtime how it should handle unknown video outputs. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return string AllowPassingVideoContentToUnknownOutput
|
||||
*/
|
||||
|
@ -308,8 +308,8 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* This property configures Unknown output handling settings of the license. These settings tell the PlayReady DRM runtime
|
||||
* how it should handle unknown video outputs. For further details see the PlayReady Compliance Rules.
|
||||
* This property configures Unknown output handling settings of the license. These settings tell the PlayReady DRM
|
||||
* runtime how it should handle unknown video outputs. For further details see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param string $value AllowPassingVideoContentToUnknownOutput
|
||||
*/
|
||||
|
@ -319,9 +319,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for uncompressed digital video. Valid values are null, 100, 250, 270, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for uncompressed digital video. Valid values are null, 100, 250, 270, and
|
||||
* 300. When the property is set to null, the output protection level is not set in the license. For further details
|
||||
* on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return int UncompressedDigitalVideoOpl
|
||||
*/
|
||||
|
@ -331,9 +331,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for uncompressed digital video. Valid values are null, 100, 250, 270, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for uncompressed digital video. Valid values are null, 100, 250, 270, and
|
||||
* 300. When the property is set to null, the output protection level is not set in the license. For further details
|
||||
* on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param int $value UncompressedDigitalVideoOpl
|
||||
*/
|
||||
|
@ -346,9 +346,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for compressed digital video. Valid values are null, 400, and 500.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for compressed digital video. Valid values are null, 400, and 500. When the
|
||||
* property is set to null, the output protection level is not set in the license. For further details on the
|
||||
* meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return int CompressedDigitalVideoOpl
|
||||
*/
|
||||
|
@ -358,9 +358,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for compressed digital video. Valid values are null, 400, and 500.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for compressed digital video. Valid values are null, 400, and 500. When the
|
||||
* property is set to null, the output protection level is not set in the license. For further details on the
|
||||
* meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param int $value CompressedDigitalVideoOpl
|
||||
*/
|
||||
|
@ -373,9 +373,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for analog video. Valid values are null, 100, 150, and 200.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for analog video. Valid values are null, 100, 150, and 200. When the
|
||||
* property is set to null, the output protection level is not set in the license. For further details on the
|
||||
* meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return int AnalogVideoOpl
|
||||
*/
|
||||
|
@ -385,9 +385,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for analog video. Valid values are null, 100, 150, and 200.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for analog video. Valid values are null, 100, 150, and 200. When the
|
||||
* property is set to null, the output protection level is not set in the license. For further details on the
|
||||
* meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param int $value AnalogVideoOpl
|
||||
*/
|
||||
|
@ -400,9 +400,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for compressed digital audio. Valid values are null, 100, 150, 200, 250, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for compressed digital audio. Valid values are null, 100, 150, 200, 250,
|
||||
* and 300. When the property is set to null, the output protection level is not set in the license. For further
|
||||
* details on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return int CompressedDigitalAudioOpl
|
||||
*/
|
||||
|
@ -412,9 +412,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for compressed digital audio. Valid values are null, 100, 150, 200, 250, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for compressed digital audio. Valid values are null, 100, 150, 200, 250,
|
||||
* and 300. When the property is set to null, the output protection level is not set in the license. For further
|
||||
* details on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param int $value CompressedDigitalAudioOpl
|
||||
*/
|
||||
|
@ -427,9 +427,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for uncompressed digital audio. Valid values are 100, 150, 200, 250, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for uncompressed digital audio. Valid values are 100, 150, 200, 250, and
|
||||
* 300. When the property is set to null, the output protection level is not set in the license. For further details
|
||||
* on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @return int UncompressedDigitalAudioOpl
|
||||
*/
|
||||
|
@ -439,9 +439,9 @@ class PlayReadyPlayRight
|
|||
}
|
||||
|
||||
/**
|
||||
* Specifies the output protection level for uncompressed digital audio. Valid values are 100, 150, 200, 250, and 300.
|
||||
* When the property is set to null, the output protection level is not set in the license. For further details on the meaning
|
||||
* of the specific value see the PlayReady Compliance Rules.
|
||||
* Specifies the output protection level for uncompressed digital audio. Valid values are 100, 150, 200, 250, and
|
||||
* 300. When the property is set to null, the output protection level is not set in the license. For further details
|
||||
* on the meaning of the specific value see the PlayReady Compliance Rules.
|
||||
*
|
||||
* @param int $value UncompressedDigitalAudioOpl
|
||||
*/
|
||||
|
|
|
@ -58,7 +58,8 @@ class ScmsRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Serial Copy Management System (SCMS) control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Serial Copy Management System (SCMS) control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @return int ConfigurationData
|
||||
*/
|
||||
|
@ -68,7 +69,8 @@ class ScmsRestriction
|
|||
}
|
||||
|
||||
/**
|
||||
* Configures the Serial Copy Management System (SCMS) control bits. For further details see the PlayReady Compliance Rules.
|
||||
* Configures the Serial Copy Management System (SCMS) control bits. For further details see the PlayReady
|
||||
* Compliance Rules.
|
||||
*
|
||||
* @param int $value ConfigurationData
|
||||
*/
|
||||
|
|
|
@ -73,7 +73,9 @@ class TokenRestrictionTemplateSerializer
|
|||
|
||||
// decoding
|
||||
if (isset($xml->AlternateVerificationKeys)) {
|
||||
$result->setAlternateVerificationKeys(self::deserializeAlternateVerificationKeys($xml->AlternateVerificationKeys));
|
||||
$result->setAlternateVerificationKeys(
|
||||
self::deserializeAlternateVerificationKeys($xml->AlternateVerificationKeys)
|
||||
);
|
||||
}
|
||||
|
||||
$result->setAudience((string) $xml->Audience);
|
||||
|
@ -92,7 +94,9 @@ class TokenRestrictionTemplateSerializer
|
|||
}
|
||||
|
||||
if (isset($xml->OpenIdConnectDiscoveryDocument)) {
|
||||
$result->setOpenIdConnectDiscoveryDocument(self::deserializeOpenIdConnectDiscoveryDocument($xml->OpenIdConnectDiscoveryDocument));
|
||||
$result->setOpenIdConnectDiscoveryDocument(
|
||||
self::deserializeOpenIdConnectDiscoveryDocument($xml->OpenIdConnectDiscoveryDocument)
|
||||
);
|
||||
}
|
||||
|
||||
return $result;
|
||||
|
@ -149,7 +153,9 @@ class TokenRestrictionTemplateSerializer
|
|||
}
|
||||
|
||||
if ($tokenRestriction->getOpenIdConnectDiscoveryDocument()) {
|
||||
self::serializeOpenIdConnectDiscoveryDocument($writer, $tokenRestriction->getOpenIdConnectDiscoveryDocument());
|
||||
self::serializeOpenIdConnectDiscoveryDocument(
|
||||
$writer, $tokenRestriction->getOpenIdConnectDiscoveryDocument()
|
||||
);
|
||||
}
|
||||
|
||||
$writer->endElement();
|
||||
|
@ -188,7 +194,9 @@ class TokenRestrictionTemplateSerializer
|
|||
if ($template->getTokenType() == TokenType::SWT) {
|
||||
return self::generateTestTokenSWT($template, $verificationKey, $contentKeyUUID, $tokenExpiration);
|
||||
} else {
|
||||
return self::generateTestTokenJWT($template, $verificationKey, $contentKeyUUID, $tokenExpiration, $notBefore);
|
||||
return self::generateTestTokenJWT(
|
||||
$template, $verificationKey, $contentKeyUUID, $tokenExpiration, $notBefore
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -436,7 +444,9 @@ class TokenRestrictionTemplateSerializer
|
|||
private static function deserializeOpenIdConnectDiscoveryDocument($xmlElement)
|
||||
{
|
||||
if (!isset($xmlElement->OpenIdDiscoveryUri)) {
|
||||
throw new \RuntimeException("The OpenIdConnectDiscoveryDocument must contains a 'OpenIdDiscoveryUri' element");
|
||||
throw new \RuntimeException(
|
||||
"The OpenIdConnectDiscoveryDocument must contains a 'OpenIdDiscoveryUri' element"
|
||||
);
|
||||
}
|
||||
|
||||
$result = new OpenIdConnectDiscoveryDocument();
|
||||
|
|
|
@ -168,9 +168,8 @@ interface IServiceManagement extends FilterableService
|
|||
* @param string $name The affinity group name
|
||||
* @param string $label A base-64 encoded name for
|
||||
* the affinity group. The name can be up to 100 characters in length
|
||||
* @param string $location The data center location
|
||||
* where the affinity group will be created. To list available locations, use
|
||||
* the listLocations API
|
||||
* @param string $location The data center location where the affinity group will be created. To
|
||||
* list available locations, use the listLocations API
|
||||
* @param CreateAffinityGroupOptions $options The optional parameters
|
||||
*
|
||||
* @see http://msdn.microsoft.com/en-us/library/windowsazure/gg715317.aspx
|
||||
|
@ -244,12 +243,10 @@ interface IServiceManagement extends FilterableService
|
|||
/**
|
||||
* Creates a new hosted service in Windows Azure.
|
||||
*
|
||||
* @param string $name The name for the hosted service
|
||||
* that is unique within Windows Azure. This name is the DNS prefix name and can
|
||||
* be used to access the hosted service
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name can be used identify the storage account for
|
||||
* your tracking purposes
|
||||
* @param string $name The name for the hosted service that is unique within Windows Azure. This
|
||||
* name is the DNS prefix name and can be used to access the hosted service
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name can be
|
||||
* used identify the storage account for your tracking purposes
|
||||
* @param CreateServiceOptions $options The optional parameters
|
||||
*
|
||||
* @see http://msdn.microsoft.com/en-us/library/windowsazure/gg441304.aspx
|
||||
|
@ -308,20 +305,19 @@ interface IServiceManagement extends FilterableService
|
|||
*
|
||||
* @param string $name The name for the hosted service
|
||||
* that is unique within Windows Azure
|
||||
* @param string $deploymentName The name for the deployment.
|
||||
* The deployment name must be unique among other deployments for the hosted
|
||||
* service
|
||||
* @param string $deploymentName The name for the deployment. The deployment name must be unique
|
||||
* among other deployments for the hosted service
|
||||
* @param string $slot The name of the deployment slot
|
||||
* This can be "production" or "staging"
|
||||
* @param string $packageUrl The URL that refers to the
|
||||
* location of the service package in the Blob service. The service package can
|
||||
* be located in a storage account beneath the same subscription
|
||||
* @param string $packageUrl The URL that refers to the location of the service package in the
|
||||
* Blob service. The service package can be located in a storage
|
||||
* account beneath the same subscription
|
||||
* @param string $configuration The base-64 encoded service
|
||||
* configuration file for the deployment
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name can be up to 100 characters in length. It is
|
||||
* recommended that the label be unique within the subscription. The name can be
|
||||
* used identify the hosted service for your tracking purposes
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name
|
||||
* can be up to 100 characters in length. It is recommended that the
|
||||
* label be unique within the subscription. The name can be used
|
||||
* identify the hosted service for your tracking purposes
|
||||
* @param CreateDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
@ -444,22 +440,22 @@ interface IServiceManagement extends FilterableService
|
|||
* name.
|
||||
*
|
||||
* @param string $name The hosted service name
|
||||
* @param string $mode The type of upgrade to initiate
|
||||
* If not specified the default value is Auto. If set to Manual,
|
||||
* walkUpgradeDomain API must be called to apply the update. If set to Auto, the
|
||||
* Windows Azure platform will automatically apply the update to each Upgrade
|
||||
* @param string $mode The type of upgrade to initiate. If not specified the default
|
||||
* value is Auto. If set to Manual, walkUpgradeDomain API must be
|
||||
* called to apply the update. If set to Auto, the Windows Azure
|
||||
* platform will automatically apply the update to each Upgrade
|
||||
* Domain in sequence
|
||||
* @param string $packageUrl The URL that refers to the
|
||||
* location of the service package in the Blob service. The service package can
|
||||
* be located in a storage account beneath the same subscription
|
||||
* @param string $packageUrl The URL that refers to the location of the service package in the
|
||||
* Blob service. The service package can be located in a storage
|
||||
* account beneath the same subscription
|
||||
* @param string $configuration The base-64 encoded service
|
||||
* configuration file for the deployment
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name may be up to 100 characters in length
|
||||
* @param bool $force Specifies whether the rollback
|
||||
* should proceed even when it will cause local data to be lost from some role
|
||||
* instances. True if the rollback should proceed; otherwise false if the
|
||||
* rollback should fail
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name
|
||||
* may be up to 100 characters in length
|
||||
* @param bool $force Specifies whether the rollback should proceed even when it will
|
||||
* cause local data to be lost from some role instances. True if the
|
||||
* rollback should proceed; otherwise false if the rollback should
|
||||
* fail
|
||||
* @param UpgradeDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
@ -485,10 +481,9 @@ interface IServiceManagement extends FilterableService
|
|||
* name.
|
||||
*
|
||||
* @param string $name The hosted service name
|
||||
* @param int $upgradeDomain The integer value that
|
||||
* identifies the upgrade domain to walk. Upgrade domains are identified with a
|
||||
* zero-based index: the first upgrade domain has an ID of 0, the second has an
|
||||
* ID of 1, and so on
|
||||
* @param int $upgradeDomain The integer value that identifies the upgrade domain to walk. Upgrade
|
||||
* domains are identified with a zero-based index: the first upgrade
|
||||
* domain has an ID of 0, the second has an ID of 1, and so on
|
||||
* @param GetDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
|
|
@ -470,10 +470,9 @@ class ServiceManagementRestProxy extends RestProxy implements IServiceManagement
|
|||
* status code 200 (OK).
|
||||
*
|
||||
* @param string $name The storage account name
|
||||
* @param string $label The name for the storage account
|
||||
* specified as a base64-encoded string. The name may be up to 100 characters
|
||||
* in length. The name can be used identify the storage account for your tracking
|
||||
* purposes
|
||||
* @param string $label The name for the storage account specified as a base64-encoded string. The
|
||||
* name may be up to 100 characters in length. The name can be used identify
|
||||
* the storage account for your tracking purposes
|
||||
* @param CreateServiceOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
@ -807,12 +806,10 @@ class ServiceManagementRestProxy extends RestProxy implements IServiceManagement
|
|||
/**
|
||||
* Creates a new hosted service in Windows Azure.
|
||||
*
|
||||
* @param string $name The name for the hosted service
|
||||
* that is unique within Windows Azure. This name is the DNS prefix name and can
|
||||
* be used to access the hosted service
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name can be used identify the storage account for
|
||||
* your tracking purposes
|
||||
* @param string $name The name for the hosted service that is unique within Windows Azure. This
|
||||
* name is the DNS prefix name and can be used to access the hosted service
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name can be
|
||||
* used identify the storage account for your tracking purposes
|
||||
* @param CreateServiceOptions $options The optional parameters
|
||||
*
|
||||
* @see http://msdn.microsoft.com/en-us/library/windowsazure/gg441304.aspx
|
||||
|
@ -972,20 +969,18 @@ class ServiceManagementRestProxy extends RestProxy implements IServiceManagement
|
|||
*
|
||||
* @param string $name The name for the hosted service
|
||||
* that is unique within Windows Azure
|
||||
* @param string $deploymentName The name for the deployment.
|
||||
* The deployment name must be unique among other deployments for the hosted
|
||||
* service
|
||||
* @param string $deploymentName The name for the deployment. The deployment name must be unique
|
||||
* among other deployments for the hosted service
|
||||
* @param string $slot The name of the deployment slot
|
||||
* This can be "production" or "staging"
|
||||
* @param string $packageUrl The URL that refers to the
|
||||
* location of the service package in the Blob service. The service package can
|
||||
* be located in a storage account beneath the same subscription
|
||||
* @param string|resource $configuration The configuration file contents
|
||||
* or file stream
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name can be up to 100 characters in length. It is
|
||||
* recommended that the label be unique within the subscription. The name can be
|
||||
* used identify the hosted service for your tracking purposes
|
||||
* @param string $packageUrl The URL that refers to the location of the service package in the
|
||||
* Blob service. The service package can be located in a storage
|
||||
* account beneath the same subscription
|
||||
* @param string|resource $configuration The configuration file contents or file stream
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name
|
||||
* can be up to 100 characters in length. It is recommended that the
|
||||
* label be unique within the subscription. The name can be used
|
||||
* identify the hosted service for your tracking purposes
|
||||
* @param CreateDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
@ -1293,22 +1288,22 @@ class ServiceManagementRestProxy extends RestProxy implements IServiceManagement
|
|||
* name.
|
||||
*
|
||||
* @param string $name The hosted service name
|
||||
* @param string $mode The type of upgrade to initiate
|
||||
* If not specified the default value is Auto. If set to Manual,
|
||||
* walkUpgradeDomain API must be called to apply the update. If set to Auto, the
|
||||
* Windows Azure platform will automatically apply the update to each Upgrade
|
||||
* @param string $mode The type of upgrade to initiate. If not specified the default
|
||||
* value is Auto. If set to Manual, walkUpgradeDomain API must be
|
||||
* called to apply the update. If set to Auto, the Windows Azure
|
||||
* platform will automatically apply the update to each Upgrade
|
||||
* Domain in sequence
|
||||
* @param string $packageUrl The URL that refers to the
|
||||
* location of the service package in the Blob service. The service package can
|
||||
* be located in a storage account beneath the same subscription
|
||||
* @param string $packageUrl The URL that refers to the location of the service package in the
|
||||
* Blob service. The service package can be located in a storage
|
||||
* account beneath the same subscription
|
||||
* @param string|resource $configuration The configuration file contents
|
||||
* or file stream
|
||||
* @param string $label The name for the hosted service
|
||||
* that is base-64 encoded. The name may be up to 100 characters in length
|
||||
* @param bool $force Specifies whether the rollback
|
||||
* should proceed even when it will cause local data to be lost from some role
|
||||
* instances. True if the rollback should proceed; otherwise false if the
|
||||
* rollback should fail
|
||||
* @param string $label The name for the hosted service that is base-64 encoded. The name
|
||||
* may be up to 100 characters in length
|
||||
* @param bool $force Specifies whether the rollback should proceed even when it will
|
||||
* cause local data to be lost from some role instances. True if the
|
||||
* rollback should proceed; otherwise false if the rollback should
|
||||
* fail
|
||||
* @param UpgradeDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
@ -1381,10 +1376,9 @@ class ServiceManagementRestProxy extends RestProxy implements IServiceManagement
|
|||
* name.
|
||||
*
|
||||
* @param string $name The hosted service name
|
||||
* @param int $upgradeDomain The integer value that
|
||||
* identifies the upgrade domain to walk. Upgrade domains are identified with a
|
||||
* zero-based index: the first upgrade domain has an ID of 0, the second has an
|
||||
* ID of 1, and so on
|
||||
* @param int $upgradeDomain The integer value that identifies the upgrade domain to walk. Upgrade
|
||||
* domains are identified with a zero-based index: the first upgrade
|
||||
* domain has an ID of 0, the second has an ID of 1, and so on
|
||||
* @param GetDeploymentOptions $options The optional parameters
|
||||
*
|
||||
* @return AsynchronousOperationResult
|
||||
|
|
|
@ -66,7 +66,10 @@ class BatchResponseTest extends \PHPUnit_Framework_TestCase
|
|||
$body.
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122--\r\n".
|
||||
'--batch_956c339e-1ef0-4443-9276-68c12888a3f7--';
|
||||
$response = new Response(200, [], $encodedBody);
|
||||
$response = new Response(
|
||||
200,
|
||||
['content-type' => ['boundary=batch_956c339e-1ef0-4443-9276-68c12888a3f7']],
|
||||
$encodedBody);
|
||||
|
||||
// Test
|
||||
$batchResp = new BatchResponse($response);
|
||||
|
@ -107,7 +110,10 @@ class BatchResponseTest extends \PHPUnit_Framework_TestCase
|
|||
$body.
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122--\r\n".
|
||||
'--batch_956c339e-1ef0-4443-9276-68c12888a3f7--';
|
||||
$response = new Response(200, [], $encodedBody);
|
||||
$response = new Response(
|
||||
200,
|
||||
['Content-Type' => ['boundary=batch_956c339e-1ef0-4443-9276-68c12888a3f7']],
|
||||
$encodedBody);
|
||||
|
||||
// Test
|
||||
$batchResp = new BatchResponse($response, $batchReq);
|
||||
|
@ -136,20 +142,23 @@ class BatchResponseTest extends \PHPUnit_Framework_TestCase
|
|||
$batchReq->appendContext($httpCallContext);
|
||||
|
||||
$encodedBody =
|
||||
"--batch_956c339e-1ef0-4443-9276-68c12888a3f7\r\n".
|
||||
"Content-Type: multipart/mixed; boundary=changeset_4a3f1712-c034-416e-9772-905d28c0b122\r\n".
|
||||
"\r\n".
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122\r\n".
|
||||
"Content-Transfer-Encoding: binary\r\n".
|
||||
"Content-Type: application/http\r\n".
|
||||
"\r\n".
|
||||
"HTTP/1.1 {$statusCode} OK\r\n".
|
||||
"content-id: 1\r\n".
|
||||
"\r\n".
|
||||
$body.
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122--\r\n".
|
||||
'--batch_956c339e-1ef0-4443-9276-68c12888a3f7--';
|
||||
$response = new Response(200, [], $encodedBody);
|
||||
"--batch_956c339e-1ef0-4443-9276-68c12888a3f7\r\n".
|
||||
"Content-Type: multipart/mixed; boundary=changeset_4a3f1712-c034-416e-9772-905d28c0b122\r\n".
|
||||
"\r\n".
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122\r\n".
|
||||
"Content-Transfer-Encoding: binary\r\n".
|
||||
"Content-Type: application/http\r\n".
|
||||
"\r\n".
|
||||
"HTTP/1.1 {$statusCode} OK\r\n".
|
||||
"content-id: 1\r\n".
|
||||
"\r\n".
|
||||
$body.
|
||||
"--changeset_4a3f1712-c034-416e-9772-905d28c0b122--\r\n".
|
||||
'--batch_956c339e-1ef0-4443-9276-68c12888a3f7--';
|
||||
$response = new Response(
|
||||
200,
|
||||
['content-type' => ['boundary=batch_956c339e-1ef0-4443-9276-68c12888a3f7']],
|
||||
$encodedBody);
|
||||
|
||||
$this->setExpectedException('WindowsAzure\Common\ServiceException');
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче