當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Utilities::tryGetValueInsensitive方法代碼示例

本文整理匯總了PHP中Utilities::tryGetValueInsensitive方法的典型用法代碼示例。如果您正苦於以下問題:PHP Utilities::tryGetValueInsensitive方法的具體用法?PHP Utilities::tryGetValueInsensitive怎麽用?PHP Utilities::tryGetValueInsensitive使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Utilities的用法示例。


在下文中一共展示了Utilities::tryGetValueInsensitive方法的4個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: createFromConnectionString

 /**
  * Creates a MediaServicesSettings object from the given connection string.
  *
  * @param string $connectionString The media services settings connection string.
  *
  * @return MediaServicesSettings
  */
 public static function createFromConnectionString($connectionString)
 {
     $tokenizedSettings = self::parseAndValidateKeys($connectionString);
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::allRequired(self::$_accountNameSetting, self::$_accessKeySetting), self::optional(self::$_endpointUriSetting, self::$_oauthEndpointUriSetting));
     if ($matchedSpecs) {
         $endpointUri = Utilities::tryGetValueInsensitive(Resources::MEDIA_SERVICES_ENDPOINT_URI_NAME, $tokenizedSettings, Resources::MEDIA_SERVICES_URL);
         $oauthEndpointUri = Utilities::tryGetValueInsensitive(Resources::MEDIA_SERVICES_OAUTH_ENDPOINT_URI_NAME, $tokenizedSettings, Resources::MEDIA_SERVICES_OAUTH_URL);
         $accountName = Utilities::tryGetValueInsensitive(Resources::MEDIA_SERVICES_ACCOUNT_NAME, $tokenizedSettings);
         $accessKey = Utilities::tryGetValueInsensitive(Resources::MEDIA_SERVICES_ACCESS_KEY, $tokenizedSettings);
         return new self($accountName, $accessKey, $endpointUri, $oauthEndpointUri);
     }
     self::noMatch($connectionString);
 }
開發者ID:southworkscom,項目名稱:azure-sdk-for-php,代碼行數:20,代碼來源:MediaServicesSettings.php

示例2: createFromConnectionString

 /**
  * Creates a ServiceBusSettings object from the given connection string.
  * 
  * @param string $connectionString The storage settings connection string.
  * 
  * @return ServiceBusSettings
  */
 public static function createFromConnectionString($connectionString)
 {
     $tokenizedSettings = self::parseAndValidateKeys($connectionString);
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::allRequired(self::$_serviceBusEndpointSetting, self::$_wrapNameSetting, self::$_wrapPasswordSetting), self::optional(self::$_wrapEndpointUriSetting));
     if ($matchedSpecs) {
         $endpoint = Utilities::tryGetValueInsensitive(Resources::SERVICE_BUS_ENDPOINT_NAME, $tokenizedSettings);
         // Parse the namespace part from the URI
         $namespace = explode('.', parse_url($endpoint, PHP_URL_HOST));
         $namespace = $namespace[0];
         $wrapEndpointUri = Utilities::tryGetValueInsensitive(Resources::STS_ENDPOINT_NAME, $tokenizedSettings, sprintf(Resources::WRAP_ENDPOINT_URI_FORMAT, $namespace));
         $issuerName = Utilities::tryGetValueInsensitive(Resources::SHARED_SECRET_ISSUER_NAME, $tokenizedSettings);
         $issuerValue = Utilities::tryGetValueInsensitive(Resources::SHARED_SECRET_VALUE_NAME, $tokenizedSettings);
         return new self($endpoint, $namespace, $wrapEndpointUri, $issuerName, $issuerValue);
     }
     self::noMatch($connectionString);
 }
開發者ID:southworkscom,項目名稱:azure-sdk-for-php,代碼行數:23,代碼來源:ServiceBusSettings.php

示例3: createFromConnectionString

 /**
  * Creates a ServiceManagementSettings object from the given connection string.
  * 
  * @param string $connectionString The storage settings connection string.
  * 
  * @return ServiceManagementSettings
  */
 public static function createFromConnectionString($connectionString)
 {
     $tokenizedSettings = self::parseAndValidateKeys($connectionString);
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::allRequired(self::$_subscriptionIdSetting, self::$_certificatePathSetting), self::optional(self::$_endpointSetting));
     if ($matchedSpecs) {
         $endpointUri = Utilities::tryGetValueInsensitive(Resources::SERVICE_MANAGEMENT_ENDPOINT_NAME, $tokenizedSettings, Resources::SERVICE_MANAGEMENT_URL);
         $subscriptionId = Utilities::tryGetValueInsensitive(Resources::SUBSCRIPTION_ID_NAME, $tokenizedSettings);
         $certificatePath = Utilities::tryGetValueInsensitive(Resources::CERTIFICATE_PATH_NAME, $tokenizedSettings);
         return new self($subscriptionId, $endpointUri, $certificatePath);
     }
     self::noMatch($connectionString);
 }
開發者ID:southworkscom,項目名稱:azure-sdk-for-php,代碼行數:19,代碼來源:ServiceManagementSettings.php

示例4: createFromConnectionString

 /**
  * Creates a StorageServiceSettings object from the given connection string.
  * 
  * @param string $connectionString The storage settings connection string.
  * 
  * @return StorageServiceSettings
  */
 public static function createFromConnectionString($connectionString)
 {
     $tokenizedSettings = self::parseAndValidateKeys($connectionString);
     // Devstore case
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::allRequired(self::$_useDevelopmentStorageSetting), self::optional(self::$_developmentStorageProxyUriSetting));
     if ($matchedSpecs) {
         $proxyUri = Utilities::tryGetValueInsensitive(Resources::DEVELOPMENT_STORAGE_PROXY_URI_NAME, $tokenizedSettings);
         return self::_getDevelopmentStorageAccount($proxyUri);
     }
     // Automatic case
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::allRequired(self::$_defaultEndpointsProtocolSetting, self::$_accountNameSetting, self::$_accountKeySetting), self::optional(self::$_blobEndpointSetting, self::$_queueEndpointSetting, self::$_tableEndpointSetting));
     if ($matchedSpecs) {
         return self::_createStorageServiceSettings($tokenizedSettings, self::_getDefaultServiceEndpoint($tokenizedSettings, Resources::BLOB_BASE_DNS_NAME), self::_getDefaultServiceEndpoint($tokenizedSettings, Resources::QUEUE_BASE_DNS_NAME), self::_getDefaultServiceEndpoint($tokenizedSettings, Resources::TABLE_BASE_DNS_NAME));
     }
     // Explicit case
     $matchedSpecs = self::matchedSpecification($tokenizedSettings, self::atLeastOne(self::$_blobEndpointSetting, self::$_queueEndpointSetting, self::$_tableEndpointSetting), self::allRequired(self::$_accountNameSetting, self::$_accountKeySetting));
     if ($matchedSpecs) {
         return self::_createStorageServiceSettings($tokenizedSettings);
     }
     self::noMatch($connectionString);
 }
開發者ID:southworkscom,項目名稱:azure-sdk-for-php,代碼行數:28,代碼來源:StorageServiceSettings.php


注:本文中的Utilities::tryGetValueInsensitive方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。