diff --git a/Makefile b/Makefile index c039bdd6..68ec6309 100644 --- a/Makefile +++ b/Makefile @@ -9,8 +9,8 @@ compatible: php vendor/bin/phpcs --config-set testVersion 5.6 php vendor/bin/phpcs -p --standard=PHPCompatibility src -fmt: - php vendor/bin/phpcbf +fmt: install + php vendor/bin/phpcbf || true build: composer dump-autoload @@ -24,30 +24,3 @@ test-cov: cov-show: open build/coverage/index.html - -gen: - ucloud-spec create opensdk \ - --only "UFS" \ - --only "UDisk" \ - --only "UHost" \ - --only "PathX" \ - --only "UDDB" \ - --only "UCDN" \ - --only "UNet" \ - --only "VPC2.0" \ - --only "UDB" \ - --only "UMem" \ - --only "ULB" \ - --only "Cube" \ - --only "UK8S" \ - --only "IPSecVPN" \ - --only "UAccount" \ - --only "UDPN" \ - --only "UBill" \ - --only "UPHost" \ - --only "UFile" \ - --only "USMS" \ - --only "UEC" \ - --public \ - -s https://git.ucloudadmin.com/apispec/apispec.git \ - /Users/user/code/oas/plugins/template-opensdk-php . diff --git a/examples/generic/README.md b/examples/generic/README.md deleted file mode 100644 index c25d3df6..00000000 --- a/examples/generic/README.md +++ /dev/null @@ -1,20 +0,0 @@ -# UCloud SDK Generic Invoking Example - -## What is the goal - -Call the UCloudStack API. - -## Setup Environment - -```go -export UCLOUDSTACK_PUBLIC_KEY="your public key" -export UCLOUDSTACK_PRIVATE_KEY="your private key" -``` - -## How to run - -change directory to here. - -```sh -php main.php -``` diff --git a/examples/generic/main.php b/examples/generic/main.php deleted file mode 100644 index 0a6a79ad..00000000 --- a/examples/generic/main.php +++ /dev/null @@ -1,26 +0,0 @@ - getenv("UCLOUDSTACK_PUBLIC_KEY"), - "privateKey" => getenv("UCLOUDSTACK_PRIVATE_KEY"), - "baseUrl" => "http://console.pre.ucloudstack.com/api", - ]); - - try { - $resp = $client->invoke(new Request([ - "Action" => "DescribeRegion", - ])); - } catch (UCloudException $e) { - exit(1); - } - print_r($resp); -} - -main(); diff --git a/examples/two-tier/README.md b/examples/two-tier/README.md deleted file mode 100644 index ce2ab65c..00000000 --- a/examples/two-tier/README.md +++ /dev/null @@ -1,19 +0,0 @@ -# UCloud SDK Two-Tier Example - -## What is the goal - -Build a two-tier architecture with ulb and uhost, and remove all example data. - -## Setup Environment - -```go -export UCLOUD_PUBLIC_KEY="your public key" -export UCLOUD_PRIVATE_KEY="your private key" -export UCLOUD_PROJECT_ID="your project id" -``` - -## How to run - -```sh -php main.php -``` diff --git a/examples/two-tier/main.php b/examples/two-tier/main.php deleted file mode 100644 index 68a5e418..00000000 --- a/examples/two-tier/main.php +++ /dev/null @@ -1,264 +0,0 @@ - getenv("UCLOUD_PUBLIC_KEY"), - "privateKey" => getenv("UCLOUD_PRIVATE_KEY"), - "projectId" => getenv("UCLOUD_PROJECT_ID"), - "region" => "cn-bj2", - ]; - $this->uhostClient = new UHostClient($cfg); - $this->ulbClient = new ULBClient($cfg); - $this->zone = "cn-bj2-05"; - $this->name = "sdk-php-example-two-tier"; - } - - /** - * @throws UCloudException - */ - public function __invoke() - { - $imageId = $this->describeImage(); - - $uhostIds = $this->createUHostBatch($imageId, 2); - - $ulbId = $this->createUlb(); - - $vserverId = $this->createVServer($ulbId); - - $backendIds = $this->allocateBackendBatch($ulbId, $vserverId, $uhostIds); - - $this->releaseBackendBatch($ulbId, $backendIds); - - $this->deleteVServer($ulbId, $vserverId); - - $this->deleteUlb($ulbId); - - $this->deleteUHostBatch($uhostIds); - } - - /** - * Describe Image - * - * @return string - * @throws UCloudException - */ - private function describeImage(): string - { - $req = new DescribeImageRequest(); - $req->setZone($this->zone); - $req->setImageType("Base"); - $req->setOsType("Linux"); - $resp = $this->uhostClient->describeImage($req); - $image = $resp->getImageSet()[0]; - return $image->getImageId(); - } - - /** - * Create Instance - * - * @param string $imageId - * @param int $count - * @return array - * @throws UCloudException - */ - private function createUHostBatch(string $imageId, int $count): array - { - $ids = []; - foreach(range(1, $count) as $index) { - $req = new CreateUHostInstanceRequest(); - $req->setName($this->name); - $req->setZone($this->zone); - $req->setImageId($imageId); - $req->setLoginMode("Password"); - $req->setPassword(base64_encode("UCloud1234!")); - $req->setCPU(1); - $req->setMemory(1024); - - $resp = $this->uhostClient->createUHostInstance($req); - array_push($ids, $resp->getUHostIds()[0]); - } - $this->waitUHostState($ids, "Running"); - return $ids; - } - - /** - * Create ULB - * - * @return string - * @throws UCloudException - */ - private function createUlb(): string - { - $req = new CreateULBRequest(); - $req->setULBName($this->name); - $resp = $this->ulbClient->createULB($req); - return $resp->getULBId(); - } - - /** - * Create VServer under ULB - * - * @param string $ulbId - * @return string - * @throws UCloudException - */ - private function createVServer(string $ulbId): string - { - - $req = new CreateVServerRequest(); - $req->setVServerName($this->name); - $req->setULBId($ulbId); - $resp = $this->ulbClient->createVServer($req); - return $resp->getVServerId(); - } - - /** - * Create several backends under VServer - * - * @param string $ulbId - * @param string $vserverId - * @param array $uhostIds - * @return array - * @throws UCloudException - */ - private function allocateBackendBatch(string $ulbId, string $vserverId, array $uhostIds): array - { - $backendIds = []; - foreach ($uhostIds as $uhostId) { - $req = new AllocateBackendRequest(); - $req->setULBId($ulbId); - $req->setVServerId($vserverId); - $req->setResourceId($uhostId); - $req->setResourceType("UHost"); - $resp = $this->ulbClient->allocateBackend($req); - array_push($backendIds, $resp->getBackendId()); - } - return $backendIds; - } - - /** - * Delete backends from VServer - * - * @param string $ulbId - * @param string $vserverId - * @param array $backendIds - * @throws UCloudException - */ - private function releaseBackendBatch(string $ulbId, array $backendIds) - { - foreach ($backendIds as $backendId) { - $req = new ReleaseBackendRequest(); - $req->setULBId($ulbId); - $req->setBackendId($backendId); - $this->ulbClient->releaseBackend($req); - } - } - - /** - * Delete VServer from ULB - * - * @param string $ulbId - * @param string $vserverId - * @throws UCloudException - */ - private function deleteVServer(string $ulbId, string $vserverId) - { - $req = new DeleteVServerRequest(); - $req->setULBId($ulbId); - $req->setVServerId($vserverId); - } - - /** - * Delete ULB - * - * @param string $ulbId - * @throws UCloudException - */ - private function deleteUlb(string $ulbId) - { - $req = new DeleteULBRequest(); - $req->setULBId($ulbId); - $this->ulbClient->deleteULB($req); - } - - /** - * Delete UHost instances - * - * @param array $uhostIds - * @throws UCloudException - */ - private function deleteUHostBatch(array $uhostIds) - { - foreach ($uhostIds as $uhostId) { - $req = new StopUHostInstanceRequest(); - $req->setUHostId($uhostId); - $this->uhostClient->stopUHostInstance($req); - } - - $this->waitUHostState($uhostIds, "Stopped"); - - foreach ($uhostIds as $uhostId) { - $req = new TerminateUHostInstanceRequest(); - $req->setUHostId($uhostId); - $this->uhostClient->terminateUHostInstance($req); - } - } - - /** - * @throws UCloudException - */ - private function waitUHostState(array $uhostIds, string $state) - { - while (true) { - $hasNotReady = false; - - $req = new DescribeUHostInstanceRequest(); - $req->setUHostIds($uhostIds); - $resp = $this->uhostClient->describeUHostInstance($req); - foreach ($resp->getUHostSet() as $instance) { - if ($instance->getState() != $state) { - $hasNotReady = true; - } - } - if (!$hasNotReady) { - break; - } - sleep(1); - } - } -} - - -$main = new Main(); -$main(); diff --git a/examples/uhost/README.md b/examples/uhost/README.md deleted file mode 100644 index b308f167..00000000 --- a/examples/uhost/README.md +++ /dev/null @@ -1,21 +0,0 @@ -# UCloud SDK UHost Example - -## What is the goal - -Create an uhost, wait it created, and remove all example data. - -## Setup Environment - -```go -export UCLOUD_PUBLIC_KEY="your public key" -export UCLOUD_PRIVATE_KEY="your private key" -export UCLOUD_PROJECT_ID="your project id" -``` - -## How to run - -change directory to here. - -```sh -php main.php -``` diff --git a/examples/uhost/main.php b/examples/uhost/main.php deleted file mode 100644 index 276d8b00..00000000 --- a/examples/uhost/main.php +++ /dev/null @@ -1,124 +0,0 @@ - getenv("UCLOUD_PUBLIC_KEY"), - "privateKey" => getenv("UCLOUD_PRIVATE_KEY"), - "projectId" => getenv("UCLOUD_PROJECT_ID"), - "region" => "cn-bj2", - ]); - $zone = "cn-bj2-05"; - - // Describe Image - try { - $req = new DescribeImageRequest(); - $req->setZone($zone); - $req->setImageType("Base"); - $req->setOsType("Linux"); - - $resp = $client->describeImage($req); - } catch (UCloudException $e) { - throw $e; - } - $image = $resp->getImageSet()[0]; - - // Create Instance - try { - $req = new CreateUHostInstanceRequest(); - $req->setName("sdk-php-example"); - $req->setZone($zone); - $req->setImageId($image->getImageId()); - $req->setLoginMode("Password"); - $req->setPassword(base64_encode("UCloud1234!")); - $req->setCPU(1); - $req->setMemory(1024); - - $disk = new CreateUHostInstanceParamDisks(); - $disk->setSize($image->getImageSize()); - $disk->setType("CLOUD_SSD"); - $disk->setIsBoot("True"); - - $req->setDisks([$disk]); - - $resp = $client->createUHostInstance($req); - } catch (UCloudException $e) { - throw $e; - } - $id = $resp->getUHostIds()[0]; - - // Wait instance to boot - while (True) { - sleep(3); - - try { - $req = new DescribeUHostInstanceRequest(); - $req->setZone($zone); - $req->setUHostIds([$id]); - $resp = $client->describeUHostInstance($req); - } catch (UCloudException $e) { - break; - } - - $instance = $resp->getUHostSet()[0]; - echo "waiting " . $id . " to boot, got " . $instance->getState() . "\n"; - if (in_array($instance->getState(), ["Running"])) { - break; - } - } - - // Stop the instance - try { - $req = new StopUHostInstanceRequest(); - $req->setZone($zone); - $req->setUHostId($id); - $client->stopUHostInstance($req); - } catch (UCloudException $e) { - throw $e; - } - - // Wait instance to boot - while (True) { - sleep(3); - - try { - $req = new DescribeUHostInstanceRequest(); - $req->setZone($zone); - $req->setUHostIds([$id]); - $resp = $client->describeUHostInstance($req); - } catch (UCloudException $e) { - break; - } - $instance = $resp->getUHostSet()[0]; - echo "waiting " . $id . " to stopped, got " . $instance->getState() . "\n"; - if (in_array($instance->getState(), ["Stopped"])) { - break; - } - } - - // Cleanup the instance - try { - $req = new TerminateUHostInstanceRequest(); - $req->setZone($zone); - $req->setUHostId($id); - $client->terminateUHostInstance($req); - } catch (UCloudException $e) { - throw $e; - } -} - -main(); diff --git a/src/Cube/Apis/CreateCubeDeploymentRequest.php b/src/Cube/Apis/CreateCubeDeploymentRequest.php index af92c114..96f4c48f 100644 --- a/src/Cube/Apis/CreateCubeDeploymentRequest.php +++ b/src/Cube/Apis/CreateCubeDeploymentRequest.php @@ -1,6 +1,7 @@ markRequired("Deployment"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPCId * @@ -107,11 +105,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网Id * @@ -127,11 +124,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Deployment: base64编码的Deployment的yaml。大小不超过16KB * @@ -147,11 +143,10 @@ public function getDeployment() * * @param string $deployment */ - public function setDeployment($deployment) + public function setDeployment(string $deployment) { $this->set("Deployment", $deployment); } - /** * Name: Deployment名称 * @@ -167,11 +162,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Postpay, \\ 后付费;默认为后付费 * @@ -187,11 +181,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CpuPlatform: Cpu平台(V6:Intel、A2:AMD),默认V6。支持的地域(北京2B、北京2E、上海2A、广东、香港 、东京)目前北京2E仅有A2,其余地域仅有V6 * @@ -207,11 +200,10 @@ public function getCpuPlatform() * * @param string $cpuPlatform */ - public function setCpuPlatform($cpuPlatform) + public function setCpuPlatform(string $cpuPlatform) { $this->set("CpuPlatform", $cpuPlatform); } - /** * KubeConfig: base64编码的kubeconfig。大小不超过16KB * @@ -227,11 +219,10 @@ public function getKubeConfig() * * @param string $kubeConfig */ - public function setKubeConfig($kubeConfig) + public function setKubeConfig(string $kubeConfig) { $this->set("KubeConfig", $kubeConfig); } - /** * Quantity: 购买时长。默认:值 1。 月付时,此参数传0,代表购买至月末。 * @@ -247,11 +238,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Tag: 业务组。默认:Default(Default即为未分组) * @@ -267,7 +257,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/Cube/Apis/CreateCubeDeploymentResponse.php b/src/Cube/Apis/CreateCubeDeploymentResponse.php index df249e08..99c4d1b1 100644 --- a/src/Cube/Apis/CreateCubeDeploymentResponse.php +++ b/src/Cube/Apis/CreateCubeDeploymentResponse.php @@ -1,6 +1,7 @@ set("DeploymentId", $deploymentId); } - /** * Deployment: 经过base64编码的Deployment的yaml * @@ -57,7 +57,7 @@ public function getDeployment() * * @param string $deployment */ - public function setDeployment($deployment) + public function setDeployment(string $deployment) { $this->set("Deployment", $deployment); } diff --git a/src/Cube/Apis/CreateCubePodRequest.php b/src/Cube/Apis/CreateCubePodRequest.php index 4f5ae452..bc9e187a 100644 --- a/src/Cube/Apis/CreateCubePodRequest.php +++ b/src/Cube/Apis/CreateCubePodRequest.php @@ -1,6 +1,7 @@ markRequired("Pod"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPCId * @@ -107,11 +105,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网Id * @@ -127,11 +124,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Pod: base64编码的Pod的yaml。大小不超过16KB * @@ -147,11 +143,10 @@ public function getPod() * * @param string $pod */ - public function setPod($pod) + public function setPod(string $pod) { $this->set("Pod", $pod); } - /** * Group: pod所在组 * @@ -167,11 +162,10 @@ public function getGroup() * * @param string $group */ - public function setGroup($group) + public function setGroup(string $group) { $this->set("Group", $group); } - /** * Name: pod的名字 * @@ -187,11 +181,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务组。默认:Default(Default即为未分组) * @@ -207,11 +200,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * CpuPlatform: Cpu平台(V6:Intel、A2:AMD、Auto),默认Auto。支持的地域(北京2B、北京2E、上海2A、广东、香港 、东京)目前北京2E仅有A2,其余地域仅有V6 * @@ -227,11 +219,10 @@ public function getCpuPlatform() * * @param string $cpuPlatform */ - public function setCpuPlatform($cpuPlatform) + public function setCpuPlatform(string $cpuPlatform) { $this->set("CpuPlatform", $cpuPlatform); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Postpay, \\ 后付费;默认为后付费 * @@ -247,11 +238,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长。默认:值 1。 月付时,此参数传0,代表购买至月末。 * @@ -267,11 +257,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * KubeConfig: base64编码的kubeconfig。大小不超过16KB * @@ -287,11 +276,10 @@ public function getKubeConfig() * * @param string $kubeConfig */ - public function setKubeConfig($kubeConfig) + public function setKubeConfig(string $kubeConfig) { $this->set("KubeConfig", $kubeConfig); } - /** * CouponId: 代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看 * @@ -307,7 +295,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/Cube/Apis/CreateCubePodResponse.php b/src/Cube/Apis/CreateCubePodResponse.php index a78ae2ab..a832b552 100644 --- a/src/Cube/Apis/CreateCubePodResponse.php +++ b/src/Cube/Apis/CreateCubePodResponse.php @@ -1,6 +1,7 @@ set("Pod", $pod); } - /** * CubeId: cube的资源Id * @@ -57,7 +57,7 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } diff --git a/src/Cube/Apis/DeleteCubeDeploymentRequest.php b/src/Cube/Apis/DeleteCubeDeploymentRequest.php index a3d95461..9300ab61 100644 --- a/src/Cube/Apis/DeleteCubeDeploymentRequest.php +++ b/src/Cube/Apis/DeleteCubeDeploymentRequest.php @@ -1,6 +1,7 @@ markRequired("DeploymentId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DeploymentId: 控制器Id * @@ -104,7 +102,7 @@ public function getDeploymentId() * * @param string $deploymentId */ - public function setDeploymentId($deploymentId) + public function setDeploymentId(string $deploymentId) { $this->set("DeploymentId", $deploymentId); } diff --git a/src/Cube/Apis/DeleteCubeDeploymentResponse.php b/src/Cube/Apis/DeleteCubeDeploymentResponse.php index 461c9fa3..fd69b2b3 100644 --- a/src/Cube/Apis/DeleteCubeDeploymentResponse.php +++ b/src/Cube/Apis/DeleteCubeDeploymentResponse.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Uid: cubeid和uid任意一个(必须) * @@ -104,11 +102,10 @@ public function getUid() * * @param string $uid */ - public function setUid($uid) + public function setUid(string $uid) { $this->set("Uid", $uid); } - /** * CubeId: cubeid和uid任意一个(必须) * @@ -124,11 +121,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * ReleaseEIP: 删除cube时是否释放绑定的EIP。默认为false。 * @@ -144,7 +140,7 @@ public function getReleaseEIP() * * @param boolean $releaseEIP */ - public function setReleaseEIP($releaseEIP) + public function setReleaseEIP(bool $releaseEIP) { $this->set("ReleaseEIP", $releaseEIP); } diff --git a/src/Cube/Apis/DeleteCubePodResponse.php b/src/Cube/Apis/DeleteCubePodResponse.php index fa45cd5c..2b960144 100644 --- a/src/Cube/Apis/DeleteCubePodResponse.php +++ b/src/Cube/Apis/DeleteCubePodResponse.php @@ -1,6 +1,7 @@ markRequired("DeploymentId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DeploymentId: Deployment的Id * @@ -104,7 +102,7 @@ public function getDeploymentId() * * @param string $deploymentId */ - public function setDeploymentId($deploymentId) + public function setDeploymentId(string $deploymentId) { $this->set("DeploymentId", $deploymentId); } diff --git a/src/Cube/Apis/GetCubeDeploymentResponse.php b/src/Cube/Apis/GetCubeDeploymentResponse.php index b33ddd07..c1f4a28a 100644 --- a/src/Cube/Apis/GetCubeDeploymentResponse.php +++ b/src/Cube/Apis/GetCubeDeploymentResponse.php @@ -1,6 +1,7 @@ set("Deployment", $deployment); } diff --git a/src/Cube/Apis/GetCubeExecTokenRequest.php b/src/Cube/Apis/GetCubeExecTokenRequest.php index ab747786..a3461c1b 100644 --- a/src/Cube/Apis/GetCubeExecTokenRequest.php +++ b/src/Cube/Apis/GetCubeExecTokenRequest.php @@ -1,6 +1,7 @@ markRequired("ContainerName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ContainerName: 容器名称 * @@ -105,11 +103,10 @@ public function getContainerName() * * @param string $containerName */ - public function setContainerName($containerName) + public function setContainerName(string $containerName) { $this->set("ContainerName", $containerName); } - /** * CubeId: CubeId 和 Uid 中必须填写任意一个。CubeId 是所有 Cube 资源的唯一 ID,如非在 UK8S 通过 Virtual Kubelet 插件创建的 Cube, 则必填 CubeId * @@ -125,11 +122,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Uid: CubeId 和 Uid 中必须填写任意一个。Uid 是在 UK8S 中通过 Virtual Kubelet 插件创建出的 Cube 的唯一标识 * @@ -145,7 +141,7 @@ public function getUid() * * @param string $uid */ - public function setUid($uid) + public function setUid(string $uid) { $this->set("Uid", $uid); } diff --git a/src/Cube/Apis/GetCubeExecTokenResponse.php b/src/Cube/Apis/GetCubeExecTokenResponse.php index c203a5fd..3ac40b23 100644 --- a/src/Cube/Apis/GetCubeExecTokenResponse.php +++ b/src/Cube/Apis/GetCubeExecTokenResponse.php @@ -1,6 +1,7 @@ set("Token", $token); } - /** * TerminalUrl: terminal的登录连接地址,限单点登录,有效时间5min * @@ -57,7 +57,7 @@ public function getTerminalUrl() * * @param string $terminalUrl */ - public function setTerminalUrl($terminalUrl) + public function setTerminalUrl(string $terminalUrl) { $this->set("TerminalUrl", $terminalUrl); } diff --git a/src/Cube/Apis/GetCubeExtendInfoRequest.php b/src/Cube/Apis/GetCubeExtendInfoRequest.php index 11eb161b..6d0c271f 100644 --- a/src/Cube/Apis/GetCubeExtendInfoRequest.php +++ b/src/Cube/Apis/GetCubeExtendInfoRequest.php @@ -1,6 +1,7 @@ markRequired("CubeIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CubeIds: id列表以逗号(,)分割 * @@ -105,7 +103,7 @@ public function getCubeIds() * * @param string $cubeIds */ - public function setCubeIds($cubeIds) + public function setCubeIds(string $cubeIds) { $this->set("CubeIds", $cubeIds); } diff --git a/src/Cube/Apis/GetCubeExtendInfoResponse.php b/src/Cube/Apis/GetCubeExtendInfoResponse.php index d172fbd3..e6e34688 100644 --- a/src/Cube/Apis/GetCubeExtendInfoResponse.php +++ b/src/Cube/Apis/GetCubeExtendInfoResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new CubeExtendInfo($item)); + array_push($result, new CubeExtendInfoModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getExtendInfo() /** * ExtendInfo: CubeExtendInfo * - * @param CubeExtendInfo[] $extendInfo + * @param CubeExtendInfoModel[] $extendInfo */ public function setExtendInfo(array $extendInfo) { diff --git a/src/Cube/Apis/GetCubeMetricsRequest.php b/src/Cube/Apis/GetCubeMetricsRequest.php index 09ae1bf2..7fb24c47 100644 --- a/src/Cube/Apis/GetCubeMetricsRequest.php +++ b/src/Cube/Apis/GetCubeMetricsRequest.php @@ -1,6 +1,7 @@ markRequired("ContainerName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -49,11 +50,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -69,11 +69,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -89,11 +88,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ResourceId: Cube实例资源ID * @@ -109,11 +107,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * MetricName: 监控指标名称 * @@ -133,7 +130,6 @@ public function setMetricName(array $metricName) { $this->set("MetricName", $metricName); } - /** * BeginTime: 开始时间 * @@ -149,11 +145,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 结束时间,必须大于开始时间 * @@ -169,11 +164,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * ContainerName: Pod内容器名称 * @@ -189,7 +183,7 @@ public function getContainerName() * * @param string $containerName */ - public function setContainerName($containerName) + public function setContainerName(string $containerName) { $this->set("ContainerName", $containerName); } diff --git a/src/Cube/Apis/GetCubeMetricsResponse.php b/src/Cube/Apis/GetCubeMetricsResponse.php index ac9609a6..f72dbd8d 100644 --- a/src/Cube/Apis/GetCubeMetricsResponse.php +++ b/src/Cube/Apis/GetCubeMetricsResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new MetricDataSet($item)); + array_push($result, new MetricDataSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSets() /** * DataSets: 时间序列集合 * - * @param MetricDataSet[] $dataSets + * @param MetricDataSetModel[] $dataSets */ public function setDataSets(array $dataSets) { diff --git a/src/Cube/Apis/GetCubePodRequest.php b/src/Cube/Apis/GetCubePodRequest.php index c6a80299..151139ea 100644 --- a/src/Cube/Apis/GetCubePodRequest.php +++ b/src/Cube/Apis/GetCubePodRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CubeId: CubeId和Uid任意一个 * @@ -104,11 +102,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Uid: CubeId和Uid任意一个 * @@ -124,7 +121,7 @@ public function getUid() * * @param string $uid */ - public function setUid($uid) + public function setUid(string $uid) { $this->set("Uid", $uid); } diff --git a/src/Cube/Apis/GetCubePodResponse.php b/src/Cube/Apis/GetCubePodResponse.php index 0eec8dda..10b3daf6 100644 --- a/src/Cube/Apis/GetCubePodResponse.php +++ b/src/Cube/Apis/GetCubePodResponse.php @@ -1,6 +1,7 @@ set("Pod", $pod); } diff --git a/src/Cube/Apis/GetCubePriceRequest.php b/src/Cube/Apis/GetCubePriceRequest.php index bb01ebe0..1ac44ecc 100644 --- a/src/Cube/Apis/GetCubePriceRequest.php +++ b/src/Cube/Apis/GetCubePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Quantity"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -49,11 +50,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -69,11 +69,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -89,11 +88,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Count: 购买数量 * @@ -109,11 +107,10 @@ public function getCount() * * @param string $count */ - public function setCount($count) + public function setCount(string $count) { $this->set("Count", $count); } - /** * Cpu: CPU 配置,单位为毫核,例如如 1 核则须输入 1000 * @@ -129,11 +126,10 @@ public function getCpu() * * @param string $cpu */ - public function setCpu($cpu) + public function setCpu(string $cpu) { $this->set("Cpu", $cpu); } - /** * Mem: 内存配置,单位为 Mi,例如 1Gi 须输入 1024 * @@ -149,11 +145,10 @@ public function getMem() * * @param string $mem */ - public function setMem($mem) + public function setMem(string $mem) { $this->set("Mem", $mem); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按秒后付费,默认为月付 * @@ -169,11 +164,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长。默认:值 1。按小时购买(Dynamic/Postpay)时无需此参数。 月付时,此参数传0,代表购买至月末。 * @@ -189,7 +183,7 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } diff --git a/src/Cube/Apis/GetCubePriceResponse.php b/src/Cube/Apis/GetCubePriceResponse.php index 2cdbf808..acb024bf 100644 --- a/src/Cube/Apis/GetCubePriceResponse.php +++ b/src/Cube/Apis/GetCubePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } - /** * OriginalPrice: 列表价格,单位为分 * @@ -57,7 +57,7 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/Cube/Apis/GetCubeTokenRequest.php b/src/Cube/Apis/GetCubeTokenRequest.php index d4d8c8b6..ec55eee3 100644 --- a/src/Cube/Apis/GetCubeTokenRequest.php +++ b/src/Cube/Apis/GetCubeTokenRequest.php @@ -1,6 +1,7 @@ markRequired("ContainerName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ContainerName: 容器名称 * @@ -105,11 +103,10 @@ public function getContainerName() * * @param string $containerName */ - public function setContainerName($containerName) + public function setContainerName(string $containerName) { $this->set("ContainerName", $containerName); } - /** * CubeId: CubeId 和 Uid 中必须填写任意一个。CubeId 是所有 Cube 资源的唯一 ID,如非在 UK8S 通过 Virtual Kubelet 插件创建的 Cube, 则必填 CubeId * @@ -125,11 +122,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Uid: CubeId 和 Uid 中必须填写任意一个。Uid 是在 UK8S 中通过 Virtual Kubelet 插件创建出的 Cube 的唯一标识 * @@ -145,7 +141,7 @@ public function getUid() * * @param string $uid */ - public function setUid($uid) + public function setUid(string $uid) { $this->set("Uid", $uid); } diff --git a/src/Cube/Apis/GetCubeTokenResponse.php b/src/Cube/Apis/GetCubeTokenResponse.php index fb29c0ce..38932649 100644 --- a/src/Cube/Apis/GetCubeTokenResponse.php +++ b/src/Cube/Apis/GetCubeTokenResponse.php @@ -1,6 +1,7 @@ set("Token", $token); } diff --git a/src/Cube/Apis/ListCubeDeploymentRequest.php b/src/Cube/Apis/ListCubeDeploymentRequest.php index a17b1e2d..201aa8f8 100644 --- a/src/Cube/Apis/ListCubeDeploymentRequest.php +++ b/src/Cube/Apis/ListCubeDeploymentRequest.php @@ -1,6 +1,7 @@ markRequired("Limit"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 默认0 * @@ -105,11 +103,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 默认20 * @@ -125,7 +122,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/Cube/Apis/ListCubeDeploymentResponse.php b/src/Cube/Apis/ListCubeDeploymentResponse.php index 3c3a4491..0923e021 100644 --- a/src/Cube/Apis/ListCubeDeploymentResponse.php +++ b/src/Cube/Apis/ListCubeDeploymentResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * Deployments: DeploymentInfo * diff --git a/src/Cube/Apis/ListCubePodRequest.php b/src/Cube/Apis/ListCubePodRequest.php index 7ad09291..db1b2e89 100644 --- a/src/Cube/Apis/ListCubePodRequest.php +++ b/src/Cube/Apis/ListCubePodRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPC的Id * @@ -103,11 +101,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网Id * @@ -123,11 +120,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Group: 组名称 * @@ -143,11 +139,10 @@ public function getGroup() * * @param string $group */ - public function setGroup($group) + public function setGroup(string $group) { $this->set("Group", $group); } - /** * Offset: 默认0 * @@ -163,11 +158,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 默认20 * @@ -183,11 +177,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * DeploymentId: Deployment的Id * @@ -203,7 +196,7 @@ public function getDeploymentId() * * @param string $deploymentId */ - public function setDeploymentId($deploymentId) + public function setDeploymentId(string $deploymentId) { $this->set("DeploymentId", $deploymentId); } diff --git a/src/Cube/Apis/ListCubePodResponse.php b/src/Cube/Apis/ListCubePodResponse.php index 108b6f02..535bf34b 100644 --- a/src/Cube/Apis/ListCubePodResponse.php +++ b/src/Cube/Apis/ListCubePodResponse.php @@ -1,6 +1,7 @@ set("Pods", $pods); } - /** * TotalCount: Cube的总数 * @@ -57,7 +57,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/Cube/Apis/ModifyCubeExtendInfoRequest.php b/src/Cube/Apis/ModifyCubeExtendInfoRequest.php index 01fd2f32..5f0b68ae 100644 --- a/src/Cube/Apis/ModifyCubeExtendInfoRequest.php +++ b/src/Cube/Apis/ModifyCubeExtendInfoRequest.php @@ -1,6 +1,7 @@ markRequired("CubeId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CubeId: cube的id * @@ -105,11 +103,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Name: 修改的名字,规则(^[a-zA-Z0-9-_.\u4e00-\u9fa5]{1,32}) * @@ -125,7 +122,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/Cube/Apis/ModifyCubeExtendInfoResponse.php b/src/Cube/Apis/ModifyCubeExtendInfoResponse.php index 449e8f1c..0a969c69 100644 --- a/src/Cube/Apis/ModifyCubeExtendInfoResponse.php +++ b/src/Cube/Apis/ModifyCubeExtendInfoResponse.php @@ -1,6 +1,7 @@ markRequired("Tag"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CubeId: CubeId * @@ -105,11 +103,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Tag: 业务组名称 * @@ -125,7 +122,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/Cube/Apis/ModifyCubeTagResponse.php b/src/Cube/Apis/ModifyCubeTagResponse.php index 14035bff..81804e4c 100644 --- a/src/Cube/Apis/ModifyCubeTagResponse.php +++ b/src/Cube/Apis/ModifyCubeTagResponse.php @@ -1,6 +1,7 @@ set("CubeId", $cubeId); } diff --git a/src/Cube/Apis/RebootCubePodRequest.php b/src/Cube/Apis/RebootCubePodRequest.php new file mode 100644 index 00000000..dd0e69af --- /dev/null +++ b/src/Cube/Apis/RebootCubePodRequest.php @@ -0,0 +1,109 @@ + "RebootCubePod"]); + $this->markRequired("Region"); + $this->markRequired("CubeId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * CubeId: cube资源id(cube-xxxxxx) + * + * @return string|null + */ + public function getCubeId() + { + return $this->get("CubeId"); + } + + /** + * CubeId: cube资源id(cube-xxxxxx) + * + * @param string $cubeId + */ + public function setCubeId(string $cubeId) + { + $this->set("CubeId", $cubeId); + } +} diff --git a/src/UHost/Params/CreateUHostInstanceParamVolumes.php b/src/Cube/Apis/RebootCubePodResponse.php similarity index 77% rename from src/UHost/Params/CreateUHostInstanceParamVolumes.php rename to src/Cube/Apis/RebootCubePodResponse.php index 826ad819..8aba9489 100644 --- a/src/UHost/Params/CreateUHostInstanceParamVolumes.php +++ b/src/Cube/Apis/RebootCubePodResponse.php @@ -1,6 +1,7 @@ markRequired("Pod"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CubeId: 容器Id * @@ -106,11 +104,10 @@ public function getCubeId() * * @param string $cubeId */ - public function setCubeId($cubeId) + public function setCubeId(string $cubeId) { $this->set("CubeId", $cubeId); } - /** * Pod: base64编码的Pod的yaml * @@ -126,7 +123,7 @@ public function getPod() * * @param string $pod */ - public function setPod($pod) + public function setPod(string $pod) { $this->set("Pod", $pod); } diff --git a/src/Cube/Apis/RenewCubePodResponse.php b/src/Cube/Apis/RenewCubePodResponse.php index 87f967cd..4f4d87e1 100644 --- a/src/Cube/Apis/RenewCubePodResponse.php +++ b/src/Cube/Apis/RenewCubePodResponse.php @@ -1,6 +1,7 @@ set("Pod", $pod); } diff --git a/src/Cube/Apis/UpdateCubeDeploymentRequest.php b/src/Cube/Apis/UpdateCubeDeploymentRequest.php index 630f7db0..b1c14452 100644 --- a/src/Cube/Apis/UpdateCubeDeploymentRequest.php +++ b/src/Cube/Apis/UpdateCubeDeploymentRequest.php @@ -1,6 +1,7 @@ markRequired("Deployment"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DeploymentId: Deployment的Id * @@ -105,11 +103,10 @@ public function getDeploymentId() * * @param string $deploymentId */ - public function setDeploymentId($deploymentId) + public function setDeploymentId(string $deploymentId) { $this->set("DeploymentId", $deploymentId); } - /** * Deployment: base64编码的Deployment的yaml。大小不超过16KB * @@ -125,11 +122,10 @@ public function getDeployment() * * @param string $deployment */ - public function setDeployment($deployment) + public function setDeployment(string $deployment) { $this->set("Deployment", $deployment); } - /** * Name: Deployment的name * @@ -145,7 +141,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/Cube/Apis/UpdateCubeDeploymentResponse.php b/src/Cube/Apis/UpdateCubeDeploymentResponse.php index cf691d6c..3611e409 100644 --- a/src/Cube/Apis/UpdateCubeDeploymentResponse.php +++ b/src/Cube/Apis/UpdateCubeDeploymentResponse.php @@ -1,6 +1,7 @@ set("Deployment", $deployment); } diff --git a/src/Cube/CubeClient.php b/src/Cube/CubeClient.php index 5013de1a..9e3ecbe1 100644 --- a/src/Cube/CubeClient.php +++ b/src/Cube/CubeClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "VPCId" => (string) VPCId - * "SubnetId" => (string) 子网Id - * "Deployment" => (string) base64编码的Deployment的yaml。大小不超过16KB - * "Name" => (string) Deployment名称 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Postpay, \\ 后付费;默认为后付费 - * "CpuPlatform" => (string) Cpu平台(V6:Intel、A2:AMD),默认V6。支持的地域(北京2B、北京2E、上海2A、广东、香港 、东京)目前北京2E仅有A2,其余地域仅有V6 - * "KubeConfig" => (string) base64编码的kubeconfig。大小不超过16KB - * "Quantity" => (integer) 购买时长。默认:值 1。 月付时,此参数传0,代表购买至月末。 - * "Tag" => (string) 业务组。默认:Default(Default即为未分组) - * ] - * - * Outputs: - * - * $outputs = [ - * "DeploymentId" => (string) 控制器ID - * "Deployment" => (string) 经过base64编码的Deployment的yaml - * ] - * - * @return CreateCubeDeploymentResponse * @throws UCloudException */ public function createCubeDeployment(CreateCubeDeploymentRequest $request = null) @@ -96,39 +131,13 @@ public function createCubeDeployment(CreateCubeDeploymentRequest $request = null $resp = $this->invoke($request); return new CreateCubeDeploymentResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateCubePod - 创建Pod * - * See also: https://docs.ucloud.cn/api/cube-api/create_cube_pod - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "VPCId" => (string) VPCId - * "SubnetId" => (string) 子网Id - * "Pod" => (string) base64编码的Pod的yaml。大小不超过16KB - * "Group" => (string) pod所在组 - * "Name" => (string) pod的名字 - * "Tag" => (string) 业务组。默认:Default(Default即为未分组) - * "CpuPlatform" => (string) Cpu平台(V6:Intel、A2:AMD、Auto),默认Auto。支持的地域(北京2B、北京2E、上海2A、广东、香港 、东京)目前北京2E仅有A2,其余地域仅有V6 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Postpay, \\ 后付费;默认为后付费 - * "Quantity" => (integer) 购买时长。默认:值 1。 月付时,此参数传0,代表购买至月末。 - * "KubeConfig" => (string) base64编码的kubeconfig。大小不超过16KB - * "CouponId" => (string) 代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看 - * ] - * - * Outputs: - * - * $outputs = [ - * "Pod" => (string) base64编码的yaml - * "CubeId" => (string) cube的资源Id - * ] - * - * @return CreateCubePodResponse * @throws UCloudException */ public function createCubePod(CreateCubePodRequest $request = null) @@ -136,27 +145,13 @@ public function createCubePod(CreateCubePodRequest $request = null) $resp = $this->invoke($request); return new CreateCubePodResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteCubeDeployment - 删除Cube的Deployment * - * See also: https://docs.ucloud.cn/api/cube-api/delete_cube_deployment - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DeploymentId" => (string) 控制器Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteCubeDeploymentResponse * @throws UCloudException */ public function deleteCubeDeployment(DeleteCubeDeploymentRequest $request = null) @@ -164,29 +159,13 @@ public function deleteCubeDeployment(DeleteCubeDeploymentRequest $request = null $resp = $this->invoke($request); return new DeleteCubeDeploymentResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteCubePod - 删除Pod * - * See also: https://docs.ucloud.cn/api/cube-api/delete_cube_pod - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Uid" => (string) cubeid和uid任意一个(必须) - * "CubeId" => (string) cubeid和uid任意一个(必须) - * "ReleaseEIP" => (boolean) 删除cube时是否释放绑定的EIP。默认为false。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteCubePodResponse * @throws UCloudException */ public function deleteCubePod(DeleteCubePodRequest $request = null) @@ -194,28 +173,13 @@ public function deleteCubePod(DeleteCubePodRequest $request = null) $resp = $this->invoke($request); return new DeleteCubePodResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubeDeployment - 获取Deployment的详细信息 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_deployment - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DeploymentId" => (string) Deployment的Id - * ] - * - * Outputs: - * - * $outputs = [ - * "Deployment" => (string) 经过base64编码的Deployment的yaml - * ] - * - * @return GetCubeDeploymentResponse * @throws UCloudException */ public function getCubeDeployment(GetCubeDeploymentRequest $request = null) @@ -223,31 +187,13 @@ public function getCubeDeployment(GetCubeDeploymentRequest $request = null) $resp = $this->invoke($request); return new GetCubeDeploymentResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubeExecToken - 获取登录容器的token * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_exec_token - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ContainerName" => (string) 容器名称 - * "CubeId" => (string) CubeId 和 Uid 中必须填写任意一个。CubeId 是所有 Cube 资源的唯一 ID,如非在 UK8S 通过 Virtual Kubelet 插件创建的 Cube, 则必填 CubeId - * "Uid" => (string) CubeId 和 Uid 中必须填写任意一个。Uid 是在 UK8S 中通过 Virtual Kubelet 插件创建出的 Cube 的唯一标识 - * ] - * - * Outputs: - * - * $outputs = [ - * "Token" => (string) 有效时间5min - * "TerminalUrl" => (string) terminal的登录连接地址,限单点登录,有效时间5min - * ] - * - * @return GetCubeExecTokenResponse * @throws UCloudException */ public function getCubeExecToken(GetCubeExecTokenRequest $request = null) @@ -255,53 +201,13 @@ public function getCubeExecToken(GetCubeExecTokenRequest $request = null) $resp = $this->invoke($request); return new GetCubeExecTokenResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubeExtendInfo - 获取Cube的额外信息 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_extend_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "CubeIds" => (string) id列表以逗号(,)分割 - * ] - * - * Outputs: - * - * $outputs = [ - * "ExtendInfo" => (array) CubeExtendInfo[ - * [ - * "CubeId" => (string) Cube的Id - * "Name" => (string) Cube的名称 - * "Eip" => (array) EIPSet[ - * [ - * "Bandwidth" => (integer) EIP带宽值 - * "BandwidthType" => (integer) 带宽类型0标准普通带宽,1表示共享带宽 - * "CreateTime" => (integer) EIP创建时间 - * "EIPAddr" => (array) EIP地址[ - * [ - * "IP" => (string) IP地址 - * "OperatorName" => (string) 线路名称BGP或者internalation - * ] - * ] - * "EIPId" => (string) EIPId - * "PayMode" => (string) 付费模式,带宽付费或者流量付费 - * "Resource" => (string) EIP绑定对象的资源Id - * "Status" => (string) EIP状态,表示使用中或者空闲 - * "Weight" => (integer) EIP权重 - * ] - * ] - * "Expiration" => (integer) 资源有效期 - * "Tag" => (string) 业务组名称 - * ] - * ] - * ] - * - * @return GetCubeExtendInfoResponse * @throws UCloudException */ public function getCubeExtendInfo(GetCubeExtendInfoRequest $request = null) @@ -309,42 +215,13 @@ public function getCubeExtendInfo(GetCubeExtendInfoRequest $request = null) $resp = $this->invoke($request); return new GetCubeExtendInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubeMetrics - 获取Cube实例(Pod,PodX,Deploy等)监控数据时间序列 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_metrics - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ResourceId" => (string) Cube实例资源ID - * "MetricName" => (array) 监控指标名称 - * "BeginTime" => (integer) 开始时间 - * "EndTime" => (integer) 结束时间,必须大于开始时间 - * "ContainerName" => (string) Pod内容器名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSets" => (array) 时间序列集合[ - * [ - * "MetricName" => (string) - * "Values" => (array) [ - * [ - * "Value" => (number) - * "Timestamp" => (integer) - * ] - * ] - * ] - * ] - * ] - * - * @return GetCubeMetricsResponse * @throws UCloudException */ public function getCubeMetrics(GetCubeMetricsRequest $request = null) @@ -352,29 +229,13 @@ public function getCubeMetrics(GetCubeMetricsRequest $request = null) $resp = $this->invoke($request); return new GetCubeMetricsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubePod - 获取Pod的详细信息 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_pod - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "CubeId" => (string) CubeId和Uid任意一个 - * "Uid" => (string) CubeId和Uid任意一个 - * ] - * - * Outputs: - * - * $outputs = [ - * "Pod" => (string) base64编码的pod的yaml - * ] - * - * @return GetCubePodResponse * @throws UCloudException */ public function getCubePod(GetCubePodRequest $request = null) @@ -382,33 +243,13 @@ public function getCubePod(GetCubePodRequest $request = null) $resp = $this->invoke($request); return new GetCubePodResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubePrice - 获取cube的价格 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Count" => (string) 购买数量 - * "Cpu" => (string) CPU 配置,单位为毫核,例如如 1 核则须输入 1000 - * "Mem" => (string) 内存配置,单位为 Mi,例如 1Gi 须输入 1024 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按秒后付费,默认为月付 - * "Quantity" => (integer) 购买时长。默认:值 1。按小时购买(Dynamic/Postpay)时无需此参数。 月付时,此参数传0,代表购买至月末。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (integer) 折扣后价格,单位为分 - * "OriginalPrice" => (integer) 列表价格,单位为分 - * ] - * - * @return GetCubePriceResponse * @throws UCloudException */ public function getCubePrice(GetCubePriceRequest $request = null) @@ -416,30 +257,13 @@ public function getCubePrice(GetCubePriceRequest $request = null) $resp = $this->invoke($request); return new GetCubePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCubeToken - 获取Cube的token,可用于terminal登录、log获取 * - * See also: https://docs.ucloud.cn/api/cube-api/get_cube_token - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ContainerName" => (string) 容器名称 - * "CubeId" => (string) CubeId 和 Uid 中必须填写任意一个。CubeId 是所有 Cube 资源的唯一 ID,如非在 UK8S 通过 Virtual Kubelet 插件创建的 Cube, 则必填 CubeId - * "Uid" => (string) CubeId 和 Uid 中必须填写任意一个。Uid 是在 UK8S 中通过 Virtual Kubelet 插件创建出的 Cube 的唯一标识 - * ] - * - * Outputs: - * - * $outputs = [ - * "Token" => (string) 有效时间5min - * ] - * - * @return GetCubeTokenResponse * @throws UCloudException */ public function getCubeToken(GetCubeTokenRequest $request = null) @@ -447,30 +271,13 @@ public function getCubeToken(GetCubeTokenRequest $request = null) $resp = $this->invoke($request); return new GetCubeTokenResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ListCubeDeployment - 获取Cube的Deployment列表 * - * See also: https://docs.ucloud.cn/api/cube-api/list_cube_deployment - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 默认0 - * "Limit" => (integer) 默认20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) - * "Deployments" => (array) DeploymentInfo - * ] - * - * @return ListCubeDeploymentResponse * @throws UCloudException */ public function listCubeDeployment(ListCubeDeploymentRequest $request = null) @@ -478,34 +285,13 @@ public function listCubeDeployment(ListCubeDeploymentRequest $request = null) $resp = $this->invoke($request); return new ListCubeDeploymentResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ListCubePod - 获取Pods列表 * - * See also: https://docs.ucloud.cn/api/cube-api/list_cube_pod - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "VPCId" => (string) VPC的Id - * "SubnetId" => (string) 子网Id - * "Group" => (string) 组名称 - * "Offset" => (integer) 默认0 - * "Limit" => (integer) 默认20 - * "DeploymentId" => (string) Deployment的Id - * ] - * - * Outputs: - * - * $outputs = [ - * "Pods" => (array) Pod列表,每条数据都做了base64编码 - * "TotalCount" => (integer) Cube的总数 - * ] - * - * @return ListCubePodResponse * @throws UCloudException */ public function listCubePod(ListCubePodRequest $request = null) @@ -513,28 +299,13 @@ public function listCubePod(ListCubePodRequest $request = null) $resp = $this->invoke($request); return new ListCubePodResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyCubeExtendInfo - 修改Cube额外信息 * - * See also: https://docs.ucloud.cn/api/cube-api/modify_cube_extend_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "CubeId" => (string) cube的id - * "Name" => (string) 修改的名字,规则(^[a-zA-Z0-9-_.\u4e00-\u9fa5]{1,32}) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyCubeExtendInfoResponse * @throws UCloudException */ public function modifyCubeExtendInfo(ModifyCubeExtendInfoRequest $request = null) @@ -542,29 +313,13 @@ public function modifyCubeExtendInfo(ModifyCubeExtendInfoRequest $request = null $resp = $this->invoke($request); return new ModifyCubeExtendInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyCubeTag - 修改业务组名字 * - * See also: https://docs.ucloud.cn/api/cube-api/modify_cube_tag - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "CubeId" => (string) CubeId - * "Tag" => (string) 业务组名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "CubeId" => (string) CubeId - * ] - * - * @return ModifyCubeTagResponse * @throws UCloudException */ public function modifyCubeTag(ModifyCubeTagRequest $request = null) @@ -572,29 +327,27 @@ public function modifyCubeTag(ModifyCubeTagRequest $request = null) $resp = $this->invoke($request); return new ModifyCubeTagResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * RenewCubePod - 更新Pod - * - * See also: https://docs.ucloud.cn/api/cube-api/renew_cube_pod - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "CubeId" => (string) 容器Id - * "Pod" => (string) base64编码的Pod的yaml - * ] + * RebootCubePod - 重启Cube Pod * - * Outputs: - * - * $outputs = [ - * "Pod" => (string) base64编码过的yaml,需要解码获取信息 - * ] + * @throws UCloudException + */ + public function rebootCubePod(RebootCubePodRequest $request = null) + { + $resp = $this->invoke($request); + return new RebootCubePodResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * RenewCubePod - 更新Pod * - * @return RenewCubePodResponse * @throws UCloudException */ public function renewCubePod(RenewCubePodRequest $request = null) @@ -602,30 +355,13 @@ public function renewCubePod(RenewCubePodRequest $request = null) $resp = $this->invoke($request); return new RenewCubePodResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateCubeDeployment - 更新Deployment * - * See also: https://docs.ucloud.cn/api/cube-api/update_cube_deployment - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DeploymentId" => (string) Deployment的Id - * "Deployment" => (string) base64编码的Deployment的yaml。大小不超过16KB - * "Name" => (string) Deployment的name - * ] - * - * Outputs: - * - * $outputs = [ - * "Deployment" => (string) 经过base64编码的Deployment的yaml - * ] - * - * @return UpdateCubeDeploymentResponse * @throws UCloudException */ public function updateCubeDeployment(UpdateCubeDeploymentRequest $request = null) diff --git a/src/Cube/Models/CubeExtendInfo.php b/src/Cube/Models/CubeExtendInfo.php index 21df5e42..ce2ee7e1 100644 --- a/src/Cube/Models/CubeExtendInfo.php +++ b/src/Cube/Models/CubeExtendInfo.php @@ -1,6 +1,7 @@ set("CubeId", $cubeId); } - /** * Name: Cube的名称 * @@ -57,15 +61,14 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Eip: EIPSet * - * @return EIPSet[]|null + * @return EIPSetModel[]|null */ public function getEip() { @@ -75,7 +78,7 @@ public function getEip() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EIPSet($item)); + array_push($result, new EIPSetModel($item)); } return $result; } @@ -83,7 +86,7 @@ public function getEip() /** * Eip: EIPSet * - * @param EIPSet[] $eip + * @param EIPSetModel[] $eip */ public function setEip(array $eip) { @@ -93,7 +96,6 @@ public function setEip(array $eip) } return $result; } - /** * Expiration: 资源有效期 * @@ -109,11 +111,10 @@ public function getExpiration() * * @param int $expiration */ - public function setExpiration($expiration) + public function setExpiration(int $expiration) { $this->set("Expiration", $expiration); } - /** * Tag: 业务组名称 * @@ -129,7 +130,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/Cube/Models/EIPAddr.php b/src/Cube/Models/EIPAddr.php index 8fcd2a05..bbe266b4 100644 --- a/src/Cube/Models/EIPAddr.php +++ b/src/Cube/Models/EIPAddr.php @@ -1,6 +1,7 @@ set("IP", $ip); } - /** * OperatorName: 线路名称BGP或者internalation * @@ -57,7 +61,7 @@ public function getOperatorName() * * @param string $operatorName */ - public function setOperatorName($operatorName) + public function setOperatorName(string $operatorName) { $this->set("OperatorName", $operatorName); } diff --git a/src/Cube/Models/EIPSet.php b/src/Cube/Models/EIPSet.php index 69d4a015..c8097ec0 100644 --- a/src/Cube/Models/EIPSet.php +++ b/src/Cube/Models/EIPSet.php @@ -1,6 +1,7 @@ set("Bandwidth", $bandwidth); } - /** * BandwidthType: 带宽类型0标准普通带宽,1表示共享带宽 * @@ -57,11 +61,10 @@ public function getBandwidthType() * * @param int $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(int $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * CreateTime: EIP创建时间 * @@ -77,15 +80,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * EIPAddr: EIP地址 * - * @return EIPAddr[]|null + * @return EIPAddrModel[]|null */ public function getEIPAddr() { @@ -95,7 +97,7 @@ public function getEIPAddr() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EIPAddr($item)); + array_push($result, new EIPAddrModel($item)); } return $result; } @@ -103,7 +105,7 @@ public function getEIPAddr() /** * EIPAddr: EIP地址 * - * @param EIPAddr[] $eipAddr + * @param EIPAddrModel[] $eipAddr */ public function setEIPAddr(array $eipAddr) { @@ -113,7 +115,6 @@ public function setEIPAddr(array $eipAddr) } return $result; } - /** * EIPId: EIPId * @@ -129,11 +130,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * PayMode: 付费模式,带宽付费或者流量付费 * @@ -149,11 +149,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * Resource: EIP绑定对象的资源Id * @@ -169,11 +168,10 @@ public function getResource() * * @param string $resource */ - public function setResource($resource) + public function setResource(string $resource) { $this->set("Resource", $resource); } - /** * Status: EIP状态,表示使用中或者空闲 * @@ -189,11 +187,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * Weight: EIP权重 * @@ -209,7 +206,7 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } diff --git a/src/Cube/Models/MetricDataSet.php b/src/Cube/Models/MetricDataSet.php index ba37b4af..2705f8a0 100644 --- a/src/Cube/Models/MetricDataSet.php +++ b/src/Cube/Models/MetricDataSet.php @@ -1,6 +1,7 @@ set("MetricName", $metricName); } - /** * Values: * - * @return ValueSet[]|null + * @return ValueSetModel[]|null */ public function getValues() { @@ -55,7 +58,7 @@ public function getValues() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ValueSet($item)); + array_push($result, new ValueSetModel($item)); } return $result; } @@ -63,7 +66,7 @@ public function getValues() /** * Values: * - * @param ValueSet[] $values + * @param ValueSetModel[] $values */ public function setValues(array $values) { diff --git a/src/Cube/Models/ValueSet.php b/src/Cube/Models/ValueSet.php index 61339163..05767d2c 100644 --- a/src/Cube/Models/ValueSet.php +++ b/src/Cube/Models/ValueSet.php @@ -1,6 +1,7 @@ set("Value", $value); } - /** * Timestamp: * @@ -57,7 +60,7 @@ public function getTimestamp() * * @param int $timestamp */ - public function setTimestamp($timestamp) + public function setTimestamp(int $timestamp) { $this->set("Timestamp", $timestamp); } diff --git a/src/IPSecVPN/Apis/CreateRemoteVPNGatewayRequest.php b/src/IPSecVPN/Apis/CreateRemoteVPNGatewayRequest.php index c1e273f5..45b78aff 100644 --- a/src/IPSecVPN/Apis/CreateRemoteVPNGatewayRequest.php +++ b/src/IPSecVPN/Apis/CreateRemoteVPNGatewayRequest.php @@ -1,6 +1,7 @@ markRequired("RemoteVPNGatewayAddr"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RemoteVPNGatewayName: 客户VPN网关名称 * @@ -86,11 +85,10 @@ public function getRemoteVPNGatewayName() * * @param string $remoteVPNGatewayName */ - public function setRemoteVPNGatewayName($remoteVPNGatewayName) + public function setRemoteVPNGatewayName(string $remoteVPNGatewayName) { $this->set("RemoteVPNGatewayName", $remoteVPNGatewayName); } - /** * RemoteVPNGatewayAddr: 客户VPN网关地址 * @@ -106,11 +104,10 @@ public function getRemoteVPNGatewayAddr() * * @param string $remoteVPNGatewayAddr */ - public function setRemoteVPNGatewayAddr($remoteVPNGatewayAddr) + public function setRemoteVPNGatewayAddr(string $remoteVPNGatewayAddr) { $this->set("RemoteVPNGatewayAddr", $remoteVPNGatewayAddr); } - /** * Tag: 业务组名称,默认为 "Default" * @@ -126,11 +123,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注,默认为空 * @@ -146,7 +142,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/IPSecVPN/Apis/CreateRemoteVPNGatewayResponse.php b/src/IPSecVPN/Apis/CreateRemoteVPNGatewayResponse.php index e7e03dc7..215d9397 100644 --- a/src/IPSecVPN/Apis/CreateRemoteVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/CreateRemoteVPNGatewayResponse.php @@ -1,6 +1,7 @@ set("RemoteVPNGatewayId", $remoteVPNGatewayId); } diff --git a/src/IPSecVPN/Apis/CreateVPNGatewayRequest.php b/src/IPSecVPN/Apis/CreateVPNGatewayRequest.php index e35d2758..2858a65c 100644 --- a/src/IPSecVPN/Apis/CreateVPNGatewayRequest.php +++ b/src/IPSecVPN/Apis/CreateVPNGatewayRequest.php @@ -1,6 +1,7 @@ markRequired("Grade"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNGatewayName: 新建VPN网关名称 * @@ -87,11 +86,10 @@ public function getVPNGatewayName() * * @param string $vpnGatewayName */ - public function setVPNGatewayName($vpnGatewayName) + public function setVPNGatewayName(string $vpnGatewayName) { $this->set("VPNGatewayName", $vpnGatewayName); } - /** * VPCId: 新建VPN网关所属VPC的资源ID * @@ -107,11 +105,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Grade: 购买的VPN网关规格,枚举值为: Standard, 标准型; Enhanced, 增强型 * @@ -127,11 +124,10 @@ public function getGrade() * * @param string $grade */ - public function setGrade($grade) + public function setGrade(string $grade) { $this->set("Grade", $grade); } - /** * Remark: 备注,默认为空 * @@ -147,11 +143,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组名称,默认为 "Default" * @@ -167,11 +162,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Quantity: 购买时长, 默认: 1 * @@ -187,11 +181,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费;Dynamic, 按需付费(需开启权限);Trial, 试用(需开启权限);默认为按月付费 * @@ -207,11 +200,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * BusinessId: 业务组ID * @@ -227,11 +219,10 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } - /** * EIPId: 若要绑定EIP,在此填上EIP的资源ID * @@ -247,11 +238,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * CouponId: 代金券ID, 默认不使用 * @@ -267,7 +257,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/IPSecVPN/Apis/CreateVPNGatewayResponse.php b/src/IPSecVPN/Apis/CreateVPNGatewayResponse.php index b5668314..974d3e26 100644 --- a/src/IPSecVPN/Apis/CreateVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/CreateVPNGatewayResponse.php @@ -1,6 +1,7 @@ set("VPNGatewayId", $vpnGatewayId); } diff --git a/src/IPSecVPN/Apis/CreateVPNTunnelRequest.php b/src/IPSecVPN/Apis/CreateVPNTunnelRequest.php index d3f066df..8f67fe22 100644 --- a/src/IPSecVPN/Apis/CreateVPNTunnelRequest.php +++ b/src/IPSecVPN/Apis/CreateVPNTunnelRequest.php @@ -1,6 +1,7 @@ markRequired("RemoteVPNGatewayId"); $this->markRequired("IKEPreSharedKey"); $this->markRequired("VPCId"); + $this->markRequired("IKEVersion"); $this->markRequired("IPSecLocalSubnetIds"); $this->markRequired("IPSecRemoteSubnets"); - $this->markRequired("IKEVersion"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -48,17 +49,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -68,15 +68,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNTunnelName: VPN隧道名称 * @@ -92,11 +91,10 @@ public function getVPNTunnelName() * * @param string $vpnTunnelName */ - public function setVPNTunnelName($vpnTunnelName) + public function setVPNTunnelName(string $vpnTunnelName) { $this->set("VPNTunnelName", $vpnTunnelName); } - /** * VPNGatewayId: VPN网关的资源ID * @@ -112,11 +110,10 @@ public function getVPNGatewayId() * * @param string $vpnGatewayId */ - public function setVPNGatewayId($vpnGatewayId) + public function setVPNGatewayId(string $vpnGatewayId) { $this->set("VPNGatewayId", $vpnGatewayId); } - /** * RemoteVPNGatewayId: 客户VPN网关的资源ID * @@ -132,11 +129,10 @@ public function getRemoteVPNGatewayId() * * @param string $remoteVPNGatewayId */ - public function setRemoteVPNGatewayId($remoteVPNGatewayId) + public function setRemoteVPNGatewayId(string $remoteVPNGatewayId) { $this->set("RemoteVPNGatewayId", $remoteVPNGatewayId); } - /** * IKEPreSharedKey: 预共享密钥 * @@ -152,11 +148,10 @@ public function getIKEPreSharedKey() * * @param string $ikePreSharedKey */ - public function setIKEPreSharedKey($ikePreSharedKey) + public function setIKEPreSharedKey(string $ikePreSharedKey) { $this->set("IKEPreSharedKey", $ikePreSharedKey); } - /** * VPCId: vpcId * @@ -172,11 +167,29 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } + /** + * IKEVersion: ike版本,枚举值: "IKE V1","IKE V2",默认v1 + * + * @return string|null + */ + public function getIKEVersion() + { + return $this->get("IKEVersion"); + } + /** + * IKEVersion: ike版本,枚举值: "IKE V1","IKE V2",默认v1 + * + * @param string $ikeVersion + */ + public function setIKEVersion(string $ikeVersion) + { + $this->set("IKEVersion", $ikeVersion); + } /** * IPSecLocalSubnetIds: 指定VPN连接的本地子网的资源ID,最多可填写10个。 * @@ -196,7 +209,6 @@ public function setIPSecLocalSubnetIds(array $ipSecLocalSubnetIds) { $this->set("IPSecLocalSubnetIds", $ipSecLocalSubnetIds); } - /** * IPSecRemoteSubnets: 指定VPN连接的客户网段,最多可填写20个。 * @@ -216,27 +228,6 @@ public function setIPSecRemoteSubnets(array $ipSecRemoteSubnets) { $this->set("IPSecRemoteSubnets", $ipSecRemoteSubnets); } - - /** - * IKEVersion: ike版本,枚举值: "IKE V1","IKE V2",默认v1 - * - * @return string|null - */ - public function getIKEVersion() - { - return $this->get("IKEVersion"); - } - - /** - * IKEVersion: ike版本,枚举值: "IKE V1","IKE V2",默认v1 - * - * @param string $ikeVersion - */ - public function setIKEVersion($ikeVersion) - { - $this->set("IKEVersion", $ikeVersion); - } - /** * Tag: 业务组,默认为“Default” * @@ -252,11 +243,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注,默认为空 * @@ -272,11 +262,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * IKEEncryptionAlgorithm: IKE协商过程中使用的加密算法,枚举值,"aes128", "aes192", "aes256", "aes512", "3des"。默认值为“aes128” * @@ -292,11 +281,10 @@ public function getIKEEncryptionAlgorithm() * * @param string $ikeEncryptionAlgorithm */ - public function setIKEEncryptionAlgorithm($ikeEncryptionAlgorithm) + public function setIKEEncryptionAlgorithm(string $ikeEncryptionAlgorithm) { $this->set("IKEEncryptionAlgorithm", $ikeEncryptionAlgorithm); } - /** * IKEAuthenticationAlgorithm: IKE协商过程中使用的认证算法,"md5", "sha1", "sha2-256"。默认值为“sha1” * @@ -312,11 +300,10 @@ public function getIKEAuthenticationAlgorithm() * * @param string $ikeAuthenticationAlgorithm */ - public function setIKEAuthenticationAlgorithm($ikeAuthenticationAlgorithm) + public function setIKEAuthenticationAlgorithm(string $ikeAuthenticationAlgorithm) { $this->set("IKEAuthenticationAlgorithm", $ikeAuthenticationAlgorithm); } - /** * IKEExchangeMode: IKE协商过程中使用的模式,枚举值,主模式,“main”;野蛮模式,“aggressive”。IKEV1默认为主模式“main”,IKEV2时不使用该参数。 * @@ -332,11 +319,10 @@ public function getIKEExchangeMode() * * @param string $ikeExchangeMode */ - public function setIKEExchangeMode($ikeExchangeMode) + public function setIKEExchangeMode(string $ikeExchangeMode) { $this->set("IKEExchangeMode", $ikeExchangeMode); } - /** * IKELocalId: 本端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为自动识别“auto”。IKEV2必填该参数 * @@ -352,11 +338,10 @@ public function getIKELocalId() * * @param string $ikeLocalId */ - public function setIKELocalId($ikeLocalId) + public function setIKELocalId(string $ikeLocalId) { $this->set("IKELocalId", $ikeLocalId); } - /** * IKERemoteId: 客户端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为“自动识别“auto”。IKEV2必填该参数 * @@ -372,11 +357,10 @@ public function getIKERemoteId() * * @param string $ikeRemoteId */ - public function setIKERemoteId($ikeRemoteId) + public function setIKERemoteId(string $ikeRemoteId) { $this->set("IKERemoteId", $ikeRemoteId); } - /** * IKEDhGroup: IKE协商过程中使用的DH组,枚举值,"1", "2", "5", "14", "15", "16"。默认为“15” * @@ -392,11 +376,10 @@ public function getIKEDhGroup() * * @param string $ikeDhGroup */ - public function setIKEDhGroup($ikeDhGroup) + public function setIKEDhGroup(string $ikeDhGroup) { $this->set("IKEDhGroup", $ikeDhGroup); } - /** * IKESALifetime: IKE中SA的生存时间,可填写范围为600-604800。默认为86400。 * @@ -412,11 +395,10 @@ public function getIKESALifetime() * * @param string $ikesaLifetime */ - public function setIKESALifetime($ikesaLifetime) + public function setIKESALifetime(string $ikesaLifetime) { $this->set("IKESALifetime", $ikesaLifetime); } - /** * IPSecProtocol: 使用的安全协议,枚举值,“esp”,“ah”。默认为“esp” * @@ -432,11 +414,10 @@ public function getIPSecProtocol() * * @param string $ipSecProtocol */ - public function setIPSecProtocol($ipSecProtocol) + public function setIPSecProtocol(string $ipSecProtocol) { $this->set("IPSecProtocol", $ipSecProtocol); } - /** * IPSecEncryptionAlgorithm: IPSec隧道中使用的加密算法,枚举值,"aes128", "aes192", "aes256", "aes512", "3des"。默认值为“aes128” * @@ -452,13 +433,12 @@ public function getIPSecEncryptionAlgorithm() * * @param string $ipSecEncryptionAlgorithm */ - public function setIPSecEncryptionAlgorithm($ipSecEncryptionAlgorithm) + public function setIPSecEncryptionAlgorithm(string $ipSecEncryptionAlgorithm) { $this->set("IPSecEncryptionAlgorithm", $ipSecEncryptionAlgorithm); } - /** - * IPSecAuthenticationAlgorithm: IPSec隧道中使用的认证算法,枚举值,"md5", "sha1"。默认值为“sha1” + * IPSecAuthenticationAlgorithm: IPSec隧道中使用的认证算法,枚举值,"md5", "sha1","sha2-256"。默认值为“sha1” * * @return string|null */ @@ -468,15 +448,14 @@ public function getIPSecAuthenticationAlgorithm() } /** - * IPSecAuthenticationAlgorithm: IPSec隧道中使用的认证算法,枚举值,"md5", "sha1"。默认值为“sha1” + * IPSecAuthenticationAlgorithm: IPSec隧道中使用的认证算法,枚举值,"md5", "sha1","sha2-256"。默认值为“sha1” * * @param string $ipSecAuthenticationAlgorithm */ - public function setIPSecAuthenticationAlgorithm($ipSecAuthenticationAlgorithm) + public function setIPSecAuthenticationAlgorithm(string $ipSecAuthenticationAlgorithm) { $this->set("IPSecAuthenticationAlgorithm", $ipSecAuthenticationAlgorithm); } - /** * IPSecSALifetime: IPSec中SA的生存时间,可填写范围为1200 - 604800。默认为3600 * @@ -492,11 +471,10 @@ public function getIPSecSALifetime() * * @param string $ipSecSALifetime */ - public function setIPSecSALifetime($ipSecSALifetime) + public function setIPSecSALifetime(string $ipSecSALifetime) { $this->set("IPSecSALifetime", $ipSecSALifetime); } - /** * IPSecSALifetimeBytes: IPSec中SA的生存时间(以字节计)。可选为8000 – 20000000。默认使用SA生存时间, * @@ -512,11 +490,10 @@ public function getIPSecSALifetimeBytes() * * @param string $ipSecSALifetimeBytes */ - public function setIPSecSALifetimeBytes($ipSecSALifetimeBytes) + public function setIPSecSALifetimeBytes(string $ipSecSALifetimeBytes) { $this->set("IPSecSALifetimeBytes", $ipSecSALifetimeBytes); } - /** * IPSecPFSDhGroup: IPSec的PFS是否开启,枚举值,,不开启,"disable";数字表示DH组, "1", "2", "5", "14", "15", "16"。默认为“disable”。 * @@ -532,8 +509,27 @@ public function getIPSecPFSDhGroup() * * @param string $ipSecPFSDhGroup */ - public function setIPSecPFSDhGroup($ipSecPFSDhGroup) + public function setIPSecPFSDhGroup(string $ipSecPFSDhGroup) { $this->set("IPSecPFSDhGroup", $ipSecPFSDhGroup); } + /** + * IPSecCloseAction: IPSec隧道关闭后的处理动作,枚举值:“none”,流量触发;“restart”,自动重联,默认为none + * + * @return string|null + */ + public function getIPSecCloseAction() + { + return $this->get("IPSecCloseAction"); + } + + /** + * IPSecCloseAction: IPSec隧道关闭后的处理动作,枚举值:“none”,流量触发;“restart”,自动重联,默认为none + * + * @param string $ipSecCloseAction + */ + public function setIPSecCloseAction(string $ipSecCloseAction) + { + $this->set("IPSecCloseAction", $ipSecCloseAction); + } } diff --git a/src/IPSecVPN/Apis/CreateVPNTunnelResponse.php b/src/IPSecVPN/Apis/CreateVPNTunnelResponse.php index ad69857a..668c698e 100644 --- a/src/IPSecVPN/Apis/CreateVPNTunnelResponse.php +++ b/src/IPSecVPN/Apis/CreateVPNTunnelResponse.php @@ -1,6 +1,7 @@ set("VPNTunnelId", $vpnTunnelId); } diff --git a/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayRequest.php b/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayRequest.php index 0927282b..7ec56b94 100644 --- a/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayRequest.php +++ b/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayRequest.php @@ -1,6 +1,7 @@ markRequired("RemoteVPNGatewayId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RemoteVPNGatewayId: 客户VPN网关的资源ID * @@ -85,7 +84,7 @@ public function getRemoteVPNGatewayId() * * @param string $remoteVPNGatewayId */ - public function setRemoteVPNGatewayId($remoteVPNGatewayId) + public function setRemoteVPNGatewayId(string $remoteVPNGatewayId) { $this->set("RemoteVPNGatewayId", $remoteVPNGatewayId); } diff --git a/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayResponse.php b/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayResponse.php index 8659811f..4fce1ab9 100644 --- a/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/DeleteRemoteVPNGatewayResponse.php @@ -1,6 +1,7 @@ markRequired("VPNGatewayId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNGatewayId: VPN网关的资源ID * @@ -85,11 +84,10 @@ public function getVPNGatewayId() * * @param string $vpnGatewayId */ - public function setVPNGatewayId($vpnGatewayId) + public function setVPNGatewayId(string $vpnGatewayId) { $this->set("VPNGatewayId", $vpnGatewayId); } - /** * ReleaseEip: 删除VPN时是否一并释放EIP。false,只解绑EIP不删除EIP;true,解绑并释放EIP。默认是false * @@ -105,7 +103,7 @@ public function getReleaseEip() * * @param boolean $releaseEip */ - public function setReleaseEip($releaseEip) + public function setReleaseEip(bool $releaseEip) { $this->set("ReleaseEip", $releaseEip); } diff --git a/src/IPSecVPN/Apis/DeleteVPNGatewayResponse.php b/src/IPSecVPN/Apis/DeleteVPNGatewayResponse.php index 595a6296..ac35e0f9 100644 --- a/src/IPSecVPN/Apis/DeleteVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/DeleteVPNGatewayResponse.php @@ -1,6 +1,7 @@ markRequired("VPNTunnelId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNTunnelId: VPN隧道的资源ID * @@ -85,7 +84,7 @@ public function getVPNTunnelId() * * @param string $vpnTunnelId */ - public function setVPNTunnelId($vpnTunnelId) + public function setVPNTunnelId(string $vpnTunnelId) { $this->set("VPNTunnelId", $vpnTunnelId); } diff --git a/src/IPSecVPN/Apis/DeleteVPNTunnelResponse.php b/src/IPSecVPN/Apis/DeleteVPNTunnelResponse.php index 5c6a04a3..727d320d 100644 --- a/src/IPSecVPN/Apis/DeleteVPNTunnelResponse.php +++ b/src/IPSecVPN/Apis/DeleteVPNTunnelResponse.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RemoteVPNGatewayIds: 客户VPN网关的资源ID,例如RemoteVPNGatewayIds.0代表希望获取客户VPN网关1的信息,RemoteVPNGatewayIds.1代表客户VPN网关2,如果为空,则返回当前Region中所有客户VPN网关实例的信息 * @@ -88,7 +87,6 @@ public function setRemoteVPNGatewayIds(array $remoteVPNGatewayIds) { $this->set("RemoteVPNGatewayIds", $remoteVPNGatewayIds); } - /** * Tag: 业务组名称,若指定则返回业务组下所有客户VPN网关信息 * @@ -104,11 +102,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Offset: 数据偏移量, 默认为0 * @@ -124,11 +121,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -144,7 +140,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/IPSecVPN/Apis/DescribeRemoteVPNGatewayResponse.php b/src/IPSecVPN/Apis/DescribeRemoteVPNGatewayResponse.php index c62813a4..3d612a4d 100644 --- a/src/IPSecVPN/Apis/DescribeRemoteVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/DescribeRemoteVPNGatewayResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 客户VPN网关列表, 每项参数详见 RemoteVPNGatewayDataSet * - * @return RemoteVPNGatewayDataSet[]|null + * @return RemoteVPNGatewayDataSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new RemoteVPNGatewayDataSet($item)); + array_push($result, new RemoteVPNGatewayDataSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 客户VPN网关列表, 每项参数详见 RemoteVPNGatewayDataSet * - * @param RemoteVPNGatewayDataSet[] $dataSet + * @param RemoteVPNGatewayDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/IPSecVPN/Apis/DescribeVPNGatewayRequest.php b/src/IPSecVPN/Apis/DescribeVPNGatewayRequest.php index 507314b3..8e1e2e86 100644 --- a/src/IPSecVPN/Apis/DescribeVPNGatewayRequest.php +++ b/src/IPSecVPN/Apis/DescribeVPNGatewayRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNGatewayIds: VPN网关的资源ID,例如VPNGatewayIds.0代表希望获取VPN网关1的信息,VPNGatewayIds.1代表VPN网关2,如果为空,则返回当前Region中所有VPN网关的信息 * @@ -88,7 +87,6 @@ public function setVPNGatewayIds(array $vpnGatewayIds) { $this->set("VPNGatewayIds", $vpnGatewayIds); } - /** * VPCId: VPC的资源ID,返回指定的VPC下的所有VPN网关的信息。默认返回当前Region中所有VPN网关实例的信息 * @@ -104,11 +102,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Offset: 数据偏移量。默认为0 * @@ -124,11 +121,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Tag: 业务组名称,若指定则返回指定的业务组下的所有VPN网关的信息。 * @@ -144,11 +140,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Limit: 数据分页值。默认为20 * @@ -164,7 +159,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/IPSecVPN/Apis/DescribeVPNGatewayResponse.php b/src/IPSecVPN/Apis/DescribeVPNGatewayResponse.php index 9fb3392b..bd3d9f18 100644 --- a/src/IPSecVPN/Apis/DescribeVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/DescribeVPNGatewayResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 获取的VPN网关信息列表,每项参数详见 VPNGatewayDataSet * - * @return VPNGatewayDataSet[]|null + * @return VPNGatewayDataSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new VPNGatewayDataSet($item)); + array_push($result, new VPNGatewayDataSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 获取的VPN网关信息列表,每项参数详见 VPNGatewayDataSet * - * @param VPNGatewayDataSet[] $dataSet + * @param VPNGatewayDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/IPSecVPN/Apis/DescribeVPNTunnelRequest.php b/src/IPSecVPN/Apis/DescribeVPNTunnelRequest.php index 23942aff..c113e6db 100644 --- a/src/IPSecVPN/Apis/DescribeVPNTunnelRequest.php +++ b/src/IPSecVPN/Apis/DescribeVPNTunnelRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNTunnelIds: VPN隧道的资源ID,例如VPNTunnelIds.0代表希望获取信息的VPN隧道1,VPNTunneIds.1代表VPN隧道2,如果为空,则返回当前Region中所有的VPN隧道实例 * @@ -88,7 +87,6 @@ public function setVPNTunnelIds(array $vpnTunnelIds) { $this->set("VPNTunnelIds", $vpnTunnelIds); } - /** * Offset: 数据偏移量, 默认为0 * @@ -104,11 +102,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -124,11 +121,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Tag: 业务组名称,若指定则返回指定的业务组下的所有VPN网关的信息 * @@ -144,7 +140,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/IPSecVPN/Apis/DescribeVPNTunnelResponse.php b/src/IPSecVPN/Apis/DescribeVPNTunnelResponse.php index 22d90574..172d9dc0 100644 --- a/src/IPSecVPN/Apis/DescribeVPNTunnelResponse.php +++ b/src/IPSecVPN/Apis/DescribeVPNTunnelResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 获取的VPN隧道信息列表,每项参数详见 VPNTunnelDataSet * - * @return VPNTunnelDataSet[]|null + * @return VPNTunnelDataSetModel[]|null */ public function getDataSet() { @@ -58,7 +59,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new VPNTunnelDataSet($item)); + array_push($result, new VPNTunnelDataSetModel($item)); } return $result; } @@ -66,7 +67,7 @@ public function getDataSet() /** * DataSet: 获取的VPN隧道信息列表,每项参数详见 VPNTunnelDataSet * - * @param VPNTunnelDataSet[] $dataSet + * @param VPNTunnelDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/IPSecVPN/Apis/GetVPNGatewayPriceRequest.php b/src/IPSecVPN/Apis/GetVPNGatewayPriceRequest.php index 0599647f..d60c0394 100644 --- a/src/IPSecVPN/Apis/GetVPNGatewayPriceRequest.php +++ b/src/IPSecVPN/Apis/GetVPNGatewayPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Grade"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Grade: VPN网关规格。枚举值,包括:标准型:Standard,增强型:Enhanced。 * @@ -85,11 +84,10 @@ public function getGrade() * * @param string $grade */ - public function setGrade($grade) + public function setGrade(string $grade) { $this->set("Grade", $grade); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按需付费(需开启权限); 默认为获取三种价格 * @@ -105,11 +103,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长, 默认: 1 * @@ -125,7 +122,7 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } diff --git a/src/IPSecVPN/Apis/GetVPNGatewayPriceResponse.php b/src/IPSecVPN/Apis/GetVPNGatewayPriceResponse.php index 0b748bf0..59d06f4b 100644 --- a/src/IPSecVPN/Apis/GetVPNGatewayPriceResponse.php +++ b/src/IPSecVPN/Apis/GetVPNGatewayPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VPNGatewayPriceSet($item)); + array_push($result, new VPNGatewayPriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getPriceSet() /** * PriceSet: 获取的VPN网关价格信息列表,每项参数详见 VPNGatewayPriceSet * - * @param VPNGatewayPriceSet[] $priceSet + * @param VPNGatewayPriceSetModel[] $priceSet */ public function setPriceSet(array $priceSet) { diff --git a/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceRequest.php b/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceRequest.php index 71626cf1..d496e656 100644 --- a/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceRequest.php +++ b/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Grade"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNGatewayId: VPN网关的资源ID * @@ -86,11 +85,10 @@ public function getVPNGatewayId() * * @param string $vpnGatewayId */ - public function setVPNGatewayId($vpnGatewayId) + public function setVPNGatewayId(string $vpnGatewayId) { $this->set("VPNGatewayId", $vpnGatewayId); } - /** * Grade: 更改的VPN网关规格,枚举值为: Standard, 标准型; Enhanced, 增强型。 * @@ -106,7 +104,7 @@ public function getGrade() * * @param string $grade */ - public function setGrade($grade) + public function setGrade(string $grade) { $this->set("Grade", $grade); } diff --git a/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceResponse.php b/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceResponse.php index 5588f1e6..b6ce3288 100644 --- a/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceResponse.php +++ b/src/IPSecVPN/Apis/GetVPNGatewayUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/IPSecVPN/Apis/UpdateVPNGatewayRequest.php b/src/IPSecVPN/Apis/UpdateVPNGatewayRequest.php index 7a8c31cf..72022546 100644 --- a/src/IPSecVPN/Apis/UpdateVPNGatewayRequest.php +++ b/src/IPSecVPN/Apis/UpdateVPNGatewayRequest.php @@ -1,6 +1,7 @@ markRequired("Grade"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNGatewayId: VPN网关的资源ID * @@ -86,11 +85,10 @@ public function getVPNGatewayId() * * @param string $vpnGatewayId */ - public function setVPNGatewayId($vpnGatewayId) + public function setVPNGatewayId(string $vpnGatewayId) { $this->set("VPNGatewayId", $vpnGatewayId); } - /** * Grade: 网关规格。枚举值为: Standard, 标准型; Enhanced, 增强型。 * @@ -106,7 +104,7 @@ public function getGrade() * * @param string $grade */ - public function setGrade($grade) + public function setGrade(string $grade) { $this->set("Grade", $grade); } diff --git a/src/IPSecVPN/Apis/UpdateVPNGatewayResponse.php b/src/IPSecVPN/Apis/UpdateVPNGatewayResponse.php index f1bc2e94..1d29bea1 100644 --- a/src/IPSecVPN/Apis/UpdateVPNGatewayResponse.php +++ b/src/IPSecVPN/Apis/UpdateVPNGatewayResponse.php @@ -1,6 +1,7 @@ markRequired("VPNTunnelId"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -41,17 +42,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -61,15 +61,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPNTunnelId: VPN隧道的资源ID * @@ -85,11 +84,10 @@ public function getVPNTunnelId() * * @param string $vpnTunnelId */ - public function setVPNTunnelId($vpnTunnelId) + public function setVPNTunnelId(string $vpnTunnelId) { $this->set("VPNTunnelId", $vpnTunnelId); } - /** * IKEPreSharedKey: 预共享密钥 * @@ -105,11 +103,10 @@ public function getIKEPreSharedKey() * * @param string $ikePreSharedKey */ - public function setIKEPreSharedKey($ikePreSharedKey) + public function setIKEPreSharedKey(string $ikePreSharedKey) { $this->set("IKEPreSharedKey", $ikePreSharedKey); } - /** * IKEEncryptionAlgorithm: IKE协商过程中使用的加密算法 * @@ -125,11 +122,10 @@ public function getIKEEncryptionAlgorithm() * * @param string $ikeEncryptionAlgorithm */ - public function setIKEEncryptionAlgorithm($ikeEncryptionAlgorithm) + public function setIKEEncryptionAlgorithm(string $ikeEncryptionAlgorithm) { $this->set("IKEEncryptionAlgorithm", $ikeEncryptionAlgorithm); } - /** * IKEAuthenticationAlgorithm: IKE协商过程中使用的认证算法 * @@ -145,11 +141,10 @@ public function getIKEAuthenticationAlgorithm() * * @param string $ikeAuthenticationAlgorithm */ - public function setIKEAuthenticationAlgorithm($ikeAuthenticationAlgorithm) + public function setIKEAuthenticationAlgorithm(string $ikeAuthenticationAlgorithm) { $this->set("IKEAuthenticationAlgorithm", $ikeAuthenticationAlgorithm); } - /** * IKEExchangeMode: IKE协商过程中使用的模式,可选“主动模式”与“野蛮模式”。IKEV2不使用该参数。 * @@ -165,11 +160,10 @@ public function getIKEExchangeMode() * * @param string $ikeExchangeMode */ - public function setIKEExchangeMode($ikeExchangeMode) + public function setIKEExchangeMode(string $ikeExchangeMode) { $this->set("IKEExchangeMode", $ikeExchangeMode); } - /** * IKELocalId: 本端标识。不填时默认使用之前的参数,结合IKEversion进行校验,IKEV2时不能为auto。 * @@ -185,11 +179,10 @@ public function getIKELocalId() * * @param string $ikeLocalId */ - public function setIKELocalId($ikeLocalId) + public function setIKELocalId(string $ikeLocalId) { $this->set("IKELocalId", $ikeLocalId); } - /** * IKERemoteId: 客户端标识。不填时默认使用之前的参数,结合IKEversion进行校验,IKEV2时不能为auto。 * @@ -205,11 +198,10 @@ public function getIKERemoteId() * * @param string $ikeRemoteId */ - public function setIKERemoteId($ikeRemoteId) + public function setIKERemoteId(string $ikeRemoteId) { $this->set("IKERemoteId", $ikeRemoteId); } - /** * IKEDhGroup: IKE协商过程中使用的DH组 * @@ -225,11 +217,10 @@ public function getIKEDhGroup() * * @param string $ikeDhGroup */ - public function setIKEDhGroup($ikeDhGroup) + public function setIKEDhGroup(string $ikeDhGroup) { $this->set("IKEDhGroup", $ikeDhGroup); } - /** * IKESALifetime: IKE中SA的生存时间 * @@ -245,11 +236,10 @@ public function getIKESALifetime() * * @param string $ikesaLifetime */ - public function setIKESALifetime($ikesaLifetime) + public function setIKESALifetime(string $ikesaLifetime) { $this->set("IKESALifetime", $ikesaLifetime); } - /** * IPSecProtocol: 使用的安全协议,ESP或AH * @@ -265,11 +255,10 @@ public function getIPSecProtocol() * * @param string $ipSecProtocol */ - public function setIPSecProtocol($ipSecProtocol) + public function setIPSecProtocol(string $ipSecProtocol) { $this->set("IPSecProtocol", $ipSecProtocol); } - /** * IPSecLocalSubnetIds: 指定VPN连接的本地子网的id,用逗号分隔 * @@ -289,7 +278,6 @@ public function setIPSecLocalSubnetIds(array $ipSecLocalSubnetIds) { $this->set("IPSecLocalSubnetIds", $ipSecLocalSubnetIds); } - /** * IPSecRemoteSubnets: 指定VPN连接的客户网段,用逗号分隔 * @@ -309,7 +297,6 @@ public function setIPSecRemoteSubnets(array $ipSecRemoteSubnets) { $this->set("IPSecRemoteSubnets", $ipSecRemoteSubnets); } - /** * IPSecEncryptionAlgorithm: IPSec隧道中使用的加密算法 * @@ -325,11 +312,10 @@ public function getIPSecEncryptionAlgorithm() * * @param string $ipSecEncryptionAlgorithm */ - public function setIPSecEncryptionAlgorithm($ipSecEncryptionAlgorithm) + public function setIPSecEncryptionAlgorithm(string $ipSecEncryptionAlgorithm) { $this->set("IPSecEncryptionAlgorithm", $ipSecEncryptionAlgorithm); } - /** * IPSecAuthenticationAlgorithm: IPSec隧道中使用的认证算法 * @@ -345,11 +331,10 @@ public function getIPSecAuthenticationAlgorithm() * * @param string $ipSecAuthenticationAlgorithm */ - public function setIPSecAuthenticationAlgorithm($ipSecAuthenticationAlgorithm) + public function setIPSecAuthenticationAlgorithm(string $ipSecAuthenticationAlgorithm) { $this->set("IPSecAuthenticationAlgorithm", $ipSecAuthenticationAlgorithm); } - /** * IPSecSALifetime: IPSec中SA的生存时间 * @@ -365,11 +350,10 @@ public function getIPSecSALifetime() * * @param string $ipSecSALifetime */ - public function setIPSecSALifetime($ipSecSALifetime) + public function setIPSecSALifetime(string $ipSecSALifetime) { $this->set("IPSecSALifetime", $ipSecSALifetime); } - /** * IPSecSALifetimeBytes: IPSec中SA的生存时间(以字节计) * @@ -385,11 +369,10 @@ public function getIPSecSALifetimeBytes() * * @param string $ipSecSALifetimeBytes */ - public function setIPSecSALifetimeBytes($ipSecSALifetimeBytes) + public function setIPSecSALifetimeBytes(string $ipSecSALifetimeBytes) { $this->set("IPSecSALifetimeBytes", $ipSecSALifetimeBytes); } - /** * IPSecPFSDhGroup: IPSec中的PFS是否开启 * @@ -405,11 +388,10 @@ public function getIPSecPFSDhGroup() * * @param string $ipSecPFSDhGroup */ - public function setIPSecPFSDhGroup($ipSecPFSDhGroup) + public function setIPSecPFSDhGroup(string $ipSecPFSDhGroup) { $this->set("IPSecPFSDhGroup", $ipSecPFSDhGroup); } - /** * IKEVersion: 枚举值:"IKE V1","IKE V2" * @@ -425,8 +407,27 @@ public function getIKEVersion() * * @param string $ikeVersion */ - public function setIKEVersion($ikeVersion) + public function setIKEVersion(string $ikeVersion) { $this->set("IKEVersion", $ikeVersion); } + /** + * IPSecCloseAction: IPSec隧道关闭后的处理动作,默认与原本一致,若原本为空,必传。枚举值:“none”,不处理(推荐为none,流量会自动触发隧道重建);“restart”重建 + * + * @return string|null + */ + public function getIPSecCloseAction() + { + return $this->get("IPSecCloseAction"); + } + + /** + * IPSecCloseAction: IPSec隧道关闭后的处理动作,默认与原本一致,若原本为空,必传。枚举值:“none”,不处理(推荐为none,流量会自动触发隧道重建);“restart”重建 + * + * @param string $ipSecCloseAction + */ + public function setIPSecCloseAction(string $ipSecCloseAction) + { + $this->set("IPSecCloseAction", $ipSecCloseAction); + } } diff --git a/src/IPSecVPN/Apis/UpdateVPNTunnelAttributeResponse.php b/src/IPSecVPN/Apis/UpdateVPNTunnelAttributeResponse.php index 3fd71b5c..201fa4a6 100644 --- a/src/IPSecVPN/Apis/UpdateVPNTunnelAttributeResponse.php +++ b/src/IPSecVPN/Apis/UpdateVPNTunnelAttributeResponse.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RemoteVPNGatewayName" => (string) 客户VPN网关名称 - * "RemoteVPNGatewayAddr" => (string) 客户VPN网关地址 - * "Tag" => (string) 业务组名称,默认为 "Default" - * "Remark" => (string) 备注,默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * "RemoteVPNGatewayId" => (string) 新建客户VPN网关的资源ID - * ] - * - * @return CreateRemoteVPNGatewayResponse * @throws UCloudException */ public function createRemoteVPNGateway(CreateRemoteVPNGatewayRequest $request = null) @@ -81,36 +106,13 @@ public function createRemoteVPNGateway(CreateRemoteVPNGatewayRequest $request = $resp = $this->invoke($request); return new CreateRemoteVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateVPNGateway - 创建VPN网关 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/create_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNGatewayName" => (string) 新建VPN网关名称 - * "VPCId" => (string) 新建VPN网关所属VPC的资源ID - * "Grade" => (string) 购买的VPN网关规格,枚举值为: Standard, 标准型; Enhanced, 增强型 - * "Remark" => (string) 备注,默认为空 - * "Tag" => (string) 业务组名称,默认为 "Default" - * "Quantity" => (integer) 购买时长, 默认: 1 - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费;Dynamic, 按需付费(需开启权限);Trial, 试用(需开启权限);默认为按月付费 - * "BusinessId" => (string) 业务组ID - * "EIPId" => (string) 若要绑定EIP,在此填上EIP的资源ID - * "CouponId" => (string) 代金券ID, 默认不使用 - * ] - * - * Outputs: - * - * $outputs = [ - * "VPNGatewayId" => (string) 新建VPN网关的资源ID - * ] - * - * @return CreateVPNGatewayResponse * @throws UCloudException */ public function createVPNGateway(CreateVPNGatewayRequest $request = null) @@ -118,49 +120,13 @@ public function createVPNGateway(CreateVPNGatewayRequest $request = null) $resp = $this->invoke($request); return new CreateVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateVPNTunnel - 创建VPN隧道 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/create_vpn_tunnel - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNTunnelName" => (string) VPN隧道名称 - * "VPNGatewayId" => (string) VPN网关的资源ID - * "RemoteVPNGatewayId" => (string) 客户VPN网关的资源ID - * "IKEPreSharedKey" => (string) 预共享密钥 - * "VPCId" => (string) vpcId - * "IPSecLocalSubnetIds" => (array) 指定VPN连接的本地子网的资源ID,最多可填写10个。 - * "IPSecRemoteSubnets" => (array) 指定VPN连接的客户网段,最多可填写20个。 - * "IKEVersion" => (string) ike版本,枚举值: "IKE V1","IKE V2",默认v1 - * "Tag" => (string) 业务组,默认为“Default” - * "Remark" => (string) 备注,默认为空 - * "IKEEncryptionAlgorithm" => (string) IKE协商过程中使用的加密算法,枚举值,"aes128", "aes192", "aes256", "aes512", "3des"。默认值为“aes128” - * "IKEAuthenticationAlgorithm" => (string) IKE协商过程中使用的认证算法,"md5", "sha1", "sha2-256"。默认值为“sha1” - * "IKEExchangeMode" => (string) IKE协商过程中使用的模式,枚举值,主模式,“main”;野蛮模式,“aggressive”。IKEV1默认为主模式“main”,IKEV2时不使用该参数。 - * "IKELocalId" => (string) 本端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为自动识别“auto”。IKEV2必填该参数 - * "IKERemoteId" => (string) 客户端标识。枚举值,自动识别,“auto”;IP地址或域名。默认为“自动识别“auto”。IKEV2必填该参数 - * "IKEDhGroup" => (string) IKE协商过程中使用的DH组,枚举值,"1", "2", "5", "14", "15", "16"。默认为“15” - * "IKESALifetime" => (string) IKE中SA的生存时间,可填写范围为600-604800。默认为86400。 - * "IPSecProtocol" => (string) 使用的安全协议,枚举值,“esp”,“ah”。默认为“esp” - * "IPSecEncryptionAlgorithm" => (string) IPSec隧道中使用的加密算法,枚举值,"aes128", "aes192", "aes256", "aes512", "3des"。默认值为“aes128” - * "IPSecAuthenticationAlgorithm" => (string) IPSec隧道中使用的认证算法,枚举值,"md5", "sha1"。默认值为“sha1” - * "IPSecSALifetime" => (string) IPSec中SA的生存时间,可填写范围为1200 - 604800。默认为3600 - * "IPSecSALifetimeBytes" => (string) IPSec中SA的生存时间(以字节计)。可选为8000 – 20000000。默认使用SA生存时间, - * "IPSecPFSDhGroup" => (string) IPSec的PFS是否开启,枚举值,,不开启,"disable";数字表示DH组, "1", "2", "5", "14", "15", "16"。默认为“disable”。 - * ] - * - * Outputs: - * - * $outputs = [ - * "VPNTunnelId" => (string) VPN隧道的资源ID - * ] - * - * @return CreateVPNTunnelResponse * @throws UCloudException */ public function createVPNTunnel(CreateVPNTunnelRequest $request = null) @@ -168,26 +134,13 @@ public function createVPNTunnel(CreateVPNTunnelRequest $request = null) $resp = $this->invoke($request); return new CreateVPNTunnelResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteRemoteVPNGateway - 删除客户VPN网关 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/delete_remote_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RemoteVPNGatewayId" => (string) 客户VPN网关的资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteRemoteVPNGatewayResponse * @throws UCloudException */ public function deleteRemoteVPNGateway(DeleteRemoteVPNGatewayRequest $request = null) @@ -195,27 +148,13 @@ public function deleteRemoteVPNGateway(DeleteRemoteVPNGatewayRequest $request = $resp = $this->invoke($request); return new DeleteRemoteVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteVPNGateway - 删除VPN网关 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/delete_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNGatewayId" => (string) VPN网关的资源ID - * "ReleaseEip" => (boolean) 删除VPN时是否一并释放EIP。false,只解绑EIP不删除EIP;true,解绑并释放EIP。默认是false - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteVPNGatewayResponse * @throws UCloudException */ public function deleteVPNGateway(DeleteVPNGatewayRequest $request = null) @@ -223,26 +162,13 @@ public function deleteVPNGateway(DeleteVPNGatewayRequest $request = null) $resp = $this->invoke($request); return new DeleteVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteVPNTunnel - 删除VPN隧道 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/delete_vpn_tunnel - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNTunnelId" => (string) VPN隧道的资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteVPNTunnelResponse * @throws UCloudException */ public function deleteVPNTunnel(DeleteVPNTunnelRequest $request = null) @@ -250,41 +176,13 @@ public function deleteVPNTunnel(DeleteVPNTunnelRequest $request = null) $resp = $this->invoke($request); return new DeleteVPNTunnelResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeRemoteVPNGateway - 获取客户VPN网关信息 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/describe_remote_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "RemoteVPNGatewayIds" => (array) 客户VPN网关的资源ID,例如RemoteVPNGatewayIds.0代表希望获取客户VPN网关1的信息,RemoteVPNGatewayIds.1代表客户VPN网关2,如果为空,则返回当前Region中所有客户VPN网关实例的信息 - * "Tag" => (string) 业务组名称,若指定则返回业务组下所有客户VPN网关信息 - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 符合条件的客户VPN网关总数 - * "DataSet" => (array) 客户VPN网关列表, 每项参数详见 RemoteVPNGatewayDataSet[ - * [ - * "RemoteVPNGatewayId" => (string) 客户网关ID - * "RemoteVPNGatewayName" => (string) 客户网关名称 - * "RemoteVPNGatewayAddr" => (string) 客户网关IP地址 - * "Tag" => (string) 用户组 - * "Remark" => (string) 备注 - * "CreateTime" => (integer) 创建时间 - * "TunnelCount" => (integer) 活跃的隧道数量 - * ] - * ] - * ] - * - * @return DescribeRemoteVPNGatewayResponse * @throws UCloudException */ public function describeRemoteVPNGateway(DescribeRemoteVPNGatewayRequest $request = null) @@ -292,49 +190,13 @@ public function describeRemoteVPNGateway(DescribeRemoteVPNGatewayRequest $reques $resp = $this->invoke($request); return new DescribeRemoteVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeVPNGateway - 获取VPN网关信息 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/describe_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNGatewayIds" => (array) VPN网关的资源ID,例如VPNGatewayIds.0代表希望获取VPN网关1的信息,VPNGatewayIds.1代表VPN网关2,如果为空,则返回当前Region中所有VPN网关的信息 - * "VPCId" => (string) VPC的资源ID,返回指定的VPC下的所有VPN网关的信息。默认返回当前Region中所有VPN网关实例的信息 - * "Offset" => (integer) 数据偏移量。默认为0 - * "Tag" => (string) 业务组名称,若指定则返回指定的业务组下的所有VPN网关的信息。 - * "Limit" => (integer) 数据分页值。默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的VPN网关总数 - * "DataSet" => (array) 获取的VPN网关信息列表,每项参数详见 VPNGatewayDataSet[ - * [ - * "VPNGatewayId" => (string) 网关Id - * "VPNGatewayName" => (string) 网关名字 - * "Tag" => (string) 网关业务组 - * "Remark" => (string) 网关备注 - * "VPCId" => (string) 所属VPCId - * "VPCName" => (string) 所属VPC名字 - * "ChargeType" => (string) 付费类型 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 到期时间 - * "AutoRenew" => (string) 是否自动续费 - * "Grade" => (string) 网关类型 - * "EIP" => (string) 绑定EIP的IP地址 - * "EIPType" => (string) EIP类型 - * "EIPId" => (string) EIPID - * ] - * ] - * ] - * - * @return DescribeVPNGatewayResponse * @throws UCloudException */ public function describeVPNGateway(DescribeVPNGatewayRequest $request = null) @@ -342,66 +204,13 @@ public function describeVPNGateway(DescribeVPNGatewayRequest $request = null) $resp = $this->invoke($request); return new DescribeVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeVPNTunnel - 获取VPN隧道信息 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/describe_vpn_tunnel - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNTunnelIds" => (array) VPN隧道的资源ID,例如VPNTunnelIds.0代表希望获取信息的VPN隧道1,VPNTunneIds.1代表VPN隧道2,如果为空,则返回当前Region中所有的VPN隧道实例 - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * "Tag" => (string) 业务组名称,若指定则返回指定的业务组下的所有VPN网关的信息 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) VPN隧道总数 - * "DataSet" => (array) 获取的VPN隧道信息列表,每项参数详见 VPNTunnelDataSet[ - * [ - * "VPNTunnelId" => (string) 隧道id - * "VPNTunnelName" => (string) 隧道名称 - * "Tag" => (string) 用户组 - * "Remark" => (string) 备注 - * "VPNGatewayId" => (string) 所属VPN网关id - * "RemoteVPNGatewayId" => (string) 对端网关Id - * "VPNGatewayName" => (string) VPN网关名字 - * "RemoteVPNGatewayName" => (string) 对端网关名字 - * "VPCId" => (string) 所属VPCId - * "VPCName" => (string) 所属VOC名字 - * "CreateTime" => (integer) 创建时间 - * "IKEData" => (object) IKE参数[ - * "IKEAuthenticationAlgorithm" => (string) IKE认证算法 - * "IKEDhGroup" => (string) IKEDH组 - * "IKEEncryptionAlgorithm" => (string) IKE加密算法 - * "IKEExchangeMode" => (string) IKEv1协商模式 - * "IKELocalId" => (string) IKE本地ID标识 - * "IKEPreSharedKey" => (string) IKE预共享秘钥 - * "IKERemoteId" => (string) IKE对端ID标识 - * "IKESALifetime" => (string) IKE秘钥生存时间 - * "IKEVersion" => (string) IKE版本 - * ] - * "IPSecData" => (object) IPSec参数[ - * "IPSecAuthenticationAlgorithm" => (string) IPSec通道中使用的认证算法 - * "IPSecEncryptionAlgorithm" => (string) IPSec通道中使用的加密算法 - * "IPSecLocalSubnetIds" => (array) 指定VPN连接的本地子网,用逗号分隔 - * "IPSecProtocol" => (string) 使用的安全协议,ESP或AH - * "IPSecRemoteSubnets" => (array) 指定VPN连接的客户网段,用逗号分隔 - * "IPSecSALifetime" => (string) IPSec中SA的生存时间 - * "IPSecSALifetimeBytes" => (string) IPSec中SA的生存时间(以字节计) - * "IPSecPFSDhGroup" => (string) 是否开启PFS功能,Disable表示关闭,数字表示DH组 - * ] - * ] - * ] - * ] - * - * @return DescribeVPNTunnelResponse * @throws UCloudException */ public function describeVPNTunnel(DescribeVPNTunnelRequest $request = null) @@ -409,35 +218,13 @@ public function describeVPNTunnel(DescribeVPNTunnelRequest $request = null) $resp = $this->invoke($request); return new DescribeVPNTunnelResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetVPNGatewayPrice - 获取VPN价格 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/get_vpn_gateway_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Grade" => (string) VPN网关规格。枚举值,包括:标准型:Standard,增强型:Enhanced。 - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按需付费(需开启权限); 默认为获取三种价格 - * "Quantity" => (integer) 购买时长, 默认: 1 - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceSet" => (array) 获取的VPN网关价格信息列表,每项参数详见 VPNGatewayPriceSet[ - * [ - * "ChargeType" => (string) VPN网关付费方式 - * "Price" => (number) VPN网关价格, 单位"元" - * "PurchaseValue" => (integer) 资源有效期, 以Unix Timestamp表示 - * ] - * ] - * ] - * - * @return GetVPNGatewayPriceResponse * @throws UCloudException */ public function getVPNGatewayPrice(GetVPNGatewayPriceRequest $request = null) @@ -445,28 +232,13 @@ public function getVPNGatewayPrice(GetVPNGatewayPriceRequest $request = null) $resp = $this->invoke($request); return new GetVPNGatewayPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetVPNGatewayUpgradePrice - 获取VPN网关规格改动价格 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/get_vpn_gateway_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNGatewayId" => (string) VPN网关的资源ID - * "Grade" => (string) 更改的VPN网关规格,枚举值为: Standard, 标准型; Enhanced, 增强型。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 调整规格后的VPN网关价格, 单位为"元", 如需退费此处为负值 - * ] - * - * @return GetVPNGatewayUpgradePriceResponse * @throws UCloudException */ public function getVPNGatewayUpgradePrice(GetVPNGatewayUpgradePriceRequest $request = null) @@ -474,27 +246,13 @@ public function getVPNGatewayUpgradePrice(GetVPNGatewayUpgradePriceRequest $requ $resp = $this->invoke($request); return new GetVPNGatewayUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateVPNGateway - 更改VPN网关规格 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/update_vpn_gateway - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNGatewayId" => (string) VPN网关的资源ID - * "Grade" => (string) 网关规格。枚举值为: Standard, 标准型; Enhanced, 增强型。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateVPNGatewayResponse * @throws UCloudException */ public function updateVPNGateway(UpdateVPNGatewayRequest $request = null) @@ -502,43 +260,13 @@ public function updateVPNGateway(UpdateVPNGatewayRequest $request = null) $resp = $this->invoke($request); return new UpdateVPNGatewayResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateVPNTunnelAttribute - 更新VPN隧道属性 * - * See also: https://docs.ucloud.cn/api/ipsecvpn-api/update_vpn_tunnel_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPNTunnelId" => (string) VPN隧道的资源ID - * "IKEPreSharedKey" => (string) 预共享密钥 - * "IKEEncryptionAlgorithm" => (string) IKE协商过程中使用的加密算法 - * "IKEAuthenticationAlgorithm" => (string) IKE协商过程中使用的认证算法 - * "IKEExchangeMode" => (string) IKE协商过程中使用的模式,可选“主动模式”与“野蛮模式”。IKEV2不使用该参数。 - * "IKELocalId" => (string) 本端标识。不填时默认使用之前的参数,结合IKEversion进行校验,IKEV2时不能为auto。 - * "IKERemoteId" => (string) 客户端标识。不填时默认使用之前的参数,结合IKEversion进行校验,IKEV2时不能为auto。 - * "IKEDhGroup" => (string) IKE协商过程中使用的DH组 - * "IKESALifetime" => (string) IKE中SA的生存时间 - * "IPSecProtocol" => (string) 使用的安全协议,ESP或AH - * "IPSecLocalSubnetIds" => (array) 指定VPN连接的本地子网的id,用逗号分隔 - * "IPSecRemoteSubnets" => (array) 指定VPN连接的客户网段,用逗号分隔 - * "IPSecEncryptionAlgorithm" => (string) IPSec隧道中使用的加密算法 - * "IPSecAuthenticationAlgorithm" => (string) IPSec隧道中使用的认证算法 - * "IPSecSALifetime" => (string) IPSec中SA的生存时间 - * "IPSecSALifetimeBytes" => (string) IPSec中SA的生存时间(以字节计) - * "IPSecPFSDhGroup" => (string) IPSec中的PFS是否开启 - * "IKEVersion" => (string) 枚举值:"IKE V1","IKE V2" - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateVPNTunnelAttributeResponse * @throws UCloudException */ public function updateVPNTunnelAttribute(UpdateVPNTunnelAttributeRequest $request = null) diff --git a/src/IPSecVPN/Models/IKEData.php b/src/IPSecVPN/Models/IKEData.php index 314480b3..29e03698 100644 --- a/src/IPSecVPN/Models/IKEData.php +++ b/src/IPSecVPN/Models/IKEData.php @@ -1,6 +1,7 @@ set("IKEAuthenticationAlgorithm", $ikeAuthenticationAlgorithm); } - /** * IKEDhGroup: IKEDH组 * @@ -57,11 +60,10 @@ public function getIKEDhGroup() * * @param string $ikeDhGroup */ - public function setIKEDhGroup($ikeDhGroup) + public function setIKEDhGroup(string $ikeDhGroup) { $this->set("IKEDhGroup", $ikeDhGroup); } - /** * IKEEncryptionAlgorithm: IKE加密算法 * @@ -77,11 +79,10 @@ public function getIKEEncryptionAlgorithm() * * @param string $ikeEncryptionAlgorithm */ - public function setIKEEncryptionAlgorithm($ikeEncryptionAlgorithm) + public function setIKEEncryptionAlgorithm(string $ikeEncryptionAlgorithm) { $this->set("IKEEncryptionAlgorithm", $ikeEncryptionAlgorithm); } - /** * IKEExchangeMode: IKEv1协商模式 * @@ -97,11 +98,10 @@ public function getIKEExchangeMode() * * @param string $ikeExchangeMode */ - public function setIKEExchangeMode($ikeExchangeMode) + public function setIKEExchangeMode(string $ikeExchangeMode) { $this->set("IKEExchangeMode", $ikeExchangeMode); } - /** * IKELocalId: IKE本地ID标识 * @@ -117,11 +117,10 @@ public function getIKELocalId() * * @param string $ikeLocalId */ - public function setIKELocalId($ikeLocalId) + public function setIKELocalId(string $ikeLocalId) { $this->set("IKELocalId", $ikeLocalId); } - /** * IKEPreSharedKey: IKE预共享秘钥 * @@ -137,11 +136,10 @@ public function getIKEPreSharedKey() * * @param string $ikePreSharedKey */ - public function setIKEPreSharedKey($ikePreSharedKey) + public function setIKEPreSharedKey(string $ikePreSharedKey) { $this->set("IKEPreSharedKey", $ikePreSharedKey); } - /** * IKERemoteId: IKE对端ID标识 * @@ -157,11 +155,10 @@ public function getIKERemoteId() * * @param string $ikeRemoteId */ - public function setIKERemoteId($ikeRemoteId) + public function setIKERemoteId(string $ikeRemoteId) { $this->set("IKERemoteId", $ikeRemoteId); } - /** * IKESALifetime: IKE秘钥生存时间 * @@ -177,11 +174,10 @@ public function getIKESALifetime() * * @param string $ikesaLifetime */ - public function setIKESALifetime($ikesaLifetime) + public function setIKESALifetime(string $ikesaLifetime) { $this->set("IKESALifetime", $ikesaLifetime); } - /** * IKEVersion: IKE版本 * @@ -197,7 +193,7 @@ public function getIKEVersion() * * @param string $ikeVersion */ - public function setIKEVersion($ikeVersion) + public function setIKEVersion(string $ikeVersion) { $this->set("IKEVersion", $ikeVersion); } diff --git a/src/IPSecVPN/Models/IPSecData.php b/src/IPSecVPN/Models/IPSecData.php index 599482fb..fc20afe1 100644 --- a/src/IPSecVPN/Models/IPSecData.php +++ b/src/IPSecVPN/Models/IPSecData.php @@ -1,6 +1,7 @@ set("IPSecAuthenticationAlgorithm", $ipSecAuthenticationAlgorithm); } - /** * IPSecEncryptionAlgorithm: IPSec通道中使用的加密算法 * @@ -57,11 +60,10 @@ public function getIPSecEncryptionAlgorithm() * * @param string $ipSecEncryptionAlgorithm */ - public function setIPSecEncryptionAlgorithm($ipSecEncryptionAlgorithm) + public function setIPSecEncryptionAlgorithm(string $ipSecEncryptionAlgorithm) { $this->set("IPSecEncryptionAlgorithm", $ipSecEncryptionAlgorithm); } - /** * IPSecLocalSubnetIds: 指定VPN连接的本地子网,用逗号分隔 * @@ -81,7 +83,6 @@ public function setIPSecLocalSubnetIds(array $ipSecLocalSubnetIds) { $this->set("IPSecLocalSubnetIds", $ipSecLocalSubnetIds); } - /** * IPSecProtocol: 使用的安全协议,ESP或AH * @@ -97,11 +98,10 @@ public function getIPSecProtocol() * * @param string $ipSecProtocol */ - public function setIPSecProtocol($ipSecProtocol) + public function setIPSecProtocol(string $ipSecProtocol) { $this->set("IPSecProtocol", $ipSecProtocol); } - /** * IPSecRemoteSubnets: 指定VPN连接的客户网段,用逗号分隔 * @@ -121,7 +121,6 @@ public function setIPSecRemoteSubnets(array $ipSecRemoteSubnets) { $this->set("IPSecRemoteSubnets", $ipSecRemoteSubnets); } - /** * IPSecSALifetime: IPSec中SA的生存时间 * @@ -137,11 +136,10 @@ public function getIPSecSALifetime() * * @param string $ipSecSALifetime */ - public function setIPSecSALifetime($ipSecSALifetime) + public function setIPSecSALifetime(string $ipSecSALifetime) { $this->set("IPSecSALifetime", $ipSecSALifetime); } - /** * IPSecSALifetimeBytes: IPSec中SA的生存时间(以字节计) * @@ -157,11 +155,10 @@ public function getIPSecSALifetimeBytes() * * @param string $ipSecSALifetimeBytes */ - public function setIPSecSALifetimeBytes($ipSecSALifetimeBytes) + public function setIPSecSALifetimeBytes(string $ipSecSALifetimeBytes) { $this->set("IPSecSALifetimeBytes", $ipSecSALifetimeBytes); } - /** * IPSecPFSDhGroup: 是否开启PFS功能,Disable表示关闭,数字表示DH组 * @@ -177,7 +174,7 @@ public function getIPSecPFSDhGroup() * * @param string $ipSecPFSDhGroup */ - public function setIPSecPFSDhGroup($ipSecPFSDhGroup) + public function setIPSecPFSDhGroup(string $ipSecPFSDhGroup) { $this->set("IPSecPFSDhGroup", $ipSecPFSDhGroup); } diff --git a/src/IPSecVPN/Models/RemoteVPNGatewayDataSet.php b/src/IPSecVPN/Models/RemoteVPNGatewayDataSet.php index bd899374..3c0fa6e4 100644 --- a/src/IPSecVPN/Models/RemoteVPNGatewayDataSet.php +++ b/src/IPSecVPN/Models/RemoteVPNGatewayDataSet.php @@ -1,6 +1,7 @@ set("RemoteVPNGatewayId", $remoteVPNGatewayId); } - /** * RemoteVPNGatewayName: 客户网关名称 * @@ -57,11 +59,10 @@ public function getRemoteVPNGatewayName() * * @param string $remoteVPNGatewayName */ - public function setRemoteVPNGatewayName($remoteVPNGatewayName) + public function setRemoteVPNGatewayName(string $remoteVPNGatewayName) { $this->set("RemoteVPNGatewayName", $remoteVPNGatewayName); } - /** * RemoteVPNGatewayAddr: 客户网关IP地址 * @@ -77,11 +78,10 @@ public function getRemoteVPNGatewayAddr() * * @param string $remoteVPNGatewayAddr */ - public function setRemoteVPNGatewayAddr($remoteVPNGatewayAddr) + public function setRemoteVPNGatewayAddr(string $remoteVPNGatewayAddr) { $this->set("RemoteVPNGatewayAddr", $remoteVPNGatewayAddr); } - /** * Tag: 用户组 * @@ -97,11 +97,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -117,11 +116,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * CreateTime: 创建时间 * @@ -137,11 +135,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * TunnelCount: 活跃的隧道数量 * @@ -157,7 +154,7 @@ public function getTunnelCount() * * @param int $tunnelCount */ - public function setTunnelCount($tunnelCount) + public function setTunnelCount(int $tunnelCount) { $this->set("TunnelCount", $tunnelCount); } diff --git a/src/IPSecVPN/Models/VPNGatewayDataSet.php b/src/IPSecVPN/Models/VPNGatewayDataSet.php index 35e1c0d8..c5a66a46 100644 --- a/src/IPSecVPN/Models/VPNGatewayDataSet.php +++ b/src/IPSecVPN/Models/VPNGatewayDataSet.php @@ -1,6 +1,7 @@ set("VPNGatewayId", $vpnGatewayId); } - /** * VPNGatewayName: 网关名字 * @@ -57,11 +59,10 @@ public function getVPNGatewayName() * * @param string $vpnGatewayName */ - public function setVPNGatewayName($vpnGatewayName) + public function setVPNGatewayName(string $vpnGatewayName) { $this->set("VPNGatewayName", $vpnGatewayName); } - /** * Tag: 网关业务组 * @@ -77,11 +78,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 网关备注 * @@ -97,11 +97,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * VPCId: 所属VPCId * @@ -117,11 +116,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * VPCName: 所属VPC名字 * @@ -137,11 +135,10 @@ public function getVPCName() * * @param string $vpcName */ - public function setVPCName($vpcName) + public function setVPCName(string $vpcName) { $this->set("VPCName", $vpcName); } - /** * ChargeType: 付费类型 * @@ -157,11 +154,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CreateTime: 创建时间 * @@ -177,11 +173,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 到期时间 * @@ -197,11 +192,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * AutoRenew: 是否自动续费 * @@ -217,11 +211,10 @@ public function getAutoRenew() * * @param string $autoRenew */ - public function setAutoRenew($autoRenew) + public function setAutoRenew(string $autoRenew) { $this->set("AutoRenew", $autoRenew); } - /** * Grade: 网关类型 * @@ -237,11 +230,10 @@ public function getGrade() * * @param string $grade */ - public function setGrade($grade) + public function setGrade(string $grade) { $this->set("Grade", $grade); } - /** * EIP: 绑定EIP的IP地址 * @@ -257,11 +249,10 @@ public function getEIP() * * @param string $eip */ - public function setEIP($eip) + public function setEIP(string $eip) { $this->set("EIP", $eip); } - /** * EIPType: EIP类型 * @@ -277,11 +268,10 @@ public function getEIPType() * * @param string $eipType */ - public function setEIPType($eipType) + public function setEIPType(string $eipType) { $this->set("EIPType", $eipType); } - /** * EIPId: EIPID * @@ -297,7 +287,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/IPSecVPN/Models/VPNGatewayPriceSet.php b/src/IPSecVPN/Models/VPNGatewayPriceSet.php index dae29844..597b00a8 100644 --- a/src/IPSecVPN/Models/VPNGatewayPriceSet.php +++ b/src/IPSecVPN/Models/VPNGatewayPriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: VPN网关价格, 单位"元" * @@ -57,11 +59,10 @@ public function getPrice() * * @param float $price */ - public function setPrice($price) + public function setPrice(float $price) { $this->set("Price", $price); } - /** * PurchaseValue: 资源有效期, 以Unix Timestamp表示 * @@ -77,7 +78,7 @@ public function getPurchaseValue() * * @param int $purchaseValue */ - public function setPurchaseValue($purchaseValue) + public function setPurchaseValue(int $purchaseValue) { $this->set("PurchaseValue", $purchaseValue); } diff --git a/src/IPSecVPN/Models/VPNTunnelDataSet.php b/src/IPSecVPN/Models/VPNTunnelDataSet.php index c32d6d8a..e6b048a9 100644 --- a/src/IPSecVPN/Models/VPNTunnelDataSet.php +++ b/src/IPSecVPN/Models/VPNTunnelDataSet.php @@ -1,6 +1,7 @@ set("VPNTunnelId", $vpnTunnelId); } - /** * VPNTunnelName: 隧道名称 * @@ -57,11 +61,10 @@ public function getVPNTunnelName() * * @param string $vpnTunnelName */ - public function setVPNTunnelName($vpnTunnelName) + public function setVPNTunnelName(string $vpnTunnelName) { $this->set("VPNTunnelName", $vpnTunnelName); } - /** * Tag: 用户组 * @@ -77,11 +80,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -97,11 +99,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * VPNGatewayId: 所属VPN网关id * @@ -117,11 +118,10 @@ public function getVPNGatewayId() * * @param string $vpnGatewayId */ - public function setVPNGatewayId($vpnGatewayId) + public function setVPNGatewayId(string $vpnGatewayId) { $this->set("VPNGatewayId", $vpnGatewayId); } - /** * RemoteVPNGatewayId: 对端网关Id * @@ -137,11 +137,10 @@ public function getRemoteVPNGatewayId() * * @param string $remoteVPNGatewayId */ - public function setRemoteVPNGatewayId($remoteVPNGatewayId) + public function setRemoteVPNGatewayId(string $remoteVPNGatewayId) { $this->set("RemoteVPNGatewayId", $remoteVPNGatewayId); } - /** * VPNGatewayName: VPN网关名字 * @@ -157,11 +156,10 @@ public function getVPNGatewayName() * * @param string $vpnGatewayName */ - public function setVPNGatewayName($vpnGatewayName) + public function setVPNGatewayName(string $vpnGatewayName) { $this->set("VPNGatewayName", $vpnGatewayName); } - /** * RemoteVPNGatewayName: 对端网关名字 * @@ -177,11 +175,10 @@ public function getRemoteVPNGatewayName() * * @param string $remoteVPNGatewayName */ - public function setRemoteVPNGatewayName($remoteVPNGatewayName) + public function setRemoteVPNGatewayName(string $remoteVPNGatewayName) { $this->set("RemoteVPNGatewayName", $remoteVPNGatewayName); } - /** * VPCId: 所属VPCId * @@ -197,11 +194,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * VPCName: 所属VOC名字 * @@ -217,11 +213,10 @@ public function getVPCName() * * @param string $vpcName */ - public function setVPCName($vpcName) + public function setVPCName(string $vpcName) { $this->set("VPCName", $vpcName); } - /** * CreateTime: 创建时间 * @@ -237,47 +232,45 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * IKEData: IKE参数 * - * @return IKEData|null + * @return IKEDataModel|null */ public function getIKEData() { - return new IKEData($this->get("IKEData")); + return new IKEDataModel($this->get("IKEData")); } /** * IKEData: IKE参数 * - * @param IKEData $ikeData + * @param IKEDataModel $ikeData */ - public function setIKEData(array $ikeData) + public function setIKEData(IKEDataModel $ikeData) { $this->set("IKEData", $ikeData->getAll()); } - /** * IPSecData: IPSec参数 * - * @return IPSecData|null + * @return IPSecDataModel|null */ public function getIPSecData() { - return new IPSecData($this->get("IPSecData")); + return new IPSecDataModel($this->get("IPSecData")); } /** * IPSecData: IPSec参数 * - * @param IPSecData $ipSecData + * @param IPSecDataModel $ipSecData */ - public function setIPSecData(array $ipSecData) + public function setIPSecData(IPSecDataModel $ipSecData) { $this->set("IPSecData", $ipSecData->getAll()); } diff --git a/src/PathX/Apis/BindPathXSSLRequest.php b/src/PathX/Apis/BindPathXSSLRequest.php index bf375955..80ede70f 100644 --- a/src/PathX/Apis/BindPathXSSLRequest.php +++ b/src/PathX/Apis/BindPathXSSLRequest.php @@ -1,6 +1,7 @@ markRequired("Port"); } - /** * ProjectId: 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -46,11 +47,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLId: 证书ID,如果没有指定证书ID也没有申请免费证书,HTTPS接入无法正常工作 * @@ -66,11 +66,10 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } - /** * UGAId: UGA实例ID * @@ -86,11 +85,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * Port: 绑定SSL证书的HTTPS端口。Port.0 Port.1对应多个Port。如果Port不存在则不会绑定 * diff --git a/src/PathX/Apis/BindPathXSSLResponse.php b/src/PathX/Apis/BindPathXSSLResponse.php index 8dde0440..987778ee 100644 --- a/src/PathX/Apis/BindPathXSSLResponse.php +++ b/src/PathX/Apis/BindPathXSSLResponse.php @@ -1,6 +1,7 @@ markRequired("AreaCode"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -47,11 +48,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Area: 填写支持SSH访问IP的地区名称,如“洛杉矶”,“新加坡”,“香港”,“东京”,“华盛顿”,“法兰克福”,“首尔”。Area和AreaCode两者必填一个 * @@ -67,11 +67,10 @@ public function getArea() * * @param string $area */ - public function setArea($area) + public function setArea(string $area) { $this->set("Area", $area); } - /** * TargetIP: 被SSH访问的源站IP,仅支持IPv4地址。 * @@ -87,11 +86,10 @@ public function getTargetIP() * * @param string $targetIP */ - public function setTargetIP($targetIP) + public function setTargetIP(string $targetIP) { $this->set("TargetIP", $targetIP); } - /** * Port: 源站服务器监听的SSH端口,可取范围[1-65535],不能使用80,443, 65123端口。如果InstanceType=Free,取值范围缩小为[22,3389],linux系统选择22,windows系统自动选3389。 * @@ -107,11 +105,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * AreaCode: AreaCode, 区域航空港国际通用代码。Area和AreaCode两者必填一个 * @@ -127,11 +124,10 @@ public function getAreaCode() * * @param string $areaCode */ - public function setAreaCode($areaCode) + public function setAreaCode(string $areaCode) { $this->set("AreaCode", $areaCode); } - /** * Remark: 备注信息 * @@ -147,11 +143,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * ChargeType: 支付方式,如按月:Month、 按年:Year、按时:Dynamic * @@ -167,11 +162,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买数量按月购买至月底请传0 * @@ -187,11 +181,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * InstanceType: 枚举值:["Ultimate","Enterprise","Basic","Primary"], 分别代表旗舰版,企业版,基础版,入门版 * @@ -207,11 +200,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * BandwidthPackage: Ultimate版本带宽包大小,枚举值:[0,20,40]。单位MB * @@ -227,11 +219,10 @@ public function getBandwidthPackage() * * @param int $bandwidthPackage */ - public function setBandwidthPackage($bandwidthPackage) + public function setBandwidthPackage(int $bandwidthPackage) { $this->set("BandwidthPackage", $bandwidthPackage); } - /** * ForwardRegion: InstanceType等于Basic时可以在["cn-bj2","cn-sh2","cn-gd"]中选择1个作为转发机房,其他付费版默认配置三个转发机房 * @@ -247,11 +238,10 @@ public function getForwardRegion() * * @param string $forwardRegion */ - public function setForwardRegion($forwardRegion) + public function setForwardRegion(string $forwardRegion) { $this->set("ForwardRegion", $forwardRegion); } - /** * CouponId: 使用代金券可冲抵部分费用 * @@ -267,7 +257,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/PathX/Apis/CreateGlobalSSHInstanceResponse.php b/src/PathX/Apis/CreateGlobalSSHInstanceResponse.php index eeb9d47a..1ebc1aaa 100644 --- a/src/PathX/Apis/CreateGlobalSSHInstanceResponse.php +++ b/src/PathX/Apis/CreateGlobalSSHInstanceResponse.php @@ -1,6 +1,7 @@ set("InstanceId", $instanceId); } - /** * AcceleratingDomain: 加速域名,访问该域名可就近接入 * @@ -57,7 +57,7 @@ public function getAcceleratingDomain() * * @param string $acceleratingDomain */ - public function setAcceleratingDomain($acceleratingDomain) + public function setAcceleratingDomain(string $acceleratingDomain) { $this->set("AcceleratingDomain", $acceleratingDomain); } diff --git a/src/PathX/Apis/CreatePathXSSLRequest.php b/src/PathX/Apis/CreatePathXSSLRequest.php index 2bfd7f90..d99efa43 100644 --- a/src/PathX/Apis/CreatePathXSSLRequest.php +++ b/src/PathX/Apis/CreatePathXSSLRequest.php @@ -1,6 +1,7 @@ markRequired("SSLName"); } - /** * ProjectId: 项目ID org-xxx格式。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLName: SSL证书的名字 * @@ -64,11 +64,10 @@ public function getSSLName() * * @param string $sslName */ - public function setSSLName($sslName) + public function setSSLName(string $sslName) { $this->set("SSLName", $sslName); } - /** * SSLType: 所添加的SSL证书类型,目前只支持Pem格式 * @@ -84,11 +83,10 @@ public function getSSLType() * * @param string $sslType */ - public function setSSLType($sslType) + public function setSSLType(string $sslType) { $this->set("SSLType", $sslType); } - /** * SSLContent: SSL证书的完整内容,私钥不可使用密码,包括加密证书的私钥、用户证书或CA证书等 * @@ -104,11 +102,10 @@ public function getSSLContent() * * @param string $sslContent */ - public function setSSLContent($sslContent) + public function setSSLContent(string $sslContent) { $this->set("SSLContent", $sslContent); } - /** * UserCert: 用户自签证书内容 * @@ -124,11 +121,10 @@ public function getUserCert() * * @param string $userCert */ - public function setUserCert($userCert) + public function setUserCert(string $userCert) { $this->set("UserCert", $userCert); } - /** * PrivateKey: 加密证书的私钥,不可使用密码保护,开启密码保护后,重启服务需要输入密码 * @@ -144,11 +140,10 @@ public function getPrivateKey() * * @param string $privateKey */ - public function setPrivateKey($privateKey) + public function setPrivateKey(string $privateKey) { $this->set("PrivateKey", $privateKey); } - /** * CACert: CA颁发证书内容 * @@ -164,7 +159,7 @@ public function getCACert() * * @param string $caCert */ - public function setCACert($caCert) + public function setCACert(string $caCert) { $this->set("CACert", $caCert); } diff --git a/src/PathX/Apis/CreatePathXSSLResponse.php b/src/PathX/Apis/CreatePathXSSLResponse.php index 5241c020..bd5f179a 100644 --- a/src/PathX/Apis/CreatePathXSSLResponse.php +++ b/src/PathX/Apis/CreatePathXSSLResponse.php @@ -1,6 +1,7 @@ set("SSLId", $sslId); } diff --git a/src/PathX/Apis/CreateUGA3InstanceRequest.php b/src/PathX/Apis/CreateUGA3InstanceRequest.php new file mode 100644 index 00000000..5320fbfa --- /dev/null +++ b/src/PathX/Apis/CreateUGA3InstanceRequest.php @@ -0,0 +1,242 @@ + "CreateUGA3Instance"]); + $this->markRequired("ProjectId"); + $this->markRequired("Bandwidth"); + } + + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * Bandwidth: 实例的共享带宽大小,单位Mbps + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 实例的共享带宽大小,单位Mbps + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * Name: 加速配置实例名称,默认PathX + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 加速配置实例名称,默认PathX + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * AreaCode: 非必填,如果不填,会根据Domain 和IPList 去选一个最近的源站区域BKK表示AreaCode;曼谷表示Area["BKK":"曼谷","DXB":"迪拜","FRA":"法兰克福","SGN":"胡志明市","HKG":"香港",CGK":"雅加达","LOS":"拉各斯","LHR":"伦敦","LAX":"洛杉矶","MNL":"马尼拉","DME":"莫斯科","BOM":"孟买","MSP":"圣保罗","ICN":"首尔","PVG":"上海","SIN":"新加坡","NRT":"东京","IAD":"华盛顿","TPE": "台北"] + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 非必填,如果不填,会根据Domain 和IPList 去选一个最近的源站区域BKK表示AreaCode;曼谷表示Area["BKK":"曼谷","DXB":"迪拜","FRA":"法兰克福","SGN":"胡志明市","HKG":"香港",CGK":"雅加达","LOS":"拉各斯","LHR":"伦敦","LAX":"洛杉矶","MNL":"马尼拉","DME":"莫斯科","BOM":"孟买","MSP":"圣保罗","ICN":"首尔","PVG":"上海","SIN":"新加坡","NRT":"东京","IAD":"华盛顿","TPE": "台北"] + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * Remark: 备注项 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注项 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } + /** + * ChargeType: 支付方式,如按月、按年、按时[Year,Month,Dynamic] + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 支付方式,如按月、按年、按时[Year,Month,Dynamic] + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * Quantity: 购买周期 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买周期 + * + * @param int $quantity + */ + public function setQuantity(int $quantity) + { + $this->set("Quantity", $quantity); + } + /** + * AccelerationArea: 加速大区,默认Global,[ "Global":"全球", "AP":"亚太", "EU":"欧洲", "ME":"中东", "OA":"大洋洲", "AF":"非洲", "NA":"北美洲", "SA":"南美洲"] + * + * @return string|null + */ + public function getAccelerationArea() + { + return $this->get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区,默认Global,[ "Global":"全球", "AP":"亚太", "EU":"欧洲", "ME":"中东", "OA":"大洋洲", "AF":"非洲", "NA":"北美洲", "SA":"南美洲"] + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * OriginIPList: 加速源IP,多个IP用英文半角逗号(,)隔开;IPList和Domain二选一必填 + * + * @return string|null + */ + public function getOriginIPList() + { + return $this->get("OriginIPList"); + } + + /** + * OriginIPList: 加速源IP,多个IP用英文半角逗号(,)隔开;IPList和Domain二选一必填 + * + * @param string $originIPList + */ + public function setOriginIPList(string $originIPList) + { + $this->set("OriginIPList", $originIPList); + } + /** + * OriginDomain: 加速源域名,IPList和Domain二选一必填 + * + * @return string|null + */ + public function getOriginDomain() + { + return $this->get("OriginDomain"); + } + + /** + * OriginDomain: 加速源域名,IPList和Domain二选一必填 + * + * @param string $originDomain + */ + public function setOriginDomain(string $originDomain) + { + $this->set("OriginDomain", $originDomain); + } + /** + * CouponId: 使用代金券可冲抵部分费用,仅全地域可用的代金券 + * + * @return string|null + */ + public function getCouponId() + { + return $this->get("CouponId"); + } + + /** + * CouponId: 使用代金券可冲抵部分费用,仅全地域可用的代金券 + * + * @param string $couponId + */ + public function setCouponId(string $couponId) + { + $this->set("CouponId", $couponId); + } +} diff --git a/src/PathX/Apis/CreateUGA3InstanceResponse.php b/src/PathX/Apis/CreateUGA3InstanceResponse.php new file mode 100644 index 00000000..ad7871c0 --- /dev/null +++ b/src/PathX/Apis/CreateUGA3InstanceResponse.php @@ -0,0 +1,64 @@ +get("InstanceId"); + } + + /** + * InstanceId: 加速配置ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * CName: 加速域名 用户可把业务域名CName到此域名上 + * + * @return string|null + */ + public function getCName() + { + return $this->get("CName"); + } + + /** + * CName: 加速域名 用户可把业务域名CName到此域名上 + * + * @param string $cName + */ + public function setCName(string $cName) + { + $this->set("CName", $cName); + } +} diff --git a/src/PathX/Apis/CreateUGA3PortRequest.php b/src/PathX/Apis/CreateUGA3PortRequest.php new file mode 100644 index 00000000..85490437 --- /dev/null +++ b/src/PathX/Apis/CreateUGA3PortRequest.php @@ -0,0 +1,109 @@ + "CreateUGA3Port"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * TCP: TCP接入端口,禁用65123端口 + * + * @return int[]|null + */ + public function getTCP() + { + return $this->get("TCP"); + } + + /** + * TCP: TCP接入端口,禁用65123端口 + * + * @param int[] $tcp + */ + public function setTCP(array $tcp) + { + $this->set("TCP", $tcp); + } + /** + * TCPRS: TCP回源端口 + * + * @return int[]|null + */ + public function getTCPRS() + { + return $this->get("TCPRS"); + } + + /** + * TCPRS: TCP回源端口 + * + * @param int[] $tcprs + */ + public function setTCPRS(array $tcprs) + { + $this->set("TCPRS", $tcprs); + } +} diff --git a/src/UHost/Params/GetUHostInstancePriceParamVolumes.php b/src/PathX/Apis/CreateUGA3PortResponse.php similarity index 77% rename from src/UHost/Params/GetUHostInstancePriceParamVolumes.php rename to src/PathX/Apis/CreateUGA3PortResponse.php index 750a34e6..195450d5 100644 --- a/src/UHost/Params/GetUHostInstancePriceParamVolumes.php +++ b/src/PathX/Apis/CreateUGA3PortResponse.php @@ -1,6 +1,7 @@ markRequired("UGAId"); } - /** * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID * @@ -64,11 +64,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * HTTPHTTP: HTTP接入HTTP回源转发,接入端口。禁用65123端口 * @@ -88,7 +87,6 @@ public function setHTTPHTTP(array $httphttp) { $this->set("HTTPHTTP", $httphttp); } - /** * HTTPHTTPRS: HTTP接入HTTP回源转发,源站监听端口 * @@ -108,7 +106,6 @@ public function setHTTPHTTPRS(array $httphttprs) { $this->set("HTTPHTTPRS", $httphttprs); } - /** * HTTPSHTTP: HTTPS接入HTTP回源转发,接入端口。禁用65123端口 * @@ -128,7 +125,6 @@ public function setHTTPSHTTP(array $httpshttp) { $this->set("HTTPSHTTP", $httpshttp); } - /** * HTTPSHTTPRS: HTTPS接入HTTP回源转发,回源端口 * @@ -148,7 +144,6 @@ public function setHTTPSHTTPRS(array $httpshttprs) { $this->set("HTTPSHTTPRS", $httpshttprs); } - /** * HTTPSHTTPS: HTTPS接入HTTPS回源转发,接入端口。禁用65123端口 * @@ -168,7 +163,6 @@ public function setHTTPSHTTPS(array $httpshttps) { $this->set("HTTPSHTTPS", $httpshttps); } - /** * HTTPSHTTPSRS: HTTPS接入HTTPS回源转发,源站监听端口 * @@ -188,7 +182,6 @@ public function setHTTPSHTTPSRS(array $httpshttpsrs) { $this->set("HTTPSHTTPSRS", $httpshttpsrs); } - /** * TCP: TCP接入端口,禁用65123端口 * @@ -208,7 +201,6 @@ public function setTCP(array $tcp) { $this->set("TCP", $tcp); } - /** * TCPRS: TCP回源端口 * @@ -228,7 +220,6 @@ public function setTCPRS(array $tcprs) { $this->set("TCPRS", $tcprs); } - /** * UDP: UDP接入端口,禁用65123端口 * @@ -248,7 +239,6 @@ public function setUDP(array $udp) { $this->set("UDP", $udp); } - /** * UDPRS: UDP回源端口 * @@ -268,7 +258,6 @@ public function setUDPRS(array $udprs) { $this->set("UDPRS", $udprs); } - /** * WSWS: WebSocket接入WebSocket回源转发,接入端口。禁用65123。 * @@ -288,7 +277,6 @@ public function setWSWS(array $wsws) { $this->set("WSWS", $wsws); } - /** * WSWSRS: WebSocket接入WebSocket回源转发,源站监听端口 * @@ -308,7 +296,6 @@ public function setWSWSRS(array $wswsrs) { $this->set("WSWSRS", $wswsrs); } - /** * WSSWSS: WebSocketS接入WebSocketS回源转发,接入端口。禁用65123。 * @@ -328,7 +315,6 @@ public function setWSSWSS(array $wsswss) { $this->set("WSSWSS", $wsswss); } - /** * WSSWSSRS: WebSocketS接入WebSocketS回源转发,源站监听端口。 * @@ -348,7 +334,6 @@ public function setWSSWSSRS(array $wsswssrs) { $this->set("WSSWSSRS", $wsswssrs); } - /** * WSSWS: WebSocketS接入WebSocket回源转发,接入端口。禁用65123。 * @@ -368,7 +353,6 @@ public function setWSSWS(array $wssws) { $this->set("WSSWS", $wssws); } - /** * WSSWSRS: WebSocketS接入WebSocket回源转发,源站监听端口。 * diff --git a/src/PathX/Apis/CreateUGAForwarderResponse.php b/src/PathX/Apis/CreateUGAForwarderResponse.php index 986af719..2e73e51e 100644 --- a/src/PathX/Apis/CreateUGAForwarderResponse.php +++ b/src/PathX/Apis/CreateUGAForwarderResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 加速配置实例名称 * @@ -64,11 +64,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * IPList: 加速源IP,多个IP用英文半角逗号(,)隔开;IPList和Domain二选一必填 * @@ -84,11 +83,10 @@ public function getIPList() * * @param string $ipList */ - public function setIPList($ipList) + public function setIPList(string $ipList) { $this->set("IPList", $ipList); } - /** * Domain: 加速源域名,IPList和Domain二选一必填 * @@ -104,11 +102,10 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * TCP: TCP端口号,已废弃。请使用 CreateUGAForwarder API 创建端口 * @@ -128,7 +125,6 @@ public function setTCP(array $tcp) { $this->set("TCP", $tcp); } - /** * UDP: UDP端口号,已废弃。请使用 CreateUGAForwarder API 创建端口 * diff --git a/src/PathX/Apis/CreateUGAInstanceResponse.php b/src/PathX/Apis/CreateUGAInstanceResponse.php index b9b22086..a346aa5e 100644 --- a/src/PathX/Apis/CreateUGAInstanceResponse.php +++ b/src/PathX/Apis/CreateUGAInstanceResponse.php @@ -1,6 +1,7 @@ set("UGAId", $ugaId); } - /** * CName: 加速域名 用户可把业务域名CName到此域名上。注意:未绑定线路情况时 加速域名解析不出IP。 * @@ -57,7 +57,7 @@ public function getCName() * * @param string $cName */ - public function setCName($cName) + public function setCName(string $cName) { $this->set("CName", $cName); } diff --git a/src/PathX/Apis/CreateUPathRequest.php b/src/PathX/Apis/CreateUPathRequest.php index 9177b52e..3e276186 100644 --- a/src/PathX/Apis/CreateUPathRequest.php +++ b/src/PathX/Apis/CreateUPathRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** - * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -42,17 +43,16 @@ public function getProjectId() } /** - * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * Name: UPath名字 + * Name: 名字,便于记忆区分 * * @return string|null */ @@ -62,17 +62,16 @@ public function getName() } /** - * Name: UPath名字 + * Name: 名字,便于记忆区分 * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** - * LineId: 选择的线路 + * LineId: 选择的线路,由DescribePathXLineConfig接口提供 * * @return string|null */ @@ -82,17 +81,16 @@ public function getLineId() } /** - * LineId: 选择的线路 + * LineId: 选择的线路,由DescribePathXLineConfig接口提供 * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } - /** - * Bandwidth: 线路带宽,最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。如需更大带宽,请联系产品团队。 + * Bandwidth: 当PostPaid为false时,该值为预付费固定带宽;当PostPaid为true时,该值为后付费保底带宽,保底带宽越大可用的上限带宽越大。最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。可联系产品团队咨询最大带宽。 * * @return integer|null */ @@ -102,15 +100,14 @@ public function getBandwidth() } /** - * Bandwidth: 线路带宽,最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。如需更大带宽,请联系产品团队。 + * Bandwidth: 当PostPaid为false时,该值为预付费固定带宽;当PostPaid为true时,该值为后付费保底带宽,保底带宽越大可用的上限带宽越大。最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。可联系产品团队咨询最大带宽。 * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * ChargeType: 计费模式,默认为Month 按月收费,可选范围['Month','Year','Dynamic'] * @@ -126,11 +123,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买周期,ChargeType为Month时,Quantity默认为0代表购买到月底,按时和按年付费该参数必须大于0 * @@ -146,13 +142,12 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** - * PostPaid: 是否开启后付费, 默认为false + * PostPaid: 是否开启后付费, 默认为false ,不开启后付费。当ChargeType为Dynamic时不能开启后付费。 * * @return boolean|null */ @@ -162,15 +157,33 @@ public function getPostPaid() } /** - * PostPaid: 是否开启后付费, 默认为false + * PostPaid: 是否开启后付费, 默认为false ,不开启后付费。当ChargeType为Dynamic时不能开启后付费。 * * @param boolean $postPaid */ - public function setPostPaid($postPaid) + public function setPostPaid(bool $postPaid) { $this->set("PostPaid", $postPaid); } + /** + * PathType: private:专线线路;public:海外SD-WAN。默认为private。 + * + * @return string|null + */ + public function getPathType() + { + return $this->get("PathType"); + } + /** + * PathType: private:专线线路;public:海外SD-WAN。默认为private。 + * + * @param string $pathType + */ + public function setPathType(string $pathType) + { + $this->set("PathType", $pathType); + } /** * CouponId: 代金券Id * @@ -186,7 +199,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/PathX/Apis/CreateUPathResponse.php b/src/PathX/Apis/CreateUPathResponse.php index e11e2cd3..08bc5763 100644 --- a/src/PathX/Apis/CreateUPathResponse.php +++ b/src/PathX/Apis/CreateUPathResponse.php @@ -1,6 +1,7 @@ get("UPathId"); + return $this->get("PathId"); } /** - * UPathId: 加速线路实例Id + * PathId: 加速线路实例Id * - * @param string $uPathId + * @param string $pathId */ - public function setUPathId($uPathId) + public function setPathId(string $pathId) { - $this->set("UPathId", $uPathId); + $this->set("PathId", $pathId); } } diff --git a/src/PathX/Apis/DeleteGlobalSSHInstanceRequest.php b/src/PathX/Apis/DeleteGlobalSSHInstanceRequest.php index 71e3ff18..bd3e2cb8 100644 --- a/src/PathX/Apis/DeleteGlobalSSHInstanceRequest.php +++ b/src/PathX/Apis/DeleteGlobalSSHInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("InstanceId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: 实例Id,资源的唯一标识 * @@ -64,7 +64,7 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } diff --git a/src/PathX/Apis/DeleteGlobalSSHInstanceResponse.php b/src/PathX/Apis/DeleteGlobalSSHInstanceResponse.php index e8b4ff28..555086ad 100644 --- a/src/PathX/Apis/DeleteGlobalSSHInstanceResponse.php +++ b/src/PathX/Apis/DeleteGlobalSSHInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("SSLId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLId: SSL证书的ID * @@ -64,7 +64,7 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } diff --git a/src/PathX/Apis/DeletePathXSSLResponse.php b/src/PathX/Apis/DeletePathXSSLResponse.php index ae8fc442..f039c0d7 100644 --- a/src/PathX/Apis/DeletePathXSSLResponse.php +++ b/src/PathX/Apis/DeletePathXSSLResponse.php @@ -1,6 +1,7 @@ "DeleteUGA3Instance"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 实例Id,资源的唯一标识 + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 实例Id,资源的唯一标识 + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } +} diff --git a/src/UHost/Params/GetUHostInstancePriceParamVirtualGpu.php b/src/PathX/Apis/DeleteUGA3InstanceResponse.php similarity index 76% rename from src/UHost/Params/GetUHostInstancePriceParamVirtualGpu.php rename to src/PathX/Apis/DeleteUGA3InstanceResponse.php index a06c3580..57b6c006 100644 --- a/src/UHost/Params/GetUHostInstancePriceParamVirtualGpu.php +++ b/src/PathX/Apis/DeleteUGA3InstanceResponse.php @@ -1,6 +1,7 @@ "DeleteUGA3Port"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * TCP: TCP接入端口 + * + * @return int[]|null + */ + public function getTCP() + { + return $this->get("TCP"); + } + + /** + * TCP: TCP接入端口 + * + * @param int[] $tcp + */ + public function setTCP(array $tcp) + { + $this->set("TCP", $tcp); + } +} diff --git a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceIPv6.php b/src/PathX/Apis/DeleteUGA3PortResponse.php similarity index 76% rename from src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceIPv6.php rename to src/PathX/Apis/DeleteUGA3PortResponse.php index d8c3a58c..3b5381c8 100644 --- a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceIPv6.php +++ b/src/PathX/Apis/DeleteUGA3PortResponse.php @@ -1,6 +1,7 @@ markRequired("UGAId"); } - /** * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID * @@ -64,11 +64,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * HTTPHTTP: HTTP接入HTTP回源,接入端口。禁用65123端口 * @@ -88,7 +87,6 @@ public function setHTTPHTTP(array $httphttp) { $this->set("HTTPHTTP", $httphttp); } - /** * HTTPSHTTP: HTTPS接入HTTP回源, 接入端口。禁用65123端口 * @@ -108,7 +106,6 @@ public function setHTTPSHTTP(array $httpshttp) { $this->set("HTTPSHTTP", $httpshttp); } - /** * HTTPSHTTPS: HTTPS接入HTTPS回源, 接入端口。禁用65123端口 * @@ -128,7 +125,6 @@ public function setHTTPSHTTPS(array $httpshttps) { $this->set("HTTPSHTTPS", $httpshttps); } - /** * WSSWSS: WebSocketS接入WebSocketS回源, 接入端口。禁用65123端口 * @@ -148,7 +144,6 @@ public function setWSSWSS(array $wsswss) { $this->set("WSSWSS", $wsswss); } - /** * WSWS: WebSocket接入WebSocket回源, 接入端口。禁用65123端口 * @@ -168,7 +163,6 @@ public function setWSWS(array $wsws) { $this->set("WSWS", $wsws); } - /** * WSSWS: WebSocketS接入WebSocket回源, 接入端口。禁用65123端口。 * @@ -188,7 +182,6 @@ public function setWSSWS(array $wssws) { $this->set("WSSWS", $wssws); } - /** * TCP: TCP接入端口 * @@ -208,7 +201,6 @@ public function setTCP(array $tcp) { $this->set("TCP", $tcp); } - /** * UDP: UDP接入端口 * diff --git a/src/PathX/Apis/DeleteUGAForwarderResponse.php b/src/PathX/Apis/DeleteUGAForwarderResponse.php index b92d63c7..1cbb3079 100644 --- a/src/PathX/Apis/DeleteUGAForwarderResponse.php +++ b/src/PathX/Apis/DeleteUGAForwarderResponse.php @@ -1,6 +1,7 @@ markRequired("UGAId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID * @@ -64,7 +64,7 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } diff --git a/src/PathX/Apis/DeleteUGAInstanceResponse.php b/src/PathX/Apis/DeleteUGAInstanceResponse.php index 0aadcd00..5c6f410a 100644 --- a/src/PathX/Apis/DeleteUGAInstanceResponse.php +++ b/src/PathX/Apis/DeleteUGAInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("UPathId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UPathId: 加速线路实例ID * @@ -64,7 +64,7 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } diff --git a/src/PathX/Apis/DeleteUPathResponse.php b/src/PathX/Apis/DeleteUPathResponse.php index 75ee9f94..dc20540e 100644 --- a/src/PathX/Apis/DeleteUPathResponse.php +++ b/src/PathX/Apis/DeleteUPathResponse.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: 实例ID,资源唯一标识 * @@ -63,7 +63,7 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } diff --git a/src/PathX/Apis/DescribeGlobalSSHInstanceResponse.php b/src/PathX/Apis/DescribeGlobalSSHInstanceResponse.php index c1f6114f..09b3ed3b 100644 --- a/src/PathX/Apis/DescribeGlobalSSHInstanceResponse.php +++ b/src/PathX/Apis/DescribeGlobalSSHInstanceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new GlobalSSHInfo($item)); + array_push($result, new GlobalSSHInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getInstanceSet() /** * InstanceSet: GlobalSSH实例列表,实例的属性参考GlobalSSHInfo模型 * - * @param GlobalSSHInfo[] $instanceSet + * @param GlobalSSHInfoModel[] $instanceSet */ public function setInstanceSet(array $instanceSet) { diff --git a/src/PathX/Apis/DescribePathXLineConfigRequest.php b/src/PathX/Apis/DescribePathXLineConfigRequest.php index 29455f66..a3f48228 100644 --- a/src/PathX/Apis/DescribePathXLineConfigRequest.php +++ b/src/PathX/Apis/DescribePathXLineConfigRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,7 +44,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/PathX/Apis/DescribePathXLineConfigResponse.php b/src/PathX/Apis/DescribePathXLineConfigResponse.php index 377894e6..ac15edd1 100644 --- a/src/PathX/Apis/DescribePathXLineConfigResponse.php +++ b/src/PathX/Apis/DescribePathXLineConfigResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UGAALine($item)); + array_push($result, new UGAALineModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getLineSet() /** * LineSet: UGAA线路列表,参考UGAALine字段定义 * - * @param UGAALine[] $lineSet + * @param UGAALineModel[] $lineSet */ public function setLineSet(array $lineSet) { diff --git a/src/PathX/Apis/DescribePathXSSLRequest.php b/src/PathX/Apis/DescribePathXSSLRequest.php index f3b26b4d..ca17c462 100644 --- a/src/PathX/Apis/DescribePathXSSLRequest.php +++ b/src/PathX/Apis/DescribePathXSSLRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLId: SSL证书的Id,不传分页获取证书列表 * @@ -63,11 +63,10 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } - /** * SearchValue: 不为空则按证书名称、证书域名模糊搜索 分页返回结果 * @@ -83,11 +82,10 @@ public function getSearchValue() * * @param string $searchValue */ - public function setSearchValue($searchValue) + public function setSearchValue(string $searchValue) { $this->set("SearchValue", $searchValue); } - /** * Limit: 最大返回条数,默认100,最大400 * @@ -103,11 +101,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 偏移值 默认为0 * @@ -123,7 +120,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/PathX/Apis/DescribePathXSSLResponse.php b/src/PathX/Apis/DescribePathXSSLResponse.php index 41b0a38d..1aea580a 100644 --- a/src/PathX/Apis/DescribePathXSSLResponse.php +++ b/src/PathX/Apis/DescribePathXSSLResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new PathXSSLSet($item)); + array_push($result, new PathXSSLSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: SSL证书详细信息,具体结构见 PathXSSLSet * - * @param PathXSSLSet[] $dataSet + * @param PathXSSLSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -55,7 +57,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 符合条件的证书总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/PathX/Apis/DescribeUGA3AreaRequest.php b/src/PathX/Apis/DescribeUGA3AreaRequest.php new file mode 100644 index 00000000..3020ef45 --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3AreaRequest.php @@ -0,0 +1,88 @@ + "DescribeUGA3Area"]); + } + + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * IPList: IP集合,非必填。如果填IP或者域名,会推荐一个地域在返回列表的第一个,源站IP集合,以逗号分隔[127.0.0.1,127.0.0.2] + * + * @return string|null + */ + public function getIPList() + { + return $this->get("IPList"); + } + + /** + * IPList: IP集合,非必填。如果填IP或者域名,会推荐一个地域在返回列表的第一个,源站IP集合,以逗号分隔[127.0.0.1,127.0.0.2] + * + * @param string $ipList + */ + public function setIPList(string $ipList) + { + $this->set("IPList", $ipList); + } + /** + * Domain: 域名,非必填。如果填IP或者域名,会推荐一个地域在返回列表的第一个 + * + * @return string|null + */ + public function getDomain() + { + return $this->get("Domain"); + } + + /** + * Domain: 域名,非必填。如果填IP或者域名,会推荐一个地域在返回列表的第一个 + * + * @param string $domain + */ + public function setDomain(string $domain) + { + $this->set("Domain", $domain); + } +} diff --git a/src/PathX/Apis/DescribeUGA3AreaResponse.php b/src/PathX/Apis/DescribeUGA3AreaResponse.php new file mode 100644 index 00000000..1f501c3b --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3AreaResponse.php @@ -0,0 +1,59 @@ +get("AreaSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new ForwardAreaModel($item)); + } + return $result; + } + + /** + * AreaSet: 支持源站的地区,比如:AreaSet[{ "Area": "首尔", "AreaCode": "ICN", "CountryCode": "CN", "ContinentCode": "CN" }]ContinentCode:["CN","NA","OT"];"CN":表示国内,"NA":表示美洲,“OT":表示欧洲等其他地区 + * + * @param ForwardAreaModel[] $areaSet + */ + public function setAreaSet(array $areaSet) + { + $result = []; + foreach ($areaSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/PathX/Apis/DescribeUGA3InstanceRequest.php b/src/PathX/Apis/DescribeUGA3InstanceRequest.php new file mode 100644 index 00000000..44dc96fa --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3InstanceRequest.php @@ -0,0 +1,108 @@ + "DescribeUGA3Instance"]); + $this->markRequired("ProjectId"); + } + + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID,如果传了实例ID 则返回匹配实例ID的记录;如果没传则返回 ProjectId 下全部实例且符合分页要求 + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID,如果传了实例ID 则返回匹配实例ID的记录;如果没传则返回 ProjectId 下全部实例且符合分页要求 + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Limit: 返回的最大条数,默认为100,最大值400 + * + * @return integer|null + */ + public function getLimit() + { + return $this->get("Limit"); + } + + /** + * Limit: 返回的最大条数,默认为100,最大值400 + * + * @param int $limit + */ + public function setLimit(int $limit) + { + $this->set("Limit", $limit); + } + /** + * Offset: 偏移量,默认为0 + * + * @return integer|null + */ + public function getOffset() + { + return $this->get("Offset"); + } + + /** + * Offset: 偏移量,默认为0 + * + * @param int $offset + */ + public function setOffset(int $offset) + { + $this->set("Offset", $offset); + } +} diff --git a/src/PathX/Apis/DescribeUGA3InstanceResponse.php b/src/PathX/Apis/DescribeUGA3InstanceResponse.php new file mode 100644 index 00000000..e3e7617d --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3InstanceResponse.php @@ -0,0 +1,82 @@ +get("ForwardInstanceInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new ForwardInfoModel($item)); + } + return $result; + } + + /** + * ForwardInstanceInfos: 全球加速实例信息列表 + * + * @param ForwardInfoModel[] $forwardInstanceInfos + */ + public function setForwardInstanceInfos(array $forwardInstanceInfos) + { + $result = []; + foreach ($forwardInstanceInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * TotalCount: 符合条件的总数 + * + * @return integer|null + */ + public function getTotalCount() + { + return $this->get("TotalCount"); + } + + /** + * TotalCount: 符合条件的总数 + * + * @param int $totalCount + */ + public function setTotalCount(int $totalCount) + { + $this->set("TotalCount", $totalCount); + } +} diff --git a/src/PathX/Apis/DescribeUGA3OptimizationRequest.php b/src/PathX/Apis/DescribeUGA3OptimizationRequest.php new file mode 100644 index 00000000..55cb538e --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3OptimizationRequest.php @@ -0,0 +1,108 @@ + "DescribeUGA3Optimization"]); + $this->markRequired("AreaCode"); + } + + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * AreaCode: 源站AreaCode + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 源站AreaCode + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * TimeRange: 默认一天 ,枚举类型["Hour","Day","Week"] + * + * @return string|null + */ + public function getTimeRange() + { + return $this->get("TimeRange"); + } + + /** + * TimeRange: 默认一天 ,枚举类型["Hour","Day","Week"] + * + * @param string $timeRange + */ + public function setTimeRange(string $timeRange) + { + $this->set("TimeRange", $timeRange); + } + /** + * AccelerationArea: 加速大区,默认Global,[ "Global":"全球", "AP":"亚太", "EU":"欧洲", "ME":"中东", "OA":"大洋洲", "AF":"非洲", "NA":"北美洲", "SA":"南美洲"] + * + * @return string|null + */ + public function getAccelerationArea() + { + return $this->get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区,默认Global,[ "Global":"全球", "AP":"亚太", "EU":"欧洲", "ME":"中东", "OA":"大洋洲", "AF":"非洲", "NA":"北美洲", "SA":"南美洲"] + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } +} diff --git a/src/PathX/Apis/DescribeUGA3OptimizationResponse.php b/src/PathX/Apis/DescribeUGA3OptimizationResponse.php new file mode 100644 index 00000000..8c9fcc6a --- /dev/null +++ b/src/PathX/Apis/DescribeUGA3OptimizationResponse.php @@ -0,0 +1,60 @@ +get("AccelerationInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new AccelerationInfoModel($item)); + } + return $result; + } + + /** + * AccelerationInfos: 加速详情 + * + * @param AccelerationInfoModel[] $accelerationInfos + */ + public function setAccelerationInfos(array $accelerationInfos) + { + $result = []; + foreach ($accelerationInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/PathX/Apis/DescribeUGAInstanceRequest.php b/src/PathX/Apis/DescribeUGAInstanceRequest.php index c19a7672..e1d2a7c3 100644 --- a/src/PathX/Apis/DescribeUGAInstanceRequest.php +++ b/src/PathX/Apis/DescribeUGAInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID,如果传了实例ID 则返回匹配实例ID的记录;如果没传则返回 ProjectId 下全部实例且符合分页要求 * @@ -63,11 +63,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * Limit: 返回的最大条数,默认为100,最大值400 * @@ -83,11 +82,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 偏移量,默认为0 * @@ -103,7 +101,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/PathX/Apis/DescribeUGAInstanceResponse.php b/src/PathX/Apis/DescribeUGAInstanceResponse.php index fccaef80..05042ea5 100644 --- a/src/PathX/Apis/DescribeUGAInstanceResponse.php +++ b/src/PathX/Apis/DescribeUGAInstanceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UGAAInfo($item)); + array_push($result, new UGAAInfoModel($item)); } return $result; } @@ -49,7 +51,7 @@ public function getUGAList() /** * UGAList: 全球加速实例信息列表 * - * @param UGAAInfo[] $ugaList + * @param UGAAInfoModel[] $ugaList */ public function setUGAList(array $ugaList) { @@ -59,7 +61,6 @@ public function setUGAList(array $ugaList) } return $result; } - /** * TotalCount: 符合条件的总数 * @@ -75,7 +76,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/PathX/Apis/DescribeUPathRequest.php b/src/PathX/Apis/DescribeUPathRequest.php index b96e40c5..463fa405 100644 --- a/src/PathX/Apis/DescribeUPathRequest.php +++ b/src/PathX/Apis/DescribeUPathRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UPathId: 如果不填参数 返回 ProjectId 下所有的线路资源,填此参数则返回upath实例ID匹配的线路 * @@ -63,7 +63,7 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } diff --git a/src/PathX/Apis/DescribeUPathResponse.php b/src/PathX/Apis/DescribeUPathResponse.php index a60d4a9f..0c65d452 100644 --- a/src/PathX/Apis/DescribeUPathResponse.php +++ b/src/PathX/Apis/DescribeUPathResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UPathInfo($item)); + array_push($result, new UPathInfoModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getUPathSet() /** * UPathSet: 线路信息数组 * - * @param UPathInfo[] $uPathSet + * @param UPathInfoModel[] $uPathSet */ public function setUPathSet(array $uPathSet) { diff --git a/src/PathX/Apis/DescribeUPathTemplateRequest.php b/src/PathX/Apis/DescribeUPathTemplateRequest.php index 353df710..fb496326 100644 --- a/src/PathX/Apis/DescribeUPathTemplateRequest.php +++ b/src/PathX/Apis/DescribeUPathTemplateRequest.php @@ -1,6 +1,7 @@ markRequired("UPathId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UPathId: 加速线路实例ID,格式 upath-xxxx * @@ -64,7 +64,7 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } diff --git a/src/PathX/Apis/DescribeUPathTemplateResponse.php b/src/PathX/Apis/DescribeUPathTemplateResponse.php index 46dd693f..82320067 100644 --- a/src/PathX/Apis/DescribeUPathTemplateResponse.php +++ b/src/PathX/Apis/DescribeUPathTemplateResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new AlarmRuler($item)); + array_push($result, new AlarmRulerModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 监控模板详情 * - * @param AlarmRuler[] $dataSet + * @param AlarmRulerModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/PathX/Apis/GetGlobalSSHPriceRequest.php b/src/PathX/Apis/GetGlobalSSHPriceRequest.php index a871f320..afe07433 100644 --- a/src/PathX/Apis/GetGlobalSSHPriceRequest.php +++ b/src/PathX/Apis/GetGlobalSSHPriceRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Quantity: 购买周期,如果ChargeType为Month,Quantity默认为0;其他情况必须为大于0的整数 * @@ -63,11 +63,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ChargeType: 计费类型:Dynamic,Month,Year * @@ -83,11 +82,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * InstanceType: 版本类型。枚举值,Enterprise:企业版;Basic:基础版。可不填,默认为Basic。 * @@ -103,7 +101,7 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } diff --git a/src/PathX/Apis/GetGlobalSSHPriceResponse.php b/src/PathX/Apis/GetGlobalSSHPriceResponse.php index a48ba710..4f6a6532 100644 --- a/src/PathX/Apis/GetGlobalSSHPriceResponse.php +++ b/src/PathX/Apis/GetGlobalSSHPriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/PathX/Apis/GetGlobalSSHUpdatePriceRequest.php b/src/PathX/Apis/GetGlobalSSHUpdatePriceRequest.php index 51253a10..944f9719 100644 --- a/src/PathX/Apis/GetGlobalSSHUpdatePriceRequest.php +++ b/src/PathX/Apis/GetGlobalSSHUpdatePriceRequest.php @@ -1,6 +1,7 @@ markRequired("InstanceType"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceType: 升级后的实例类型。枚举值,Enterprise:企业版;Basic:基础版。 * @@ -64,11 +64,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * InstanceId: 实例ID,唯一资源标识。从免费版升级到付费版可不填,其他情况必填。 * @@ -84,11 +83,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * Quantity: 购买周期,如果ChargeType为Month,Quantity可以不填默认为0;其他情况必须为正整数。 * @@ -104,11 +102,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ChargeType: 计费类型:Dynamic,Month,Year。从免费版升级到付费版必须传,其他情况不需要传 * @@ -124,7 +121,7 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } diff --git a/src/PathX/Apis/GetGlobalSSHUpdatePriceResponse.php b/src/PathX/Apis/GetGlobalSSHUpdatePriceResponse.php index e894e44a..0deb4150 100644 --- a/src/PathX/Apis/GetGlobalSSHUpdatePriceResponse.php +++ b/src/PathX/Apis/GetGlobalSSHUpdatePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/PathX/Apis/GetPathXMetricRequest.php b/src/PathX/Apis/GetPathXMetricRequest.php index e4b0802d..cfad8e6b 100644 --- a/src/PathX/Apis/GetPathXMetricRequest.php +++ b/src/PathX/Apis/GetPathXMetricRequest.php @@ -1,6 +1,7 @@ markRequired("LineId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -49,11 +50,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ResourceId: ResourceId,如upath ID 和 uga ID * @@ -69,11 +69,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * BeginTime: 查询起始时间,10位长度时间戳 * @@ -89,11 +88,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询结束时间,10位长度时间戳 * @@ -109,11 +107,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * MetricName: 查询监控的指标项。目前仅允许以下四项:NetworkOut:出向带宽,NetworkIn:入向带宽,NetworkOutUsage:出向带宽使用率,NetworkInUsage:入向带宽使用率 * @@ -133,7 +130,6 @@ public function setMetricName(array $metricName) { $this->set("MetricName", $metricName); } - /** * ResourceType: upath:加速线路,uga:加速实例 * @@ -149,11 +145,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * LineId: 具体线路id,调用DescribePathXLineConfig接口获取线路列表 * @@ -169,7 +164,7 @@ public function getLineId() * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } diff --git a/src/PathX/Apis/GetPathXMetricResponse.php b/src/PathX/Apis/GetPathXMetricResponse.php index 36e16809..1951e4f8 100644 --- a/src/PathX/Apis/GetPathXMetricResponse.php +++ b/src/PathX/Apis/GetPathXMetricResponse.php @@ -1,6 +1,7 @@ get("DataSet")); + return new MetricPeriodModel($this->get("DataSet")); } /** * DataSet: 监控数据结果集 * - * @param MetricPeriod $dataSet + * @param MetricPeriodModel $dataSet */ - public function setDataSet(array $dataSet) + public function setDataSet(MetricPeriodModel $dataSet) { $this->set("DataSet", $dataSet->getAll()); } diff --git a/src/PathX/Apis/GetUGA3MetricRequest.php b/src/PathX/Apis/GetUGA3MetricRequest.php new file mode 100644 index 00000000..b38666dc --- /dev/null +++ b/src/PathX/Apis/GetUGA3MetricRequest.php @@ -0,0 +1,168 @@ + "GetUGA3Metric"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + $this->markRequired("BeginTime"); + $this->markRequired("EndTime"); + } + + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 资源ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 资源ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * BeginTime: 查询起始时间,10位长度时间戳 + * + * @return integer|null + */ + public function getBeginTime() + { + return $this->get("BeginTime"); + } + + /** + * BeginTime: 查询起始时间,10位长度时间戳 + * + * @param int $beginTime + */ + public function setBeginTime(int $beginTime) + { + $this->set("BeginTime", $beginTime); + } + /** + * EndTime: 查询结束时间,10位长度时间戳 + * + * @return integer|null + */ + public function getEndTime() + { + return $this->get("EndTime"); + } + + /** + * EndTime: 查询结束时间,10位长度时间戳 + * + * @param int $endTime + */ + public function setEndTime(int $endTime) + { + $this->set("EndTime", $endTime); + } + /** + * MetricName: 查询监控的指标项。可不传 NetworkOut:出口总带宽 NetworkIn:入口总带宽 NetworkOutUsage:出口带宽使用率 NetworkInUsage:入口总带宽使用率 NetworkOutSubline :子线路出口带宽 NetworkInSubline:子线路入口带宽 Delay:线路平均延迟 DelaySubline:子线路延迟 ConnectCount:当前连接数 ConnectCountSubline:子线路当前连接数 DelayPromote:延迟提升 DelayPromoteSubline:子线路延迟提升 + * + * @return string[]|null + */ + public function getMetricName() + { + return $this->get("MetricName"); + } + + /** + * MetricName: 查询监控的指标项。可不传 NetworkOut:出口总带宽 NetworkIn:入口总带宽 NetworkOutUsage:出口带宽使用率 NetworkInUsage:入口总带宽使用率 NetworkOutSubline :子线路出口带宽 NetworkInSubline:子线路入口带宽 Delay:线路平均延迟 DelaySubline:子线路延迟 ConnectCount:当前连接数 ConnectCountSubline:子线路当前连接数 DelayPromote:延迟提升 DelayPromoteSubline:子线路延迟提升 + * + * @param string[] $metricName + */ + public function setMetricName(array $metricName) + { + $this->set("MetricName", $metricName); + } + /** + * IsSubline: 是否为子线路。为了简化查询,true 会返回所有子线路监控项可以,false:返回所有汇总的监控数据 + * + * @return boolean|null + */ + public function getIsSubline() + { + return $this->get("IsSubline"); + } + + /** + * IsSubline: 是否为子线路。为了简化查询,true 会返回所有子线路监控项可以,false:返回所有汇总的监控数据 + * + * @param boolean $isSubline + */ + public function setIsSubline(bool $isSubline) + { + $this->set("IsSubline", $isSubline); + } + /** + * AreaCode: 子线路AreaCode ,子线路的时候传,不是子线路可以不传 + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 子线路AreaCode ,子线路的时候传,不是子线路可以不传 + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } +} diff --git a/src/PathX/Apis/GetUGA3MetricResponse.php b/src/PathX/Apis/GetUGA3MetricResponse.php new file mode 100644 index 00000000..3c65d62f --- /dev/null +++ b/src/PathX/Apis/GetUGA3MetricResponse.php @@ -0,0 +1,48 @@ +get("DataSet")); + } + + /** + * DataSet: 监控数据结果集 + * + * @param UGA3MetricModel $dataSet + */ + public function setDataSet(UGA3MetricModel $dataSet) + { + $this->set("DataSet", $dataSet->getAll()); + } +} diff --git a/src/PathX/Apis/GetUGA3PriceRequest.php b/src/PathX/Apis/GetUGA3PriceRequest.php new file mode 100644 index 00000000..c17e49b6 --- /dev/null +++ b/src/PathX/Apis/GetUGA3PriceRequest.php @@ -0,0 +1,148 @@ + "GetUGA3Price"]); + $this->markRequired("ProjectId"); + $this->markRequired("Bandwidth"); + $this->markRequired("AreaCode"); + } + + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * Bandwidth: 共享带宽大小 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 共享带宽大小 + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * AreaCode: 源站区域 + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 源站区域 + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * Quantity: 购买时间数量,当ChargeType为Month时 Quantity默认为0,代表购买至月底。按年按小时必须为大于0 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买时间数量,当ChargeType为Month时 Quantity默认为0,代表购买至月底。按年按小时必须为大于0 + * + * @param int $quantity + */ + public function setQuantity(int $quantity) + { + $this->set("Quantity", $quantity); + } + /** + * ChargeType: 计费方式,默认按月支付。Month: 按月; Year: 按年; Dynamic: 按小时收 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费方式,默认按月支付。Month: 按月; Year: 按年; Dynamic: 按小时收 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * AccelerationArea: 加速大区,默认返回所有加速大区价格 + * + * @return string|null + */ + public function getAccelerationArea() + { + return $this->get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区,默认返回所有加速大区价格 + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } +} diff --git a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Response.php b/src/PathX/Apis/GetUGA3PriceResponse.php similarity index 60% rename from src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Response.php rename to src/PathX/Apis/GetUGA3PriceResponse.php index f7d4af26..a8eea442 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Response.php +++ b/src/PathX/Apis/GetUGA3PriceResponse.php @@ -1,6 +1,7 @@ get("HttpCodeV2Detail"); + $items = $this->get("UGA3Price"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new HttpCodeV2Detail($item)); + array_push($result, new UGA3PriceModel($item)); } return $result; } /** - * HttpCodeV2Detail: 状态码详情 + * UGA3Price: 加速大区对应价格 * - * @param HttpCodeV2Detail[] $httpCodeV2Detail + * @param UGA3PriceModel[] $uga3Price */ - public function setHttpCodeV2Detail(array $httpCodeV2Detail) + public function setUGA3Price(array $uga3Price) { $result = []; - foreach ($httpCodeV2Detail as $i => $item) { + foreach ($uga3Price as $i => $item) { array_push($result, $item->getAll()); } return $result; diff --git a/src/PathX/Apis/GetUGA3UpdatePriceRequest.php b/src/PathX/Apis/GetUGA3UpdatePriceRequest.php new file mode 100644 index 00000000..1ba10ac1 --- /dev/null +++ b/src/PathX/Apis/GetUGA3UpdatePriceRequest.php @@ -0,0 +1,128 @@ + "GetUGA3UpdatePrice"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 资源ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 资源ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Bandwidth: 只有升级带宽的时候有价格变化 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 只有升级带宽的时候有价格变化 + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * AccelerationArea: 暂未支持,加速大区,在更换加速大区的时候使用 + * + * @return string|null + */ + public function getAccelerationArea() + { + return $this->get("AccelerationArea"); + } + + /** + * AccelerationArea: 暂未支持,加速大区,在更换加速大区的时候使用 + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * AreaCode: 暂未支持,源站区域 + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 暂未支持,源站区域 + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } +} diff --git a/src/PathX/Apis/GetUGA3UpdatePriceResponse.php b/src/PathX/Apis/GetUGA3UpdatePriceResponse.php new file mode 100644 index 00000000..0eb19245 --- /dev/null +++ b/src/PathX/Apis/GetUGA3UpdatePriceResponse.php @@ -0,0 +1,45 @@ +get("Price"); + } + + /** + * Price: 价格 元。大于0需付费,小于0则退费。 + * + * @param float $price + */ + public function setPrice(float $price) + { + $this->set("Price", $price); + } +} diff --git a/src/PathX/Apis/ModifyGlobalSSHPortRequest.php b/src/PathX/Apis/ModifyGlobalSSHPortRequest.php index 84f78764..68f5f571 100644 --- a/src/PathX/Apis/ModifyGlobalSSHPortRequest.php +++ b/src/PathX/Apis/ModifyGlobalSSHPortRequest.php @@ -1,6 +1,7 @@ markRequired("Port"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: 实例ID,资源唯一标识。当前仅收费版GlobalSSH实例可以修改端口。 * @@ -65,11 +65,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * Port: 源站服务器监听的SSH端口号。收费版本端口范围[1,65535]且不能为80,443,65123端口。免费版不支持修改端口。 * @@ -85,7 +84,7 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } diff --git a/src/PathX/Apis/ModifyGlobalSSHPortResponse.php b/src/PathX/Apis/ModifyGlobalSSHPortResponse.php index 6ccbf349..04662979 100644 --- a/src/PathX/Apis/ModifyGlobalSSHPortResponse.php +++ b/src/PathX/Apis/ModifyGlobalSSHPortResponse.php @@ -1,6 +1,7 @@ "ModifyGlobalSSHRemark"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 实例ID,资源唯一标识 + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 实例ID,资源唯一标识 + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Remark: 备注信息,不填默认为空字符串 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注信息,不填默认为空字符串 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } +} diff --git a/src/PathX/Apis/ModifyGlobalSSHRemarkResponse.php b/src/PathX/Apis/ModifyGlobalSSHRemarkResponse.php new file mode 100644 index 00000000..35cc18d4 --- /dev/null +++ b/src/PathX/Apis/ModifyGlobalSSHRemarkResponse.php @@ -0,0 +1,26 @@ +markRequired("InstanceType"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: 实例ID,资源唯一标识 * @@ -65,11 +65,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * InstanceType: 取值范围["Enterprise","Basic"],分别对应企业版和基础版,表示升级后的实例类型。比如从Free版本升级为Basic版或Enterprise版,不可从收费版降级为免费版,或从企业版降级为基础版 * @@ -85,11 +84,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * ChargeType: 支付方式,如按月、按年、按时 * @@ -105,11 +103,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时间,当ChargeType为Month,Quantity为0代表购买到月底 * @@ -125,11 +122,10 @@ public function getQuantity() * * @param string $quantity */ - public function setQuantity($quantity) + public function setQuantity(string $quantity) { $this->set("Quantity", $quantity); } - /** * CouponId: 可抵扣费用的券,通常不使用 * @@ -145,7 +141,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/PathX/Apis/ModifyGlobalSSHTypeResponse.php b/src/PathX/Apis/ModifyGlobalSSHTypeResponse.php index c6b4bb2b..051216f5 100644 --- a/src/PathX/Apis/ModifyGlobalSSHTypeResponse.php +++ b/src/PathX/Apis/ModifyGlobalSSHTypeResponse.php @@ -1,6 +1,7 @@ "ModifyUGA3Bandwidth"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID,格式uga3-xxxx + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID,格式uga3-xxxx + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Bandwidth: 带宽大小,范围[1,100],不传则不更新 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 带宽大小,范围[1,100],不传则不更新 + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * CouponId: 需要全地域可用的代金券 + * + * @return string|null + */ + public function getCouponId() + { + return $this->get("CouponId"); + } + + /** + * CouponId: 需要全地域可用的代金券 + * + * @param string $couponId + */ + public function setCouponId(string $couponId) + { + $this->set("CouponId", $couponId); + } +} diff --git a/src/PathX/Apis/ModifyUGA3BandwidthResponse.php b/src/PathX/Apis/ModifyUGA3BandwidthResponse.php new file mode 100644 index 00000000..18dffeb0 --- /dev/null +++ b/src/PathX/Apis/ModifyUGA3BandwidthResponse.php @@ -0,0 +1,26 @@ + "ModifyUGA3Instance"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID,格式uga-xxxx。不支持GlobalSSH实例。 + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID,格式uga-xxxx。不支持GlobalSSH实例。 + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Name: 加速配置实例名称,不填或空字符串则不更新 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 加速配置实例名称,不填或空字符串则不更新 + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * Remark: 备注信息,暂时前端为使用 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注信息,暂时前端为使用 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } +} diff --git a/src/PathX/Apis/ModifyUGA3InstanceResponse.php b/src/PathX/Apis/ModifyUGA3InstanceResponse.php new file mode 100644 index 00000000..ddceb424 --- /dev/null +++ b/src/PathX/Apis/ModifyUGA3InstanceResponse.php @@ -0,0 +1,26 @@ + "ModifyUGA3OriginInfo"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + $this->markRequired("OriginDomain"); + $this->markRequired("OriginIPList"); + } + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID,格式uga3-xxxx。 + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID,格式uga3-xxxx。 + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * OriginDomain: 加速源域名,仅支持1个域名。修改源站时 OriginIPList和OriginDomain至少填一个。OriginIPList和OriginDomain都填时 以Domain为准,如果两个都不填,不修改 + * + * @return string|null + */ + public function getOriginDomain() + { + return $this->get("OriginDomain"); + } + + /** + * OriginDomain: 加速源域名,仅支持1个域名。修改源站时 OriginIPList和OriginDomain至少填一个。OriginIPList和OriginDomain都填时 以Domain为准,如果两个都不填,不修改 + * + * @param string $originDomain + */ + public function setOriginDomain(string $originDomain) + { + $this->set("OriginDomain", $originDomain); + } + /** + * OriginIPList: ,加速源IP,多个IP用英文半角逗号(,)隔开。修改源站时 ,OriginIPList和OriginDomain至少填一个。OriginIPList和OriginDomain都填时 以OriginDomain为准。如果两个都不填,不修改 + * + * @return string|null + */ + public function getOriginIPList() + { + return $this->get("OriginIPList"); + } + + /** + * OriginIPList: ,加速源IP,多个IP用英文半角逗号(,)隔开。修改源站时 ,OriginIPList和OriginDomain至少填一个。OriginIPList和OriginDomain都填时 以OriginDomain为准。如果两个都不填,不修改 + * + * @param string $originIPList + */ + public function setOriginIPList(string $originIPList) + { + $this->set("OriginIPList", $originIPList); + } +} diff --git a/src/PathX/Apis/ModifyUGA3OriginInfoResponse.php b/src/PathX/Apis/ModifyUGA3OriginInfoResponse.php new file mode 100644 index 00000000..53500699 --- /dev/null +++ b/src/PathX/Apis/ModifyUGA3OriginInfoResponse.php @@ -0,0 +1,26 @@ + "ModifyUGA3Port"]); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 加速配置实例ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 加速配置实例ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * TCP: TCP接入端口,禁用65123端口 + * + * @return int[]|null + */ + public function getTCP() + { + return $this->get("TCP"); + } + + /** + * TCP: TCP接入端口,禁用65123端口 + * + * @param int[] $tcp + */ + public function setTCP(array $tcp) + { + $this->set("TCP", $tcp); + } + /** + * TCPRS: TCP回源端口 + * + * @return int[]|null + */ + public function getTCPRS() + { + return $this->get("TCPRS"); + } + + /** + * TCPRS: TCP回源端口 + * + * @param int[] $tcprs + */ + public function setTCPRS(array $tcprs) + { + $this->set("TCPRS", $tcprs); + } +} diff --git a/src/PathX/Apis/ModifyUGA3PortResponse.php b/src/PathX/Apis/ModifyUGA3PortResponse.php new file mode 100644 index 00000000..f12f6d22 --- /dev/null +++ b/src/PathX/Apis/ModifyUGA3PortResponse.php @@ -0,0 +1,26 @@ +markRequired("Bandwidth"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UPathId: UPath 加速线路实例Id * @@ -65,11 +65,10 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } - /** * Bandwidth: 线路带宽,单位Mbps。最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。如需更大带宽,请联系产品团队。 * @@ -85,7 +84,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/PathX/Apis/ModifyUPathBandwidthResponse.php b/src/PathX/Apis/ModifyUPathBandwidthResponse.php index 196a3516..95ac2a2f 100644 --- a/src/PathX/Apis/ModifyUPathBandwidthResponse.php +++ b/src/PathX/Apis/ModifyUPathBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("UPathId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UPathId: 加速线路实例ID * @@ -64,11 +64,10 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } - /** * MetricName: 告警指标名称, 所有n的个数必须一致。目前仅允许以下四项:UpathNetworkOut:出向带宽,UpathNetworkIn:入向带宽,UpathNetworkOutUsage:出向带宽使用率,UpathNetworkInUsage:入向带宽使用率 * @@ -88,7 +87,6 @@ public function setMetricName(array $metricName) { $this->set("MetricName", $metricName); } - /** * Threshold: 告警阈值,带宽使用率的阈值范围是[50,100]的正整数,带宽告警阈值为1000000的倍数, 如大于2Mbps则告警 阈值应该传 2000000 * @@ -108,7 +106,6 @@ public function setThreshold(array $threshold) { $this->set("Threshold", $threshold); } - /** * AlarmFrequency: 告警探测周期,单位:秒 * @@ -128,7 +125,6 @@ public function setAlarmFrequency(array $alarmFrequency) { $this->set("AlarmFrequency", $alarmFrequency); } - /** * ContactGroupId: 告警组id * @@ -148,7 +144,6 @@ public function setContactGroupId(array $contactGroupId) { $this->set("ContactGroupId", $contactGroupId); } - /** * Compare: 比较策略,可选 ['GE','LE'] 分别代表不小于和不大于 * @@ -168,7 +163,6 @@ public function setCompare(array $compare) { $this->set("Compare", $compare); } - /** * AlarmStrategy: 收敛策略,可选范围 ['Exponential','Continuous','Once'],分别对应指数递增、连续告警、单次告警 * @@ -188,7 +182,6 @@ public function setAlarmStrategy(array $alarmStrategy) { $this->set("AlarmStrategy", $alarmStrategy); } - /** * TriggerCount: 告警触发周期(次数) * diff --git a/src/PathX/Apis/ModifyUPathTemplateResponse.php b/src/PathX/Apis/ModifyUPathTemplateResponse.php index f6ecfa4a..92af40e9 100644 --- a/src/PathX/Apis/ModifyUPathTemplateResponse.php +++ b/src/PathX/Apis/ModifyUPathTemplateResponse.php @@ -1,6 +1,7 @@ markRequired("UPathId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID,格式uga-xxxx * @@ -65,11 +65,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * UPathId: 加速线路实例ID,格式upath-xxx * @@ -85,11 +84,10 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } - /** * CouponId: 代金券 * @@ -105,7 +103,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/PathX/Apis/UGABindUPathResponse.php b/src/PathX/Apis/UGABindUPathResponse.php index 1f194c29..eb21b674 100644 --- a/src/PathX/Apis/UGABindUPathResponse.php +++ b/src/PathX/Apis/UGABindUPathResponse.php @@ -1,6 +1,7 @@ markRequired("UPathId"); } - /** * ProjectId: 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: 加速配置实例ID 格式uga-xxx * @@ -65,11 +65,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * UPathId: 加速线路实例ID 格式upath-xxx * @@ -85,7 +84,7 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } diff --git a/src/PathX/Apis/UGAUnBindUPathResponse.php b/src/PathX/Apis/UGAUnBindUPathResponse.php index f3dddb0b..ce62d3c2 100644 --- a/src/PathX/Apis/UGAUnBindUPathResponse.php +++ b/src/PathX/Apis/UGAUnBindUPathResponse.php @@ -1,6 +1,7 @@ markRequired("Port"); } - /** * ProjectId: 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -46,11 +47,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UGAId: UGA实例ID。 * @@ -66,11 +66,10 @@ public function getUGAId() * * @param string $ugaId */ - public function setUGAId($ugaId) + public function setUGAId(string $ugaId) { $this->set("UGAId", $ugaId); } - /** * SSLId: SSL证书ID。 * @@ -86,11 +85,10 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } - /** * Port: 解绑SSL证书的HTTPS端口。Port.0 Port.1格式 端口错误则解绑失败。 * diff --git a/src/PathX/Apis/UnBindPathXSSLResponse.php b/src/PathX/Apis/UnBindPathXSSLResponse.php index fcefeb60..b7b42e66 100644 --- a/src/PathX/Apis/UnBindPathXSSLResponse.php +++ b/src/PathX/Apis/UnBindPathXSSLResponse.php @@ -1,6 +1,7 @@ markRequired("InstanceId"); } - /** * ProjectId: 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: GlobalSSH实例ID,资源唯一标识 * @@ -64,11 +64,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * Whitelist: 白名单规则,例如 "Whitelist.0": "192.168.1.1/24|tcp|22","Whitelist.1": "192.168.1.2|tcp|8080:8090",第一个参数为ip或ip段,第二个参数代表协议(tcp/udp),第三个参数代表端口号或端口范围(使用 ':' 隔开);可以添加多条规则(递增Whitelist.n字段内的n值);此接口需要列出全部规则,例如不填则为清空白名单规则,如若需要增量添加,使用InsertPathXWhitelist接口,globalssh 没有端口范围:端口设置成加速端口,协议设置成tcp:ip|tcp|加速端口 * diff --git a/src/PathX/Apis/UpdatePathXWhitelistResponse.php b/src/PathX/Apis/UpdatePathXWhitelistResponse.php index c29a959e..6e092049 100644 --- a/src/PathX/Apis/UpdatePathXWhitelistResponse.php +++ b/src/PathX/Apis/UpdatePathXWhitelistResponse.php @@ -1,6 +1,7 @@ get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速区code + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * AccelerationNodes: 加速节点信息 + * + * @return SrcAreaInfoModel[]|null + */ + public function getAccelerationNodes() + { + $items = $this->get("AccelerationNodes"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new SrcAreaInfoModel($item)); + } + return $result; + } + + /** + * AccelerationNodes: 加速节点信息 + * + * @param SrcAreaInfoModel[] $accelerationNodes + */ + public function setAccelerationNodes(array $accelerationNodes) + { + $result = []; + foreach ($accelerationNodes as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/PathX/Models/AccelerationInfo.php b/src/PathX/Models/AccelerationInfo.php new file mode 100644 index 00000000..7e18f75c --- /dev/null +++ b/src/PathX/Models/AccelerationInfo.php @@ -0,0 +1,98 @@ +get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区代码 + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * AccelerationName: 加速大区名称 + * + * @return string|null + */ + public function getAccelerationName() + { + return $this->get("AccelerationName"); + } + + /** + * AccelerationName: 加速大区名称 + * + * @param string $accelerationName + */ + public function setAccelerationName(string $accelerationName) + { + $this->set("AccelerationName", $accelerationName); + } + /** + * NodeInfo: 加速提升情况 + * + * @return NodeDelaysModel[]|null + */ + public function getNodeInfo() + { + $items = $this->get("NodeInfo"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new NodeDelaysModel($item)); + } + return $result; + } + + /** + * NodeInfo: 加速提升情况 + * + * @param NodeDelaysModel[] $nodeInfo + */ + public function setNodeInfo(array $nodeInfo) + { + $result = []; + foreach ($nodeInfo as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/PathX/Models/AlarmRuler.php b/src/PathX/Models/AlarmRuler.php index 57544579..15bb6ad5 100644 --- a/src/PathX/Models/AlarmRuler.php +++ b/src/PathX/Models/AlarmRuler.php @@ -1,6 +1,7 @@ set("AlarmStrategy", $alarmStrategy); } - /** * AlarmFrequency: 告警探测周期,单位秒 * @@ -57,11 +59,10 @@ public function getAlarmFrequency() * * @param int $alarmFrequency */ - public function setAlarmFrequency($alarmFrequency) + public function setAlarmFrequency(int $alarmFrequency) { $this->set("AlarmFrequency", $alarmFrequency); } - /** * Compare: 比较策略,可选 ['GE','LE'] 分别代表不小于和不大于 * @@ -77,11 +78,10 @@ public function getCompare() * * @param string $compare */ - public function setCompare($compare) + public function setCompare(string $compare) { $this->set("Compare", $compare); } - /** * ContactGroupId: 联系组ID * @@ -97,11 +97,10 @@ public function getContactGroupId() * * @param int $contactGroupId */ - public function setContactGroupId($contactGroupId) + public function setContactGroupId(int $contactGroupId) { $this->set("ContactGroupId", $contactGroupId); } - /** * MetricName: 告警指标名称, 所有n的个数必须一致。目前仅允许以下四项:UpathNetworkOut:出向带宽,UpathNetworkIn:入向带宽,UpathNetworkOutUsage:出向带宽使用率,UpathNetworkInUsage:入向带宽使用率 * @@ -117,11 +116,10 @@ public function getMetricName() * * @param string $metricName */ - public function setMetricName($metricName) + public function setMetricName(string $metricName) { $this->set("MetricName", $metricName); } - /** * Threshold: 告警阈值,带宽使用率的阈值范围是[50,100]的正整数,带宽告警阈值为1000000的倍数, 如大于2Mbps则告警 阈值应该传 2000000 * @@ -137,11 +135,10 @@ public function getThreshold() * * @param int $threshold */ - public function setThreshold($threshold) + public function setThreshold(int $threshold) { $this->set("Threshold", $threshold); } - /** * TriggerCount: 告警触发周期(次数) * @@ -157,11 +154,10 @@ public function getTriggerCount() * * @param int $triggerCount */ - public function setTriggerCount($triggerCount) + public function setTriggerCount(int $triggerCount) { $this->set("TriggerCount", $triggerCount); } - /** * AlarmTemplateRuleId: 告警模板策略ID * @@ -177,11 +173,10 @@ public function getAlarmTemplateRuleId() * * @param int $alarmTemplateRuleId */ - public function setAlarmTemplateRuleId($alarmTemplateRuleId) + public function setAlarmTemplateRuleId(int $alarmTemplateRuleId) { $this->set("AlarmTemplateRuleId", $alarmTemplateRuleId); } - /** * ResourceType: 资源类型 * @@ -197,7 +192,7 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } diff --git a/src/PathX/Models/ForwardArea.php b/src/PathX/Models/ForwardArea.php new file mode 100644 index 00000000..13daef1c --- /dev/null +++ b/src/PathX/Models/ForwardArea.php @@ -0,0 +1,142 @@ +get("AreaCode"); + } + + /** + * AreaCode: 源站区域代码 + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * Area: 源站区域中文 + * + * @return string|null + */ + public function getArea() + { + return $this->get("Area"); + } + + /** + * Area: 源站区域中文 + * + * @param string $area + */ + public function setArea(string $area) + { + $this->set("Area", $area); + } + /** + * CountryCode: 国家代码 + * + * @return string|null + */ + public function getCountryCode() + { + return $this->get("CountryCode"); + } + + /** + * CountryCode: 国家代码 + * + * @param string $countryCode + */ + public function setCountryCode(string $countryCode) + { + $this->set("CountryCode", $countryCode); + } + /** + * FlagUnicode: 国旗unicode + * + * @return string|null + */ + public function getFlagUnicode() + { + return $this->get("FlagUnicode"); + } + + /** + * FlagUnicode: 国旗unicode + * + * @param string $flagUnicode + */ + public function setFlagUnicode(string $flagUnicode) + { + $this->set("FlagUnicode", $flagUnicode); + } + /** + * FlagEmoji: 国旗 emoji + * + * @return string|null + */ + public function getFlagEmoji() + { + return $this->get("FlagEmoji"); + } + + /** + * FlagEmoji: 国旗 emoji + * + * @param string $flagEmoji + */ + public function setFlagEmoji(string $flagEmoji) + { + $this->set("FlagEmoji", $flagEmoji); + } + /** + * ContinentCode: 大陆代码 + * + * @return string|null + */ + public function getContinentCode() + { + return $this->get("ContinentCode"); + } + + /** + * ContinentCode: 大陆代码 + * + * @param string $continentCode + */ + public function setContinentCode(string $continentCode) + { + $this->set("ContinentCode", $continentCode); + } +} diff --git a/src/PathX/Models/ForwardInfo.php b/src/PathX/Models/ForwardInfo.php new file mode 100644 index 00000000..eb0c884e --- /dev/null +++ b/src/PathX/Models/ForwardInfo.php @@ -0,0 +1,392 @@ +get("InstanceId"); + } + + /** + * InstanceId: 加速配置ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * CName: 加速域名 + * + * @return string|null + */ + public function getCName() + { + return $this->get("CName"); + } + + /** + * CName: 加速域名 + * + * @param string $cName + */ + public function setCName(string $cName) + { + $this->set("CName", $cName); + } + /** + * Name: 加速实例名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 加速实例名称 + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * AccelerationArea: 加速大区代码 + * + * @return string|null + */ + public function getAccelerationArea() + { + return $this->get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区代码 + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * AccelerationAreaName: 加速大区名称 + * + * @return string|null + */ + public function getAccelerationAreaName() + { + return $this->get("AccelerationAreaName"); + } + + /** + * AccelerationAreaName: 加速大区名称 + * + * @param string $accelerationAreaName + */ + public function setAccelerationAreaName(string $accelerationAreaName) + { + $this->set("AccelerationAreaName", $accelerationAreaName); + } + /** + * AccelerationAreaInfos: 加速节点列表 + * + * @return AccelerationAreaInfosModel[]|null + */ + public function getAccelerationAreaInfos() + { + $items = $this->get("AccelerationAreaInfos"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new AccelerationAreaInfosModel($item)); + } + return $result; + } + + /** + * AccelerationAreaInfos: 加速节点列表 + * + * @param AccelerationAreaInfosModel[] $accelerationAreaInfos + */ + public function setAccelerationAreaInfos(array $accelerationAreaInfos) + { + $result = []; + foreach ($accelerationAreaInfos as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * EgressIpList: 回源出口IP地址 + * + * @return OutPublicIpInfoModel[]|null + */ + public function getEgressIpList() + { + $items = $this->get("EgressIpList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new OutPublicIpInfoModel($item)); + } + return $result; + } + + /** + * EgressIpList: 回源出口IP地址 + * + * @param OutPublicIpInfoModel[] $egressIpList + */ + public function setEgressIpList(array $egressIpList) + { + $result = []; + foreach ($egressIpList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * Bandwidth: 购买的带宽值 + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: 购买的带宽值 + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * OriginArea: 源站中文名 + * + * @return string|null + */ + public function getOriginArea() + { + return $this->get("OriginArea"); + } + + /** + * OriginArea: 源站中文名 + * + * @param string $originArea + */ + public function setOriginArea(string $originArea) + { + $this->set("OriginArea", $originArea); + } + /** + * OriginAreaCode: 源站AreaCode + * + * @return string|null + */ + public function getOriginAreaCode() + { + return $this->get("OriginAreaCode"); + } + + /** + * OriginAreaCode: 源站AreaCode + * + * @param string $originAreaCode + */ + public function setOriginAreaCode(string $originAreaCode) + { + $this->set("OriginAreaCode", $originAreaCode); + } + /** + * CreateTime: 资源创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 资源创建时间 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * ExpireTime: 资源过期时间 + * + * @return integer|null + */ + public function getExpireTime() + { + return $this->get("ExpireTime"); + } + + /** + * ExpireTime: 资源过期时间 + * + * @param int $expireTime + */ + public function setExpireTime(int $expireTime) + { + $this->set("ExpireTime", $expireTime); + } + /** + * ChargeType: 计费方式 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费方式 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } + /** + * PortSets: 端口列表 + * + * @return ForwardTaskModel[]|null + */ + public function getPortSets() + { + $items = $this->get("PortSets"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new ForwardTaskModel($item)); + } + return $result; + } + + /** + * PortSets: 端口列表 + * + * @param ForwardTaskModel[] $portSets + */ + public function setPortSets(array $portSets) + { + $result = []; + foreach ($portSets as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * IPList: 源站IP列表,多个值由半角英文逗号相隔 + * + * @return string[]|null + */ + public function getIPList() + { + return $this->get("IPList"); + } + + /** + * IPList: 源站IP列表,多个值由半角英文逗号相隔 + * + * @param string[] $ipList + */ + public function setIPList(array $ipList) + { + $this->set("IPList", $ipList); + } + /** + * Domain: 源站域名 + * + * @return string|null + */ + public function getDomain() + { + return $this->get("Domain"); + } + + /** + * Domain: 源站域名 + * + * @param string $domain + */ + public function setDomain(string $domain) + { + $this->set("Domain", $domain); + } +} diff --git a/src/PathX/Models/ForwardTask.php b/src/PathX/Models/ForwardTask.php new file mode 100644 index 00000000..a210488a --- /dev/null +++ b/src/PathX/Models/ForwardTask.php @@ -0,0 +1,87 @@ +get("Protocol"); + } + + /** + * Protocol: 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS","WSWS","WSSWS","WSSWSS"]。TCP和UDP代表四层转发,其余为七层转发。 + * + * @param string $protocol + */ + public function setProtocol(string $protocol) + { + $this->set("Protocol", $protocol); + } + /** + * RSPort: 源站服务器监听的端口号 + * + * @return integer|null + */ + public function getRSPort() + { + return $this->get("RSPort"); + } + + /** + * RSPort: 源站服务器监听的端口号 + * + * @param int $rsPort + */ + public function setRSPort(int $rsPort) + { + $this->set("RSPort", $rsPort); + } + /** + * Port: 加速端口 + * + * @return integer|null + */ + public function getPort() + { + return $this->get("Port"); + } + + /** + * Port: 加速端口 + * + * @param int $port + */ + public function setPort(int $port) + { + $this->set("Port", $port); + } +} diff --git a/src/PathX/Models/GlobalSSHInfo.php b/src/PathX/Models/GlobalSSHInfo.php index 103cb7b2..31783803 100644 --- a/src/PathX/Models/GlobalSSHInfo.php +++ b/src/PathX/Models/GlobalSSHInfo.php @@ -1,6 +1,7 @@ set("InstanceId", $instanceId); } - /** * InstanceType: 枚举值:["Enterprise","Basic","Free","Welfare"], 分别代表企业版,基础版本,免费版本,较早的公测免费版 * @@ -57,11 +59,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * AcceleratingDomain: GlobalSSH分配的加速域名。 * @@ -77,11 +78,10 @@ public function getAcceleratingDomain() * * @param string $acceleratingDomain */ - public function setAcceleratingDomain($acceleratingDomain) + public function setAcceleratingDomain(string $acceleratingDomain) { $this->set("AcceleratingDomain", $acceleratingDomain); } - /** * Area: 被SSH访问的IP所在地区 * @@ -97,11 +97,10 @@ public function getArea() * * @param string $area */ - public function setArea($area) + public function setArea(string $area) { $this->set("Area", $area); } - /** * TargetIP: 被SSH访问的源站 IPv4地址。 * @@ -117,11 +116,10 @@ public function getTargetIP() * * @param string $targetIP */ - public function setTargetIP($targetIP) + public function setTargetIP(string $targetIP) { $this->set("TargetIP", $targetIP); } - /** * Remark: 备注信息 * @@ -137,11 +135,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Port: 源站服务器监听的SSH端口,windows系统为RDP端口 * @@ -157,11 +154,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * GlobalSSHPort: InstanceType等于Free时,由系统自动分配,不等于源站Port值。InstanceType不等于Free时,与源站Port值相同。 * @@ -177,11 +173,10 @@ public function getGlobalSSHPort() * * @param int $globalSSHPort */ - public function setGlobalSSHPort($globalSSHPort) + public function setGlobalSSHPort(int $globalSSHPort) { $this->set("GlobalSSHPort", $globalSSHPort); } - /** * ChargeType: 支付周期,如Month,Year,Dynamic等 * @@ -197,11 +192,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CreateTime: 资源创建时间戳 * @@ -217,11 +211,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 资源过期时间戳 * @@ -237,11 +230,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Expire: 是否过期 * @@ -257,11 +249,10 @@ public function getExpire() * * @param boolean $expire */ - public function setExpire($expire) + public function setExpire(bool $expire) { $this->set("Expire", $expire); } - /** * BandwidthPackage: globalssh Ultimate带宽包大小 * @@ -277,11 +268,10 @@ public function getBandwidthPackage() * * @param int $bandwidthPackage */ - public function setBandwidthPackage($bandwidthPackage) + public function setBandwidthPackage(int $bandwidthPackage) { $this->set("BandwidthPackage", $bandwidthPackage); } - /** * ForwardRegion: InstanceType为Basic版本时,需要展示具体分配的转发机房 * @@ -297,7 +287,7 @@ public function getForwardRegion() * * @param string $forwardRegion */ - public function setForwardRegion($forwardRegion) + public function setForwardRegion(string $forwardRegion) { $this->set("ForwardRegion", $forwardRegion); } diff --git a/src/PathX/Models/LineDetail.php b/src/PathX/Models/LineDetail.php index 27a84892..b4af6a29 100644 --- a/src/PathX/Models/LineDetail.php +++ b/src/PathX/Models/LineDetail.php @@ -1,6 +1,7 @@ set("LineFrom", $lineFrom); } - /** * LineTo: 线路目的 * @@ -57,11 +60,10 @@ public function getLineTo() * * @param string $lineTo */ - public function setLineTo($lineTo) + public function setLineTo(string $lineTo) { $this->set("LineTo", $lineTo); } - /** * LineId: 线路计费Id * @@ -77,11 +79,10 @@ public function getLineId() * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } - /** * LineFromName: 线路源中文名称 * @@ -97,11 +98,10 @@ public function getLineFromName() * * @param string $lineFromName */ - public function setLineFromName($lineFromName) + public function setLineFromName(string $lineFromName) { $this->set("LineFromName", $lineFromName); } - /** * LineToName: 线路目的中文名称 * @@ -117,7 +117,7 @@ public function getLineToName() * * @param string $lineToName */ - public function setLineToName($lineToName) + public function setLineToName(string $lineToName) { $this->set("LineToName", $lineToName); } diff --git a/src/PathX/Models/MatricPoint.php b/src/PathX/Models/MatricPoint.php index 38082605..2bc5f599 100644 --- a/src/PathX/Models/MatricPoint.php +++ b/src/PathX/Models/MatricPoint.php @@ -1,6 +1,7 @@ set("Timestamp", $timestamp); } - /** * Value: 监控点数值 * @@ -57,7 +66,7 @@ public function getValue() * * @param int $value */ - public function setValue($value) + public function setValue(int $value) { $this->set("Value", $value); } diff --git a/src/PathX/Models/MetricPeriod.php b/src/PathX/Models/MetricPeriod.php index c802e6e9..3d273624 100644 --- a/src/PathX/Models/MetricPeriod.php +++ b/src/PathX/Models/MetricPeriod.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new MatricPoint($item)); + array_push($result, new MatricPointModel($item)); } return $result; } @@ -43,7 +47,7 @@ public function getNetworkOut() /** * NetworkOut: 出向带宽 * - * @param MatricPoint[] $networkOut + * @param MatricPointModel[] $networkOut */ public function setNetworkOut(array $networkOut) { @@ -53,11 +57,10 @@ public function setNetworkOut(array $networkOut) } return $result; } - /** * NetworkIn: 入向带宽 * - * @return MatricPoint[]|null + * @return MatricPointModel[]|null */ public function getNetworkIn() { @@ -67,7 +70,7 @@ public function getNetworkIn() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MatricPoint($item)); + array_push($result, new MatricPointModel($item)); } return $result; } @@ -75,7 +78,7 @@ public function getNetworkIn() /** * NetworkIn: 入向带宽 * - * @param MatricPoint[] $networkIn + * @param MatricPointModel[] $networkIn */ public function setNetworkIn(array $networkIn) { @@ -85,11 +88,10 @@ public function setNetworkIn(array $networkIn) } return $result; } - /** * NetworkOutUsage: 出向带宽使用率 * - * @return MatricPoint[]|null + * @return MatricPointModel[]|null */ public function getNetworkOutUsage() { @@ -99,7 +101,7 @@ public function getNetworkOutUsage() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MatricPoint($item)); + array_push($result, new MatricPointModel($item)); } return $result; } @@ -107,7 +109,7 @@ public function getNetworkOutUsage() /** * NetworkOutUsage: 出向带宽使用率 * - * @param MatricPoint[] $networkOutUsage + * @param MatricPointModel[] $networkOutUsage */ public function setNetworkOutUsage(array $networkOutUsage) { @@ -117,11 +119,10 @@ public function setNetworkOutUsage(array $networkOutUsage) } return $result; } - /** * NetworkInUsage: 入向带宽使用率 * - * @return MatricPoint[]|null + * @return MatricPointModel[]|null */ public function getNetworkInUsage() { @@ -131,7 +132,7 @@ public function getNetworkInUsage() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MatricPoint($item)); + array_push($result, new MatricPointModel($item)); } return $result; } @@ -139,7 +140,7 @@ public function getNetworkInUsage() /** * NetworkInUsage: 入向带宽使用率 * - * @param MatricPoint[] $networkInUsage + * @param MatricPointModel[] $networkInUsage */ public function setNetworkInUsage(array $networkInUsage) { diff --git a/src/PathX/Models/NodeDelays.php b/src/PathX/Models/NodeDelays.php new file mode 100644 index 00000000..7e68934b --- /dev/null +++ b/src/PathX/Models/NodeDelays.php @@ -0,0 +1,239 @@ +get("Area"); + } + + /** + * Area: 加速区域 + * + * @param string $area + */ + public function setArea(string $area) + { + $this->set("Area", $area); + } + /** + * AreaCode: 加速区域Code + * + * @return string|null + */ + public function getAreaCode() + { + return $this->get("AreaCode"); + } + + /** + * AreaCode: 加速区域Code + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * CountryCode: 国家代码 + * + * @return string|null + */ + public function getCountryCode() + { + return $this->get("CountryCode"); + } + + /** + * CountryCode: 国家代码 + * + * @param string $countryCode + */ + public function setCountryCode(string $countryCode) + { + $this->set("CountryCode", $countryCode); + } + /** + * FlagUnicode: 国旗Code + * + * @return string|null + */ + public function getFlagUnicode() + { + return $this->get("FlagUnicode"); + } + + /** + * FlagUnicode: 国旗Code + * + * @param string $flagUnicode + */ + public function setFlagUnicode(string $flagUnicode) + { + $this->set("FlagUnicode", $flagUnicode); + } + /** + * FlagEmoji: 国旗Emoji + * + * @return string|null + */ + public function getFlagEmoji() + { + return $this->get("FlagEmoji"); + } + + /** + * FlagEmoji: 国旗Emoji + * + * @param string $flagEmoji + */ + public function setFlagEmoji(string $flagEmoji) + { + $this->set("FlagEmoji", $flagEmoji); + } + /** + * Latency: 加速延迟 + * + * @return float|null + */ + public function getLatency() + { + return $this->get("Latency"); + } + + /** + * Latency: 加速延迟 + * + * @param float $latency + */ + public function setLatency(float $latency) + { + $this->set("Latency", $latency); + } + /** + * LatencyInternet: 公网延迟 + * + * @return float|null + */ + public function getLatencyInternet() + { + return $this->get("LatencyInternet"); + } + + /** + * LatencyInternet: 公网延迟 + * + * @param float $latencyInternet + */ + public function setLatencyInternet(float $latencyInternet) + { + $this->set("LatencyInternet", $latencyInternet); + } + /** + * LatencyOptimization: 加速提升比例 + * + * @return float|null + */ + public function getLatencyOptimization() + { + return $this->get("LatencyOptimization"); + } + + /** + * LatencyOptimization: 加速提升比例 + * + * @param float $latencyOptimization + */ + public function setLatencyOptimization(float $latencyOptimization) + { + $this->set("LatencyOptimization", $latencyOptimization); + } + /** + * Loss: 加速后丢包率 + * + * @return float|null + */ + public function getLoss() + { + return $this->get("Loss"); + } + + /** + * Loss: 加速后丢包率 + * + * @param float $loss + */ + public function setLoss(float $loss) + { + $this->set("Loss", $loss); + } + /** + * LossInternet: 原始丢包率 + * + * @return float|null + */ + public function getLossInternet() + { + return $this->get("LossInternet"); + } + + /** + * LossInternet: 原始丢包率 + * + * @param float $lossInternet + */ + public function setLossInternet(float $lossInternet) + { + $this->set("LossInternet", $lossInternet); + } + /** + * LossOptimization: 丢包下降比例 + * + * @return float|null + */ + public function getLossOptimization() + { + return $this->get("LossOptimization"); + } + + /** + * LossOptimization: 丢包下降比例 + * + * @param float $lossOptimization + */ + public function setLossOptimization(float $lossOptimization) + { + $this->set("LossOptimization", $lossOptimization); + } +} diff --git a/src/PathX/Models/OutPublicIpInfo.php b/src/PathX/Models/OutPublicIpInfo.php index 27cfaf2b..79b88944 100644 --- a/src/PathX/Models/OutPublicIpInfo.php +++ b/src/PathX/Models/OutPublicIpInfo.php @@ -1,6 +1,7 @@ set("IP", $ip); } - /** - * Area: 线路出口机房代号 + * Area: 线路回源节点机房代号 * * @return string|null */ @@ -53,11 +61,11 @@ public function getArea() } /** - * Area: 线路出口机房代号 + * Area: 线路回源节点机房代号 * * @param string $area */ - public function setArea($area) + public function setArea(string $area) { $this->set("Area", $area); } diff --git a/src/PathX/Models/PathXSSLSet.php b/src/PathX/Models/PathXSSLSet.php index 10b19a38..4800131b 100644 --- a/src/PathX/Models/PathXSSLSet.php +++ b/src/PathX/Models/PathXSSLSet.php @@ -1,6 +1,7 @@ set("SSLId", $sslId); } - /** * SSLName: SSL证书的名字 * @@ -57,11 +60,10 @@ public function getSSLName() * * @param string $sslName */ - public function setSSLName($sslName) + public function setSSLName(string $sslName) { $this->set("SSLName", $sslName); } - /** * SubjectName: 证书域名 * @@ -77,11 +79,10 @@ public function getSubjectName() * * @param string $subjectName */ - public function setSubjectName($subjectName) + public function setSubjectName(string $subjectName) { $this->set("SubjectName", $subjectName); } - /** * ExpireTime: 证书过期时间 时间戳 * @@ -97,11 +98,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * SourceType: 证书来源,0:用户上传 1: 免费颁发 * @@ -117,11 +117,10 @@ public function getSourceType() * * @param int $sourceType */ - public function setSourceType($sourceType) + public function setSourceType(int $sourceType) { $this->set("SourceType", $sourceType); } - /** * SSLMD5: SSL证书(用户证书、私钥、ca证书合并)内容md5值 * @@ -137,11 +136,10 @@ public function getSSLMD5() * * @param string $sslmd5 */ - public function setSSLMD5($sslmd5) + public function setSSLMD5(string $sslmd5) { $this->set("SSLMD5", $sslmd5); } - /** * CreateTime: SSL证书的创建时间 时间戳 * @@ -157,15 +155,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * SSLBindedTargetSet: SSL证书绑定的对象 * - * @return SSLBindedTargetSet[]|null + * @return SSLBindedTargetSetModel[]|null */ public function getSSLBindedTargetSet() { @@ -175,7 +172,7 @@ public function getSSLBindedTargetSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SSLBindedTargetSet($item)); + array_push($result, new SSLBindedTargetSetModel($item)); } return $result; } @@ -183,7 +180,7 @@ public function getSSLBindedTargetSet() /** * SSLBindedTargetSet: SSL证书绑定的对象 * - * @param SSLBindedTargetSet[] $sslBindedTargetSet + * @param SSLBindedTargetSetModel[] $sslBindedTargetSet */ public function setSSLBindedTargetSet(array $sslBindedTargetSet) { @@ -193,7 +190,6 @@ public function setSSLBindedTargetSet(array $sslBindedTargetSet) } return $result; } - /** * SSLContent: SSL证书内容 * @@ -209,7 +205,7 @@ public function getSSLContent() * * @param string $sslContent */ - public function setSSLContent($sslContent) + public function setSSLContent(string $sslContent) { $this->set("SSLContent", $sslContent); } diff --git a/src/PathX/Models/PathXUGAInfo.php b/src/PathX/Models/PathXUGAInfo.php index 8475611e..f5ac7f7e 100644 --- a/src/PathX/Models/PathXUGAInfo.php +++ b/src/PathX/Models/PathXUGAInfo.php @@ -1,6 +1,7 @@ set("UGAId", $ugaId); } - /** * IPList: 源站IP列表,多个值由半角英文逗号相隔 * @@ -61,7 +64,6 @@ public function setIPList(array $ipList) { $this->set("IPList", $ipList); } - /** * Domain: 源站域名 * @@ -77,7 +79,7 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } diff --git a/src/PathX/Models/SSLBindedTargetSet.php b/src/PathX/Models/SSLBindedTargetSet.php index 4dcf521e..e10ab0b1 100644 --- a/src/PathX/Models/SSLBindedTargetSet.php +++ b/src/PathX/Models/SSLBindedTargetSet.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * ResourceName: SSL证书绑定到的实例名称 * @@ -57,7 +60,7 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } diff --git a/src/PathX/Models/SrcAreaInfo.php b/src/PathX/Models/SrcAreaInfo.php new file mode 100644 index 00000000..f453f157 --- /dev/null +++ b/src/PathX/Models/SrcAreaInfo.php @@ -0,0 +1,107 @@ +get("AreaCode"); + } + + /** + * AreaCode: AreaCode ,城市机场代码 + * + * @param string $areaCode + */ + public function setAreaCode(string $areaCode) + { + $this->set("AreaCode", $areaCode); + } + /** + * Area: AreaCode对应城市名 + * + * @return string|null + */ + public function getArea() + { + return $this->get("Area"); + } + + /** + * Area: AreaCode对应城市名 + * + * @param string $area + */ + public function setArea(string $area) + { + $this->set("Area", $area); + } + /** + * FlagEmoji: 国旗Emoji + * + * @return string|null + */ + public function getFlagEmoji() + { + return $this->get("FlagEmoji"); + } + + /** + * FlagEmoji: 国旗Emoji + * + * @param string $flagEmoji + */ + public function setFlagEmoji(string $flagEmoji) + { + $this->set("FlagEmoji", $flagEmoji); + } + /** + * FlagUnicode: 国旗Unicode + * + * @return string|null + */ + public function getFlagUnicode() + { + return $this->get("FlagUnicode"); + } + + /** + * FlagUnicode: 国旗Unicode + * + * @param string $flagUnicode + */ + public function setFlagUnicode(string $flagUnicode) + { + $this->set("FlagUnicode", $flagUnicode); + } +} diff --git a/src/PathX/Models/UGA3Metric.php b/src/PathX/Models/UGA3Metric.php new file mode 100644 index 00000000..d3d61383 --- /dev/null +++ b/src/PathX/Models/UGA3Metric.php @@ -0,0 +1,401 @@ +get("NetworkOut"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkOut: 出向带宽 + * + * @param MatricPointModel[] $networkOut + */ + public function setNetworkOut(array $networkOut) + { + $result = []; + foreach ($networkOut as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NetworkIn: 入向带宽 + * + * @return MatricPointModel[]|null + */ + public function getNetworkIn() + { + $items = $this->get("NetworkIn"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkIn: 入向带宽 + * + * @param MatricPointModel[] $networkIn + */ + public function setNetworkIn(array $networkIn) + { + $result = []; + foreach ($networkIn as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NetworkOutUsage: 出向带宽使用率 + * + * @return MatricPointModel[]|null + */ + public function getNetworkOutUsage() + { + $items = $this->get("NetworkOutUsage"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkOutUsage: 出向带宽使用率 + * + * @param MatricPointModel[] $networkOutUsage + */ + public function setNetworkOutUsage(array $networkOutUsage) + { + $result = []; + foreach ($networkOutUsage as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NetworkInUsage: 入向带宽使用率 + * + * @return MatricPointModel[]|null + */ + public function getNetworkInUsage() + { + $items = $this->get("NetworkInUsage"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkInUsage: 入向带宽使用率 + * + * @param MatricPointModel[] $networkInUsage + */ + public function setNetworkInUsage(array $networkInUsage) + { + $result = []; + foreach ($networkInUsage as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NetworkOutSubline: 子线路出口带宽 + * + * @return MatricPointModel[]|null + */ + public function getNetworkOutSubline() + { + $items = $this->get("NetworkOutSubline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkOutSubline: 子线路出口带宽 + * + * @param MatricPointModel[] $networkOutSubline + */ + public function setNetworkOutSubline(array $networkOutSubline) + { + $result = []; + foreach ($networkOutSubline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NetworkInSubline: 子线路入口带宽 + * + * @return MatricPointModel[]|null + */ + public function getNetworkInSubline() + { + $items = $this->get("NetworkInSubline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * NetworkInSubline: 子线路入口带宽 + * + * @param MatricPointModel[] $networkInSubline + */ + public function setNetworkInSubline(array $networkInSubline) + { + $result = []; + foreach ($networkInSubline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * Delay: 线路平均延迟 + * + * @return MatricPointModel[]|null + */ + public function getDelay() + { + $items = $this->get("Delay"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * Delay: 线路平均延迟 + * + * @param MatricPointModel[] $delay + */ + public function setDelay(array $delay) + { + $result = []; + foreach ($delay as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * DelaySubline: 子线路延迟 + * + * @return MatricPointModel[]|null + */ + public function getDelaySubline() + { + $items = $this->get("DelaySubline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * DelaySubline: 子线路延迟 + * + * @param MatricPointModel[] $delaySubline + */ + public function setDelaySubline(array $delaySubline) + { + $result = []; + foreach ($delaySubline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * DelayPromote: 延迟提升 + * + * @return MatricPointModel[]|null + */ + public function getDelayPromote() + { + $items = $this->get("DelayPromote"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * DelayPromote: 延迟提升 + * + * @param MatricPointModel[] $delayPromote + */ + public function setDelayPromote(array $delayPromote) + { + $result = []; + foreach ($delayPromote as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * DelayPromoteSubline: 子线路延迟提升 + * + * @return MatricPointModel[]|null + */ + public function getDelayPromoteSubline() + { + $items = $this->get("DelayPromoteSubline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * DelayPromoteSubline: 子线路延迟提升 + * + * @param MatricPointModel[] $delayPromoteSubline + */ + public function setDelayPromoteSubline(array $delayPromoteSubline) + { + $result = []; + foreach ($delayPromoteSubline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * ConnectCount: 当前连接数 + * + * @return MatricPointModel[]|null + */ + public function getConnectCount() + { + $items = $this->get("ConnectCount"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * ConnectCount: 当前连接数 + * + * @param MatricPointModel[] $connectCount + */ + public function setConnectCount(array $connectCount) + { + $result = []; + foreach ($connectCount as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * ConnectCountSubline: 子线路当前连接数 + * + * @return MatricPointModel[]|null + */ + public function getConnectCountSubline() + { + $items = $this->get("ConnectCountSubline"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MatricPointModel($item)); + } + return $result; + } + + /** + * ConnectCountSubline: 子线路当前连接数 + * + * @param MatricPointModel[] $connectCountSubline + */ + public function setConnectCountSubline(array $connectCountSubline) + { + $result = []; + foreach ($connectCountSubline as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/PathX/Models/UGA3Price.php b/src/PathX/Models/UGA3Price.php new file mode 100644 index 00000000..c200bab6 --- /dev/null +++ b/src/PathX/Models/UGA3Price.php @@ -0,0 +1,104 @@ +get("AccelerationArea"); + } + + /** + * AccelerationArea: 加速大区代码 + * + * @param string $accelerationArea + */ + public function setAccelerationArea(string $accelerationArea) + { + $this->set("AccelerationArea", $accelerationArea); + } + /** + * AccelerationAreaName: 加速大区名称 + * + * @return string|null + */ + public function getAccelerationAreaName() + { + return $this->get("AccelerationAreaName"); + } + + /** + * AccelerationAreaName: 加速大区名称 + * + * @param string $accelerationAreaName + */ + public function setAccelerationAreaName(string $accelerationAreaName) + { + $this->set("AccelerationAreaName", $accelerationAreaName); + } + /** + * AccelerationForwarderPrice: 转发配置价格 + * + * @return float|null + */ + public function getAccelerationForwarderPrice() + { + return $this->get("AccelerationForwarderPrice"); + } + + /** + * AccelerationForwarderPrice: 转发配置价格 + * + * @param float $accelerationForwarderPrice + */ + public function setAccelerationForwarderPrice(float $accelerationForwarderPrice) + { + $this->set("AccelerationForwarderPrice", $accelerationForwarderPrice); + } + /** + * AccelerationBandwidthPrice: 加速配置带宽价格 + * + * @return float|null + */ + public function getAccelerationBandwidthPrice() + { + return $this->get("AccelerationBandwidthPrice"); + } + + /** + * AccelerationBandwidthPrice: 加速配置带宽价格 + * + * @param float $accelerationBandwidthPrice + */ + public function setAccelerationBandwidthPrice(float $accelerationBandwidthPrice) + { + $this->set("AccelerationBandwidthPrice", $accelerationBandwidthPrice); + } +} diff --git a/src/PathX/Models/UGAAInfo.php b/src/PathX/Models/UGAAInfo.php index 5cca88e7..ae623adb 100644 --- a/src/PathX/Models/UGAAInfo.php +++ b/src/PathX/Models/UGAAInfo.php @@ -1,6 +1,7 @@ set("UGAId", $ugaId); } - /** * CName: 加速域名,请在加速区域配置您的业务域名的CName记录值为加速域名 * @@ -57,11 +64,10 @@ public function getCName() * * @param string $cName */ - public function setCName($cName) + public function setCName(string $cName) { $this->set("CName", $cName); } - /** * UGAName: 加速配置名称 * @@ -77,11 +83,10 @@ public function getUGAName() * * @param string $ugaName */ - public function setUGAName($ugaName) + public function setUGAName(string $ugaName) { $this->set("UGAName", $ugaName); } - /** * IPList: 源站IP列表,多个值由半角英文逗号相隔 * @@ -101,7 +106,6 @@ public function setIPList(array $ipList) { $this->set("IPList", $ipList); } - /** * Domain: 源站域名 * @@ -117,11 +121,10 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * Location: 源站所在区域,加速实例在绑定线路后会自动设置该值。console页面上通过该值过滤加速实例可以绑定的upath实例。注意:缺少该值会导致在console上无法修改线路 * @@ -137,15 +140,14 @@ public function getLocation() * * @param string $location */ - public function setLocation($location) + public function setLocation(string $location) { $this->set("Location", $location); } - /** * UPathSet: 绑定的加速线路 * - * @return UPathSet[]|null + * @return UPathSetModel[]|null */ public function getUPathSet() { @@ -155,7 +157,7 @@ public function getUPathSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UPathSet($item)); + array_push($result, new UPathSetModel($item)); } return $result; } @@ -163,7 +165,7 @@ public function getUPathSet() /** * UPathSet: 绑定的加速线路 * - * @param UPathSet[] $uPathSet + * @param UPathSetModel[] $uPathSet */ public function setUPathSet(array $uPathSet) { @@ -173,11 +175,10 @@ public function setUPathSet(array $uPathSet) } return $result; } - /** * TaskSet: 端口配置信息(不再维护,建议使用ForwarderSet) * - * @return UGAATask[]|null + * @return UGAATaskModel[]|null */ public function getTaskSet() { @@ -187,7 +188,7 @@ public function getTaskSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UGAATask($item)); + array_push($result, new UGAATaskModel($item)); } return $result; } @@ -195,7 +196,7 @@ public function getTaskSet() /** * TaskSet: 端口配置信息(不再维护,建议使用ForwarderSet) * - * @param UGAATask[] $taskSet + * @param UGAATaskModel[] $taskSet */ public function setTaskSet(array $taskSet) { @@ -205,11 +206,10 @@ public function setTaskSet(array $taskSet) } return $result; } - /** * L4ForwarderSet: UGA 4层转发器配置,记录接入或回源端口,接入或回源协议信息 * - * @return UGAL4Forwarder[]|null + * @return UGAL4ForwarderModel[]|null */ public function getL4ForwarderSet() { @@ -219,7 +219,7 @@ public function getL4ForwarderSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UGAL4Forwarder($item)); + array_push($result, new UGAL4ForwarderModel($item)); } return $result; } @@ -227,7 +227,7 @@ public function getL4ForwarderSet() /** * L4ForwarderSet: UGA 4层转发器配置,记录接入或回源端口,接入或回源协议信息 * - * @param UGAL4Forwarder[] $l4ForwarderSet + * @param UGAL4ForwarderModel[] $l4ForwarderSet */ public function setL4ForwarderSet(array $l4ForwarderSet) { @@ -237,11 +237,10 @@ public function setL4ForwarderSet(array $l4ForwarderSet) } return $result; } - /** * L7ForwarderSet: UGA 7层转发器配置,记录接入或回源端口,接入或回源协议信息 如绑定证书会返回证书ID * - * @return UGAL7Forwarder[]|null + * @return UGAL7ForwarderModel[]|null */ public function getL7ForwarderSet() { @@ -251,7 +250,7 @@ public function getL7ForwarderSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UGAL7Forwarder($item)); + array_push($result, new UGAL7ForwarderModel($item)); } return $result; } @@ -259,7 +258,7 @@ public function getL7ForwarderSet() /** * L7ForwarderSet: UGA 7层转发器配置,记录接入或回源端口,接入或回源协议信息 如绑定证书会返回证书ID * - * @param UGAL7Forwarder[] $l7ForwarderSet + * @param UGAL7ForwarderModel[] $l7ForwarderSet */ public function setL7ForwarderSet(array $l7ForwarderSet) { @@ -269,11 +268,10 @@ public function setL7ForwarderSet(array $l7ForwarderSet) } return $result; } - /** * OutPublicIpList: 线路出口IP地址 * - * @return OutPublicIpInfo[]|null + * @return OutPublicIpInfoModel[]|null */ public function getOutPublicIpList() { @@ -283,7 +281,7 @@ public function getOutPublicIpList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new OutPublicIpInfo($item)); + array_push($result, new OutPublicIpInfoModel($item)); } return $result; } @@ -291,7 +289,7 @@ public function getOutPublicIpList() /** * OutPublicIpList: 线路出口IP地址 * - * @param OutPublicIpInfo[] $outPublicIpList + * @param OutPublicIpInfoModel[] $outPublicIpList */ public function setOutPublicIpList(array $outPublicIpList) { diff --git a/src/PathX/Models/UGAALine.php b/src/PathX/Models/UGAALine.php index 7e15e8f3..abadf488 100644 --- a/src/PathX/Models/UGAALine.php +++ b/src/PathX/Models/UGAALine.php @@ -1,6 +1,7 @@ set("LineFrom", $lineFrom); } - /** * LineTo: 线路目的 * @@ -57,11 +60,10 @@ public function getLineTo() * * @param string $lineTo */ - public function setLineTo($lineTo) + public function setLineTo(string $lineTo) { $this->set("LineTo", $lineTo); } - /** * LineFromName: 线路源中文名称 * @@ -77,11 +79,10 @@ public function getLineFromName() * * @param string $lineFromName */ - public function setLineFromName($lineFromName) + public function setLineFromName(string $lineFromName) { $this->set("LineFromName", $lineFromName); } - /** * LineToName: 线路目的中文名称 * @@ -97,11 +98,10 @@ public function getLineToName() * * @param string $lineToName */ - public function setLineToName($lineToName) + public function setLineToName(string $lineToName) { $this->set("LineToName", $lineToName); } - /** * MaxBandwidth: 线路可售最大带宽 * @@ -117,11 +117,10 @@ public function getMaxBandwidth() * * @param int $maxBandwidth */ - public function setMaxBandwidth($maxBandwidth) + public function setMaxBandwidth(int $maxBandwidth) { $this->set("MaxBandwidth", $maxBandwidth); } - /** * LineId: 线路计费Id * @@ -137,15 +136,14 @@ public function getLineId() * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } - /** * LineDetail: 子线路信息 * - * @return LineDetail[]|null + * @return LineDetailModel[]|null */ public function getLineDetail() { @@ -155,7 +153,7 @@ public function getLineDetail() } $result = []; foreach ($items as $i => $item) { - array_push($result, new LineDetail($item)); + array_push($result, new LineDetailModel($item)); } return $result; } @@ -163,7 +161,7 @@ public function getLineDetail() /** * LineDetail: 子线路信息 * - * @param LineDetail[] $lineDetail + * @param LineDetailModel[] $lineDetail */ public function setLineDetail(array $lineDetail) { diff --git a/src/PathX/Models/UGAATask.php b/src/PathX/Models/UGAATask.php index 4a9b6faf..919954b4 100644 --- a/src/PathX/Models/UGAATask.php +++ b/src/PathX/Models/UGAATask.php @@ -1,6 +1,7 @@ set("Port", $port); } - /** * Protocol: 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 * @@ -57,7 +62,7 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } diff --git a/src/PathX/Models/UGAL4Forwarder.php b/src/PathX/Models/UGAL4Forwarder.php index 3a7c337b..c4a3b218 100644 --- a/src/PathX/Models/UGAL4Forwarder.php +++ b/src/PathX/Models/UGAL4Forwarder.php @@ -1,6 +1,7 @@ set("Port", $port); } - /** * Protocol: 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 * @@ -57,11 +60,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * RSPort: RSPort,源站监听端口 * @@ -77,7 +79,7 @@ public function getRSPort() * * @param int $rsPort */ - public function setRSPort($rsPort) + public function setRSPort(int $rsPort) { $this->set("RSPort", $rsPort); } diff --git a/src/PathX/Models/UGAL7Forwarder.php b/src/PathX/Models/UGAL7Forwarder.php index c3f7c28d..a607dbdc 100644 --- a/src/PathX/Models/UGAL7Forwarder.php +++ b/src/PathX/Models/UGAL7Forwarder.php @@ -1,6 +1,7 @@ set("Port", $port); } - /** * Protocol: 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 * @@ -57,11 +60,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * RSPort: RSPort,源站监听端口 * @@ -77,11 +79,10 @@ public function getRSPort() * * @param int $rsPort */ - public function setRSPort($rsPort) + public function setRSPort(int $rsPort) { $this->set("RSPort", $rsPort); } - /** * SSLId: 证书ID * @@ -97,11 +98,10 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } - /** * SSLName: 证书名称 * @@ -117,7 +117,7 @@ public function getSSLName() * * @param string $sslName */ - public function setSSLName($sslName) + public function setSSLName(string $sslName) { $this->set("SSLName", $sslName); } diff --git a/src/PathX/Models/UPathInfo.php b/src/PathX/Models/UPathInfo.php index 6d13e8bf..adca0a65 100644 --- a/src/PathX/Models/UPathInfo.php +++ b/src/PathX/Models/UPathInfo.php @@ -1,6 +1,7 @@ set("PostPaid", $postPaid); } - /** * ChargeType: 计费模式,默认为Month 按月收费,可选范围['Month','Year','Dynamic'] * @@ -57,11 +61,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Name: UPath实例名字 * @@ -77,11 +80,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * UPathId: UPath加速线路实例ID * @@ -97,11 +99,10 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } - /** * Bandwidth: 带宽,单位Mbps * @@ -117,11 +118,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * LineId: 选择的线路 * @@ -137,15 +137,14 @@ public function getLineId() * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } - /** * UGAList: 与该UPath绑定的UGA列表 * - * @return PathXUGAInfo[]|null + * @return PathXUGAInfoModel[]|null */ public function getUGAList() { @@ -155,7 +154,7 @@ public function getUGAList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PathXUGAInfo($item)); + array_push($result, new PathXUGAInfoModel($item)); } return $result; } @@ -163,7 +162,7 @@ public function getUGAList() /** * UGAList: 与该UPath绑定的UGA列表 * - * @param PathXUGAInfo[] $ugaList + * @param PathXUGAInfoModel[] $ugaList */ public function setUGAList(array $ugaList) { @@ -173,7 +172,6 @@ public function setUGAList(array $ugaList) } return $result; } - /** * CreateTime: UPath创建的时间,10位时间戳 * @@ -189,11 +187,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: UPath的过期时间,10位时间戳 * @@ -209,11 +206,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * LineFromName: 线路入口名称 * @@ -229,11 +225,10 @@ public function getLineFromName() * * @param string $lineFromName */ - public function setLineFromName($lineFromName) + public function setLineFromName(string $lineFromName) { $this->set("LineFromName", $lineFromName); } - /** * LineToName: 线路出口名称 * @@ -249,15 +244,14 @@ public function getLineToName() * * @param string $lineToName */ - public function setLineToName($lineToName) + public function setLineToName(string $lineToName) { $this->set("LineToName", $lineToName); } - /** * OutPublicIpList: 线路出口IP数组 * - * @return OutPublicIpInfo[]|null + * @return OutPublicIpInfoModel[]|null */ public function getOutPublicIpList() { @@ -267,7 +261,7 @@ public function getOutPublicIpList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new OutPublicIpInfo($item)); + array_push($result, new OutPublicIpInfoModel($item)); } return $result; } @@ -275,7 +269,7 @@ public function getOutPublicIpList() /** * OutPublicIpList: 线路出口IP数组 * - * @param OutPublicIpInfo[] $outPublicIpList + * @param OutPublicIpInfoModel[] $outPublicIpList */ public function setOutPublicIpList(array $outPublicIpList) { diff --git a/src/PathX/Models/UPathSet.php b/src/PathX/Models/UPathSet.php index 55d30796..21c0a1df 100644 --- a/src/PathX/Models/UPathSet.php +++ b/src/PathX/Models/UPathSet.php @@ -1,6 +1,7 @@ set("UPathName", $uPathName); } - /** * UPathId: UPath 实例ID * @@ -57,11 +60,10 @@ public function getUPathId() * * @param string $uPathId */ - public function setUPathId($uPathId) + public function setUPathId(string $uPathId) { $this->set("UPathId", $uPathId); } - /** * Bandwidth: 带宽 Mbps, 1~800Mbps * @@ -77,11 +79,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * LineId: 线路ID * @@ -97,11 +98,10 @@ public function getLineId() * * @param string $lineId */ - public function setLineId($lineId) + public function setLineId(string $lineId) { $this->set("LineId", $lineId); } - /** * LineFromName: 线路起点中文名字,加速区域 * @@ -117,11 +117,10 @@ public function getLineFromName() * * @param string $lineFromName */ - public function setLineFromName($lineFromName) + public function setLineFromName(string $lineFromName) { $this->set("LineFromName", $lineFromName); } - /** * LineToName: 线路对端中文名字,源站区域 * @@ -137,11 +136,10 @@ public function getLineToName() * * @param string $lineToName */ - public function setLineToName($lineToName) + public function setLineToName(string $lineToName) { $this->set("LineToName", $lineToName); } - /** * LineFrom: 线路起点英文代号,加速区域 * @@ -157,11 +155,10 @@ public function getLineFrom() * * @param string $lineFrom */ - public function setLineFrom($lineFrom) + public function setLineFrom(string $lineFrom) { $this->set("LineFrom", $lineFrom); } - /** * LineTo: 线路对端英文代号,源站区域 * @@ -177,7 +174,7 @@ public function getLineTo() * * @param string $lineTo */ - public function setLineTo($lineTo) + public function setLineTo(string $lineTo) { $this->set("LineTo", $lineTo); } diff --git a/src/PathX/PathXClient.php b/src/PathX/PathXClient.php index b12e62a9..ddb3a5a5 100644 --- a/src/PathX/PathXClient.php +++ b/src/PathX/PathXClient.php @@ -1,6 +1,7 @@ (string) 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLId" => (string) 证书ID,如果没有指定证书ID也没有申请免费证书,HTTPS接入无法正常工作 - * "UGAId" => (string) UGA实例ID - * "Port" => (array) 绑定SSL证书的HTTPS端口。Port.0 Port.1对应多个Port。如果Port不存在则不会绑定 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BindPathXSSLResponse * @throws UCloudException */ public function bindPathXSSL(BindPathXSSLRequest $request = null) @@ -108,37 +256,13 @@ public function bindPathXSSL(BindPathXSSLRequest $request = null) $resp = $this->invoke($request); return new BindPathXSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateGlobalSSHInstance - 创建GlobalSSH实例 * - * See also: https://docs.ucloud.cn/api/pathx-api/create_global_ssh_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Area" => (string) 填写支持SSH访问IP的地区名称,如“洛杉矶”,“新加坡”,“香港”,“东京”,“华盛顿”,“法兰克福”,“首尔”。Area和AreaCode两者必填一个 - * "TargetIP" => (string) 被SSH访问的源站IP,仅支持IPv4地址。 - * "Port" => (integer) 源站服务器监听的SSH端口,可取范围[1-65535],不能使用80,443, 65123端口。如果InstanceType=Free,取值范围缩小为[22,3389],linux系统选择22,windows系统自动选3389。 - * "AreaCode" => (string) AreaCode, 区域航空港国际通用代码。Area和AreaCode两者必填一个 - * "Remark" => (string) 备注信息 - * "ChargeType" => (string) 支付方式,如按月:Month、 按年:Year、按时:Dynamic - * "Quantity" => (integer) 购买数量按月购买至月底请传0 - * "InstanceType" => (string) 枚举值:["Ultimate","Enterprise","Basic","Primary"], 分别代表旗舰版,企业版,基础版,入门版 - * "BandwidthPackage" => (integer) Ultimate版本带宽包大小,枚举值:[0,20,40]。单位MB - * "ForwardRegion" => (string) InstanceType等于Basic时可以在["cn-bj2","cn-sh2","cn-gd"]中选择1个作为转发机房,其他付费版默认配置三个转发机房 - * "CouponId" => (string) 使用代金券可冲抵部分费用 - * ] - * - * Outputs: - * - * $outputs = [ - * "InstanceId" => (string) 实例ID,资源唯一标识 - * "AcceleratingDomain" => (string) 加速域名,访问该域名可就近接入 - * ] - * - * @return CreateGlobalSSHInstanceResponse * @throws UCloudException */ public function createGlobalSSHInstance(CreateGlobalSSHInstanceRequest $request = null) @@ -146,31 +270,13 @@ public function createGlobalSSHInstance(CreateGlobalSSHInstanceRequest $request $resp = $this->invoke($request); return new CreateGlobalSSHInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreatePathXSSL - 创建SSL证书,可以把整个 Pem 证书内容传到SSLContent,或者把证书、私钥、CA证书分别传过来 * - * See also: https://docs.ucloud.cn/api/pathx-api/create_path_xssl - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID org-xxx格式。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLName" => (string) SSL证书的名字 - * "SSLType" => (string) 所添加的SSL证书类型,目前只支持Pem格式 - * "SSLContent" => (string) SSL证书的完整内容,私钥不可使用密码,包括加密证书的私钥、用户证书或CA证书等 - * "UserCert" => (string) 用户自签证书内容 - * "PrivateKey" => (string) 加密证书的私钥,不可使用密码保护,开启密码保护后,重启服务需要输入密码 - * "CACert" => (string) CA颁发证书内容 - * ] - * - * Outputs: - * - * $outputs = [ - * "SSLId" => (string) SSL证书的Id - * ] - * - * @return CreatePathXSSLResponse * @throws UCloudException */ public function createPathXSSL(CreatePathXSSLRequest $request = null) @@ -178,41 +284,41 @@ public function createPathXSSL(CreatePathXSSLRequest $request = null) $resp = $this->invoke($request); return new CreatePathXSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * CreateUGAForwarder - 创建加速实例转发器,支持HTTPS接入HTTPS回源、HTTPS接入HTTP回源、HTTP接入HTTP回源、TCP接入TCP回源、UDP接入UDP回源、 支持WSS接入WSS回源、WSS接入WS回源、WS接入WS回源 - * - * See also: https://docs.ucloud.cn/api/pathx-api/create_uga_forwarder - * - * Arguments: + * CreateUGA3Instance - 创建全球统一接入加速配置项 * - * $args = [ - * "ProjectId" => (string) 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UGAId" => (string) 加速配置实例ID - * "HTTPHTTP" => (array) HTTP接入HTTP回源转发,接入端口。禁用65123端口 - * "HTTPHTTPRS" => (array) HTTP接入HTTP回源转发,源站监听端口 - * "HTTPSHTTP" => (array) HTTPS接入HTTP回源转发,接入端口。禁用65123端口 - * "HTTPSHTTPRS" => (array) HTTPS接入HTTP回源转发,回源端口 - * "HTTPSHTTPS" => (array) HTTPS接入HTTPS回源转发,接入端口。禁用65123端口 - * "HTTPSHTTPSRS" => (array) HTTPS接入HTTPS回源转发,源站监听端口 - * "TCP" => (array) TCP接入端口,禁用65123端口 - * "TCPRS" => (array) TCP回源端口 - * "UDP" => (array) UDP接入端口,禁用65123端口 - * "UDPRS" => (array) UDP回源端口 - * "WSWS" => (array) WebSocket接入WebSocket回源转发,接入端口。禁用65123。 - * "WSWSRS" => (array) WebSocket接入WebSocket回源转发,源站监听端口 - * "WSSWSS" => (array) WebSocketS接入WebSocketS回源转发,接入端口。禁用65123。 - * "WSSWSSRS" => (array) WebSocketS接入WebSocketS回源转发,源站监听端口。 - * "WSSWS" => (array) WebSocketS接入WebSocket回源转发,接入端口。禁用65123。 - * "WSSWSRS" => (array) WebSocketS接入WebSocket回源转发,源站监听端口。 - * ] - * - * Outputs: + * @throws UCloudException + */ + public function createUGA3Instance(CreateUGA3InstanceRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateUGA3InstanceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateUGA3Port - 创建统一接入加速实例端口,目前仅支持四层TCP端口 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function createUGA3Port(CreateUGA3PortRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateUGA3PortResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateUGAForwarder - 创建加速实例转发器,支持HTTPS接入HTTPS回源、HTTPS接入HTTP回源、HTTP接入HTTP回源、TCP接入TCP回源、UDP接入UDP回源、 支持WSS接入WSS回源、WSS接入WS回源、WS接入WS回源 * - * @return CreateUGAForwarderResponse * @throws UCloudException */ public function createUGAForwarder(CreateUGAForwarderRequest $request = null) @@ -220,31 +326,13 @@ public function createUGAForwarder(CreateUGAForwarderRequest $request = null) $resp = $this->invoke($request); return new CreateUGAForwarderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUGAInstance - 创建全球加速配置项 * - * See also: https://docs.ucloud.cn/api/pathx-api/create_uga_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) 加速配置实例名称 - * "IPList" => (string) 加速源IP,多个IP用英文半角逗号(,)隔开;IPList和Domain二选一必填 - * "Domain" => (string) 加速源域名,IPList和Domain二选一必填 - * "TCP" => (array) TCP端口号,已废弃。请使用 CreateUGAForwarder API 创建端口 - * "UDP" => (array) UDP端口号,已废弃。请使用 CreateUGAForwarder API 创建端口 - * ] - * - * Outputs: - * - * $outputs = [ - * "UGAId" => (string) 加速配置ID - * "CName" => (string) 加速域名 用户可把业务域名CName到此域名上。注意:未绑定线路情况时 加速域名解析不出IP。 - * ] - * - * @return CreateUGAInstanceResponse * @throws UCloudException */ public function createUGAInstance(CreateUGAInstanceRequest $request = null) @@ -252,32 +340,13 @@ public function createUGAInstance(CreateUGAInstanceRequest $request = null) $resp = $this->invoke($request); return new CreateUGAInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUPath - 创建UPath * - * See also: https://docs.ucloud.cn/api/pathx-api/create_upath - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) UPath名字 - * "LineId" => (string) 选择的线路 - * "Bandwidth" => (integer) 线路带宽,最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。如需更大带宽,请联系产品团队。 - * "ChargeType" => (string) 计费模式,默认为Month 按月收费,可选范围['Month','Year','Dynamic'] - * "Quantity" => (integer) 购买周期,ChargeType为Month时,Quantity默认为0代表购买到月底,按时和按年付费该参数必须大于0 - * "PostPaid" => (boolean) 是否开启后付费, 默认为false - * "CouponId" => (string) 代金券Id - * ] - * - * Outputs: - * - * $outputs = [ - * "UPathId" => (string) 加速线路实例Id - * ] - * - * @return CreateUPathResponse * @throws UCloudException */ public function createUPath(CreateUPathRequest $request = null) @@ -285,25 +354,13 @@ public function createUPath(CreateUPathRequest $request = null) $resp = $this->invoke($request); return new CreateUPathResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteGlobalSSHInstance - 删除GlobalSSH实例 * - * See also: https://docs.ucloud.cn/api/pathx-api/delete_global_ssh_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "InstanceId" => (string) 实例Id,资源的唯一标识 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteGlobalSSHInstanceResponse * @throws UCloudException */ public function deleteGlobalSSHInstance(DeleteGlobalSSHInstanceRequest $request = null) @@ -311,25 +368,13 @@ public function deleteGlobalSSHInstance(DeleteGlobalSSHInstanceRequest $request $resp = $this->invoke($request); return new DeleteGlobalSSHInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeletePathXSSL - 删除PathX SSL证书 * - * See also: https://docs.ucloud.cn/api/pathx-api/delete_path_xssl - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLId" => (string) SSL证书的ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeletePathXSSLResponse * @throws UCloudException */ public function deletePathXSSL(DeletePathXSSLRequest $request = null) @@ -337,33 +382,41 @@ public function deletePathXSSL(DeletePathXSSLRequest $request = null) $resp = $this->invoke($request); return new DeletePathXSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DeleteUGAForwarder - 删除加速实例转发器 按接入端口删除 + * DeleteUGA3Instance - 删除全球统一接入转发实例 * - * See also: https://docs.ucloud.cn/api/pathx-api/delete_uga_forwarder - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UGAId" => (string) 加速配置实例ID - * "HTTPHTTP" => (array) HTTP接入HTTP回源,接入端口。禁用65123端口 - * "HTTPSHTTP" => (array) HTTPS接入HTTP回源, 接入端口。禁用65123端口 - * "HTTPSHTTPS" => (array) HTTPS接入HTTPS回源, 接入端口。禁用65123端口 - * "WSSWSS" => (array) WebSocketS接入WebSocketS回源, 接入端口。禁用65123端口 - * "WSWS" => (array) WebSocket接入WebSocket回源, 接入端口。禁用65123端口 - * "WSSWS" => (array) WebSocketS接入WebSocket回源, 接入端口。禁用65123端口。 - * "TCP" => (array) TCP接入端口 - * "UDP" => (array) UDP接入端口 - * ] - * - * Outputs: + * @throws UCloudException + */ + public function deleteUGA3Instance(DeleteUGA3InstanceRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteUGA3InstanceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteUGA3Port - 删除统一接入加速实例转发器 按接入端口删除 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function deleteUGA3Port(DeleteUGA3PortRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteUGA3PortResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteUGAForwarder - 删除加速实例转发器 按接入端口删除 * - * @return DeleteUGAForwarderResponse * @throws UCloudException */ public function deleteUGAForwarder(DeleteUGAForwarderRequest $request = null) @@ -371,25 +424,13 @@ public function deleteUGAForwarder(DeleteUGAForwarderRequest $request = null) $resp = $this->invoke($request); return new DeleteUGAForwarderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUGAInstance - 删除全球加速服务加速配置 * - * See also: https://docs.ucloud.cn/api/pathx-api/delete_uga_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UGAId" => (string) 加速配置实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUGAInstanceResponse * @throws UCloudException */ public function deleteUGAInstance(DeleteUGAInstanceRequest $request = null) @@ -397,25 +438,13 @@ public function deleteUGAInstance(DeleteUGAInstanceRequest $request = null) $resp = $this->invoke($request); return new DeleteUGAInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUPath - 删除UPath * - * See also: https://docs.ucloud.cn/api/pathx-api/delete_upath - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UPathId" => (string) 加速线路实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUPathResponse * @throws UCloudException */ public function deleteUPath(DeleteUPathRequest $request = null) @@ -423,43 +452,13 @@ public function deleteUPath(DeleteUPathRequest $request = null) $resp = $this->invoke($request); return new DeleteUPathResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeGlobalSSHInstance - 获取GlobalSSH实例列表(传实例ID获取单个实例信息,不传获取项目下全部实例) * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_global_ssh_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "InstanceId" => (string) 实例ID,资源唯一标识 - * ] - * - * Outputs: - * - * $outputs = [ - * "InstanceSet" => (array) GlobalSSH实例列表,实例的属性参考GlobalSSHInfo模型[ - * [ - * "InstanceId" => (string) 实例ID,资源唯一标识 - * "InstanceType" => (string) 枚举值:["Enterprise","Basic","Free","Welfare"], 分别代表企业版,基础版本,免费版本,较早的公测免费版 - * "AcceleratingDomain" => (string) GlobalSSH分配的加速域名。 - * "Area" => (string) 被SSH访问的IP所在地区 - * "TargetIP" => (string) 被SSH访问的源站 IPv4地址。 - * "Remark" => (string) 备注信息 - * "Port" => (integer) 源站服务器监听的SSH端口,windows系统为RDP端口 - * "GlobalSSHPort" => (integer) InstanceType等于Free时,由系统自动分配,不等于源站Port值。InstanceType不等于Free时,与源站Port值相同。 - * "ChargeType" => (string) 支付周期,如Month,Year,Dynamic等 - * "CreateTime" => (integer) 资源创建时间戳 - * "ExpireTime" => (integer) 资源过期时间戳 - * "Expire" => (boolean) 是否过期 - * "BandwidthPackage" => (integer) globalssh Ultimate带宽包大小 - * "ForwardRegion" => (string) InstanceType为Basic版本时,需要展示具体分配的转发机房 - * ] - * ] - * ] - * - * @return DescribeGlobalSSHInstanceResponse * @throws UCloudException */ public function describeGlobalSSHInstance(DescribeGlobalSSHInstanceRequest $request = null) @@ -467,43 +466,13 @@ public function describeGlobalSSHInstance(DescribeGlobalSSHInstanceRequest $requ $resp = $this->invoke($request); return new DescribeGlobalSSHInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePathXLineConfig - 获取全球加速线路信息 * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_path_x_line_config - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "LineSet" => (array) UGAA线路列表,参考UGAALine字段定义[ - * [ - * "LineFrom" => (string) 线路源 - * "LineTo" => (string) 线路目的 - * "LineFromName" => (string) 线路源中文名称 - * "LineToName" => (string) 线路目的中文名称 - * "MaxBandwidth" => (integer) 线路可售最大带宽 - * "LineId" => (string) 线路计费Id - * "LineDetail" => (array) 子线路信息[ - * [ - * "LineFrom" => (string) 线路源 - * "LineTo" => (string) 线路目的 - * "LineId" => (string) 线路计费Id - * "LineFromName" => (string) 线路源中文名称 - * "LineToName" => (string) 线路目的中文名称 - * ] - * ] - * ] - * ] - * ] - * - * @return DescribePathXLineConfigResponse * @throws UCloudException */ public function describePathXLineConfig(DescribePathXLineConfigRequest $request = null) @@ -511,47 +480,13 @@ public function describePathXLineConfig(DescribePathXLineConfigRequest $request $resp = $this->invoke($request); return new DescribePathXLineConfigResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePathXSSL - 获取SSL证书信息,支持分页,支持按证书名称 证书域名模糊搜索 * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_path_xssl - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLId" => (string) SSL证书的Id,不传分页获取证书列表 - * "SearchValue" => (string) 不为空则按证书名称、证书域名模糊搜索 分页返回结果 - * "Limit" => (integer) 最大返回条数,默认100,最大400 - * "Offset" => (integer) 偏移值 默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) SSL证书详细信息,具体结构见 PathXSSLSet[ - * [ - * "SSLId" => (string) SSL证书的Id - * "SSLName" => (string) SSL证书的名字 - * "SubjectName" => (string) 证书域名 - * "ExpireTime" => (integer) 证书过期时间 时间戳 - * "SourceType" => (integer) 证书来源,0:用户上传 1: 免费颁发 - * "SSLMD5" => (string) SSL证书(用户证书、私钥、ca证书合并)内容md5值 - * "CreateTime" => (integer) SSL证书的创建时间 时间戳 - * "SSLBindedTargetSet" => (array) SSL证书绑定的对象[ - * [ - * "ResourceId" => (string) SSL证书绑定到的实例ID - * "ResourceName" => (string) SSL证书绑定到的实例名称 - * ] - * ] - * "SSLContent" => (string) SSL证书内容 - * ] - * ] - * "TotalCount" => (integer) 符合条件的证书总数 - * ] - * - * @return DescribePathXSSLResponse * @throws UCloudException */ public function describePathXSSL(DescribePathXSSLRequest $request = null) @@ -559,78 +494,55 @@ public function describePathXSSL(DescribePathXSSLRequest $request = null) $resp = $this->invoke($request); return new DescribePathXSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DescribeUGAInstance - 获取全球加速服务加速配置信息,指定实例ID返回单个实例。未指定实例ID时 指定分页参数 则按创建时间降序 返回记录 + * DescribeUGA3Area - 获取全球接入源站可选列表 * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_uga_instance - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UGAId" => (string) 加速配置实例ID,如果传了实例ID 则返回匹配实例ID的记录;如果没传则返回 ProjectId 下全部实例且符合分页要求 - * "Limit" => (integer) 返回的最大条数,默认为100,最大值400 - * "Offset" => (integer) 偏移量,默认为0 - * ] + * @throws UCloudException + */ + public function describeUGA3Area(DescribeUGA3AreaRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUGA3AreaResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUGA3Instance - 获取全球统一接入加速服务加速配置信息,指定实例ID返回单个实例。未指定实例ID时 指定分页参数 则按创建时间降序 返回记录 * - * Outputs: + * @throws UCloudException + */ + public function describeUGA3Instance(DescribeUGA3InstanceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUGA3InstanceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUGA3Optimization - 获取全球接入UGA3线路加速化情况 * - * $outputs = [ - * "UGAList" => (array) 全球加速实例信息列表[ - * [ - * "UGAId" => (string) 加速配置实例ID - * "CName" => (string) 加速域名,请在加速区域配置您的业务域名的CName记录值为加速域名 - * "UGAName" => (string) 加速配置名称 - * "IPList" => (array) 源站IP列表,多个值由半角英文逗号相隔 - * "Domain" => (string) 源站域名 - * "Location" => (string) 源站所在区域,加速实例在绑定线路后会自动设置该值。console页面上通过该值过滤加速实例可以绑定的upath实例。注意:缺少该值会导致在console上无法修改线路 - * "UPathSet" => (array) 绑定的加速线路[ - * [ - * "UPathName" => (string) UPath名字 - * "UPathId" => (string) UPath 实例ID - * "Bandwidth" => (integer) 带宽 Mbps, 1~800Mbps - * "LineId" => (string) 线路ID - * "LineFromName" => (string) 线路起点中文名字,加速区域 - * "LineToName" => (string) 线路对端中文名字,源站区域 - * "LineFrom" => (string) 线路起点英文代号,加速区域 - * "LineTo" => (string) 线路对端英文代号,源站区域 - * ] - * ] - * "TaskSet" => (array) 端口配置信息(不再维护,建议使用ForwarderSet)[ - * [ - * "Port" => (integer) 接入端口 - * "Protocol" => (string) 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 - * ] - * ] - * "L4ForwarderSet" => (array) UGA 4层转发器配置,记录接入或回源端口,接入或回源协议信息[ - * [ - * "Port" => (integer) 接入端口 - * "Protocol" => (string) 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 - * "RSPort" => (integer) RSPort,源站监听端口 - * ] - * ] - * "L7ForwarderSet" => (array) UGA 7层转发器配置,记录接入或回源端口,接入或回源协议信息 如绑定证书会返回证书ID[ - * [ - * "Port" => (integer) 接入端口 - * "Protocol" => (string) 转发协议,枚举值["TCP","UDP","HTTPHTTP","HTTPSHTTP","HTTPSHTTPS"]。TCP和UDP代表四层转发,其余为七层转发 - * "RSPort" => (integer) RSPort,源站监听端口 - * "SSLId" => (string) 证书ID - * "SSLName" => (string) 证书名称 - * ] - * ] - * "OutPublicIpList" => (array) 线路出口IP地址[ - * [ - * "IP" => (string) 线路出口EIP - * "Area" => (string) 线路出口机房代号 - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 符合条件的总数 - * ] + * @throws UCloudException + */ + public function describeUGA3Optimization(DescribeUGA3OptimizationRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUGA3OptimizationResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUGAInstance - 获取全球加速服务加速配置信息,指定实例ID返回单个实例。未指定实例ID时 指定分页参数 则按创建时间降序 返回记录 * - * @return DescribeUGAInstanceResponse * @throws UCloudException */ public function describeUGAInstance(DescribeUGAInstanceRequest $request = null) @@ -638,52 +550,13 @@ public function describeUGAInstance(DescribeUGAInstanceRequest $request = null) $resp = $this->invoke($request); return new DescribeUGAInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUPath - 获取加速线路信息 * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_upath - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UPathId" => (string) 如果不填参数 返回 ProjectId 下所有的线路资源,填此参数则返回upath实例ID匹配的线路 - * ] - * - * Outputs: - * - * $outputs = [ - * "UPathSet" => (array) 线路信息数组[ - * [ - * "PostPaid" => (boolean) 是否为后付费实例 - * "ChargeType" => (string) 计费模式,默认为Month 按月收费,可选范围['Month','Year','Dynamic'] - * "Name" => (string) UPath实例名字 - * "UPathId" => (string) UPath加速线路实例ID - * "Bandwidth" => (integer) 带宽,单位Mbps - * "LineId" => (string) 选择的线路 - * "UGAList" => (array) 与该UPath绑定的UGA列表[ - * [ - * "UGAId" => (string) 加速配置ID - * "IPList" => (array) 源站IP列表,多个值由半角英文逗号相隔 - * "Domain" => (string) 源站域名 - * ] - * ] - * "CreateTime" => (integer) UPath创建的时间,10位时间戳 - * "ExpireTime" => (integer) UPath的过期时间,10位时间戳 - * "LineFromName" => (string) 线路入口名称 - * "LineToName" => (string) 线路出口名称 - * "OutPublicIpList" => (array) 线路出口IP数组[ - * [ - * "IP" => (string) 线路出口EIP - * "Area" => (string) 线路出口机房代号 - * ] - * ] - * ] - * ] - * ] - * - * @return DescribeUPathResponse * @throws UCloudException */ public function describeUPath(DescribeUPathRequest $request = null) @@ -691,38 +564,13 @@ public function describeUPath(DescribeUPathRequest $request = null) $resp = $this->invoke($request); return new DescribeUPathResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUPathTemplate - 查询UPath的监控模板 * - * See also: https://docs.ucloud.cn/api/pathx-api/describe_upath_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UPathId" => (string) 加速线路实例ID,格式 upath-xxxx - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 监控模板详情[ - * [ - * "AlarmStrategy" => (string) 收敛策略,可选范围 ['Exponential','Continuous','Once'],分别对应指数递增、连续告警、单次告警 - * "AlarmFrequency" => (integer) 告警探测周期,单位秒 - * "Compare" => (string) 比较策略,可选 ['GE','LE'] 分别代表不小于和不大于 - * "ContactGroupId" => (integer) 联系组ID - * "MetricName" => (string) 告警指标名称, 所有n的个数必须一致。目前仅允许以下四项:UpathNetworkOut:出向带宽,UpathNetworkIn:入向带宽,UpathNetworkOutUsage:出向带宽使用率,UpathNetworkInUsage:入向带宽使用率 - * "Threshold" => (integer) 告警阈值,带宽使用率的阈值范围是[50,100]的正整数,带宽告警阈值为1000000的倍数, 如大于2Mbps则告警 阈值应该传 2000000 - * "TriggerCount" => (integer) 告警触发周期(次数) - * "AlarmTemplateRuleId" => (integer) 告警模板策略ID - * "ResourceType" => (string) 资源类型 - * ] - * ] - * ] - * - * @return DescribeUPathTemplateResponse * @throws UCloudException */ public function describeUPathTemplate(DescribeUPathTemplateRequest $request = null) @@ -730,28 +578,13 @@ public function describeUPathTemplate(DescribeUPathTemplateRequest $request = nu $resp = $this->invoke($request); return new DescribeUPathTemplateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetGlobalSSHPrice - 获取GlobalSSH价格 * - * See also: https://docs.ucloud.cn/api/pathx-api/get_global_ssh_price - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "Quantity" => (integer) 购买周期,如果ChargeType为Month,Quantity默认为0;其他情况必须为大于0的整数 - * "ChargeType" => (string) 计费类型:Dynamic,Month,Year - * "InstanceType" => (string) 版本类型。枚举值,Enterprise:企业版;Basic:基础版。可不填,默认为Basic。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 价格,返回单位为元 - * ] - * - * @return GetGlobalSSHPriceResponse * @throws UCloudException */ public function getGlobalSSHPrice(GetGlobalSSHPriceRequest $request = null) @@ -759,29 +592,13 @@ public function getGlobalSSHPrice(GetGlobalSSHPriceRequest $request = null) $resp = $this->invoke($request); return new GetGlobalSSHPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetGlobalSSHUpdatePrice - 获取GlobalSSH升级价格 * - * See also: https://docs.ucloud.cn/api/pathx-api/get_global_ssh_update_price - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "InstanceType" => (string) 升级后的实例类型。枚举值,Enterprise:企业版;Basic:基础版。 - * "InstanceId" => (string) 实例ID,唯一资源标识。从免费版升级到付费版可不填,其他情况必填。 - * "Quantity" => (integer) 购买周期,如果ChargeType为Month,Quantity可以不填默认为0;其他情况必须为正整数。 - * "ChargeType" => (string) 计费类型:Dynamic,Month,Year。从免费版升级到付费版必须传,其他情况不需要传 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 价格,返回单位为元。正数表示付费升级,负数表示降级退费。 - * ] - * - * @return GetGlobalSSHUpdatePriceResponse * @throws UCloudException */ public function getGlobalSSHUpdatePrice(GetGlobalSSHUpdatePriceRequest $request = null) @@ -789,56 +606,13 @@ public function getGlobalSSHUpdatePrice(GetGlobalSSHUpdatePriceRequest $request $resp = $this->invoke($request); return new GetGlobalSSHUpdatePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetPathXMetric - 获取全球加速监控信息 * - * See also: https://docs.ucloud.cn/api/pathx-api/get_path_x_metric - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ResourceId" => (string) ResourceId,如upath ID 和 uga ID - * "BeginTime" => (integer) 查询起始时间,10位长度时间戳 - * "EndTime" => (integer) 查询结束时间,10位长度时间戳 - * "MetricName" => (array) 查询监控的指标项。目前仅允许以下四项:NetworkOut:出向带宽,NetworkIn:入向带宽,NetworkOutUsage:出向带宽使用率,NetworkInUsage:入向带宽使用率 - * "ResourceType" => (string) upath:加速线路,uga:加速实例 - * "LineId" => (string) 具体线路id,调用DescribePathXLineConfig接口获取线路列表 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (object) 监控数据结果集[ - * "NetworkOut" => (array) 出向带宽[ - * [ - * "Timestamp" => (integer) 时间戳 - * "Value" => (integer) 监控点数值 - * ] - * ] - * "NetworkIn" => (array) 入向带宽[ - * [ - * "Timestamp" => (integer) 时间戳 - * "Value" => (integer) 监控点数值 - * ] - * ] - * "NetworkOutUsage" => (array) 出向带宽使用率[ - * [ - * "Timestamp" => (integer) 时间戳 - * "Value" => (integer) 监控点数值 - * ] - * ] - * "NetworkInUsage" => (array) 入向带宽使用率[ - * [ - * "Timestamp" => (integer) 时间戳 - * "Value" => (integer) 监控点数值 - * ] - * ] - * ] - * ] - * - * @return GetPathXMetricResponse * @throws UCloudException */ public function getPathXMetric(GetPathXMetricRequest $request = null) @@ -846,26 +620,55 @@ public function getPathXMetric(GetPathXMetricRequest $request = null) $resp = $this->invoke($request); return new GetPathXMetricResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ModifyGlobalSSHPort - 修改GlobalSSH端口 + * GetUGA3Metric - 获取全地域加速监控信息 * - * See also: https://docs.ucloud.cn/api/pathx-api/modify_global_ssh_port - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "InstanceId" => (string) 实例ID,资源唯一标识。当前仅收费版GlobalSSH实例可以修改端口。 - * "Port" => (integer) 源站服务器监听的SSH端口号。收费版本端口范围[1,65535]且不能为80,443,65123端口。免费版不支持修改端口。 - * ] + * @throws UCloudException + */ + public function getUGA3Metric(GetUGA3MetricRequest $request = null) + { + $resp = $this->invoke($request); + return new GetUGA3MetricResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetUGA3Price - 获取全球统一接入转发实例价格 * - * Outputs: + * @throws UCloudException + */ + public function getUGA3Price(GetUGA3PriceRequest $request = null) + { + $resp = $this->invoke($request); + return new GetUGA3PriceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetUGA3UpdatePrice - 全球统一接入获取实例更新价格(增加、删退) * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function getUGA3UpdatePrice(GetUGA3UpdatePriceRequest $request = null) + { + $resp = $this->invoke($request); + return new GetUGA3UpdatePriceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyGlobalSSHPort - 修改GlobalSSH端口 * - * @return ModifyGlobalSSHPortResponse * @throws UCloudException */ public function modifyGlobalSSHPort(ModifyGlobalSSHPortRequest $request = null) @@ -873,29 +676,27 @@ public function modifyGlobalSSHPort(ModifyGlobalSSHPortRequest $request = null) $resp = $this->invoke($request); return new ModifyGlobalSSHPortResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ModifyGlobalSSHType - 修改GlobalSSH实例类型,仅支持低版本升级到高版本,不支持高版本降级到低版本 - * - * See also: https://docs.ucloud.cn/api/pathx-api/modify_global_ssh_type + * ModifyGlobalSSHRemark - 修改GlobalSSH备注 * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](../summary/get_project_list.html) - * "InstanceId" => (string) 实例ID,资源唯一标识 - * "InstanceType" => (string) 取值范围["Enterprise","Basic"],分别对应企业版和基础版,表示升级后的实例类型。比如从Free版本升级为Basic版或Enterprise版,不可从收费版降级为免费版,或从企业版降级为基础版 - * "ChargeType" => (string) 支付方式,如按月、按年、按时 - * "Quantity" => (string) 购买时间,当ChargeType为Month,Quantity为0代表购买到月底 - * "CouponId" => (string) 可抵扣费用的券,通常不使用 - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function modifyGlobalSSHRemark(ModifyGlobalSSHRemarkRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyGlobalSSHRemarkResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyGlobalSSHType - 修改GlobalSSH实例类型,仅支持低版本升级到高版本,不支持高版本降级到低版本 * - * @return ModifyGlobalSSHTypeResponse * @throws UCloudException */ public function modifyGlobalSSHType(ModifyGlobalSSHTypeRequest $request = null) @@ -903,26 +704,69 @@ public function modifyGlobalSSHType(ModifyGlobalSSHTypeRequest $request = null) $resp = $this->invoke($request); return new ModifyGlobalSSHTypeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ModifyUPathBandwidth - 修改加速线路带宽 + * ModifyUGA3Bandwidth - 修改统一接入加速配置带宽 * - * See also: https://docs.ucloud.cn/api/pathx-api/modify_upath_bandwidth - * - * Arguments: + * @throws UCloudException + */ + public function modifyUGA3Bandwidth(ModifyUGA3BandwidthRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyUGA3BandwidthResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyUGA3Instance - 修改统一接入加速配置属性,如Name,ReMark * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UPathId" => (string) UPath 加速线路实例Id - * "Bandwidth" => (integer) 线路带宽,单位Mbps。最小1Mbps,最大带宽由 DescribePathXLineConfig 接口获得。如需更大带宽,请联系产品团队。 - * ] + * @throws UCloudException + */ + public function modifyUGA3Instance(ModifyUGA3InstanceRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyUGA3InstanceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyUGA3OriginInfo - Domain, IPList注意:修改Domain或IPList时, 请确保源站服务端口已经开启且外网防火墙允许pathx出口ip访问。 * - * Outputs: + * @throws UCloudException + */ + public function modifyUGA3OriginInfo(ModifyUGA3OriginInfoRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyUGA3OriginInfoResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyUGA3Port - 修改统一接入加速实例端口,目前仅支持四层TCP端口 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function modifyUGA3Port(ModifyUGA3PortRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyUGA3PortResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyUPathBandwidth - 修改加速线路带宽 * - * @return ModifyUPathBandwidthResponse * @throws UCloudException */ public function modifyUPathBandwidth(ModifyUPathBandwidthRequest $request = null) @@ -930,32 +774,13 @@ public function modifyUPathBandwidth(ModifyUPathBandwidthRequest $request = null $resp = $this->invoke($request); return new ModifyUPathBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUPathTemplate - 修改UPath监控告警项 * - * See also: https://docs.ucloud.cn/api/pathx-api/modify_upath_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UPathId" => (string) 加速线路实例ID - * "MetricName" => (array) 告警指标名称, 所有n的个数必须一致。目前仅允许以下四项:UpathNetworkOut:出向带宽,UpathNetworkIn:入向带宽,UpathNetworkOutUsage:出向带宽使用率,UpathNetworkInUsage:入向带宽使用率 - * "Threshold" => (array) 告警阈值,带宽使用率的阈值范围是[50,100]的正整数,带宽告警阈值为1000000的倍数, 如大于2Mbps则告警 阈值应该传 2000000 - * "AlarmFrequency" => (array) 告警探测周期,单位:秒 - * "ContactGroupId" => (array) 告警组id - * "Compare" => (array) 比较策略,可选 ['GE','LE'] 分别代表不小于和不大于 - * "AlarmStrategy" => (array) 收敛策略,可选范围 ['Exponential','Continuous','Once'],分别对应指数递增、连续告警、单次告警 - * "TriggerCount" => (array) 告警触发周期(次数) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUPathTemplateResponse * @throws UCloudException */ public function modifyUPathTemplate(ModifyUPathTemplateRequest $request = null) @@ -963,27 +788,13 @@ public function modifyUPathTemplate(ModifyUPathTemplateRequest $request = null) $resp = $this->invoke($request); return new ModifyUPathTemplateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UGABindUPath - UGA绑定UPath * - * See also: https://docs.ucloud.cn/api/pathx-api/uga_bind_upath - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UGAId" => (string) 加速配置实例ID,格式uga-xxxx - * "UPathId" => (string) 加速线路实例ID,格式upath-xxx - * "CouponId" => (string) 代金券 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UGABindUPathResponse * @throws UCloudException */ public function ugaBindUPath(UGABindUPathRequest $request = null) @@ -991,26 +802,13 @@ public function ugaBindUPath(UGABindUPathRequest $request = null) $resp = $this->invoke($request); return new UGABindUPathResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UGAUnBindUPath - UGA与UPath解绑 * - * See also: https://docs.ucloud.cn/api/pathx-api/uga_un_bind_upath - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。请参考[GetProjectList接口](../summary/get_project_list.html) - * "UGAId" => (string) 加速配置实例ID 格式uga-xxx - * "UPathId" => (string) 加速线路实例ID 格式upath-xxx - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UGAUnBindUPathResponse * @throws UCloudException */ public function ugaUnBindUPath(UGAUnBindUPathRequest $request = null) @@ -1018,27 +816,13 @@ public function ugaUnBindUPath(UGAUnBindUPathRequest $request = null) $resp = $this->invoke($request); return new UGAUnBindUPathResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UnBindPathXSSL - 解绑PathX SSL 证书 * - * See also: https://docs.ucloud.cn/api/pathx-api/un_bind_path_xssl - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UGAId" => (string) UGA实例ID。 - * "SSLId" => (string) SSL证书ID。 - * "Port" => (array) 解绑SSL证书的HTTPS端口。Port.0 Port.1格式 端口错误则解绑失败。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UnBindPathXSSLResponse * @throws UCloudException */ public function unBindPathXSSL(UnBindPathXSSLRequest $request = null) @@ -1046,26 +830,13 @@ public function unBindPathXSSL(UnBindPathXSSLRequest $request = null) $resp = $this->invoke($request); return new UnBindPathXSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdatePathXWhitelist - 更新入口白名单,仅限GlobalSSH 实例使用。其他uga-实例不生效 * - * See also: https://docs.ucloud.cn/api/pathx-api/update_path_x_whitelist - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,如org-xxxx。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "InstanceId" => (string) GlobalSSH实例ID,资源唯一标识 - * "Whitelist" => (array) 白名单规则,例如 "Whitelist.0": "192.168.1.1/24|tcp|22","Whitelist.1": "192.168.1.2|tcp|8080:8090",第一个参数为ip或ip段,第二个参数代表协议(tcp/udp),第三个参数代表端口号或端口范围(使用 ':' 隔开);可以添加多条规则(递增Whitelist.n字段内的n值);此接口需要列出全部规则,例如不填则为清空白名单规则,如若需要增量添加,使用InsertPathXWhitelist接口,globalssh 没有端口范围:端口设置成加速端口,协议设置成tcp:ip|tcp|加速端口 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdatePathXWhitelistResponse * @throws UCloudException */ public function updatePathXWhitelist(UpdatePathXWhitelistRequest $request = null) diff --git a/src/UAccount/Apis/AddMemberToProjectRequest.php b/src/UAccount/Apis/AddMemberToProjectRequest.php index 274b6566..523de04d 100644 --- a/src/UAccount/Apis/AddMemberToProjectRequest.php +++ b/src/UAccount/Apis/AddMemberToProjectRequest.php @@ -1,6 +1,7 @@ markRequired("CharacterId"); } - /** * ProjectId: 项目ID,请参考[GetProjectList接口](../summary/get_project_list.html)的描述。不填写为创建时间最早的项目。 @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * MemberEmail: 被加入成员Email * @@ -64,11 +64,10 @@ public function getMemberEmail() * * @param string $memberEmail */ - public function setMemberEmail($memberEmail) + public function setMemberEmail(string $memberEmail) { $this->set("MemberEmail", $memberEmail); } - /** * CharacterId: 被加入成员归属角色ID * @@ -84,7 +83,7 @@ public function getCharacterId() * * @param string $characterId */ - public function setCharacterId($characterId) + public function setCharacterId(string $characterId) { $this->set("CharacterId", $characterId); } diff --git a/src/UAccount/Apis/AddMemberToProjectResponse.php b/src/UAccount/Apis/AddMemberToProjectResponse.php index c8e49354..3273699a 100644 --- a/src/UAccount/Apis/AddMemberToProjectResponse.php +++ b/src/UAccount/Apis/AddMemberToProjectResponse.php @@ -1,6 +1,7 @@ markRequired("MemberEmail"); } - /** * MemberEmail: 需要被冻结的成员Email @@ -43,7 +44,7 @@ public function getMemberEmail() * * @param string $memberEmail */ - public function setMemberEmail($memberEmail) + public function setMemberEmail(string $memberEmail) { $this->set("MemberEmail", $memberEmail); } diff --git a/src/UAccount/Apis/FreezeMemberResponse.php b/src/UAccount/Apis/FreezeMemberResponse.php index 3d2ccd2f..7a24a6f1 100644 --- a/src/UAccount/Apis/FreezeMemberResponse.php +++ b/src/UAccount/Apis/FreezeMemberResponse.php @@ -1,6 +1,7 @@ get("Data")); + return new NetworkMaskModel($this->get("Data")); } /** * Data: 接口返回数据 * - * @param NetworkMask $data + * @param NetworkMaskModel $data */ - public function setData(array $data) + public function setData(NetworkMaskModel $data) { $this->set("Data", $data->getAll()); } diff --git a/src/UAccount/Apis/GetProjectListRequest.php b/src/UAccount/Apis/GetProjectListRequest.php index 89f638dc..213a0538 100644 --- a/src/UAccount/Apis/GetProjectListRequest.php +++ b/src/UAccount/Apis/GetProjectListRequest.php @@ -1,6 +1,7 @@ "GetProjectList"]); } - /** * IsFinance: 是否是财务账号(Yes:是,No:否) @@ -42,7 +43,7 @@ public function getIsFinance() * * @param string $isFinance */ - public function setIsFinance($isFinance) + public function setIsFinance(string $isFinance) { $this->set("IsFinance", $isFinance); } diff --git a/src/UAccount/Apis/GetProjectListResponse.php b/src/UAccount/Apis/GetProjectListResponse.php index 5a2e2cb2..c03c9fc6 100644 --- a/src/UAccount/Apis/GetProjectListResponse.php +++ b/src/UAccount/Apis/GetProjectListResponse.php @@ -1,6 +1,7 @@ set("ProjectCount", $projectCount); } - /** * ProjectSet: JSON格式的项目列表实例 * - * @return ProjectListInfo[]|null + * @return ProjectListInfoModel[]|null */ public function getProjectSet() { @@ -56,7 +57,7 @@ public function getProjectSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ProjectListInfo($item)); + array_push($result, new ProjectListInfoModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getProjectSet() /** * ProjectSet: JSON格式的项目列表实例 * - * @param ProjectListInfo[] $projectSet + * @param ProjectListInfoModel[] $projectSet */ public function setProjectSet(array $projectSet) { diff --git a/src/UAccount/Apis/GetRegionRequest.php b/src/UAccount/Apis/GetRegionRequest.php index f7dbab44..3de8dc1c 100644 --- a/src/UAccount/Apis/GetRegionRequest.php +++ b/src/UAccount/Apis/GetRegionRequest.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new RegionInfo($item)); + array_push($result, new RegionInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getRegions() /** * Regions: 各数据中心信息 * - * @param RegionInfo[] $regions + * @param RegionInfoModel[] $regions */ public function setRegions(array $regions) { diff --git a/src/UAccount/Apis/InviteSubaccountRequest.php b/src/UAccount/Apis/InviteSubaccountRequest.php index 30002308..6a6489d7 100644 --- a/src/UAccount/Apis/InviteSubaccountRequest.php +++ b/src/UAccount/Apis/InviteSubaccountRequest.php @@ -1,6 +1,7 @@ markRequired("IsFinance"); } - /** * UserEmail: 受邀成员邮箱地址,不得重复 @@ -46,11 +47,10 @@ public function getUserEmail() * * @param string $userEmail */ - public function setUserEmail($userEmail) + public function setUserEmail(string $userEmail) { $this->set("UserEmail", $userEmail); } - /** * UserPhone: 受邀成员手机号码 * @@ -66,11 +66,10 @@ public function getUserPhone() * * @param string $userPhone */ - public function setUserPhone($userPhone) + public function setUserPhone(string $userPhone) { $this->set("UserPhone", $userPhone); } - /** * UserName: 受邀成员姓名 * @@ -86,11 +85,10 @@ public function getUserName() * * @param string $userName */ - public function setUserName($userName) + public function setUserName(string $userName) { $this->set("UserName", $userName); } - /** * IsFinance: 是否有财务权限(true:是,false:否,默认为否) * @@ -106,7 +104,7 @@ public function getIsFinance() * * @param string $isFinance */ - public function setIsFinance($isFinance) + public function setIsFinance(string $isFinance) { $this->set("IsFinance", $isFinance); } diff --git a/src/UAccount/Apis/InviteSubaccountResponse.php b/src/UAccount/Apis/InviteSubaccountResponse.php index 77dc6ece..0cb0837c 100644 --- a/src/UAccount/Apis/InviteSubaccountResponse.php +++ b/src/UAccount/Apis/InviteSubaccountResponse.php @@ -1,6 +1,7 @@ markRequired("MemberEmail"); } - /** * ProjectId: 项目ID,请参考[GetProjectList接口](../summary/get_project_list.html)的描述。不填写为默认项目,子帐号必须填写。 @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * MemberEmail: 需要被移除成员Email * @@ -64,7 +64,7 @@ public function getMemberEmail() * * @param string $memberEmail */ - public function setMemberEmail($memberEmail) + public function setMemberEmail(string $memberEmail) { $this->set("MemberEmail", $memberEmail); } diff --git a/src/UAccount/Apis/RemoveMemberFromProjectResponse.php b/src/UAccount/Apis/RemoveMemberFromProjectResponse.php index e60471e6..9cbfeef9 100644 --- a/src/UAccount/Apis/RemoveMemberFromProjectResponse.php +++ b/src/UAccount/Apis/RemoveMemberFromProjectResponse.php @@ -1,6 +1,7 @@ markRequired("Code"); } - /** * Code: 短信验证码 @@ -43,11 +44,10 @@ public function getCode() * * @param string $code */ - public function setCode($code) + public function setCode(string $code) { $this->set("Code", $code); } - /** * APINetworkMask: API调用网络掩码,多个IP以英文逗号分隔。默认空字符串,不限制登录IP。 * @@ -63,11 +63,10 @@ public function getAPINetworkMask() * * @param string $apiNetworkMask */ - public function setAPINetworkMask($apiNetworkMask) + public function setAPINetworkMask(string $apiNetworkMask) { $this->set("APINetworkMask", $apiNetworkMask); } - /** * LoginNetworkMask: 登录网络掩码,多个IP以英文逗号分隔。默认空字符串,不限制登录IP。 * @@ -83,7 +82,7 @@ public function getLoginNetworkMask() * * @param string $loginNetworkMask */ - public function setLoginNetworkMask($loginNetworkMask) + public function setLoginNetworkMask(string $loginNetworkMask) { $this->set("LoginNetworkMask", $loginNetworkMask); } diff --git a/src/UAccount/Apis/SetNetworkMaskResponse.php b/src/UAccount/Apis/SetNetworkMaskResponse.php index 1bb7a8f4..93a7147d 100644 --- a/src/UAccount/Apis/SetNetworkMaskResponse.php +++ b/src/UAccount/Apis/SetNetworkMaskResponse.php @@ -1,6 +1,7 @@ set("APINetworkMask", $apiNetworkMask); } - /** * LoginNetworkMask: 登录网络掩码,默认空字符串,不限制登录IP,多个IP以英文逗号分隔。 * @@ -57,7 +59,7 @@ public function getLoginNetworkMask() * * @param string $loginNetworkMask */ - public function setLoginNetworkMask($loginNetworkMask) + public function setLoginNetworkMask(string $loginNetworkMask) { $this->set("LoginNetworkMask", $loginNetworkMask); } diff --git a/src/UAccount/Models/ProjectListInfo.php b/src/UAccount/Models/ProjectListInfo.php index 7a765238..1e098b30 100644 --- a/src/UAccount/Models/ProjectListInfo.php +++ b/src/UAccount/Models/ProjectListInfo.php @@ -1,6 +1,7 @@ set("ProjectId", $projectId); } - /** * ProjectName: 项目名称 * @@ -57,11 +59,10 @@ public function getProjectName() * * @param string $projectName */ - public function setProjectName($projectName) + public function setProjectName(string $projectName) { $this->set("ProjectName", $projectName); } - /** * CreateTime: 创建时间(Unix时间戳) * @@ -77,11 +78,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * IsDefault: 是否为默认项目 * @@ -97,11 +97,10 @@ public function getIsDefault() * * @param boolean $isDefault */ - public function setIsDefault($isDefault) + public function setIsDefault(bool $isDefault) { $this->set("IsDefault", $isDefault); } - /** * ResourceCount: 项目下资源数量(已废弃,不建议使用) * @@ -117,11 +116,10 @@ public function getResourceCount() * * @param int $resourceCount */ - public function setResourceCount($resourceCount) + public function setResourceCount(int $resourceCount) { $this->set("ResourceCount", $resourceCount); } - /** * MemberCount: 项目下成员数量 * @@ -137,11 +135,10 @@ public function getMemberCount() * * @param int $memberCount */ - public function setMemberCount($memberCount) + public function setMemberCount(int $memberCount) { $this->set("MemberCount", $memberCount); } - /** * ParentId: 父项目ID(已废弃) * @@ -157,11 +154,10 @@ public function getParentId() * * @param string $parentId */ - public function setParentId($parentId) + public function setParentId(string $parentId) { $this->set("ParentId", $parentId); } - /** * ParentName: 父项目名称(已废弃) * @@ -177,7 +173,7 @@ public function getParentName() * * @param string $parentName */ - public function setParentName($parentName) + public function setParentName(string $parentName) { $this->set("ParentName", $parentName); } diff --git a/src/UAccount/Models/RegionInfo.php b/src/UAccount/Models/RegionInfo.php index 49e0aad5..76aae571 100644 --- a/src/UAccount/Models/RegionInfo.php +++ b/src/UAccount/Models/RegionInfo.php @@ -1,6 +1,7 @@ set("RegionId", $regionId); } - /** * RegionName: 数据中心名称 * @@ -57,11 +59,10 @@ public function getRegionName() * * @param string $regionName */ - public function setRegionName($regionName) + public function setRegionName(string $regionName) { $this->set("RegionName", $regionName); } - /** * IsDefault: 是否用户当前默认数据中心 * @@ -77,11 +78,10 @@ public function getIsDefault() * * @param boolean $isDefault */ - public function setIsDefault($isDefault) + public function setIsDefault(bool $isDefault) { $this->set("IsDefault", $isDefault); } - /** * BitMaps: 用户在此数据中心的权限位 * @@ -97,11 +97,10 @@ public function getBitMaps() * * @param string $bitMaps */ - public function setBitMaps($bitMaps) + public function setBitMaps(string $bitMaps) { $this->set("BitMaps", $bitMaps); } - /** * Region: 地域名字,如cn-bj * @@ -117,11 +116,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区名字,如cn-bj-01 * @@ -137,7 +135,7 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } diff --git a/src/UAccount/UAccountClient.php b/src/UAccount/UAccountClient.php index f4760a30..d0ee4118 100644 --- a/src/UAccount/UAccountClient.php +++ b/src/UAccount/UAccountClient.php @@ -1,6 +1,7 @@ (string) 项目ID,请参考[GetProjectList接口](../summary/get_project_list.html)的描述。不填写为创建时间最早的项目。 - * "MemberEmail" => (string) 被加入成员Email - * "CharacterId" => (string) 被加入成员归属角色ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddMemberToProjectResponse * @throws UCloudException */ public function addMemberToProject(AddMemberToProjectRequest $request = null) @@ -67,24 +81,13 @@ public function addMemberToProject(AddMemberToProjectRequest $request = null) $resp = $this->invoke($request); return new AddMemberToProjectResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * FreezeMember - 冻结成员 * - * See also: https://docs.ucloud.cn/api/uaccount-api/freeze_member - * - * Arguments: - * - * $args = [ - * "MemberEmail" => (string) 需要被冻结的成员Email - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return FreezeMemberResponse * @throws UCloudException */ public function freezeMember(FreezeMemberRequest $request = null) @@ -92,27 +95,13 @@ public function freezeMember(FreezeMemberRequest $request = null) $resp = $this->invoke($request); return new FreezeMemberResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetNetworkMask - 查询登录与API调用的网络掩码 * - * See also: https://docs.ucloud.cn/api/uaccount-api/get_network_mask - * - * Arguments: - * - * $args = [ - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (object) 接口返回数据[ - * "APINetworkMask" => (string) API调用网络掩码,默认空字符串,不限制登录IP,多个IP以英文逗号分隔。 - * "LoginNetworkMask" => (string) 登录网络掩码,默认空字符串,不限制登录IP,多个IP以英文逗号分隔。 - * ] - * ] - * - * @return GetNetworkMaskResponse * @throws UCloudException */ public function getNetworkMask(GetNetworkMaskRequest $request = null) @@ -120,37 +109,13 @@ public function getNetworkMask(GetNetworkMaskRequest $request = null) $resp = $this->invoke($request); return new GetNetworkMaskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetProjectList - 获取项目列表 * - * See also: https://docs.ucloud.cn/api/uaccount-api/get_project_list - * - * Arguments: - * - * $args = [ - * "IsFinance" => (string) 是否是财务账号(Yes:是,No:否) - * ] - * - * Outputs: - * - * $outputs = [ - * "ProjectCount" => (integer) 项目总数 - * "ProjectSet" => (array) JSON格式的项目列表实例[ - * [ - * "ProjectId" => (string) 项目ID - * "ProjectName" => (string) 项目名称 - * "CreateTime" => (integer) 创建时间(Unix时间戳) - * "IsDefault" => (boolean) 是否为默认项目 - * "ResourceCount" => (integer) 项目下资源数量(已废弃,不建议使用) - * "MemberCount" => (integer) 项目下成员数量 - * "ParentId" => (string) 父项目ID(已废弃) - * "ParentName" => (string) 父项目名称(已废弃) - * ] - * ] - * ] - * - * @return GetProjectListResponse * @throws UCloudException */ public function getProjectList(GetProjectListRequest $request = null) @@ -158,33 +123,13 @@ public function getProjectList(GetProjectListRequest $request = null) $resp = $this->invoke($request); return new GetProjectListResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetRegion - 获取用户在各数据中心的权限等信息 * - * See also: https://docs.ucloud.cn/api/uaccount-api/get_region - * - * Arguments: - * - * $args = [ - * ] - * - * Outputs: - * - * $outputs = [ - * "Regions" => (array) 各数据中心信息[ - * [ - * "RegionId" => (integer) 数据中心ID - * "RegionName" => (string) 数据中心名称 - * "IsDefault" => (boolean) 是否用户当前默认数据中心 - * "BitMaps" => (string) 用户在此数据中心的权限位 - * "Region" => (string) 地域名字,如cn-bj - * "Zone" => (string) 可用区名字,如cn-bj-01 - * ] - * ] - * ] - * - * @return GetRegionResponse * @throws UCloudException */ public function getRegion(GetRegionRequest $request = null) @@ -192,27 +137,13 @@ public function getRegion(GetRegionRequest $request = null) $resp = $this->invoke($request); return new GetRegionResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * InviteSubaccount - 邀请子帐号成员 * - * See also: https://docs.ucloud.cn/api/uaccount-api/invite_subaccount - * - * Arguments: - * - * $args = [ - * "UserEmail" => (string) 受邀成员邮箱地址,不得重复 - * "UserPhone" => (string) 受邀成员手机号码 - * "UserName" => (string) 受邀成员姓名 - * "IsFinance" => (string) 是否有财务权限(true:是,false:否,默认为否) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return InviteSubaccountResponse * @throws UCloudException */ public function inviteSubaccount(InviteSubaccountRequest $request = null) @@ -220,25 +151,13 @@ public function inviteSubaccount(InviteSubaccountRequest $request = null) $resp = $this->invoke($request); return new InviteSubaccountResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RemoveMemberFromProject - 从项目中移除成员 * - * See also: https://docs.ucloud.cn/api/uaccount-api/remove_member_from_project - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,请参考[GetProjectList接口](../summary/get_project_list.html)的描述。不填写为默认项目,子帐号必须填写。 - * "MemberEmail" => (string) 需要被移除成员Email - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RemoveMemberFromProjectResponse * @throws UCloudException */ public function removeMemberFromProject(RemoveMemberFromProjectRequest $request = null) @@ -246,26 +165,13 @@ public function removeMemberFromProject(RemoveMemberFromProjectRequest $request $resp = $this->invoke($request); return new RemoveMemberFromProjectResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SetNetworkMask - 设置登录与API调用的网络掩码 * - * See also: https://docs.ucloud.cn/api/uaccount-api/set_network_mask - * - * Arguments: - * - * $args = [ - * "Code" => (string) 短信验证码 - * "APINetworkMask" => (string) API调用网络掩码,多个IP以英文逗号分隔。默认空字符串,不限制登录IP。 - * "LoginNetworkMask" => (string) 登录网络掩码,多个IP以英文逗号分隔。默认空字符串,不限制登录IP。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetNetworkMaskResponse * @throws UCloudException */ public function setNetworkMask(SetNetworkMaskRequest $request = null) diff --git a/src/UBill/Apis/GetBalanceRequest.php b/src/UBill/Apis/GetBalanceRequest.php index 0cee16bf..6a10c04a 100644 --- a/src/UBill/Apis/GetBalanceRequest.php +++ b/src/UBill/Apis/GetBalanceRequest.php @@ -1,6 +1,7 @@ get("AccountInfo")); + return new AccountInfoModel($this->get("AccountInfo")); } /** * AccountInfo: 账户余额信息 * - * @param AccountInfo $accountInfo + * @param AccountInfoModel $accountInfo */ - public function setAccountInfo(array $accountInfo) + public function setAccountInfo(AccountInfoModel $accountInfo) { $this->set("AccountInfo", $accountInfo->getAll()); } diff --git a/src/UBill/Apis/GetBillDataFileUrlRequest.php b/src/UBill/Apis/GetBillDataFileUrlRequest.php index bb88f608..2467452b 100644 --- a/src/UBill/Apis/GetBillDataFileUrlRequest.php +++ b/src/UBill/Apis/GetBillDataFileUrlRequest.php @@ -1,6 +1,7 @@ "GetBillDataFileUrl"]); - $this->markRequired("BillPeriod"); $this->markRequired("BillType"); + $this->markRequired("BillingCycle"); } - /** - * BillPeriod: 账期(时间戳格式) + * BillType: 账单类型,传 0 时获取账单总览报表,传 1 获取账单明细报表 * * @return integer|null */ - public function getBillPeriod() + public function getBillType() { - return $this->get("BillPeriod"); + return $this->get("BillType"); } /** - * BillPeriod: 账期(时间戳格式) + * BillType: 账单类型,传 0 时获取账单总览报表,传 1 获取账单明细报表 * - * @param int $billPeriod + * @param int $billType */ - public function setBillPeriod($billPeriod) + public function setBillType(int $billType) { - $this->set("BillPeriod", $billPeriod); + $this->set("BillType", $billType); + } + /** + * BillingCycle: 账期(字符串格式,YYYY-MM,例如2021-08). 若BillingCycle 和 BillPeriod同时存在,BillingCycle 优先 + * + * @return string|null + */ + public function getBillingCycle() + { + return $this->get("BillingCycle"); } /** - * BillType: 账单类型,传 0 时获取账单总览报表,传 1 获取账单明细报表 + * BillingCycle: 账期(字符串格式,YYYY-MM,例如2021-08). 若BillingCycle 和 BillPeriod同时存在,BillingCycle 优先 + * + * @param string $billingCycle + */ + public function setBillingCycle(string $billingCycle) + { + $this->set("BillingCycle", $billingCycle); + } + /** + * BillPeriod: 此字段不推荐使用,建议使用BillingCycle. 若BillingCycle 和 BillPeriod同时存在,BillingCycle 优先 * * @return integer|null */ - public function getBillType() + public function getBillPeriod() { - return $this->get("BillType"); + return $this->get("BillPeriod"); } /** - * BillType: 账单类型,传 0 时获取账单总览报表,传 1 获取账单明细报表 + * BillPeriod: 此字段不推荐使用,建议使用BillingCycle. 若BillingCycle 和 BillPeriod同时存在,BillingCycle 优先 * - * @param int $billType + * @param int $billPeriod */ - public function setBillType($billType) + public function setBillPeriod(int $billPeriod) { - $this->set("BillType", $billType); + $this->set("BillPeriod", $billPeriod); } - /** * PaidType: 获取账单总览报表时,账单的支付状态,传 0 时获取待支付账单,传 1 时获取已支付账单。获取账单明细报表时该参数无效 * @@ -84,11 +102,10 @@ public function getPaidType() * * @param int $paidType */ - public function setPaidType($paidType) + public function setPaidType(int $paidType) { $this->set("PaidType", $paidType); } - /** * RequireVersion: 如需求其他语言版本的账单则使用此参数。默认中文。如 RequireVersion = "EN",则提供英文版本账单。 * @@ -104,8 +121,27 @@ public function getRequireVersion() * * @param string $requireVersion */ - public function setRequireVersion($requireVersion) + public function setRequireVersion(string $requireVersion) { $this->set("RequireVersion", $requireVersion); } + /** + * Version: 文件版本,若为"v1"表示获取带有子用户信息的账单,可以为空 + * + * @return string|null + */ + public function getVersion() + { + return $this->get("Version"); + } + + /** + * Version: 文件版本,若为"v1"表示获取带有子用户信息的账单,可以为空 + * + * @param string $version + */ + public function setVersion(string $version) + { + $this->set("Version", $version); + } } diff --git a/src/UBill/Apis/GetBillDataFileUrlResponse.php b/src/UBill/Apis/GetBillDataFileUrlResponse.php index 4abc9f33..fc9ca9e2 100644 --- a/src/UBill/Apis/GetBillDataFileUrlResponse.php +++ b/src/UBill/Apis/GetBillDataFileUrlResponse.php @@ -1,6 +1,7 @@ set("FileUrl", $fileUrl); } - /** * IsValid: 生成的 URL是否有效,即有对应数据文件 * @@ -57,7 +57,7 @@ public function getIsValid() * * @param string $isValid */ - public function setIsValid($isValid) + public function setIsValid(string $isValid) { $this->set("IsValid", $isValid); } diff --git a/src/UBill/Apis/ListUBillDetailRequest.php b/src/UBill/Apis/ListUBillDetailRequest.php new file mode 100644 index 00000000..01be34ce --- /dev/null +++ b/src/UBill/Apis/ListUBillDetailRequest.php @@ -0,0 +1,241 @@ + "ListUBillDetail"]); + $this->markRequired("BillingCycle"); + } + + + /** + * BillingCycle: 账期,YYYY-MM,比如2021-08,只支持2018-05之后的查询 + * + * @return string|null + */ + public function getBillingCycle() + { + return $this->get("BillingCycle"); + } + + /** + * BillingCycle: 账期,YYYY-MM,比如2021-08,只支持2018-05之后的查询 + * + * @param string $billingCycle + */ + public function setBillingCycle(string $billingCycle) + { + $this->set("BillingCycle", $billingCycle); + } + /** + * ProjectName: 项目名称 (筛选项, 默认全部) + * + * @return string|null + */ + public function getProjectName() + { + return $this->get("ProjectName"); + } + + /** + * ProjectName: 项目名称 (筛选项, 默认全部) + * + * @param string $projectName + */ + public function setProjectName(string $projectName) + { + $this->set("ProjectName", $projectName); + } + /** + * ResourceIds: 资源ID(筛选项, 默认全部) 支持多筛选,多筛选请在请求参数中添加多个字段例ResourceIds.0: uhost-bzgf1gh5,ResourceIds.1: uhost-gu1xpspa, + * + * @return string[]|null + */ + public function getResourceIds() + { + return $this->get("ResourceIds"); + } + + /** + * ResourceIds: 资源ID(筛选项, 默认全部) 支持多筛选,多筛选请在请求参数中添加多个字段例ResourceIds.0: uhost-bzgf1gh5,ResourceIds.1: uhost-gu1xpspa, + * + * @param string[] $resourceIds + */ + public function setResourceIds(array $resourceIds) + { + $this->set("ResourceIds", $resourceIds); + } + /** + * OrderType: 订单类型 (筛选项, 默认全部) 。枚举值:\\ > OT_BUY:新购 \\ > OT_RENEW:续费 \\ > OT_UPGRADE:升级 \\ > OT_REFUND:退费 \\ > OT_DOWNGRADE:降级 \\ > OT_SUSPEND:结算 \\ > OT_PAYMENT:删除资源回款 \\ > OT_POSTPAID_PAYMENT:后付费回款 \\ > OT_RECOVER:删除恢复 \\ > OT_POSTPAID_RENEW:过期续费回款 + * + * @return string|null + */ + public function getOrderType() + { + return $this->get("OrderType"); + } + + /** + * OrderType: 订单类型 (筛选项, 默认全部) 。枚举值:\\ > OT_BUY:新购 \\ > OT_RENEW:续费 \\ > OT_UPGRADE:升级 \\ > OT_REFUND:退费 \\ > OT_DOWNGRADE:降级 \\ > OT_SUSPEND:结算 \\ > OT_PAYMENT:删除资源回款 \\ > OT_POSTPAID_PAYMENT:后付费回款 \\ > OT_RECOVER:删除恢复 \\ > OT_POSTPAID_RENEW:过期续费回款 + * + * @param string $orderType + */ + public function setOrderType(string $orderType) + { + $this->set("OrderType", $orderType); + } + /** + * ChargeType: 计费方式 (筛选项, 默认全部)。枚举值:\\ > Dynamic:按时 \\ > Month:按月 \\ > Year:按年 \\ > Once:一次性按量 \\ > Used:按量 \\ > Post:后付费 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费方式 (筛选项, 默认全部)。枚举值:\\ > Dynamic:按时 \\ > Month:按月 \\ > Year:按年 \\ > Once:一次性按量 \\ > Used:按量 \\ > Post:后付费 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * ShowZero: 是否显示0元订单 (0 不显示, 1 显示, 默认0) + * + * @return integer|null + */ + public function getShowZero() + { + return $this->get("ShowZero"); + } + + /** + * ShowZero: 是否显示0元订单 (0 不显示, 1 显示, 默认0) + * + * @param int $showZero + */ + public function setShowZero(int $showZero) + { + $this->set("ShowZero", $showZero); + } + /** + * PaidState: 支付状态 (筛选项, 1:仅显示未支付订单; 2:仅显示已支付订单; 0:两者都显示) + * + * @return integer|null + */ + public function getPaidState() + { + return $this->get("PaidState"); + } + + /** + * PaidState: 支付状态 (筛选项, 1:仅显示未支付订单; 2:仅显示已支付订单; 0:两者都显示) + * + * @param int $paidState + */ + public function setPaidState(int $paidState) + { + $this->set("PaidState", $paidState); + } + /** + * UserEmail: 用户邮箱,可以根据用户邮箱来进行筛选 + * + * @return string|null + */ + public function getUserEmail() + { + return $this->get("UserEmail"); + } + + /** + * UserEmail: 用户邮箱,可以根据用户邮箱来进行筛选 + * + * @param string $userEmail + */ + public function setUserEmail(string $userEmail) + { + $this->set("UserEmail", $userEmail); + } + /** + * Limit: 每页数量,默认值25,最大值:100。 + * + * @return integer|null + */ + public function getLimit() + { + return $this->get("Limit"); + } + + /** + * Limit: 每页数量,默认值25,最大值:100。 + * + * @param int $limit + */ + public function setLimit(int $limit) + { + $this->set("Limit", $limit); + } + /** + * Offset: 数据偏移量 (默认0) + * + * @return integer|null + */ + public function getOffset() + { + return $this->get("Offset"); + } + + /** + * Offset: 数据偏移量 (默认0) + * + * @param int $offset + */ + public function setOffset(int $offset) + { + $this->set("Offset", $offset); + } + /** + * ResourceTypes: 产品类型 (筛选项, 默认全部),支持多筛选,多筛选请在请求参数中添加多个字段。枚举值:\\ > uhost:云主机 \\ > udisk:普通云硬盘 \\ > udb:云数据库 \\ > eip:弹性IP \\ > ufile:对象存储 \\ > fortress_host:堡垒机 \\ > ufs:文件存储 \\ > waf:WEB应用防火墙 \\ > ues:弹性搜索 \\ > udisk_ssd:SSD云硬盘 \\ > rssd:RSSD云硬盘 + * + * @return string[]|null + */ + public function getResourceTypes() + { + return $this->get("ResourceTypes"); + } + + /** + * ResourceTypes: 产品类型 (筛选项, 默认全部),支持多筛选,多筛选请在请求参数中添加多个字段。枚举值:\\ > uhost:云主机 \\ > udisk:普通云硬盘 \\ > udb:云数据库 \\ > eip:弹性IP \\ > ufile:对象存储 \\ > fortress_host:堡垒机 \\ > ufs:文件存储 \\ > waf:WEB应用防火墙 \\ > ues:弹性搜索 \\ > udisk_ssd:SSD云硬盘 \\ > rssd:RSSD云硬盘 + * + * @param string[] $resourceTypes + */ + public function setResourceTypes(array $resourceTypes) + { + $this->set("ResourceTypes", $resourceTypes); + } +} diff --git a/src/UCDN/Apis/GetNewUcdnDomainBandwidthResponse.php b/src/UBill/Apis/ListUBillDetailResponse.php similarity index 50% rename from src/UCDN/Apis/GetNewUcdnDomainBandwidthResponse.php rename to src/UBill/Apis/ListUBillDetailResponse.php index 2356641f..e5e5998a 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainBandwidthResponse.php +++ b/src/UBill/Apis/ListUBillDetailResponse.php @@ -1,6 +1,7 @@ get("BandwidthList"); + $items = $this->get("Items"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new BandwidthInfo($item)); + array_push($result, new BillDetailItemModel($item)); } return $result; } /** - * BandwidthList: 带宽信息列表,参见BandwidthInfo + * Items: 账单明细数组 * - * @param BandwidthInfo[] $bandwidthList + * @param BillDetailItemModel[] $items */ - public function setBandwidthList(array $bandwidthList) + public function setItems(array $items) { $result = []; - foreach ($bandwidthList as $i => $item) { + foreach ($items as $i => $item) { array_push($result, $item->getAll()); } return $result; } - /** - * Traffic: 从起始时间到结束时间内的所使用的CDN总流量,单位GB + * TotalCount: 账单明细总长度 * - * @return float|null + * @return integer|null */ - public function getTraffic() + public function getTotalCount() { - return $this->get("Traffic"); + return $this->get("TotalCount"); } /** - * Traffic: 从起始时间到结束时间内的所使用的CDN总流量,单位GB + * TotalCount: 账单明细总长度 * - * @param float $traffic + * @param int $totalCount */ - public function setTraffic($traffic) + public function setTotalCount(int $totalCount) { - $this->set("Traffic", $traffic); + $this->set("TotalCount", $totalCount); } } diff --git a/src/UBill/Apis/ListUBillOverviewRequest.php b/src/UBill/Apis/ListUBillOverviewRequest.php new file mode 100644 index 00000000..3da6931b --- /dev/null +++ b/src/UBill/Apis/ListUBillOverviewRequest.php @@ -0,0 +1,90 @@ + "ListUBillOverview"]); + $this->markRequired("BillingCycle"); + $this->markRequired("Dimension"); + } + + + /** + * BillingCycle: 账期,YYYY-MM格式,例如2022-02,只支持2018-05之后的查询 + * + * @return string|null + */ + public function getBillingCycle() + { + return $this->get("BillingCycle"); + } + + /** + * BillingCycle: 账期,YYYY-MM格式,例如2022-02,只支持2018-05之后的查询 + * + * @param string $billingCycle + */ + public function setBillingCycle(string $billingCycle) + { + $this->set("BillingCycle", $billingCycle); + } + /** + * Dimension: 账单维度, product 按产品聚合,project 按项目聚合,user 按子账号聚合 + * + * @return string|null + */ + public function getDimension() + { + return $this->get("Dimension"); + } + + /** + * Dimension: 账单维度, product 按产品聚合,project 按项目聚合,user 按子账号聚合 + * + * @param string $dimension + */ + public function setDimension(string $dimension) + { + $this->set("Dimension", $dimension); + } + /** + * HideUnpaid: 是否显示已入账账单, 1 已入账, 0 待入账 (默认0 ) + * + * @return integer|null + */ + public function getHideUnpaid() + { + return $this->get("HideUnpaid"); + } + + /** + * HideUnpaid: 是否显示已入账账单, 1 已入账, 0 待入账 (默认0 ) + * + * @param int $hideUnpaid + */ + public function setHideUnpaid(int $hideUnpaid) + { + $this->set("HideUnpaid", $hideUnpaid); + } +} diff --git a/src/UBill/Apis/ListUBillOverviewResponse.php b/src/UBill/Apis/ListUBillOverviewResponse.php new file mode 100644 index 00000000..cc4ca6e4 --- /dev/null +++ b/src/UBill/Apis/ListUBillOverviewResponse.php @@ -0,0 +1,135 @@ +get("TotalCount"); + } + + /** + * TotalCount: 账单总览数据总数 + * + * @param int $totalCount + */ + public function setTotalCount(int $totalCount) + { + $this->set("TotalCount", $totalCount); + } + /** + * TotalPaidAmount: 已入账订单总额(已入账时显示) + * + * @return string|null + */ + public function getTotalPaidAmount() + { + return $this->get("TotalPaidAmount"); + } + + /** + * TotalPaidAmount: 已入账订单总额(已入账时显示) + * + * @param string $totalPaidAmount + */ + public function setTotalPaidAmount(string $totalPaidAmount) + { + $this->set("TotalPaidAmount", $totalPaidAmount); + } + /** + * TotalPaidAmountReal: 现金账户扣款总额 (已入账时显示) + * + * @return string|null + */ + public function getTotalPaidAmountReal() + { + return $this->get("TotalPaidAmountReal"); + } + + /** + * TotalPaidAmountReal: 现金账户扣款总额 (已入账时显示) + * + * @param string $totalPaidAmountReal + */ + public function setTotalPaidAmountReal(string $totalPaidAmountReal) + { + $this->set("TotalPaidAmountReal", $totalPaidAmountReal); + } + /** + * TotalUnpaidAmount: 待入账订单总额(待入账时显示) + * + * @return string|null + */ + public function getTotalUnpaidAmount() + { + return $this->get("TotalUnpaidAmount"); + } + + /** + * TotalUnpaidAmount: 待入账订单总额(待入账时显示) + * + * @param string $totalUnpaidAmount + */ + public function setTotalUnpaidAmount(string $totalUnpaidAmount) + { + $this->set("TotalUnpaidAmount", $totalUnpaidAmount); + } + /** + * Items: 账单聚合数据 + * + * @return BillOverviewItemModel[]|null + */ + public function getItems() + { + $items = $this->get("Items"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new BillOverviewItemModel($item)); + } + return $result; + } + + /** + * Items: 账单聚合数据 + * + * @param BillOverviewItemModel[] $items + */ + public function setItems(array $items) + { + $result = []; + foreach ($items as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UBill/Models/AccountInfo.php b/src/UBill/Models/AccountInfo.php index 20729ede..8cb3f573 100644 --- a/src/UBill/Models/AccountInfo.php +++ b/src/UBill/Models/AccountInfo.php @@ -1,6 +1,7 @@ set("AmountFreeze", $amountFreeze); } - /** * AmountCredit: 信用账户余额 * @@ -57,11 +59,10 @@ public function getAmountCredit() * * @param string $amountCredit */ - public function setAmountCredit($amountCredit) + public function setAmountCredit(string $amountCredit) { $this->set("AmountCredit", $amountCredit); } - /** * AmountFree: 赠送账户余额 * @@ -77,11 +78,10 @@ public function getAmountFree() * * @param string $amountFree */ - public function setAmountFree($amountFree) + public function setAmountFree(string $amountFree) { $this->set("AmountFree", $amountFree); } - /** * Amount: 账户余额 * @@ -97,11 +97,10 @@ public function getAmount() * * @param string $amount */ - public function setAmount($amount) + public function setAmount(string $amount) { $this->set("Amount", $amount); } - /** * AmountAvailable: 账户可用余额 * @@ -117,7 +116,7 @@ public function getAmountAvailable() * * @param string $amountAvailable */ - public function setAmountAvailable($amountAvailable) + public function setAmountAvailable(string $amountAvailable) { $this->set("AmountAvailable", $amountAvailable); } diff --git a/src/UBill/Models/BillDetailItem.php b/src/UBill/Models/BillDetailItem.php new file mode 100644 index 00000000..b63c37aa --- /dev/null +++ b/src/UBill/Models/BillDetailItem.php @@ -0,0 +1,453 @@ +get("Amount"); + } + + /** + * Amount: 订单总金额 + * + * @param string $amount + */ + public function setAmount(string $amount) + { + $this->set("Amount", $amount); + } + /** + * AmountReal: 现金账户支付 + * + * @return string|null + */ + public function getAmountReal() + { + return $this->get("AmountReal"); + } + + /** + * AmountReal: 现金账户支付 + * + * @param string $amountReal + */ + public function setAmountReal(string $amountReal) + { + $this->set("AmountReal", $amountReal); + } + /** + * AmountFree: 赠送金额抵扣 + * + * @return string|null + */ + public function getAmountFree() + { + return $this->get("AmountFree"); + } + + /** + * AmountFree: 赠送金额抵扣 + * + * @param string $amountFree + */ + public function setAmountFree(string $amountFree) + { + $this->set("AmountFree", $amountFree); + } + /** + * AmountCoupon: 代金券抵扣 + * + * @return string|null + */ + public function getAmountCoupon() + { + return $this->get("AmountCoupon"); + } + + /** + * AmountCoupon: 代金券抵扣 + * + * @param string $amountCoupon + */ + public function setAmountCoupon(string $amountCoupon) + { + $this->set("AmountCoupon", $amountCoupon); + } + /** + * AzGroupCName: 可用区 + * + * @return string|null + */ + public function getAzGroupCName() + { + return $this->get("AzGroupCName"); + } + + /** + * AzGroupCName: 可用区 + * + * @param string $azGroupCName + */ + public function setAzGroupCName(string $azGroupCName) + { + $this->set("AzGroupCName", $azGroupCName); + } + /** + * ChargeType: 计费方式 (筛选项, 默认全部)。枚举值:\\ > Dynamic:按时 \\ > Month:按月 \\ > Year:按年 \\ > Once:一次性按量 \\ > Used:按量 \\ > Post:后付费 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费方式 (筛选项, 默认全部)。枚举值:\\ > Dynamic:按时 \\ > Month:按月 \\ > Year:按年 \\ > Once:一次性按量 \\ > Used:按量 \\ > Post:后付费 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * CreateTime: 创建时间(时间戳) + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间(时间戳) + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * StartTime: 开始时间(时间戳) + * + * @return integer|null + */ + public function getStartTime() + { + return $this->get("StartTime"); + } + + /** + * StartTime: 开始时间(时间戳) + * + * @param int $startTime + */ + public function setStartTime(int $startTime) + { + $this->set("StartTime", $startTime); + } + /** + * OrderNo: 订单号 + * + * @return string|null + */ + public function getOrderNo() + { + return $this->get("OrderNo"); + } + + /** + * OrderNo: 订单号 + * + * @param string $orderNo + */ + public function setOrderNo(string $orderNo) + { + $this->set("OrderNo", $orderNo); + } + /** + * OrderType: 订单类型 (筛选项, 默认全部) 。枚举值:\\ > OT_BUY:新购 \\ > OT_RENEW:续费 \\ > OT_UPGRADE:升级 \\ > OT_REFUND:退费 \\ > OT_DOWNGRADE:降级 \\ > OT_SUSPEND:结算 \\ > OT_PAYMENT:删除资源回款 \\ > OT_POSTPAID_PAYMENT:后付费回款 \\ > OT_RECOVER:删除恢复 \\ > OT_POSTPAID_RENEW:过期续费回款 + * + * @return string|null + */ + public function getOrderType() + { + return $this->get("OrderType"); + } + + /** + * OrderType: 订单类型 (筛选项, 默认全部) 。枚举值:\\ > OT_BUY:新购 \\ > OT_RENEW:续费 \\ > OT_UPGRADE:升级 \\ > OT_REFUND:退费 \\ > OT_DOWNGRADE:降级 \\ > OT_SUSPEND:结算 \\ > OT_PAYMENT:删除资源回款 \\ > OT_POSTPAID_PAYMENT:后付费回款 \\ > OT_RECOVER:删除恢复 \\ > OT_POSTPAID_RENEW:过期续费回款 + * + * @param string $orderType + */ + public function setOrderType(string $orderType) + { + $this->set("OrderType", $orderType); + } + /** + * ProjectName: 项目名称 + * + * @return string|null + */ + public function getProjectName() + { + return $this->get("ProjectName"); + } + + /** + * ProjectName: 项目名称 + * + * @param string $projectName + */ + public function setProjectName(string $projectName) + { + $this->set("ProjectName", $projectName); + } + /** + * ResourceId: 资源ID + * + * @return string|null + */ + public function getResourceId() + { + return $this->get("ResourceId"); + } + + /** + * ResourceId: 资源ID + * + * @param string $resourceId + */ + public function setResourceId(string $resourceId) + { + $this->set("ResourceId", $resourceId); + } + /** + * ResourceType: 产品类型。枚举值:\\ > uhost:云主机 \\ > udisk:普通云硬盘 \\ > udb:云数据库 \\ > eip:弹性IP \\ > ufile:对象存储 \\ > fortress_host:堡垒机 \\ > ufs:文件存储 \\ > waf:WEB应用防火墙 \\ > ues:弹性搜索 \\ > udisk_ssd:SSD云硬盘 \\ > rssd:RSSD云硬盘 + * + * @return string|null + */ + public function getResourceType() + { + return $this->get("ResourceType"); + } + + /** + * ResourceType: 产品类型。枚举值:\\ > uhost:云主机 \\ > udisk:普通云硬盘 \\ > udb:云数据库 \\ > eip:弹性IP \\ > ufile:对象存储 \\ > fortress_host:堡垒机 \\ > ufs:文件存储 \\ > waf:WEB应用防火墙 \\ > ues:弹性搜索 \\ > udisk_ssd:SSD云硬盘 \\ > rssd:RSSD云硬盘 + * + * @param string $resourceType + */ + public function setResourceType(string $resourceType) + { + $this->set("ResourceType", $resourceType); + } + /** + * ResourceTypeCode: 产品类型代码 + * + * @return integer|null + */ + public function getResourceTypeCode() + { + return $this->get("ResourceTypeCode"); + } + + /** + * ResourceTypeCode: 产品类型代码 + * + * @param int $resourceTypeCode + */ + public function setResourceTypeCode(int $resourceTypeCode) + { + $this->set("ResourceTypeCode", $resourceTypeCode); + } + /** + * ItemDetails: 产品配置 + * + * @return ItemDetailModel[]|null + */ + public function getItemDetails() + { + $items = $this->get("ItemDetails"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new ItemDetailModel($item)); + } + return $result; + } + + /** + * ItemDetails: 产品配置 + * + * @param ItemDetailModel[] $itemDetails + */ + public function setItemDetails(array $itemDetails) + { + $result = []; + foreach ($itemDetails as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * ResourceExtendInfo: 资源标识 + * + * @return ResourceExtendInfoModel[]|null + */ + public function getResourceExtendInfo() + { + $items = $this->get("ResourceExtendInfo"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new ResourceExtendInfoModel($item)); + } + return $result; + } + + /** + * ResourceExtendInfo: 资源标识 + * + * @param ResourceExtendInfoModel[] $resourceExtendInfo + */ + public function setResourceExtendInfo(array $resourceExtendInfo) + { + $result = []; + foreach ($resourceExtendInfo as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * ShowHover: 订单支付状态。枚举值:\\> 0:未支付 \\ > 1:已支付 + * + * @return integer|null + */ + public function getShowHover() + { + return $this->get("ShowHover"); + } + + /** + * ShowHover: 订单支付状态。枚举值:\\> 0:未支付 \\ > 1:已支付 + * + * @param int $showHover + */ + public function setShowHover(int $showHover) + { + $this->set("ShowHover", $showHover); + } + /** + * UserEmail: 账户邮箱 + * + * @return string|null + */ + public function getUserEmail() + { + return $this->get("UserEmail"); + } + + /** + * UserEmail: 账户邮箱 + * + * @param string $userEmail + */ + public function setUserEmail(string $userEmail) + { + $this->set("UserEmail", $userEmail); + } + /** + * UserName: 账户名 + * + * @return string|null + */ + public function getUserName() + { + return $this->get("UserName"); + } + + /** + * UserName: 账户名 + * + * @param string $userName + */ + public function setUserName(string $userName) + { + $this->set("UserName", $userName); + } + /** + * UserDisplayName: 账户昵称 + * + * @return string|null + */ + public function getUserDisplayName() + { + return $this->get("UserDisplayName"); + } + + /** + * UserDisplayName: 账户昵称 + * + * @param string $userDisplayName + */ + public function setUserDisplayName(string $userDisplayName) + { + $this->set("UserDisplayName", $userDisplayName); + } + /** + * Admin: 是否为主账号。枚举值:\\ > 0:子账号 \\ > 1:主账号 + * + * @return integer|null + */ + public function getAdmin() + { + return $this->get("Admin"); + } + + /** + * Admin: 是否为主账号。枚举值:\\ > 0:子账号 \\ > 1:主账号 + * + * @param int $admin + */ + public function setAdmin(int $admin) + { + $this->set("Admin", $admin); + } +} diff --git a/src/UBill/Models/BillOverviewItem.php b/src/UBill/Models/BillOverviewItem.php new file mode 100644 index 00000000..739c425a --- /dev/null +++ b/src/UBill/Models/BillOverviewItem.php @@ -0,0 +1,275 @@ +get("Dimension"); + } + + /** + * Dimension: 账单维度, product 按产品维度聚合,project 按项目维度聚合,user 按子账号维度聚合 + * + * @param string $dimension + */ + public function setDimension(string $dimension) + { + $this->set("Dimension", $dimension); + } + /** + * Amount: 订单总金额 + * + * @return string|null + */ + public function getAmount() + { + return $this->get("Amount"); + } + + /** + * Amount: 订单总金额 + * + * @param string $amount + */ + public function setAmount(string $amount) + { + $this->set("Amount", $amount); + } + /** + * AmountCoupon: 代金券抵扣(已入账时显示) + * + * @return string|null + */ + public function getAmountCoupon() + { + return $this->get("AmountCoupon"); + } + + /** + * AmountCoupon: 代金券抵扣(已入账时显示) + * + * @param string $amountCoupon + */ + public function setAmountCoupon(string $amountCoupon) + { + $this->set("AmountCoupon", $amountCoupon); + } + /** + * AmountFree: 赠送金额抵扣(已入账时显示) + * + * @return string|null + */ + public function getAmountFree() + { + return $this->get("AmountFree"); + } + + /** + * AmountFree: 赠送金额抵扣(已入账时显示) + * + * @param string $amountFree + */ + public function setAmountFree(string $amountFree) + { + $this->set("AmountFree", $amountFree); + } + /** + * AmountReal: 现金账户支付(已入账时显示) + * + * @return string|null + */ + public function getAmountReal() + { + return $this->get("AmountReal"); + } + + /** + * AmountReal: 现金账户支付(已入账时显示) + * + * @param string $amountReal + */ + public function setAmountReal(string $amountReal) + { + $this->set("AmountReal", $amountReal); + } + /** + * ProductCategory: 产品分类 (账单维度按产品筛选时显示) + * + * @return string|null + */ + public function getProductCategory() + { + return $this->get("ProductCategory"); + } + + /** + * ProductCategory: 产品分类 (账单维度按产品筛选时显示) + * + * @param string $productCategory + */ + public function setProductCategory(string $productCategory) + { + $this->set("ProductCategory", $productCategory); + } + /** + * ResourceType: 产品类型 (账单维度按产品筛选时显示) + * + * @return string|null + */ + public function getResourceType() + { + return $this->get("ResourceType"); + } + + /** + * ResourceType: 产品类型 (账单维度按产品筛选时显示) + * + * @param string $resourceType + */ + public function setResourceType(string $resourceType) + { + $this->set("ResourceType", $resourceType); + } + /** + * ResourceTypeCode: 产品类型代码(账单维度按产品筛选时显示) + * + * @return integer|null + */ + public function getResourceTypeCode() + { + return $this->get("ResourceTypeCode"); + } + + /** + * ResourceTypeCode: 产品类型代码(账单维度按产品筛选时显示) + * + * @param int $resourceTypeCode + */ + public function setResourceTypeCode(int $resourceTypeCode) + { + $this->set("ResourceTypeCode", $resourceTypeCode); + } + /** + * ProjectName: 项目名称(账单维度按项目筛选时显示) + * + * @return string|null + */ + public function getProjectName() + { + return $this->get("ProjectName"); + } + + /** + * ProjectName: 项目名称(账单维度按项目筛选时显示) + * + * @param string $projectName + */ + public function setProjectName(string $projectName) + { + $this->set("ProjectName", $projectName); + } + /** + * UserEmail: 账户邮箱(账单维度按子账号筛选时显示) + * + * @return string|null + */ + public function getUserEmail() + { + return $this->get("UserEmail"); + } + + /** + * UserEmail: 账户邮箱(账单维度按子账号筛选时显示) + * + * @param string $userEmail + */ + public function setUserEmail(string $userEmail) + { + $this->set("UserEmail", $userEmail); + } + /** + * UserName: 账户名 (账单维度按子账号筛选时显示) + * + * @return string|null + */ + public function getUserName() + { + return $this->get("UserName"); + } + + /** + * UserName: 账户名 (账单维度按子账号筛选时显示) + * + * @param string $userName + */ + public function setUserName(string $userName) + { + $this->set("UserName", $userName); + } + /** + * UserDisplayName: 账户昵称(账单维度按子账号筛选时显示) + * + * @return string|null + */ + public function getUserDisplayName() + { + return $this->get("UserDisplayName"); + } + + /** + * UserDisplayName: 账户昵称(账单维度按子账号筛选时显示) + * + * @param string $userDisplayName + */ + public function setUserDisplayName(string $userDisplayName) + { + $this->set("UserDisplayName", $userDisplayName); + } + /** + * Admin: 该账户是否为主账号,1 主账号,0 子账号(账单维度按子账号筛选时显示) + * + * @return integer|null + */ + public function getAdmin() + { + return $this->get("Admin"); + } + + /** + * Admin: 该账户是否为主账号,1 主账号,0 子账号(账单维度按子账号筛选时显示) + * + * @param int $admin + */ + public function setAdmin(int $admin) + { + $this->set("Admin", $admin); + } +} diff --git a/src/UBill/Models/ItemDetail.php b/src/UBill/Models/ItemDetail.php new file mode 100644 index 00000000..d4cfd175 --- /dev/null +++ b/src/UBill/Models/ItemDetail.php @@ -0,0 +1,67 @@ +get("ProductName"); + } + + /** + * ProductName: 产品小类名称 + * + * @param string $productName + */ + public function setProductName(string $productName) + { + $this->set("ProductName", $productName); + } + /** + * Value: 产品小类规格 + * + * @return string|null + */ + public function getValue() + { + return $this->get("Value"); + } + + /** + * Value: 产品小类规格 + * + * @param string $value + */ + public function setValue(string $value) + { + $this->set("Value", $value); + } +} diff --git a/src/UCDN/Models/UcdnDomainTrafficSet.php b/src/UBill/Models/ResourceExtendInfo.php similarity index 57% rename from src/UCDN/Models/UcdnDomainTrafficSet.php rename to src/UBill/Models/ResourceExtendInfo.php index d35860f9..fb573f35 100644 --- a/src/UCDN/Models/UcdnDomainTrafficSet.php +++ b/src/UBill/Models/ResourceExtendInfo.php @@ -1,6 +1,7 @@ get("Time"); + return $this->get("KeyId"); } /** - * Time: 流量获取的时间点,格式为Unix Timestamp + * KeyId: 资源标识健 * - * @param int $time + * @param string $keyId */ - public function setTime($time) + public function setKeyId(string $keyId) { - $this->set("Time", $time); + $this->set("KeyId", $keyId); } - /** - * Value: 查询每日流量总值,单位:GB + * Value: 资源标识值 * - * @return float|null + * @return string|null */ public function getValue() { @@ -53,11 +56,11 @@ public function getValue() } /** - * Value: 查询每日流量总值,单位:GB + * Value: 资源标识值 * - * @param float $value + * @param string $value */ - public function setValue($value) + public function setValue(string $value) { $this->set("Value", $value); } diff --git a/src/UBill/UBillClient.php b/src/UBill/UBillClient.php index c745803f..da25ba09 100644 --- a/src/UBill/UBillClient.php +++ b/src/UBill/UBillClient.php @@ -1,6 +1,7 @@ (object) 账户余额信息[ - * "AmountFreeze" => (string) 冻结账户金额 - * "AmountCredit" => (string) 信用账户余额 - * "AmountFree" => (string) 赠送账户余额 - * "Amount" => (string) 账户余额 - * "AmountAvailable" => (string) 账户可用余额 - * ] - * ] - * - * @return GetBalanceResponse * @throws UCloudException */ public function getBalance(GetBalanceRequest $request = null) @@ -59,29 +61,13 @@ public function getBalance(GetBalanceRequest $request = null) $resp = $this->invoke($request); return new GetBalanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetBillDataFileUrl - 生成账单数据文件下载的 url * - * See also: https://docs.ucloud.cn/api/ubill-api/get_bill_data_file_url - * - * Arguments: - * - * $args = [ - * "BillPeriod" => (integer) 账期(时间戳格式) - * "BillType" => (integer) 账单类型,传 0 时获取账单总览报表,传 1 获取账单明细报表 - * "PaidType" => (integer) 获取账单总览报表时,账单的支付状态,传 0 时获取待支付账单,传 1 时获取已支付账单。获取账单明细报表时该参数无效 - * "RequireVersion" => (string) 如需求其他语言版本的账单则使用此参数。默认中文。如 RequireVersion = "EN",则提供英文版本账单。 - * ] - * - * Outputs: - * - * $outputs = [ - * "FileUrl" => (string) 交易账单数据下载URL - * "IsValid" => (string) 生成的 URL是否有效,即有对应数据文件 - * ] - * - * @return GetBillDataFileUrlResponse * @throws UCloudException */ public function getBillDataFileUrl(GetBillDataFileUrlRequest $request = null) @@ -89,4 +75,32 @@ public function getBillDataFileUrl(GetBillDataFileUrlRequest $request = null) $resp = $this->invoke($request); return new GetBillDataFileUrlResponse($resp->toArray(), $resp->getRequestId()); } + + + + + /** + * ListUBillDetail - 获取某个账期内的所有消费。 + * + * @throws UCloudException + */ + public function listUBillDetail(ListUBillDetailRequest $request = null) + { + $resp = $this->invoke($request); + return new ListUBillDetailResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ListUBillOverview - 账单总览。可按产品/项目/用户纬度获取某个账期内账单总览信息。 + * + * @throws UCloudException + */ + public function listUBillOverview(ListUBillOverviewRequest $request = null) + { + $resp = $this->invoke($request); + return new ListUBillOverviewResponse($resp->toArray(), $resp->getRequestId()); + } } diff --git a/src/UCDN/Apis/AddCertificateRequest.php b/src/UCDN/Apis/AddCertificateRequest.php index 7b360e36..0ebdd54e 100644 --- a/src/UCDN/Apis/AddCertificateRequest.php +++ b/src/UCDN/Apis/AddCertificateRequest.php @@ -1,6 +1,7 @@ markRequired("PrivateKey"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CertName: 证书名称 * @@ -65,11 +65,10 @@ public function getCertName() * * @param string $certName */ - public function setCertName($certName) + public function setCertName(string $certName) { $this->set("CertName", $certName); } - /** * UserCert: 用户证书 * @@ -85,11 +84,10 @@ public function getUserCert() * * @param string $userCert */ - public function setUserCert($userCert) + public function setUserCert(string $userCert) { $this->set("UserCert", $userCert); } - /** * PrivateKey: 用户私钥 * @@ -105,11 +103,10 @@ public function getPrivateKey() * * @param string $privateKey */ - public function setPrivateKey($privateKey) + public function setPrivateKey(string $privateKey) { $this->set("PrivateKey", $privateKey); } - /** * CaCert: Ca证书,默认为空 * @@ -125,7 +122,7 @@ public function getCaCert() * * @param string $caCert */ - public function setCaCert($caCert) + public function setCaCert(string $caCert) { $this->set("CaCert", $caCert); } diff --git a/src/UCDN/Apis/AddCertificateResponse.php b/src/UCDN/Apis/AddCertificateResponse.php index fd65c496..b7693e7d 100644 --- a/src/UCDN/Apis/AddCertificateResponse.php +++ b/src/UCDN/Apis/AddCertificateResponse.php @@ -1,6 +1,7 @@ "ControlUcdnDomainCacheAccess"]); + $this->markRequired("UrlList"); + $this->markRequired("Type"); + } + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * UrlList: 待封禁的Url,一次封禁多个Url时最多一次30条,只能对表示文件的Url进行操作 + * + * @return string[]|null + */ + public function getUrlList() + { + return $this->get("UrlList"); + } + + /** + * UrlList: 待封禁的Url,一次封禁多个Url时最多一次30条,只能对表示文件的Url进行操作 + * + * @param string[] $urlList + */ + public function setUrlList(array $urlList) + { + $this->set("UrlList", $urlList); + } + /** + * Type: forbid=封禁 unforbid=解封 其他值非法 + * + * @return string|null + */ + public function getType() + { + return $this->get("Type"); + } + + /** + * Type: forbid=封禁 unforbid=解封 其他值非法 + * + * @param string $type + */ + public function setType(string $type) + { + $this->set("Type", $type); + } +} diff --git a/src/UCDN/Apis/ControlUcdnDomainCacheAccessResponse.php b/src/UCDN/Apis/ControlUcdnDomainCacheAccessResponse.php new file mode 100644 index 00000000..22e6c5bd --- /dev/null +++ b/src/UCDN/Apis/ControlUcdnDomainCacheAccessResponse.php @@ -0,0 +1,26 @@ +markRequired("CertName"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CertName: 证书名称 * @@ -63,7 +63,7 @@ public function getCertName() * * @param string $certName */ - public function setCertName($certName) + public function setCertName(string $certName) { $this->set("CertName", $certName); } diff --git a/src/UCDN/Apis/DeleteCertificateResponse.php b/src/UCDN/Apis/DeleteCertificateResponse.php index 650e6ef4..3d2cb2ba 100644 --- a/src/UCDN/Apis/DeleteCertificateResponse.php +++ b/src/UCDN/Apis/DeleteCertificateResponse.php @@ -1,6 +1,7 @@ "DescribeNewUcdnPrefetchCacheTask"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TaskId: 提交任务时返回的任务ID * @@ -66,7 +66,6 @@ public function setTaskId(array $taskId) { $this->set("TaskId", $taskId); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 * @@ -82,11 +81,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -102,11 +100,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Status: 需要获取的内容预热的状态,枚举值:success:成功;wait:等待处理;process:正在处理;failure:失败; unknow:未知,默认选择所有状态 * @@ -122,11 +119,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * Offset: 数据偏移量,默认为0,自然数 * @@ -142,11 +138,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认全部,自然数 * @@ -162,7 +157,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UCDN/Apis/DescribeNewUcdnPrefetchCacheTaskResponse.php b/src/UCDN/Apis/DescribeNewUcdnPrefetchCacheTaskResponse.php index 64921715..00787b71 100644 --- a/src/UCDN/Apis/DescribeNewUcdnPrefetchCacheTaskResponse.php +++ b/src/UCDN/Apis/DescribeNewUcdnPrefetchCacheTaskResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * TaskList: 预热任务信息,参考TaskInfo * - * @return TaskInfo[]|null + * @return TaskInfoModel[]|null */ public function getTaskList() { @@ -57,7 +58,7 @@ public function getTaskList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new TaskInfo($item)); + array_push($result, new TaskInfoModel($item)); } return $result; } @@ -65,7 +66,7 @@ public function getTaskList() /** * TaskList: 预热任务信息,参考TaskInfo * - * @param TaskInfo[] $taskList + * @param TaskInfoModel[] $taskList */ public function setTaskList(array $taskList) { diff --git a/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskRequest.php b/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskRequest.php index ad3bd0b1..834d9a23 100644 --- a/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskRequest.php +++ b/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskRequest.php @@ -1,6 +1,7 @@ "DescribeNewUcdnRefreshCacheTask"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TaskId: 提交任务时返回的任务ID * @@ -66,7 +66,6 @@ public function setTaskId(array $taskId) { $this->set("TaskId", $taskId); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 * @@ -82,11 +81,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -102,11 +100,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Status: 需要获取的内容刷新的状态,枚举值:success:成功;wait:等待处理;process:正在处理;failure:失败; unknow:未知,默认选择所有状态 * @@ -122,11 +119,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * Offset: 数据偏移量,默认为0,自然数 * @@ -142,11 +138,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认全部,自然数 * @@ -162,7 +157,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskResponse.php b/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskResponse.php index cfb27fd2..6c3d944f 100644 --- a/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskResponse.php +++ b/src/UCDN/Apis/DescribeNewUcdnRefreshCacheTaskResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * TaskList: 刷新任务信息,参考TaskInfo * - * @return TaskInfo[]|null + * @return TaskInfoModel[]|null */ public function getTaskList() { @@ -57,7 +58,7 @@ public function getTaskList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new TaskInfo($item)); + array_push($result, new TaskInfoModel($item)); } return $result; } @@ -65,7 +66,7 @@ public function getTaskList() /** * TaskList: 刷新任务信息,参考TaskInfo * - * @param TaskInfo[] $taskList + * @param TaskInfoModel[] $taskList */ public function setTaskList(array $taskList) { diff --git a/src/UCDN/Apis/GetCertificateV2Request.php b/src/UCDN/Apis/GetCertificateV2Request.php index 17709299..537e57f1 100644 --- a/src/UCDN/Apis/GetCertificateV2Request.php +++ b/src/UCDN/Apis/GetCertificateV2Request.php @@ -1,6 +1,7 @@ "GetCertificateV2"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 偏移,默认为0,非负整数 * @@ -62,11 +62,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 长度,默认为全部,非负整数 * @@ -82,7 +81,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UCDN/Apis/GetCertificateV2Response.php b/src/UCDN/Apis/GetCertificateV2Response.php index be361a14..2179cbe7 100644 --- a/src/UCDN/Apis/GetCertificateV2Response.php +++ b/src/UCDN/Apis/GetCertificateV2Response.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * CertList: 证书信息列表 * - * @return CertList[]|null + * @return CertListModel[]|null */ public function getCertList() { @@ -56,7 +57,7 @@ public function getCertList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CertList($item)); + array_push($result, new CertListModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getCertList() /** * CertList: 证书信息列表 * - * @param CertList[] $certList + * @param CertListModel[] $certList */ public function setCertList(array $certList) { diff --git a/src/UCDN/Apis/GetNewUcdnDomainBandwidthRequest.php b/src/UCDN/Apis/GetNewUcdnDomainBandwidthRequest.php deleted file mode 100644 index 54f48b22..00000000 --- a/src/UCDN/Apis/GetNewUcdnDomainBandwidthRequest.php +++ /dev/null @@ -1,150 +0,0 @@ - "GetNewUcdnDomainBandwidth"]); - $this->markRequired("Type"); - } - - - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * - * @return string|null - */ - public function getProjectId() - { - return $this->get("ProjectId"); - } - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * - * @param string $projectId - */ - public function setProjectId($projectId) - { - $this->set("ProjectId", $projectId); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @return integer|null - */ - public function getType() - { - return $this->get("Type"); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @param int $type - */ - public function setType($type) - { - $this->set("Type", $type); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @return string[]|null - */ - public function getDomainId() - { - return $this->get("DomainId"); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @param string[] $domainId - */ - public function setDomainId(array $domainId) - { - $this->set("DomainId", $domainId); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 - * - * @return string|null - */ - public function getAreacode() - { - return $this->get("Areacode"); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 - * - * @param string $areacode - */ - public function setAreacode($areacode) - { - $this->set("Areacode", $areacode); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @return integer|null - */ - public function getBeginTime() - { - return $this->get("BeginTime"); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @param int $beginTime - */ - public function setBeginTime($beginTime) - { - $this->set("BeginTime", $beginTime); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @return integer|null - */ - public function getEndTime() - { - return $this->get("EndTime"); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @param int $endTime - */ - public function setEndTime($endTime) - { - $this->set("EndTime", $endTime); - } -} diff --git a/src/UCDN/Apis/GetNewUcdnDomainHitRateRequest.php b/src/UCDN/Apis/GetNewUcdnDomainHitRateRequest.php index 462cb0c7..116e6cc4 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainHitRateRequest.php +++ b/src/UCDN/Apis/GetNewUcdnDomainHitRateRequest.php @@ -1,6 +1,7 @@ "GetNewUcdnDomainHitRate"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度)默认5分钟 * @@ -62,11 +62,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -86,7 +85,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -102,11 +100,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -122,11 +119,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -142,7 +138,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UCDN/Apis/GetNewUcdnDomainHitRateResponse.php b/src/UCDN/Apis/GetNewUcdnDomainHitRateResponse.php index 9f6e0e5c..b8f452c0 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainHitRateResponse.php +++ b/src/UCDN/Apis/GetNewUcdnDomainHitRateResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HitRateInfo($item)); + array_push($result, new HitRateInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getHitRateList() /** * HitRateList: 请求数实例表。 * - * @param HitRateInfo[] $hitRateList + * @param HitRateInfoModel[] $hitRateList */ public function setHitRateList(array $hitRateList) { diff --git a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeRequest.php b/src/UCDN/Apis/GetNewUcdnDomainHttpCodeRequest.php deleted file mode 100644 index 994b94a1..00000000 --- a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeRequest.php +++ /dev/null @@ -1,150 +0,0 @@ - "GetNewUcdnDomainHttpCode"]); - $this->markRequired("Type"); - } - - - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @return string|null - */ - public function getProjectId() - { - return $this->get("ProjectId"); - } - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @param string $projectId - */ - public function setProjectId($projectId) - { - $this->set("ProjectId", $projectId); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @return integer|null - */ - public function getType() - { - return $this->get("Type"); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @param int $type - */ - public function setType($type) - { - $this->set("Type", $type); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @return string[]|null - */ - public function getDomainId() - { - return $this->get("DomainId"); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @param string[] $domainId - */ - public function setDomainId(array $domainId) - { - $this->set("DomainId", $domainId); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * - * @return string|null - */ - public function getAreacode() - { - return $this->get("Areacode"); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * - * @param string $areacode - */ - public function setAreacode($areacode) - { - $this->set("Areacode", $areacode); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @return integer|null - */ - public function getBeginTime() - { - return $this->get("BeginTime"); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @param int $beginTime - */ - public function setBeginTime($beginTime) - { - $this->set("BeginTime", $beginTime); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @return integer|null - */ - public function getEndTime() - { - return $this->get("EndTime"); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @param int $endTime - */ - public function setEndTime($endTime) - { - $this->set("EndTime", $endTime); - } -} diff --git a/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsRequest.php b/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsRequest.php new file mode 100644 index 00000000..ea8d1c82 --- /dev/null +++ b/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsRequest.php @@ -0,0 +1,145 @@ + "GetNewUcdnLogRefererStatistics"]); + } + + + /** + * DomainId: 域名id,创建域名时生成的id + * + * @return string|null + */ + public function getDomainId() + { + return $this->get("DomainId"); + } + + /** + * DomainId: 域名id,创建域名时生成的id + * + * @param string $domainId + */ + public function setDomainId(string $domainId) + { + $this->set("DomainId", $domainId); + } + /** + * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 ;目前只支持国内 + * + * @return string|null + */ + public function getAreacode() + { + return $this->get("Areacode"); + } + + /** + * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 ;目前只支持国内 + * + * @param string $areacode + */ + public function setAreacode(string $areacode) + { + $this->set("Areacode", $areacode); + } + /** + * BeginTime: 查询带宽的起始时间,格式:时间戳 + * + * @return integer|null + */ + public function getBeginTime() + { + return $this->get("BeginTime"); + } + + /** + * BeginTime: 查询带宽的起始时间,格式:时间戳 + * + * @param int $beginTime + */ + public function setBeginTime(int $beginTime) + { + $this->set("BeginTime", $beginTime); + } + /** + * EndTime: 查询统计日志的结束时间,格式:时间戳。最大时间间隔30天 + * + * @return integer|null + */ + public function getEndTime() + { + return $this->get("EndTime"); + } + + /** + * EndTime: 查询统计日志的结束时间,格式:时间戳。最大时间间隔30天 + * + * @param int $endTime + */ + public function setEndTime(int $endTime) + { + $this->set("EndTime", $endTime); + } + /** + * OrderBy: 0表示按流量降序排列,1表示按照下载次数降序排列,默认为0 + * + * @return integer|null + */ + public function getOrderBy() + { + return $this->get("OrderBy"); + } + + /** + * OrderBy: 0表示按流量降序排列,1表示按照下载次数降序排列,默认为0 + * + * @param int $orderBy + */ + public function setOrderBy(int $orderBy) + { + $this->set("OrderBy", $orderBy); + } + /** + * Limit: 返回的结果数量限制,默认1000 + * + * @return integer|null + */ + public function getLimit() + { + return $this->get("Limit"); + } + + /** + * Limit: 返回的结果数量限制,默认1000 + * + * @param int $limit + */ + public function setLimit(int $limit) + { + $this->set("Limit", $limit); + } +} diff --git a/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsResponse.php b/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsResponse.php new file mode 100644 index 00000000..521ec6f8 --- /dev/null +++ b/src/UCDN/Apis/GetNewUcdnLogRefererStatisticsResponse.php @@ -0,0 +1,60 @@ +get("RefererStatistics"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new RefererStatisticsModel($item)); + } + return $result; + } + + /** + * RefererStatistics: 按天统计实例 + * + * @param RefererStatisticsModel[] $refererStatistics + */ + public function setRefererStatistics(array $refererStatistics) + { + $result = []; + foreach ($refererStatistics as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Request.php b/src/UCDN/Apis/GetNewUcdnLogUrlStatisticsRequest.php similarity index 57% rename from src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Request.php rename to src/UCDN/Apis/GetNewUcdnLogUrlStatisticsRequest.php index d9f0cc48..957d2a67 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeV2Request.php +++ b/src/UCDN/Apis/GetNewUcdnLogUrlStatisticsRequest.php @@ -1,6 +1,7 @@ "GetNewUcdnDomainHttpCodeV2"]); - $this->markRequired("Type"); - $this->markRequired("BeginTime"); - $this->markRequired("EndTime"); + parent::__construct(["Action" => "GetNewUcdnLogUrlStatistics"]); + $this->markRequired("DomainId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,33 +44,50 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) + * DomainId: 域名Id * - * @return integer|null + * @return string|null */ - public function getType() + public function getDomainId() { - return $this->get("Type"); + return $this->get("DomainId"); } /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) + * DomainId: 域名Id + * + * @param string $domainId + */ + public function setDomainId(string $domainId) + { + $this->set("DomainId", $domainId); + } + /** + * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 只支持国内 * - * @param int $type + * @return string|null */ - public function setType($type) + public function getAreacode() { - $this->set("Type", $type); + return $this->get("Areacode"); } /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。 + * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 只支持国内 + * + * @param string $areacode + */ + public function setAreacode(string $areacode) + { + $this->set("Areacode", $areacode); + } + /** + * BeginTime: 查询带宽的起始时间,格式:时间戳。BeginTime和EndTime必须同时赋值 * * @return integer|null */ @@ -81,17 +97,16 @@ public function getBeginTime() } /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。 + * BeginTime: 查询带宽的起始时间,格式:时间戳。BeginTime和EndTime必须同时赋值 * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。 + * EndTime: 查询统计日志的结束时间,格式:时间戳,最多可拉取30天 * * @return integer|null */ @@ -101,52 +116,50 @@ public function getEndTime() } /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。 + * EndTime: 查询统计日志的结束时间,格式:时间戳,最多可拉取30天 * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 + * OrderBy: 0表示按流量降序排列,1表示按照下载次数降序排列,默认为0 * - * @return string[]|null + * @return integer|null */ - public function getDomainId() + public function getOrderBy() { - return $this->get("DomainId"); + return $this->get("OrderBy"); } /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 + * OrderBy: 0表示按流量降序排列,1表示按照下载次数降序排列,默认为0 * - * @param string[] $domainId + * @param int $orderBy */ - public function setDomainId(array $domainId) + public function setOrderBy(int $orderBy) { - $this->set("DomainId", $domainId); + $this->set("OrderBy", $orderBy); } - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 + * Limit: 返回的结果数量限制,默认1000 * - * @return string|null + * @return integer|null */ - public function getAreacode() + public function getLimit() { - return $this->get("Areacode"); + return $this->get("Limit"); } /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 + * Limit: 返回的结果数量限制,默认1000 * - * @param string $areacode + * @param int $limit */ - public function setAreacode($areacode) + public function setLimit(int $limit) { - $this->set("Areacode", $areacode); + $this->set("Limit", $limit); } } diff --git a/src/UCDN/Apis/GetNewUcdnLogUrlStatisticsResponse.php b/src/UCDN/Apis/GetNewUcdnLogUrlStatisticsResponse.php new file mode 100644 index 00000000..75b074f6 --- /dev/null +++ b/src/UCDN/Apis/GetNewUcdnLogUrlStatisticsResponse.php @@ -0,0 +1,60 @@ +get("UrlStatisticsList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new UrlStatisticsModel($item)); + } + return $result; + } + + /** + * UrlStatisticsList: 按天统计实例。 + * + * @param UrlStatisticsModel[] $urlStatisticsList + */ + public function setUrlStatisticsList(array $urlStatisticsList) + { + $result = []; + foreach ($urlStatisticsList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Request.php b/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Request.php index aad32fc9..1afa5098 100644 --- a/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Request.php +++ b/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Request.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BeginTime: 查询的起始日期,格式为Unix Timestamp * @@ -64,11 +64,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束日期,格式为Unix Timestamp * @@ -84,11 +83,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -108,7 +106,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 * @@ -124,7 +121,7 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } diff --git a/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Response.php b/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Response.php index b1774319..90084d89 100644 --- a/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Response.php +++ b/src/UCDN/Apis/GetUcdnDomain95BandwidthV2Response.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CdnBandwidth: 查询期间的CDN的95带宽值,单位Mbps * @@ -57,7 +57,7 @@ public function getCdnBandwidth() * * @param float $cdnBandwidth */ - public function setCdnBandwidth($cdnBandwidth) + public function setCdnBandwidth(float $cdnBandwidth) { $this->set("CdnBandwidth", $cdnBandwidth); } diff --git a/src/UCDN/Apis/GetUcdnDomainBandwidthV2Request.php b/src/UCDN/Apis/GetUcdnDomainBandwidthV2Request.php index c8b27cb4..5bf0ea8a 100644 --- a/src/UCDN/Apis/GetUcdnDomainBandwidthV2Request.php +++ b/src/UCDN/Apis/GetUcdnDomainBandwidthV2Request.php @@ -1,6 +1,7 @@ "GetUcdnDomainBandwidthV2"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) * @@ -62,11 +62,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -86,7 +85,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 * @@ -102,11 +100,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -122,11 +119,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -142,11 +138,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Protocol: 协议,http、https 不传则查所有协议的带宽 * @@ -162,11 +157,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * Primeval: 原始带宽,不为0则获取原始带宽,默认为0 * @@ -182,7 +176,7 @@ public function getPrimeval() * * @param int $primeval */ - public function setPrimeval($primeval) + public function setPrimeval(int $primeval) { $this->set("Primeval", $primeval); } diff --git a/src/UCDN/Apis/GetUcdnDomainBandwidthV2Response.php b/src/UCDN/Apis/GetUcdnDomainBandwidthV2Response.php index d4385828..b28f6d7c 100644 --- a/src/UCDN/Apis/GetUcdnDomainBandwidthV2Response.php +++ b/src/UCDN/Apis/GetUcdnDomainBandwidthV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new BandwidthTrafficInfo($item)); + array_push($result, new BandwidthTrafficInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getBandwidthTrafficList() /** * BandwidthTrafficList: 带宽信息列表,参见BandwidthTrafficInfo * - * @param BandwidthTrafficInfo[] $bandwidthTrafficList + * @param BandwidthTrafficInfoModel[] $bandwidthTrafficList */ public function setBandwidthTrafficList(array $bandwidthTrafficList) { diff --git a/src/UCDN/Apis/GetUcdnDomainConfigRequest.php b/src/UCDN/Apis/GetUcdnDomainConfigRequest.php index 4488e3f3..f6898b41 100644 --- a/src/UCDN/Apis/GetUcdnDomainConfigRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainConfigRequest.php @@ -1,6 +1,7 @@ "GetUcdnDomainConfig"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 数据偏移量,默认0,非负整数 * @@ -62,11 +62,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认全部,非负整数 * @@ -82,11 +81,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * DomainId: 域名id,创建域名时生成的id。默认获取账号下的所有域名信息,n为自然数,从DomainId.0开始。 * @@ -106,7 +104,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * ChannelType: 产品类型ucdn,可不填,默认为ucdn * @@ -122,7 +119,7 @@ public function getChannelType() * * @param string $channelType */ - public function setChannelType($channelType) + public function setChannelType(string $channelType) { $this->set("ChannelType", $channelType); } diff --git a/src/UCDN/Apis/GetUcdnDomainConfigResponse.php b/src/UCDN/Apis/GetUcdnDomainConfigResponse.php index 1cf5f04c..b98a7667 100644 --- a/src/UCDN/Apis/GetUcdnDomainConfigResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainConfigResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new DomainConfigInfo($item)); + array_push($result, new DomainConfigInfoModel($item)); } return $result; } @@ -52,7 +53,7 @@ public function getDomainList() /** * DomainList: 获取的域名信息,具体参考下面DomainConfig * - * @param DomainConfigInfo[] $domainList + * @param DomainConfigInfoModel[] $domainList */ public function setDomainList(array $domainList) { diff --git a/src/UCDN/Apis/GetUcdnDomainHitRateRequest.php b/src/UCDN/Apis/GetUcdnDomainHitRateRequest.php index f59fa8cc..056b57f9 100644 --- a/src/UCDN/Apis/GetUcdnDomainHitRateRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainHitRateRequest.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照一分钟的粒度)默认5分钟 * @@ -63,11 +63,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -87,7 +86,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -103,11 +101,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -123,11 +120,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -143,11 +139,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * HitType: 命中类型:0=整体命中 1=边缘命中 默认是0 * @@ -163,7 +158,7 @@ public function getHitType() * * @param int $hitType */ - public function setHitType($hitType) + public function setHitType(int $hitType) { $this->set("HitType", $hitType); } diff --git a/src/UCDN/Apis/GetUcdnDomainHitRateResponse.php b/src/UCDN/Apis/GetUcdnDomainHitRateResponse.php index 67c8da51..b17e36e0 100644 --- a/src/UCDN/Apis/GetUcdnDomainHitRateResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainHitRateResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HitRateInfoV2($item)); + array_push($result, new HitRateInfoV2Model($item)); } return $result; } @@ -44,7 +46,7 @@ public function getHitRateList() /** * HitRateList: 请求数实例表。 * - * @param HitRateInfoV2[] $hitRateList + * @param HitRateInfoV2Model[] $hitRateList */ public function setHitRateList(array $hitRateList) { diff --git a/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Request.php b/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Request.php index 8b2bc8fe..f0cf58c5 100644 --- a/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Request.php +++ b/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Request.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示1分钟粒度) * @@ -63,11 +63,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -87,7 +86,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -103,11 +101,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -123,11 +120,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -143,11 +139,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Layer: 指定获取的状态码是边缘还是上层 edge 表示边缘 layer 表示上层 * @@ -163,7 +158,7 @@ public function getLayer() * * @param string $layer */ - public function setLayer($layer) + public function setLayer(string $layer) { $this->set("Layer", $layer); } diff --git a/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Response.php b/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Response.php index 598c194c..c2d10764 100644 --- a/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Response.php +++ b/src/UCDN/Apis/GetUcdnDomainHttpCodeV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HttpCodeInfoV2($item)); + array_push($result, new HttpCodeInfoV2Model($item)); } return $result; } @@ -50,7 +47,7 @@ public function getHttpCodeDetail() /** * HttpCodeDetail: 状态码实例表。详细见HttpCodeInfoV2 * - * @param HttpCodeInfoV2[] $httpCodeDetail + * @param HttpCodeInfoV2Model[] $httpCodeDetail */ public function setHttpCodeDetail(array $httpCodeDetail) { diff --git a/src/UCDN/Apis/GetUcdnDomainInfoListRequest.php b/src/UCDN/Apis/GetUcdnDomainInfoListRequest.php index 7a293ddd..a86e4468 100644 --- a/src/UCDN/Apis/GetUcdnDomainInfoListRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainInfoListRequest.php @@ -1,6 +1,7 @@ "GetUcdnDomainInfoList"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PageSize: 分页的大小,不填默认每页20个 * @@ -62,11 +62,10 @@ public function getPageSize() * * @param int $pageSize */ - public function setPageSize($pageSize) + public function setPageSize(int $pageSize) { $this->set("PageSize", $pageSize); } - /** * PageIndex: 返回第几页,不填默认是第1页 * @@ -82,7 +81,7 @@ public function getPageIndex() * * @param int $pageIndex */ - public function setPageIndex($pageIndex) + public function setPageIndex(int $pageIndex) { $this->set("PageIndex", $pageIndex); } diff --git a/src/UCDN/Apis/GetUcdnDomainInfoListResponse.php b/src/UCDN/Apis/GetUcdnDomainInfoListResponse.php index f6258fcc..68076763 100644 --- a/src/UCDN/Apis/GetUcdnDomainInfoListResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainInfoListResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DomainInfoList: 域名基本信息 * - * @return DomainBaseInfo[]|null + * @return DomainBaseInfoModel[]|null */ public function getDomainInfoList() { @@ -56,7 +57,7 @@ public function getDomainInfoList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new DomainBaseInfo($item)); + array_push($result, new DomainBaseInfoModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDomainInfoList() /** * DomainInfoList: 域名基本信息 * - * @param DomainBaseInfo[] $domainInfoList + * @param DomainBaseInfoModel[] $domainInfoList */ public function setDomainInfoList(array $domainInfoList) { diff --git a/src/UCDN/Apis/GetUcdnDomainLogRequest.php b/src/UCDN/Apis/GetUcdnDomainLogRequest.php index 0cfd5e89..f7cd4729 100644 --- a/src/UCDN/Apis/GetUcdnDomainLogRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainLogRequest.php @@ -1,6 +1,7 @@ "GetUcdnDomainLog"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DomainId: 域名ID,创建加速域名时生成。默认全部域名 * @@ -66,7 +66,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。 * @@ -82,11 +81,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -102,11 +100,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Type: 查询粒度 0=default(没有粒度) 1=按小时 2=按天 * @@ -122,7 +119,7 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } diff --git a/src/UCDN/Apis/GetUcdnDomainLogResponse.php b/src/UCDN/Apis/GetUcdnDomainLogResponse.php index 4a6c91e6..f77eaded 100644 --- a/src/UCDN/Apis/GetUcdnDomainLogResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainLogResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new LogSetList($item)); + array_push($result, new LogSetListModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getLogSet() /** * LogSet: 获取日志的连接地址。具体参考下面LogSetList * - * @param LogSetList[] $logSet + * @param LogSetListModel[] $logSet */ public function setLogSet(array $logSet) { diff --git a/src/UCDN/Apis/GetUcdnDomainRequestNumV2Request.php b/src/UCDN/Apis/GetUcdnDomainLogV2Request.php similarity index 65% rename from src/UCDN/Apis/GetUcdnDomainRequestNumV2Request.php rename to src/UCDN/Apis/GetUcdnDomainLogV2Request.php index 33ee59bf..a96dfeab 100644 --- a/src/UCDN/Apis/GetUcdnDomainRequestNumV2Request.php +++ b/src/UCDN/Apis/GetUcdnDomainLogV2Request.php @@ -1,6 +1,7 @@ "GetUcdnDomainRequestNumV2"]); - $this->markRequired("Type"); + parent::__construct(["Action" => "GetUcdnDomainLogV2"]); $this->markRequired("BeginTime"); $this->markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,31 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) - * - * @return integer|null - */ - public function getType() - { - return $this->get("Type"); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) - * - * @param int $type - */ - public function setType($type) - { - $this->set("Type", $type); - } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp * @@ -85,11 +64,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp * @@ -105,11 +83,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -129,24 +106,4 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - - /** - * Areacode: 查询区域 cn代表国内 abroad代表海外,只支持国内 - * - * @return string|null - */ - public function getAreacode() - { - return $this->get("Areacode"); - } - - /** - * Areacode: 查询区域 cn代表国内 abroad代表海外,只支持国内 - * - * @param string $areacode - */ - public function setAreacode($areacode) - { - $this->set("Areacode", $areacode); - } } diff --git a/src/UCDN/Apis/GetUcdnDomainRequestNumV2Response.php b/src/UCDN/Apis/GetUcdnDomainLogV2Response.php similarity index 63% rename from src/UCDN/Apis/GetUcdnDomainRequestNumV2Response.php rename to src/UCDN/Apis/GetUcdnDomainLogV2Response.php index 00d1fe25..002b2427 100644 --- a/src/UCDN/Apis/GetUcdnDomainRequestNumV2Response.php +++ b/src/UCDN/Apis/GetUcdnDomainLogV2Response.php @@ -1,6 +1,7 @@ get("RequestList"); + $items = $this->get("DomainLogSet"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new RequestInfo($item)); + array_push($result, new DomanLogListModel($item)); } return $result; } /** - * RequestList: 请求数实例表。 + * DomainLogSet: * - * @param RequestInfo[] $requestList + * @param DomanLogListModel[] $domainLogSet */ - public function setRequestList(array $requestList) + public function setDomainLogSet(array $domainLogSet) { $result = []; - foreach ($requestList as $i => $item) { + foreach ($domainLogSet as $i => $item) { array_push($result, $item->getAll()); } return $result; diff --git a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailRequest.php b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailRequest.php index 8e2f0315..d8b9d04e 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) * @@ -65,11 +65,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。 * @@ -85,11 +84,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。 * @@ -105,11 +103,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -129,7 +126,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -145,7 +141,7 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } diff --git a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailResponse.php b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailResponse.php index 9736fe73..3a5590e8 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeDetailResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HttpCodeV2Detail($item)); + array_push($result, new HttpCodeV2DetailModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getHttpCodeV2Detail() /** * HttpCodeV2Detail: 状态码详情 * - * @param HttpCodeV2Detail[] $httpCodeV2Detail + * @param HttpCodeV2DetailModel[] $httpCodeV2Detail */ public function setHttpCodeV2Detail(array $httpCodeV2Detail) { diff --git a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeRequest.php b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeRequest.php index 3c9188af..425e7b2e 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeRequest.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) * @@ -63,11 +63,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -87,7 +86,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -103,11 +101,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -123,11 +120,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -143,7 +139,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeResponse.php b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeResponse.php index ae644a5c..fcc94e28 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginHttpCodeResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HttpCodeInfo($item)); + array_push($result, new HttpCodeInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getHttpCodeDetail() /** * HttpCodeDetail: 状态码实例表。详细见HttpCodeInfo * - * @param HttpCodeInfo[] $httpCodeDetail + * @param HttpCodeInfoModel[] $httpCodeDetail */ public function setHttpCodeDetail(array $httpCodeDetail) { diff --git a/src/UCDN/Apis/GetUcdnDomainOriginRequestNumRequest.php b/src/UCDN/Apis/GetUcdnDomainOriginRequestNumRequest.php index bc77ad31..9b1f0b40 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginRequestNumRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginRequestNumRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) * @@ -65,11 +65,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp * @@ -85,11 +84,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp * @@ -105,11 +103,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -129,7 +126,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询区域 cn代表国内 abroad代表海外,只支持国内 * @@ -145,7 +141,7 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } diff --git a/src/UCDN/Apis/GetUcdnDomainOriginRequestNumResponse.php b/src/UCDN/Apis/GetUcdnDomainOriginRequestNumResponse.php index c0e19bd9..b7a7b2bd 100644 --- a/src/UCDN/Apis/GetUcdnDomainOriginRequestNumResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainOriginRequestNumResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new RequestInfoV2($item)); + array_push($result, new RequestInfoV2Model($item)); } return $result; } @@ -44,7 +46,7 @@ public function getRequestList() /** * RequestList: 请求数实例表。 * - * @param RequestInfoV2[] $requestList + * @param RequestInfoV2Model[] $requestList */ public function setRequestList(array $requestList) { diff --git a/src/UCDN/Apis/GetUcdnDomainPrefetchEnableRequest.php b/src/UCDN/Apis/GetUcdnDomainPrefetchEnableRequest.php index 07988069..833897c4 100644 --- a/src/UCDN/Apis/GetUcdnDomainPrefetchEnableRequest.php +++ b/src/UCDN/Apis/GetUcdnDomainPrefetchEnableRequest.php @@ -1,6 +1,7 @@ markRequired("DomainId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DomainId: 域名ID,创建加速域名时生成。 * @@ -63,7 +63,7 @@ public function getDomainId() * * @param string $domainId */ - public function setDomainId($domainId) + public function setDomainId(string $domainId) { $this->set("DomainId", $domainId); } diff --git a/src/UCDN/Apis/GetUcdnDomainPrefetchEnableResponse.php b/src/UCDN/Apis/GetUcdnDomainPrefetchEnableResponse.php index b74ae886..16de7052 100644 --- a/src/UCDN/Apis/GetUcdnDomainPrefetchEnableResponse.php +++ b/src/UCDN/Apis/GetUcdnDomainPrefetchEnableResponse.php @@ -1,6 +1,7 @@ set("Enable", $enable); } diff --git a/src/UCDN/Apis/GetUcdnDomainRequestNumV3Request.php b/src/UCDN/Apis/GetUcdnDomainRequestNumV3Request.php index 69c4efb4..7f2e325b 100644 --- a/src/UCDN/Apis/GetUcdnDomainRequestNumV3Request.php +++ b/src/UCDN/Apis/GetUcdnDomainRequestNumV3Request.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) * @@ -65,11 +65,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp * @@ -85,11 +84,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp * @@ -105,11 +103,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -129,7 +126,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询区域 cn代表国内 abroad代表海外,只支持国内 * @@ -145,11 +141,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * Protocol: 协议,http、https 不传则查所有协议的带宽 * @@ -165,7 +160,7 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } diff --git a/src/UCDN/Apis/GetUcdnDomainRequestNumV3Response.php b/src/UCDN/Apis/GetUcdnDomainRequestNumV3Response.php index 62751506..5320af2c 100644 --- a/src/UCDN/Apis/GetUcdnDomainRequestNumV3Response.php +++ b/src/UCDN/Apis/GetUcdnDomainRequestNumV3Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new RequestInfoV2($item)); + array_push($result, new RequestInfoV2Model($item)); } return $result; } @@ -44,7 +46,7 @@ public function getRequestList() /** * RequestList: 请求数实例表。 * - * @param RequestInfoV2[] $requestList + * @param RequestInfoV2Model[] $requestList */ public function setRequestList(array $requestList) { diff --git a/src/UCDN/Apis/GetUcdnDomainTrafficRequest.php b/src/UCDN/Apis/GetUcdnDomainTrafficRequest.php deleted file mode 100644 index 65cbe4fa..00000000 --- a/src/UCDN/Apis/GetUcdnDomainTrafficRequest.php +++ /dev/null @@ -1,149 +0,0 @@ - "GetUcdnDomainTraffic"]); - } - - - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @return string|null - */ - public function getProjectId() - { - return $this->get("ProjectId"); - } - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @param string $projectId - */ - public function setProjectId($projectId) - { - $this->set("ProjectId", $projectId); - } - - /** - * AccountType: 指定按项目查询,还是按整个账户查询 取值 top 表示按整个账户查询,取值org表示按项目查询 - * - * @return string|null - */ - public function getAccountType() - { - return $this->get("AccountType"); - } - - /** - * AccountType: 指定按项目查询,还是按整个账户查询 取值 top 表示按整个账户查询,取值org表示按项目查询 - * - * @param string $accountType - */ - public function setAccountType($accountType) - { - $this->set("AccountType", $accountType); - } - - /** - * DomainId: 域名ID,创建加速域名时生成,n从自然数0开始。默认全部域名 - * - * @return string[]|null - */ - public function getDomainId() - { - return $this->get("DomainId"); - } - - /** - * DomainId: 域名ID,创建加速域名时生成,n从自然数0开始。默认全部域名 - * - * @param string[] $domainId - */ - public function setDomainId(array $domainId) - { - $this->set("DomainId", $domainId); - } - - /** - * Areacode: 查询流量区域 cn代表国内 abroad代表海外,默认全部区域 - * - * @return string|null - */ - public function getAreacode() - { - return $this->get("Areacode"); - } - - /** - * Areacode: 查询流量区域 cn代表国内 abroad代表海外,默认全部区域 - * - * @param string $areacode - */ - public function setAreacode($areacode) - { - $this->set("Areacode", $areacode); - } - - /** - * BeginTime: 查询的起始日期,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 - * - * @return integer|null - */ - public function getBeginTime() - { - return $this->get("BeginTime"); - } - - /** - * BeginTime: 查询的起始日期,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 - * - * @param int $beginTime - */ - public function setBeginTime($beginTime) - { - $this->set("BeginTime", $beginTime); - } - - /** - * EndTime: 查询的结束日期,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天 - * - * @return integer|null - */ - public function getEndTime() - { - return $this->get("EndTime"); - } - - /** - * EndTime: 查询的结束日期,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天 - * - * @param int $endTime - */ - public function setEndTime($endTime) - { - $this->set("EndTime", $endTime); - } -} diff --git a/src/UCDN/Apis/GetUcdnPassBandwidthRequest.php b/src/UCDN/Apis/GetUcdnPassBandwidthRequest.php deleted file mode 100644 index ba805a28..00000000 --- a/src/UCDN/Apis/GetUcdnPassBandwidthRequest.php +++ /dev/null @@ -1,150 +0,0 @@ - "GetUcdnPassBandwidth"]); - $this->markRequired("Type"); - } - - - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @return string|null - */ - public function getProjectId() - { - return $this->get("ProjectId"); - } - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * - * @param string $projectId - */ - public function setProjectId($projectId) - { - $this->set("ProjectId", $projectId); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @return integer|null - */ - public function getType() - { - return $this->get("Type"); - } - - /** - * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * - * @param int $type - */ - public function setType($type) - { - $this->set("Type", $type); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @return string[]|null - */ - public function getDomainId() - { - return $this->get("DomainId"); - } - - /** - * DomainId: 域名id,创建域名时生成的id。默认全部域名 - * - * @param string[] $domainId - */ - public function setDomainId(array $domainId) - { - $this->set("DomainId", $domainId); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * - * @return string|null - */ - public function getAreacode() - { - return $this->get("Areacode"); - } - - /** - * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * - * @param string $areacode - */ - public function setAreacode($areacode) - { - $this->set("Areacode", $areacode); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @return integer|null - */ - public function getBeginTime() - { - return $this->get("BeginTime"); - } - - /** - * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * - * @param int $beginTime - */ - public function setBeginTime($beginTime) - { - $this->set("BeginTime", $beginTime); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @return integer|null - */ - public function getEndTime() - { - return $this->get("EndTime"); - } - - /** - * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * - * @param int $endTime - */ - public function setEndTime($endTime) - { - $this->set("EndTime", $endTime); - } -} diff --git a/src/UCDN/Apis/GetUcdnPassBandwidthV2Request.php b/src/UCDN/Apis/GetUcdnPassBandwidthV2Request.php index e5e268c8..3deecc90 100644 --- a/src/UCDN/Apis/GetUcdnPassBandwidthV2Request.php +++ b/src/UCDN/Apis/GetUcdnPassBandwidthV2Request.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) * @@ -63,11 +63,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -87,7 +86,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Areacode: 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 * @@ -103,11 +101,10 @@ public function getAreacode() * * @param string $areacode */ - public function setAreacode($areacode) + public function setAreacode(string $areacode) { $this->set("Areacode", $areacode); } - /** * BeginTime: 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 * @@ -123,11 +120,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 * @@ -143,7 +139,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UCDN/Apis/GetUcdnPassBandwidthV2Response.php b/src/UCDN/Apis/GetUcdnPassBandwidthV2Response.php index 7d38e734..06a251a9 100644 --- a/src/UCDN/Apis/GetUcdnPassBandwidthV2Response.php +++ b/src/UCDN/Apis/GetUcdnPassBandwidthV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new BandwidthInfoDetail($item)); + array_push($result, new BandwidthInfoDetailModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getBandwidthList() /** * BandwidthList: 回源带宽数据 * - * @param BandwidthInfoDetail[] $bandwidthList + * @param BandwidthInfoDetailModel[] $bandwidthList */ public function setBandwidthList(array $bandwidthList) { diff --git a/src/UCDN/Apis/GetUcdnProIspBandwidthV2Request.php b/src/UCDN/Apis/GetUcdnProIspBandwidthV2Request.php index a6b360fc..68357063 100644 --- a/src/UCDN/Apis/GetUcdnProIspBandwidthV2Request.php +++ b/src/UCDN/Apis/GetUcdnProIspBandwidthV2Request.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BeginTime: 查询的起始日期,格式为Unix Timestamp * @@ -65,11 +65,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束日期,格式为Unix Timestamp * @@ -85,11 +84,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * Type: 时间粒度0 (按5分钟粒度)1 (按小时粒度)2(按天粒度)3(按分钟粒度) * @@ -105,11 +103,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -129,7 +126,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Province: 省份代码(省份拼音),可以传多个,不传则查询所有省份 * @@ -149,7 +145,6 @@ public function setProvince(array $province) { $this->set("Province", $province); } - /** * Isp: 运营商代码(运营商拼音),一次只能查询一个运营商,不传递默认取所有运营商 * @@ -165,7 +160,7 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } diff --git a/src/UCDN/Apis/GetUcdnProIspBandwidthV2Response.php b/src/UCDN/Apis/GetUcdnProIspBandwidthV2Response.php index 5b17eca3..041103df 100644 --- a/src/UCDN/Apis/GetUcdnProIspBandwidthV2Response.php +++ b/src/UCDN/Apis/GetUcdnProIspBandwidthV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ProIspBandwidthSet($item)); + array_push($result, new ProIspBandwidthSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getBandwidthSet() /** * BandwidthSet: 按省份的带宽流量实例表。具体参考下面BandwidthSet * - * @param ProIspBandwidthSet[] $bandwidthSet + * @param ProIspBandwidthSetModel[] $bandwidthSet */ public function setBandwidthSet(array $bandwidthSet) { diff --git a/src/UCDN/Apis/GetUcdnProIspRequestNumV2Request.php b/src/UCDN/Apis/GetUcdnProIspRequestNumV2Request.php index 6cb923f7..6cb5783f 100644 --- a/src/UCDN/Apis/GetUcdnProIspRequestNumV2Request.php +++ b/src/UCDN/Apis/GetUcdnProIspRequestNumV2Request.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BeginTime: 查询的起始日期,格式为Unix Timestamp 忽略时间部分 * @@ -64,11 +64,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询的结束日期,格式为Unix Timestamp 忽略时间部分 * @@ -84,11 +83,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainId: 域名id,创建域名时生成的id。默认全部域名 * @@ -108,7 +106,6 @@ public function setDomainId(array $domainId) { $this->set("DomainId", $domainId); } - /** * Province: 省份代码,可以传多个,不传则查询所有省份 * @@ -128,7 +125,6 @@ public function setProvince(array $province) { $this->set("Province", $province); } - /** * Isp: 运营商代码,一次只能查询一个运营商,不传递默认取所有运营商 * @@ -144,11 +140,10 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } - /** * Type: 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) * @@ -164,7 +159,7 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } diff --git a/src/UCDN/Apis/GetUcdnProIspRequestNumV2Response.php b/src/UCDN/Apis/GetUcdnProIspRequestNumV2Response.php index 3d44ceb0..8ad682b0 100644 --- a/src/UCDN/Apis/GetUcdnProIspRequestNumV2Response.php +++ b/src/UCDN/Apis/GetUcdnProIspRequestNumV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ProIspRequestNumSetV2($item)); + array_push($result, new ProIspRequestNumSetV2Model($item)); } return $result; } @@ -45,7 +47,7 @@ public function getRequestNumSet() /** * RequestNumSet: 按省份的请求数实例表。具体参考下面RequestList * - * @param ProIspRequestNumSetV2[] $requestNumSet + * @param ProIspRequestNumSetV2Model[] $requestNumSet */ public function setRequestNumSet(array $requestNumSet) { diff --git a/src/UCDN/Apis/GetUcdnTrafficRequest.php b/src/UCDN/Apis/GetUcdnTrafficRequest.php deleted file mode 100644 index 1d45b2ab..00000000 --- a/src/UCDN/Apis/GetUcdnTrafficRequest.php +++ /dev/null @@ -1,49 +0,0 @@ - "GetUcdnTraffic"]); - } - - - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * - * @return string|null - */ - public function getProjectId() - { - return $this->get("ProjectId"); - } - - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * - * @param string $projectId - */ - public function setProjectId($projectId) - { - $this->set("ProjectId", $projectId); - } -} diff --git a/src/UCDN/Apis/GetUcdnTrafficResponse.php b/src/UCDN/Apis/GetUcdnTrafficResponse.php deleted file mode 100644 index 60019523..00000000 --- a/src/UCDN/Apis/GetUcdnTrafficResponse.php +++ /dev/null @@ -1,57 +0,0 @@ -get("TrafficSet"); - if ($items == null) { - return []; - } - $result = []; - foreach ($items as $i => $item) { - array_push($result, new TrafficSet($item)); - } - return $result; - } - - /** - * TrafficSet: 用户不同区域的流量信息, 具体结构参见TrafficSet部分 - * - * @param TrafficSet[] $trafficSet - */ - public function setTrafficSet(array $trafficSet) - { - $result = []; - foreach ($trafficSet as $i => $item) { - array_push($result, $item->getAll()); - } - return $result; - } -} diff --git a/src/UCDN/Apis/GetUcdnTrafficV2Request.php b/src/UCDN/Apis/GetUcdnTrafficV2Request.php index 2e167573..a4eeeb16 100644 --- a/src/UCDN/Apis/GetUcdnTrafficV2Request.php +++ b/src/UCDN/Apis/GetUcdnTrafficV2Request.php @@ -1,6 +1,7 @@ "GetUcdnTrafficV2"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -42,7 +43,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UCDN/Apis/GetUcdnTrafficV2Response.php b/src/UCDN/Apis/GetUcdnTrafficV2Response.php index bbb32fee..b62df94e 100644 --- a/src/UCDN/Apis/GetUcdnTrafficV2Response.php +++ b/src/UCDN/Apis/GetUcdnTrafficV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new TrafficSet($item)); + array_push($result, new TrafficSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getTrafficSet() /** * TrafficSet: 用户不同区域的流量信息, 具体结构参见TrafficSet部分 * - * @param TrafficSet[] $trafficSet + * @param TrafficSetModel[] $trafficSet */ public function setTrafficSet(array $trafficSet) { diff --git a/src/UCDN/Apis/PrefetchNewUcdnDomainCacheRequest.php b/src/UCDN/Apis/PrefetchNewUcdnDomainCacheRequest.php index 0fa5932e..60185e44 100644 --- a/src/UCDN/Apis/PrefetchNewUcdnDomainCacheRequest.php +++ b/src/UCDN/Apis/PrefetchNewUcdnDomainCacheRequest.php @@ -1,6 +1,7 @@ markRequired("UrlList"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UrlList: 预热URL列表,n从自然数0开始。UrlList.n字段必须以”http://域名/”开始。如刷新文件目录a下面img.png文件, 格式为http://abc.ucloud.cn/a/img.png。请正确提交需要刷新的域名 * diff --git a/src/UCDN/Apis/PrefetchNewUcdnDomainCacheResponse.php b/src/UCDN/Apis/PrefetchNewUcdnDomainCacheResponse.php index ff6cc131..1bdf372f 100644 --- a/src/UCDN/Apis/PrefetchNewUcdnDomainCacheResponse.php +++ b/src/UCDN/Apis/PrefetchNewUcdnDomainCacheResponse.php @@ -1,6 +1,7 @@ set("TaskId", $taskId); } diff --git a/src/UCDN/Apis/QueryIpLocationRequest.php b/src/UCDN/Apis/QueryIpLocationRequest.php index 7cab29db..e3f95e03 100644 --- a/src/UCDN/Apis/QueryIpLocationRequest.php +++ b/src/UCDN/Apis/QueryIpLocationRequest.php @@ -1,6 +1,7 @@ markRequired("Ip"); } - /** * Ip: ip列表 diff --git a/src/UCDN/Apis/QueryIpLocationResponse.php b/src/UCDN/Apis/QueryIpLocationResponse.php index 04e6ff70..3ab3a3c2 100644 --- a/src/UCDN/Apis/QueryIpLocationResponse.php +++ b/src/UCDN/Apis/QueryIpLocationResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IpLocationInfo($item)); + array_push($result, new IpLocationInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getData() /** * Data: IP信息列表 * - * @param IpLocationInfo[] $data + * @param IpLocationInfoModel[] $data */ public function setData(array $data) { diff --git a/src/UCDN/Apis/RefreshNewUcdnDomainCacheRequest.php b/src/UCDN/Apis/RefreshNewUcdnDomainCacheRequest.php index b267d686..afe66703 100644 --- a/src/UCDN/Apis/RefreshNewUcdnDomainCacheRequest.php +++ b/src/UCDN/Apis/RefreshNewUcdnDomainCacheRequest.php @@ -1,6 +1,7 @@ markRequired("UrlList"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,13 +45,12 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * Type: 刷新类型,file代表文件刷新,dir 代表路径刷新 + * Type: 刷新类型,file代表文件刷新,dir 代表路径刷新,m3u8带表m3u8刷新 * * @return string|null */ @@ -60,15 +60,14 @@ public function getType() } /** - * Type: 刷新类型,file代表文件刷新,dir 代表路径刷新 + * Type: 刷新类型,file代表文件刷新,dir 代表路径刷新,m3u8带表m3u8刷新 * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * UrlList: 需要刷新的URL,n 从自然数0开始,刷新多个URL列表时,一次最多提交30个。必须以”http://域名/”开始。目录要以”/”结尾, 如刷新目录a下所有文件,格式为:http://abc.ucloud.cn/a/;如刷新文件目录a下面img.png文件, 格式为http://abc.ucloud.cn/a/img.png。请正确提交需要刷新的域名 * diff --git a/src/UCDN/Apis/RefreshNewUcdnDomainCacheResponse.php b/src/UCDN/Apis/RefreshNewUcdnDomainCacheResponse.php index f365ba2a..410a8750 100644 --- a/src/UCDN/Apis/RefreshNewUcdnDomainCacheResponse.php +++ b/src/UCDN/Apis/RefreshNewUcdnDomainCacheResponse.php @@ -1,6 +1,7 @@ set("TaskId", $taskId); } diff --git a/src/UCDN/Apis/SwitchUcdnChargeTypeRequest.php b/src/UCDN/Apis/SwitchUcdnChargeTypeRequest.php index fb65044d..103f3c5f 100644 --- a/src/UCDN/Apis/SwitchUcdnChargeTypeRequest.php +++ b/src/UCDN/Apis/SwitchUcdnChargeTypeRequest.php @@ -1,6 +1,7 @@ markRequired("ChargeType"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ChargeType: 计费方式。traffic代表按流量包计费,bandwidth按带宽付费 * @@ -63,7 +63,7 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } diff --git a/src/UCDN/Apis/SwitchUcdnChargeTypeResponse.php b/src/UCDN/Apis/SwitchUcdnChargeTypeResponse.php index f2ca4d6f..95ab60d8 100644 --- a/src/UCDN/Apis/SwitchUcdnChargeTypeResponse.php +++ b/src/UCDN/Apis/SwitchUcdnChargeTypeResponse.php @@ -1,6 +1,7 @@ set("IpBlackList", $ipBlackList); } - /** * ReferConf: refer配置 * - * @return ReferConf|null + * @return ReferConfModel|null */ public function getReferConf() { - return new ReferConf($this->get("ReferConf")); + return new ReferConfModel($this->get("ReferConf")); } /** * ReferConf: refer配置 * - * @param ReferConf $referConf + * @param ReferConfModel $referConf */ - public function setReferConf(array $referConf) + public function setReferConf(ReferConfModel $referConf) { $this->set("ReferConf", $referConf->getAll()); } diff --git a/src/UCDN/Models/AdvancedConf.php b/src/UCDN/Models/AdvancedConf.php index c6c877cb..9cbdc034 100644 --- a/src/UCDN/Models/AdvancedConf.php +++ b/src/UCDN/Models/AdvancedConf.php @@ -1,6 +1,7 @@ set("HttpClientHeader", $httpClientHeader); } - /** * HttpOriginHeader: 源站http头列表 * @@ -61,7 +65,6 @@ public function setHttpOriginHeader(array $httpOriginHeader) { $this->set("HttpOriginHeader", $httpOriginHeader); } - /** * Http2Https: http转https回源 true是,false否 * @@ -77,7 +80,7 @@ public function getHttp2Https() * * @param boolean $http2Https */ - public function setHttp2Https($http2Https) + public function setHttp2Https(bool $http2Https) { $this->set("Http2Https", $http2Https); } diff --git a/src/UCDN/Models/BandwidthInfo.php b/src/UCDN/Models/BandwidthInfo.php deleted file mode 100644 index 43860f63..00000000 --- a/src/UCDN/Models/BandwidthInfo.php +++ /dev/null @@ -1,64 +0,0 @@ -get("Time"); - } - - /** - * Time: 带宽获取的时间点。格式:时间戳 - * - * @param int $time - */ - public function setTime($time) - { - $this->set("Time", $time); - } - - /** - * CdnBandwidth: 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps(如果请求参数Type为0,则Value是五分钟粒度的带宽值,如果Type为1,则Value是1小时的带宽峰值,如果Type为2,则Value是一天内的带宽峰值) - * - * @return float|null - */ - public function getCdnBandwidth() - { - return $this->get("CdnBandwidth"); - } - - /** - * CdnBandwidth: 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps(如果请求参数Type为0,则Value是五分钟粒度的带宽值,如果Type为1,则Value是1小时的带宽峰值,如果Type为2,则Value是一天内的带宽峰值) - * - * @param float $cdnBandwidth - */ - public function setCdnBandwidth($cdnBandwidth) - { - $this->set("CdnBandwidth", $cdnBandwidth); - } -} diff --git a/src/UCDN/Models/BandwidthInfoDetail.php b/src/UCDN/Models/BandwidthInfoDetail.php index e8afb9c6..b229fe3e 100644 --- a/src/UCDN/Models/BandwidthInfoDetail.php +++ b/src/UCDN/Models/BandwidthInfoDetail.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * Bandwidth: 返回值带宽值数据。 * @@ -57,7 +60,7 @@ public function getBandwidth() * * @param float $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(float $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UCDN/Models/BandwidthTrafficInfo.php b/src/UCDN/Models/BandwidthTrafficInfo.php index 860028ea..5496d3b9 100644 --- a/src/UCDN/Models/BandwidthTrafficInfo.php +++ b/src/UCDN/Models/BandwidthTrafficInfo.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CdnBandwidth: 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps(如果请求参数Type为0,则Value是五分钟粒度的带宽值,如果Type为1,则Value是1小时的带宽峰值,如果Type为2,则Value是一天内的带宽峰值) * @@ -57,11 +60,10 @@ public function getCdnBandwidth() * * @param float $cdnBandwidth */ - public function setCdnBandwidth($cdnBandwidth) + public function setCdnBandwidth(float $cdnBandwidth) { $this->set("CdnBandwidth", $cdnBandwidth); } - /** * Traffic: 对应时间粒度的流量,单位字节 * @@ -77,7 +79,7 @@ public function getTraffic() * * @param float $traffic */ - public function setTraffic($traffic) + public function setTraffic(float $traffic) { $this->set("Traffic", $traffic); } diff --git a/src/UCDN/Models/CacheAllConfig.php b/src/UCDN/Models/CacheAllConfig.php index 3d75a8a1..7d08b055 100644 --- a/src/UCDN/Models/CacheAllConfig.php +++ b/src/UCDN/Models/CacheAllConfig.php @@ -1,6 +1,7 @@ set("CacheHost", $cacheHost); } - /** * CacheList: 缓存配置列表,参见CacheConf * - * @return CacheConf[]|null + * @return CacheConfModel[]|null */ public function getCacheList() { @@ -55,7 +61,7 @@ public function getCacheList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CacheConf($item)); + array_push($result, new CacheConfModel($item)); } return $result; } @@ -63,7 +69,7 @@ public function getCacheList() /** * CacheList: 缓存配置列表,参见CacheConf * - * @param CacheConf[] $cacheList + * @param CacheConfModel[] $cacheList */ public function setCacheList(array $cacheList) { @@ -73,11 +79,10 @@ public function setCacheList(array $cacheList) } return $result; } - /** * HttpCodeCacheList: 状态码缓存配置列表,参见CacheConf * - * @return CacheConf[]|null + * @return CacheConfModel[]|null */ public function getHttpCodeCacheList() { @@ -87,7 +92,7 @@ public function getHttpCodeCacheList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CacheConf($item)); + array_push($result, new CacheConfModel($item)); } return $result; } @@ -95,7 +100,7 @@ public function getHttpCodeCacheList() /** * HttpCodeCacheList: 状态码缓存配置列表,参见CacheConf * - * @param CacheConf[] $httpCodeCacheList + * @param CacheConfModel[] $httpCodeCacheList */ public function setHttpCodeCacheList(array $httpCodeCacheList) { @@ -105,11 +110,10 @@ public function setHttpCodeCacheList(array $httpCodeCacheList) } return $result; } - /** * CacheKeyList: 忽略参数缓存配置列表,参见CacheKeyInfo * - * @return CacheKeyInfo[]|null + * @return CacheKeyInfoModel[]|null */ public function getCacheKeyList() { @@ -119,7 +123,7 @@ public function getCacheKeyList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CacheKeyInfo($item)); + array_push($result, new CacheKeyInfoModel($item)); } return $result; } @@ -127,7 +131,7 @@ public function getCacheKeyList() /** * CacheKeyList: 忽略参数缓存配置列表,参见CacheKeyInfo * - * @param CacheKeyInfo[] $cacheKeyList + * @param CacheKeyInfoModel[] $cacheKeyList */ public function setCacheKeyList(array $cacheKeyList) { diff --git a/src/UCDN/Models/CacheConf.php b/src/UCDN/Models/CacheConf.php index 0482ebed..20e43054 100644 --- a/src/UCDN/Models/CacheConf.php +++ b/src/UCDN/Models/CacheConf.php @@ -1,6 +1,7 @@ set("PathPattern", $pathPattern); } - /** * CacheTTL: 缓存时间 * @@ -57,11 +64,10 @@ public function getCacheTTL() * * @param int $cacheTTL */ - public function setCacheTTL($cacheTTL) + public function setCacheTTL(int $cacheTTL) { $this->set("CacheTTL", $cacheTTL); } - /** * CacheUnit: 缓存时间的单位。sec(秒),min(分钟),hour(小时),day(天)。上限1年。 * @@ -77,11 +83,10 @@ public function getCacheUnit() * * @param string $cacheUnit */ - public function setCacheUnit($cacheUnit) + public function setCacheUnit(string $cacheUnit) { $this->set("CacheUnit", $cacheUnit); } - /** * CacheBehavior: 是否缓存,true为缓存,flase为不缓存。为flase的情况下,CacheTTL和CacheUnit强制不生效 * @@ -97,11 +102,10 @@ public function getCacheBehavior() * * @param boolean $cacheBehavior */ - public function setCacheBehavior($cacheBehavior) + public function setCacheBehavior(bool $cacheBehavior) { $this->set("CacheBehavior", $cacheBehavior); } - /** * HttpCodePattern: 状态码模式,非200,206状态码,多个状态码用竖线(|)分隔,该属性仅仅在状态码缓存配置列表中返回 * @@ -117,11 +121,10 @@ public function getHttpCodePattern() * * @param string $httpCodePattern */ - public function setHttpCodePattern($httpCodePattern) + public function setHttpCodePattern(string $httpCodePattern) { $this->set("HttpCodePattern", $httpCodePattern); } - /** * Description: 缓存规则描述 * @@ -137,11 +140,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * FollowOriginRule: 是否优先遵循源站头部缓存策略,false为不优先遵循源站,true为优先遵循源站缓存头部。默认为0 * @@ -157,7 +159,7 @@ public function getFollowOriginRule() * * @param boolean $followOriginRule */ - public function setFollowOriginRule($followOriginRule) + public function setFollowOriginRule(bool $followOriginRule) { $this->set("FollowOriginRule", $followOriginRule); } diff --git a/src/UCDN/Models/CacheKeyInfo.php b/src/UCDN/Models/CacheKeyInfo.php index 67d315d2..b95cf3c9 100644 --- a/src/UCDN/Models/CacheKeyInfo.php +++ b/src/UCDN/Models/CacheKeyInfo.php @@ -1,6 +1,7 @@ set("Ignore", $ignore); } - /** * PathPattern: 路径模式,支持正则 * @@ -57,11 +62,10 @@ public function getPathPattern() * * @param string $pathPattern */ - public function setPathPattern($pathPattern) + public function setPathPattern(string $pathPattern) { $this->set("PathPattern", $pathPattern); } - /** * QueryString: 自定义变量,以$符号开头,多个变量用加号(+)连接,$querystring表示所有变量 * @@ -77,7 +81,7 @@ public function getQueryString() * * @param string $queryString */ - public function setQueryString($queryString) + public function setQueryString(string $queryString) { $this->set("QueryString", $queryString); } diff --git a/src/UCDN/Models/CertList.php b/src/UCDN/Models/CertList.php index 5649f3bd..65cdf2e0 100644 --- a/src/UCDN/Models/CertList.php +++ b/src/UCDN/Models/CertList.php @@ -1,6 +1,7 @@ set("CertName", $certName); } - /** * CommonName: 通用名 * @@ -57,11 +60,10 @@ public function getCommonName() * * @param string $commonName */ - public function setCommonName($commonName) + public function setCommonName(string $commonName) { $this->set("CommonName", $commonName); } - /** * DnsName: dns名称 * @@ -77,11 +79,10 @@ public function getDnsName() * * @param string $dnsName */ - public function setDnsName($dnsName) + public function setDnsName(string $dnsName) { $this->set("DnsName", $dnsName); } - /** * BeginTime: 证书开始时间 * @@ -97,11 +98,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 证书获取时间 * @@ -117,11 +117,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * DomainCount: 已配置域名个数 * @@ -137,11 +136,10 @@ public function getDomainCount() * * @param int $domainCount */ - public function setDomainCount($domainCount) + public function setDomainCount(int $domainCount) { $this->set("DomainCount", $domainCount); } - /** * UserCert: 证书内容 * @@ -157,11 +155,10 @@ public function getUserCert() * * @param string $userCert */ - public function setUserCert($userCert) + public function setUserCert(string $userCert) { $this->set("UserCert", $userCert); } - /** * CaCert: ca证内容 * @@ -177,11 +174,10 @@ public function getCaCert() * * @param string $caCert */ - public function setCaCert($caCert) + public function setCaCert(string $caCert) { $this->set("CaCert", $caCert); } - /** * Domains: 已配置的域名列表 * diff --git a/src/UCDN/Models/DomainBaseInfo.php b/src/UCDN/Models/DomainBaseInfo.php index ed1bbda1..c3ab1a92 100644 --- a/src/UCDN/Models/DomainBaseInfo.php +++ b/src/UCDN/Models/DomainBaseInfo.php @@ -1,6 +1,7 @@ set("Domain", $domain); } - /** * DomainId: 域名的资源id * @@ -57,7 +59,7 @@ public function getDomainId() * * @param string $domainId */ - public function setDomainId($domainId) + public function setDomainId(string $domainId) { $this->set("DomainId", $domainId); } diff --git a/src/UCDN/Models/DomainConfigInfo.php b/src/UCDN/Models/DomainConfigInfo.php index ae655eee..05d9f548 100644 --- a/src/UCDN/Models/DomainConfigInfo.php +++ b/src/UCDN/Models/DomainConfigInfo.php @@ -1,6 +1,7 @@ set("AreaCode", $areaCode); } - /** * CdnType: 加速域名的业务类型,web代表网站,stream代表视频 ,download 代表下载 * @@ -57,11 +67,10 @@ public function getCdnType() * * @param string $cdnType */ - public function setCdnType($cdnType) + public function setCdnType(string $cdnType) { $this->set("CdnType", $cdnType); } - /** * Status: 创建的加速域名的当前的状态。check代表审核中,checkSuccess代表审核通过,checkFail代表审核失败,enable代表加速中,disable代表停止加速,delete代表删除加速enableing代表正在开启加速,disableing代表正在停止加速中,deleteing代表删除中 * @@ -77,11 +86,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * Cname: cdn域名。创建加速域名生成的cdn域名,用于设置CNAME记录 * @@ -97,11 +105,10 @@ public function getCname() * * @param string $cname */ - public function setCname($cname) + public function setCname(string $cname) { $this->set("Cname", $cname); } - /** * CreateTime: 域名创建的时间。格式:时间戳 * @@ -117,11 +124,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * TestUrl: 测试url。用于域名创建加速时的测试 * @@ -137,11 +143,10 @@ public function getTestUrl() * * @param string $testUrl */ - public function setTestUrl($testUrl) + public function setTestUrl(string $testUrl) { $this->set("TestUrl", $testUrl); } - /** * HttpsStatusCn: 国内https状态 enableing-开启中 fail-开启失败 enable-启用 disable-未启用 * @@ -157,11 +162,10 @@ public function getHttpsStatusCn() * * @param string $httpsStatusCn */ - public function setHttpsStatusCn($httpsStatusCn) + public function setHttpsStatusCn(string $httpsStatusCn) { $this->set("HttpsStatusCn", $httpsStatusCn); } - /** * HttpsStatusAbroad: 国外https状态 enableing-开启中 fail-开启失败 enable-启用 disable-未启用 * @@ -177,11 +181,10 @@ public function getHttpsStatusAbroad() * * @param string $httpsStatusAbroad */ - public function setHttpsStatusAbroad($httpsStatusAbroad) + public function setHttpsStatusAbroad(string $httpsStatusAbroad) { $this->set("HttpsStatusAbroad", $httpsStatusAbroad); } - /** * CertNameCn: 国内证书名称 * @@ -197,11 +200,10 @@ public function getCertNameCn() * * @param string $certNameCn */ - public function setCertNameCn($certNameCn) + public function setCertNameCn(string $certNameCn) { $this->set("CertNameCn", $certNameCn); } - /** * CertNameAbroad: 国外证书名称 * @@ -217,11 +219,10 @@ public function getCertNameAbroad() * * @param string $certNameAbroad */ - public function setCertNameAbroad($certNameAbroad) + public function setCertNameAbroad(string $certNameAbroad) { $this->set("CertNameAbroad", $certNameAbroad); } - /** * Tag: 业务组:Default * @@ -237,11 +238,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * DomainId: 域名Id * @@ -257,11 +257,10 @@ public function getDomainId() * * @param string $domainId */ - public function setDomainId($domainId) + public function setDomainId(string $domainId) { $this->set("DomainId", $domainId); } - /** * Domain: 域名 * @@ -277,87 +276,83 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * OriginConf: 源站配置 参考OriginConf * - * @return OriginConf|null + * @return OriginConfModel|null */ public function getOriginConf() { - return new OriginConf($this->get("OriginConf")); + return new OriginConfModel($this->get("OriginConf")); } /** * OriginConf: 源站配置 参考OriginConf * - * @param OriginConf $originConf + * @param OriginConfModel $originConf */ - public function setOriginConf(array $originConf) + public function setOriginConf(OriginConfModel $originConf) { $this->set("OriginConf", $originConf->getAll()); } - /** * AccessControlConf: 访问控制配置 参考AccessControlConf * - * @return AccessControlConf|null + * @return AccessControlConfModel|null */ public function getAccessControlConf() { - return new AccessControlConf($this->get("AccessControlConf")); + return new AccessControlConfModel($this->get("AccessControlConf")); } /** * AccessControlConf: 访问控制配置 参考AccessControlConf * - * @param AccessControlConf $accessControlConf + * @param AccessControlConfModel $accessControlConf */ - public function setAccessControlConf(array $accessControlConf) + public function setAccessControlConf(AccessControlConfModel $accessControlConf) { $this->set("AccessControlConf", $accessControlConf->getAll()); } - /** * CacheConf: 缓存配置 参考CacheAllConfig * - * @return CacheAllConfig|null + * @return CacheAllConfigModel|null */ public function getCacheConf() { - return new CacheAllConfig($this->get("CacheConf")); + return new CacheAllConfigModel($this->get("CacheConf")); } /** * CacheConf: 缓存配置 参考CacheAllConfig * - * @param CacheAllConfig $cacheConf + * @param CacheAllConfigModel $cacheConf */ - public function setCacheConf(array $cacheConf) + public function setCacheConf(CacheAllConfigModel $cacheConf) { $this->set("CacheConf", $cacheConf->getAll()); } - /** * AdvancedConf: 高级配置 参考AdvancedConf * - * @return AdvancedConf|null + * @return AdvancedConfModel|null */ public function getAdvancedConf() { - return new AdvancedConf($this->get("AdvancedConf")); + return new AdvancedConfModel($this->get("AdvancedConf")); } /** * AdvancedConf: 高级配置 参考AdvancedConf * - * @param AdvancedConf $advancedConf + * @param AdvancedConfModel $advancedConf */ - public function setAdvancedConf(array $advancedConf) + public function setAdvancedConf(AdvancedConfModel $advancedConf) { $this->set("AdvancedConf", $advancedConf->getAll()); } diff --git a/src/UCDN/Apis/GetUcdnDomainTrafficResponse.php b/src/UCDN/Models/DomanLogList.php similarity index 51% rename from src/UCDN/Apis/GetUcdnDomainTrafficResponse.php rename to src/UCDN/Models/DomanLogList.php index a3d47265..9ed5d2ae 100644 --- a/src/UCDN/Apis/GetUcdnDomainTrafficResponse.php +++ b/src/UCDN/Models/DomanLogList.php @@ -1,6 +1,7 @@ get("Domain"); + } + + /** + * Domain: 域名 + * + * @param string $domain + */ + public function setDomain(string $domain) + { + $this->set("Domain", $domain); + } + /** + * LogList: 日志信息列表 * - * @return UcdnDomainTrafficSet[]|null + * @return LogInfoModel[]|null */ - public function getTrafficSet() + public function getLogList() { - $items = $this->get("TrafficSet"); + $items = $this->get("LogList"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new UcdnDomainTrafficSet($item)); + array_push($result, new LogInfoModel($item)); } return $result; } /** - * TrafficSet: 流量实例表,具体结构见 UcdnDomainTrafficSet + * LogList: 日志信息列表 * - * @param UcdnDomainTrafficSet[] $trafficSet + * @param LogInfoModel[] $logList */ - public function setTrafficSet(array $trafficSet) + public function setLogList(array $logList) { $result = []; - foreach ($trafficSet as $i => $item) { + foreach ($logList as $i => $item) { array_push($result, $item->getAll()); } return $result; diff --git a/src/UCDN/Models/DownloadStatisticInfo.php b/src/UCDN/Models/DownloadStatisticInfo.php new file mode 100644 index 00000000..2f05d3f8 --- /dev/null +++ b/src/UCDN/Models/DownloadStatisticInfo.php @@ -0,0 +1,105 @@ +get("Url"); + } + + /** + * Url: 下载链接的url + * + * @param string $url + */ + public function setUrl(string $url) + { + $this->set("Url", $url); + } + /** + * Traffic: 流量(单位为G) + * + * @return float|null + */ + public function getTraffic() + { + return $this->get("Traffic"); + } + + /** + * Traffic: 流量(单位为G) + * + * @param float $traffic + */ + public function setTraffic(float $traffic) + { + $this->set("Traffic", $traffic); + } + /** + * DownloadTimes: 下载次数 + * + * @return integer|null + */ + public function getDownloadTimes() + { + return $this->get("DownloadTimes"); + } + + /** + * DownloadTimes: 下载次数 + * + * @param int $downloadTimes + */ + public function setDownloadTimes(int $downloadTimes) + { + $this->set("DownloadTimes", $downloadTimes); + } + /** + * Percent: 流量占比,单位% + * + * @return float|null + */ + public function getPercent() + { + return $this->get("Percent"); + } + + /** + * Percent: 流量占比,单位% + * + * @param float $percent + */ + public function setPercent(float $percent) + { + $this->set("Percent", $percent); + } +} diff --git a/src/UCDN/Models/HitRateInfo.php b/src/UCDN/Models/HitRateInfo.php index 534011d2..b7c84da5 100644 --- a/src/UCDN/Models/HitRateInfo.php +++ b/src/UCDN/Models/HitRateInfo.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * FlowHitRate: 总流量命中率,单位% * @@ -57,11 +59,10 @@ public function getFlowHitRate() * * @param float $flowHitRate */ - public function setFlowHitRate($flowHitRate) + public function setFlowHitRate(float $flowHitRate) { $this->set("FlowHitRate", $flowHitRate); } - /** * RequestHitRate: 请求数命中率,单位% * @@ -77,7 +78,7 @@ public function getRequestHitRate() * * @param float $requestHitRate */ - public function setRequestHitRate($requestHitRate) + public function setRequestHitRate(float $requestHitRate) { $this->set("RequestHitRate", $requestHitRate); } diff --git a/src/UCDN/Models/HitRateInfoV2.php b/src/UCDN/Models/HitRateInfoV2.php index 8ea42ef9..1d65e488 100644 --- a/src/UCDN/Models/HitRateInfoV2.php +++ b/src/UCDN/Models/HitRateInfoV2.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * FlowHitRate: 总流量命中率,单位% * @@ -57,11 +59,10 @@ public function getFlowHitRate() * * @param float $flowHitRate */ - public function setFlowHitRate($flowHitRate) + public function setFlowHitRate(float $flowHitRate) { $this->set("FlowHitRate", $flowHitRate); } - /** * RequestHitRate: 请求数命中率,单位% * @@ -77,7 +78,7 @@ public function getRequestHitRate() * * @param float $requestHitRate */ - public function setRequestHitRate($requestHitRate) + public function setRequestHitRate(float $requestHitRate) { $this->set("RequestHitRate", $requestHitRate); } diff --git a/src/UCDN/Models/HttpCodeInfo.php b/src/UCDN/Models/HttpCodeInfo.php index 1d6b2d09..eac8d9f3 100644 --- a/src/UCDN/Models/HttpCodeInfo.php +++ b/src/UCDN/Models/HttpCodeInfo.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * HttpOneXX: 1xx数量 * @@ -57,11 +60,10 @@ public function getHttpOneXX() * * @param int $httpOneXX */ - public function setHttpOneXX($httpOneXX) + public function setHttpOneXX(int $httpOneXX) { $this->set("HttpOneXX", $httpOneXX); } - /** * HttpTwoXX: 2xx数量 * @@ -77,11 +79,10 @@ public function getHttpTwoXX() * * @param int $httpTwoXX */ - public function setHttpTwoXX($httpTwoXX) + public function setHttpTwoXX(int $httpTwoXX) { $this->set("HttpTwoXX", $httpTwoXX); } - /** * HttpThreeXX: 3xx数量 * @@ -97,11 +98,10 @@ public function getHttpThreeXX() * * @param int $httpThreeXX */ - public function setHttpThreeXX($httpThreeXX) + public function setHttpThreeXX(int $httpThreeXX) { $this->set("HttpThreeXX", $httpThreeXX); } - /** * HttpFourXX: 4xx数量 * @@ -117,11 +117,10 @@ public function getHttpFourXX() * * @param int $httpFourXX */ - public function setHttpFourXX($httpFourXX) + public function setHttpFourXX(int $httpFourXX) { $this->set("HttpFourXX", $httpFourXX); } - /** * HttpFiveXX: 5xx数量 * @@ -137,7 +136,7 @@ public function getHttpFiveXX() * * @param int $httpFiveXX */ - public function setHttpFiveXX($httpFiveXX) + public function setHttpFiveXX(int $httpFiveXX) { $this->set("HttpFiveXX", $httpFiveXX); } diff --git a/src/UCDN/Models/HttpCodeInfoV2.php b/src/UCDN/Models/HttpCodeInfoV2.php index a845dedc..7a28e868 100644 --- a/src/UCDN/Models/HttpCodeInfoV2.php +++ b/src/UCDN/Models/HttpCodeInfoV2.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * Http1XX: 1xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp1XX() { - return new HttpCodeV2Detail($this->get("Http1XX")); + return new HttpCodeV2DetailModel($this->get("Http1XX")); } /** * Http1XX: 1xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http1XX + * @param HttpCodeV2DetailModel $http1XX */ - public function setHttp1XX(array $http1XX) + public function setHttp1XX(HttpCodeV2DetailModel $http1XX) { $this->set("Http1XX", $http1XX->getAll()); } - /** * Http2XX: 2xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp2XX() { - return new HttpCodeV2Detail($this->get("Http2XX")); + return new HttpCodeV2DetailModel($this->get("Http2XX")); } /** * Http2XX: 2xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http2XX + * @param HttpCodeV2DetailModel $http2XX */ - public function setHttp2XX(array $http2XX) + public function setHttp2XX(HttpCodeV2DetailModel $http2XX) { $this->set("Http2XX", $http2XX->getAll()); } - /** * Http3XX: 3xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp3XX() { - return new HttpCodeV2Detail($this->get("Http3XX")); + return new HttpCodeV2DetailModel($this->get("Http3XX")); } /** * Http3XX: 3xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http3XX + * @param HttpCodeV2DetailModel $http3XX */ - public function setHttp3XX(array $http3XX) + public function setHttp3XX(HttpCodeV2DetailModel $http3XX) { $this->set("Http3XX", $http3XX->getAll()); } - /** * Http4XX: 4xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp4XX() { - return new HttpCodeV2Detail($this->get("Http4XX")); + return new HttpCodeV2DetailModel($this->get("Http4XX")); } /** * Http4XX: 4xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http4XX + * @param HttpCodeV2DetailModel $http4XX */ - public function setHttp4XX(array $http4XX) + public function setHttp4XX(HttpCodeV2DetailModel $http4XX) { $this->set("Http4XX", $http4XX->getAll()); } - /** * Http5XX: 5xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp5XX() { - return new HttpCodeV2Detail($this->get("Http5XX")); + return new HttpCodeV2DetailModel($this->get("Http5XX")); } /** * Http5XX: 5xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http5XX + * @param HttpCodeV2DetailModel $http5XX */ - public function setHttp5XX(array $http5XX) + public function setHttp5XX(HttpCodeV2DetailModel $http5XX) { $this->set("Http5XX", $http5XX->getAll()); } - /** * Http6XX: 6xx信息,参考HttpCodeV2Detail结构 * - * @return HttpCodeV2Detail|null + * @return HttpCodeV2DetailModel|null */ public function getHttp6XX() { - return new HttpCodeV2Detail($this->get("Http6XX")); + return new HttpCodeV2DetailModel($this->get("Http6XX")); } /** * Http6XX: 6xx信息,参考HttpCodeV2Detail结构 * - * @param HttpCodeV2Detail $http6XX + * @param HttpCodeV2DetailModel $http6XX */ - public function setHttp6XX(array $http6XX) + public function setHttp6XX(HttpCodeV2DetailModel $http6XX) { $this->set("Http6XX", $http6XX->getAll()); } diff --git a/src/UCDN/Models/HttpCodeV2Detail.php b/src/UCDN/Models/HttpCodeV2Detail.php index 7d652440..39dfcca0 100644 --- a/src/UCDN/Models/HttpCodeV2Detail.php +++ b/src/UCDN/Models/HttpCodeV2Detail.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * Total: 当前分组的总状态码数 * @@ -57,11 +62,10 @@ public function getTotal() * * @param int $total */ - public function setTotal($total) + public function setTotal(int $total) { $this->set("Total", $total); } - /** * Http100: http100数量 * @@ -77,11 +81,10 @@ public function getHttp100() * * @param int $http100 */ - public function setHttp100($http100) + public function setHttp100(int $http100) { $this->set("Http100", $http100); } - /** * Http101: http101数量 * @@ -97,11 +100,10 @@ public function getHttp101() * * @param int $http101 */ - public function setHttp101($http101) + public function setHttp101(int $http101) { $this->set("Http101", $http101); } - /** * Http102: http102数量 * @@ -117,11 +119,10 @@ public function getHttp102() * * @param int $http102 */ - public function setHttp102($http102) + public function setHttp102(int $http102) { $this->set("Http102", $http102); } - /** * Http200: http200数量 * @@ -137,11 +138,10 @@ public function getHttp200() * * @param int $http200 */ - public function setHttp200($http200) + public function setHttp200(int $http200) { $this->set("Http200", $http200); } - /** * Http201: http201数量 * @@ -157,11 +157,10 @@ public function getHttp201() * * @param int $http201 */ - public function setHttp201($http201) + public function setHttp201(int $http201) { $this->set("Http201", $http201); } - /** * Http202: http202数量 * @@ -177,11 +176,10 @@ public function getHttp202() * * @param int $http202 */ - public function setHttp202($http202) + public function setHttp202(int $http202) { $this->set("Http202", $http202); } - /** * Http203: http203数量 * @@ -197,11 +195,10 @@ public function getHttp203() * * @param int $http203 */ - public function setHttp203($http203) + public function setHttp203(int $http203) { $this->set("Http203", $http203); } - /** * Http204: http204数量 * @@ -217,11 +214,10 @@ public function getHttp204() * * @param int $http204 */ - public function setHttp204($http204) + public function setHttp204(int $http204) { $this->set("Http204", $http204); } - /** * Http205: http205数量 * @@ -237,11 +233,10 @@ public function getHttp205() * * @param int $http205 */ - public function setHttp205($http205) + public function setHttp205(int $http205) { $this->set("Http205", $http205); } - /** * Http206: http206数量 * @@ -257,11 +252,10 @@ public function getHttp206() * * @param int $http206 */ - public function setHttp206($http206) + public function setHttp206(int $http206) { $this->set("Http206", $http206); } - /** * Http207: http207数量 * @@ -277,11 +271,10 @@ public function getHttp207() * * @param int $http207 */ - public function setHttp207($http207) + public function setHttp207(int $http207) { $this->set("Http207", $http207); } - /** * Http300: http300数量 * @@ -297,11 +290,10 @@ public function getHttp300() * * @param int $http300 */ - public function setHttp300($http300) + public function setHttp300(int $http300) { $this->set("Http300", $http300); } - /** * Http301: http301数量 * @@ -317,11 +309,10 @@ public function getHttp301() * * @param int $http301 */ - public function setHttp301($http301) + public function setHttp301(int $http301) { $this->set("Http301", $http301); } - /** * Http302: http302数量 * @@ -337,11 +328,10 @@ public function getHttp302() * * @param int $http302 */ - public function setHttp302($http302) + public function setHttp302(int $http302) { $this->set("Http302", $http302); } - /** * Http303: http303数量 * @@ -357,11 +347,10 @@ public function getHttp303() * * @param int $http303 */ - public function setHttp303($http303) + public function setHttp303(int $http303) { $this->set("Http303", $http303); } - /** * Http304: http304数量 * @@ -377,11 +366,10 @@ public function getHttp304() * * @param int $http304 */ - public function setHttp304($http304) + public function setHttp304(int $http304) { $this->set("Http304", $http304); } - /** * Http305: http305数量 * @@ -397,11 +385,10 @@ public function getHttp305() * * @param int $http305 */ - public function setHttp305($http305) + public function setHttp305(int $http305) { $this->set("Http305", $http305); } - /** * Http306: http306数量 * @@ -417,11 +404,10 @@ public function getHttp306() * * @param int $http306 */ - public function setHttp306($http306) + public function setHttp306(int $http306) { $this->set("Http306", $http306); } - /** * Http307: http307数量 * @@ -437,11 +423,10 @@ public function getHttp307() * * @param int $http307 */ - public function setHttp307($http307) + public function setHttp307(int $http307) { $this->set("Http307", $http307); } - /** * Http400: http400数量 * @@ -457,11 +442,10 @@ public function getHttp400() * * @param int $http400 */ - public function setHttp400($http400) + public function setHttp400(int $http400) { $this->set("Http400", $http400); } - /** * Http401: http401数量 * @@ -477,11 +461,10 @@ public function getHttp401() * * @param int $http401 */ - public function setHttp401($http401) + public function setHttp401(int $http401) { $this->set("Http401", $http401); } - /** * Http402: http402数量 * @@ -497,11 +480,10 @@ public function getHttp402() * * @param int $http402 */ - public function setHttp402($http402) + public function setHttp402(int $http402) { $this->set("Http402", $http402); } - /** * Http403: http403数量 * @@ -517,11 +499,10 @@ public function getHttp403() * * @param int $http403 */ - public function setHttp403($http403) + public function setHttp403(int $http403) { $this->set("Http403", $http403); } - /** * Http404: http404数量 * @@ -537,11 +518,10 @@ public function getHttp404() * * @param int $http404 */ - public function setHttp404($http404) + public function setHttp404(int $http404) { $this->set("Http404", $http404); } - /** * Http405: http405数量 * @@ -557,11 +537,10 @@ public function getHttp405() * * @param int $http405 */ - public function setHttp405($http405) + public function setHttp405(int $http405) { $this->set("Http405", $http405); } - /** * Http406: http406数量 * @@ -577,11 +556,10 @@ public function getHttp406() * * @param int $http406 */ - public function setHttp406($http406) + public function setHttp406(int $http406) { $this->set("Http406", $http406); } - /** * Http407: http407数量 * @@ -597,11 +575,10 @@ public function getHttp407() * * @param int $http407 */ - public function setHttp407($http407) + public function setHttp407(int $http407) { $this->set("Http407", $http407); } - /** * Http408: http408数量 * @@ -617,11 +594,10 @@ public function getHttp408() * * @param int $http408 */ - public function setHttp408($http408) + public function setHttp408(int $http408) { $this->set("Http408", $http408); } - /** * Http409: http409数量 * @@ -637,11 +613,10 @@ public function getHttp409() * * @param int $http409 */ - public function setHttp409($http409) + public function setHttp409(int $http409) { $this->set("Http409", $http409); } - /** * Http410: http410数量 * @@ -657,11 +632,10 @@ public function getHttp410() * * @param int $http410 */ - public function setHttp410($http410) + public function setHttp410(int $http410) { $this->set("Http410", $http410); } - /** * Http411: http411数量 * @@ -677,11 +651,10 @@ public function getHttp411() * * @param int $http411 */ - public function setHttp411($http411) + public function setHttp411(int $http411) { $this->set("Http411", $http411); } - /** * Http412: http412数量 * @@ -697,11 +670,10 @@ public function getHttp412() * * @param int $http412 */ - public function setHttp412($http412) + public function setHttp412(int $http412) { $this->set("Http412", $http412); } - /** * Http413: http413数量 * @@ -717,11 +689,10 @@ public function getHttp413() * * @param int $http413 */ - public function setHttp413($http413) + public function setHttp413(int $http413) { $this->set("Http413", $http413); } - /** * Http414: http414数量 * @@ -737,11 +708,10 @@ public function getHttp414() * * @param int $http414 */ - public function setHttp414($http414) + public function setHttp414(int $http414) { $this->set("Http414", $http414); } - /** * Http415: http415数量 * @@ -757,11 +727,10 @@ public function getHttp415() * * @param int $http415 */ - public function setHttp415($http415) + public function setHttp415(int $http415) { $this->set("Http415", $http415); } - /** * Http416: http416数量 * @@ -777,11 +746,10 @@ public function getHttp416() * * @param int $http416 */ - public function setHttp416($http416) + public function setHttp416(int $http416) { $this->set("Http416", $http416); } - /** * Http417: http417数量 * @@ -797,11 +765,10 @@ public function getHttp417() * * @param int $http417 */ - public function setHttp417($http417) + public function setHttp417(int $http417) { $this->set("Http417", $http417); } - /** * Http418: http418数量 * @@ -817,11 +784,10 @@ public function getHttp418() * * @param int $http418 */ - public function setHttp418($http418) + public function setHttp418(int $http418) { $this->set("Http418", $http418); } - /** * Http421: http421数量 * @@ -837,11 +803,10 @@ public function getHttp421() * * @param int $http421 */ - public function setHttp421($http421) + public function setHttp421(int $http421) { $this->set("Http421", $http421); } - /** * Http422: http422数量 * @@ -857,11 +822,10 @@ public function getHttp422() * * @param int $http422 */ - public function setHttp422($http422) + public function setHttp422(int $http422) { $this->set("Http422", $http422); } - /** * Http423: http423数量 * @@ -877,11 +841,10 @@ public function getHttp423() * * @param int $http423 */ - public function setHttp423($http423) + public function setHttp423(int $http423) { $this->set("Http423", $http423); } - /** * Http424: http424数量 * @@ -897,11 +860,10 @@ public function getHttp424() * * @param int $http424 */ - public function setHttp424($http424) + public function setHttp424(int $http424) { $this->set("Http424", $http424); } - /** * Http425: http425数量 * @@ -917,11 +879,10 @@ public function getHttp425() * * @param int $http425 */ - public function setHttp425($http425) + public function setHttp425(int $http425) { $this->set("Http425", $http425); } - /** * Http426: http426数量 * @@ -937,11 +898,10 @@ public function getHttp426() * * @param int $http426 */ - public function setHttp426($http426) + public function setHttp426(int $http426) { $this->set("Http426", $http426); } - /** * Http449: http449数量 * @@ -957,11 +917,10 @@ public function getHttp449() * * @param int $http449 */ - public function setHttp449($http449) + public function setHttp449(int $http449) { $this->set("Http449", $http449); } - /** * Http451: http451数量 * @@ -977,11 +936,10 @@ public function getHttp451() * * @param int $http451 */ - public function setHttp451($http451) + public function setHttp451(int $http451) { $this->set("Http451", $http451); } - /** * Http500: http500数量 * @@ -997,11 +955,10 @@ public function getHttp500() * * @param int $http500 */ - public function setHttp500($http500) + public function setHttp500(int $http500) { $this->set("Http500", $http500); } - /** * Http501: http501数量 * @@ -1017,11 +974,10 @@ public function getHttp501() * * @param int $http501 */ - public function setHttp501($http501) + public function setHttp501(int $http501) { $this->set("Http501", $http501); } - /** * Http502: http502数量 * @@ -1037,11 +993,10 @@ public function getHttp502() * * @param int $http502 */ - public function setHttp502($http502) + public function setHttp502(int $http502) { $this->set("Http502", $http502); } - /** * Http503: http503数量 * @@ -1057,11 +1012,10 @@ public function getHttp503() * * @param int $http503 */ - public function setHttp503($http503) + public function setHttp503(int $http503) { $this->set("Http503", $http503); } - /** * Http504: http504数量 * @@ -1077,11 +1031,10 @@ public function getHttp504() * * @param int $http504 */ - public function setHttp504($http504) + public function setHttp504(int $http504) { $this->set("Http504", $http504); } - /** * Http505: http505数量 * @@ -1097,11 +1050,10 @@ public function getHttp505() * * @param int $http505 */ - public function setHttp505($http505) + public function setHttp505(int $http505) { $this->set("Http505", $http505); } - /** * Http506: http506数量 * @@ -1117,11 +1069,10 @@ public function getHttp506() * * @param int $http506 */ - public function setHttp506($http506) + public function setHttp506(int $http506) { $this->set("Http506", $http506); } - /** * Http507: http507数量 * @@ -1137,11 +1088,10 @@ public function getHttp507() * * @param int $http507 */ - public function setHttp507($http507) + public function setHttp507(int $http507) { $this->set("Http507", $http507); } - /** * Http509: http509数量 * @@ -1157,11 +1107,10 @@ public function getHttp509() * * @param int $http509 */ - public function setHttp509($http509) + public function setHttp509(int $http509) { $this->set("Http509", $http509); } - /** * Http510: http510数量 * @@ -1177,7 +1126,7 @@ public function getHttp510() * * @param int $http510 */ - public function setHttp510($http510) + public function setHttp510(int $http510) { $this->set("Http510", $http510); } diff --git a/src/UCDN/Models/IpLocationInfo.php b/src/UCDN/Models/IpLocationInfo.php index edfbe573..b7fc5ec0 100644 --- a/src/UCDN/Models/IpLocationInfo.php +++ b/src/UCDN/Models/IpLocationInfo.php @@ -1,6 +1,7 @@ set("Ip", $ip); } - /** * Area: 地区 * @@ -57,11 +59,10 @@ public function getArea() * * @param string $area */ - public function setArea($area) + public function setArea(string $area) { $this->set("Area", $area); } - /** * Isp: 运营商 * @@ -77,11 +78,10 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } - /** * City: 城市 * @@ -97,11 +97,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * Exist: ip是否存在 * @@ -117,7 +116,7 @@ public function getExist() * * @param boolean $exist */ - public function setExist($exist) + public function setExist(bool $exist) { $this->set("Exist", $exist); } diff --git a/src/UCDN/Models/LogInfo.php b/src/UCDN/Models/LogInfo.php new file mode 100644 index 00000000..6a6940b2 --- /dev/null +++ b/src/UCDN/Models/LogInfo.php @@ -0,0 +1,67 @@ +get("LogTime"); + } + + /** + * LogTime: Unix时间戳 + * + * @param int $logTime + */ + public function setLogTime(int $logTime) + { + $this->set("LogTime", $logTime); + } + /** + * LogUrl: 日志url地址 + * + * @return string|null + */ + public function getLogUrl() + { + return $this->get("LogUrl"); + } + + /** + * LogUrl: 日志url地址 + * + * @param string $logUrl + */ + public function setLogUrl(string $logUrl) + { + $this->set("LogUrl", $logUrl); + } +} diff --git a/src/UCDN/Models/LogSetInfo.php b/src/UCDN/Models/LogSetInfo.php index 69b0bfff..09383cf0 100644 --- a/src/UCDN/Models/LogSetInfo.php +++ b/src/UCDN/Models/LogSetInfo.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CnLog: 国内日志url列表 * @@ -61,7 +64,6 @@ public function setCnLog(array $cnLog) { $this->set("CnLog", $cnLog); } - /** * AbroadLog: 国外日志url列表 * diff --git a/src/UCDN/Models/LogSetList.php b/src/UCDN/Models/LogSetList.php index c15a4197..9c60c99d 100644 --- a/src/UCDN/Models/LogSetList.php +++ b/src/UCDN/Models/LogSetList.php @@ -1,6 +1,7 @@ set("Domain", $domain); } - /** * Logs: 域名信息列表,参考LogSetInfo * - * @return LogSetInfo[]|null + * @return LogSetInfoModel[]|null */ public function getLogs() { @@ -55,7 +58,7 @@ public function getLogs() } $result = []; foreach ($items as $i => $item) { - array_push($result, new LogSetInfo($item)); + array_push($result, new LogSetInfoModel($item)); } return $result; } @@ -63,7 +66,7 @@ public function getLogs() /** * Logs: 域名信息列表,参考LogSetInfo * - * @param LogSetInfo[] $logs + * @param LogSetInfoModel[] $logs */ public function setLogs(array $logs) { diff --git a/src/UCDN/Models/OriginConf.php b/src/UCDN/Models/OriginConf.php index aada0f2a..f0bc6944 100644 --- a/src/UCDN/Models/OriginConf.php +++ b/src/UCDN/Models/OriginConf.php @@ -1,6 +1,7 @@ set("OriginIpList", $originIpList); } - /** * OriginHost: 回源Http请求头部Host,默认是加速域名 * @@ -57,11 +61,10 @@ public function getOriginHost() * * @param string $originHost */ - public function setOriginHost($originHost) + public function setOriginHost(string $originHost) { $this->set("OriginHost", $originHost); } - /** * OriginPort: 回源端口 * @@ -77,11 +80,10 @@ public function getOriginPort() * * @param int $originPort */ - public function setOriginPort($originPort) + public function setOriginPort(int $originPort) { $this->set("OriginPort", $originPort); } - /** * BackupOriginEnable: 1如果为false表示BackupOriginIp为空,表示没有备份源站,忽略BackupOriginIp,BackupOriginHost字段2如果为true表示BackupOriginIp.n必须至少有一个备份源站地址 * @@ -97,11 +99,10 @@ public function getBackupOriginEnable() * * @param boolean $backupOriginEnable */ - public function setBackupOriginEnable($backupOriginEnable) + public function setBackupOriginEnable(bool $backupOriginEnable) { $this->set("BackupOriginEnable", $backupOriginEnable); } - /** * BackupOriginIpList: 备份源站ip即cdn服务器回源访问的ip地址。多个源站ip,可以这样表述,如:["1.1.1.1","2.2.2.2"] * @@ -121,7 +122,6 @@ public function setBackupOriginIpList(array $backupOriginIpList) { $this->set("BackupOriginIpList", $backupOriginIpList); } - /** * BackupOriginHost: 备份回源Http请求头部Host,默认是加速域名 * @@ -137,11 +137,10 @@ public function getBackupOriginHost() * * @param string $backupOriginHost */ - public function setBackupOriginHost($backupOriginHost) + public function setBackupOriginHost(string $backupOriginHost) { $this->set("BackupOriginHost", $backupOriginHost); } - /** * OriginErrorCode: 主源响应的回源错误码(如:404|500),默认空字符串 * @@ -157,11 +156,10 @@ public function getOriginErrorCode() * * @param string $originErrorCode */ - public function setOriginErrorCode($originErrorCode) + public function setOriginErrorCode(string $originErrorCode) { $this->set("OriginErrorCode", $originErrorCode); } - /** * OriginErrorNum: 回主源的回源失败数,默认1 * @@ -177,11 +175,10 @@ public function getOriginErrorNum() * * @param int $originErrorNum */ - public function setOriginErrorNum($originErrorNum) + public function setOriginErrorNum(int $originErrorNum) { $this->set("OriginErrorNum", $originErrorNum); } - /** * OriginProtocol: 源站协议http,http|https 默认http * @@ -197,11 +194,10 @@ public function getOriginProtocol() * * @param string $originProtocol */ - public function setOriginProtocol($originProtocol) + public function setOriginProtocol(string $originProtocol) { $this->set("OriginProtocol", $originProtocol); } - /** * OriginFollow301: 跟随301跳转 0=不跟随 1=跟随 * @@ -217,7 +213,7 @@ public function getOriginFollow301() * * @param int $originFollow301 */ - public function setOriginFollow301($originFollow301) + public function setOriginFollow301(int $originFollow301) { $this->set("OriginFollow301", $originFollow301); } diff --git a/src/UCDN/Models/ProIspBandwidthList.php b/src/UCDN/Models/ProIspBandwidthList.php index cb1d4521..c8cf75f9 100644 --- a/src/UCDN/Models/ProIspBandwidthList.php +++ b/src/UCDN/Models/ProIspBandwidthList.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CdnBandwidth: 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps * @@ -57,11 +66,10 @@ public function getCdnBandwidth() * * @param float $cdnBandwidth */ - public function setCdnBandwidth($cdnBandwidth) + public function setCdnBandwidth(float $cdnBandwidth) { $this->set("CdnBandwidth", $cdnBandwidth); } - /** * Traffic: 对应时间粒度的流量,单位字节 * @@ -77,7 +85,7 @@ public function getTraffic() * * @param float $traffic */ - public function setTraffic($traffic) + public function setTraffic(float $traffic) { $this->set("Traffic", $traffic); } diff --git a/src/UCDN/Models/ProIspBandwidthSet.php b/src/UCDN/Models/ProIspBandwidthSet.php index c79e53b3..6c72d7cf 100644 --- a/src/UCDN/Models/ProIspBandwidthSet.php +++ b/src/UCDN/Models/ProIspBandwidthSet.php @@ -1,6 +1,7 @@ set("Province", $province); } - /** * BandwidthTrafficList: 省份带宽流量实例表 * - * @return ProIspBandwidthList[]|null + * @return ProIspBandwidthListModel[]|null */ public function getBandwidthTrafficList() { @@ -55,7 +59,7 @@ public function getBandwidthTrafficList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ProIspBandwidthList($item)); + array_push($result, new ProIspBandwidthListModel($item)); } return $result; } @@ -63,7 +67,7 @@ public function getBandwidthTrafficList() /** * BandwidthTrafficList: 省份带宽流量实例表 * - * @param ProIspBandwidthList[] $bandwidthTrafficList + * @param ProIspBandwidthListModel[] $bandwidthTrafficList */ public function setBandwidthTrafficList(array $bandwidthTrafficList) { diff --git a/src/UCDN/Models/ProIspRequestListV2.php b/src/UCDN/Models/ProIspRequestListV2.php index a243b2f9..3e95e657 100644 --- a/src/UCDN/Models/ProIspRequestListV2.php +++ b/src/UCDN/Models/ProIspRequestListV2.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CdnRequest: 返回值返回指定时间区间内的请求数 * @@ -57,7 +60,7 @@ public function getCdnRequest() * * @param float $cdnRequest */ - public function setCdnRequest($cdnRequest) + public function setCdnRequest(float $cdnRequest) { $this->set("CdnRequest", $cdnRequest); } diff --git a/src/UCDN/Models/ProIspRequestNumSetV2.php b/src/UCDN/Models/ProIspRequestNumSetV2.php index a7e6273c..c4408277 100644 --- a/src/UCDN/Models/ProIspRequestNumSetV2.php +++ b/src/UCDN/Models/ProIspRequestNumSetV2.php @@ -1,6 +1,7 @@ set("Province", $province); } - /** * RequestList: 省份请求数实例表 ProIspRequestListV2 * - * @return ProIspRequestListV2[]|null + * @return ProIspRequestListV2Model[]|null */ public function getRequestList() { @@ -55,7 +58,7 @@ public function getRequestList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ProIspRequestListV2($item)); + array_push($result, new ProIspRequestListV2Model($item)); } return $result; } @@ -63,7 +66,7 @@ public function getRequestList() /** * RequestList: 省份请求数实例表 ProIspRequestListV2 * - * @param ProIspRequestListV2[] $requestList + * @param ProIspRequestListV2Model[] $requestList */ public function setRequestList(array $requestList) { diff --git a/src/UCDN/Models/ReferConf.php b/src/UCDN/Models/ReferConf.php index 067dc9e0..cae15be5 100644 --- a/src/UCDN/Models/ReferConf.php +++ b/src/UCDN/Models/ReferConf.php @@ -1,6 +1,7 @@ set("ReferType", $referType); } - /** * NullRefer: ReferType为白名单时(删除),NullRefer为0代表不允许NULL refer访问,为1代表允许Null refer访问 * @@ -57,11 +62,10 @@ public function getNullRefer() * * @param int $nullRefer */ - public function setNullRefer($nullRefer) + public function setNullRefer(int $nullRefer) { $this->set("NullRefer", $nullRefer); } - /** * ReferList: Refer防盗链规则列表,支持正则表达式 * diff --git a/src/UCDN/Models/RefererList.php b/src/UCDN/Models/RefererList.php new file mode 100644 index 00000000..c2c3bdd0 --- /dev/null +++ b/src/UCDN/Models/RefererList.php @@ -0,0 +1,86 @@ +get("Referer"); + } + + /** + * Referer: 客户端请求的referer + * + * @param string $referer + */ + public function setReferer(string $referer) + { + $this->set("Referer", $referer); + } + /** + * RequestTimes: 次数 + * + * @return integer|null + */ + public function getRequestTimes() + { + return $this->get("RequestTimes"); + } + + /** + * RequestTimes: 次数 + * + * @param int $requestTimes + */ + public function setRequestTimes(int $requestTimes) + { + $this->set("RequestTimes", $requestTimes); + } + /** + * Percent: 次数占比,单位% + * + * @return float|null + */ + public function getPercent() + { + return $this->get("Percent"); + } + + /** + * Percent: 次数占比,单位% + * + * @param float $percent + */ + public function setPercent(float $percent) + { + $this->set("Percent", $percent); + } +} diff --git a/src/UCDN/Models/RefererStatistics.php b/src/UCDN/Models/RefererStatistics.php new file mode 100644 index 00000000..37aa9059 --- /dev/null +++ b/src/UCDN/Models/RefererStatistics.php @@ -0,0 +1,79 @@ +get("Date"); + } + + /** + * Date: 日期 + * + * @param string $date + */ + public function setDate(string $date) + { + $this->set("Date", $date); + } + /** + * RefererList: Referer实例表 + * + * @return RefererListModel[]|null + */ + public function getRefererList() + { + $items = $this->get("RefererList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new RefererListModel($item)); + } + return $result; + } + + /** + * RefererList: Referer实例表 + * + * @param RefererListModel[] $refererList + */ + public function setRefererList(array $refererList) + { + $result = []; + foreach ($refererList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UCDN/Models/RequestInfo.php b/src/UCDN/Models/RequestInfo.php deleted file mode 100644 index ec4cc9e4..00000000 --- a/src/UCDN/Models/RequestInfo.php +++ /dev/null @@ -1,84 +0,0 @@ -get("Time"); - } - - /** - * Time: 带宽获取的时间点。格式:时间戳 - * - * @param int $time - */ - public function setTime($time) - { - $this->set("Time", $time); - } - - /** - * CdnRequest: 返回值返回指定时间区间内的cdn收到的请求次数之和 - * - * @return float|null - */ - public function getCdnRequest() - { - return $this->get("CdnRequest"); - } - - /** - * CdnRequest: 返回值返回指定时间区间内的cdn收到的请求次数之和 - * - * @param float $cdnRequest - */ - public function setCdnRequest($cdnRequest) - { - $this->set("CdnRequest", $cdnRequest); - } - - /** - * OriginRequest: 返回值返回指定时间区间内的cdn回源的请求次数之和 - * - * @return float|null - */ - public function getOriginRequest() - { - return $this->get("OriginRequest"); - } - - /** - * OriginRequest: 返回值返回指定时间区间内的cdn回源的请求次数之和 - * - * @param float $originRequest - */ - public function setOriginRequest($originRequest) - { - $this->set("OriginRequest", $originRequest); - } -} diff --git a/src/UCDN/Models/RequestInfoV2.php b/src/UCDN/Models/RequestInfoV2.php index ab70b3ad..1dd32a99 100644 --- a/src/UCDN/Models/RequestInfoV2.php +++ b/src/UCDN/Models/RequestInfoV2.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * CdnRequest: 返回值返回指定时间区间内的cdn收到的请求次数之和 * @@ -57,7 +61,7 @@ public function getCdnRequest() * * @param float $cdnRequest */ - public function setCdnRequest($cdnRequest) + public function setCdnRequest(float $cdnRequest) { $this->set("CdnRequest", $cdnRequest); } diff --git a/src/UCDN/Models/TaskInfo.php b/src/UCDN/Models/TaskInfo.php index 98c910c8..387a109b 100644 --- a/src/UCDN/Models/TaskInfo.php +++ b/src/UCDN/Models/TaskInfo.php @@ -1,6 +1,7 @@ set("TaskId", $taskId); } - /** * UrlLists: 任务url的信息列表,参考UrlProgressInfo * - * @return UrlProgressInfo[]|null + * @return UrlProgressInfoModel[]|null */ public function getUrlLists() { @@ -55,7 +59,7 @@ public function getUrlLists() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UrlProgressInfo($item)); + array_push($result, new UrlProgressInfoModel($item)); } return $result; } @@ -63,7 +67,7 @@ public function getUrlLists() /** * UrlLists: 任务url的信息列表,参考UrlProgressInfo * - * @param UrlProgressInfo[] $urlLists + * @param UrlProgressInfoModel[] $urlLists */ public function setUrlLists(array $urlLists) { @@ -73,7 +77,6 @@ public function setUrlLists(array $urlLists) } return $result; } - /** * CreateTime: 刷新任务创建的时间。格式为Unix Timestamp * @@ -89,11 +92,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Status: 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 * @@ -109,7 +111,7 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } diff --git a/src/UCDN/Models/TrafficSet.php b/src/UCDN/Models/TrafficSet.php index a0598638..0aa508d3 100644 --- a/src/UCDN/Models/TrafficSet.php +++ b/src/UCDN/Models/TrafficSet.php @@ -1,6 +1,7 @@ set("Areacode", $areacode); } - /** * TrafficTotal: Areacode区域内总购买流量, 单位GB * @@ -57,11 +60,10 @@ public function getTrafficTotal() * * @param float $trafficTotal */ - public function setTrafficTotal($trafficTotal) + public function setTrafficTotal(float $trafficTotal) { $this->set("TrafficTotal", $trafficTotal); } - /** * TrafficLeft: Areacode区域内总剩余流量, 单位GB * @@ -77,11 +79,10 @@ public function getTrafficLeft() * * @param float $trafficLeft */ - public function setTrafficLeft($trafficLeft) + public function setTrafficLeft(float $trafficLeft) { $this->set("TrafficLeft", $trafficLeft); } - /** * TrafficUsed: Areacode区域内总使用流量, 单位GB * @@ -97,7 +98,7 @@ public function getTrafficUsed() * * @param float $trafficUsed */ - public function setTrafficUsed($trafficUsed) + public function setTrafficUsed(float $trafficUsed) { $this->set("TrafficUsed", $trafficUsed); } diff --git a/src/UCDN/Models/UrlProgressInfo.php b/src/UCDN/Models/UrlProgressInfo.php index 15c33944..c3c488ac 100644 --- a/src/UCDN/Models/UrlProgressInfo.php +++ b/src/UCDN/Models/UrlProgressInfo.php @@ -1,6 +1,7 @@ set("Url", $url); } - /** * CreateTime: 刷新任务创建的时间。格式为Unix Timestamp * @@ -57,11 +61,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * FinishTime: 任务完成时间。格式为Unix Timestamp * @@ -77,11 +80,10 @@ public function getFinishTime() * * @param int $finishTime */ - public function setFinishTime($finishTime) + public function setFinishTime(int $finishTime) { $this->set("FinishTime", $finishTime); } - /** * Status: 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 * @@ -97,11 +99,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * Progress: 刷新进度,单位% * @@ -117,7 +118,7 @@ public function getProgress() * * @param int $progress */ - public function setProgress($progress) + public function setProgress(int $progress) { $this->set("Progress", $progress); } diff --git a/src/UCDN/Models/UrlStatistics.php b/src/UCDN/Models/UrlStatistics.php new file mode 100644 index 00000000..db8fbade --- /dev/null +++ b/src/UCDN/Models/UrlStatistics.php @@ -0,0 +1,79 @@ +get("UrlList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new DownloadStatisticInfoModel($item)); + } + return $result; + } + + /** + * UrlList: + * + * @param DownloadStatisticInfoModel[] $urlList + */ + public function setUrlList(array $urlList) + { + $result = []; + foreach ($urlList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * Date: 日期 + * + * @return string|null + */ + public function getDate() + { + return $this->get("Date"); + } + + /** + * Date: 日期 + * + * @param string $date + */ + public function setDate(string $date) + { + $this->set("Date", $date); + } +} diff --git a/src/UCDN/UCDNClient.php b/src/UCDN/UCDNClient.php index cffb116a..9266c43b 100644 --- a/src/UCDN/UCDNClient.php +++ b/src/UCDN/UCDNClient.php @@ -1,6 +1,7 @@ (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "CertName" => (string) 证书名称 - * "UserCert" => (string) 用户证书 - * "PrivateKey" => (string) 用户私钥 - * "CaCert" => (string) Ca证书,默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddCertificateResponse * @throws UCloudException */ public function addCertificate(AddCertificateRequest $request = null) @@ -119,25 +191,27 @@ public function addCertificate(AddCertificateRequest $request = null) $resp = $this->invoke($request); return new AddCertificateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DeleteCertificate - 删除证书 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/delete_certificate + * ControlUcdnDomainCacheAccess - 封禁解封缓存访问 * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "CertName" => (string) 证书名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function controlUcdnDomainCacheAccess(ControlUcdnDomainCacheAccessRequest $request = null) + { + $resp = $this->invoke($request); + return new ControlUcdnDomainCacheAccessResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteCertificate - 删除证书 * - * @return DeleteCertificateResponse * @throws UCloudException */ public function deleteCertificate(DeleteCertificateRequest $request = null) @@ -145,47 +219,13 @@ public function deleteCertificate(DeleteCertificateRequest $request = null) $resp = $this->invoke($request); return new DeleteCertificateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeNewUcdnPrefetchCacheTask - 获取预取任务状态 * - * See also: https://docs.ucloud.cn/api/ucdn-api/describe_new_ucdn_prefetch_cache_task - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "TaskId" => (array) 提交任务时返回的任务ID - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "Status" => (string) 需要获取的内容预热的状态,枚举值:success:成功;wait:等待处理;process:正在处理;failure:失败; unknow:未知,默认选择所有状态 - * "Offset" => (integer) 数据偏移量,默认为0,自然数 - * "Limit" => (integer) 返回数据长度,默认全部,自然数 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 预热任务的总数 - * "TaskList" => (array) 预热任务信息,参考TaskInfo[ - * [ - * "TaskId" => (string) 提交任务时返回的任务ID - * "UrlLists" => (array) 任务url的信息列表,参考UrlProgressInfo[ - * [ - * "Url" => (string) 刷新的单条url - * "CreateTime" => (integer) 刷新任务创建的时间。格式为Unix Timestamp - * "FinishTime" => (integer) 任务完成时间。格式为Unix Timestamp - * "Status" => (string) 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 - * "Progress" => (integer) 刷新进度,单位% - * ] - * ] - * "CreateTime" => (integer) 刷新任务创建的时间。格式为Unix Timestamp - * "Status" => (string) 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 - * ] - * ] - * ] - * - * @return DescribeNewUcdnPrefetchCacheTaskResponse * @throws UCloudException */ public function describeNewUcdnPrefetchCacheTask(DescribeNewUcdnPrefetchCacheTaskRequest $request = null) @@ -193,47 +233,13 @@ public function describeNewUcdnPrefetchCacheTask(DescribeNewUcdnPrefetchCacheTas $resp = $this->invoke($request); return new DescribeNewUcdnPrefetchCacheTaskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeNewUcdnRefreshCacheTask - 获取域名刷新任务状态 * - * See also: https://docs.ucloud.cn/api/ucdn-api/describe_new_ucdn_refresh_cache_task - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "TaskId" => (array) 提交任务时返回的任务ID - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "Status" => (string) 需要获取的内容刷新的状态,枚举值:success:成功;wait:等待处理;process:正在处理;failure:失败; unknow:未知,默认选择所有状态 - * "Offset" => (integer) 数据偏移量,默认为0,自然数 - * "Limit" => (integer) 返回数据长度,默认全部,自然数 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 刷新任务的总数 - * "TaskList" => (array) 刷新任务信息,参考TaskInfo[ - * [ - * "TaskId" => (string) 提交任务时返回的任务ID - * "UrlLists" => (array) 任务url的信息列表,参考UrlProgressInfo[ - * [ - * "Url" => (string) 刷新的单条url - * "CreateTime" => (integer) 刷新任务创建的时间。格式为Unix Timestamp - * "FinishTime" => (integer) 任务完成时间。格式为Unix Timestamp - * "Status" => (string) 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 - * "Progress" => (integer) 刷新进度,单位% - * ] - * ] - * "CreateTime" => (integer) 刷新任务创建的时间。格式为Unix Timestamp - * "Status" => (string) 刷新任务的当前状态,枚举值:success:成功;wait:排队中;process:处理中;failure:失败; unknow:未知 - * ] - * ] - * ] - * - * @return DescribeNewUcdnRefreshCacheTaskResponse * @throws UCloudException */ public function describeNewUcdnRefreshCacheTask(DescribeNewUcdnRefreshCacheTaskRequest $request = null) @@ -241,40 +247,13 @@ public function describeNewUcdnRefreshCacheTask(DescribeNewUcdnRefreshCacheTaskR $resp = $this->invoke($request); return new DescribeNewUcdnRefreshCacheTaskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetCertificateV2 - 获取证书列表(新) * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_certificate_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 偏移,默认为0,非负整数 - * "Limit" => (integer) 长度,默认为全部,非负整数 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 证书数量 - * "CertList" => (array) 证书信息列表[ - * [ - * "CertName" => (string) 证书名 - * "CommonName" => (string) 通用名 - * "DnsName" => (string) dns名称 - * "BeginTime" => (integer) 证书开始时间 - * "EndTime" => (integer) 证书获取时间 - * "DomainCount" => (integer) 已配置域名个数 - * "UserCert" => (string) 证书内容 - * "CaCert" => (string) ca证内容 - * "Domains" => (array) 已配置的域名列表 - * ] - * ] - * ] - * - * @return GetCertificateV2Response * @throws UCloudException */ public function getCertificateV2(GetCertificateV2Request $request = null) @@ -282,73 +261,13 @@ public function getCertificateV2(GetCertificateV2Request $request = null) $resp = $this->invoke($request); return new GetCertificateV2Response($resp->toArray(), $resp->getRequestId()); } - - /** - * GetNewUcdnDomainBandwidth - 获取域名带宽数据 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_new_ucdn_domain_bandwidth - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthList" => (array) 带宽信息列表,参见BandwidthInfo[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnBandwidth" => (number) 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps(如果请求参数Type为0,则Value是五分钟粒度的带宽值,如果Type为1,则Value是1小时的带宽峰值,如果Type为2,则Value是一天内的带宽峰值) - * ] - * ] - * "Traffic" => (number) 从起始时间到结束时间内的所使用的CDN总流量,单位GB - * ] - * - * @return GetNewUcdnDomainBandwidthResponse - * @throws UCloudException - */ - public function getNewUcdnDomainBandwidth(GetNewUcdnDomainBandwidthRequest $request = null) - { - $resp = $this->invoke($request); - return new GetNewUcdnDomainBandwidthResponse($resp->toArray(), $resp->getRequestId()); - } - + + + + /** * GetNewUcdnDomainHitRate - 获取域名命中率 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_new_ucdn_domain_hit_rate - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度)默认5分钟 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] - * - * Outputs: - * - * $outputs = [ - * "HitRateList" => (array) 请求数实例表。[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "FlowHitRate" => (number) 总流量命中率,单位% - * "RequestHitRate" => (number) 请求数命中率,单位% - * ] - * ] - * ] - * - * @return GetNewUcdnDomainHitRateResponse * @throws UCloudException */ public function getNewUcdnDomainHitRate(GetNewUcdnDomainHitRateRequest $request = null) @@ -356,162 +275,41 @@ public function getNewUcdnDomainHitRate(GetNewUcdnDomainHitRateRequest $request $resp = $this->invoke($request); return new GetNewUcdnDomainHitRateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * GetNewUcdnDomainHttpCode - 获取域名状态码监控 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_new_ucdn_domain_http_code - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] + * GetNewUcdnLogRefererStatistics - 获取热点referer统计 * - * Outputs: - * - * $outputs = [ - * "HttpCodeDetail" => (array) 状态码实例表。详细见HttpCodeInfo[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "HttpOneXX" => (integer) 1xx数量 - * "HttpTwoXX" => (integer) 2xx数量 - * "HttpThreeXX" => (integer) 3xx数量 - * "HttpFourXX" => (integer) 4xx数量 - * "HttpFiveXX" => (integer) 5xx数量 - * ] - * ] - * ] - * - * @return GetNewUcdnDomainHttpCodeResponse * @throws UCloudException */ - public function getNewUcdnDomainHttpCode(GetNewUcdnDomainHttpCodeRequest $request = null) + public function getNewUcdnLogRefererStatistics(GetNewUcdnLogRefererStatisticsRequest $request = null) { $resp = $this->invoke($request); - return new GetNewUcdnDomainHttpCodeResponse($resp->toArray(), $resp->getRequestId()); + return new GetNewUcdnLogRefererStatisticsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * GetNewUcdnDomainHttpCodeV2 - 获取域名详细状态码监控 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_new_ucdn_domain_http_code_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * ] - * - * Outputs: - * - * $outputs = [ - * "HttpCodeV2Detail" => (array) 状态码详情[ - * [ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * ] - * ] + * GetNewUcdnLogUrlStatistics - 获取日志url统计 * - * @return GetNewUcdnDomainHttpCodeV2Response * @throws UCloudException */ - public function getNewUcdnDomainHttpCodeV2(GetNewUcdnDomainHttpCodeV2Request $request = null) + public function getNewUcdnLogUrlStatistics(GetNewUcdnLogUrlStatisticsRequest $request = null) { $resp = $this->invoke($request); - return new GetNewUcdnDomainHttpCodeV2Response($resp->toArray(), $resp->getRequestId()); + return new GetNewUcdnLogUrlStatisticsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomain95BandwidthV2 - 获取域名九五峰值带宽数据 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain95_bandwidth_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "BeginTime" => (integer) 查询的起始日期,格式为Unix Timestamp - * "EndTime" => (integer) 查询的结束日期,格式为Unix Timestamp - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 - * ] - * - * Outputs: - * - * $outputs = [ - * "Time" => (integer) 查询时间期间的95带宽时间点 Unix时间戳 - * "CdnBandwidth" => (number) 查询期间的CDN的95带宽值,单位Mbps - * ] - * - * @return GetUcdnDomain95BandwidthV2Response * @throws UCloudException */ public function getUcdnDomain95BandwidthV2(GetUcdnDomain95BandwidthV2Request $request = null) @@ -519,38 +317,13 @@ public function getUcdnDomain95BandwidthV2(GetUcdnDomain95BandwidthV2Request $re $resp = $this->invoke($request); return new GetUcdnDomain95BandwidthV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainBandwidthV2 - 获取域名带宽数据(新) * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_bandwidth_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外 不填默认为全部区域 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "Protocol" => (string) 协议,http、https 不传则查所有协议的带宽 - * "Primeval" => (integer) 原始带宽,不为0则获取原始带宽,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthTrafficList" => (array) 带宽信息列表,参见BandwidthTrafficInfo[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnBandwidth" => (number) 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps(如果请求参数Type为0,则Value是五分钟粒度的带宽值,如果Type为1,则Value是1小时的带宽峰值,如果Type为2,则Value是一天内的带宽峰值) - * "Traffic" => (number) 对应时间粒度的流量,单位字节 - * ] - * ] - * ] - * - * @return GetUcdnDomainBandwidthV2Response * @throws UCloudException */ public function getUcdnDomainBandwidthV2(GetUcdnDomainBandwidthV2Request $request = null) @@ -558,102 +331,13 @@ public function getUcdnDomainBandwidthV2(GetUcdnDomainBandwidthV2Request $reques $resp = $this->invoke($request); return new GetUcdnDomainBandwidthV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainConfig - 批量获取加速域名配置 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_config - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 数据偏移量,默认0,非负整数 - * "Limit" => (integer) 返回数据长度, 默认全部,非负整数 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认获取账号下的所有域名信息,n为自然数,从DomainId.0开始。 - * "ChannelType" => (string) 产品类型ucdn,可不填,默认为ucdn - * ] - * - * Outputs: - * - * $outputs = [ - * "DomainList" => (array) 获取的域名信息,具体参考下面DomainConfig[ - * [ - * "AreaCode" => (string) 查询带宽区域 cn代表国内 abroad代表海外 all表示全部区域 - * "CdnType" => (string) 加速域名的业务类型,web代表网站,stream代表视频 ,download 代表下载 - * "Status" => (string) 创建的加速域名的当前的状态。check代表审核中,checkSuccess代表审核通过,checkFail代表审核失败,enable代表加速中,disable代表停止加速,delete代表删除加速enableing代表正在开启加速,disableing代表正在停止加速中,deleteing代表删除中 - * "Cname" => (string) cdn域名。创建加速域名生成的cdn域名,用于设置CNAME记录 - * "CreateTime" => (integer) 域名创建的时间。格式:时间戳 - * "TestUrl" => (string) 测试url。用于域名创建加速时的测试 - * "HttpsStatusCn" => (string) 国内https状态 enableing-开启中 fail-开启失败 enable-启用 disable-未启用 - * "HttpsStatusAbroad" => (string) 国外https状态 enableing-开启中 fail-开启失败 enable-启用 disable-未启用 - * "CertNameCn" => (string) 国内证书名称 - * "CertNameAbroad" => (string) 国外证书名称 - * "Tag" => (string) 业务组:Default - * "DomainId" => (string) 域名Id - * "Domain" => (string) 域名 - * "OriginConf" => (object) 源站配置 参考OriginConf[ - * "OriginIpList" => (array) 源站ip即cdn服务器回源访问的ip地址。多个源站ip,可以这样表述,如:["1.1.1.1","2.2.2.2"] - * "OriginHost" => (string) 回源Http请求头部Host,默认是加速域名 - * "OriginPort" => (integer) 回源端口 - * "BackupOriginEnable" => (boolean) 1如果为false表示BackupOriginIp为空,表示没有备份源站,忽略BackupOriginIp,BackupOriginHost字段2如果为true表示BackupOriginIp.n必须至少有一个备份源站地址 - * "BackupOriginIpList" => (array) 备份源站ip即cdn服务器回源访问的ip地址。多个源站ip,可以这样表述,如:["1.1.1.1","2.2.2.2"] - * "BackupOriginHost" => (string) 备份回源Http请求头部Host,默认是加速域名 - * "OriginErrorCode" => (string) 主源响应的回源错误码(如:404|500),默认空字符串 - * "OriginErrorNum" => (integer) 回主源的回源失败数,默认1 - * "OriginProtocol" => (string) 源站协议http,http|https 默认http - * "OriginFollow301" => (integer) 跟随301跳转 0=不跟随 1=跟随 - * ] - * "AccessControlConf" => (object) 访问控制配置 参考AccessControlConf[ - * "IpBlackList" => (array) ip黑名单,多个ip,可表示为:IpBlackList.0=1.1.1.1,IpBlackList.1=2.2.2.2 - * "ReferConf" => (object) refer配置[ - * "ReferType" => (integer) Refer防盗链配置 0白名单,1黑名单 - * "NullRefer" => (integer) ReferType为白名单时(删除),NullRefer为0代表不允许NULL refer访问,为1代表允许Null refer访问 - * "ReferList" => (array) Refer防盗链规则列表,支持正则表达式 - * ] - * ] - * "CacheConf" => (object) 缓存配置 参考CacheAllConfig[ - * "CacheHost" => (string) 缓存Host,不同的域名可以配置为同一个CacheHost来实现缓存共享,默认为加速域名 - * "CacheList" => (array) 缓存配置列表,参见CacheConf[ - * [ - * "PathPattern" => (string) 路径模式,支持正则 - * "CacheTTL" => (integer) 缓存时间 - * "CacheUnit" => (string) 缓存时间的单位。sec(秒),min(分钟),hour(小时),day(天)。上限1年。 - * "CacheBehavior" => (boolean) 是否缓存,true为缓存,flase为不缓存。为flase的情况下,CacheTTL和CacheUnit强制不生效 - * "HttpCodePattern" => (string) 状态码模式,非200,206状态码,多个状态码用竖线(|)分隔,该属性仅仅在状态码缓存配置列表中返回 - * "Description" => (string) 缓存规则描述 - * "FollowOriginRule" => (boolean) 是否优先遵循源站头部缓存策略,false为不优先遵循源站,true为优先遵循源站缓存头部。默认为0 - * ] - * ] - * "HttpCodeCacheList" => (array) 状态码缓存配置列表,参见CacheConf[ - * [ - * "PathPattern" => (string) 路径模式,支持正则 - * "CacheTTL" => (integer) 缓存时间 - * "CacheUnit" => (string) 缓存时间的单位。sec(秒),min(分钟),hour(小时),day(天)。上限1年。 - * "CacheBehavior" => (boolean) 是否缓存,true为缓存,flase为不缓存。为flase的情况下,CacheTTL和CacheUnit强制不生效 - * "HttpCodePattern" => (string) 状态码模式,非200,206状态码,多个状态码用竖线(|)分隔,该属性仅仅在状态码缓存配置列表中返回 - * "Description" => (string) 缓存规则描述 - * "FollowOriginRule" => (boolean) 是否优先遵循源站头部缓存策略,false为不优先遵循源站,true为优先遵循源站缓存头部。默认为0 - * ] - * ] - * "CacheKeyList" => (array) 忽略参数缓存配置列表,参见CacheKeyInfo[ - * [ - * "Ignore" => (boolean) 是否忽略 - * "PathPattern" => (string) 路径模式,支持正则 - * "QueryString" => (string) 自定义变量,以$符号开头,多个变量用加号(+)连接,$querystring表示所有变量 - * ] - * ] - * ] - * "AdvancedConf" => (object) 高级配置 参考AdvancedConf[ - * "HttpClientHeader" => (array) 客户端响应http头列表 - * "HttpOriginHeader" => (array) 源站http头列表 - * "Http2Https" => (boolean) http转https回源 true是,false否 - * ] - * ] - * ] - * ] - * - * @return GetUcdnDomainConfigResponse * @throws UCloudException */ public function getUcdnDomainConfig(GetUcdnDomainConfigRequest $request = null) @@ -661,37 +345,13 @@ public function getUcdnDomainConfig(GetUcdnDomainConfigRequest $request = null) $resp = $this->invoke($request); return new GetUcdnDomainConfigResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainHitRate - 获取域名命中率 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_hit_rate - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照一分钟的粒度)默认5分钟 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "HitType" => (integer) 命中类型:0=整体命中 1=边缘命中 默认是0 - * ] - * - * Outputs: - * - * $outputs = [ - * "HitRateList" => (array) 请求数实例表。[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "FlowHitRate" => (number) 总流量命中率,单位% - * "RequestHitRate" => (number) 请求数命中率,单位% - * ] - * ] - * ] - * - * @return GetUcdnDomainHitRateResponse * @throws UCloudException */ public function getUcdnDomainHitRate(GetUcdnDomainHitRateRequest $request = null) @@ -699,395 +359,13 @@ public function getUcdnDomainHitRate(GetUcdnDomainHitRateRequest $request = null $resp = $this->invoke($request); return new GetUcdnDomainHitRateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainHttpCodeV2 - 获取域名状态码信息 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_http_code_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示1分钟粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "Layer" => (string) 指定获取的状态码是边缘还是上层 edge 表示边缘 layer 表示上层 - * ] - * - * Outputs: - * - * $outputs = [ - * "HttpCodeDetail" => (array) 状态码实例表。详细见HttpCodeInfoV2[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "Http1XX" => (object) 1xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * "Http2XX" => (object) 2xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * "Http3XX" => (object) 3xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * "Http4XX" => (object) 4xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * "Http5XX" => (object) 5xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * "Http6XX" => (object) 6xx信息,参考HttpCodeV2Detail结构[ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * ] - * ] - * ] - * - * @return GetUcdnDomainHttpCodeV2Response * @throws UCloudException */ public function getUcdnDomainHttpCodeV2(GetUcdnDomainHttpCodeV2Request $request = null) @@ -1095,33 +373,13 @@ public function getUcdnDomainHttpCodeV2(GetUcdnDomainHttpCodeV2Request $request $resp = $this->invoke($request); return new GetUcdnDomainHttpCodeV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainInfoList - 获取域名基本信息 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_info_list - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PageSize" => (integer) 分页的大小,不填默认每页20个 - * "PageIndex" => (integer) 返回第几页,不填默认是第1页 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 账户下域名总个数 - * "DomainInfoList" => (array) 域名基本信息[ - * [ - * "Domain" => (string) 域名 - * "DomainId" => (string) 域名的资源id - * ] - * ] - * ] - * - * @return GetUcdnDomainInfoListResponse * @throws UCloudException */ public function getUcdnDomainInfoList(GetUcdnDomainInfoListRequest $request = null) @@ -1129,40 +387,13 @@ public function getUcdnDomainInfoList(GetUcdnDomainInfoListRequest $request = nu $resp = $this->invoke($request); return new GetUcdnDomainInfoListResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainLog - 获取加速域名原始日志 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_log - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DomainId" => (array) 域名ID,创建加速域名时生成。默认全部域名 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * "Type" => (integer) 查询粒度 0=default(没有粒度) 1=按小时 2=按天 - * ] - * - * Outputs: - * - * $outputs = [ - * "LogSet" => (array) 获取日志的连接地址。具体参考下面LogSetList[ - * [ - * "Domain" => (string) 域名 - * "Logs" => (array) 域名信息列表,参考LogSetInfo[ - * [ - * "Time" => (integer) 日志时间UnixTime - * "CnLog" => (array) 国内日志url列表 - * "AbroadLog" => (array) 国外日志url列表 - * ] - * ] - * ] - * ] - * ] - * - * @return GetUcdnDomainLogResponse * @throws UCloudException */ public function getUcdnDomainLog(GetUcdnDomainLogRequest $request = null) @@ -1170,39 +401,27 @@ public function getUcdnDomainLog(GetUcdnDomainLogRequest $request = null) $resp = $this->invoke($request); return new GetUcdnDomainLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * GetUcdnDomainOriginHttpCode - 获取域名源站状态码监控 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_origin_http_code - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] + * GetUcdnDomainLogV2 - 获取域名5分钟日志 * - * Outputs: - * - * $outputs = [ - * "HttpCodeDetail" => (array) 状态码实例表。详细见HttpCodeInfo[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "HttpOneXX" => (integer) 1xx数量 - * "HttpTwoXX" => (integer) 2xx数量 - * "HttpThreeXX" => (integer) 3xx数量 - * "HttpFourXX" => (integer) 4xx数量 - * "HttpFiveXX" => (integer) 5xx数量 - * ] - * ] - * ] + * @throws UCloudException + */ + public function getUcdnDomainLogV2(GetUcdnDomainLogV2Request $request = null) + { + $resp = $this->invoke($request); + return new GetUcdnDomainLogV2Response($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetUcdnDomainOriginHttpCode - 获取域名源站状态码监控 * - * @return GetUcdnDomainOriginHttpCodeResponse * @throws UCloudException */ public function getUcdnDomainOriginHttpCode(GetUcdnDomainOriginHttpCodeRequest $request = null) @@ -1210,91 +429,13 @@ public function getUcdnDomainOriginHttpCode(GetUcdnDomainOriginHttpCodeRequest $ $resp = $this->invoke($request); return new GetUcdnDomainOriginHttpCodeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainOriginHttpCodeDetail - 获取域名源站详细状态码监控 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_origin_http_code_detail - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * ] - * - * Outputs: - * - * $outputs = [ - * "HttpCodeV2Detail" => (array) 状态码详情[ - * [ - * "Time" => (integer) 时间 - * "Total" => (integer) 当前分组的总状态码数 - * "Http100" => (integer) http100数量 - * "Http101" => (integer) http101数量 - * "Http102" => (integer) http102数量 - * "Http200" => (integer) http200数量 - * "Http201" => (integer) http201数量 - * "Http202" => (integer) http202数量 - * "Http203" => (integer) http203数量 - * "Http204" => (integer) http204数量 - * "Http205" => (integer) http205数量 - * "Http206" => (integer) http206数量 - * "Http207" => (integer) http207数量 - * "Http300" => (integer) http300数量 - * "Http301" => (integer) http301数量 - * "Http302" => (integer) http302数量 - * "Http303" => (integer) http303数量 - * "Http304" => (integer) http304数量 - * "Http305" => (integer) http305数量 - * "Http306" => (integer) http306数量 - * "Http307" => (integer) http307数量 - * "Http400" => (integer) http400数量 - * "Http401" => (integer) http401数量 - * "Http402" => (integer) http402数量 - * "Http403" => (integer) http403数量 - * "Http404" => (integer) http404数量 - * "Http405" => (integer) http405数量 - * "Http406" => (integer) http406数量 - * "Http407" => (integer) http407数量 - * "Http408" => (integer) http408数量 - * "Http409" => (integer) http409数量 - * "Http410" => (integer) http410数量 - * "Http411" => (integer) http411数量 - * "Http412" => (integer) http412数量 - * "Http413" => (integer) http413数量 - * "Http414" => (integer) http414数量 - * "Http415" => (integer) http415数量 - * "Http416" => (integer) http416数量 - * "Http417" => (integer) http417数量 - * "Http418" => (integer) http418数量 - * "Http421" => (integer) http421数量 - * "Http422" => (integer) http422数量 - * "Http423" => (integer) http423数量 - * "Http424" => (integer) http424数量 - * "Http425" => (integer) http425数量 - * "Http426" => (integer) http426数量 - * "Http449" => (integer) http449数量 - * "Http451" => (integer) http451数量 - * "Http500" => (integer) http500数量 - * "Http501" => (integer) http501数量 - * "Http502" => (integer) http502数量 - * "Http503" => (integer) http503数量 - * "Http504" => (integer) http504数量 - * "Http505" => (integer) http505数量 - * "Http506" => (integer) http506数量 - * "Http507" => (integer) http507数量 - * "Http509" => (integer) http509数量 - * "Http510" => (integer) http510数量 - * ] - * ] - * ] - * - * @return GetUcdnDomainOriginHttpCodeDetailResponse * @throws UCloudException */ public function getUcdnDomainOriginHttpCodeDetail(GetUcdnDomainOriginHttpCodeDetailRequest $request = null) @@ -1302,35 +443,13 @@ public function getUcdnDomainOriginHttpCodeDetail(GetUcdnDomainOriginHttpCodeDet $resp = $this->invoke($request); return new GetUcdnDomainOriginHttpCodeDetailResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainOriginRequestNum - 获取域名回源请求数 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_origin_request_num - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询区域 cn代表国内 abroad代表海外,只支持国内 - * ] - * - * Outputs: - * - * $outputs = [ - * "RequestList" => (array) 请求数实例表。[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnRequest" => (number) 返回值返回指定时间区间内的cdn收到的请求次数之和 - * ] - * ] - * ] - * - * @return GetUcdnDomainOriginRequestNumResponse * @throws UCloudException */ public function getUcdnDomainOriginRequestNum(GetUcdnDomainOriginRequestNumRequest $request = null) @@ -1338,26 +457,13 @@ public function getUcdnDomainOriginRequestNum(GetUcdnDomainOriginRequestNumReque $resp = $this->invoke($request); return new GetUcdnDomainOriginRequestNumResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnDomainPrefetchEnable - 获取域名预取开启状态 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_prefetch_enable - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DomainId" => (string) 域名ID,创建加速域名时生成。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Enable" => (integer) 0表示该域名未开启预取,1表示该域名已开启预取 - * ] - * - * @return GetUcdnDomainPrefetchEnableResponse * @throws UCloudException */ public function getUcdnDomainPrefetchEnable(GetUcdnDomainPrefetchEnableRequest $request = null) @@ -1365,73 +471,13 @@ public function getUcdnDomainPrefetchEnable(GetUcdnDomainPrefetchEnableRequest $ $resp = $this->invoke($request); return new GetUcdnDomainPrefetchEnableResponse($resp->toArray(), $resp->getRequestId()); } - - /** - * GetUcdnDomainRequestNumV2 - 获取域名请求数 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_request_num_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询区域 cn代表国内 abroad代表海外,只支持国内 - * ] - * - * Outputs: - * - * $outputs = [ - * "RequestList" => (array) 请求数实例表。[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnRequest" => (number) 返回值返回指定时间区间内的cdn收到的请求次数之和 - * "OriginRequest" => (number) 返回值返回指定时间区间内的cdn回源的请求次数之和 - * ] - * ] - * ] - * - * @return GetUcdnDomainRequestNumV2Response - * @throws UCloudException - */ - public function getUcdnDomainRequestNumV2(GetUcdnDomainRequestNumV2Request $request = null) - { - $resp = $this->invoke($request); - return new GetUcdnDomainRequestNumV2Response($resp->toArray(), $resp->getRequestId()); - } - + + + + /** * GetUcdnDomainRequestNumV3 - 获取域名请求数 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_request_num_v3 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度, 3=按1分钟) - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询区域 cn代表国内 abroad代表海外,只支持国内 - * "Protocol" => (string) 协议,http、https 不传则查所有协议的带宽 - * ] - * - * Outputs: - * - * $outputs = [ - * "RequestList" => (array) 请求数实例表。[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnRequest" => (number) 返回值返回指定时间区间内的cdn收到的请求次数之和 - * ] - * ] - * ] - * - * @return GetUcdnDomainRequestNumV3Response * @throws UCloudException */ public function getUcdnDomainRequestNumV3(GetUcdnDomainRequestNumV3Request $request = null) @@ -1439,107 +485,13 @@ public function getUcdnDomainRequestNumV3(GetUcdnDomainRequestNumV3Request $requ $resp = $this->invoke($request); return new GetUcdnDomainRequestNumV3Response($resp->toArray(), $resp->getRequestId()); } - - /** - * GetUcdnDomainTraffic - 获取加速域名流量使用信息 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_domain_traffic - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "AccountType" => (string) 指定按项目查询,还是按整个账户查询 取值 top 表示按整个账户查询,取值org表示按项目查询 - * "DomainId" => (array) 域名ID,创建加速域名时生成,n从自然数0开始。默认全部域名 - * "Areacode" => (string) 查询流量区域 cn代表国内 abroad代表海外,默认全部区域 - * "BeginTime" => (integer) 查询的起始日期,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值 - * "EndTime" => (integer) 查询的结束日期,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天 - * ] - * - * Outputs: - * - * $outputs = [ - * "TrafficSet" => (array) 流量实例表,具体结构见 UcdnDomainTrafficSet[ - * [ - * "Time" => (integer) 流量获取的时间点,格式为Unix Timestamp - * "Value" => (number) 查询每日流量总值,单位:GB - * ] - * ] - * ] - * - * @return GetUcdnDomainTrafficResponse - * @throws UCloudException - */ - public function getUcdnDomainTraffic(GetUcdnDomainTrafficRequest $request = null) - { - $resp = $this->invoke($request); - return new GetUcdnDomainTrafficResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * GetUcdnPassBandwidth - 获取回源带宽数据(cdn回客户源站部分) - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_pass_bandwidth - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthDetail" => (array) 回源带宽数据[ - * [ - * "Time" => (integer) 宽获取的时间点。格式:时间戳 - * "Bandwidth" => (number) 返回值带宽值数据。 - * ] - * ] - * ] - * - * @return GetUcdnPassBandwidthResponse - * @throws UCloudException - */ - public function getUcdnPassBandwidth(GetUcdnPassBandwidthRequest $request = null) - { - $resp = $this->invoke($request); - return new GetUcdnPassBandwidthResponse($resp->toArray(), $resp->getRequestId()); - } - + + + + /** * GetUcdnPassBandwidthV2 - 获取回源带宽数据(cdn回客户源站部分) * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_pass_bandwidth_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天的粒度,3表示按照1分钟粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Areacode" => (string) 查询带宽区域 cn代表国内 abroad代表海外,只支持国内 - * "BeginTime" => (integer) 查询的起始时间,格式为Unix Timestamp。如果有EndTime,BeginTime必须赋值。如没有赋值,则返回缺少参 数错误,如果没有EndTime,BeginTime也可以不赋值,EndTime默认当前时间,BeginTime 默认前一天的当前时间。 - * "EndTime" => (integer) 查询的结束时间,格式为Unix Timestamp。EndTime默认为当前时间,BeginTime默认为当前时间前一天时间。 - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthList" => (array) 回源带宽数据[ - * [ - * "Time" => (integer) 宽获取的时间点。格式:时间戳 - * "Bandwidth" => (number) 返回值带宽值数据。 - * ] - * ] - * ] - * - * @return GetUcdnPassBandwidthV2Response * @throws UCloudException */ public function getUcdnPassBandwidthV2(GetUcdnPassBandwidthV2Request $request = null) @@ -1547,42 +499,13 @@ public function getUcdnPassBandwidthV2(GetUcdnPassBandwidthV2Request $request = $resp = $this->invoke($request); return new GetUcdnPassBandwidthV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnProIspBandwidthV2 - 按省份运营商获取域名带宽数据 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_pro_isp_bandwidth_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "BeginTime" => (integer) 查询的起始日期,格式为Unix Timestamp - * "EndTime" => (integer) 查询的结束日期,格式为Unix Timestamp - * "Type" => (integer) 时间粒度0 (按5分钟粒度)1 (按小时粒度)2(按天粒度)3(按分钟粒度) - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Province" => (array) 省份代码(省份拼音),可以传多个,不传则查询所有省份 - * "Isp" => (string) 运营商代码(运营商拼音),一次只能查询一个运营商,不传递默认取所有运营商 - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthSet" => (array) 按省份的带宽流量实例表。具体参考下面BandwidthSet[ - * [ - * "Province" => (string) 省份代码 - * "BandwidthTrafficList" => (array) 省份带宽流量实例表[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnBandwidth" => (number) 返回值返回指定时间区间内CDN的带宽峰值,单位Mbps - * "Traffic" => (number) 对应时间粒度的流量,单位字节 - * ] - * ] - * ] - * ] - * ] - * - * @return GetUcdnProIspBandwidthV2Response * @throws UCloudException */ public function getUcdnProIspBandwidthV2(GetUcdnProIspBandwidthV2Request $request = null) @@ -1590,41 +513,13 @@ public function getUcdnProIspBandwidthV2(GetUcdnProIspBandwidthV2Request $reques $resp = $this->invoke($request); return new GetUcdnProIspBandwidthV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUcdnProIspRequestNumV2 - 按省份运营商获取域名请求数 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_pro_isp_request_num_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "BeginTime" => (integer) 查询的起始日期,格式为Unix Timestamp 忽略时间部分 - * "EndTime" => (integer) 查询的结束日期,格式为Unix Timestamp 忽略时间部分 - * "DomainId" => (array) 域名id,创建域名时生成的id。默认全部域名 - * "Province" => (array) 省份代码,可以传多个,不传则查询所有省份 - * "Isp" => (string) 运营商代码,一次只能查询一个运营商,不传递默认取所有运营商 - * "Type" => (integer) 时间粒度(0表示按照5分钟粒度,1表示按照1小时粒度,2表示按照一天粒度,3表示按照一分钟粒度) - * ] - * - * Outputs: - * - * $outputs = [ - * "RequestNumSet" => (array) 按省份的请求数实例表。具体参考下面RequestList[ - * [ - * "Province" => (string) 省份代码 - * "RequestList" => (array) 省份请求数实例表 ProIspRequestListV2[ - * [ - * "Time" => (integer) 带宽获取的时间点。格式:时间戳 - * "CdnRequest" => (number) 返回值返回指定时间区间内的请求数 - * ] - * ] - * ] - * ] - * ] - * - * @return GetUcdnProIspRequestNumV2Response * @throws UCloudException */ public function getUcdnProIspRequestNumV2(GetUcdnProIspRequestNumV2Request $request = null) @@ -1632,65 +527,13 @@ public function getUcdnProIspRequestNumV2(GetUcdnProIspRequestNumV2Request $requ $resp = $this->invoke($request); return new GetUcdnProIspRequestNumV2Response($resp->toArray(), $resp->getRequestId()); } - - /** - * GetUcdnTraffic - 获取流量信息 - * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_traffic - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "TrafficSet" => (array) 用户不同区域的流量信息, 具体结构参见TrafficSet部分[ - * [ - * "Areacode" => (string) 购买流量的区域, cn: 国内; abroad: 国外 - * "TrafficTotal" => (number) Areacode区域内总购买流量, 单位GB - * "TrafficLeft" => (number) Areacode区域内总剩余流量, 单位GB - * "TrafficUsed" => (number) Areacode区域内总使用流量, 单位GB - * ] - * ] - * ] - * - * @return GetUcdnTrafficResponse - * @throws UCloudException - */ - public function getUcdnTraffic(GetUcdnTrafficRequest $request = null) - { - $resp = $this->invoke($request); - return new GetUcdnTrafficResponse($resp->toArray(), $resp->getRequestId()); - } - + + + + /** * GetUcdnTrafficV2 - 获取流量信息 * - * See also: https://docs.ucloud.cn/api/ucdn-api/get_ucdn_traffic_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "TrafficSet" => (array) 用户不同区域的流量信息, 具体结构参见TrafficSet部分[ - * [ - * "Areacode" => (string) 购买流量的区域, cn: 国内; abroad: 国外 - * "TrafficTotal" => (number) Areacode区域内总购买流量, 单位GB - * "TrafficLeft" => (number) Areacode区域内总剩余流量, 单位GB - * "TrafficUsed" => (number) Areacode区域内总使用流量, 单位GB - * ] - * ] - * ] - * - * @return GetUcdnTrafficV2Response * @throws UCloudException */ public function getUcdnTrafficV2(GetUcdnTrafficV2Request $request = null) @@ -1698,26 +541,13 @@ public function getUcdnTrafficV2(GetUcdnTrafficV2Request $request = null) $resp = $this->invoke($request); return new GetUcdnTrafficV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PrefetchNewUcdnDomainCache - 提交预取任务 * - * See also: https://docs.ucloud.cn/api/ucdn-api/prefetch_new_ucdn_domain_cache - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UrlList" => (array) 预热URL列表,n从自然数0开始。UrlList.n字段必须以”http://域名/”开始。如刷新文件目录a下面img.png文件, 格式为http://abc.ucloud.cn/a/img.png。请正确提交需要刷新的域名 - * ] - * - * Outputs: - * - * $outputs = [ - * "TaskId" => (string) 本次提交url对应的任务id - * ] - * - * @return PrefetchNewUcdnDomainCacheResponse * @throws UCloudException */ public function prefetchNewUcdnDomainCache(PrefetchNewUcdnDomainCacheRequest $request = null) @@ -1725,33 +555,13 @@ public function prefetchNewUcdnDomainCache(PrefetchNewUcdnDomainCacheRequest $re $resp = $this->invoke($request); return new PrefetchNewUcdnDomainCacheResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * QueryIpLocation - 查询IP信息 * - * See also: https://docs.ucloud.cn/api/ucdn-api/query_ip_location - * - * Arguments: - * - * $args = [ - * "Ip" => (array) ip列表 - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (array) IP信息列表[ - * [ - * "Ip" => (string) 客户端请求的ip - * "Area" => (string) 地区 - * "Isp" => (string) 运营商 - * "City" => (string) 城市 - * "Exist" => (boolean) ip是否存在 - * ] - * ] - * ] - * - * @return QueryIpLocationResponse * @throws UCloudException */ public function queryIpLocation(QueryIpLocationRequest $request = null) @@ -1759,27 +569,13 @@ public function queryIpLocation(QueryIpLocationRequest $request = null) $resp = $this->invoke($request); return new QueryIpLocationResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RefreshNewUcdnDomainCache - 刷新缓存 * - * See also: https://docs.ucloud.cn/api/ucdn-api/refresh_new_ucdn_domain_cache - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (string) 刷新类型,file代表文件刷新,dir 代表路径刷新 - * "UrlList" => (array) 需要刷新的URL,n 从自然数0开始,刷新多个URL列表时,一次最多提交30个。必须以”http://域名/”开始。目录要以”/”结尾, 如刷新目录a下所有文件,格式为:http://abc.ucloud.cn/a/;如刷新文件目录a下面img.png文件, 格式为http://abc.ucloud.cn/a/img.png。请正确提交需要刷新的域名 - * ] - * - * Outputs: - * - * $outputs = [ - * "TaskId" => (string) 本次提交url对应的任务id - * ] - * - * @return RefreshNewUcdnDomainCacheResponse * @throws UCloudException */ public function refreshNewUcdnDomainCache(RefreshNewUcdnDomainCacheRequest $request = null) @@ -1787,25 +583,13 @@ public function refreshNewUcdnDomainCache(RefreshNewUcdnDomainCacheRequest $requ $resp = $this->invoke($request); return new RefreshNewUcdnDomainCacheResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SwitchUcdnChargeType - 切换账号计费方式 * - * See also: https://docs.ucloud.cn/api/ucdn-api/switch_ucdn_charge_type - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ChargeType" => (string) 计费方式。traffic代表按流量包计费,bandwidth按带宽付费 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SwitchUcdnChargeTypeResponse * @throws UCloudException */ public function switchUcdnChargeType(SwitchUcdnChargeTypeRequest $request = null) diff --git a/src/UDB/Apis/BackupUDBInstanceBinlogRequest.php b/src/UDB/Apis/BackupUDBInstanceBinlogRequest.php index 61ecb562..c848cb20 100644 --- a/src/UDB/Apis/BackupUDBInstanceBinlogRequest.php +++ b/src/UDB/Apis/BackupUDBInstanceBinlogRequest.php @@ -1,6 +1,7 @@ markRequired("BackupFile"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupFile: 需要备份文件,可通过DescribeUDBInstanceBinlog获得 如果要传入多个文件名,以空格键分割,用单引号包含. * @@ -125,11 +122,10 @@ public function getBackupFile() * * @param string $backupFile */ - public function setBackupFile($backupFile) + public function setBackupFile(string $backupFile) { $this->set("BackupFile", $backupFile); } - /** * BackupName: DB备份文件名称 * @@ -145,7 +141,7 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } diff --git a/src/UDB/Apis/BackupUDBInstanceBinlogResponse.php b/src/UDB/Apis/BackupUDBInstanceBinlogResponse.php index 9eb1d794..da296fac 100644 --- a/src/UDB/Apis/BackupUDBInstanceBinlogResponse.php +++ b/src/UDB/Apis/BackupUDBInstanceBinlogResponse.php @@ -1,6 +1,7 @@ markRequired("BackupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupName: 备份名称 * @@ -125,7 +122,7 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } diff --git a/src/UDB/Apis/BackupUDBInstanceErrorLogResponse.php b/src/UDB/Apis/BackupUDBInstanceErrorLogResponse.php index 456c967b..d3c8a5b6 100644 --- a/src/UDB/Apis/BackupUDBInstanceErrorLogResponse.php +++ b/src/UDB/Apis/BackupUDBInstanceErrorLogResponse.php @@ -1,6 +1,7 @@ markRequired("BackupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupName: 备份名称 * @@ -125,11 +122,10 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } - /** * UseBlacklist: 是否使用黑名单备份,默认false * @@ -145,11 +141,10 @@ public function getUseBlacklist() * * @param boolean $useBlacklist */ - public function setUseBlacklist($useBlacklist) + public function setUseBlacklist(bool $useBlacklist) { $this->set("UseBlacklist", $useBlacklist); } - /** * BackupMethod: 使用的备份方式。(快照备份即物理备份。注意只有SSD版本的mysql实例支持设置为snapshot) * @@ -165,11 +160,10 @@ public function getBackupMethod() * * @param string $backupMethod */ - public function setBackupMethod($backupMethod) + public function setBackupMethod(string $backupMethod) { $this->set("BackupMethod", $backupMethod); } - /** * Blacklist: 备份黑名单列表,以 ; 分隔。注意:只有逻辑备份下备份黑名单才生效,快照备份备份黑名单下无效 * @@ -185,11 +179,10 @@ public function getBlacklist() * * @param string $blacklist */ - public function setBlacklist($blacklist) + public function setBlacklist(string $blacklist) { $this->set("Blacklist", $blacklist); } - /** * ForceBackup: true表示逻辑备份时是使用 --force 参数,false表示不使用 --force 参数。物理备份此参数无效。 * @@ -205,7 +198,7 @@ public function getForceBackup() * * @param boolean $forceBackup */ - public function setForceBackup($forceBackup) + public function setForceBackup(bool $forceBackup) { $this->set("ForceBackup", $forceBackup); } diff --git a/src/UDB/Apis/BackupUDBInstanceResponse.php b/src/UDB/Apis/BackupUDBInstanceResponse.php index 937c3165..ad9e2ee6 100644 --- a/src/UDB/Apis/BackupUDBInstanceResponse.php +++ b/src/UDB/Apis/BackupUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("BackupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -87,11 +86,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BeginTime: 过滤条件:起始时间(时间戳) * @@ -107,11 +105,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 过滤条件:结束时间(时间戳) * @@ -127,11 +124,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * BackupName: 备份文件名称 * @@ -147,7 +143,7 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } diff --git a/src/UDB/Apis/BackupUDBInstanceSlowLogResponse.php b/src/UDB/Apis/BackupUDBInstanceSlowLogResponse.php index 6c22be26..23a0bec8 100644 --- a/src/UDB/Apis/BackupUDBInstanceSlowLogResponse.php +++ b/src/UDB/Apis/BackupUDBInstanceSlowLogResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * GroupId: 参数组Id * @@ -125,7 +122,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UDB/Apis/ChangeUDBParamGroupResponse.php b/src/UDB/Apis/ChangeUDBParamGroupResponse.php index 3f5a159e..db6bde1c 100644 --- a/src/UDB/Apis/ChangeUDBParamGroupResponse.php +++ b/src/UDB/Apis/ChangeUDBParamGroupResponse.php @@ -1,6 +1,7 @@ markRequired("SrcDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SrcDBId: 源实例的Id * @@ -104,7 +102,7 @@ public function getSrcDBId() * * @param string $srcDBId */ - public function setSrcDBId($srcDBId) + public function setSrcDBId(string $srcDBId) { $this->set("SrcDBId", $srcDBId); } diff --git a/src/UDB/Apis/CheckRecoverUDBInstanceResponse.php b/src/UDB/Apis/CheckRecoverUDBInstanceResponse.php index d05a4356..8920bcbc 100644 --- a/src/UDB/Apis/CheckRecoverUDBInstanceResponse.php +++ b/src/UDB/Apis/CheckRecoverUDBInstanceResponse.php @@ -1,6 +1,7 @@ set("LastestTime", $lastestTime); } diff --git a/src/UDB/Apis/CheckUDBInstanceToHAAllowanceRequest.php b/src/UDB/Apis/CheckUDBInstanceToHAAllowanceRequest.php index cee13347..550de9ac 100644 --- a/src/UDB/Apis/CheckUDBInstanceToHAAllowanceRequest.php +++ b/src/UDB/Apis/CheckUDBInstanceToHAAllowanceRequest.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -84,7 +83,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/CheckUDBInstanceToHAAllowanceResponse.php b/src/UDB/Apis/CheckUDBInstanceToHAAllowanceResponse.php index ad569793..89315f52 100644 --- a/src/UDB/Apis/CheckUDBInstanceToHAAllowanceResponse.php +++ b/src/UDB/Apis/CheckUDBInstanceToHAAllowanceResponse.php @@ -1,6 +1,7 @@ set("Allowance", $allowance); } diff --git a/src/UDB/Apis/ClearUDBLogRequest.php b/src/UDB/Apis/ClearUDBLogRequest.php index 8cc0a4e1..f15ff412 100644 --- a/src/UDB/Apis/ClearUDBLogRequest.php +++ b/src/UDB/Apis/ClearUDBLogRequest.php @@ -1,6 +1,7 @@ markRequired("LogType"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例的id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * LogType: 日志类型,10-error(暂不支持)、20-slow(暂不支持 )、30-binlog * @@ -125,11 +122,10 @@ public function getLogType() * * @param int $logType */ - public function setLogType($logType) + public function setLogType(int $logType) { $this->set("LogType", $logType); } - /** * BeforeTime: 删除时间点(至少前一天)之前log,采用时间戳(秒),默认当 前时间点前一天 * @@ -145,7 +141,7 @@ public function getBeforeTime() * * @param int $beforeTime */ - public function setBeforeTime($beforeTime) + public function setBeforeTime(int $beforeTime) { $this->set("BeforeTime", $beforeTime); } diff --git a/src/UDB/Apis/ClearUDBLogResponse.php b/src/UDB/Apis/ClearUDBLogResponse.php index f3fa2932..831caa9a 100644 --- a/src/UDB/Apis/ClearUDBLogResponse.php +++ b/src/UDB/Apis/ClearUDBLogResponse.php @@ -1,6 +1,7 @@ markRequired("Port"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -51,11 +52,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -71,11 +71,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -91,11 +90,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: PrimaryDB实例名称,至少6位 * @@ -111,11 +109,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * AdminPassword: 管理员密码 * @@ -131,11 +128,10 @@ public function getAdminPassword() * * @param string $adminPassword */ - public function setAdminPassword($adminPassword) + public function setAdminPassword(string $adminPassword) { $this->set("AdminPassword", $adminPassword); } - /** * DBTypeId: DB类型id对应的字符串形式(例如:mongodb-2.6)注意:当前仅支持mongodb * @@ -151,11 +147,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G - 3000G * @@ -171,11 +166,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * ParamGroupId: DB实例使用的配置参数组id * @@ -191,11 +185,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * MemoryLimit: 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M * @@ -211,11 +204,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * Port: 端口号 * @@ -231,11 +223,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Month * @@ -251,11 +242,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长(N个月),默认值1个月。如果为0,代表购买到月底。 * @@ -271,11 +261,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * AdminUser: 管理员帐户名,默认root * @@ -291,11 +280,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * BackupCount: 备份策略,每周备份数量,默认7次 * @@ -311,11 +299,10 @@ public function getBackupCount() * * @param int $backupCount */ - public function setBackupCount($backupCount) + public function setBackupCount(int $backupCount) { $this->set("BackupCount", $backupCount); } - /** * BackupTime: 备份策略,备份开始时间,单位小时计,默认1点 * @@ -331,11 +318,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupDuration: 备份策略,备份时间间隔,单位小时计,默认24小时 * @@ -351,11 +337,10 @@ public function getBackupDuration() * * @param int $backupDuration */ - public function setBackupDuration($backupDuration) + public function setBackupDuration(int $backupDuration) { $this->set("BackupDuration", $backupDuration); } - /** * UseSSD: 是否使用SSD,默认为true * @@ -371,11 +356,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必选 * @@ -391,11 +375,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * CPU: cpu核数 * @@ -411,11 +394,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * InstanceType: UDB数据库机型 * @@ -431,11 +413,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * SubnetId: 子网ID * @@ -451,11 +432,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC的ID * @@ -471,11 +451,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * ClusterId: 所属分片集群的ID * @@ -491,11 +470,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * CouponId: CouponId.0 代表第一个代金券id,对于传入多个代金券id,后面为 CouponId.1, CouponId.2 以此类推 * diff --git a/src/UDB/Apis/CreateMongoDBReplicaSetResponse.php b/src/UDB/Apis/CreateMongoDBReplicaSetResponse.php index 9c3e0476..bdc6eb0a 100644 --- a/src/UDB/Apis/CreateMongoDBReplicaSetResponse.php +++ b/src/UDB/Apis/CreateMongoDBReplicaSetResponse.php @@ -1,6 +1,7 @@ markRequired("RecoveryTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 实例名称,至少6位 * @@ -106,11 +104,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * SrcDBId: 源实例的Id * @@ -126,11 +123,10 @@ public function getSrcDBId() * * @param string $srcDBId */ - public function setSrcDBId($srcDBId) + public function setSrcDBId(string $srcDBId) { $this->set("SrcDBId", $srcDBId); } - /** * RecoveryTime: 恢复到某个时间点的时间戳(UTC时间格式,默认单位秒) * @@ -146,11 +142,10 @@ public function getRecoveryTime() * * @param int $recoveryTime */ - public function setRecoveryTime($recoveryTime) + public function setRecoveryTime(int $recoveryTime) { $this->set("RecoveryTime", $recoveryTime); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Dynamic * @@ -166,11 +161,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认值1 * @@ -186,11 +180,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UseSSD: 指定是否是否使用SSD,默认使用主库的配置 * @@ -206,11 +199,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * UDBCId: 专区的Id * @@ -226,11 +218,10 @@ public function getUDBCId() * * @param string $udbcId */ - public function setUDBCId($udbcId) + public function setUDBCId(string $udbcId) { $this->set("UDBCId", $udbcId); } - /** * SubnetId: 子网ID * @@ -246,11 +237,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC的ID * @@ -266,11 +256,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * EnableIpV6: 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true * @@ -286,11 +275,10 @@ public function getEnableIpV6() * * @param boolean $enableIpV6 */ - public function setEnableIpV6($enableIpV6) + public function setEnableIpV6(bool $enableIpV6) { $this->set("EnableIpV6", $enableIpV6); } - /** * CouponId: 使用的代金券id * @@ -306,7 +294,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/CreateUDBInstanceByRecoveryResponse.php b/src/UDB/Apis/CreateUDBInstanceByRecoveryResponse.php index 80c99b1c..147f7b7b 100644 --- a/src/UDB/Apis/CreateUDBInstanceByRecoveryResponse.php +++ b/src/UDB/Apis/CreateUDBInstanceByRecoveryResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/CreateUDBInstanceRequest.php b/src/UDB/Apis/CreateUDBInstanceRequest.php index b9ca8af9..11244cc2 100644 --- a/src/UDB/Apis/CreateUDBInstanceRequest.php +++ b/src/UDB/Apis/CreateUDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("MemoryLimit"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -51,11 +52,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -71,11 +71,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -91,11 +90,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 实例名称,至少6位 * @@ -111,11 +109,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * AdminPassword: 管理员密码 * @@ -131,11 +128,10 @@ public function getAdminPassword() * * @param string $adminPassword */ - public function setAdminPassword($adminPassword) + public function setAdminPassword(string $adminPassword) { $this->set("AdminPassword", $adminPassword); } - /** * DBTypeId: DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6,14:postgresql-10.4 * @@ -151,11 +147,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * Port: 端口号,mysql默认3306,mongodb默认27017,postgresql默认5432 * @@ -171,11 +166,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G - 32T * @@ -191,11 +185,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * ParamGroupId: DB实例使用的配置参数组id * @@ -211,11 +204,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * MemoryLimit: 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M/128000M/192000M/256000M/320000M * @@ -231,11 +223,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Month * @@ -251,11 +242,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认值1 * @@ -271,11 +261,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * AdminUser: 管理员帐户名,默认root * @@ -291,11 +280,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * BackupCount: 备份策略,每周备份数量,默认7次 * @@ -311,11 +299,10 @@ public function getBackupCount() * * @param int $backupCount */ - public function setBackupCount($backupCount) + public function setBackupCount(int $backupCount) { $this->set("BackupCount", $backupCount); } - /** * BackupTime: 备份策略,备份开始时间,单位小时计,默认1点 * @@ -331,11 +318,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupDuration: 备份策略,备份时间间隔,单位小时计,默认24小时 * @@ -351,11 +337,10 @@ public function getBackupDuration() * * @param int $backupDuration */ - public function setBackupDuration($backupDuration) + public function setBackupDuration(int $backupDuration) { $this->set("BackupDuration", $backupDuration); } - /** * BackupId: 备份id,如果指定,则表明从备份恢复实例 * @@ -371,11 +356,10 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } - /** * UseSSD: 是否使用SSD,默认为true。目前主要可用区、海外机房、新机房只提供SSD资源,非SSD资源不再提供。 * @@ -391,11 +375,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、“NVMe”,如果UseSSD为true ,则必选 * @@ -411,11 +394,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * InstanceMode: UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例 "HA": 高可用版UDB实例 默认是"Normal" * @@ -431,11 +413,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * UDBCId: 专区ID信息(如果这个参数存在这说明是在专区中创建DB) * @@ -451,11 +432,10 @@ public function getUDBCId() * * @param string $udbcId */ - public function setUDBCId($udbcId) + public function setUDBCId(string $udbcId) { $this->set("UDBCId", $udbcId); } - /** * CPU: cpu核数 * @@ -471,11 +451,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * BackupZone: 跨可用区高可用备库所在可用区,参见 [可用区列表](../summary/regionlist.html) * @@ -491,11 +470,10 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } - /** * SubnetId: 子网ID * @@ -511,11 +489,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC的ID * @@ -531,11 +508,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * DisableSemisync: 是否开启异步高可用,默认不填,可置为true * @@ -551,11 +527,10 @@ public function getDisableSemisync() * * @param boolean $disableSemisync */ - public function setDisableSemisync($disableSemisync) + public function setDisableSemisync(bool $disableSemisync) { $this->set("DisableSemisync", $disableSemisync); } - /** * ClusterRole: 当DB类型(DBTypeId)为mongodb时,需要指定mongo的角色,可选值为configsrv (配置节点),shardsrv (数据节点) * @@ -571,11 +546,10 @@ public function getClusterRole() * * @param string $clusterRole */ - public function setClusterRole($clusterRole) + public function setClusterRole(string $clusterRole) { $this->set("ClusterRole", $clusterRole); } - /** * HAArch: 高可用架构:1) haproxy(默认): 当前仅支持mysql。2) sentinel: 基于vip和哨兵节点的架构,当前支持mysql和pg。 * @@ -591,11 +565,10 @@ public function getHAArch() * * @param string $haArch */ - public function setHAArch($haArch) + public function setHAArch(string $haArch) { $this->set("HAArch", $haArch); } - /** * Tag: 实例所在的业务组名称 * @@ -611,11 +584,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * EnableIpV6: 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true * @@ -631,11 +603,10 @@ public function getEnableIpV6() * * @param boolean $enableIpV6 */ - public function setEnableIpV6($enableIpV6) + public function setEnableIpV6(bool $enableIpV6) { $this->set("EnableIpV6", $enableIpV6); } - /** * CouponId: 使用的代金券id * @@ -651,7 +622,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/CreateUDBInstanceResponse.php b/src/UDB/Apis/CreateUDBInstanceResponse.php index b88c6925..a6ec3244 100644 --- a/src/UDB/Apis/CreateUDBInstanceResponse.php +++ b/src/UDB/Apis/CreateUDBInstanceResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/CreateUDBParamGroupRequest.php b/src/UDB/Apis/CreateUDBParamGroupRequest.php index e3c2d42e..f60dbc6e 100644 --- a/src/UDB/Apis/CreateUDBParamGroupRequest.php +++ b/src/UDB/Apis/CreateUDBParamGroupRequest.php @@ -1,6 +1,7 @@ markRequired("DBTypeId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -68,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -88,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupName: 新配置参数组名称 * @@ -108,11 +106,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * Description: 参数组描述 * @@ -128,11 +125,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * SrcGroupId: 源参数组id * @@ -148,11 +144,10 @@ public function getSrcGroupId() * * @param int $srcGroupId */ - public function setSrcGroupId($srcGroupId) + public function setSrcGroupId(int $srcGroupId) { $this->set("SrcGroupId", $srcGroupId); } - /** * DBTypeId: DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6 * @@ -168,11 +163,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * RegionFlag: 是否是地域级别的配置文件,默认是false * @@ -188,7 +182,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UDB/Apis/CreateUDBParamGroupResponse.php b/src/UDB/Apis/CreateUDBParamGroupResponse.php index 19d4bcac..3836a034 100644 --- a/src/UDB/Apis/CreateUDBParamGroupResponse.php +++ b/src/UDB/Apis/CreateUDBParamGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UDB/Apis/CreateUDBReplicationInstanceRequest.php b/src/UDB/Apis/CreateUDBReplicationInstanceRequest.php index 65778c84..7cad2597 100644 --- a/src/UDB/Apis/CreateUDBReplicationInstanceRequest.php +++ b/src/UDB/Apis/CreateUDBReplicationInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SrcId: primary节点的DBId,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getSrcId() * * @param string $srcId */ - public function setSrcId($srcId) + public function setSrcId(string $srcId) { $this->set("SrcId", $srcId); } - /** * Name: 实例名称,至少6位 * @@ -125,11 +122,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Port: 端口号,默认27017,取值范围3306至65535。 * @@ -145,11 +141,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * IsArbiter: 是否是仲裁节点,默认false,仲裁节点按最小机型创建 * @@ -165,11 +160,10 @@ public function getIsArbiter() * * @param boolean $isArbiter */ - public function setIsArbiter($isArbiter) + public function setIsArbiter(bool $isArbiter) { $this->set("IsArbiter", $isArbiter); } - /** * UseSSD: 是否使用SSD,默认 为 true * @@ -185,11 +179,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * CouponId: 使用的代金券id * @@ -205,7 +198,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/CreateUDBReplicationInstanceResponse.php b/src/UDB/Apis/CreateUDBReplicationInstanceResponse.php index eb5e0b47..8b4b8e01 100644 --- a/src/UDB/Apis/CreateUDBReplicationInstanceResponse.php +++ b/src/UDB/Apis/CreateUDBReplicationInstanceResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/CreateUDBRouteInstanceRequest.php b/src/UDB/Apis/CreateUDBRouteInstanceRequest.php index 4b5016fd..0b7d3b86 100644 --- a/src/UDB/Apis/CreateUDBRouteInstanceRequest.php +++ b/src/UDB/Apis/CreateUDBRouteInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("ConfigsvrId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -50,11 +51,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -70,11 +70,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -90,11 +89,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBTypeId: DB类型id,mongodb按版本细分有1:mongodb-2.4,2:mongodb-2.6,3:mongodb-3.0,4:mongodb-3.2 * @@ -110,11 +108,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * Name: 实例名称,至少6位 * @@ -130,11 +127,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Port: 端口号,mongodb默认27017 * @@ -150,11 +146,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * ParamGroupId: DB实例使用的配置参数组id * @@ -170,11 +165,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * MemoryLimit: 内存限制(MB),目前支持以下几档 600M/1500M/3000M /6000M/15000M/30000M * @@ -190,11 +184,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G - 500G * @@ -210,11 +203,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * ConfigsvrId: 配置服务器的dbid,允许一个或者三个。 * @@ -234,7 +226,6 @@ public function setConfigsvrId(array $configsvrId) { $this->set("ConfigsvrId", $configsvrId); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Month * @@ -250,11 +241,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认值1 * @@ -270,11 +260,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UseSSD: 是否使用SSD,默认为ture * @@ -290,11 +279,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * CouponId: 使用的代金券id * @@ -310,7 +298,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/CreateUDBRouteInstanceResponse.php b/src/UDB/Apis/CreateUDBRouteInstanceResponse.php index 9103c3fc..2af24a11 100644 --- a/src/UDB/Apis/CreateUDBRouteInstanceResponse.php +++ b/src/UDB/Apis/CreateUDBRouteInstanceResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/CreateUDBSlaveRequest.php b/src/UDB/Apis/CreateUDBSlaveRequest.php index a7d75b59..465ca046 100644 --- a/src/UDB/Apis/CreateUDBSlaveRequest.php +++ b/src/UDB/Apis/CreateUDBSlaveRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SrcId: master实例的DBId,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getSrcId() * * @param string $srcId */ - public function setSrcId($srcId) + public function setSrcId(string $srcId) { $this->set("SrcId", $srcId); } - /** * Name: 实例名称,至少6位 * @@ -125,11 +122,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Port: 端口号 * @@ -145,11 +141,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * UseSSD: 是否使用SSD,默认为true * @@ -165,11 +160,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、"PCI-E"、“NVMe”,如果UseSSD为true ,则必选 * @@ -185,11 +179,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * IsLock: 是否锁主库,默认为true * @@ -205,11 +198,10 @@ public function getIsLock() * * @param boolean $isLock */ - public function setIsLock($isLock) + public function setIsLock(bool $isLock) { $this->set("IsLock", $isLock); } - /** * InstanceMode: UDB实例部署模式,可选值如下:Normal: 普通单点实例HA: 高可用部署实例 * @@ -225,11 +217,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * MemoryLimit: 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M/128000M/192000M/256000M/320000M * @@ -245,11 +236,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G - 3000G(API支持,前端暂时只开放内存定制) * @@ -265,11 +255,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * InstanceType: UDB实例类型:Normal、SATA_SSD、NVMe_SSD * @@ -285,11 +274,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * SubnetId: 子网ID(如果不传用默认子网) * @@ -305,11 +293,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPCID(如果不传用默认的VPC) * @@ -325,11 +312,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认和主库保持一致 * @@ -345,11 +331,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认默认和主库保持一致 * @@ -365,11 +350,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ParamGroupId: DB实例使用的配置参数组id,默认和主库保持一致 * @@ -385,11 +369,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * CouponId: 使用的代金券id * @@ -405,7 +388,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/CreateUDBSlaveResponse.php b/src/UDB/Apis/CreateUDBSlaveResponse.php index 7e32d5bc..f53c3ee3 100644 --- a/src/UDB/Apis/CreateUDBSlaveResponse.php +++ b/src/UDB/Apis/CreateUDBSlaveResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/DeleteUDBInstanceRequest.php b/src/UDB/Apis/DeleteUDBInstanceRequest.php index f5441619..fbc793d0 100644 --- a/src/UDB/Apis/DeleteUDBInstanceRequest.php +++ b/src/UDB/Apis/DeleteUDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例的id,该值可以通过DescribeUDBInstance获取 * @@ -104,11 +102,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * UDBCId: 专区ID * @@ -124,7 +121,7 @@ public function getUDBCId() * * @param string $udbcId */ - public function setUDBCId($udbcId) + public function setUDBCId(string $udbcId) { $this->set("UDBCId", $udbcId); } diff --git a/src/UDB/Apis/DeleteUDBInstanceResponse.php b/src/UDB/Apis/DeleteUDBInstanceResponse.php index 75393e2e..053c14fe 100644 --- a/src/UDB/Apis/DeleteUDBInstanceResponse.php +++ b/src/UDB/Apis/DeleteUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BackupId: 日志包id,可通过DescribeUDBLogPackage获得 * @@ -105,11 +103,10 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } - /** * BackupZone: 跨可用区高可用备库所在可用区 * @@ -125,7 +122,7 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } diff --git a/src/UDB/Apis/DeleteUDBLogPackageResponse.php b/src/UDB/Apis/DeleteUDBLogPackageResponse.php index 23418170..4790c3e6 100644 --- a/src/UDB/Apis/DeleteUDBLogPackageResponse.php +++ b/src/UDB/Apis/DeleteUDBLogPackageResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 参数组id,可通过DescribeUDBParamGroup获取 * @@ -105,11 +103,10 @@ public function getGroupId() * * @param int $groupId */ - public function setGroupId($groupId) + public function setGroupId(int $groupId) { $this->set("GroupId", $groupId); } - /** * RegionFlag: 是否属于地域级别 * @@ -125,7 +122,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UDB/Apis/DeleteUDBParamGroupResponse.php b/src/UDB/Apis/DeleteUDBParamGroupResponse.php index f85b3618..510134fe 100644 --- a/src/UDB/Apis/DeleteUDBParamGroupResponse.php +++ b/src/UDB/Apis/DeleteUDBParamGroupResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -104,7 +102,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/DescribeUDBBackupBlacklistResponse.php b/src/UDB/Apis/DescribeUDBBackupBlacklistResponse.php index 17555f0e..680f9286 100644 --- a/src/UDB/Apis/DescribeUDBBackupBlacklistResponse.php +++ b/src/UDB/Apis/DescribeUDBBackupBlacklistResponse.php @@ -1,6 +1,7 @@ set("Blacklist", $blacklist); } diff --git a/src/UDB/Apis/DescribeUDBBackupRequest.php b/src/UDB/Apis/DescribeUDBBackupRequest.php index 210f56b4..d727eaa4 100644 --- a/src/UDB/Apis/DescribeUDBBackupRequest.php +++ b/src/UDB/Apis/DescribeUDBBackupRequest.php @@ -1,6 +1,7 @@ markRequired("Limit"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 分页显示的起始偏移,列表操作则指定 * @@ -105,11 +103,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数,列表操作则指定 * @@ -125,11 +122,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * DBId: DB实例Id,如果指定,则只获取该db的备份信息 该值可以通过DescribeUDBInstance获取 * @@ -145,11 +141,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupType: 备份类型,取值为0或1,0表示自动,1表示手动 * @@ -165,11 +160,10 @@ public function getBackupType() * * @param int $backupType */ - public function setBackupType($backupType) + public function setBackupType(int $backupType) { $this->set("BackupType", $backupType); } - /** * BeginTime: 过滤条件:起始时间(Unix时间戳) * @@ -185,11 +179,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 过滤条件:结束时间(Unix时间戳) * @@ -205,7 +198,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UDB/Apis/DescribeUDBBackupResponse.php b/src/UDB/Apis/DescribeUDBBackupResponse.php index ed3da752..516af950 100644 --- a/src/UDB/Apis/DescribeUDBBackupResponse.php +++ b/src/UDB/Apis/DescribeUDBBackupResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBBackupSet($item)); + array_push($result, new UDBBackupSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 备份信息 参照UDBBackupSet * - * @param UDBBackupSet[] $dataSet + * @param UDBBackupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 满足条件备份总数,如果指定dbid,则是该db备份总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDB/Apis/DescribeUDBBinlogBackupURLRequest.php b/src/UDB/Apis/DescribeUDBBinlogBackupURLRequest.php index e2c50c35..aabffd0d 100644 --- a/src/UDB/Apis/DescribeUDBBinlogBackupURLRequest.php +++ b/src/UDB/Apis/DescribeUDBBinlogBackupURLRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * DBId: DB实例Id * @@ -85,11 +84,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupId: DB实例binlog备份ID,可以从DescribeUDBLogPackage结果当中获得 * @@ -105,7 +103,7 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } diff --git a/src/UDB/Apis/DescribeUDBBinlogBackupURLResponse.php b/src/UDB/Apis/DescribeUDBBinlogBackupURLResponse.php index 65ce0647..2c340e8b 100644 --- a/src/UDB/Apis/DescribeUDBBinlogBackupURLResponse.php +++ b/src/UDB/Apis/DescribeUDBBinlogBackupURLResponse.php @@ -1,6 +1,7 @@ set("BackupPath", $backupPath); } - /** * InnerBackupPath: DB实例备份文件的内网地址 * @@ -57,7 +57,7 @@ public function getInnerBackupPath() * * @param string $innerBackupPath */ - public function setInnerBackupPath($innerBackupPath) + public function setInnerBackupPath(string $innerBackupPath) { $this->set("InnerBackupPath", $innerBackupPath); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBackupStateRequest.php b/src/UDB/Apis/DescribeUDBInstanceBackupStateRequest.php index a290f48b..21075547 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBackupStateRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceBackupStateRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BackupId: 备份记录ID * @@ -105,11 +103,10 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } - /** * BackupZone: 跨可用区高可用备库所在可用区,参见[可用区列表] * @@ -125,7 +122,7 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBackupStateResponse.php b/src/UDB/Apis/DescribeUDBInstanceBackupStateResponse.php index da5db7e0..dadad85c 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBackupStateResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceBackupStateResponse.php @@ -1,6 +1,7 @@ set("State", $state); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBackupURLRequest.php b/src/UDB/Apis/DescribeUDBInstanceBackupURLRequest.php index db4dbaaf..eeec80ec 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBackupURLRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceBackupURLRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupId: DB实例备份ID,该值可以通过DescribeUDBBackup获取 * @@ -125,7 +122,7 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBackupURLResponse.php b/src/UDB/Apis/DescribeUDBInstanceBackupURLResponse.php index 60a5ca7e..cb5a625a 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBackupURLResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceBackupURLResponse.php @@ -1,6 +1,7 @@ set("BackupPath", $backupPath); } - /** * InnerBackupPath: DB实例备份文件内网的地址 * @@ -57,7 +57,7 @@ public function getInnerBackupPath() * * @param string $innerBackupPath */ - public function setInnerBackupPath($innerBackupPath) + public function setInnerBackupPath(string $innerBackupPath) { $this->set("InnerBackupPath", $innerBackupPath); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateRequest.php b/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateRequest.php index 82bde701..6ba1a7cb 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BackupId: 备份记录ID * @@ -105,11 +103,10 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } - /** * BackupZone: 跨可用区高可用备库所在可用区 * @@ -125,7 +122,7 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateResponse.php b/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateResponse.php index a599e702..f03ab75a 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceBinlogBackupStateResponse.php @@ -1,6 +1,7 @@ set("State", $state); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBinlogRequest.php b/src/UDB/Apis/DescribeUDBInstanceBinlogRequest.php index d75e9f3a..b3b31aa5 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBinlogRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceBinlogRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id * @@ -106,11 +104,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BeginTime: 过滤条件:起始时间(时间戳) * @@ -126,11 +123,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 过滤条件:结束时间(时间戳) * @@ -146,7 +142,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UDB/Apis/DescribeUDBInstanceBinlogResponse.php b/src/UDB/Apis/DescribeUDBInstanceBinlogResponse.php index 62091cbc..c14c21bc 100644 --- a/src/UDB/Apis/DescribeUDBInstanceBinlogResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceBinlogResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBInstanceBinlogSet($item)); + array_push($result, new UDBInstanceBinlogSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 获取的Binlog信息列表 UDBInstanceBinlogSet * - * @param UDBInstanceBinlogSet[] $dataSet + * @param UDBInstanceBinlogSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDB/Apis/DescribeUDBInstanceLogRequest.php b/src/UDB/Apis/DescribeUDBInstanceLogRequest.php index 8778a90c..0947b8dc 100644 --- a/src/UDB/Apis/DescribeUDBInstanceLogRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceLogRequest.php @@ -1,6 +1,7 @@ markRequired("LogType"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例ID * @@ -107,11 +105,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BeginTime: 查询的日志开始的时间戳(Unix Timestamp)。对于实时查询,这个参数应该是上次轮询请求时的时间戳,后台会返回从该值到当前时间的日志内容。 * @@ -127,11 +124,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询日志的结束时间戳(Unix Timestamp),对于实时查询不传该值,与BeginTime的差值不超过24小时:(EndTime-BeginTime) < 24*60*60 * @@ -147,11 +143,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * LogType: 查询日志的类型error:错误日志;slow:慢日志 * @@ -167,7 +162,7 @@ public function getLogType() * * @param string $logType */ - public function setLogType($logType) + public function setLogType(string $logType) { $this->set("LogType", $logType); } diff --git a/src/UDB/Apis/DescribeUDBInstanceLogResponse.php b/src/UDB/Apis/DescribeUDBInstanceLogResponse.php index acf20731..ddcad055 100644 --- a/src/UDB/Apis/DescribeUDBInstanceLogResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceLogResponse.php @@ -1,6 +1,7 @@ set("Log", $log); } - /** * NextTime: 此次查询到的日志的下一个时间,用于下一次轮询时的BeginTime参数;如果日志查询结束则返回为空,前端结束查询 * @@ -57,7 +57,7 @@ public function getNextTime() * * @param string $nextTime */ - public function setNextTime($nextTime) + public function setNextTime(string $nextTime) { $this->set("NextTime", $nextTime); } diff --git a/src/UDB/Apis/DescribeUDBInstancePriceRequest.php b/src/UDB/Apis/DescribeUDBInstancePriceRequest.php index e7b7d9cc..725d8d70 100644 --- a/src/UDB/Apis/DescribeUDBInstancePriceRequest.php +++ b/src/UDB/Apis/DescribeUDBInstancePriceRequest.php @@ -1,6 +1,7 @@ markRequired("DBTypeId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MemoryLimit: 内存限制(MB),单位为MB.目前支持:1000-96000 * @@ -87,11 +86,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB),暂时支持20(GB) - 3000(GB), 输入不带单位 * @@ -107,11 +105,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * DBTypeId: UDB实例的DB版本字符串 * @@ -127,11 +124,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * Count: 购买DB实例数量,最大数量为10台, 默认为1台 * @@ -147,11 +143,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * ChargeType: Year,按年付费; Month,按月付费 Dynamic,按需付费(需开启权限) Trial,试用(需开启权限)默认为月付 * @@ -167,11 +162,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: DB购买多少个"计费时间单位",默认值为1。比如:买2个月,Quantity就是2。如果计费单位是“按月”,并且Quantity为0,表示“购买到月底” * @@ -187,11 +181,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UseSSD: 是否使用SSD,只能填true或false,默认为false * @@ -207,11 +200,10 @@ public function getUseSSD() * * @param string $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(string $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必填 * @@ -227,11 +219,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * InstanceMode: 实例的部署类型。可选值为:Normal: 普通单点实例,Slave: 从库实例,HA: 高可用部署实例,默认是Normal * @@ -247,7 +238,7 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } diff --git a/src/UDB/Apis/DescribeUDBInstancePriceResponse.php b/src/UDB/Apis/DescribeUDBInstancePriceResponse.php index c7e43bd5..ec8caf1c 100644 --- a/src/UDB/Apis/DescribeUDBInstancePriceResponse.php +++ b/src/UDB/Apis/DescribeUDBInstancePriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBInstancePriceSet($item)); + array_push($result, new UDBInstancePriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 价格 参照UDBInstancePriceSet * - * @param UDBInstancePriceSet[] $dataSet + * @param UDBInstancePriceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDB/Apis/DescribeUDBInstanceRequest.php b/src/UDB/Apis/DescribeUDBInstanceRequest.php index 149c782c..bd8937b9 100644 --- a/src/UDB/Apis/DescribeUDBInstanceRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区,不填时默认全部可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ClassType: DB种类,如果是列表操作,则需要指定,不区分大小写,其取值如下:mysql: SQL;mongo: NOSQL;postgresql: postgresql * @@ -103,11 +101,10 @@ public function getClassType() * * @param string $classType */ - public function setClassType($classType) + public function setClassType(string $classType) { $this->set("ClassType", $classType); } - /** * Offset: 分页显示起始偏移位置,列表操作时必填 * @@ -123,11 +120,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示数量,列表操作时必填 * @@ -143,11 +139,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * DBId: DB实例id,如果指定则获取单个db实例的描述,否则为列表操作。 指定DBId时无需填写ClassType、Offset、Limit * @@ -163,11 +158,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * IsInUDBC: 是否查看专区里面DB * @@ -183,11 +177,10 @@ public function getIsInUDBC() * * @param boolean $isInUDBC */ - public function setIsInUDBC($isInUDBC) + public function setIsInUDBC(bool $isInUDBC) { $this->set("IsInUDBC", $isInUDBC); } - /** * UDBCId: IsInUDBC为True,UDBCId为空,说明查看整个可用区的专区的db,如果UDBId不为空则只查看此专区下面的db * @@ -203,11 +196,10 @@ public function getUDBCId() * * @param string $udbcId */ - public function setUDBCId($udbcId) + public function setUDBCId(string $udbcId) { $this->set("UDBCId", $udbcId); } - /** * IncludeSlaves: 当只获取这个特定DBId的信息时,如果有该选项,那么把这个DBId实例的所有从库信息一起拉取并返回 * @@ -223,7 +215,7 @@ public function getIncludeSlaves() * * @param boolean $includeSlaves */ - public function setIncludeSlaves($includeSlaves) + public function setIncludeSlaves(bool $includeSlaves) { $this->set("IncludeSlaves", $includeSlaves); } diff --git a/src/UDB/Apis/DescribeUDBInstanceResponse.php b/src/UDB/Apis/DescribeUDBInstanceResponse.php index 865e2532..6aecfa86 100644 --- a/src/UDB/Apis/DescribeUDBInstanceResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBInstanceSet($item)); + array_push($result, new UDBInstanceSetModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getDataSet() /** * DataSet: DB实例信息列表 UDBInstanceSet * - * @param UDBInstanceSet[] $dataSet + * @param UDBInstanceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -56,7 +58,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 用户db组的数量,对于 mysql: 主从结对数量,没有slave,则只有master mongodb: 副本集数量 * @@ -72,7 +73,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDB/Apis/DescribeUDBInstanceStateRequest.php b/src/UDB/Apis/DescribeUDBInstanceStateRequest.php index a6cfd677..c78c293e 100644 --- a/src/UDB/Apis/DescribeUDBInstanceStateRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceStateRequest.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -104,7 +102,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/DescribeUDBInstanceStateResponse.php b/src/UDB/Apis/DescribeUDBInstanceStateResponse.php index 49030f18..c3e12798 100644 --- a/src/UDB/Apis/DescribeUDBInstanceStateResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceStateResponse.php @@ -1,6 +1,7 @@ set("State", $state); } diff --git a/src/UDB/Apis/DescribeUDBInstanceUpgradePriceRequest.php b/src/UDB/Apis/DescribeUDBInstanceUpgradePriceRequest.php index 8134410a..573d84bf 100644 --- a/src/UDB/Apis/DescribeUDBInstanceUpgradePriceRequest.php +++ b/src/UDB/Apis/DescribeUDBInstanceUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("DiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id * @@ -106,11 +104,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * MemoryLimit: 内存限制(MB) * @@ -126,11 +123,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G - 500G * @@ -146,11 +142,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * UseSSD: 是否使用SSD,默认为false * @@ -166,11 +161,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必选 * @@ -186,7 +180,7 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } diff --git a/src/UDB/Apis/DescribeUDBInstanceUpgradePriceResponse.php b/src/UDB/Apis/DescribeUDBInstanceUpgradePriceResponse.php index 9be9dcf9..c2b64263 100644 --- a/src/UDB/Apis/DescribeUDBInstanceUpgradePriceResponse.php +++ b/src/UDB/Apis/DescribeUDBInstanceUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UDB/Apis/DescribeUDBLogBackupURLRequest.php b/src/UDB/Apis/DescribeUDBLogBackupURLRequest.php index 66d8548a..3be7fccd 100644 --- a/src/UDB/Apis/DescribeUDBLogBackupURLRequest.php +++ b/src/UDB/Apis/DescribeUDBLogBackupURLRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupId: DB实例备份ID * @@ -125,7 +122,7 @@ public function getBackupId() * * @param int $backupId */ - public function setBackupId($backupId) + public function setBackupId(int $backupId) { $this->set("BackupId", $backupId); } diff --git a/src/UDB/Apis/DescribeUDBLogBackupURLResponse.php b/src/UDB/Apis/DescribeUDBLogBackupURLResponse.php index b89140d0..5d12f30f 100644 --- a/src/UDB/Apis/DescribeUDBLogBackupURLResponse.php +++ b/src/UDB/Apis/DescribeUDBLogBackupURLResponse.php @@ -1,6 +1,7 @@ set("BackupPath", $backupPath); } - /** * UsernetPath: 备份用户网URL * @@ -57,7 +57,7 @@ public function getUsernetPath() * * @param string $usernetPath */ - public function setUsernetPath($usernetPath) + public function setUsernetPath(string $usernetPath) { $this->set("UsernetPath", $usernetPath); } diff --git a/src/UDB/Apis/DescribeUDBLogPackageRequest.php b/src/UDB/Apis/DescribeUDBLogPackageRequest.php index 2ecdb4d1..4b202ee5 100644 --- a/src/UDB/Apis/DescribeUDBLogPackageRequest.php +++ b/src/UDB/Apis/DescribeUDBLogPackageRequest.php @@ -1,6 +1,7 @@ markRequired("Limit"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 分页显示的起始偏移,列表操作则指定 * @@ -105,11 +103,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数,列表操作则指定 * @@ -125,11 +122,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Type: 需要列出的备份文件类型,每种文件的值如下 2 : BINLOG\_BACKUP 3 : SLOW\_QUERY\_BACKUP 4 : ERRORLOG\_BACKUP * @@ -145,11 +141,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * Types: Types作为Type的补充,支持多值传入,可以获取多个类型的日志记录,如:Types.0=2&Types.1=3 * @@ -169,7 +164,6 @@ public function setTypes(array $types) { $this->set("Types", $types); } - /** * DBId: DB实例Id,如果指定,则只获取该db的备份信息 * @@ -185,11 +179,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BeginTime: 过滤条件:起始时间(时间戳) * @@ -205,11 +198,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 过滤条件:结束时间(时间戳) * @@ -225,7 +217,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UDB/Apis/DescribeUDBLogPackageResponse.php b/src/UDB/Apis/DescribeUDBLogPackageResponse.php index 3ae6fbe2..c68ae619 100644 --- a/src/UDB/Apis/DescribeUDBLogPackageResponse.php +++ b/src/UDB/Apis/DescribeUDBLogPackageResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new LogPackageDataSet($item)); + array_push($result, new LogPackageDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 备份信息 参见LogPackageDataSet * - * @param LogPackageDataSet[] $dataSet + * @param LogPackageDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 备份总数,如果指定dbid,则是该db备份总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDB/Apis/DescribeUDBParamGroupRequest.php b/src/UDB/Apis/DescribeUDBParamGroupRequest.php index 3be3d01c..5438579e 100644 --- a/src/UDB/Apis/DescribeUDBParamGroupRequest.php +++ b/src/UDB/Apis/DescribeUDBParamGroupRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 分页显示的起始偏移,列表操作则指定 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数,列表操作则指定 * @@ -123,11 +120,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * GroupId: 参数组id,如果指定则获取描述,否则是列表操作,需要 指定Offset/Limit * @@ -143,11 +139,10 @@ public function getGroupId() * * @param int $groupId */ - public function setGroupId($groupId) + public function setGroupId(int $groupId) { $this->set("GroupId", $groupId); } - /** * IsInUDBC: 是否选取专区中配置 * @@ -163,11 +158,10 @@ public function getIsInUDBC() * * @param boolean $isInUDBC */ - public function setIsInUDBC($isInUDBC) + public function setIsInUDBC(bool $isInUDBC) { $this->set("IsInUDBC", $isInUDBC); } - /** * RegionFlag: 当请求没有填写Zone时,如果指定为true,表示只拉取跨可用区的相关配置文件,否则,拉取所有机房的配置文件(包括每个单可用区和跨可用区) * @@ -183,11 +177,10 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } - /** * ClassType: 如果未指定GroupId,则可选是否选取特定DB类型的配置(sql, nosql, postgresql, sqlserver) * @@ -203,7 +196,7 @@ public function getClassType() * * @param string $classType */ - public function setClassType($classType) + public function setClassType(string $classType) { $this->set("ClassType", $classType); } diff --git a/src/UDB/Apis/DescribeUDBParamGroupResponse.php b/src/UDB/Apis/DescribeUDBParamGroupResponse.php index 189a1939..9ddeec00 100644 --- a/src/UDB/Apis/DescribeUDBParamGroupResponse.php +++ b/src/UDB/Apis/DescribeUDBParamGroupResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBParamGroupSet($item)); + array_push($result, new UDBParamGroupSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: 参数组列表 参照UDBParamGroupSet * - * @param UDBParamGroupSet[] $dataSet + * @param UDBParamGroupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -55,7 +57,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 参数组总数,列表操作时才会有该参数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDB/Apis/DescribeUDBSplittingInfoRequest.php b/src/UDB/Apis/DescribeUDBSplittingInfoRequest.php index 8e9c15a9..0d2ba028 100644 --- a/src/UDB/Apis/DescribeUDBSplittingInfoRequest.php +++ b/src/UDB/Apis/DescribeUDBSplittingInfoRequest.php @@ -1,6 +1,7 @@ markRequired("MasterDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MasterDBId: DB实例ID * @@ -85,7 +84,7 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } diff --git a/src/UDB/Apis/DescribeUDBSplittingInfoResponse.php b/src/UDB/Apis/DescribeUDBSplittingInfoResponse.php index 64d825cc..0e8e7c06 100644 --- a/src/UDB/Apis/DescribeUDBSplittingInfoResponse.php +++ b/src/UDB/Apis/DescribeUDBSplittingInfoResponse.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * MasterDBId: DB实例ID * @@ -58,11 +59,10 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } - /** * RWIP: 读写分离IP * @@ -78,11 +78,10 @@ public function getRWIP() * * @param string $rwip */ - public function setRWIP($rwip) + public function setRWIP(string $rwip) { $this->set("RWIP", $rwip); } - /** * DelayThreshold: 时间阈值 * @@ -98,11 +97,10 @@ public function getDelayThreshold() * * @param int $delayThreshold */ - public function setDelayThreshold($delayThreshold) + public function setDelayThreshold(int $delayThreshold) { $this->set("DelayThreshold", $delayThreshold); } - /** * Port: 端口号 * @@ -118,11 +116,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * ReadModel: 读写分离策略 * @@ -138,11 +135,10 @@ public function getReadModel() * * @param string $readModel */ - public function setReadModel($readModel) + public function setReadModel(string $readModel) { $this->set("ReadModel", $readModel); } - /** * DBTypeId: 数据库版本 * @@ -158,11 +154,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * RWState: 读写分离状态 * @@ -178,15 +173,14 @@ public function getRWState() * * @param string $rwState */ - public function setRWState($rwState) + public function setRWState(string $rwState) { $this->set("RWState", $rwState); } - /** * DataSet: 读写分离从库信息 * - * @return UDBRWSplittingSet[]|null + * @return UDBRWSplittingSetModel[]|null */ public function getDataSet() { @@ -196,7 +190,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDBRWSplittingSet($item)); + array_push($result, new UDBRWSplittingSetModel($item)); } return $result; } @@ -204,7 +198,7 @@ public function getDataSet() /** * DataSet: 读写分离从库信息 * - * @param UDBRWSplittingSet[] $dataSet + * @param UDBRWSplittingSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDB/Apis/DescribeUDBTypeRequest.php b/src/UDB/Apis/DescribeUDBTypeRequest.php index 45457a55..2f23de3e 100644 --- a/src/UDB/Apis/DescribeUDBTypeRequest.php +++ b/src/UDB/Apis/DescribeUDBTypeRequest.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * BackupZone: 跨可用区高可用DB的备库所在区域,仅当该可用区支持跨可用区高可用时填入。参见 [可用区列表](../summary/regionlist.html) * @@ -84,11 +83,10 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } - /** * DBClusterType: DB实例类型,如mysql,sqlserver,mongo,postgresql * @@ -104,11 +102,10 @@ public function getDBClusterType() * * @param string $dbClusterType */ - public function setDBClusterType($dbClusterType) + public function setDBClusterType(string $dbClusterType) { $this->set("DBClusterType", $dbClusterType); } - /** * InstanceMode: 返回支持某种实例类型的DB类型。如果没传,则表示任何实例类型均可。normal:单点,ha:高可用,sharded_cluster:分片集群 * @@ -124,11 +121,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * DiskType: 返回支持某种磁盘类型的DB类型,如Normal、SSD、NVMe_SSD。如果没传,则表示任何磁盘类型均可。 * @@ -144,11 +140,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * CompatibleWithDBType: 返回从备份创建实例时,该版本号所支持的备份创建版本。如果没传,则表示不是从备份创建。 * @@ -164,7 +159,7 @@ public function getCompatibleWithDBType() * * @param string $compatibleWithDBType */ - public function setCompatibleWithDBType($compatibleWithDBType) + public function setCompatibleWithDBType(string $compatibleWithDBType) { $this->set("CompatibleWithDBType", $compatibleWithDBType); } diff --git a/src/UDB/Apis/DescribeUDBTypeResponse.php b/src/UDB/Apis/DescribeUDBTypeResponse.php index 87e45472..91d82ad6 100644 --- a/src/UDB/Apis/DescribeUDBTypeResponse.php +++ b/src/UDB/Apis/DescribeUDBTypeResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDBTypeSet($item)); + array_push($result, new UDBTypeSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: DB类型列表 参数见 UDBTypeSet * - * @param UDBTypeSet[] $dataSet + * @param UDBTypeSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDB/Apis/DisableUDBRWSplittingRequest.php b/src/UDB/Apis/DisableUDBRWSplittingRequest.php index 340c67f2..a9336202 100644 --- a/src/UDB/Apis/DisableUDBRWSplittingRequest.php +++ b/src/UDB/Apis/DisableUDBRWSplittingRequest.php @@ -1,6 +1,7 @@ markRequired("MasterDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MasterDBId: DB实例ID(master) * @@ -85,7 +84,7 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } diff --git a/src/UDB/Apis/DisableUDBRWSplittingResponse.php b/src/UDB/Apis/DisableUDBRWSplittingResponse.php index a6533725..ac478dae 100644 --- a/src/UDB/Apis/DisableUDBRWSplittingResponse.php +++ b/src/UDB/Apis/DisableUDBRWSplittingResponse.php @@ -1,6 +1,7 @@ markRequired("Blacklist"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * Blacklist: 黑名单,规范示例,指定库mysql.%;test.%; 指定表city.address; * @@ -125,7 +122,7 @@ public function getBlacklist() * * @param string $blacklist */ - public function setBlacklist($blacklist) + public function setBlacklist(string $blacklist) { $this->set("Blacklist", $blacklist); } diff --git a/src/UDB/Apis/EditUDBBackupBlacklistResponse.php b/src/UDB/Apis/EditUDBBackupBlacklistResponse.php index ff92680f..865ede6f 100644 --- a/src/UDB/Apis/EditUDBBackupBlacklistResponse.php +++ b/src/UDB/Apis/EditUDBBackupBlacklistResponse.php @@ -1,6 +1,7 @@ markRequired("MasterDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MasterDBId: DB实例ID(主库) * @@ -85,11 +84,10 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } - /** * BackupZone: 备份的可用区。用于创建跨可用区读写分离的一个节点,跨机房的读写分离必须有这个参数 * @@ -105,7 +103,7 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } diff --git a/src/UDB/Apis/EnableUDBRWSplittingResponse.php b/src/UDB/Apis/EnableUDBRWSplittingResponse.php index 0cb9c920..5916962c 100644 --- a/src/UDB/Apis/EnableUDBRWSplittingResponse.php +++ b/src/UDB/Apis/EnableUDBRWSplittingResponse.php @@ -1,6 +1,7 @@ set("MasterDBId", $masterDBId); } - /** * RWIp: 读写分离访问IP * @@ -57,7 +57,7 @@ public function getRWIp() * * @param string $rwIp */ - public function setRWIp($rwIp) + public function setRWIp(string $rwIp) { $this->set("RWIp", $rwIp); } diff --git a/src/UDB/Apis/ExtractUDBParamGroupRequest.php b/src/UDB/Apis/ExtractUDBParamGroupRequest.php index fb43961a..42435aa6 100644 --- a/src/UDB/Apis/ExtractUDBParamGroupRequest.php +++ b/src/UDB/Apis/ExtractUDBParamGroupRequest.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。如果RegionFlag=false,必须传,反之,可不传。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * GroupId: 配置id * @@ -84,11 +83,10 @@ public function getGroupId() * * @param int $groupId */ - public function setGroupId($groupId) + public function setGroupId(int $groupId) { $this->set("GroupId", $groupId); } - /** * RegionFlag: 是否跨可用区,RegionFlag为true时表示跨可用区配置文件。如果RegionFlag=true,Zone可以不传,否则Zone必须传。 * @@ -104,7 +102,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UDB/Apis/ExtractUDBParamGroupResponse.php b/src/UDB/Apis/ExtractUDBParamGroupResponse.php index add018c5..a2c20d64 100644 --- a/src/UDB/Apis/ExtractUDBParamGroupResponse.php +++ b/src/UDB/Apis/ExtractUDBParamGroupResponse.php @@ -1,6 +1,7 @@ set("Content", $content); } diff --git a/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeRequest.php b/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeRequest.php index 223db57c..f248f051 100644 --- a/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeRequest.php +++ b/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeRequest.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: DB实例Id * @@ -104,7 +102,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeResponse.php b/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeResponse.php index b7c96242..061894c9 100644 --- a/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeResponse.php +++ b/src/UDB/Apis/FetchUDBInstanceEarliestRecoverTimeResponse.php @@ -1,6 +1,7 @@ set("EarliestTime", $earliestTime); } diff --git a/src/UDB/Apis/GetUDBClientConnNumRequest.php b/src/UDB/Apis/GetUDBClientConnNumRequest.php new file mode 100644 index 00000000..c4b3090f --- /dev/null +++ b/src/UDB/Apis/GetUDBClientConnNumRequest.php @@ -0,0 +1,110 @@ + "GetUDBClientConnNum"]); + $this->markRequired("Region"); + $this->markRequired("Zone"); + $this->markRequired("DBId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * DBId: DB实例id + * + * @return string|null + */ + public function getDBId() + { + return $this->get("DBId"); + } + + /** + * DBId: DB实例id + * + * @param string $dbId + */ + public function setDBId(string $dbId) + { + $this->set("DBId", $dbId); + } +} diff --git a/src/UCDN/Apis/GetUcdnPassBandwidthResponse.php b/src/UDB/Apis/GetUDBClientConnNumResponse.php similarity index 60% rename from src/UCDN/Apis/GetUcdnPassBandwidthResponse.php rename to src/UDB/Apis/GetUDBClientConnNumResponse.php index 35229d44..b3f2eb49 100644 --- a/src/UCDN/Apis/GetUcdnPassBandwidthResponse.php +++ b/src/UDB/Apis/GetUDBClientConnNumResponse.php @@ -1,6 +1,7 @@ get("BandwidthDetail"); + $items = $this->get("DataSet"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new BandwidthInfoDetail($item)); + array_push($result, new ConnNumMapModel($item)); } return $result; } /** - * BandwidthDetail: 回源带宽数据 + * DataSet: db实例ip和连接数信息 * - * @param BandwidthInfoDetail[] $bandwidthDetail + * @param ConnNumMapModel[] $dataSet */ - public function setBandwidthDetail(array $bandwidthDetail) + public function setDataSet(array $dataSet) { $result = []; - foreach ($bandwidthDetail as $i => $item) { + foreach ($dataSet as $i => $item) { array_push($result, $item->getAll()); } return $result; diff --git a/src/UDB/Apis/ModifyUDBInstanceNameRequest.php b/src/UDB/Apis/ModifyUDBInstanceNameRequest.php index ddfa17ac..1f2b983c 100644 --- a/src/UDB/Apis/ModifyUDBInstanceNameRequest.php +++ b/src/UDB/Apis/ModifyUDBInstanceNameRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * Name: 实例的新名字, 长度要求为6~63位 * @@ -125,7 +122,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UDB/Apis/ModifyUDBInstanceNameResponse.php b/src/UDB/Apis/ModifyUDBInstanceNameResponse.php index 23c8937a..2f10ef93 100644 --- a/src/UDB/Apis/ModifyUDBInstanceNameResponse.php +++ b/src/UDB/Apis/ModifyUDBInstanceNameResponse.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的ID,该值可以通过DescribeUDBInstance获取 * @@ -105,11 +103,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * Password: 实例的新密码 * @@ -125,11 +122,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * AccountName: sqlserver帐号,仅在sqlserver的情况下填该参数 * @@ -145,7 +141,7 @@ public function getAccountName() * * @param string $accountName */ - public function setAccountName($accountName) + public function setAccountName(string $accountName) { $this->set("AccountName", $accountName); } diff --git a/src/UDB/Apis/ModifyUDBInstancePasswordResponse.php b/src/UDB/Apis/ModifyUDBInstancePasswordResponse.php index 98bd8607..42e6552a 100644 --- a/src/UDB/Apis/ModifyUDBInstancePasswordResponse.php +++ b/src/UDB/Apis/ModifyUDBInstancePasswordResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -84,7 +83,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/PromoteUDBInstanceToHAResponse.php b/src/UDB/Apis/PromoteUDBInstanceToHAResponse.php index dab17b9b..d77dcd5d 100644 --- a/src/UDB/Apis/PromoteUDBInstanceToHAResponse.php +++ b/src/UDB/Apis/PromoteUDBInstanceToHAResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -104,11 +102,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * IsForce: 是否强制(如果从库落后可能会禁止提升),默认false 如果落后情况下,强制提升丢失数据 * @@ -124,7 +121,7 @@ public function getIsForce() * * @param boolean $isForce */ - public function setIsForce($isForce) + public function setIsForce(bool $isForce) { $this->set("IsForce", $isForce); } diff --git a/src/UDB/Apis/PromoteUDBSlaveResponse.php b/src/UDB/Apis/PromoteUDBSlaveResponse.php index b145b388..a03b470e 100644 --- a/src/UDB/Apis/PromoteUDBSlaveResponse.php +++ b/src/UDB/Apis/PromoteUDBSlaveResponse.php @@ -1,6 +1,7 @@ markRequired("DiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id * @@ -106,11 +104,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * MemoryLimit: 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/ 12000M/16000M/ 24000M/32000M/ 48000M/64000M/96000M/128000M/192000M/256000M/320000M。 * @@ -126,11 +123,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 暂时支持20G-32T * @@ -146,11 +142,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * UseSSD: 是否使用SSD,默认为true * @@ -166,11 +161,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,可选值为"SATA"、"PCI-E"、“NVMe”,如果UseSSD为true ,则必选 * @@ -186,11 +180,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * UDBCId: 专区的ID,如果有值表示专区中的DB配置升降级 * @@ -206,11 +199,10 @@ public function getUDBCId() * * @param string $udbcId */ - public function setUDBCId($udbcId) + public function setUDBCId(string $udbcId) { $this->set("UDBCId", $udbcId); } - /** * InstanceType: UDB数据库机型: "Normal": "标准机型" , "SATA_SSD": "SSD机型" , "PCIE_SSD": "SSD高性能机型" , "Normal_Volume": "标准大容量机型", "SATA_SSD_Volume": "SSD大容量机型" , "PCIE_SSD_Volume": "SSD高性能大容量机型",“NVMe_SSD”:“快杰机型” * @@ -226,11 +218,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * InstanceMode: UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例 "HA": 高可用版UDB实例 默认是"Normal" * @@ -246,11 +237,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * StartAfterUpgrade: DB关闭状态下升降级,升降级后是否启动DB,默认为false * @@ -266,11 +256,10 @@ public function getStartAfterUpgrade() * * @param boolean $startAfterUpgrade */ - public function setStartAfterUpgrade($startAfterUpgrade) + public function setStartAfterUpgrade(bool $startAfterUpgrade) { $this->set("StartAfterUpgrade", $startAfterUpgrade); } - /** * CouponId: 使用的代金券id * @@ -286,7 +275,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDB/Apis/ResizeUDBInstanceResponse.php b/src/UDB/Apis/ResizeUDBInstanceResponse.php index 2d10e8e0..d8794f2d 100644 --- a/src/UDB/Apis/ResizeUDBInstanceResponse.php +++ b/src/UDB/Apis/ResizeUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("MasterDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MasterDBId: 待关闭读写分离中间键ProxyId * @@ -85,7 +84,7 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } diff --git a/src/UDB/Apis/RestartRWSplittingResponse.php b/src/UDB/Apis/RestartRWSplittingResponse.php index 8091fbdc..29752ed3 100644 --- a/src/UDB/Apis/RestartRWSplittingResponse.php +++ b/src/UDB/Apis/RestartRWSplittingResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -104,7 +102,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/RestartUDBInstanceResponse.php b/src/UDB/Apis/RestartUDBInstanceResponse.php index 2ba59f95..a74ecc98 100644 --- a/src/UDB/Apis/RestartUDBInstanceResponse.php +++ b/src/UDB/Apis/RestartUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("DBIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * MasterDBId: DB实例ID(master) * @@ -87,11 +86,10 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } - /** * ReadModel: 读写分离策略 * @@ -107,11 +105,10 @@ public function getReadModel() * * @param string $readModel */ - public function setReadModel($readModel) + public function setReadModel(string $readModel) { $this->set("ReadModel", $readModel); } - /** * DBIds: DBIds.0 代表UDB主节点, DBIds.1 到DBIds.n 代表1到N个从节点 * @@ -131,7 +128,6 @@ public function setDBIds(array $dbIds) { $this->set("DBIds", $dbIds); } - /** * ReadPercents: udb主从节点的只读比例。ReadPercents.0代表主节点的只读比例,ReadPercents.1代表从节点1的读写比例, 以此类推 * @@ -151,7 +147,6 @@ public function setReadPercents(array $readPercents) { $this->set("ReadPercents", $readPercents); } - /** * DelayThreshold: 时间阙值 * @@ -167,7 +162,7 @@ public function getDelayThreshold() * * @param int $delayThreshold */ - public function setDelayThreshold($delayThreshold) + public function setDelayThreshold(int $delayThreshold) { $this->set("DelayThreshold", $delayThreshold); } diff --git a/src/UDB/Apis/SetUDBRWSplittingResponse.php b/src/UDB/Apis/SetUDBRWSplittingResponse.php index 227f0c2f..51cb7415 100644 --- a/src/UDB/Apis/SetUDBRWSplittingResponse.php +++ b/src/UDB/Apis/SetUDBRWSplittingResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -104,7 +102,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/StartUDBInstanceResponse.php b/src/UDB/Apis/StartUDBInstanceResponse.php index 0398dc55..42c35774 100644 --- a/src/UDB/Apis/StartUDBInstanceResponse.php +++ b/src/UDB/Apis/StartUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -104,11 +102,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * ForceToKill: 是否使用强制手段关闭DB,默认是false * @@ -124,7 +121,7 @@ public function getForceToKill() * * @param boolean $forceToKill */ - public function setForceToKill($forceToKill) + public function setForceToKill(bool $forceToKill) { $this->set("ForceToKill", $forceToKill); } diff --git a/src/UDB/Apis/StopUDBInstanceResponse.php b/src/UDB/Apis/StopUDBInstanceResponse.php index 5ed8e521..2f63c1e5 100644 --- a/src/UDB/Apis/StopUDBInstanceResponse.php +++ b/src/UDB/Apis/StopUDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -41,17 +42,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -61,17 +61,16 @@ public function getZone() } /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -81,15 +80,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: UDB的实例ID * @@ -105,8 +103,27 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } + /** + * ForceSwitch: 是否跳过预检查强制升级。 + * + * @return boolean|null + */ + public function getForceSwitch() + { + return $this->get("ForceSwitch"); + } + + /** + * ForceSwitch: 是否跳过预检查强制升级。 + * + * @param boolean $forceSwitch + */ + public function setForceSwitch(bool $forceSwitch) + { + $this->set("ForceSwitch", $forceSwitch); + } } diff --git a/src/UDB/Apis/SwitchUDBHAToSentinelResponse.php b/src/UDB/Apis/SwitchUDBHAToSentinelResponse.php index 7ede4c09..9eb62c26 100644 --- a/src/UDB/Apis/SwitchUDBHAToSentinelResponse.php +++ b/src/UDB/Apis/SwitchUDBHAToSentinelResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -84,11 +83,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * ChargeType: Year, Month, Dynamic,Trial,不填则按现在单点计费执行 * @@ -104,11 +102,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,需要和 ChargeType 搭配使用,否则使用单点计费策略的值 * @@ -124,11 +121,10 @@ public function getQuantity() * * @param string $quantity */ - public function setQuantity($quantity) + public function setQuantity(string $quantity) { $this->set("Quantity", $quantity); } - /** * Tag: 业务组 * @@ -144,7 +140,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/UDB/Apis/SwitchUDBInstanceToHAResponse.php b/src/UDB/Apis/SwitchUDBInstanceToHAResponse.php index a2ad7d55..805b359d 100644 --- a/src/UDB/Apis/SwitchUDBInstanceToHAResponse.php +++ b/src/UDB/Apis/SwitchUDBInstanceToHAResponse.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } diff --git a/src/UDB/Apis/UpdateUDBInstanceBackupStrategyRequest.php b/src/UDB/Apis/UpdateUDBInstanceBackupStrategyRequest.php index 7ceee594..046e2a48 100644 --- a/src/UDB/Apis/UpdateUDBInstanceBackupStrategyRequest.php +++ b/src/UDB/Apis/UpdateUDBInstanceBackupStrategyRequest.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 主节点的Id * @@ -104,11 +102,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * BackupTime: 备份的整点时间,范围[0,23] * @@ -124,11 +121,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupDate: 备份时期标记位。共7位,每一位为一周中一天的备份情况,0表示关闭当天备份,1表示打开当天备份。最右边的一位为星期天的备份开关,其余从右到左依次为星期一到星期六的备份配置开关,每周必须至少设置两天备份。例如:1100000表示打开星期六和星期五的备份功能 * @@ -144,11 +140,10 @@ public function getBackupDate() * * @param string $backupDate */ - public function setBackupDate($backupDate) + public function setBackupDate(string $backupDate) { $this->set("BackupDate", $backupDate); } - /** * ForceDump: 当导出某些数据遇到问题后,是否强制导出其他剩余数据默认是false需要同时设置BackupDate字段 * @@ -164,11 +159,10 @@ public function getForceDump() * * @param boolean $forceDump */ - public function setForceDump($forceDump) + public function setForceDump(bool $forceDump) { $this->set("ForceDump", $forceDump); } - /** * BackupMethod: 选择默认的备份方式,可选 snapshot 表示使用快照/物理备份,不填或者其它任何值为默认的逻辑备份。需要同时设置BackupDate字段。(注意现在只有SSD 版本的 MySQL实例支持物理备份) * @@ -184,7 +178,7 @@ public function getBackupMethod() * * @param string $backupMethod */ - public function setBackupMethod($backupMethod) + public function setBackupMethod(string $backupMethod) { $this->set("BackupMethod", $backupMethod); } diff --git a/src/UDB/Apis/UpdateUDBInstanceBackupStrategyResponse.php b/src/UDB/Apis/UpdateUDBInstanceBackupStrategyResponse.php index 68b48d9c..14912b34 100644 --- a/src/UDB/Apis/UpdateUDBInstanceBackupStrategyResponse.php +++ b/src/UDB/Apis/UpdateUDBInstanceBackupStrategyResponse.php @@ -1,6 +1,7 @@ markRequired("BackupSwitch"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * MasterDBId: 主库的Id * @@ -105,11 +103,10 @@ public function getMasterDBId() * * @param string $masterDBId */ - public function setMasterDBId($masterDBId) + public function setMasterDBId(string $masterDBId) { $this->set("MasterDBId", $masterDBId); } - /** * BackupSwitch: 从库的备份开关,范围[0,1],0表示从库备份功能关闭,1 表示从库备份开关打开。 * @@ -125,11 +122,10 @@ public function getBackupSwitch() * * @param int $backupSwitch */ - public function setBackupSwitch($backupSwitch) + public function setBackupSwitch(int $backupSwitch) { $this->set("BackupSwitch", $backupSwitch); } - /** * SlaveDBId: 从库的Id,如果从库备份开关设定为打开,则必须赋值。 * @@ -145,7 +141,7 @@ public function getSlaveDBId() * * @param string $slaveDBId */ - public function setSlaveDBId($slaveDBId) + public function setSlaveDBId(string $slaveDBId) { $this->set("SlaveDBId", $slaveDBId); } diff --git a/src/UDB/Apis/UpdateUDBInstanceSlaveBackupSwitchResponse.php b/src/UDB/Apis/UpdateUDBInstanceSlaveBackupSwitchResponse.php index 02146f4c..8230a3b1 100644 --- a/src/UDB/Apis/UpdateUDBInstanceSlaveBackupSwitchResponse.php +++ b/src/UDB/Apis/UpdateUDBInstanceSlaveBackupSwitchResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 配置参数组id,使用DescribeUDBParamGroup获得 * @@ -105,11 +103,10 @@ public function getGroupId() * * @param int $groupId */ - public function setGroupId($groupId) + public function setGroupId(int $groupId) { $this->set("GroupId", $groupId); } - /** * Key: 参数名称(与Value配合使用) * @@ -125,11 +122,10 @@ public function getKey() * * @param string $key */ - public function setKey($key) + public function setKey(string $key) { $this->set("Key", $key); } - /** * Value: 参数值(与Key配合使用) * @@ -145,11 +141,10 @@ public function getValue() * * @param string $value */ - public function setValue($value) + public function setValue(string $value) { $this->set("Value", $value); } - /** * Name: 配置文件的名字,不传时认为不修改名字,传了则不能为空 * @@ -165,11 +160,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Description: 配置文件的描述,不传时认为不修改 * @@ -185,11 +179,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * RegionFlag: 该配置文件是否是地域级别配置文件,默认是false * @@ -205,7 +198,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UDB/Apis/UpdateUDBParamGroupResponse.php b/src/UDB/Apis/UpdateUDBParamGroupResponse.php index 3b0e2ae3..ab4b6532 100644 --- a/src/UDB/Apis/UpdateUDBParamGroupResponse.php +++ b/src/UDB/Apis/UpdateUDBParamGroupResponse.php @@ -1,6 +1,7 @@ markRequired("DBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBId: 实例的Id,该值可以通过DescribeUDBInstance获取 * @@ -105,7 +103,7 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } diff --git a/src/UDB/Apis/UpgradeUDBInstanceToHAResponse.php b/src/UDB/Apis/UpgradeUDBInstanceToHAResponse.php index 0d1fbc5a..0715d0d8 100644 --- a/src/UDB/Apis/UpgradeUDBInstanceToHAResponse.php +++ b/src/UDB/Apis/UpgradeUDBInstanceToHAResponse.php @@ -1,6 +1,7 @@ markRequired("Content"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -68,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -88,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBTypeId: DB类型id,DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6 * @@ -108,11 +106,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * GroupName: 配置参数组名称 * @@ -128,11 +125,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * Description: 参数组描述 * @@ -148,11 +144,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * Content: 配置内容,导入的配置内容采用base64编码 * @@ -168,11 +163,10 @@ public function getContent() * * @param string $content */ - public function setContent($content) + public function setContent(string $content) { $this->set("Content", $content); } - /** * RegionFlag: 该配置文件是否是地域级别配置文件,默认是false * @@ -188,7 +182,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UDB/Apis/UploadUDBParamGroupResponse.php b/src/UDB/Apis/UploadUDBParamGroupResponse.php index b7e7e312..e420e343 100644 --- a/src/UDB/Apis/UploadUDBParamGroupResponse.php +++ b/src/UDB/Apis/UploadUDBParamGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UDB/Models/ConnNumMap.php b/src/UDB/Models/ConnNumMap.php new file mode 100644 index 00000000..29aeaaab --- /dev/null +++ b/src/UDB/Models/ConnNumMap.php @@ -0,0 +1,66 @@ +get("Ip"); + } + + /** + * Ip: 客户端IP + * + * @param string $ip + */ + public function setIp(string $ip) + { + $this->set("Ip", $ip); + } + /** + * Num: 该Ip连接数 + * + * @return integer|null + */ + public function getNum() + { + return $this->get("Num"); + } + + /** + * Num: 该Ip连接数 + * + * @param int $num + */ + public function setNum(int $num) + { + $this->set("Num", $num); + } +} diff --git a/src/UDB/Models/LogPackageDataSet.php b/src/UDB/Models/LogPackageDataSet.php index ccb3ef61..7e4cb683 100644 --- a/src/UDB/Models/LogPackageDataSet.php +++ b/src/UDB/Models/LogPackageDataSet.php @@ -1,6 +1,7 @@ set("BackupId", $backupId); } - /** * BackupName: 备份名称 * @@ -57,11 +59,10 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } - /** * BackupTime: 备份时间 * @@ -77,11 +78,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupSize: 备份文件大小 * @@ -97,11 +97,10 @@ public function getBackupSize() * * @param int $backupSize */ - public function setBackupSize($backupSize) + public function setBackupSize(int $backupSize) { $this->set("BackupSize", $backupSize); } - /** * BackupType: 备份类型,包括2-binlog备份,3-slowlog备份 * @@ -117,11 +116,10 @@ public function getBackupType() * * @param int $backupType */ - public function setBackupType($backupType) + public function setBackupType(int $backupType) { $this->set("BackupType", $backupType); } - /** * State: 备份状态 Backuping // 备份中 Success // 备份成功 Failed // 备份失败 Expired // 备份过期 * @@ -137,11 +135,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * DBId: dbid * @@ -157,11 +154,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * DBName: 对应的db名称 * @@ -177,11 +173,10 @@ public function getDBName() * * @param string $dbName */ - public function setDBName($dbName) + public function setDBName(string $dbName) { $this->set("DBName", $dbName); } - /** * Zone: 所在可用区 * @@ -197,11 +192,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * BackupZone: 跨可用区高可用备库所在可用区 * @@ -217,7 +211,7 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } diff --git a/src/UDB/Models/UDBBackupSet.php b/src/UDB/Models/UDBBackupSet.php index 52433edc..25b48756 100644 --- a/src/UDB/Models/UDBBackupSet.php +++ b/src/UDB/Models/UDBBackupSet.php @@ -1,6 +1,7 @@ set("BackupId", $backupId); } - /** * BackupName: 备份名称 * @@ -57,11 +59,10 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } - /** * BackupTime: 备份时间(Unix时间戳) * @@ -77,11 +78,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupSize: 备份文件大小(字节) * @@ -97,11 +97,10 @@ public function getBackupSize() * * @param int $backupSize */ - public function setBackupSize($backupSize) + public function setBackupSize(int $backupSize) { $this->set("BackupSize", $backupSize); } - /** * BackupType: 备份类型,取值为0或1,0表示自动,1表示手动 * @@ -117,11 +116,10 @@ public function getBackupType() * * @param int $backupType */ - public function setBackupType($backupType) + public function setBackupType(int $backupType) { $this->set("BackupType", $backupType); } - /** * State: 备份状态 Backuping // 备份中 Success // 备份成功 Failed // 备份失败 Expired // 备份过期 * @@ -137,11 +135,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * DBId: dbid * @@ -157,11 +154,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * DBName: 对应的db名称 * @@ -177,11 +173,10 @@ public function getDBName() * * @param string $dbName */ - public function setDBName($dbName) + public function setDBName(string $dbName) { $this->set("DBName", $dbName); } - /** * Zone: 备份所在可用区 * @@ -197,11 +192,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * BackupZone: 跨机房高可用备库所在可用区 * @@ -217,11 +211,10 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } - /** * BackupEndTime: 备份完成时间(Unix时间戳) * @@ -237,7 +230,7 @@ public function getBackupEndTime() * * @param int $backupEndTime */ - public function setBackupEndTime($backupEndTime) + public function setBackupEndTime(int $backupEndTime) { $this->set("BackupEndTime", $backupEndTime); } diff --git a/src/UDB/Models/UDBInstanceBinlogSet.php b/src/UDB/Models/UDBInstanceBinlogSet.php index 0f18d22c..83ee3aee 100644 --- a/src/UDB/Models/UDBInstanceBinlogSet.php +++ b/src/UDB/Models/UDBInstanceBinlogSet.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * Size: Binlog文件大小 * @@ -57,11 +59,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * BeginTime: Binlog文件生成时间(时间戳) * @@ -77,11 +78,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: Binlog文件结束时间(时间戳) * @@ -97,7 +97,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UDB/Models/UDBInstancePriceSet.php b/src/UDB/Models/UDBInstancePriceSet.php index 95060ccc..457d88db 100644 --- a/src/UDB/Models/UDBInstancePriceSet.php +++ b/src/UDB/Models/UDBInstancePriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 价格,单位为分 * @@ -57,7 +59,7 @@ public function getPrice() * * @param int $price */ - public function setPrice($price) + public function setPrice(int $price) { $this->set("Price", $price); } diff --git a/src/UDB/Models/UDBInstanceSet.php b/src/UDB/Models/UDBInstanceSet.php index 7b6dc5b1..26358361 100644 --- a/src/UDB/Models/UDBInstanceSet.php +++ b/src/UDB/Models/UDBInstanceSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * ClusterRole: 当DB类型为mongodb时,返回该实例所在集群中的角色,包括:mongos、configsrv_sccc、configsrv_csrs、shardsrv_datanode、shardsrv_arbiter,其中congfigsrv分为sccc和csrs两种模式,shardsrv分为datanode和arbiter两种模式 * @@ -57,11 +62,10 @@ public function getClusterRole() * * @param string $clusterRole */ - public function setClusterRole($clusterRole) + public function setClusterRole(string $clusterRole) { $this->set("ClusterRole", $clusterRole); } - /** * DBId: DB实例id * @@ -77,11 +81,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * Name: 实例名称,至少6位 * @@ -97,11 +100,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * DBTypeId: DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下: 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6, 7:percona-5.6 * @@ -117,11 +119,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * ParamGroupId: DB实例使用的配置参数组id * @@ -137,11 +138,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * AdminUser: 管理员帐户名,默认root * @@ -157,11 +157,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * VirtualIP: DB实例虚ip * @@ -177,11 +176,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * VirtualIPMac: DB实例虚ip的mac地址 * @@ -197,11 +195,10 @@ public function getVirtualIPMac() * * @param string $virtualIPMac */ - public function setVirtualIPMac($virtualIPMac) + public function setVirtualIPMac(string $virtualIPMac) { $this->set("VirtualIPMac", $virtualIPMac); } - /** * VPCId: VPC的ID * @@ -217,11 +214,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网ID * @@ -237,11 +233,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * InstanceType: UDB数据库机型 * @@ -257,11 +252,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * InstanceTypeId: UDB数据库机型ID * @@ -277,11 +271,10 @@ public function getInstanceTypeId() * * @param int $instanceTypeId */ - public function setInstanceTypeId($instanceTypeId) + public function setInstanceTypeId(int $instanceTypeId) { $this->set("InstanceTypeId", $instanceTypeId); } - /** * Tag: 获取资源其他信息 * @@ -297,11 +290,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Port: 端口号,mysql默认3306,mongodb默认27017 * @@ -317,11 +309,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * SrcDBId: 对mysql的slave而言是master的DBId,对master则为空, 对mongodb则是副本集id * @@ -337,11 +328,10 @@ public function getSrcDBId() * * @param string $srcDBId */ - public function setSrcDBId($srcDBId) + public function setSrcDBId(string $srcDBId) { $this->set("SrcDBId", $srcDBId); } - /** * BackupCount: 备份策略,不可修改,备份文件保留的数量,默认7次 * @@ -357,11 +347,10 @@ public function getBackupCount() * * @param int $backupCount */ - public function setBackupCount($backupCount) + public function setBackupCount(int $backupCount) { $this->set("BackupCount", $backupCount); } - /** * BackupBeginTime: 备份策略,不可修改,开始时间,单位小时计,默认3点 * @@ -377,11 +366,10 @@ public function getBackupBeginTime() * * @param int $backupBeginTime */ - public function setBackupBeginTime($backupBeginTime) + public function setBackupBeginTime(int $backupBeginTime) { $this->set("BackupBeginTime", $backupBeginTime); } - /** * BackupDuration: 备份策略,一天内备份时间间隔,单位小时,默认24小时 * @@ -397,11 +385,10 @@ public function getBackupDuration() * * @param int $backupDuration */ - public function setBackupDuration($backupDuration) + public function setBackupDuration(int $backupDuration) { $this->set("BackupDuration", $backupDuration); } - /** * BackupBlacklist: 备份策略,备份黑名单,mongodb则不适用 * @@ -417,11 +404,10 @@ public function getBackupBlacklist() * * @param string $backupBlacklist */ - public function setBackupBlacklist($backupBlacklist) + public function setBackupBlacklist(string $backupBlacklist) { $this->set("BackupBlacklist", $backupBlacklist); } - /** * State: DB状态标记 Init:初始化中,Fail:安装失败,Starting:启动中,Running:运行,Shutdown:关闭中,Shutoff:已关闭,Delete:已删除,Upgrading:升级中,Promoting:提升为独库进行中,Recovering:恢复中,Recover fail:恢复失败 * @@ -437,11 +423,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: DB实例创建时间,采用UTC计时时间戳 * @@ -457,11 +442,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: DB实例修改时间,采用UTC计时时间戳 * @@ -477,11 +461,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * ExpiredTime: DB实例过期时间,采用UTC计时时间戳 * @@ -497,11 +480,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Dynamic * @@ -517,11 +499,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * MemoryLimit: 内存限制(MB),默认根据配置机型 * @@ -537,11 +518,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 默认根据配置机型 * @@ -557,11 +537,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * UseSSD: 是否使用SSD * @@ -577,11 +556,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,SATA/PCI-E/NVMe * @@ -597,11 +575,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * Role: DB实例角色,mysql区分master/slave,mongodb多种角色 * @@ -617,11 +594,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * DiskUsedSize: DB实例磁盘已使用空间,单位GB * @@ -637,11 +613,10 @@ public function getDiskUsedSize() * * @param float $diskUsedSize */ - public function setDiskUsedSize($diskUsedSize) + public function setDiskUsedSize(float $diskUsedSize) { $this->set("DiskUsedSize", $diskUsedSize); } - /** * DataFileSize: DB实例数据文件大小,单位GB * @@ -657,11 +632,10 @@ public function getDataFileSize() * * @param float $dataFileSize */ - public function setDataFileSize($dataFileSize) + public function setDataFileSize(float $dataFileSize) { $this->set("DataFileSize", $dataFileSize); } - /** * SystemFileSize: DB实例系统文件大小,单位GB * @@ -677,11 +651,10 @@ public function getSystemFileSize() * * @param float $systemFileSize */ - public function setSystemFileSize($systemFileSize) + public function setSystemFileSize(float $systemFileSize) { $this->set("SystemFileSize", $systemFileSize); } - /** * LogFileSize: DB实例日志文件大小,单位GB * @@ -697,11 +670,10 @@ public function getLogFileSize() * * @param float $logFileSize */ - public function setLogFileSize($logFileSize) + public function setLogFileSize(float $logFileSize) { $this->set("LogFileSize", $logFileSize); } - /** * BackupDate: 备份日期标记位。共7位,每一位为一周中一天的备份情况 0表示关闭当天备份,1表示打开当天备份。最右边的一位 为星期天的备份开关,其余从右到左依次为星期一到星期 六的备份配置开关,每周必须至少设置两天备份。 例如:1100000 表示打开星期六和星期五的自动备份功能 * @@ -717,11 +689,10 @@ public function getBackupDate() * * @param string $backupDate */ - public function setBackupDate($backupDate) + public function setBackupDate(string $backupDate) { $this->set("BackupDate", $backupDate); } - /** * InstanceMode: UDB实例模式类型, 可选值如下: “Normal”: 普通版UDB实例 “HA”: 高可用版UDB实例 * @@ -737,15 +708,14 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * DataSet: 如果在需要返回从库的场景下,返回该DB实例的所有从库DB实例信息列表。列表中每一个元素的内容同UDBSlaveInstanceSet 。如果这个DB实例没有从库的情况下,此时返回一个空的列表 * - * @return UDBSlaveInstanceSet[]|null + * @return UDBSlaveInstanceSetModel[]|null */ public function getDataSet() { @@ -755,7 +725,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDBSlaveInstanceSet($item)); + array_push($result, new UDBSlaveInstanceSetModel($item)); } return $result; } @@ -763,7 +733,7 @@ public function getDataSet() /** * DataSet: 如果在需要返回从库的场景下,返回该DB实例的所有从库DB实例信息列表。列表中每一个元素的内容同UDBSlaveInstanceSet 。如果这个DB实例没有从库的情况下,此时返回一个空的列表 * - * @param UDBSlaveInstanceSet[] $dataSet + * @param UDBSlaveInstanceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -773,7 +743,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * BackupZone: 跨可用区高可用备库所在可用区 * @@ -789,11 +758,10 @@ public function getBackupZone() * * @param string $backupZone */ - public function setBackupZone($backupZone) + public function setBackupZone(string $backupZone) { $this->set("BackupZone", $backupZone); } - /** * IPv6Address: 该实例的ipv6地址 * @@ -809,27 +777,26 @@ public function getIPv6Address() * * @param string $iPv6Address */ - public function setIPv6Address($iPv6Address) + public function setIPv6Address(string $iPv6Address) { $this->set("IPv6Address", $iPv6Address); } - /** * UserUFileData: 用户转存备份到自己的UFILE配置, 结构参考UFileDataSet * - * @return UFileDataSet|null + * @return UFileDataSetModel|null */ public function getUserUFileData() { - return new UFileDataSet($this->get("UserUFileData")); + return new UFileDataSetModel($this->get("UserUFileData")); } /** * UserUFileData: 用户转存备份到自己的UFILE配置, 结构参考UFileDataSet * - * @param UFileDataSet $userUFileData + * @param UFileDataSetModel $userUFileData */ - public function setUserUFileData(array $userUFileData) + public function setUserUFileData(UFileDataSetModel $userUFileData) { $this->set("UserUFileData", $userUFileData->getAll()); } diff --git a/src/UDB/Models/UDBParamGroupSet.php b/src/UDB/Models/UDBParamGroupSet.php index 9e7e0b10..8200919b 100644 --- a/src/UDB/Models/UDBParamGroupSet.php +++ b/src/UDB/Models/UDBParamGroupSet.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } - /** * GroupName: 参数组名称 * @@ -57,11 +60,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * DBTypeId: DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6 7:percona-5.6 * @@ -77,11 +79,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * Description: 参数组描述 * @@ -97,11 +98,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * Modifiable: 参数组是否可修改 * @@ -117,15 +117,14 @@ public function getModifiable() * * @param boolean $modifiable */ - public function setModifiable($modifiable) + public function setModifiable(bool $modifiable) { $this->set("Modifiable", $modifiable); } - /** * ParamMember: 参数的键值对表 UDBParamMemberSet * - * @return UDBParamMemberSet[]|null + * @return UDBParamMemberSetModel[]|null */ public function getParamMember() { @@ -135,7 +134,7 @@ public function getParamMember() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDBParamMemberSet($item)); + array_push($result, new UDBParamMemberSetModel($item)); } return $result; } @@ -143,7 +142,7 @@ public function getParamMember() /** * ParamMember: 参数的键值对表 UDBParamMemberSet * - * @param UDBParamMemberSet[] $paramMember + * @param UDBParamMemberSetModel[] $paramMember */ public function setParamMember(array $paramMember) { diff --git a/src/UDB/Models/UDBParamMemberSet.php b/src/UDB/Models/UDBParamMemberSet.php index 256e5b04..a7136cd0 100644 --- a/src/UDB/Models/UDBParamMemberSet.php +++ b/src/UDB/Models/UDBParamMemberSet.php @@ -1,6 +1,7 @@ set("Key", $key); } - /** * Value: 参数值 * @@ -57,11 +60,10 @@ public function getValue() * * @param string $value */ - public function setValue($value) + public function setValue(string $value) { $this->set("Value", $value); } - /** * ValueType: 参数值应用类型,取值范围为{0,10,20,30},各值 代表意义为 0-unknown、10-int、20-string、 30-bool * @@ -77,11 +79,10 @@ public function getValueType() * * @param int $valueType */ - public function setValueType($valueType) + public function setValueType(int $valueType) { $this->set("ValueType", $valueType); } - /** * AllowedVal: 允许的值(根据参数类型,用分隔符表示) * @@ -97,11 +98,10 @@ public function getAllowedVal() * * @param string $allowedVal */ - public function setAllowedVal($allowedVal) + public function setAllowedVal(string $allowedVal) { $this->set("AllowedVal", $allowedVal); } - /** * ApplyType: 参数值应用类型,取值范围为{0,10,20},各值代表 意义为0-unknown、10-static、20-dynamic * @@ -117,11 +117,10 @@ public function getApplyType() * * @param int $applyType */ - public function setApplyType($applyType) + public function setApplyType(int $applyType) { $this->set("ApplyType", $applyType); } - /** * Modifiable: 是否可更改,默认为false * @@ -137,11 +136,10 @@ public function getModifiable() * * @param boolean $modifiable */ - public function setModifiable($modifiable) + public function setModifiable(bool $modifiable) { $this->set("Modifiable", $modifiable); } - /** * FormatType: 允许值的格式类型,取值范围为{0,10,20},意义分 别为PVFT_UNKOWN=0,PVFT_RANGE=10, PVFT_ENUM=20 * @@ -157,7 +155,7 @@ public function getFormatType() * * @param int $formatType */ - public function setFormatType($formatType) + public function setFormatType(int $formatType) { $this->set("FormatType", $formatType); } diff --git a/src/UDB/Models/UDBRWSplittingSet.php b/src/UDB/Models/UDBRWSplittingSet.php index 1ce08076..8c97a947 100644 --- a/src/UDB/Models/UDBRWSplittingSet.php +++ b/src/UDB/Models/UDBRWSplittingSet.php @@ -1,6 +1,7 @@ set("DBId", $dbId); } - /** * Role: 主库/从库 * @@ -57,11 +59,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * VirtualIP: DBIP * @@ -77,11 +78,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * ReadWeight: 读写分离比重 * @@ -97,11 +97,10 @@ public function getReadWeight() * * @param int $readWeight */ - public function setReadWeight($readWeight) + public function setReadWeight(int $readWeight) { $this->set("ReadWeight", $readWeight); } - /** * State: DB状态 * @@ -117,7 +116,7 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } diff --git a/src/UDB/Models/UDBSlaveInstanceSet.php b/src/UDB/Models/UDBSlaveInstanceSet.php index 86023085..ac153d3c 100644 --- a/src/UDB/Models/UDBSlaveInstanceSet.php +++ b/src/UDB/Models/UDBSlaveInstanceSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * DBId: DB实例id * @@ -57,11 +61,10 @@ public function getDBId() * * @param string $dbId */ - public function setDBId($dbId) + public function setDBId(string $dbId) { $this->set("DBId", $dbId); } - /** * Name: 实例名称,至少6位 * @@ -77,11 +80,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * DBTypeId: DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下: 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6, 7:percona-5.6 * @@ -97,11 +99,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * ParamGroupId: DB实例使用的配置参数组id * @@ -117,11 +118,10 @@ public function getParamGroupId() * * @param int $paramGroupId */ - public function setParamGroupId($paramGroupId) + public function setParamGroupId(int $paramGroupId) { $this->set("ParamGroupId", $paramGroupId); } - /** * AdminUser: 管理员帐户名,默认root * @@ -137,11 +137,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * VirtualIP: DB实例虚ip * @@ -157,11 +156,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * VirtualIPMac: DB实例虚ip的mac地址 * @@ -177,11 +175,10 @@ public function getVirtualIPMac() * * @param string $virtualIPMac */ - public function setVirtualIPMac($virtualIPMac) + public function setVirtualIPMac(string $virtualIPMac) { $this->set("VirtualIPMac", $virtualIPMac); } - /** * Port: 端口号,mysql默认3306,mongodb默认27017 * @@ -197,11 +194,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * SrcDBId: 对mysql的slave而言是master的DBId,对master则为空, 对mongodb则是副本集id * @@ -217,11 +213,10 @@ public function getSrcDBId() * * @param string $srcDBId */ - public function setSrcDBId($srcDBId) + public function setSrcDBId(string $srcDBId) { $this->set("SrcDBId", $srcDBId); } - /** * BackupCount: 备份策略,不可修改,备份文件保留的数量,默认7次 * @@ -237,11 +232,10 @@ public function getBackupCount() * * @param int $backupCount */ - public function setBackupCount($backupCount) + public function setBackupCount(int $backupCount) { $this->set("BackupCount", $backupCount); } - /** * BackupBeginTime: 备份策略,不可修改,开始时间,单位小时计,默认3点 * @@ -257,11 +251,10 @@ public function getBackupBeginTime() * * @param int $backupBeginTime */ - public function setBackupBeginTime($backupBeginTime) + public function setBackupBeginTime(int $backupBeginTime) { $this->set("BackupBeginTime", $backupBeginTime); } - /** * BackupDuration: 备份策略,一天内备份时间间隔,单位小时,默认24小时 * @@ -277,11 +270,10 @@ public function getBackupDuration() * * @param int $backupDuration */ - public function setBackupDuration($backupDuration) + public function setBackupDuration(int $backupDuration) { $this->set("BackupDuration", $backupDuration); } - /** * BackupBlacklist: 备份策略,备份黑名单,mongodb则不适用 * @@ -297,11 +289,10 @@ public function getBackupBlacklist() * * @param string $backupBlacklist */ - public function setBackupBlacklist($backupBlacklist) + public function setBackupBlacklist(string $backupBlacklist) { $this->set("BackupBlacklist", $backupBlacklist); } - /** * State: DB状态标记 Init:初始化中,Fail:安装失败,Starting:启动中,Running:运行,Shutdown:关闭中,Shutoff:已关闭,Delete:已删除,Upgrading:升级中,Promoting:提升为独库进行中,Recovering:恢复中,Recover fail:恢复失败 * @@ -317,11 +308,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: DB实例创建时间,采用UTC计时时间戳 * @@ -337,11 +327,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: DB实例修改时间,采用UTC计时时间戳 * @@ -357,11 +346,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * ExpiredTime: DB实例过期时间,采用UTC计时时间戳 * @@ -377,11 +365,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * ChargeType: Year, Month, Dynamic,Trial,默认: Dynamic * @@ -397,11 +384,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * MemoryLimit: 内存限制(MB),默认根据配置机型 * @@ -417,11 +403,10 @@ public function getMemoryLimit() * * @param int $memoryLimit */ - public function setMemoryLimit($memoryLimit) + public function setMemoryLimit(int $memoryLimit) { $this->set("MemoryLimit", $memoryLimit); } - /** * DiskSpace: 磁盘空间(GB), 默认根据配置机型 * @@ -437,11 +422,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * UseSSD: 是否使用SSD * @@ -457,11 +441,10 @@ public function getUseSSD() * * @param boolean $useSSD */ - public function setUseSSD($useSSD) + public function setUseSSD(bool $useSSD) { $this->set("UseSSD", $useSSD); } - /** * SSDType: SSD类型,SATA/PCI-E * @@ -477,11 +460,10 @@ public function getSSDType() * * @param string $ssdType */ - public function setSSDType($ssdType) + public function setSSDType(string $ssdType) { $this->set("SSDType", $ssdType); } - /** * Role: DB实例角色,mysql区分master/slave,mongodb多种角色 * @@ -497,11 +479,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * DiskUsedSize: DB实例磁盘已使用空间,单位GB * @@ -517,11 +498,10 @@ public function getDiskUsedSize() * * @param float $diskUsedSize */ - public function setDiskUsedSize($diskUsedSize) + public function setDiskUsedSize(float $diskUsedSize) { $this->set("DiskUsedSize", $diskUsedSize); } - /** * DataFileSize: DB实例数据文件大小,单位GB * @@ -537,11 +517,10 @@ public function getDataFileSize() * * @param float $dataFileSize */ - public function setDataFileSize($dataFileSize) + public function setDataFileSize(float $dataFileSize) { $this->set("DataFileSize", $dataFileSize); } - /** * SystemFileSize: DB实例系统文件大小,单位GB * @@ -557,11 +536,10 @@ public function getSystemFileSize() * * @param float $systemFileSize */ - public function setSystemFileSize($systemFileSize) + public function setSystemFileSize(float $systemFileSize) { $this->set("SystemFileSize", $systemFileSize); } - /** * LogFileSize: DB实例日志文件大小,单位GB * @@ -577,11 +555,10 @@ public function getLogFileSize() * * @param float $logFileSize */ - public function setLogFileSize($logFileSize) + public function setLogFileSize(float $logFileSize) { $this->set("LogFileSize", $logFileSize); } - /** * BackupDate: 备份日期标记位。共7位,每一位为一周中一天的备份情况 0表示关闭当天备份,1表示打开当天备份。最右边的一位 为星期天的备份开关,其余从右到左依次为星期一到星期 六的备份配置开关,每周必须至少设置两天备份。 例如:1100000 表示打开星期六和星期五的自动备份功能 * @@ -597,11 +574,10 @@ public function getBackupDate() * * @param string $backupDate */ - public function setBackupDate($backupDate) + public function setBackupDate(string $backupDate) { $this->set("BackupDate", $backupDate); } - /** * InstanceMode: UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例;"HA": 高可用版UDB实例 * @@ -617,11 +593,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * ClusterRole: 当DB类型为mongodb时,返回该实例所在集群中的角色,包括:mongos、configsrv_sccc、configsrv_csrs、shardsrv_datanode、shardsrv_arbiter,其中congfigsrv分为sccc和csrs两种模式,shardsrv分为datanode和arbiter两种模式 * @@ -637,11 +612,10 @@ public function getClusterRole() * * @param string $clusterRole */ - public function setClusterRole($clusterRole) + public function setClusterRole(string $clusterRole) { $this->set("ClusterRole", $clusterRole); } - /** * SubnetId: 子网ID * @@ -657,11 +631,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC的ID * @@ -677,11 +650,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * InstanceType: UDB数据库机型 * @@ -697,11 +669,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * InstanceTypeId: UDB数据库机型ID * @@ -717,11 +688,10 @@ public function getInstanceTypeId() * * @param int $instanceTypeId */ - public function setInstanceTypeId($instanceTypeId) + public function setInstanceTypeId(int $instanceTypeId) { $this->set("InstanceTypeId", $instanceTypeId); } - /** * Tag: 获取资源其他信息 * @@ -737,11 +707,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * IPv6Address: 获取该实例的IPv6地址 * @@ -757,7 +726,7 @@ public function getIPv6Address() * * @param string $iPv6Address */ - public function setIPv6Address($iPv6Address) + public function setIPv6Address(string $iPv6Address) { $this->set("IPv6Address", $iPv6Address); } diff --git a/src/UDB/Models/UDBTypeSet.php b/src/UDB/Models/UDBTypeSet.php index 50b02a80..ac27dda2 100644 --- a/src/UDB/Models/UDBTypeSet.php +++ b/src/UDB/Models/UDBTypeSet.php @@ -1,6 +1,7 @@ set("DBTypeId", $dbTypeId); } diff --git a/src/UDB/Models/UFileDataSet.php b/src/UDB/Models/UFileDataSet.php index 319bb9a4..efedaec4 100644 --- a/src/UDB/Models/UFileDataSet.php +++ b/src/UDB/Models/UFileDataSet.php @@ -1,6 +1,7 @@ set("TokenID", $tokenID); } - /** * Bucket: bucket名称 * @@ -57,7 +61,7 @@ public function getBucket() * * @param string $bucket */ - public function setBucket($bucket) + public function setBucket(string $bucket) { $this->set("Bucket", $bucket); } diff --git a/src/UDB/UDBClient.php b/src/UDB/UDBClient.php index 5c1c7e21..4488b2be 100644 --- a/src/UDB/UDBClient.php +++ b/src/UDB/UDBClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * "BackupName" => (string) 备份名称 - * "UseBlacklist" => (boolean) 是否使用黑名单备份,默认false - * "BackupMethod" => (string) 使用的备份方式。(快照备份即物理备份。注意只有SSD版本的mysql实例支持设置为snapshot) - * "Blacklist" => (string) 备份黑名单列表,以 ; 分隔。注意:只有逻辑备份下备份黑名单才生效,快照备份备份黑名单下无效 - * "ForceBackup" => (boolean) true表示逻辑备份时是使用 --force 参数,false表示不使用 --force 参数。物理备份此参数无效。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BackupUDBInstanceResponse * @throws UCloudException */ public function backupUDBInstance(BackupUDBInstanceRequest $request = null) @@ -171,29 +331,13 @@ public function backupUDBInstance(BackupUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new BackupUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * BackupUDBInstanceBinlog - 备份UDB指定时间段的binlog列表 * - * See also: https://docs.ucloud.cn/api/udb-api/backup_udb_instance_binlog - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * "BackupFile" => (string) 需要备份文件,可通过DescribeUDBInstanceBinlog获得 如果要传入多个文件名,以空格键分割,用单引号包含. - * "BackupName" => (string) DB备份文件名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BackupUDBInstanceBinlogResponse * @throws UCloudException */ public function backupUDBInstanceBinlog(BackupUDBInstanceBinlogRequest $request = null) @@ -201,28 +345,13 @@ public function backupUDBInstanceBinlog(BackupUDBInstanceBinlogRequest $request $resp = $this->invoke($request); return new BackupUDBInstanceBinlogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * BackupUDBInstanceErrorLog - 备份UDB指定时间段的errorlog * - * See also: https://docs.ucloud.cn/api/udb-api/backup_udb_instance_error_log - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * "BackupName" => (string) 备份名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BackupUDBInstanceErrorLogResponse * @throws UCloudException */ public function backupUDBInstanceErrorLog(BackupUDBInstanceErrorLogRequest $request = null) @@ -230,29 +359,13 @@ public function backupUDBInstanceErrorLog(BackupUDBInstanceErrorLogRequest $requ $resp = $this->invoke($request); return new BackupUDBInstanceErrorLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * BackupUDBInstanceSlowLog - 备份UDB指定时间段的slowlog分析结果 * - * See also: https://docs.ucloud.cn/api/udb-api/backup_udb_instance_slow_log - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * "BeginTime" => (integer) 过滤条件:起始时间(时间戳) - * "EndTime" => (integer) 过滤条件:结束时间(时间戳) - * "BackupName" => (string) 备份文件名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BackupUDBInstanceSlowLogResponse * @throws UCloudException */ public function backupUDBInstanceSlowLog(BackupUDBInstanceSlowLogRequest $request = null) @@ -260,28 +373,13 @@ public function backupUDBInstanceSlowLog(BackupUDBInstanceSlowLogRequest $reques $resp = $this->invoke($request); return new BackupUDBInstanceSlowLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ChangeUDBParamGroup - 修改配置文件 * - * See also: https://docs.ucloud.cn/api/udb-api/change_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id - * "GroupId" => (string) 参数组Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ChangeUDBParamGroupResponse * @throws UCloudException */ public function changeUDBParamGroup(ChangeUDBParamGroupRequest $request = null) @@ -289,28 +387,13 @@ public function changeUDBParamGroup(ChangeUDBParamGroupRequest $request = null) $resp = $this->invoke($request); return new ChangeUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CheckRecoverUDBInstance - 核查db是否可以使用回档功能 * - * See also: https://docs.ucloud.cn/api/udb-api/check_recover_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SrcDBId" => (string) 源实例的Id - * ] - * - * Outputs: - * - * $outputs = [ - * "LastestTime" => (integer) 核查成功返回值为可以回档到的最近时刻,核查失败不返回 - * ] - * - * @return CheckRecoverUDBInstanceResponse * @throws UCloudException */ public function checkRecoverUDBInstance(CheckRecoverUDBInstanceRequest $request = null) @@ -318,27 +401,13 @@ public function checkRecoverUDBInstance(CheckRecoverUDBInstanceRequest $request $resp = $this->invoke($request); return new CheckRecoverUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CheckUDBInstanceToHAAllowance - 核查db是否可以升级为高可用 * - * See also: https://docs.ucloud.cn/api/udb-api/check_udb_instance_to_ha_allowance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * "Allowance" => (string) Yes ,No ,Yes即可以升级,No为不可以升级 - * ] - * - * @return CheckUDBInstanceToHAAllowanceResponse * @throws UCloudException */ public function checkUDBInstanceToHAAllowance(CheckUDBInstanceToHAAllowanceRequest $request = null) @@ -346,29 +415,13 @@ public function checkUDBInstanceToHAAllowance(CheckUDBInstanceToHAAllowanceReque $resp = $this->invoke($request); return new CheckUDBInstanceToHAAllowanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ClearUDBLog - 清除UDB实例的log * - * See also: https://docs.ucloud.cn/api/udb-api/clear_udb_log - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例的id,该值可以通过DescribeUDBInstance获取 - * "LogType" => (integer) 日志类型,10-error(暂不支持)、20-slow(暂不支持 )、30-binlog - * "BeforeTime" => (integer) 删除时间点(至少前一天)之前log,采用时间戳(秒),默认当 前时间点前一天 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ClearUDBLogResponse * @throws UCloudException */ public function clearUDBLog(ClearUDBLogRequest $request = null) @@ -376,48 +429,13 @@ public function clearUDBLog(ClearUDBLogRequest $request = null) $resp = $this->invoke($request); return new ClearUDBLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateMongoDBReplicaSet - 一键创建DB副本集 * - * See also: https://docs.ucloud.cn/api/udb-api/create_mongo_db_replica_set - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) PrimaryDB实例名称,至少6位 - * "AdminPassword" => (string) 管理员密码 - * "DBTypeId" => (string) DB类型id对应的字符串形式(例如:mongodb-2.6)注意:当前仅支持mongodb - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G - 3000G - * "ParamGroupId" => (integer) DB实例使用的配置参数组id - * "MemoryLimit" => (integer) 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M - * "Port" => (integer) 端口号 - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Month - * "Quantity" => (integer) 购买时长(N个月),默认值1个月。如果为0,代表购买到月底。 - * "AdminUser" => (string) 管理员帐户名,默认root - * "BackupCount" => (integer) 备份策略,每周备份数量,默认7次 - * "BackupTime" => (integer) 备份策略,备份开始时间,单位小时计,默认1点 - * "BackupDuration" => (integer) 备份策略,备份时间间隔,单位小时计,默认24小时 - * "UseSSD" => (boolean) 是否使用SSD,默认为true - * "SSDType" => (string) SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必选 - * "CPU" => (integer) cpu核数 - * "InstanceType" => (string) UDB数据库机型 - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC的ID - * "ClusterId" => (string) 所属分片集群的ID - * "CouponId" => (array) CouponId.0 代表第一个代金券id,对于传入多个代金券id,后面为 CouponId.1, CouponId.2 以此类推 - * ] - * - * Outputs: - * - * $outputs = [ - * "DBIds" => (array) 返回所有副本集成员的Id - * ] - * - * @return CreateMongoDBReplicaSetResponse * @throws UCloudException */ public function createMongoDBReplicaSet(CreateMongoDBReplicaSetRequest $request = null) @@ -425,55 +443,13 @@ public function createMongoDBReplicaSet(CreateMongoDBReplicaSetRequest $request $resp = $this->invoke($request); return new CreateMongoDBReplicaSetResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBInstance - 创建UDB实例(包括创建mysql master节点、mongodb primary/configsvr节点和从备份恢复实例) * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) 实例名称,至少6位 - * "AdminPassword" => (string) 管理员密码 - * "DBTypeId" => (string) DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6,14:postgresql-10.4 - * "Port" => (integer) 端口号,mysql默认3306,mongodb默认27017,postgresql默认5432 - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G - 32T - * "ParamGroupId" => (integer) DB实例使用的配置参数组id - * "MemoryLimit" => (integer) 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M/128000M/192000M/256000M/320000M - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Month - * "Quantity" => (integer) 购买时长,默认值1 - * "AdminUser" => (string) 管理员帐户名,默认root - * "BackupCount" => (integer) 备份策略,每周备份数量,默认7次 - * "BackupTime" => (integer) 备份策略,备份开始时间,单位小时计,默认1点 - * "BackupDuration" => (integer) 备份策略,备份时间间隔,单位小时计,默认24小时 - * "BackupId" => (integer) 备份id,如果指定,则表明从备份恢复实例 - * "UseSSD" => (boolean) 是否使用SSD,默认为true。目前主要可用区、海外机房、新机房只提供SSD资源,非SSD资源不再提供。 - * "SSDType" => (string) SSD类型,可选值为"SATA"、“NVMe”,如果UseSSD为true ,则必选 - * "InstanceMode" => (string) UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例 "HA": 高可用版UDB实例 默认是"Normal" - * "UDBCId" => (string) 专区ID信息(如果这个参数存在这说明是在专区中创建DB) - * "CPU" => (integer) cpu核数 - * "BackupZone" => (string) 跨可用区高可用备库所在可用区,参见 [可用区列表](../summary/regionlist.html) - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC的ID - * "DisableSemisync" => (boolean) 是否开启异步高可用,默认不填,可置为true - * "ClusterRole" => (string) 当DB类型(DBTypeId)为mongodb时,需要指定mongo的角色,可选值为configsrv (配置节点),shardsrv (数据节点) - * "HAArch" => (string) 高可用架构:1) haproxy(默认): 当前仅支持mysql。2) sentinel: 基于vip和哨兵节点的架构,当前支持mysql和pg。 - * "Tag" => (string) 实例所在的业务组名称 - * "EnableIpV6" => (boolean) 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) BD实例id - * ] - * - * @return CreateUDBInstanceResponse * @throws UCloudException */ public function createUDBInstance(CreateUDBInstanceRequest $request = null) @@ -481,38 +457,13 @@ public function createUDBInstance(CreateUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new CreateUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBInstanceByRecovery - 创建db,将新创建的db恢复到指定db某个指定时间点 * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_instance_by_recovery - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) 实例名称,至少6位 - * "SrcDBId" => (string) 源实例的Id - * "RecoveryTime" => (integer) 恢复到某个时间点的时间戳(UTC时间格式,默认单位秒) - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Dynamic - * "Quantity" => (integer) 购买时长,默认值1 - * "UseSSD" => (boolean) 指定是否是否使用SSD,默认使用主库的配置 - * "UDBCId" => (string) 专区的Id - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC的ID - * "EnableIpV6" => (boolean) 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) db实例id - * ] - * - * @return CreateUDBInstanceByRecoveryResponse * @throws UCloudException */ public function createUDBInstanceByRecovery(CreateUDBInstanceByRecoveryRequest $request = null) @@ -520,32 +471,13 @@ public function createUDBInstanceByRecovery(CreateUDBInstanceByRecoveryRequest $ $resp = $this->invoke($request); return new CreateUDBInstanceByRecoveryResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBParamGroup - 从已有配置文件创建新配置文件 * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupName" => (string) 新配置参数组名称 - * "Description" => (string) 参数组描述 - * "SrcGroupId" => (integer) 源参数组id - * "DBTypeId" => (string) DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6 - * "RegionFlag" => (boolean) 是否是地域级别的配置文件,默认是false - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (integer) 新配置参数组id - * ] - * - * @return CreateUDBParamGroupResponse * @throws UCloudException */ public function createUDBParamGroup(CreateUDBParamGroupRequest $request = null) @@ -553,33 +485,13 @@ public function createUDBParamGroup(CreateUDBParamGroupRequest $request = null) $resp = $this->invoke($request); return new CreateUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBReplicationInstance - 创建MongoDB的副本节点(包括仲裁) * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_replication_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SrcId" => (string) primary节点的DBId,该值可以通过DescribeUDBInstance获取 - * "Name" => (string) 实例名称,至少6位 - * "Port" => (integer) 端口号,默认27017,取值范围3306至65535。 - * "IsArbiter" => (boolean) 是否是仲裁节点,默认false,仲裁节点按最小机型创建 - * "UseSSD" => (boolean) 是否使用SSD,默认 为 true - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) 创建从节点的DBId - * ] - * - * @return CreateUDBReplicationInstanceResponse * @throws UCloudException */ public function createUDBReplicationInstance(CreateUDBReplicationInstanceRequest $request = null) @@ -587,38 +499,13 @@ public function createUDBReplicationInstance(CreateUDBReplicationInstanceRequest $resp = $this->invoke($request); return new CreateUDBReplicationInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBRouteInstance - 创建mongos实例 * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_route_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBTypeId" => (string) DB类型id,mongodb按版本细分有1:mongodb-2.4,2:mongodb-2.6,3:mongodb-3.0,4:mongodb-3.2 - * "Name" => (string) 实例名称,至少6位 - * "Port" => (integer) 端口号,mongodb默认27017 - * "ParamGroupId" => (integer) DB实例使用的配置参数组id - * "MemoryLimit" => (integer) 内存限制(MB),目前支持以下几档 600M/1500M/3000M /6000M/15000M/30000M - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G - 500G - * "ConfigsvrId" => (array) 配置服务器的dbid,允许一个或者三个。 - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Month - * "Quantity" => (integer) 购买时长,默认值1 - * "UseSSD" => (boolean) 是否使用SSD,默认为ture - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) db实例id - * ] - * - * @return CreateUDBRouteInstanceResponse * @throws UCloudException */ public function createUDBRouteInstance(CreateUDBRouteInstanceRequest $request = null) @@ -626,43 +513,13 @@ public function createUDBRouteInstance(CreateUDBRouteInstanceRequest $request = $resp = $this->invoke($request); return new CreateUDBRouteInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDBSlave - 创建UDB实例的slave * - * See also: https://docs.ucloud.cn/api/udb-api/create_udb_slave - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SrcId" => (string) master实例的DBId,该值可以通过DescribeUDBInstance获取 - * "Name" => (string) 实例名称,至少6位 - * "Port" => (integer) 端口号 - * "UseSSD" => (boolean) 是否使用SSD,默认为true - * "SSDType" => (string) SSD类型,可选值为"SATA"、"PCI-E"、“NVMe”,如果UseSSD为true ,则必选 - * "IsLock" => (boolean) 是否锁主库,默认为true - * "InstanceMode" => (string) UDB实例部署模式,可选值如下:Normal: 普通单点实例HA: 高可用部署实例 - * "MemoryLimit" => (integer) 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/12000M/16000M/ 24000M/32000M/48000M/ 64000M/96000M/128000M/192000M/256000M/320000M - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G - 3000G(API支持,前端暂时只开放内存定制) - * "InstanceType" => (string) UDB实例类型:Normal、SATA_SSD、NVMe_SSD - * "SubnetId" => (string) 子网ID(如果不传用默认子网) - * "VPCId" => (string) VPCID(如果不传用默认的VPC) - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认和主库保持一致 - * "Quantity" => (integer) 购买时长,默认默认和主库保持一致 - * "ParamGroupId" => (integer) DB实例使用的配置参数组id,默认和主库保持一致 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) 创建slave的DBId - * ] - * - * @return CreateUDBSlaveResponse * @throws UCloudException */ public function createUDBSlave(CreateUDBSlaveRequest $request = null) @@ -670,28 +527,13 @@ public function createUDBSlave(CreateUDBSlaveRequest $request = null) $resp = $this->invoke($request); return new CreateUDBSlaveResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUDBInstance - 删除UDB实例 * - * See also: https://docs.ucloud.cn/api/udb-api/delete_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例的id,该值可以通过DescribeUDBInstance获取 - * "UDBCId" => (string) 专区ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDBInstanceResponse * @throws UCloudException */ public function deleteUDBInstance(DeleteUDBInstanceRequest $request = null) @@ -699,28 +541,13 @@ public function deleteUDBInstance(DeleteUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new DeleteUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUDBLogPackage - 删除UDB日志包 * - * See also: https://docs.ucloud.cn/api/udb-api/delete_udb_log_package - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BackupId" => (integer) 日志包id,可通过DescribeUDBLogPackage获得 - * "BackupZone" => (string) 跨可用区高可用备库所在可用区 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDBLogPackageResponse * @throws UCloudException */ public function deleteUDBLogPackage(DeleteUDBLogPackageRequest $request = null) @@ -728,28 +555,13 @@ public function deleteUDBLogPackage(DeleteUDBLogPackageRequest $request = null) $resp = $this->invoke($request); return new DeleteUDBLogPackageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUDBParamGroup - 删除配置参数组 * - * See also: https://docs.ucloud.cn/api/udb-api/delete_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (integer) 参数组id,可通过DescribeUDBParamGroup获取 - * "RegionFlag" => (boolean) 是否属于地域级别 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDBParamGroupResponse * @throws UCloudException */ public function deleteUDBParamGroup(DeleteUDBParamGroupRequest $request = null) @@ -757,48 +569,13 @@ public function deleteUDBParamGroup(DeleteUDBParamGroupRequest $request = null) $resp = $this->invoke($request); return new DeleteUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBBackup - 列表UDB实例备份信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_backup - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Offset" => (integer) 分页显示的起始偏移,列表操作则指定 - * "Limit" => (integer) 分页显示的条目数,列表操作则指定 - * "DBId" => (string) DB实例Id,如果指定,则只获取该db的备份信息 该值可以通过DescribeUDBInstance获取 - * "BackupType" => (integer) 备份类型,取值为0或1,0表示自动,1表示手动 - * "BeginTime" => (integer) 过滤条件:起始时间(Unix时间戳) - * "EndTime" => (integer) 过滤条件:结束时间(Unix时间戳) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 备份信息 参照UDBBackupSet[ - * [ - * "BackupId" => (integer) 备份id - * "BackupName" => (string) 备份名称 - * "BackupTime" => (integer) 备份时间(Unix时间戳) - * "BackupSize" => (integer) 备份文件大小(字节) - * "BackupType" => (integer) 备份类型,取值为0或1,0表示自动,1表示手动 - * "State" => (string) 备份状态 Backuping // 备份中 Success // 备份成功 Failed // 备份失败 Expired // 备份过期 - * "DBId" => (string) dbid - * "DBName" => (string) 对应的db名称 - * "Zone" => (string) 备份所在可用区 - * "BackupZone" => (string) 跨机房高可用备库所在可用区 - * "BackupEndTime" => (integer) 备份完成时间(Unix时间戳) - * ] - * ] - * "TotalCount" => (integer) 满足条件备份总数,如果指定dbid,则是该db备份总数 - * ] - * - * @return DescribeUDBBackupResponse * @throws UCloudException */ public function describeUDBBackup(DescribeUDBBackupRequest $request = null) @@ -806,28 +583,13 @@ public function describeUDBBackup(DescribeUDBBackupRequest $request = null) $resp = $this->invoke($request); return new DescribeUDBBackupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBBackupBlacklist - 获取UDB实例的备份黑名单 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_backup_blacklist - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * "Blacklist" => (string) DB的黑名单列表, db.%为指定库 dbname.tablename为指定表 - * ] - * - * @return DescribeUDBBackupBlacklistResponse * @throws UCloudException */ public function describeUDBBackupBlacklist(DescribeUDBBackupBlacklistRequest $request = null) @@ -835,29 +597,13 @@ public function describeUDBBackupBlacklist(DescribeUDBBackupBlacklistRequest $re $resp = $this->invoke($request); return new DescribeUDBBackupBlacklistResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBBinlogBackupURL - 获取UDB的Binlog备份地址 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_binlog_backup_url - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "DBId" => (string) DB实例Id - * "BackupId" => (integer) DB实例binlog备份ID,可以从DescribeUDBLogPackage结果当中获得 - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupPath" => (string) DB实例备份文件的公网地址 - * "InnerBackupPath" => (string) DB实例备份文件的内网地址 - * ] - * - * @return DescribeUDBBinlogBackupURLResponse * @throws UCloudException */ public function describeUDBBinlogBackupURL(DescribeUDBBinlogBackupURLRequest $request = null) @@ -865,121 +611,13 @@ public function describeUDBBinlogBackupURL(DescribeUDBBinlogBackupURLRequest $re $resp = $this->invoke($request); return new DescribeUDBBinlogBackupURLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstance - 获取UDB实例信息,支持两类操作:(1)指定DBId用于获取该db的信息;(2)指定ClassType、Offset、Limit用于列表操作,查询某一个类型db。 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区,不填时默认全部可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ClassType" => (string) DB种类,如果是列表操作,则需要指定,不区分大小写,其取值如下:mysql: SQL;mongo: NOSQL;postgresql: postgresql - * "Offset" => (integer) 分页显示起始偏移位置,列表操作时必填 - * "Limit" => (integer) 分页显示数量,列表操作时必填 - * "DBId" => (string) DB实例id,如果指定则获取单个db实例的描述,否则为列表操作。 指定DBId时无需填写ClassType、Offset、Limit - * "IsInUDBC" => (boolean) 是否查看专区里面DB - * "UDBCId" => (string) IsInUDBC为True,UDBCId为空,说明查看整个可用区的专区的db,如果UDBId不为空则只查看此专区下面的db - * "IncludeSlaves" => (boolean) 当只获取这个特定DBId的信息时,如果有该选项,那么把这个DBId实例的所有从库信息一起拉取并返回 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) DB实例信息列表 UDBInstanceSet[ - * [ - * "Zone" => (string) DB实例所在可用区 - * "ClusterRole" => (string) 当DB类型为mongodb时,返回该实例所在集群中的角色,包括:mongos、configsrv_sccc、configsrv_csrs、shardsrv_datanode、shardsrv_arbiter,其中congfigsrv分为sccc和csrs两种模式,shardsrv分为datanode和arbiter两种模式 - * "DBId" => (string) DB实例id - * "Name" => (string) 实例名称,至少6位 - * "DBTypeId" => (string) DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下: 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6, 7:percona-5.6 - * "ParamGroupId" => (integer) DB实例使用的配置参数组id - * "AdminUser" => (string) 管理员帐户名,默认root - * "VirtualIP" => (string) DB实例虚ip - * "VirtualIPMac" => (string) DB实例虚ip的mac地址 - * "VPCId" => (string) VPC的ID - * "SubnetId" => (string) 子网ID - * "InstanceType" => (string) UDB数据库机型 - * "InstanceTypeId" => (integer) UDB数据库机型ID - * "Tag" => (string) 获取资源其他信息 - * "Port" => (integer) 端口号,mysql默认3306,mongodb默认27017 - * "SrcDBId" => (string) 对mysql的slave而言是master的DBId,对master则为空, 对mongodb则是副本集id - * "BackupCount" => (integer) 备份策略,不可修改,备份文件保留的数量,默认7次 - * "BackupBeginTime" => (integer) 备份策略,不可修改,开始时间,单位小时计,默认3点 - * "BackupDuration" => (integer) 备份策略,一天内备份时间间隔,单位小时,默认24小时 - * "BackupBlacklist" => (string) 备份策略,备份黑名单,mongodb则不适用 - * "State" => (string) DB状态标记 Init:初始化中,Fail:安装失败,Starting:启动中,Running:运行,Shutdown:关闭中,Shutoff:已关闭,Delete:已删除,Upgrading:升级中,Promoting:提升为独库进行中,Recovering:恢复中,Recover fail:恢复失败 - * "CreateTime" => (integer) DB实例创建时间,采用UTC计时时间戳 - * "ModifyTime" => (integer) DB实例修改时间,采用UTC计时时间戳 - * "ExpiredTime" => (integer) DB实例过期时间,采用UTC计时时间戳 - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Dynamic - * "MemoryLimit" => (integer) 内存限制(MB),默认根据配置机型 - * "DiskSpace" => (integer) 磁盘空间(GB), 默认根据配置机型 - * "UseSSD" => (boolean) 是否使用SSD - * "SSDType" => (string) SSD类型,SATA/PCI-E/NVMe - * "Role" => (string) DB实例角色,mysql区分master/slave,mongodb多种角色 - * "DiskUsedSize" => (number) DB实例磁盘已使用空间,单位GB - * "DataFileSize" => (number) DB实例数据文件大小,单位GB - * "SystemFileSize" => (number) DB实例系统文件大小,单位GB - * "LogFileSize" => (number) DB实例日志文件大小,单位GB - * "BackupDate" => (string) 备份日期标记位。共7位,每一位为一周中一天的备份情况 0表示关闭当天备份,1表示打开当天备份。最右边的一位 为星期天的备份开关,其余从右到左依次为星期一到星期 六的备份配置开关,每周必须至少设置两天备份。 例如:1100000 表示打开星期六和星期五的自动备份功能 - * "InstanceMode" => (string) UDB实例模式类型, 可选值如下: “Normal”: 普通版UDB实例 “HA”: 高可用版UDB实例 - * "DataSet" => (array) 如果在需要返回从库的场景下,返回该DB实例的所有从库DB实例信息列表。列表中每一个元素的内容同UDBSlaveInstanceSet 。如果这个DB实例没有从库的情况下,此时返回一个空的列表[ - * [ - * "Zone" => (string) 可用区 - * "DBId" => (string) DB实例id - * "Name" => (string) 实例名称,至少6位 - * "DBTypeId" => (string) DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下: 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6, 7:percona-5.6 - * "ParamGroupId" => (integer) DB实例使用的配置参数组id - * "AdminUser" => (string) 管理员帐户名,默认root - * "VirtualIP" => (string) DB实例虚ip - * "VirtualIPMac" => (string) DB实例虚ip的mac地址 - * "Port" => (integer) 端口号,mysql默认3306,mongodb默认27017 - * "SrcDBId" => (string) 对mysql的slave而言是master的DBId,对master则为空, 对mongodb则是副本集id - * "BackupCount" => (integer) 备份策略,不可修改,备份文件保留的数量,默认7次 - * "BackupBeginTime" => (integer) 备份策略,不可修改,开始时间,单位小时计,默认3点 - * "BackupDuration" => (integer) 备份策略,一天内备份时间间隔,单位小时,默认24小时 - * "BackupBlacklist" => (string) 备份策略,备份黑名单,mongodb则不适用 - * "State" => (string) DB状态标记 Init:初始化中,Fail:安装失败,Starting:启动中,Running:运行,Shutdown:关闭中,Shutoff:已关闭,Delete:已删除,Upgrading:升级中,Promoting:提升为独库进行中,Recovering:恢复中,Recover fail:恢复失败 - * "CreateTime" => (integer) DB实例创建时间,采用UTC计时时间戳 - * "ModifyTime" => (integer) DB实例修改时间,采用UTC计时时间戳 - * "ExpiredTime" => (integer) DB实例过期时间,采用UTC计时时间戳 - * "ChargeType" => (string) Year, Month, Dynamic,Trial,默认: Dynamic - * "MemoryLimit" => (integer) 内存限制(MB),默认根据配置机型 - * "DiskSpace" => (integer) 磁盘空间(GB), 默认根据配置机型 - * "UseSSD" => (boolean) 是否使用SSD - * "SSDType" => (string) SSD类型,SATA/PCI-E - * "Role" => (string) DB实例角色,mysql区分master/slave,mongodb多种角色 - * "DiskUsedSize" => (number) DB实例磁盘已使用空间,单位GB - * "DataFileSize" => (number) DB实例数据文件大小,单位GB - * "SystemFileSize" => (number) DB实例系统文件大小,单位GB - * "LogFileSize" => (number) DB实例日志文件大小,单位GB - * "BackupDate" => (string) 备份日期标记位。共7位,每一位为一周中一天的备份情况 0表示关闭当天备份,1表示打开当天备份。最右边的一位 为星期天的备份开关,其余从右到左依次为星期一到星期 六的备份配置开关,每周必须至少设置两天备份。 例如:1100000 表示打开星期六和星期五的自动备份功能 - * "InstanceMode" => (string) UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例;"HA": 高可用版UDB实例 - * "ClusterRole" => (string) 当DB类型为mongodb时,返回该实例所在集群中的角色,包括:mongos、configsrv_sccc、configsrv_csrs、shardsrv_datanode、shardsrv_arbiter,其中congfigsrv分为sccc和csrs两种模式,shardsrv分为datanode和arbiter两种模式 - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC的ID - * "InstanceType" => (string) UDB数据库机型 - * "InstanceTypeId" => (integer) UDB数据库机型ID - * "Tag" => (string) 获取资源其他信息 - * "IPv6Address" => (string) 获取该实例的IPv6地址 - * ] - * ] - * "BackupZone" => (string) 跨可用区高可用备库所在可用区 - * "IPv6Address" => (string) 该实例的ipv6地址 - * "UserUFileData" => (object) 用户转存备份到自己的UFILE配置, 结构参考UFileDataSet[ - * "TokenID" => (string) Ufile的令牌tokenid - * "Bucket" => (string) bucket名称 - * ] - * ] - * ] - * "TotalCount" => (integer) 用户db组的数量,对于 mysql: 主从结对数量,没有slave,则只有master mongodb: 副本集数量 - * ] - * - * @return DescribeUDBInstanceResponse * @throws UCloudException */ public function describeUDBInstance(DescribeUDBInstanceRequest $request = null) @@ -987,29 +625,13 @@ public function describeUDBInstance(DescribeUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new DescribeUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceBackupState - 获取UDB实例备份状态 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_backup_state - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BackupId" => (integer) 备份记录ID - * "BackupZone" => (string) 跨可用区高可用备库所在可用区,参见[可用区列表] - * ] - * - * Outputs: - * - * $outputs = [ - * "State" => (string) 备份状态 0 Backuping // 备份中 1 Success // 备份成功 2 Failed // 备份失败 3 Expired // 备份过期 - * ] - * - * @return DescribeUDBInstanceBackupStateResponse * @throws UCloudException */ public function describeUDBInstanceBackupState(DescribeUDBInstanceBackupStateRequest $request = null) @@ -1017,30 +639,13 @@ public function describeUDBInstanceBackupState(DescribeUDBInstanceBackupStateReq $resp = $this->invoke($request); return new DescribeUDBInstanceBackupStateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceBackupURL - 获取UDB备份下载地址 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_backup_url - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可通过DescribeUDBInstance获取 - * "BackupId" => (integer) DB实例备份ID,该值可以通过DescribeUDBBackup获取 - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupPath" => (string) DB实例备份文件公网的地址 - * "InnerBackupPath" => (string) DB实例备份文件内网的地址 - * ] - * - * @return DescribeUDBInstanceBackupURLResponse * @throws UCloudException */ public function describeUDBInstanceBackupURL(DescribeUDBInstanceBackupURLRequest $request = null) @@ -1048,37 +653,13 @@ public function describeUDBInstanceBackupURL(DescribeUDBInstanceBackupURLRequest $resp = $this->invoke($request); return new DescribeUDBInstanceBackupURLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceBinlog - 获取UDB指定时间段的binlog列表 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_binlog - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id - * "BeginTime" => (integer) 过滤条件:起始时间(时间戳) - * "EndTime" => (integer) 过滤条件:结束时间(时间戳) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 获取的Binlog信息列表 UDBInstanceBinlogSet[ - * [ - * "Name" => (string) Binlog文件名 - * "Size" => (integer) Binlog文件大小 - * "BeginTime" => (integer) Binlog文件生成时间(时间戳) - * "EndTime" => (integer) Binlog文件结束时间(时间戳) - * ] - * ] - * ] - * - * @return DescribeUDBInstanceBinlogResponse * @throws UCloudException */ public function describeUDBInstanceBinlog(DescribeUDBInstanceBinlogRequest $request = null) @@ -1086,29 +667,13 @@ public function describeUDBInstanceBinlog(DescribeUDBInstanceBinlogRequest $requ $resp = $this->invoke($request); return new DescribeUDBInstanceBinlogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceBinlogBackupState - 获取udb实例备份状态 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_binlog_backup_state - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BackupId" => (integer) 备份记录ID - * "BackupZone" => (string) 跨可用区高可用备库所在可用区 - * ] - * - * Outputs: - * - * $outputs = [ - * "State" => (string) 备份状态 0 Backuping // 备份中 1 Success // 备份成功 2 Failed // 备份失败 3 Expired // 备份过期 - * ] - * - * @return DescribeUDBInstanceBinlogBackupStateResponse * @throws UCloudException */ public function describeUDBInstanceBinlogBackupState(DescribeUDBInstanceBinlogBackupStateRequest $request = null) @@ -1116,32 +681,13 @@ public function describeUDBInstanceBinlogBackupState(DescribeUDBInstanceBinlogBa $resp = $this->invoke($request); return new DescribeUDBInstanceBinlogBackupStateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceLog - 查询某一段时间内UDB的错误日志或慢查询日志 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_log - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DBId" => (string) 实例ID - * "BeginTime" => (integer) 查询的日志开始的时间戳(Unix Timestamp)。对于实时查询,这个参数应该是上次轮询请求时的时间戳,后台会返回从该值到当前时间的日志内容。 - * "EndTime" => (integer) 查询日志的结束时间戳(Unix Timestamp),对于实时查询不传该值,与BeginTime的差值不超过24小时:(EndTime-BeginTime) < 24*60*60 - * "LogType" => (string) 查询日志的类型error:错误日志;slow:慢日志 - * ] - * - * Outputs: - * - * $outputs = [ - * "Log" => (string) 查询到的日志内容,一段纯文本 - * "NextTime" => (string) 此次查询到的日志的下一个时间,用于下一次轮询时的BeginTime参数;如果日志查询结束则返回为空,前端结束查询 - * ] - * - * @return DescribeUDBInstanceLogResponse * @throws UCloudException */ public function describeUDBInstanceLog(DescribeUDBInstanceLogRequest $request = null) @@ -1149,40 +695,13 @@ public function describeUDBInstanceLog(DescribeUDBInstanceLogRequest $request = $resp = $this->invoke($request); return new DescribeUDBInstanceLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstancePrice - 获取UDB实例价格信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "MemoryLimit" => (integer) 内存限制(MB),单位为MB.目前支持:1000-96000 - * "DiskSpace" => (integer) 磁盘空间(GB),暂时支持20(GB) - 3000(GB), 输入不带单位 - * "DBTypeId" => (string) UDB实例的DB版本字符串 - * "Count" => (integer) 购买DB实例数量,最大数量为10台, 默认为1台 - * "ChargeType" => (string) Year,按年付费; Month,按月付费 Dynamic,按需付费(需开启权限) Trial,试用(需开启权限)默认为月付 - * "Quantity" => (integer) DB购买多少个"计费时间单位",默认值为1。比如:买2个月,Quantity就是2。如果计费单位是“按月”,并且Quantity为0,表示“购买到月底” - * "UseSSD" => (string) 是否使用SSD,只能填true或false,默认为false - * "SSDType" => (string) SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必填 - * "InstanceMode" => (string) 实例的部署类型。可选值为:Normal: 普通单点实例,Slave: 从库实例,HA: 高可用部署实例,默认是Normal - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 价格 参照UDBInstancePriceSet[ - * [ - * "ChargeType" => (string) Year, Month, Dynamic,Trial - * "Price" => (integer) 价格,单位为分 - * ] - * ] - * ] - * - * @return DescribeUDBInstancePriceResponse * @throws UCloudException */ public function describeUDBInstancePrice(DescribeUDBInstancePriceRequest $request = null) @@ -1190,28 +709,13 @@ public function describeUDBInstancePrice(DescribeUDBInstancePriceRequest $reques $resp = $this->invoke($request); return new DescribeUDBInstancePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceState - 获取UDB实例状态 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_state - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * "State" => (string) DB状态标记 Init:初始化中;Fail:安装失败; Starting:启动中; Running : 运行 ;Shutdown:关闭中; Shutoff :已关闭; Delete:已删除; Upgrading:升级中; Promoting: 提升为独库进行中; Recovering: 恢复中; Recover fail:恢复失败。 - * ] - * - * @return DescribeUDBInstanceStateResponse * @throws UCloudException */ public function describeUDBInstanceState(DescribeUDBInstanceStateRequest $request = null) @@ -1219,32 +723,13 @@ public function describeUDBInstanceState(DescribeUDBInstanceStateRequest $reques $resp = $this->invoke($request); return new DescribeUDBInstanceStateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBInstanceUpgradePrice - 获取UDB实例升降级价格信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_instance_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id - * "MemoryLimit" => (integer) 内存限制(MB) - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G - 500G - * "UseSSD" => (boolean) 是否使用SSD,默认为false - * "SSDType" => (string) SSD类型,可选值为"SATA"、"PCI-E",如果UseSSD为true ,则必选 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (integer) 价格,单位为分 - * ] - * - * @return DescribeUDBInstanceUpgradePriceResponse * @throws UCloudException */ public function describeUDBInstanceUpgradePrice(DescribeUDBInstanceUpgradePriceRequest $request = null) @@ -1252,30 +737,13 @@ public function describeUDBInstanceUpgradePrice(DescribeUDBInstanceUpgradePriceR $resp = $this->invoke($request); return new DescribeUDBInstanceUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBLogBackupURL - 获取UDB的slowlog备份地址 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_log_backup_url - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DBId" => (string) DB实例Id - * "BackupId" => (integer) DB实例备份ID - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupPath" => (string) 备份外网URL - * "UsernetPath" => (string) 备份用户网URL - * ] - * - * @return DescribeUDBLogBackupURLResponse * @throws UCloudException */ public function describeUDBLogBackupURL(DescribeUDBLogBackupURLRequest $request = null) @@ -1283,48 +751,13 @@ public function describeUDBLogBackupURL(DescribeUDBLogBackupURLRequest $request $resp = $this->invoke($request); return new DescribeUDBLogBackupURLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBLogPackage - 列表UDB实例binlog或slowlog或errorlog备份信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_log_package - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Offset" => (integer) 分页显示的起始偏移,列表操作则指定 - * "Limit" => (integer) 分页显示的条目数,列表操作则指定 - * "Type" => (integer) 需要列出的备份文件类型,每种文件的值如下 2 : BINLOG\_BACKUP 3 : SLOW\_QUERY\_BACKUP 4 : ERRORLOG\_BACKUP - * "Types" => (array) Types作为Type的补充,支持多值传入,可以获取多个类型的日志记录,如:Types.0=2&Types.1=3 - * "DBId" => (string) DB实例Id,如果指定,则只获取该db的备份信息 - * "BeginTime" => (integer) 过滤条件:起始时间(时间戳) - * "EndTime" => (integer) 过滤条件:结束时间(时间戳) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 备份信息 参见LogPackageDataSet[ - * [ - * "BackupId" => (integer) 备份id - * "BackupName" => (string) 备份名称 - * "BackupTime" => (integer) 备份时间 - * "BackupSize" => (integer) 备份文件大小 - * "BackupType" => (integer) 备份类型,包括2-binlog备份,3-slowlog备份 - * "State" => (string) 备份状态 Backuping // 备份中 Success // 备份成功 Failed // 备份失败 Expired // 备份过期 - * "DBId" => (string) dbid - * "DBName" => (string) 对应的db名称 - * "Zone" => (string) 所在可用区 - * "BackupZone" => (string) 跨可用区高可用备库所在可用区 - * ] - * ] - * "TotalCount" => (integer) 备份总数,如果指定dbid,则是该db备份总数 - * ] - * - * @return DescribeUDBLogPackageResponse * @throws UCloudException */ public function describeUDBLogPackage(DescribeUDBLogPackageRequest $request = null) @@ -1332,53 +765,13 @@ public function describeUDBLogPackage(DescribeUDBLogPackageRequest $request = nu $resp = $this->invoke($request); return new DescribeUDBLogPackageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBParamGroup - 获取参数组详细参数信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 分页显示的起始偏移,列表操作则指定 - * "Limit" => (integer) 分页显示的条目数,列表操作则指定 - * "GroupId" => (integer) 参数组id,如果指定则获取描述,否则是列表操作,需要 指定Offset/Limit - * "IsInUDBC" => (boolean) 是否选取专区中配置 - * "RegionFlag" => (boolean) 当请求没有填写Zone时,如果指定为true,表示只拉取跨可用区的相关配置文件,否则,拉取所有机房的配置文件(包括每个单可用区和跨可用区) - * "ClassType" => (string) 如果未指定GroupId,则可选是否选取特定DB类型的配置(sql, nosql, postgresql, sqlserver) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 参数组列表 参照UDBParamGroupSet[ - * [ - * "GroupId" => (integer) 参数组id - * "GroupName" => (string) 参数组名称 - * "DBTypeId" => (string) DB类型id,mysql/mongodb按版本细分各有一个id 目前id的取值范围为[1,7],数值对应的版本如下 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6 7:percona-5.6 - * "Description" => (string) 参数组描述 - * "Modifiable" => (boolean) 参数组是否可修改 - * "ParamMember" => (array) 参数的键值对表 UDBParamMemberSet[ - * [ - * "Key" => (string) 参数名称 - * "Value" => (string) 参数值 - * "ValueType" => (integer) 参数值应用类型,取值范围为{0,10,20,30},各值 代表意义为 0-unknown、10-int、20-string、 30-bool - * "AllowedVal" => (string) 允许的值(根据参数类型,用分隔符表示) - * "ApplyType" => (integer) 参数值应用类型,取值范围为{0,10,20},各值代表 意义为0-unknown、10-static、20-dynamic - * "Modifiable" => (boolean) 是否可更改,默认为false - * "FormatType" => (integer) 允许值的格式类型,取值范围为{0,10,20},意义分 别为PVFT_UNKOWN=0,PVFT_RANGE=10, PVFT_ENUM=20 - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 参数组总数,列表操作时才会有该参数 - * ] - * - * @return DescribeUDBParamGroupResponse * @throws UCloudException */ public function describeUDBParamGroup(DescribeUDBParamGroupRequest $request = null) @@ -1386,43 +779,13 @@ public function describeUDBParamGroup(DescribeUDBParamGroupRequest $request = nu $resp = $this->invoke($request); return new DescribeUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBSplittingInfo - 描述读写分离功能的详细信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_splitting_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "MasterDBId" => (string) DB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * "Zone" => (string) 可用区 - * "MasterDBId" => (string) DB实例ID - * "RWIP" => (string) 读写分离IP - * "DelayThreshold" => (integer) 时间阈值 - * "Port" => (integer) 端口号 - * "ReadModel" => (string) 读写分离策略 - * "DBTypeId" => (string) 数据库版本 - * "RWState" => (string) 读写分离状态 - * "DataSet" => (array) 读写分离从库信息[ - * [ - * "DBId" => (string) DB实例ID - * "Role" => (string) 主库/从库 - * "VirtualIP" => (string) DBIP - * "ReadWeight" => (integer) 读写分离比重 - * "State" => (string) DB状态 - * ] - * ] - * ] - * - * @return DescribeUDBSplittingInfoResponse * @throws UCloudException */ public function describeUDBSplittingInfo(DescribeUDBSplittingInfoRequest $request = null) @@ -1430,35 +793,13 @@ public function describeUDBSplittingInfo(DescribeUDBSplittingInfoRequest $reques $resp = $this->invoke($request); return new DescribeUDBSplittingInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDBType - 获取UDB支持的类型信息 * - * See also: https://docs.ucloud.cn/api/udb-api/describe_udb_type - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "BackupZone" => (string) 跨可用区高可用DB的备库所在区域,仅当该可用区支持跨可用区高可用时填入。参见 [可用区列表](../summary/regionlist.html) - * "DBClusterType" => (string) DB实例类型,如mysql,sqlserver,mongo,postgresql - * "InstanceMode" => (string) 返回支持某种实例类型的DB类型。如果没传,则表示任何实例类型均可。normal:单点,ha:高可用,sharded_cluster:分片集群 - * "DiskType" => (string) 返回支持某种磁盘类型的DB类型,如Normal、SSD、NVMe_SSD。如果没传,则表示任何磁盘类型均可。 - * "CompatibleWithDBType" => (string) 返回从备份创建实例时,该版本号所支持的备份创建版本。如果没传,则表示不是从备份创建。 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) DB类型列表 参数见 UDBTypeSet[ - * [ - * "DBTypeId" => (string) DB类型id,mysql/mongodb按版本细分各有一个id, 目前id的取值范围为[1,7],数值对应的版本如下: 1:mysql-5.5,2:mysql-5.1,3:percona-5.5 4:mongodb-2.4,5:mongodb-2.6,6:mysql-5.6, 7:percona-5.6 - * ] - * ] - * ] - * - * @return DescribeUDBTypeResponse * @throws UCloudException */ public function describeUDBType(DescribeUDBTypeRequest $request = null) @@ -1466,26 +807,13 @@ public function describeUDBType(DescribeUDBTypeRequest $request = null) $resp = $this->invoke($request); return new DescribeUDBTypeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DisableUDBRWSplitting - 关闭DB的读写分离功能 * - * See also: https://docs.ucloud.cn/api/udb-api/disable_udb_rw_splitting - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "MasterDBId" => (string) DB实例ID(master) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DisableUDBRWSplittingResponse * @throws UCloudException */ public function disableUDBRWSplitting(DisableUDBRWSplittingRequest $request = null) @@ -1493,28 +821,13 @@ public function disableUDBRWSplitting(DisableUDBRWSplittingRequest $request = nu $resp = $this->invoke($request); return new DisableUDBRWSplittingResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * EditUDBBackupBlacklist - 编辑UDB实例的备份黑名单 * - * See also: https://docs.ucloud.cn/api/udb-api/edit_udb_backup_blacklist - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id,该值可以通过DescribeUDBInstance获取 - * "Blacklist" => (string) 黑名单,规范示例,指定库mysql.%;test.%; 指定表city.address; - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return EditUDBBackupBlacklistResponse * @throws UCloudException */ public function editUDBBackupBlacklist(EditUDBBackupBlacklistRequest $request = null) @@ -1522,29 +835,13 @@ public function editUDBBackupBlacklist(EditUDBBackupBlacklistRequest $request = $resp = $this->invoke($request); return new EditUDBBackupBlacklistResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * EnableUDBRWSplitting - 开启DB的读写分离功能 * - * See also: https://docs.ucloud.cn/api/udb-api/enable_udb_rw_splitting - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "MasterDBId" => (string) DB实例ID(主库) - * "BackupZone" => (string) 备份的可用区。用于创建跨可用区读写分离的一个节点,跨机房的读写分离必须有这个参数 - * ] - * - * Outputs: - * - * $outputs = [ - * "MasterDBId" => (string) DB实例ID(主库) - * "RWIp" => (string) 读写分离访问IP - * ] - * - * @return EnableUDBRWSplittingResponse * @throws UCloudException */ public function enableUDBRWSplitting(EnableUDBRWSplittingRequest $request = null) @@ -1552,28 +849,13 @@ public function enableUDBRWSplitting(EnableUDBRWSplittingRequest $request = null $resp = $this->invoke($request); return new EnableUDBRWSplittingResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ExtractUDBParamGroup - 获取配置文件内容 * - * See also: https://docs.ucloud.cn/api/udb-api/extract_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。如果RegionFlag=false,必须传,反之,可不传。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "GroupId" => (integer) 配置id - * "RegionFlag" => (boolean) 是否跨可用区,RegionFlag为true时表示跨可用区配置文件。如果RegionFlag=true,Zone可以不传,否则Zone必须传。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Content" => (string) 配置文件内容 - * ] - * - * @return ExtractUDBParamGroupResponse * @throws UCloudException */ public function extractUDBParamGroup(ExtractUDBParamGroupRequest $request = null) @@ -1581,28 +863,13 @@ public function extractUDBParamGroup(ExtractUDBParamGroupRequest $request = null $resp = $this->invoke($request); return new ExtractUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * FetchUDBInstanceEarliestRecoverTime - 获取UDB最早可回档的时间点 * - * See also: https://docs.ucloud.cn/api/udb-api/fetch_udb_instance_earliest_recover_time - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) DB实例Id - * ] - * - * Outputs: - * - * $outputs = [ - * "EarliestTime" => (integer) 获取最早可回档时间点 - * ] - * - * @return FetchUDBInstanceEarliestRecoverTimeResponse * @throws UCloudException */ public function fetchUDBInstanceEarliestRecoverTime(FetchUDBInstanceEarliestRecoverTimeRequest $request = null) @@ -1610,28 +877,27 @@ public function fetchUDBInstanceEarliestRecoverTime(FetchUDBInstanceEarliestReco $resp = $this->invoke($request); return new FetchUDBInstanceEarliestRecoverTimeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ModifyUDBInstanceName - 重命名UDB实例 - * - * See also: https://docs.ucloud.cn/api/udb-api/modify_udb_instance_name - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * "Name" => (string) 实例的新名字, 长度要求为6~63位 - * ] + * GetUDBClientConnNum - 输入一个DBID,能够获取客户端来源IP以及对应的连接数 * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function getUDBClientConnNum(GetUDBClientConnNumRequest $request = null) + { + $resp = $this->invoke($request); + return new GetUDBClientConnNumResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyUDBInstanceName - 重命名UDB实例 * - * @return ModifyUDBInstanceNameResponse * @throws UCloudException */ public function modifyUDBInstanceName(ModifyUDBInstanceNameRequest $request = null) @@ -1639,29 +905,13 @@ public function modifyUDBInstanceName(ModifyUDBInstanceNameRequest $request = nu $resp = $this->invoke($request); return new ModifyUDBInstanceNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUDBInstancePassword - 修改DB实例的管理员密码 * - * See also: https://docs.ucloud.cn/api/udb-api/modify_udb_instance_password - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的ID,该值可以通过DescribeUDBInstance获取 - * "Password" => (string) 实例的新密码 - * "AccountName" => (string) sqlserver帐号,仅在sqlserver的情况下填该参数 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUDBInstancePasswordResponse * @throws UCloudException */ public function modifyUDBInstancePassword(ModifyUDBInstancePasswordRequest $request = null) @@ -1669,26 +919,13 @@ public function modifyUDBInstancePassword(ModifyUDBInstancePasswordRequest $requ $resp = $this->invoke($request); return new ModifyUDBInstancePasswordResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PromoteUDBInstanceToHA - 普通db升级为高可用(只针对mysql5.5及以上版本SSD机型的实例) ,对于NVMe机型的单点升级高可用,虽然也能使用该操作再加上SwitchUDBInstanceToHA,但是更建议直接调用新的API接口(UpgradeUDBInstanceToHA) * - * See also: https://docs.ucloud.cn/api/udb-api/promote_udb_instance_to_ha - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return PromoteUDBInstanceToHAResponse * @throws UCloudException */ public function promoteUDBInstanceToHA(PromoteUDBInstanceToHARequest $request = null) @@ -1696,28 +933,13 @@ public function promoteUDBInstanceToHA(PromoteUDBInstanceToHARequest $request = $resp = $this->invoke($request); return new PromoteUDBInstanceToHAResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PromoteUDBSlave - 从库提升为独立库 * - * See also: https://docs.ucloud.cn/api/udb-api/promote_udb_slave - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * "IsForce" => (boolean) 是否强制(如果从库落后可能会禁止提升),默认false 如果落后情况下,强制提升丢失数据 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return PromoteUDBSlaveResponse * @throws UCloudException */ public function promoteUDBSlave(PromoteUDBSlaveRequest $request = null) @@ -1725,36 +947,13 @@ public function promoteUDBSlave(PromoteUDBSlaveRequest $request = null) $resp = $this->invoke($request); return new PromoteUDBSlaveResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeUDBInstance - 修改(升级和降级)UDB实例的配置,包括内存和磁盘的配置,对于内存升级无需关闭实例,其他场景需要事先关闭实例。两套参数可以配置升降机:1.配置UseSSD和SSDType 2.配置InstanceType,不需要配置InstanceMode。这两套第二套参数的优先级更高 * - * See also: https://docs.ucloud.cn/api/udb-api/resize_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id - * "MemoryLimit" => (integer) 内存限制(MB),目前支持以下几档 1000M/2000M/4000M/ 6000M/8000M/ 12000M/16000M/ 24000M/32000M/ 48000M/64000M/96000M/128000M/192000M/256000M/320000M。 - * "DiskSpace" => (integer) 磁盘空间(GB), 暂时支持20G-32T - * "UseSSD" => (boolean) 是否使用SSD,默认为true - * "SSDType" => (string) SSD类型,可选值为"SATA"、"PCI-E"、“NVMe”,如果UseSSD为true ,则必选 - * "UDBCId" => (string) 专区的ID,如果有值表示专区中的DB配置升降级 - * "InstanceType" => (string) UDB数据库机型: "Normal": "标准机型" , "SATA_SSD": "SSD机型" , "PCIE_SSD": "SSD高性能机型" , "Normal_Volume": "标准大容量机型", "SATA_SSD_Volume": "SSD大容量机型" , "PCIE_SSD_Volume": "SSD高性能大容量机型",“NVMe_SSD”:“快杰机型” - * "InstanceMode" => (string) UDB实例模式类型, 可选值如下: "Normal": 普通版UDB实例 "HA": 高可用版UDB实例 默认是"Normal" - * "StartAfterUpgrade" => (boolean) DB关闭状态下升降级,升降级后是否启动DB,默认为false - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ResizeUDBInstanceResponse * @throws UCloudException */ public function resizeUDBInstance(ResizeUDBInstanceRequest $request = null) @@ -1762,26 +961,13 @@ public function resizeUDBInstance(ResizeUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new ResizeUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartRWSplitting - 读写分离中间件重启,对应docker重启,但是ip不变 * - * See also: https://docs.ucloud.cn/api/udb-api/restart_rw_splitting - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "MasterDBId" => (string) 待关闭读写分离中间键ProxyId - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartRWSplittingResponse * @throws UCloudException */ public function restartRWSplitting(RestartRWSplittingRequest $request = null) @@ -1789,27 +975,13 @@ public function restartRWSplitting(RestartRWSplittingRequest $request = null) $resp = $this->invoke($request); return new RestartRWSplittingResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartUDBInstance - 重启UDB实例 * - * See also: https://docs.ucloud.cn/api/udb-api/restart_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartUDBInstanceResponse * @throws UCloudException */ public function restartUDBInstance(RestartUDBInstanceRequest $request = null) @@ -1817,30 +989,13 @@ public function restartUDBInstance(RestartUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new RestartUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SetUDBRWSplitting - 设置读写分离的模式 * - * See also: https://docs.ucloud.cn/api/udb-api/set_udb_rw_splitting - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "MasterDBId" => (string) DB实例ID(master) - * "ReadModel" => (string) 读写分离策略 - * "DBIds" => (array) DBIds.0 代表UDB主节点, DBIds.1 到DBIds.n 代表1到N个从节点 - * "ReadPercents" => (array) udb主从节点的只读比例。ReadPercents.0代表主节点的只读比例,ReadPercents.1代表从节点1的读写比例, 以此类推 - * "DelayThreshold" => (integer) 时间阙值 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetUDBRWSplittingResponse * @throws UCloudException */ public function setUDBRWSplitting(SetUDBRWSplittingRequest $request = null) @@ -1848,27 +1003,13 @@ public function setUDBRWSplitting(SetUDBRWSplittingRequest $request = null) $resp = $this->invoke($request); return new SetUDBRWSplittingResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StartUDBInstance - 启动UDB实例 * - * See also: https://docs.ucloud.cn/api/udb-api/start_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return StartUDBInstanceResponse * @throws UCloudException */ public function startUDBInstance(StartUDBInstanceRequest $request = null) @@ -1876,28 +1017,13 @@ public function startUDBInstance(StartUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new StartUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StopUDBInstance - 关闭UDB实例 * - * See also: https://docs.ucloud.cn/api/udb-api/stop_udb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * "ForceToKill" => (boolean) 是否使用强制手段关闭DB,默认是false - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return StopUDBInstanceResponse * @throws UCloudException */ public function stopUDBInstance(StopUDBInstanceRequest $request = null) @@ -1905,27 +1031,13 @@ public function stopUDBInstance(StopUDBInstanceRequest $request = null) $resp = $this->invoke($request); return new StopUDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * SwitchUDBHAToSentinel - UDB高可用实例从HAProxy版本升级为Sentinel版本(不带HAProxy)升级耗时30-70秒 - * - * See also: https://docs.ucloud.cn/api/udb-api/switch_udb_ha_to_sentinel - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) UDB的实例ID - * ] + * SwitchUDBHAToSentinel - UDB高可用实例从HAProxy版本升级为Sentinel版本(不带HAProxy)升级耗时5-10秒 * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SwitchUDBHAToSentinelResponse * @throws UCloudException */ public function switchUDBHAToSentinel(SwitchUDBHAToSentinelRequest $request = null) @@ -1933,30 +1045,13 @@ public function switchUDBHAToSentinel(SwitchUDBHAToSentinelRequest $request = nu $resp = $this->invoke($request); return new SwitchUDBHAToSentinelResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SwitchUDBInstanceToHA - 普通UDB切换为高可用(只针对mysql5.5及以上版本SSD机型的实例) ,原db状态为WaitForSwitch时,调用该api; 对于NVMe机型的单点升级高可用,虽然也能使用PromoteUDBInstanceToHA再加上该操作,但是更建议直接调用新的API接口(UpgradeUDBInstanceToHA) * - * See also: https://docs.ucloud.cn/api/udb-api/switch_udb_instance_to_ha - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * "ChargeType" => (string) Year, Month, Dynamic,Trial,不填则按现在单点计费执行 - * "Quantity" => (string) 购买时长,需要和 ChargeType 搭配使用,否则使用单点计费策略的值 - * "Tag" => (string) 业务组 - * ] - * - * Outputs: - * - * $outputs = [ - * "DBId" => (string) 切换后高可用db实例的Id - * ] - * - * @return SwitchUDBInstanceToHAResponse * @throws UCloudException */ public function switchUDBInstanceToHA(SwitchUDBInstanceToHARequest $request = null) @@ -1964,31 +1059,13 @@ public function switchUDBInstanceToHA(SwitchUDBInstanceToHARequest $request = nu $resp = $this->invoke($request); return new SwitchUDBInstanceToHAResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUDBInstanceBackupStrategy - 修改UDB自动备份策略 * - * See also: https://docs.ucloud.cn/api/udb-api/update_udb_instance_backup_strategy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBId" => (string) 主节点的Id - * "BackupTime" => (integer) 备份的整点时间,范围[0,23] - * "BackupDate" => (string) 备份时期标记位。共7位,每一位为一周中一天的备份情况,0表示关闭当天备份,1表示打开当天备份。最右边的一位为星期天的备份开关,其余从右到左依次为星期一到星期六的备份配置开关,每周必须至少设置两天备份。例如:1100000表示打开星期六和星期五的备份功能 - * "ForceDump" => (boolean) 当导出某些数据遇到问题后,是否强制导出其他剩余数据默认是false需要同时设置BackupDate字段 - * "BackupMethod" => (string) 选择默认的备份方式,可选 snapshot 表示使用快照/物理备份,不填或者其它任何值为默认的逻辑备份。需要同时设置BackupDate字段。(注意现在只有SSD 版本的 MySQL实例支持物理备份) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUDBInstanceBackupStrategyResponse * @throws UCloudException */ public function updateUDBInstanceBackupStrategy(UpdateUDBInstanceBackupStrategyRequest $request = null) @@ -1996,29 +1073,13 @@ public function updateUDBInstanceBackupStrategy(UpdateUDBInstanceBackupStrategyR $resp = $this->invoke($request); return new UpdateUDBInstanceBackupStrategyResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUDBInstanceSlaveBackupSwitch - 开启或者关闭UDB从库备份 * - * See also: https://docs.ucloud.cn/api/udb-api/update_udb_instance_slave_backup_switch - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "MasterDBId" => (string) 主库的Id - * "BackupSwitch" => (integer) 从库的备份开关,范围[0,1],0表示从库备份功能关闭,1 表示从库备份开关打开。 - * "SlaveDBId" => (string) 从库的Id,如果从库备份开关设定为打开,则必须赋值。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUDBInstanceSlaveBackupSwitchResponse * @throws UCloudException */ public function updateUDBInstanceSlaveBackupSwitch(UpdateUDBInstanceSlaveBackupSwitchRequest $request = null) @@ -2026,32 +1087,13 @@ public function updateUDBInstanceSlaveBackupSwitch(UpdateUDBInstanceSlaveBackupS $resp = $this->invoke($request); return new UpdateUDBInstanceSlaveBackupSwitchResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUDBParamGroup - 更新UDB配置参数项 * - * See also: https://docs.ucloud.cn/api/udb-api/update_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (integer) 配置参数组id,使用DescribeUDBParamGroup获得 - * "Key" => (string) 参数名称(与Value配合使用) - * "Value" => (string) 参数值(与Key配合使用) - * "Name" => (string) 配置文件的名字,不传时认为不修改名字,传了则不能为空 - * "Description" => (string) 配置文件的描述,不传时认为不修改 - * "RegionFlag" => (boolean) 该配置文件是否是地域级别配置文件,默认是false - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUDBParamGroupResponse * @throws UCloudException */ public function updateUDBParamGroup(UpdateUDBParamGroupRequest $request = null) @@ -2059,27 +1101,13 @@ public function updateUDBParamGroup(UpdateUDBParamGroupRequest $request = null) $resp = $this->invoke($request); return new UpdateUDBParamGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpgradeUDBInstanceToHA - 快杰普通db升级为高可用(只针对mysql5.5及以上版本Nvme机型的实例) * - * See also: https://docs.ucloud.cn/api/udb-api/upgrade_udb_instance_to_ha - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DBId" => (string) 实例的Id,该值可以通过DescribeUDBInstance获取 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpgradeUDBInstanceToHAResponse * @throws UCloudException */ public function upgradeUDBInstanceToHA(UpgradeUDBInstanceToHARequest $request = null) @@ -2087,32 +1115,13 @@ public function upgradeUDBInstanceToHA(UpgradeUDBInstanceToHARequest $request = $resp = $this->invoke($request); return new UpgradeUDBInstanceToHAResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UploadUDBParamGroup - 导入UDB配置 * - * See also: https://docs.ucloud.cn/api/udb-api/upload_udb_param_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBTypeId" => (string) DB类型id,DB类型id,mysql/mongodb/postgesql按版本细分 1:mysql-5.1,2:mysql-5.5,3:percona-5.5,4:mysql-5.6,5:percona-5.6,6:mysql-5.7,7:percona-5.7,8:mariadb-10.0,9:mongodb-2.4,10:mongodb-2.6,11:mongodb-3.0,12:mongodb-3.2,13:postgresql-9.4,14:postgresql-9.6 - * "GroupName" => (string) 配置参数组名称 - * "Description" => (string) 参数组描述 - * "Content" => (string) 配置内容,导入的配置内容采用base64编码 - * "RegionFlag" => (boolean) 该配置文件是否是地域级别配置文件,默认是false - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (integer) 配置参数组id - * ] - * - * @return UploadUDBParamGroupResponse * @throws UCloudException */ public function uploadUDBParamGroup(UploadUDBParamGroupRequest $request = null) diff --git a/src/UDDB/Apis/ChangeUDDBInstanceNameRequest.php b/src/UDDB/Apis/ChangeUDDBInstanceNameRequest.php index 5fac0e38..ce577bf6 100644 --- a/src/UDDB/Apis/ChangeUDDBInstanceNameRequest.php +++ b/src/UDDB/Apis/ChangeUDDBInstanceNameRequest.php @@ -1,6 +1,7 @@ markRequired("NewName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例Id * @@ -107,11 +105,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * NewName: 名称 * @@ -127,7 +124,7 @@ public function getNewName() * * @param string $newName */ - public function setNewName($newName) + public function setNewName(string $newName) { $this->set("NewName", $newName); } diff --git a/src/UDDB/Apis/ChangeUDDBInstanceNameResponse.php b/src/UDDB/Apis/ChangeUDDBInstanceNameResponse.php index a05a20bc..aee9152d 100644 --- a/src/UDDB/Apis/ChangeUDDBInstanceNameResponse.php +++ b/src/UDDB/Apis/ChangeUDDBInstanceNameResponse.php @@ -1,6 +1,7 @@ markRequired("SlaveCount"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB资源id * @@ -107,11 +105,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * SlaveCount: 每个数据节点的只读实例个数, 取值必须>=0 * @@ -127,7 +124,7 @@ public function getSlaveCount() * * @param string $slaveCount */ - public function setSlaveCount($slaveCount) + public function setSlaveCount(string $slaveCount) { $this->set("SlaveCount", $slaveCount); } diff --git a/src/UDDB/Apis/ChangeUDDBSlaveCountResponse.php b/src/UDDB/Apis/ChangeUDDBSlaveCountResponse.php index 4c49d191..923dc351 100644 --- a/src/UDDB/Apis/ChangeUDDBSlaveCountResponse.php +++ b/src/UDDB/Apis/ChangeUDDBSlaveCountResponse.php @@ -1,6 +1,7 @@ markRequired("DataNodeDiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -53,11 +54,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -73,11 +73,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -93,11 +92,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DBTypeId: UDDB的数据库版本,支持版本如下:mysql-5.6 mysql-5.7. 如果不填,则默认为mysql-5.6 * @@ -113,11 +111,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * Name: 实例名称,至少6位 * @@ -133,11 +130,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * AdminPassword: 管理员密码, 密码需要使用base64加密 * @@ -153,11 +149,10 @@ public function getAdminPassword() * * @param string $adminPassword */ - public function setAdminPassword($adminPassword) + public function setAdminPassword(string $adminPassword) { $this->set("AdminPassword", $adminPassword); } - /** * RouterVersion: UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 * @@ -173,11 +168,10 @@ public function getRouterVersion() * * @param string $routerVersion */ - public function setRouterVersion($routerVersion) + public function setRouterVersion(string $routerVersion) { $this->set("RouterVersion", $routerVersion); } - /** * RouterNodeNum: 其他版本:该参数可不填;专享版:物理机台数 * @@ -193,11 +187,10 @@ public function getRouterNodeNum() * * @param int $routerNodeNum */ - public function setRouterNodeNum($routerNodeNum) + public function setRouterNodeNum(int $routerNodeNum) { $this->set("RouterNodeNum", $routerNodeNum); } - /** * DataNodeCount: 初始的数据节点个数 取值必须>0. * @@ -213,11 +206,10 @@ public function getDataNodeCount() * * @param int $dataNodeCount */ - public function setDataNodeCount($dataNodeCount) + public function setDataNodeCount(int $dataNodeCount) { $this->set("DataNodeCount", $dataNodeCount); } - /** * DataNodeMemory: 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. * @@ -233,11 +225,10 @@ public function getDataNodeMemory() * * @param int $dataNodeMemory */ - public function setDataNodeMemory($dataNodeMemory) + public function setDataNodeMemory(int $dataNodeMemory) { $this->set("DataNodeMemory", $dataNodeMemory); } - /** * DataNodeDiskSpace: 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. * @@ -253,11 +244,10 @@ public function getDataNodeDiskSpace() * * @param int $dataNodeDiskSpace */ - public function setDataNodeDiskSpace($dataNodeDiskSpace) + public function setDataNodeDiskSpace(int $dataNodeDiskSpace) { $this->set("DataNodeDiskSpace", $dataNodeDiskSpace); } - /** * InstanceMode: 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA * @@ -273,11 +263,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * InstanceType: 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD * @@ -293,11 +282,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * ChargeType: 付费类型,可选值如下:Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 默认值为: Dynamic * @@ -313,11 +301,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认值1 * @@ -333,11 +320,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * AdminUser: 管理员帐户名,默认root * @@ -353,11 +339,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * Port: 端口号,mysql默认端口为3306 * @@ -373,11 +358,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * DataNodeSlaveCount: 每个数据节点的只读实例个数, 取值必须>=0. 默认取值为0. * @@ -393,11 +377,10 @@ public function getDataNodeSlaveCount() * * @param int $dataNodeSlaveCount */ - public function setDataNodeSlaveCount($dataNodeSlaveCount) + public function setDataNodeSlaveCount(int $dataNodeSlaveCount) { $this->set("DataNodeSlaveCount", $dataNodeSlaveCount); } - /** * VPCId: VPC的ID * @@ -413,11 +396,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网ID * @@ -433,11 +415,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * CouponId: 使用的代金券id * @@ -453,7 +434,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDDB/Apis/CreateUDDBInstanceResponse.php b/src/UDDB/Apis/CreateUDDBInstanceResponse.php index 77ecc793..c20b20d5 100644 --- a/src/UDDB/Apis/CreateUDDBInstanceResponse.php +++ b/src/UDDB/Apis/CreateUDDBInstanceResponse.php @@ -1,6 +1,7 @@ set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/DeleteUDDBInstanceRequest.php b/src/UDDB/Apis/DeleteUDDBInstanceRequest.php index 9821b9d3..6681757d 100644 --- a/src/UDDB/Apis/DeleteUDDBInstanceRequest.php +++ b/src/UDDB/Apis/DeleteUDDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UDDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -106,7 +104,7 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/DeleteUDDBInstanceResponse.php b/src/UDDB/Apis/DeleteUDDBInstanceResponse.php index 169c1f84..2632a711 100644 --- a/src/UDDB/Apis/DeleteUDDBInstanceResponse.php +++ b/src/UDDB/Apis/DeleteUDDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("DataNodeDiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -50,11 +51,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -70,11 +70,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -90,11 +89,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RouterVersion: UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5WFeelFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w;EnjoyAlone(物理机版):专享物理机,节点数让客户可选 * @@ -110,11 +108,10 @@ public function getRouterVersion() * * @param string $routerVersion */ - public function setRouterVersion($routerVersion) + public function setRouterVersion(string $routerVersion) { $this->set("RouterVersion", $routerVersion); } - /** * RouterNodeNum: 其他版本:该参数可不填;专享版:物理机节点个数。一台物理机有2个节点 * @@ -130,11 +127,10 @@ public function getRouterNodeNum() * * @param int $routerNodeNum */ - public function setRouterNodeNum($routerNodeNum) + public function setRouterNodeNum(int $routerNodeNum) { $this->set("RouterNodeNum", $routerNodeNum); } - /** * DataNodeCount: 初始的数据节点个数 取值必须>0. * @@ -150,11 +146,10 @@ public function getDataNodeCount() * * @param int $dataNodeCount */ - public function setDataNodeCount($dataNodeCount) + public function setDataNodeCount(int $dataNodeCount) { $this->set("DataNodeCount", $dataNodeCount); } - /** * DataNodeMemory: 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. * @@ -170,11 +165,10 @@ public function getDataNodeMemory() * * @param string $dataNodeMemory */ - public function setDataNodeMemory($dataNodeMemory) + public function setDataNodeMemory(string $dataNodeMemory) { $this->set("DataNodeMemory", $dataNodeMemory); } - /** * DataNodeDiskSpace: 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. * @@ -190,11 +184,10 @@ public function getDataNodeDiskSpace() * * @param int $dataNodeDiskSpace */ - public function setDataNodeDiskSpace($dataNodeDiskSpace) + public function setDataNodeDiskSpace(int $dataNodeDiskSpace) { $this->set("DataNodeDiskSpace", $dataNodeDiskSpace); } - /** * ChargeType: 付费类型,可选值如下: Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 默认值为: Dynamic * @@ -210,11 +203,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认值1 * @@ -230,11 +222,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * DataNodeSlaveCount: 每个数据节点的只读实例个数, 取值必须>=0. 默认取值为0. * @@ -250,11 +241,10 @@ public function getDataNodeSlaveCount() * * @param int $dataNodeSlaveCount */ - public function setDataNodeSlaveCount($dataNodeSlaveCount) + public function setDataNodeSlaveCount(int $dataNodeSlaveCount) { $this->set("DataNodeSlaveCount", $dataNodeSlaveCount); } - /** * InstanceMode: 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA * @@ -270,11 +260,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * InstanceType: 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD * @@ -290,7 +279,7 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } diff --git a/src/UDDB/Apis/DescribeUDDBInstancePriceResponse.php b/src/UDDB/Apis/DescribeUDDBInstancePriceResponse.php index dddf2d39..2375c6b9 100644 --- a/src/UDDB/Apis/DescribeUDDBInstancePriceResponse.php +++ b/src/UDDB/Apis/DescribeUDDBInstancePriceResponse.php @@ -1,6 +1,7 @@ get("PriceInfo")); + return new PriceDetailInfoModel($this->get("PriceInfo")); } /** * PriceInfo: 价格明细, 参考PriceDetailInfo对象定义 * - * @param PriceDetailInfo $priceInfo + * @param PriceDetailInfoModel $priceInfo */ - public function setPriceInfo(array $priceInfo) + public function setPriceInfo(PriceDetailInfoModel $priceInfo) { $this->set("PriceInfo", $priceInfo->getAll()); } diff --git a/src/UDDB/Apis/DescribeUDDBInstanceRequest.php b/src/UDDB/Apis/DescribeUDDBInstanceRequest.php index 500e944f..3d583a46 100644 --- a/src/UDDB/Apis/DescribeUDDBInstanceRequest.php +++ b/src/UDDB/Apis/DescribeUDDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UDDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -106,7 +104,7 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/DescribeUDDBInstanceResponse.php b/src/UDDB/Apis/DescribeUDDBInstanceResponse.php index 4f464f51..1b543ab6 100644 --- a/src/UDDB/Apis/DescribeUDDBInstanceResponse.php +++ b/src/UDDB/Apis/DescribeUDDBInstanceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new DataSetUDDB($item)); + array_push($result, new DataSetUDDBModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getDataSet() /** * DataSet: UDDB实例信息列表, 参见DataSetUDDB项定义 * - * @param DataSetUDDB[] $dataSet + * @param DataSetUDDBModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceRequest.php b/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceRequest.php index 435a12b1..897cd218 100644 --- a/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceRequest.php +++ b/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("RouterNodeNum"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -68,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -88,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -108,11 +106,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * RouterVersion: UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5WFeelFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w;EnjoyAlone(物理机版):专享物理机,节点数让客户可选 * @@ -128,11 +125,10 @@ public function getRouterVersion() * * @param string $routerVersion */ - public function setRouterVersion($routerVersion) + public function setRouterVersion(string $routerVersion) { $this->set("RouterVersion", $routerVersion); } - /** * RouterNodeNum: 其他版本:该参数可不填;专享版:物理机节点的个数。一台物理机有2个节点 * @@ -148,11 +144,10 @@ public function getRouterNodeNum() * * @param int $routerNodeNum */ - public function setRouterNodeNum($routerNodeNum) + public function setRouterNodeNum(int $routerNodeNum) { $this->set("RouterNodeNum", $routerNodeNum); } - /** * DataNodeCount: 新的数据节点个数 取值必须>0. * @@ -168,11 +163,10 @@ public function getDataNodeCount() * * @param int $dataNodeCount */ - public function setDataNodeCount($dataNodeCount) + public function setDataNodeCount(int $dataNodeCount) { $this->set("DataNodeCount", $dataNodeCount); } - /** * DataNodeMemory: 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. * @@ -188,11 +182,10 @@ public function getDataNodeMemory() * * @param int $dataNodeMemory */ - public function setDataNodeMemory($dataNodeMemory) + public function setDataNodeMemory(int $dataNodeMemory) { $this->set("DataNodeMemory", $dataNodeMemory); } - /** * DataNodeDiskSpace: 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. * @@ -208,11 +201,10 @@ public function getDataNodeDiskSpace() * * @param int $dataNodeDiskSpace */ - public function setDataNodeDiskSpace($dataNodeDiskSpace) + public function setDataNodeDiskSpace(int $dataNodeDiskSpace) { $this->set("DataNodeDiskSpace", $dataNodeDiskSpace); } - /** * DataNodeSlaveCount: 每个数据节点的只读实例个数, 取值必须>=0. * @@ -228,11 +220,10 @@ public function getDataNodeSlaveCount() * * @param int $dataNodeSlaveCount */ - public function setDataNodeSlaveCount($dataNodeSlaveCount) + public function setDataNodeSlaveCount(int $dataNodeSlaveCount) { $this->set("DataNodeSlaveCount", $dataNodeSlaveCount); } - /** * InstanceMode: 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA * @@ -248,11 +239,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * InstanceType: 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD * @@ -268,7 +258,7 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } diff --git a/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceResponse.php b/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceResponse.php index 4a7823a2..c4384f2a 100644 --- a/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceResponse.php +++ b/src/UDDB/Apis/DescribeUDDBInstanceUpgradePriceResponse.php @@ -1,6 +1,7 @@ get("PriceInfo")); + return new PriceInfoModel($this->get("PriceInfo")); } /** * PriceInfo: 价格明细, 参考PriceInfo对象定义 * - * @param PriceInfo $priceInfo + * @param PriceInfoModel $priceInfo */ - public function setPriceInfo(array $priceInfo) + public function setPriceInfo(PriceInfoModel $priceInfo) { $this->set("PriceInfo", $priceInfo->getAll()); } diff --git a/src/UDDB/Apis/RestartUDDBInstanceRequest.php b/src/UDDB/Apis/RestartUDDBInstanceRequest.php index b8b83608..33bb1999 100644 --- a/src/UDDB/Apis/RestartUDDBInstanceRequest.php +++ b/src/UDDB/Apis/RestartUDDBInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UDDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -106,7 +104,7 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/RestartUDDBInstanceResponse.php b/src/UDDB/Apis/RestartUDDBInstanceResponse.php index 68037d6f..c842d374 100644 --- a/src/UDDB/Apis/RestartUDDBInstanceResponse.php +++ b/src/UDDB/Apis/RestartUDDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("UDDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -106,7 +104,7 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/StartUDDBInstanceResponse.php b/src/UDDB/Apis/StartUDDBInstanceResponse.php index d94697d9..97fa046f 100644 --- a/src/UDDB/Apis/StartUDDBInstanceResponse.php +++ b/src/UDDB/Apis/StartUDDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("UDDBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -106,7 +104,7 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } diff --git a/src/UDDB/Apis/StopUDDBInstanceResponse.php b/src/UDDB/Apis/StopUDDBInstanceResponse.php index 2bedd220..6ef86f3a 100644 --- a/src/UDDB/Apis/StopUDDBInstanceResponse.php +++ b/src/UDDB/Apis/StopUDDBInstanceResponse.php @@ -1,6 +1,7 @@ markRequired("DataNodeDiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -107,11 +105,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * DataNodeMemory: 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值 * @@ -127,11 +124,10 @@ public function getDataNodeMemory() * * @param int $dataNodeMemory */ - public function setDataNodeMemory($dataNodeMemory) + public function setDataNodeMemory(int $dataNodeMemory) { $this->set("DataNodeMemory", $dataNodeMemory); } - /** * DataNodeDiskSpace: 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. * @@ -147,11 +143,10 @@ public function getDataNodeDiskSpace() * * @param int $dataNodeDiskSpace */ - public function setDataNodeDiskSpace($dataNodeDiskSpace) + public function setDataNodeDiskSpace(int $dataNodeDiskSpace) { $this->set("DataNodeDiskSpace", $dataNodeDiskSpace); } - /** * CouponId: 使用的代金券id * @@ -167,7 +162,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDDB/Apis/UpgradeUDDBDataNodeResponse.php b/src/UDDB/Apis/UpgradeUDDBDataNodeResponse.php index 423edd3a..f83ac4e9 100644 --- a/src/UDDB/Apis/UpgradeUDDBDataNodeResponse.php +++ b/src/UDDB/Apis/UpgradeUDDBDataNodeResponse.php @@ -1,6 +1,7 @@ markRequired("RouterNodeNum"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDDBId: UDDB实例ID * @@ -107,11 +105,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * RouterVersion: UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 * @@ -127,11 +124,10 @@ public function getRouterVersion() * * @param string $routerVersion */ - public function setRouterVersion($routerVersion) + public function setRouterVersion(string $routerVersion) { $this->set("RouterVersion", $routerVersion); } - /** * RouterNodeNum: 其他版本:该参数可不填;专享版:物理机台数 * @@ -147,11 +143,10 @@ public function getRouterNodeNum() * * @param int $routerNodeNum */ - public function setRouterNodeNum($routerNodeNum) + public function setRouterNodeNum(int $routerNodeNum) { $this->set("RouterNodeNum", $routerNodeNum); } - /** * CouponId: 使用的代金券id * @@ -167,7 +162,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDDB/Apis/UpgradeUDDBInstanceResponse.php b/src/UDDB/Apis/UpgradeUDDBInstanceResponse.php index 571ccfb6..1a14a53f 100644 --- a/src/UDDB/Apis/UpgradeUDDBInstanceResponse.php +++ b/src/UDDB/Apis/UpgradeUDDBInstanceResponse.php @@ -1,6 +1,7 @@ set("Id", $id); } - /** * Memory: 数据节点的内存配置, 单位:MB * @@ -57,11 +62,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * DiskSpace: 数据节点的磁盘大小配置. 单位: GB * @@ -77,11 +81,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * SlaveCount: 数据节点的只读实例个数. * @@ -97,11 +100,10 @@ public function getSlaveCount() * * @param int $slaveCount */ - public function setSlaveCount($slaveCount) + public function setSlaveCount(int $slaveCount) { $this->set("SlaveCount", $slaveCount); } - /** * State: 数据分片状态, 状态列表如下: Init: 初始化中 Fail: 安装失败 Starting: 启动中 Running: 系统正常运行中 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 Upgrading: 系统升级中 * @@ -117,15 +119,14 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * SlaveInfos: 只读实例信息列表 * - * @return SlaveInfo[]|null + * @return SlaveInfoModel[]|null */ public function getSlaveInfos() { @@ -135,7 +136,7 @@ public function getSlaveInfos() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SlaveInfo($item)); + array_push($result, new SlaveInfoModel($item)); } return $result; } @@ -143,7 +144,7 @@ public function getSlaveInfos() /** * SlaveInfos: 只读实例信息列表 * - * @param SlaveInfo[] $slaveInfos + * @param SlaveInfoModel[] $slaveInfos */ public function setSlaveInfos(array $slaveInfos) { @@ -153,7 +154,6 @@ public function setSlaveInfos(array $slaveInfos) } return $result; } - /** * LastTransTaskId: 最近一次数据迁移任务id * @@ -169,11 +169,10 @@ public function getLastTransTaskId() * * @param string $lastTransTaskId */ - public function setLastTransTaskId($lastTransTaskId) + public function setLastTransTaskId(string $lastTransTaskId) { $this->set("LastTransTaskId", $lastTransTaskId); } - /** * CreateTime: 节点的创建时间 * @@ -189,7 +188,7 @@ public function getCreateTime() * * @param string $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(string $createTime) { $this->set("CreateTime", $createTime); } diff --git a/src/UDDB/Models/DataSetUDDB.php b/src/UDDB/Models/DataSetUDDB.php index 64dc1401..b88fef20 100644 --- a/src/UDDB/Models/DataSetUDDB.php +++ b/src/UDDB/Models/DataSetUDDB.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * UDDBId: UDDB实例ID * @@ -57,11 +62,10 @@ public function getUDDBId() * * @param string $uddbId */ - public function setUDDBId($uddbId) + public function setUDDBId(string $uddbId) { $this->set("UDDBId", $uddbId); } - /** * Name: UDDB实例名称 * @@ -77,11 +81,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * DBTypeId: UDDB的数据库版本 * @@ -97,11 +100,10 @@ public function getDBTypeId() * * @param string $dbTypeId */ - public function setDBTypeId($dbTypeId) + public function setDBTypeId(string $dbTypeId) { $this->set("DBTypeId", $dbTypeId); } - /** * AdminUser: 管理员帐户名,默认root * @@ -117,11 +119,10 @@ public function getAdminUser() * * @param string $adminUser */ - public function setAdminUser($adminUser) + public function setAdminUser(string $adminUser) { $this->set("AdminUser", $adminUser); } - /** * VirtualIP: UDDB实例访问的虚IP * @@ -137,11 +138,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * Port: UDDB实例访问的端口号 * @@ -157,11 +157,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * State: UDDB状态, 状态列表如下: Init: 初始化中 InitFail: 初始化失败 Starting: 启动中 Running: 系统正常运行中 Abnormal: 系统运行中, 有异常, 还能提供服务 Error: 系统运行中, 但不能正常提供服务 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 UpgradingUDDB: 升降级UDDB配置中 UpgradingDataNode: 升降级UDDB节点配置中 ChangingSlaveCount: 改变只读实例数量中 ScalingOutUDDB: 水平扩展中 * @@ -177,11 +176,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: UDDB实例创建时间,采用UTC计时时间戳 * @@ -197,11 +195,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpiredTime: UDDB实例过期时间,采用UTC计时时间戳 * @@ -217,11 +214,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * ChargeType: 付费类型,可选值如下: Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 * @@ -237,11 +233,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * RouterVersion: UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 * @@ -257,11 +252,10 @@ public function getRouterVersion() * * @param string $routerVersion */ - public function setRouterVersion($routerVersion) + public function setRouterVersion(string $routerVersion) { $this->set("RouterVersion", $routerVersion); } - /** * RouterNodeNum: 各版本下的节点个数。体验版: 固定为2节点; 畅享版:固定为4节点(后续可通过管理API调整);专享版:物理机台数 * @@ -277,11 +271,10 @@ public function getRouterNodeNum() * * @param int $routerNodeNum */ - public function setRouterNodeNum($routerNodeNum) + public function setRouterNodeNum(int $routerNodeNum) { $this->set("RouterNodeNum", $routerNodeNum); } - /** * RefQps: 参考QPS。 免费版: 15000; 畅享版: 30000 - 100000 (根据节点数而定); 专享版: 节点数 * 10w qps * @@ -297,11 +290,10 @@ public function getRefQps() * * @param int $refQps */ - public function setRefQps($refQps) + public function setRefQps(int $refQps) { $this->set("RefQps", $refQps); } - /** * DataNodeCount: 数据节点个数 * @@ -317,11 +309,10 @@ public function getDataNodeCount() * * @param int $dataNodeCount */ - public function setDataNodeCount($dataNodeCount) + public function setDataNodeCount(int $dataNodeCount) { $this->set("DataNodeCount", $dataNodeCount); } - /** * DataNodeMemory: 数据节点的内存配置, 单位:MB * @@ -337,11 +328,10 @@ public function getDataNodeMemory() * * @param int $dataNodeMemory */ - public function setDataNodeMemory($dataNodeMemory) + public function setDataNodeMemory(int $dataNodeMemory) { $this->set("DataNodeMemory", $dataNodeMemory); } - /** * DataNodeDiskSpace: 数据节点的磁盘大小配置. 单位: GB * @@ -357,11 +347,10 @@ public function getDataNodeDiskSpace() * * @param int $dataNodeDiskSpace */ - public function setDataNodeDiskSpace($dataNodeDiskSpace) + public function setDataNodeDiskSpace(int $dataNodeDiskSpace) { $this->set("DataNodeDiskSpace", $dataNodeDiskSpace); } - /** * DataNodeSlaveCount: 每个数据节点的只读实例个数. * @@ -377,15 +366,14 @@ public function getDataNodeSlaveCount() * * @param int $dataNodeSlaveCount */ - public function setDataNodeSlaveCount($dataNodeSlaveCount) + public function setDataNodeSlaveCount(int $dataNodeSlaveCount) { $this->set("DataNodeSlaveCount", $dataNodeSlaveCount); } - /** * DataNodeList: UDDB实例的数据节点的信息列表 * - * @return DataNodeInfo[]|null + * @return DataNodeInfoModel[]|null */ public function getDataNodeList() { @@ -395,7 +383,7 @@ public function getDataNodeList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new DataNodeInfo($item)); + array_push($result, new DataNodeInfoModel($item)); } return $result; } @@ -403,7 +391,7 @@ public function getDataNodeList() /** * DataNodeList: UDDB实例的数据节点的信息列表 * - * @param DataNodeInfo[] $dataNodeList + * @param DataNodeInfoModel[] $dataNodeList */ public function setDataNodeList(array $dataNodeList) { @@ -413,7 +401,6 @@ public function setDataNodeList(array $dataNodeList) } return $result; } - /** * InstanceMode: 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA * @@ -429,11 +416,10 @@ public function getInstanceMode() * * @param string $instanceMode */ - public function setInstanceMode($instanceMode) + public function setInstanceMode(string $instanceMode) { $this->set("InstanceMode", $instanceMode); } - /** * InstanceType: 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD * @@ -449,7 +435,7 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } diff --git a/src/UDDB/Models/PriceDetailInfo.php b/src/UDDB/Models/PriceDetailInfo.php index 225033bb..82ffa111 100644 --- a/src/UDDB/Models/PriceDetailInfo.php +++ b/src/UDDB/Models/PriceDetailInfo.php @@ -1,6 +1,7 @@ set("MiddlewarePrice", $middlewarePrice); } - /** * DataNodePrice: 存储节点费用 * @@ -57,11 +59,10 @@ public function getDataNodePrice() * * @param float $dataNodePrice */ - public function setDataNodePrice($dataNodePrice) + public function setDataNodePrice(float $dataNodePrice) { $this->set("DataNodePrice", $dataNodePrice); } - /** * DataNodeSlavePrice: 只读实例费用 * @@ -77,7 +78,7 @@ public function getDataNodeSlavePrice() * * @param float $dataNodeSlavePrice */ - public function setDataNodeSlavePrice($dataNodeSlavePrice) + public function setDataNodeSlavePrice(float $dataNodeSlavePrice) { $this->set("DataNodeSlavePrice", $dataNodeSlavePrice); } diff --git a/src/UDDB/Models/PriceInfo.php b/src/UDDB/Models/PriceInfo.php index 75ad8276..927d964d 100644 --- a/src/UDDB/Models/PriceInfo.php +++ b/src/UDDB/Models/PriceInfo.php @@ -1,6 +1,7 @@ set("MiddlewarePrice", $middlewarePrice); } - /** * DataNodePrice: 存储节点费用 * @@ -57,11 +59,10 @@ public function getDataNodePrice() * * @param float $dataNodePrice */ - public function setDataNodePrice($dataNodePrice) + public function setDataNodePrice(float $dataNodePrice) { $this->set("DataNodePrice", $dataNodePrice); } - /** * DataNodeSlavePrice: 只读实例费用 * @@ -77,7 +78,7 @@ public function getDataNodeSlavePrice() * * @param float $dataNodeSlavePrice */ - public function setDataNodeSlavePrice($dataNodeSlavePrice) + public function setDataNodeSlavePrice(float $dataNodeSlavePrice) { $this->set("DataNodeSlavePrice", $dataNodeSlavePrice); } diff --git a/src/UDDB/Models/SlaveInfo.php b/src/UDDB/Models/SlaveInfo.php index e201104c..5f4ce793 100644 --- a/src/UDDB/Models/SlaveInfo.php +++ b/src/UDDB/Models/SlaveInfo.php @@ -1,6 +1,7 @@ set("Id", $id); } - /** * DataNodeId: 对应数据节点的ID * @@ -57,11 +62,10 @@ public function getDataNodeId() * * @param string $dataNodeId */ - public function setDataNodeId($dataNodeId) + public function setDataNodeId(string $dataNodeId) { $this->set("DataNodeId", $dataNodeId); } - /** * State: 只读实例状态, 状态列表如下: Init: 初始化中 Fail: 安装失败 Starting: 启动中 Running: 系统正常运行中 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 Upgrading: 系统升级中 * @@ -77,7 +81,7 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } diff --git a/src/UDDB/UDDBClient.php b/src/UDDB/UDDBClient.php index 7a69a311..bc3bfcd1 100644 --- a/src/UDDB/UDDBClient.php +++ b/src/UDDB/UDDBClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例Id - * "NewName" => (string) 名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ChangeUDDBInstanceNameResponse * @throws UCloudException */ public function changeUDDBInstanceName(ChangeUDDBInstanceNameRequest $request = null) @@ -77,34 +101,13 @@ public function changeUDDBInstanceName(ChangeUDDBInstanceNameRequest $request = $resp = $this->invoke($request); return new ChangeUDDBInstanceNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ChangeUDDBSlaveCount - 改变分布式数据库数据节点的只读实例个数 -每一个UDDB的数据节点负责处理所有的写入请求。与此同时,每一个数据节点可以配置若干个该节点的只读实例。当主节点的数据写入完毕后,只读实例把这次的写入操作进行更新,从而和数据节点保持一致。 -只读实例可以使得数据由多份复制,在数据节点和只读实例之间,可以做请求的读写分离, 也就是说, 主节点写入数据之后, 数据的读操作可以由数据只读实例进行分担, 这样减少主节点的压力, 增加性能 -当改变了数据节点的只读实例个数之后,对于现有的和以后的每一个数据节点都采用这个配置。如果UDDB实例有现有的数据节点, 那么它会根据新配置的参数,自动创建或删除数据节点的只读实例 -如下状态的UDDB实例可以进行这个操作: -Running: 系统正常运行中 -当请求返回成功之后,UDDB实例的状态变成"ChangingSlaveCount"; 如果返回失败, UDDB实例状态保持不变 当UDDB更改数据分区的只读实例个数成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果更改过程中出现异常, 状态变成"Abnormal"(异常运行中)或者"Error"(运行错误) - * - * See also: https://docs.ucloud.cn/api/uddb-api/change_uddb_slave_count + * ChangeUDDBSlaveCount - 改变分布式数据库数据节点的只读实例个数每一个UDDB的数据节点负责处理所有的写入请求。与此同时,每一个数据节点可以配置若干个该节点的只读实例。当主节点的数据写入完毕后,只读实例把这次的写入操作进行更新,从而和数据节点保持一致。只读实例可以使得数据由多份复制,在数据节点和只读实例之间,可以做请求的读写分离, 也就是说, 主节点写入数据之后, 数据的读操作可以由数据只读实例进行分担, 这样减少主节点的压力, 增加性能当改变了数据节点的只读实例个数之后,对于现有的和以后的每一个数据节点都采用这个配置。如果UDDB实例有现有的数据节点, 那么它会根据新配置的参数,自动创建或删除数据节点的只读实例如下状态的UDDB实例可以进行这个操作:Running: 系统正常运行中当请求返回成功之后,UDDB实例的状态变成"ChangingSlaveCount"; 如果返回失败, UDDB实例状态保持不变 当UDDB更改数据分区的只读实例个数成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果更改过程中出现异常, 状态变成"Abnormal"(异常运行中)或者"Error"(运行错误) * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB资源id - * "SlaveCount" => (string) 每个数据节点的只读实例个数, 取值必须>=0 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ChangeUDDBSlaveCountResponse * @throws UCloudException */ public function changeUDDBSlaveCount(ChangeUDDBSlaveCountRequest $request = null) @@ -112,45 +115,13 @@ public function changeUDDBSlaveCount(ChangeUDDBSlaveCountRequest $request = null $resp = $this->invoke($request); return new ChangeUDDBSlaveCountResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDDBInstance - 创建创建分布式数据库UDDB实例, 简称UDDB实例。 * - * See also: https://docs.ucloud.cn/api/uddb-api/create_uddb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "DBTypeId" => (string) UDDB的数据库版本,支持版本如下:mysql-5.6 mysql-5.7. 如果不填,则默认为mysql-5.6 - * "Name" => (string) 实例名称,至少6位 - * "AdminPassword" => (string) 管理员密码, 密码需要使用base64加密 - * "RouterVersion" => (string) UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 - * "RouterNodeNum" => (integer) 其他版本:该参数可不填;专享版:物理机台数 - * "DataNodeCount" => (integer) 初始的数据节点个数 取值必须>0. - * "DataNodeMemory" => (integer) 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. - * "DataNodeDiskSpace" => (integer) 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. - * "InstanceMode" => (string) 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA - * "InstanceType" => (string) 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD - * "ChargeType" => (string) 付费类型,可选值如下:Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 默认值为: Dynamic - * "Quantity" => (integer) 购买时长,默认值1 - * "AdminUser" => (string) 管理员帐户名,默认root - * "Port" => (integer) 端口号,mysql默认端口为3306 - * "DataNodeSlaveCount" => (integer) 每个数据节点的只读实例个数, 取值必须>=0. 默认取值为0. - * "VPCId" => (string) VPC的ID - * "SubnetId" => (string) 子网ID - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDDBId" => (string) UDDB实例ID - * ] - * - * @return CreateUDDBInstanceResponse * @throws UCloudException */ public function createUDDBInstance(CreateUDDBInstanceRequest $request = null) @@ -158,31 +129,13 @@ public function createUDDBInstance(CreateUDDBInstanceRequest $request = null) $resp = $this->invoke($request); return new CreateUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DeleteUDDBInstance - 删除UDDB实例。 -如下状态的UDDB实例可以进行这个操作: -InitFail: 初始化失败 -Shutoff: 已关闭 -当请求返回成功之后,UDDB实例就已经被删除, 列表上看不到对应的UDDB实例 + * DeleteUDDBInstance - 删除UDDB实例。如下状态的UDDB实例可以进行这个操作:InitFail: 初始化失败Shutoff: 已关闭当请求返回成功之后,UDDB实例就已经被删除, 列表上看不到对应的UDDB实例 * - * See also: https://docs.ucloud.cn/api/uddb-api/delete_uddb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDDBInstanceResponse * @throws UCloudException */ public function deleteUDDBInstance(DeleteUDDBInstanceRequest $request = null) @@ -190,69 +143,13 @@ public function deleteUDDBInstance(DeleteUDDBInstanceRequest $request = null) $resp = $this->invoke($request); return new DeleteUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDDBInstance - 获取分布式数据库UDDB的详细信息 * - * See also: https://docs.ucloud.cn/api/uddb-api/describe_uddb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) UDDB实例信息列表, 参见DataSetUDDB项定义[ - * [ - * "Zone" => (string) UDDB实例对应的可用区 - * "UDDBId" => (string) UDDB实例ID - * "Name" => (string) UDDB实例名称 - * "DBTypeId" => (string) UDDB的数据库版本 - * "AdminUser" => (string) 管理员帐户名,默认root - * "VirtualIP" => (string) UDDB实例访问的虚IP - * "Port" => (integer) UDDB实例访问的端口号 - * "State" => (string) UDDB状态, 状态列表如下: Init: 初始化中 InitFail: 初始化失败 Starting: 启动中 Running: 系统正常运行中 Abnormal: 系统运行中, 有异常, 还能提供服务 Error: 系统运行中, 但不能正常提供服务 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 UpgradingUDDB: 升降级UDDB配置中 UpgradingDataNode: 升降级UDDB节点配置中 ChangingSlaveCount: 改变只读实例数量中 ScalingOutUDDB: 水平扩展中 - * "CreateTime" => (integer) UDDB实例创建时间,采用UTC计时时间戳 - * "ExpiredTime" => (integer) UDDB实例过期时间,采用UTC计时时间戳 - * "ChargeType" => (string) 付费类型,可选值如下: Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 - * "RouterVersion" => (string) UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 - * "RouterNodeNum" => (integer) 各版本下的节点个数。体验版: 固定为2节点; 畅享版:固定为4节点(后续可通过管理API调整);专享版:物理机台数 - * "RefQps" => (integer) 参考QPS。 免费版: 15000; 畅享版: 30000 - 100000 (根据节点数而定); 专享版: 节点数 * 10w qps - * "DataNodeCount" => (integer) 数据节点个数 - * "DataNodeMemory" => (integer) 数据节点的内存配置, 单位:MB - * "DataNodeDiskSpace" => (integer) 数据节点的磁盘大小配置. 单位: GB - * "DataNodeSlaveCount" => (integer) 每个数据节点的只读实例个数. - * "DataNodeList" => (array) UDDB实例的数据节点的信息列表[ - * [ - * "Id" => (string) 数据节点ID - * "Memory" => (integer) 数据节点的内存配置, 单位:MB - * "DiskSpace" => (integer) 数据节点的磁盘大小配置. 单位: GB - * "SlaveCount" => (integer) 数据节点的只读实例个数. - * "State" => (string) 数据分片状态, 状态列表如下: Init: 初始化中 Fail: 安装失败 Starting: 启动中 Running: 系统正常运行中 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 Upgrading: 系统升级中 - * "SlaveInfos" => (array) 只读实例信息列表[ - * [ - * "Id" => (string) 只读实例ID - * "DataNodeId" => (string) 对应数据节点的ID - * "State" => (string) 只读实例状态, 状态列表如下: Init: 初始化中 Fail: 安装失败 Starting: 启动中 Running: 系统正常运行中 Shutdown: 关闭中 Shutoff: 已关闭 Deleted: 已删除 Upgrading: 系统升级中 - * ] - * ] - * "LastTransTaskId" => (string) 最近一次数据迁移任务id - * "CreateTime" => (string) 节点的创建时间 - * ] - * ] - * "InstanceMode" => (string) 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA - * "InstanceType" => (string) 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD - * ] - * ] - * ] - * - * @return DescribeUDDBInstanceResponse * @throws UCloudException */ public function describeUDDBInstance(DescribeUDDBInstanceRequest $request = null) @@ -260,41 +157,13 @@ public function describeUDDBInstance(DescribeUDDBInstanceRequest $request = null $resp = $this->invoke($request); return new DescribeUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDDBInstancePrice - 获取分布式数据库UDDB价格 * - * See also: https://docs.ucloud.cn/api/uddb-api/describe_uddb_instance_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RouterVersion" => (string) UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5WFeelFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w;EnjoyAlone(物理机版):专享物理机,节点数让客户可选 - * "RouterNodeNum" => (integer) 其他版本:该参数可不填;专享版:物理机节点个数。一台物理机有2个节点 - * "DataNodeCount" => (integer) 初始的数据节点个数 取值必须>0. - * "DataNodeMemory" => (string) 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. - * "DataNodeDiskSpace" => (integer) 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. - * "ChargeType" => (string) 付费类型,可选值如下: Year: 按年付费 Month: 按月付费 Dynamic: 按需付费(单位: 小时) Trial: 免费试用 默认值为: Dynamic - * "Quantity" => (integer) 购买时长,默认值1 - * "DataNodeSlaveCount" => (integer) 每个数据节点的只读实例个数, 取值必须>=0. 默认取值为0. - * "InstanceMode" => (string) 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA - * "InstanceType" => (string) 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceInfo" => (object) 价格明细, 参考PriceDetailInfo对象定义[ - * "MiddlewarePrice" => (number) 中间件路由节点费用 - * "DataNodePrice" => (number) 存储节点费用 - * "DataNodeSlavePrice" => (number) 只读实例费用 - * ] - * ] - * - * @return DescribeUDDBInstancePriceResponse * @throws UCloudException */ public function describeUDDBInstancePrice(DescribeUDDBInstancePriceRequest $request = null) @@ -302,40 +171,13 @@ public function describeUDDBInstancePrice(DescribeUDDBInstancePriceRequest $requ $resp = $this->invoke($request); return new DescribeUDDBInstancePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDDBInstanceUpgradePrice - 升级UDDB时,获取升级后的价格 * - * See also: https://docs.ucloud.cn/api/uddb-api/describe_uddb_instance_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * "RouterVersion" => (string) UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5WFeelFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w;EnjoyAlone(物理机版):专享物理机,节点数让客户可选 - * "RouterNodeNum" => (integer) 其他版本:该参数可不填;专享版:物理机节点的个数。一台物理机有2个节点 - * "DataNodeCount" => (integer) 新的数据节点个数 取值必须>0. - * "DataNodeMemory" => (integer) 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值. - * "DataNodeDiskSpace" => (integer) 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. - * "DataNodeSlaveCount" => (integer) 每个数据节点的只读实例个数, 取值必须>=0. - * "InstanceMode" => (string) 存储节点的高可用模式, 分为高可用UDB(HA)和普通UDB(Normal),如果不填, 则默认为HA - * "InstanceType" => (string) 存储节点和只读实例的磁盘类型。分为:SSD磁盘(SATA_SSD)或普通磁盘(Normal)。 如果不填,则默认为SATA_SSD - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceInfo" => (object) 价格明细, 参考PriceInfo对象定义[ - * "MiddlewarePrice" => (number) 中间件路由节点费用 - * "DataNodePrice" => (number) 存储节点费用 - * "DataNodeSlavePrice" => (number) 只读实例费用 - * ] - * ] - * - * @return DescribeUDDBInstanceUpgradePriceResponse * @throws UCloudException */ public function describeUDDBInstanceUpgradePrice(DescribeUDDBInstanceUpgradePriceRequest $request = null) @@ -343,33 +185,13 @@ public function describeUDDBInstanceUpgradePrice(DescribeUDDBInstanceUpgradePric $resp = $this->invoke($request); return new DescribeUDDBInstanceUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * RestartUDDBInstance - 重启UDDB实例,开始提供服务。 - -如下状态的UDDB实例可以进行这个操作: - -Running: 正常运行中 -Abnormal: 异常运行中 -当请求返回成功之后,UDDB实例的状态变成"Starting"(启动中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在重启过程中, 当UDDB实例启动成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果启动过程中出现异常, 状态变成"Abnormal"(异常运行中), 或者"Shutoff"(已关闭 - * - * See also: https://docs.ucloud.cn/api/uddb-api/restart_uddb_instance - * - * Arguments: + * RestartUDDBInstance - 重启UDDB实例,开始提供服务。如下状态的UDDB实例可以进行这个操作:Running: 正常运行中Abnormal: 异常运行中当请求返回成功之后,UDDB实例的状态变成"Starting"(启动中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在重启过程中, 当UDDB实例启动成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果启动过程中出现异常, 状态变成"Abnormal"(异常运行中), 或者"Shutoff"(已关闭 * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartUDDBInstanceResponse * @throws UCloudException */ public function restartUDDBInstance(RestartUDDBInstanceRequest $request = null) @@ -377,32 +199,13 @@ public function restartUDDBInstance(RestartUDDBInstanceRequest $request = null) $resp = $this->invoke($request); return new RestartUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * StartUDDBInstance - 启动UDDB实例,开始提供服务。 - -如下状态的UDDB实例可以进行这个操作: - -Shutoff: 已关闭 -当请求返回成功之后,UDDB实例的状态变成"Starting"(启动中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在启动过程中, 当UDDB实例启动成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果启动过程中出现异常, 状态变成"Abnormal"(异常运行中), 或者"Shutoff"(已关闭) - * - * See also: https://docs.ucloud.cn/api/uddb-api/start_uddb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * StartUDDBInstance - 启动UDDB实例,开始提供服务。如下状态的UDDB实例可以进行这个操作:Shutoff: 已关闭当请求返回成功之后,UDDB实例的状态变成"Starting"(启动中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在启动过程中, 当UDDB实例启动成功之后, UDDB实例的状态变成"Running"(正常运行中); 如果启动过程中出现异常, 状态变成"Abnormal"(异常运行中), 或者"Shutoff"(已关闭) * - * @return StartUDDBInstanceResponse * @throws UCloudException */ public function startUDDBInstance(StartUDDBInstanceRequest $request = null) @@ -410,33 +213,13 @@ public function startUDDBInstance(StartUDDBInstanceRequest $request = null) $resp = $this->invoke($request); return new StartUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * StopUDDBInstance - 关闭UDDB实例,停止提供服务。 - -如下状态的UDDB实例可以进行这个操作: - -Running: 正常运行中 -Abnormal: 异常运行中 -当请求返回成功之后,UDDB实例的状态变成"Shutdown"(关闭中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在关闭过程中, 当UDDB实例关闭成功之后, UDDB实例的状态变成"Shutoff"(已关闭); 如果关闭过程中出现异常, 根据UDDB实例的情况, 状态变成"Abnormal"(异常运行中), 或者"Running"(正常运行中) - * - * See also: https://docs.ucloud.cn/api/uddb-api/stop_uddb_instance - * - * Arguments: + * StopUDDBInstance - 关闭UDDB实例,停止提供服务。如下状态的UDDB实例可以进行这个操作:Running: 正常运行中Abnormal: 异常运行中当请求返回成功之后,UDDB实例的状态变成"Shutdown"(关闭中); 如果返回失败, UDDB实例状态保持不变 UDDB实例在关闭过程中, 当UDDB实例关闭成功之后, UDDB实例的状态变成"Shutoff"(已关闭); 如果关闭过程中出现异常, 根据UDDB实例的情况, 状态变成"Abnormal"(异常运行中), 或者"Running"(正常运行中) * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return StopUDDBInstanceResponse * @throws UCloudException */ public function stopUDDBInstance(StopUDDBInstanceRequest $request = null) @@ -444,39 +227,13 @@ public function stopUDDBInstance(StopUDDBInstanceRequest $request = null) $resp = $this->invoke($request); return new StopUDDBInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * UpgradeUDDBDataNode - 升降级分布式数据库数据节点的配置, 提高/降低数据节点的数据容量和内存 - -所有数据节点以及其所挂载的只读实例的配置都受到影响 - -升降级数据节点的配置之后之后, 会按照数据节点新的磁盘和内存大小重新计费 - -如下状态的数据节点实例可以进行这个操作: - -Shutoff: 已关闭 -当请求返回成功之后,UDDB实例的状态变成"UpgradingDataNode",相关数据节点的状态变成"Upgrading"; 如果返回失败, UDDB实例状态保持不变 当UDDB实例升级结束之后, UDDB实例的状态变成"Shutoff" - * - * See also: https://docs.ucloud.cn/api/uddb-api/upgrade_uddb_data_node - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * "DataNodeMemory" => (integer) 新的数据节点的内存配置, 单位:MB 具体数值参考UDB的内存取值 - * "DataNodeDiskSpace" => (integer) 新的数据节点的磁盘大小配置. 单位: GB 具体数值参考UDB的磁盘大小取值. - * "CouponId" => (string) 使用的代金券id - * ] + * UpgradeUDDBDataNode - 升降级分布式数据库数据节点的配置, 提高/降低数据节点的数据容量和内存所有数据节点以及其所挂载的只读实例的配置都受到影响升降级数据节点的配置之后之后, 会按照数据节点新的磁盘和内存大小重新计费如下状态的数据节点实例可以进行这个操作:Shutoff: 已关闭当请求返回成功之后,UDDB实例的状态变成"UpgradingDataNode",相关数据节点的状态变成"Upgrading"; 如果返回失败, UDDB实例状态保持不变 当UDDB实例升级结束之后, UDDB实例的状态变成"Shutoff" * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpgradeUDDBDataNodeResponse * @throws UCloudException */ public function upgradeUDDBDataNode(UpgradeUDDBDataNodeRequest $request = null) @@ -484,37 +241,13 @@ public function upgradeUDDBDataNode(UpgradeUDDBDataNodeRequest $request = null) $resp = $this->invoke($request); return new UpgradeUDDBDataNodeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * UpgradeUDDBInstance - 升降级分布式数据库中间件的配置, 提高/降低请求处理的并发性 - -修改请求处理节点个数之后, 按照所有请求处理节点的总内存容量和CPU核数重新计费 - -如下状态的UDDB实例可以进行这个操作: - -Running: 系统正常运行中 -当请求返回成功之后,UDDB实例的状态变成"UpgradingUDDB"; 如果返回失败, UDDB实例状态保持不变 当UDDB实例升级成功之后, UDDB实例的状态变成"Running"; 如果更改过程中出现异常, 状态变成"Abnormal", 或者"Error" - * - * See also: https://docs.ucloud.cn/api/uddb-api/upgrade_uddb_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDDBId" => (string) UDDB实例ID - * "RouterVersion" => (string) UDDB路由节点的版本。分为三种: Trival(免费版): 2中间件节点; QPS:1.5W FellFree(标准版): 固定为4中间件节点,后续将根据业务请求量自动扩展,最多扩展到12个节点,QPS为3w - 10w; EnjoyAlone(物理机版):专享物理机,节点数让客户可选 - * "RouterNodeNum" => (integer) 其他版本:该参数可不填;专享版:物理机台数 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * UpgradeUDDBInstance - 升降级分布式数据库中间件的配置, 提高/降低请求处理的并发性修改请求处理节点个数之后, 按照所有请求处理节点的总内存容量和CPU核数重新计费如下状态的UDDB实例可以进行这个操作:Running: 系统正常运行中当请求返回成功之后,UDDB实例的状态变成"UpgradingUDDB"; 如果返回失败, UDDB实例状态保持不变 当UDDB实例升级成功之后, UDDB实例的状态变成"Running"; 如果更改过程中出现异常, 状态变成"Abnormal", 或者"Error" * - * @return UpgradeUDDBInstanceResponse * @throws UCloudException */ public function upgradeUDDBInstance(UpgradeUDDBInstanceRequest $request = null) diff --git a/src/UDPN/Apis/AllocateUDPNRequest.php b/src/UDPN/Apis/AllocateUDPNRequest.php index e29b1df7..ec35cc5d 100644 --- a/src/UDPN/Apis/AllocateUDPNRequest.php +++ b/src/UDPN/Apis/AllocateUDPNRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Peer1: 专线可用区1,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-ca, 华盛顿:us-ws, 东京:jpn-tky * @@ -85,11 +84,10 @@ public function getPeer1() * * @param string $peer1 */ - public function setPeer1($peer1) + public function setPeer1(string $peer1) { $this->set("Peer1", $peer1); } - /** * Peer2: 专线可用区2,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-ca, 华盛顿:us-ws, 东京:jpn-tky * @@ -105,11 +103,10 @@ public function getPeer2() * * @param string $peer2 */ - public function setPeer2($peer2) + public function setPeer2(string $peer2) { $this->set("Peer2", $peer2); } - /** * Bandwidth: 带宽 * @@ -125,11 +122,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * ChargeType: 计费类型,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费 * @@ -145,11 +141,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 计费时长,默认 1 * @@ -165,11 +160,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * PayMode: 计费模式. 枚举值:"Traffic", 流量计费模式; 否则 带宽计费模式; * @@ -185,11 +179,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * CouponId: 代金劵 * @@ -205,7 +198,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDPN/Apis/AllocateUDPNResponse.php b/src/UDPN/Apis/AllocateUDPNResponse.php index bd7dec25..9975a78a 100644 --- a/src/UDPN/Apis/AllocateUDPNResponse.php +++ b/src/UDPN/Apis/AllocateUDPNResponse.php @@ -1,6 +1,7 @@ set("UDPNId", $udpnId); } diff --git a/src/UDPN/Apis/DescribeUDPNRequest.php b/src/UDPN/Apis/DescribeUDPNRequest.php index a00c9c9a..a0e6b46e 100644 --- a/src/UDPN/Apis/DescribeUDPNRequest.php +++ b/src/UDPN/Apis/DescribeUDPNRequest.php @@ -1,6 +1,7 @@ "DescribeUDPN"]); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -42,11 +43,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -62,11 +62,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDPNId: 申请到的 UDPN 资源 ID。若为空,则查询该用户在机房所有的专线信息。非默认项目资源,需填写ProjectId * @@ -82,11 +81,10 @@ public function getUDPNId() * * @param string $udpnId */ - public function setUDPNId($udpnId) + public function setUDPNId(string $udpnId) { $this->set("UDPNId", $udpnId); } - /** * Offset: 列表起始位置偏移量,默认为 0 * @@ -102,11 +100,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为 20 * @@ -122,7 +119,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UDPN/Apis/DescribeUDPNResponse.php b/src/UDPN/Apis/DescribeUDPNResponse.php index 7665bb6c..3b136203 100644 --- a/src/UDPN/Apis/DescribeUDPNResponse.php +++ b/src/UDPN/Apis/DescribeUDPNResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: UDPN详情 * - * @return UDPNData[]|null + * @return UDPNDataModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDPNData($item)); + array_push($result, new UDPNDataModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: UDPN详情 * - * @param UDPNData[] $dataSet + * @param UDPNDataModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDPN/Apis/GetUDPNLineListRequest.php b/src/UDPN/Apis/GetUDPNLineListRequest.php index ac63700a..cc3ffdc0 100644 --- a/src/UDPN/Apis/GetUDPNLineListRequest.php +++ b/src/UDPN/Apis/GetUDPNLineListRequest.php @@ -1,6 +1,7 @@ "GetUDPNLineList"]); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -42,11 +43,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: * @@ -62,7 +62,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UDPN/Apis/GetUDPNLineListResponse.php b/src/UDPN/Apis/GetUDPNLineListResponse.php index 31a8dd00..4b684d58 100644 --- a/src/UDPN/Apis/GetUDPNLineListResponse.php +++ b/src/UDPN/Apis/GetUDPNLineListResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 当前支持的专线线路详细信息,详见UDPNLineSet * - * @return UDPNLineSet[]|null + * @return UDPNLineSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDPNLineSet($item)); + array_push($result, new UDPNLineSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 当前支持的专线线路详细信息,详见UDPNLineSet * - * @param UDPNLineSet[] $dataSet + * @param UDPNLineSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDPN/Apis/GetUDPNPriceRequest.php b/src/UDPN/Apis/GetUDPNPriceRequest.php index 1f644076..edef22d1 100644 --- a/src/UDPN/Apis/GetUDPNPriceRequest.php +++ b/src/UDPN/Apis/GetUDPNPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Peer1: 专线可用区1,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-la, 华盛顿:us-ws, 东京:jpn-tky * @@ -65,11 +65,10 @@ public function getPeer1() * * @param string $peer1 */ - public function setPeer1($peer1) + public function setPeer1(string $peer1) { $this->set("Peer1", $peer1); } - /** * Peer2: 专线可用区2,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-la, 华盛顿:us-ws, 东京:jpn-tky * @@ -85,11 +84,10 @@ public function getPeer2() * * @param string $peer2 */ - public function setPeer2($peer2) + public function setPeer2(string $peer2) { $this->set("Peer2", $peer2); } - /** * Bandwidth: 带宽信息 * @@ -105,11 +103,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * ChargeType: 计费类型 * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 * @@ -145,11 +141,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * PayMode: PayMode,枚举值,Bandwidth:带宽;Traffic:流量 默认不填写:带宽 * @@ -165,7 +160,7 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } diff --git a/src/UDPN/Apis/GetUDPNPriceResponse.php b/src/UDPN/Apis/GetUDPNPriceResponse.php index e69b1d97..33f5ed44 100644 --- a/src/UDPN/Apis/GetUDPNPriceResponse.php +++ b/src/UDPN/Apis/GetUDPNPriceResponse.php @@ -1,6 +1,7 @@ set("PurchaseValue", $purchaseValue); } - /** * Price: 专线价格 * @@ -57,7 +57,7 @@ public function getPrice() * * @param float $price */ - public function setPrice($price) + public function setPrice(float $price) { $this->set("Price", $price); } diff --git a/src/UDPN/Apis/GetUDPNUpgradePriceRequest.php b/src/UDPN/Apis/GetUDPNUpgradePriceRequest.php index 277dae15..b12b9eb5 100644 --- a/src/UDPN/Apis/GetUDPNUpgradePriceRequest.php +++ b/src/UDPN/Apis/GetUDPNUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDPNId: 专线带宽资源 Id * @@ -84,11 +83,10 @@ public function getUDPNId() * * @param string $udpnId */ - public function setUDPNId($udpnId) + public function setUDPNId(string $udpnId) { $this->set("UDPNId", $udpnId); } - /** * Bandwidth: 带宽 * @@ -104,7 +102,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UDPN/Apis/GetUDPNUpgradePriceResponse.php b/src/UDPN/Apis/GetUDPNUpgradePriceResponse.php index ca55a29f..8833c37f 100644 --- a/src/UDPN/Apis/GetUDPNUpgradePriceResponse.php +++ b/src/UDPN/Apis/GetUDPNUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UDPN/Apis/ModifyUDPNBandwidthRequest.php b/src/UDPN/Apis/ModifyUDPNBandwidthRequest.php index febd48fb..33754799 100644 --- a/src/UDPN/Apis/ModifyUDPNBandwidthRequest.php +++ b/src/UDPN/Apis/ModifyUDPNBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDPNId: UDPN Id * @@ -64,11 +64,10 @@ public function getUDPNId() * * @param string $udpnId */ - public function setUDPNId($udpnId) + public function setUDPNId(string $udpnId) { $this->set("UDPNId", $udpnId); } - /** * Bandwidth: 调整后专线带宽, 单位为Mbps,取值范围为大于等于2且小于等于1000([2-1000])的整数 * @@ -84,11 +83,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * CouponId: 代金劵 ID * @@ -104,7 +102,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDPN/Apis/ModifyUDPNBandwidthResponse.php b/src/UDPN/Apis/ModifyUDPNBandwidthResponse.php index 33459ade..61ed6ee9 100644 --- a/src/UDPN/Apis/ModifyUDPNBandwidthResponse.php +++ b/src/UDPN/Apis/ModifyUDPNBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("UDPNId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDPNId: UDPN 资源 Id * @@ -83,7 +82,7 @@ public function getUDPNId() * * @param string $udpnId */ - public function setUDPNId($udpnId) + public function setUDPNId(string $udpnId) { $this->set("UDPNId", $udpnId); } diff --git a/src/UDPN/Apis/ReleaseUDPNResponse.php b/src/UDPN/Apis/ReleaseUDPNResponse.php index 3636a94d..3da69502 100644 --- a/src/UDPN/Apis/ReleaseUDPNResponse.php +++ b/src/UDPN/Apis/ReleaseUDPNResponse.php @@ -1,6 +1,7 @@ set("UDPNId", $udpnId); } - /** * Peer1: 可用区域 1 * @@ -57,11 +59,10 @@ public function getPeer1() * * @param string $peer1 */ - public function setPeer1($peer1) + public function setPeer1(string $peer1) { $this->set("Peer1", $peer1); } - /** * Peer2: 可用区域 2 * @@ -77,11 +78,10 @@ public function getPeer2() * * @param string $peer2 */ - public function setPeer2($peer2) + public function setPeer2(string $peer2) { $this->set("Peer2", $peer2); } - /** * ChargeType: 计费类型 * @@ -97,11 +97,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Bandwidth: 带宽 * @@ -117,11 +116,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * CreateTime: unix 时间戳 创建时间 * @@ -137,11 +135,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: unix 时间戳 到期时间 * @@ -157,7 +154,7 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } diff --git a/src/UDPN/Models/UDPNLineSet.php b/src/UDPN/Models/UDPNLineSet.php index c488c677..a717f72b 100644 --- a/src/UDPN/Models/UDPNLineSet.php +++ b/src/UDPN/Models/UDPNLineSet.php @@ -1,6 +1,7 @@ set("LocalRegion", $localRegion); } - /** * RemoteRegion: 支持UDPN的地域之一,北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 华盛顿:us-ws, 洛杉矶:us-la, 东京:jpn-tky * @@ -57,11 +59,10 @@ public function getRemoteRegion() * * @param string $remoteRegion */ - public function setRemoteRegion($remoteRegion) + public function setRemoteRegion(string $remoteRegion) { $this->set("RemoteRegion", $remoteRegion); } - /** * BandwidthUpperLimit: 线路带宽上限,单位 M * @@ -77,7 +78,7 @@ public function getBandwidthUpperLimit() * * @param int $bandwidthUpperLimit */ - public function setBandwidthUpperLimit($bandwidthUpperLimit) + public function setBandwidthUpperLimit(int $bandwidthUpperLimit) { $this->set("BandwidthUpperLimit", $bandwidthUpperLimit); } diff --git a/src/UDPN/UDPNClient.php b/src/UDPN/UDPNClient.php index c5e0812b..766dae15 100644 --- a/src/UDPN/UDPNClient.php +++ b/src/UDPN/UDPNClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Peer1" => (string) 专线可用区1,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-ca, 华盛顿:us-ws, 东京:jpn-tky - * "Peer2" => (string) 专线可用区2,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-ca, 华盛顿:us-ws, 东京:jpn-tky - * "Bandwidth" => (integer) 带宽 - * "ChargeType" => (string) 计费类型,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费 - * "Quantity" => (integer) 计费时长,默认 1 - * "PayMode" => (string) 计费模式. 枚举值:"Traffic", 流量计费模式; 否则 带宽计费模式; - * "CouponId" => (string) 代金劵 - * ] - * - * Outputs: - * - * $outputs = [ - * "UDPNId" => (string) 资源名称 - * ] - * - * @return AllocateUDPNResponse * @throws UCloudException */ public function allocateUDPN(AllocateUDPNRequest $request = null) @@ -72,40 +76,13 @@ public function allocateUDPN(AllocateUDPNRequest $request = null) $resp = $this->invoke($request); return new AllocateUDPNResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDPN - 描述 UDPN * - * See also: https://docs.ucloud.cn/api/udpn-api/describe_udpn - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UDPNId" => (string) 申请到的 UDPN 资源 ID。若为空,则查询该用户在机房所有的专线信息。非默认项目资源,需填写ProjectId - * "Offset" => (integer) 列表起始位置偏移量,默认为 0 - * "Limit" => (integer) 返回数据长度,默认为 20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 查询到的总数量 - * "DataSet" => (array) UDPN详情[ - * [ - * "UDPNId" => (string) UDPN 资源短 ID - * "Peer1" => (string) 可用区域 1 - * "Peer2" => (string) 可用区域 2 - * "ChargeType" => (string) 计费类型 - * "Bandwidth" => (integer) 带宽 - * "CreateTime" => (integer) unix 时间戳 创建时间 - * "ExpireTime" => (integer) unix 时间戳 到期时间 - * ] - * ] - * ] - * - * @return DescribeUDPNResponse * @throws UCloudException */ public function describeUDPN(DescribeUDPNRequest $request = null) @@ -113,33 +90,13 @@ public function describeUDPN(DescribeUDPNRequest $request = null) $resp = $this->invoke($request); return new DescribeUDPNResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUDPNLineList - 获取当前支持的专线线路列表 * - * See also: https://docs.ucloud.cn/api/udpn-api/get_udpn_line_list - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) DataSet中的元素个数 - * "DataSet" => (array) 当前支持的专线线路详细信息,详见UDPNLineSet[ - * [ - * "LocalRegion" => (string) 支持UDPN的地域之一,北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 华盛顿:us-ws, 洛杉矶:us-la, 东京:jpn-tky - * "RemoteRegion" => (string) 支持UDPN的地域之一,北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 华盛顿:us-ws, 洛杉矶:us-la, 东京:jpn-tky - * "BandwidthUpperLimit" => (integer) 线路带宽上限,单位 M - * ] - * ] - * ] - * - * @return GetUDPNLineListResponse * @throws UCloudException */ public function getUDPNLineList(GetUDPNLineListRequest $request = null) @@ -147,32 +104,13 @@ public function getUDPNLineList(GetUDPNLineListRequest $request = null) $resp = $this->invoke($request); return new GetUDPNLineListResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUDPNPrice - 获取 UDPN 价格 * - * See also: https://docs.ucloud.cn/api/udpn-api/get_udpn_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Peer1" => (string) 专线可用区1,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-la, 华盛顿:us-ws, 东京:jpn-tky - * "Peer2" => (string) 专线可用区2,支持地域:北京二:cn-bj2, 上海二:cn-sh2, 广东:cn-gd, 亚太: hk, 上海一:cn-sh1, 法兰克福:ge-fra, 新加坡:sg, 洛杉矶:us-la, 华盛顿:us-ws, 东京:jpn-tky - * "Bandwidth" => (integer) 带宽信息 - * "ChargeType" => (string) 计费类型 - * "Quantity" => (integer) 购买时长 - * "PayMode" => (string) PayMode,枚举值,Bandwidth:带宽;Traffic:流量 默认不填写:带宽 - * ] - * - * Outputs: - * - * $outputs = [ - * "PurchaseValue" => (integer) 资源有效期 unix 时间戳 - * "Price" => (number) 专线价格 - * ] - * - * @return GetUDPNPriceResponse * @throws UCloudException */ public function getUDPNPrice(GetUDPNPriceRequest $request = null) @@ -180,28 +118,13 @@ public function getUDPNPrice(GetUDPNPriceRequest $request = null) $resp = $this->invoke($request); return new GetUDPNPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUDPNUpgradePrice - 获取专线升级价格 * - * See also: https://docs.ucloud.cn/api/udpn-api/get_udpn_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDPNId" => (string) 专线带宽资源 Id - * "Bandwidth" => (integer) 带宽 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 升级后的价格 - * ] - * - * @return GetUDPNUpgradePriceResponse * @throws UCloudException */ public function getUDPNUpgradePrice(GetUDPNUpgradePriceRequest $request = null) @@ -209,27 +132,13 @@ public function getUDPNUpgradePrice(GetUDPNUpgradePriceRequest $request = null) $resp = $this->invoke($request); return new GetUDPNUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUDPNBandwidth - 修改带宽值 * - * See also: https://docs.ucloud.cn/api/udpn-api/modify_udpn_bandwidth - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDPNId" => (string) UDPN Id - * "Bandwidth" => (integer) 调整后专线带宽, 单位为Mbps,取值范围为大于等于2且小于等于1000([2-1000])的整数 - * "CouponId" => (string) 代金劵 ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUDPNBandwidthResponse * @throws UCloudException */ public function modifyUDPNBandwidth(ModifyUDPNBandwidthRequest $request = null) @@ -237,26 +146,13 @@ public function modifyUDPNBandwidth(ModifyUDPNBandwidthRequest $request = null) $resp = $this->invoke($request); return new ModifyUDPNBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReleaseUDPN - 释放 UDPN * - * See also: https://docs.ucloud.cn/api/udpn-api/release_udpn - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDPNId" => (string) UDPN 资源 Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReleaseUDPNResponse * @throws UCloudException */ public function releaseUDPN(ReleaseUDPNRequest $request = null) diff --git a/src/UDisk/Apis/AttachUDiskRequest.php b/src/UDisk/Apis/AttachUDiskRequest.php index b34ee26a..fcc1b60b 100644 --- a/src/UDisk/Apis/AttachUDiskRequest.php +++ b/src/UDisk/Apis/AttachUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 需要挂载的UDisk实例ID. * @@ -104,11 +102,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * UHostId: UHost实例ID。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 * @@ -124,11 +121,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * MultiAttach: 是否允许多点挂载(Yes: 允许多点挂载, No: 不允许多点挂载, 不填默认Yes ) * @@ -144,11 +140,10 @@ public function getMultiAttach() * * @param string $multiAttach */ - public function setMultiAttach($multiAttach) + public function setMultiAttach(string $multiAttach) { $this->set("MultiAttach", $multiAttach); } - /** * HostId: Host实例ID * @@ -164,7 +159,7 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } diff --git a/src/UDisk/Apis/AttachUDiskResponse.php b/src/UDisk/Apis/AttachUDiskResponse.php index cc297f64..a669e2df 100644 --- a/src/UDisk/Apis/AttachUDiskResponse.php +++ b/src/UDisk/Apis/AttachUDiskResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } - /** * UDiskId: 挂载的UDisk实例ID * @@ -57,11 +57,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * DeviceName: 挂载的设备名称 * @@ -77,11 +76,10 @@ public function getDeviceName() * * @param string $deviceName */ - public function setDeviceName($deviceName) + public function setDeviceName(string $deviceName) { $this->set("DeviceName", $deviceName); } - /** * HostId: 挂载的Host实例ID * @@ -97,7 +95,7 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } diff --git a/src/UDisk/Apis/CloneUDiskRequest.php b/src/UDisk/Apis/CloneUDiskRequest.php index 0c43f309..a00dee04 100644 --- a/src/UDisk/Apis/CloneUDiskRequest.php +++ b/src/UDisk/Apis/CloneUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("SourceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 实例名称 * @@ -106,11 +104,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * SourceId: 克隆父Disk的Id * @@ -126,11 +123,10 @@ public function getSourceId() * * @param string $sourceId */ - public function setSourceId($sourceId) + public function setSourceId(string $sourceId) { $this->set("SourceId", $sourceId); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -146,11 +142,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -166,11 +161,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * Quantity: 购买时长 默认: 1 * @@ -186,11 +180,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Comment: Disk注释 * @@ -206,11 +199,10 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } - /** * ChargeType: Year , Month, Dynamic,Postpay,Trial 默认: Month * @@ -226,11 +218,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Tag: 业务组 默认:Default * @@ -246,13 +237,12 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @return string|null */ @@ -262,15 +252,14 @@ public function getRdmaClusterId() } /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } - /** * HostId: Host实例ID。克隆出的云盘可直接挂载到该主机上。 * @@ -286,11 +275,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * CouponId: 使用的代金券id * @@ -306,7 +294,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/CloneUDiskResponse.php b/src/UDisk/Apis/CloneUDiskResponse.php index 37159874..478be362 100644 --- a/src/UDisk/Apis/CloneUDiskResponse.php +++ b/src/UDisk/Apis/CloneUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("SourceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 实例名称 * @@ -106,11 +104,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * SourceId: 克隆父Snapshot的Id * @@ -126,11 +123,10 @@ public function getSourceId() * * @param string $sourceId */ - public function setSourceId($sourceId) + public function setSourceId(string $sourceId) { $this->set("SourceId", $sourceId); } - /** * Size: 购买UDisk大小,单位:GB,范围[1~8000]。(UDisk大小设定对本地盘快照有效,对云盘快照无效) * @@ -146,11 +142,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Comment: Disk注释 * @@ -166,11 +161,10 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } - /** * ChargeType: Year , Month, Dynamic,Postpay 默认: Dynamic * @@ -186,11 +180,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -206,11 +199,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -226,11 +218,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -246,11 +237,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * Tag: 业务组 默认:Default * @@ -266,13 +256,12 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @return string|null */ @@ -282,15 +271,14 @@ public function getRdmaClusterId() } /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } - /** * HostId: Host实例ID。克隆出的云盘可直接挂载到该主机上。 * @@ -306,11 +294,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * CouponId: 使用的代金券id * @@ -326,7 +313,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/CloneUDiskSnapshotResponse.php b/src/UDisk/Apis/CloneUDiskSnapshotResponse.php index 5da16f5b..cf43b425 100644 --- a/src/UDisk/Apis/CloneUDiskSnapshotResponse.php +++ b/src/UDisk/Apis/CloneUDiskSnapshotResponse.php @@ -1,6 +1,7 @@ markRequired("SnapshotTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 实例名称 * @@ -107,11 +105,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * UDiskId: 需要克隆的源盘id * @@ -127,11 +124,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * SnapshotTime: 指定从方舟克隆的备份时间点 * @@ -147,11 +143,10 @@ public function getSnapshotTime() * * @param int $snapshotTime */ - public function setSnapshotTime($snapshotTime) + public function setSnapshotTime(int $snapshotTime) { $this->set("SnapshotTime", $snapshotTime); } - /** * Comment: Disk注释 * @@ -167,11 +162,10 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } - /** * ChargeType: Year , Month, Dynamic,Postpay 默认: Dynamic * @@ -187,11 +181,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -207,11 +200,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -227,11 +219,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -247,11 +238,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * Size: 购买UDisk大小,单位:GB,范围[1~8000]。(UDisk大小设定对本地盘备份有效,对云盘备份无效) * @@ -267,11 +257,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Tag: 业务组 默认:Default * @@ -287,13 +276,12 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @return string|null */ @@ -303,15 +291,14 @@ public function getRdmaClusterId() } /** - * RdmaClusterId: 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 + * RdmaClusterId: RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } - /** * HostId: Host实例ID。克隆出的云盘可直接挂载到该主机上。 * @@ -327,11 +314,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * CouponId: 使用的代金券id * @@ -347,7 +333,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/CloneUDiskUDataArkResponse.php b/src/UDisk/Apis/CloneUDiskUDataArkResponse.php index 25de573b..7879a3b2 100644 --- a/src/UDisk/Apis/CloneUDiskUDataArkResponse.php +++ b/src/UDisk/Apis/CloneUDiskUDataArkResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000];高效数据盘:范围[1~32000]。 * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Name: 实例名称 * @@ -126,11 +123,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * UHostId: UHost实例ID。当创建云盘类型为RSSDDataDisk时,根据传入的UHostId,创建与虚机在同一PodId下的云盘。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 * @@ -146,11 +142,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * ChargeType: Year , Month, Dynamic, Postpay, Trial 。 Size小于等于2000时,默认为Dynamic;Size大于2000时,默认为Month。 * @@ -166,11 +161,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -186,11 +180,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -206,11 +199,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -226,11 +218,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * Tag: 业务组 默认:Default * @@ -246,11 +237,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * DiskType: UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),默认值(DataDisk) * @@ -266,11 +256,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * UKmsMode: 是否加密。Yes:加密,No:不加密,默认值(No) * @@ -286,11 +275,10 @@ public function getUKmsMode() * * @param string $uKmsMode */ - public function setUKmsMode($uKmsMode) + public function setUKmsMode(string $uKmsMode) { $this->set("UKmsMode", $uKmsMode); } - /** * CmkId: 加密需要的cmk id,UKmsMode为Yes时,必填 * @@ -306,11 +294,10 @@ public function getCmkId() * * @param string $cmkId */ - public function setCmkId($cmkId) + public function setCmkId(string $cmkId) { $this->set("CmkId", $cmkId); } - /** * MultiAttach: 是否允许多点挂载(Yes: 允许多点挂载, No: 不允许多点挂载, 不填默认Yes ) * @@ -326,11 +313,10 @@ public function getMultiAttach() * * @param string $multiAttach */ - public function setMultiAttach($multiAttach) + public function setMultiAttach(string $multiAttach) { $this->set("MultiAttach", $multiAttach); } - /** * HostId: Host实例ID。当创建云盘类型为RSSDDataDisk时,根据传入的HostId,创建与虚机在同一PodId下的云盘。 * @@ -346,11 +332,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * CouponId: 使用的代金券id * @@ -366,7 +351,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/CreateAttachUDiskResponse.php b/src/UDisk/Apis/CreateAttachUDiskResponse.php index 50b8ba8c..f28d3230 100644 --- a/src/UDisk/Apis/CreateAttachUDiskResponse.php +++ b/src/UDisk/Apis/CreateAttachUDiskResponse.php @@ -1,6 +1,7 @@ set("UDiskId", $uDiskId); } - /** * UHostId: 挂载的UHost实例ID。【即将废弃,建议使用HostId】 * @@ -57,11 +57,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * HostId: 挂载的Host实例ID * @@ -77,11 +76,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * DeviceName: 挂载设备名称 * @@ -97,7 +95,7 @@ public function getDeviceName() * * @param string $deviceName */ - public function setDeviceName($deviceName) + public function setDeviceName(string $deviceName) { $this->set("DeviceName", $deviceName); } diff --git a/src/UDisk/Apis/CreateUDiskRequest.php b/src/UDisk/Apis/CreateUDiskRequest.php index 03a44464..1d087ab3 100644 --- a/src/UDisk/Apis/CreateUDiskRequest.php +++ b/src/UDisk/Apis/CreateUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000];高效数据盘:范围[1~32000]。 * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Name: 实例名称 * @@ -126,11 +123,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * ChargeType: Year , Month, Dynamic, Postpay, Trial 。默认为Dynamic。 * @@ -146,11 +142,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -166,11 +161,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -186,11 +180,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -206,11 +199,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * Tag: 业务组 默认:Default * @@ -226,11 +218,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * DiskType: UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),默认值(DataDisk) * @@ -246,11 +237,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * UKmsMode: 是否加密。Yes:加密,No:不加密,默认值(No) * @@ -266,11 +256,10 @@ public function getUKmsMode() * * @param string $uKmsMode */ - public function setUKmsMode($uKmsMode) + public function setUKmsMode(string $uKmsMode) { $this->set("UKmsMode", $uKmsMode); } - /** * CmkId: 加密需要的cmk id,UKmsMode为Yes时,必填 * @@ -286,11 +275,10 @@ public function getCmkId() * * @param string $cmkId */ - public function setCmkId($cmkId) + public function setCmkId(string $cmkId) { $this->set("CmkId", $cmkId); } - /** * RdmaClusterId: RDMA集群id。DiskType为RSSDDataDisk可填,指定云盘创建到对应的RDMA集群。 * @@ -306,11 +294,10 @@ public function getRdmaClusterId() * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } - /** * CouponId: 使用的代金券id * @@ -326,7 +313,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/CreateUDiskResponse.php b/src/UDisk/Apis/CreateUDiskResponse.php index ab52f696..0f50cd33 100644 --- a/src/UDisk/Apis/CreateUDiskResponse.php +++ b/src/UDisk/Apis/CreateUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 快照的UDisk的Id * @@ -106,11 +104,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * Name: 快照名称 * @@ -126,11 +123,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Quantity: 购买时长 默认: 1 (已废弃) * @@ -146,11 +142,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ChargeType: Year , Month, Dynamic 默认: Dynamic (已废弃) * @@ -166,11 +161,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Comment: 快照描述 * @@ -186,7 +180,7 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } diff --git a/src/UDisk/Apis/CreateUDiskSnapshotResponse.php b/src/UDisk/Apis/CreateUDiskSnapshotResponse.php index 6673bea0..eef6a15b 100644 --- a/src/UDisk/Apis/CreateUDiskSnapshotResponse.php +++ b/src/UDisk/Apis/CreateUDiskSnapshotResponse.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 要删除的UDisk的Id * @@ -105,7 +103,7 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } diff --git a/src/UDisk/Apis/DeleteUDiskResponse.php b/src/UDisk/Apis/DeleteUDiskResponse.php index 5f8a9ffc..71e84171 100644 --- a/src/UDisk/Apis/DeleteUDiskResponse.php +++ b/src/UDisk/Apis/DeleteUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SnapshotId: 快照Id(填写后不能填写UDisk Id) * @@ -104,11 +102,10 @@ public function getSnapshotId() * * @param string $snapshotId */ - public function setSnapshotId($snapshotId) + public function setSnapshotId(string $snapshotId) { $this->set("SnapshotId", $snapshotId); } - /** * UDiskId: UDisk Id,删除该盘所创建出来的所有快照(填写后不能填写SnapshotId) * @@ -124,7 +121,7 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } diff --git a/src/UDisk/Apis/DeleteUDiskSnapshotResponse.php b/src/UDisk/Apis/DeleteUDiskSnapshotResponse.php index be16881f..2f009811 100644 --- a/src/UDisk/Apis/DeleteUDiskSnapshotResponse.php +++ b/src/UDisk/Apis/DeleteUDiskSnapshotResponse.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Limit: 返回数据长度, 默认为20 * @@ -104,11 +102,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 数据偏移量, 默认为0 * @@ -124,7 +121,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UDisk/Apis/DescribeRecycleUDiskResponse.php b/src/UDisk/Apis/DescribeRecycleUDiskResponse.php index 8d898bfb..ae339d53 100644 --- a/src/UDisk/Apis/DescribeRecycleUDiskResponse.php +++ b/src/UDisk/Apis/DescribeRecycleUDiskResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 回收站磁盘列表 * - * @return RecycleUDiskSet[]|null + * @return RecycleUDiskSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new RecycleUDiskSet($item)); + array_push($result, new RecycleUDiskSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 回收站磁盘列表 * - * @param RecycleUDiskSet[] $dataSet + * @param RecycleUDiskSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDisk/Apis/DescribeUDiskPriceRequest.php b/src/UDisk/Apis/DescribeUDiskPriceRequest.php index a82886f5..60f19e10 100644 --- a/src/UDisk/Apis/DescribeUDiskPriceRequest.php +++ b/src/UDisk/Apis/DescribeUDiskPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];普通系统盘:范围[1~8000];SSD系统盘:范围[1~4000];RSSD数据盘:范围[1~32000];RSSD系统盘:范围[1~4000];高效数据盘:范围[1~32000];高效系统盘:范围[1~500]。 * @@ -105,11 +103,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * ChargeType: Year , Month, Dynamic,Postpay,Trial 默认: Month * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买UDisk的时长,默认值为1 * @@ -145,11 +141,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -165,11 +160,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No * @@ -185,11 +179,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * DiskType: UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),SystemDisk(普通系统盘),SSDSystemDisk(SSD系统盘),RSSDSystemDisk(RSSD系统盘),EfficiencySystemDisk(高效系统盘),默认值(DataDisk) * @@ -205,11 +198,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * IsTotalPrice: 是否将快照服务(数据方舟),云硬盘放入一张订单, 是:"Yes",否:"No",默认是"No" * @@ -225,11 +217,10 @@ public function getIsTotalPrice() * * @param string $isTotalPrice */ - public function setIsTotalPrice($isTotalPrice) + public function setIsTotalPrice(string $isTotalPrice) { $this->set("IsTotalPrice", $isTotalPrice); } - /** * MachineType: 云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -245,7 +236,7 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } diff --git a/src/UDisk/Apis/DescribeUDiskPriceResponse.php b/src/UDisk/Apis/DescribeUDiskPriceResponse.php index b3f5341a..a195a36f 100644 --- a/src/UDisk/Apis/DescribeUDiskPriceResponse.php +++ b/src/UDisk/Apis/DescribeUDiskPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDiskPriceDataSet($item)); + array_push($result, new UDiskPriceDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 价格参数列表,具体说明见 UDiskPriceDataSet * - * @param UDiskPriceDataSet[] $dataSet + * @param UDiskPriceDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UDisk/Apis/DescribeUDiskRequest.php b/src/UDisk/Apis/DescribeUDiskRequest.php index 27352fe7..8dcc45bc 100644 --- a/src/UDisk/Apis/DescribeUDiskRequest.php +++ b/src/UDisk/Apis/DescribeUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: UDisk Id(留空返回全部) * @@ -103,11 +101,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * Offset: 数据偏移量, 默认为0 * @@ -123,11 +120,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认为20 * @@ -143,11 +139,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * DiskType: ProtocolVersion字段为1时,需结合IsBoot确定具体磁盘类型:普通数据盘:DiskType:"CLOUD_NORMAL",IsBoot:"False";普通系统盘:DiskType:"CLOUD_NORMAL",IsBoot:"True";SSD数据盘:DiskType:"CLOUD_SSD",IsBoot:"False";SSD系统盘:DiskType:"CLOUD_SSD",IsBoot:"True";RSSD数据盘:DiskType:"CLOUD_RSSD",IsBoot:"False";RSSD系统盘:DiskType:"CLOUD_RSSD",IsBoot:"True";高效数据盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"False";高效系统盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"True";为空拉取所有。ProtocolVersion字段为0或没有该字段时,可设为以下几个值:普通数据盘:DataDisk;普通系统盘:SystemDisk;SSD数据盘:SSDDataDisk;SSD系统盘:SSDSystemDisk;RSSD数据盘:RSSDDataDisk;RSSD系统盘:RSSDSystemDisk:高效数据盘:EfficiencyDataDisk;高效系统盘:EfficiencySystemDisk;为空拉取所有。 * @@ -163,11 +158,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * ProtocolVersion: 请求协议版本,建议升级为1,为1时DiskType与UHost磁盘类型定义一致;默认为0 * @@ -183,11 +177,10 @@ public function getProtocolVersion() * * @param int $protocolVersion */ - public function setProtocolVersion($protocolVersion) + public function setProtocolVersion(int $protocolVersion) { $this->set("ProtocolVersion", $protocolVersion); } - /** * IsBoot: ProtocolVersion字段为1且DiskType不为空时,必须设置,设置规则请参照DiskType;ProtocolVersion字段为1且DiskType为空时,该字段无效。ProtocolVersion字段为0或没有该字段时,该字段无效。 * @@ -203,11 +196,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * IgnoreUBillInfo: 是否忽略计费信息。Yes:忽略,No:不忽略,默认值(No)。(如不关心账单信息,建议选填“Yes”,可降低请求延时) * @@ -223,11 +215,10 @@ public function getIgnoreUBillInfo() * * @param string $ignoreUBillInfo */ - public function setIgnoreUBillInfo($ignoreUBillInfo) + public function setIgnoreUBillInfo(string $ignoreUBillInfo) { $this->set("IgnoreUBillInfo", $ignoreUBillInfo); } - /** * IgnoreBackupMode: 是否忽略快照服务信息。Yes:忽略,No:不忽略,默认值(No)。(如不关心快照服务信息,建议选填“Yes”,可降低请求延时) * @@ -243,11 +234,10 @@ public function getIgnoreBackupMode() * * @param string $ignoreBackupMode */ - public function setIgnoreBackupMode($ignoreBackupMode) + public function setIgnoreBackupMode(string $ignoreBackupMode) { $this->set("IgnoreBackupMode", $ignoreBackupMode); } - /** * UDiskBasicInfo: 是否只返回云盘基础信息(只包含云盘及关联主机的资源信息)。Yes:是,No:否,默认值(No)。(如仅需要基础信息,建议选填“Yes”,可降低请求延时) * @@ -263,11 +253,10 @@ public function getUDiskBasicInfo() * * @param string $uDiskBasicInfo */ - public function setUDiskBasicInfo($uDiskBasicInfo) + public function setUDiskBasicInfo(string $uDiskBasicInfo) { $this->set("UDiskBasicInfo", $uDiskBasicInfo); } - /** * UHostIdForAttachment: 根据传入的UHostIdForAttachment,筛选出能被挂载在该主机上的云盘【本字段即将废弃,建议使用HostIdForAttachment】 * @@ -283,11 +272,10 @@ public function getUHostIdForAttachment() * * @param string $uHostIdForAttachment */ - public function setUHostIdForAttachment($uHostIdForAttachment) + public function setUHostIdForAttachment(string $uHostIdForAttachment) { $this->set("UHostIdForAttachment", $uHostIdForAttachment); } - /** * HostIdForAttachment: 根据传入的HostIdForAttachment,筛选出能被挂载在该主机上的云盘。目前主要针对RSSD云盘。 * @@ -303,11 +291,10 @@ public function getHostIdForAttachment() * * @param string $hostIdForAttachment */ - public function setHostIdForAttachment($hostIdForAttachment) + public function setHostIdForAttachment(string $hostIdForAttachment) { $this->set("HostIdForAttachment", $hostIdForAttachment); } - /** * HostId: 根据传入的HostId,返回与该主机关联的云盘信息。 * @@ -323,11 +310,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * HostProduct: 宿主产品类型,可筛选挂载在该类型宿主上的云盘。可选值:uhost, uphost。为空拉取所有。(当HostIdForAttachment字段不为空时,该字段可以不填,若HostIdForAttachment与该字段宿主类型冲突,则以HostIdForAttachment字段为准。) * @@ -343,7 +329,7 @@ public function getHostProduct() * * @param string $hostProduct */ - public function setHostProduct($hostProduct) + public function setHostProduct(string $hostProduct) { $this->set("HostProduct", $hostProduct); } diff --git a/src/UDisk/Apis/DescribeUDiskResponse.php b/src/UDisk/Apis/DescribeUDiskResponse.php index 99f7c285..772ffaff 100644 --- a/src/UDisk/Apis/DescribeUDiskResponse.php +++ b/src/UDisk/Apis/DescribeUDiskResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDiskDataSet($item)); + array_push($result, new UDiskDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: JSON 格式的UDisk数据列表, 每项参数可见下面 UDiskDataSet * - * @param UDiskDataSet[] $dataSet + * @param UDiskDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 根据过滤条件得到的总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDisk/Apis/DescribeUDiskSnapshotRequest.php b/src/UDisk/Apis/DescribeUDiskSnapshotRequest.php index 7b831955..3a21b56f 100644 --- a/src/UDisk/Apis/DescribeUDiskSnapshotRequest.php +++ b/src/UDisk/Apis/DescribeUDiskSnapshotRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 数据偏移量, 默认为0 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认为20 * @@ -123,11 +120,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * UDiskId: UDiskId,返回该盘所做快照.(必须同时传Zone) * @@ -143,11 +139,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * SnapshotId: 快照id,SnapshotId , UDiskId 同时传SnapshotId优先 * @@ -163,7 +158,7 @@ public function getSnapshotId() * * @param string $snapshotId */ - public function setSnapshotId($snapshotId) + public function setSnapshotId(string $snapshotId) { $this->set("SnapshotId", $snapshotId); } diff --git a/src/UDisk/Apis/DescribeUDiskSnapshotResponse.php b/src/UDisk/Apis/DescribeUDiskSnapshotResponse.php index 87d42273..9ff69798 100644 --- a/src/UDisk/Apis/DescribeUDiskSnapshotResponse.php +++ b/src/UDisk/Apis/DescribeUDiskSnapshotResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UDiskSnapshotSet($item)); + array_push($result, new UDiskSnapshotSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: JSON 格式的Snapshot列表, 详细参见 UDiskSnapshotSet * - * @param UDiskSnapshotSet[] $dataSet + * @param UDiskSnapshotSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 根据过滤条件得到的总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UDisk/Apis/DescribeUDiskUpgradePriceRequest.php b/src/UDisk/Apis/DescribeUDiskUpgradePriceRequest.php index 404945e6..fad5d57b 100644 --- a/src/UDisk/Apis/DescribeUDiskUpgradePriceRequest.php +++ b/src/UDisk/Apis/DescribeUDiskUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("SourceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];普通系统盘:范围[1~8000];SSD系统盘:范围[1~4000];RSSD数据盘:范围[1~32000];RSSD系统盘:范围[1~4000];高效数据盘:范围[1~32000];高效系统盘:范围[1~500]。 * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * SourceId: 升级目标UDisk ID * @@ -126,11 +123,10 @@ public function getSourceId() * * @param string $sourceId */ - public function setSourceId($sourceId) + public function setSourceId(string $sourceId) { $this->set("SourceId", $sourceId); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -146,11 +142,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotService: 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No。仅支持查询开启快照服务的价格。 * @@ -166,11 +161,10 @@ public function getSnapshotService() * * @param string $snapshotService */ - public function setSnapshotService($snapshotService) + public function setSnapshotService(string $snapshotService) { $this->set("SnapshotService", $snapshotService); } - /** * DiskType: 【已废弃】UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),SystemDisk(普通系统盘),SSDSystemDisk(SSD系统盘),RSSDSystemDisk(RSSD系统盘),EfficiencySystemDisk(高效系统盘),默认值(DataDisk) * @@ -186,11 +180,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * MachineType: 【已废弃】云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -206,7 +199,7 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } diff --git a/src/UDisk/Apis/DescribeUDiskUpgradePriceResponse.php b/src/UDisk/Apis/DescribeUDiskUpgradePriceResponse.php index dadc8e66..fec38c95 100644 --- a/src/UDisk/Apis/DescribeUDiskUpgradePriceResponse.php +++ b/src/UDisk/Apis/DescribeUDiskUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } - /** * OriginalPrice: 用户折后价 (对应计费CustomPrice) * @@ -57,7 +57,7 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UDisk/Apis/DetachUDiskRequest.php b/src/UDisk/Apis/DetachUDiskRequest.php index 3b82482b..27988ad1 100644 --- a/src/UDisk/Apis/DetachUDiskRequest.php +++ b/src/UDisk/Apis/DetachUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 需要卸载的UDisk实例ID * @@ -104,11 +102,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * UHostId: UHost实例ID。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 * @@ -124,11 +121,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * HostId: Host实例ID * @@ -144,7 +140,7 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } diff --git a/src/UDisk/Apis/DetachUDiskResponse.php b/src/UDisk/Apis/DetachUDiskResponse.php index 548dd912..58135436 100644 --- a/src/UDisk/Apis/DetachUDiskResponse.php +++ b/src/UDisk/Apis/DetachUDiskResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } - /** * UDiskId: 卸载的UDisk实例ID * @@ -57,11 +57,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * HostId: 卸载的Host实例ID * @@ -77,7 +76,7 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } diff --git a/src/UDisk/Apis/RecoverUDiskRequest.php b/src/UDisk/Apis/RecoverUDiskRequest.php index 56a29b14..84da025f 100644 --- a/src/UDisk/Apis/RecoverUDiskRequest.php +++ b/src/UDisk/Apis/RecoverUDiskRequest.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 云硬盘资源ID * @@ -105,11 +103,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * ChargeType: Year , Month, Dynamic 默认: Dynamic * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -145,7 +141,7 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } diff --git a/src/UDisk/Apis/RecoverUDiskResponse.php b/src/UDisk/Apis/RecoverUDiskResponse.php index 7b7327a4..ee5b369e 100644 --- a/src/UDisk/Apis/RecoverUDiskResponse.php +++ b/src/UDisk/Apis/RecoverUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("UDiskName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 重命名的UDisk的Id * @@ -106,11 +104,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * UDiskName: 重命名UDisk的name * @@ -126,7 +123,7 @@ public function getUDiskName() * * @param string $uDiskName */ - public function setUDiskName($uDiskName) + public function setUDiskName(string $uDiskName) { $this->set("UDiskName", $uDiskName); } diff --git a/src/UDisk/Apis/RenameUDiskResponse.php b/src/UDisk/Apis/RenameUDiskResponse.php index 0570c3e5..cab67ebb 100644 --- a/src/UDisk/Apis/RenameUDiskResponse.php +++ b/src/UDisk/Apis/RenameUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: UDisk Id * @@ -106,11 +104,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * Size: 调整后大小, 单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000]。 * @@ -126,11 +123,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * MachineType: 云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -146,11 +142,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * CouponId: 使用的代金券id * @@ -166,7 +161,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/ResizeUDiskResponse.php b/src/UDisk/Apis/ResizeUDiskResponse.php index 3b8d8177..850012d2 100644 --- a/src/UDisk/Apis/ResizeUDiskResponse.php +++ b/src/UDisk/Apis/ResizeUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 需要恢复的盘ID * @@ -105,11 +103,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * SnapshotId: 从指定的快照恢复 * @@ -125,11 +122,10 @@ public function getSnapshotId() * * @param string $snapshotId */ - public function setSnapshotId($snapshotId) + public function setSnapshotId(string $snapshotId) { $this->set("SnapshotId", $snapshotId); } - /** * SnapshotTime: 指定从方舟恢复的备份时间点 * @@ -145,7 +141,7 @@ public function getSnapshotTime() * * @param int $snapshotTime */ - public function setSnapshotTime($snapshotTime) + public function setSnapshotTime(int $snapshotTime) { $this->set("SnapshotTime", $snapshotTime); } diff --git a/src/UDisk/Apis/RestoreUDiskResponse.php b/src/UDisk/Apis/RestoreUDiskResponse.php index ca29d50d..19288975 100644 --- a/src/UDisk/Apis/RestoreUDiskResponse.php +++ b/src/UDisk/Apis/RestoreUDiskResponse.php @@ -1,6 +1,7 @@ markRequired("UDiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UDiskId: 需要设置数据方舟的UDisk的Id * @@ -105,11 +103,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * UDataArkMode: 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No * @@ -125,11 +122,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * CouponId: 使用的代金券id * @@ -145,7 +141,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UDisk/Apis/SetUDiskUDataArkModeResponse.php b/src/UDisk/Apis/SetUDiskUDataArkModeResponse.php index 254ce871..e10c969f 100644 --- a/src/UDisk/Apis/SetUDiskUDataArkModeResponse.php +++ b/src/UDisk/Apis/SetUDiskUDataArkModeResponse.php @@ -1,6 +1,7 @@ set("UDiskId", $uDiskId); } - /** * CreateTime: 创建时间 * @@ -57,11 +59,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpiredTime: 过期时间 * @@ -77,11 +78,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * CountdownTime: 销毁倒计时 * @@ -97,11 +97,10 @@ public function getCountdownTime() * * @param int $countdownTime */ - public function setCountdownTime($countdownTime) + public function setCountdownTime(int $countdownTime) { $this->set("CountdownTime", $countdownTime); } - /** * Name: 磁盘名称 * @@ -117,11 +116,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Size: 磁盘容量 * @@ -137,11 +135,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Tag: 业务组 * @@ -157,11 +154,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Zone: 可用区 * @@ -177,7 +173,7 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } diff --git a/src/UDisk/Models/UDiskDataSet.php b/src/UDisk/Models/UDiskDataSet.php index 013c5835..87fdc66b 100644 --- a/src/UDisk/Models/UDiskDataSet.php +++ b/src/UDisk/Models/UDiskDataSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * UDiskId: UDisk实例Id * @@ -57,11 +60,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * Name: 实例名称 * @@ -77,11 +79,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Size: 容量单位GB * @@ -97,11 +98,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Status: 状态:Available(可用),Attaching(挂载中), InUse(已挂载), Detaching(卸载中), Initializating(分配中), Failed(创建失败),Cloning(克隆中),Restoring(恢复中),RestoreFailed(恢复失败), * @@ -117,11 +117,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * CreateTime: 创建时间 * @@ -137,11 +136,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpiredTime: 过期时间 * @@ -157,11 +155,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * UHostId: 挂载的UHost的Id。【即将废弃,建议使用HostId】 * @@ -177,11 +174,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * UHostName: 挂载的UHost的Name。【即将废弃,建议使用HostName】 * @@ -197,11 +193,10 @@ public function getUHostName() * * @param string $uHostName */ - public function setUHostName($uHostName) + public function setUHostName(string $uHostName) { $this->set("UHostName", $uHostName); } - /** * UHostIP: 挂载的UHost的IP。【即将废弃,建议使用HostIP】 * @@ -217,11 +212,10 @@ public function getUHostIP() * * @param string $uHostIP */ - public function setUHostIP($uHostIP) + public function setUHostIP(string $uHostIP) { $this->set("UHostIP", $uHostIP); } - /** * HostId: 挂载的Host的Id * @@ -237,11 +231,10 @@ public function getHostId() * * @param string $hostId */ - public function setHostId($hostId) + public function setHostId(string $hostId) { $this->set("HostId", $hostId); } - /** * HostName: 挂载的Host的Name * @@ -257,11 +250,10 @@ public function getHostName() * * @param string $hostName */ - public function setHostName($hostName) + public function setHostName(string $hostName) { $this->set("HostName", $hostName); } - /** * HostIP: 挂载的Host的IP * @@ -277,11 +269,10 @@ public function getHostIP() * * @param string $hostIP */ - public function setHostIP($hostIP) + public function setHostIP(string $hostIP) { $this->set("HostIP", $hostIP); } - /** * DeviceName: 挂载的设备名称 * @@ -297,11 +288,10 @@ public function getDeviceName() * * @param string $deviceName */ - public function setDeviceName($deviceName) + public function setDeviceName(string $deviceName) { $this->set("DeviceName", $deviceName); } - /** * ChargeType: Year,Month,Dynamic,Trial,Postpay * @@ -317,11 +307,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Tag: 业务组名称 * @@ -337,11 +326,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * IsExpire: 资源是否过期,过期:"Yes", 未过期:"No" * @@ -357,11 +345,10 @@ public function getIsExpire() * * @param string $isExpire */ - public function setIsExpire($isExpire) + public function setIsExpire(string $isExpire) { $this->set("IsExpire", $isExpire); } - /** * Version: 是否支持数据方舟,支持:"2.0", 不支持:"1.0" * @@ -377,11 +364,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * UDataArkMode: 是否开启数据方舟,开启:"Yes", 不支持:"No" * @@ -397,11 +383,10 @@ public function getUDataArkMode() * * @param string $uDataArkMode */ - public function setUDataArkMode($uDataArkMode) + public function setUDataArkMode(string $uDataArkMode) { $this->set("UDataArkMode", $uDataArkMode); } - /** * SnapshotCount: 该盘快照个数 * @@ -417,11 +402,10 @@ public function getSnapshotCount() * * @param int $snapshotCount */ - public function setSnapshotCount($snapshotCount) + public function setSnapshotCount(int $snapshotCount) { $this->set("SnapshotCount", $snapshotCount); } - /** * SnapshotLimit: 该盘快照上限 * @@ -437,11 +421,10 @@ public function getSnapshotLimit() * * @param int $snapshotLimit */ - public function setSnapshotLimit($snapshotLimit) + public function setSnapshotLimit(int $snapshotLimit) { $this->set("SnapshotLimit", $snapshotLimit); } - /** * DiskType: 请求中的ProtocolVersion字段为1时,需结合IsBoot确定具体磁盘类型:普通数据盘:DiskType:"CLOUD_NORMAL",IsBoot:"False"; 普通系统盘:DiskType:"CLOUD_NORMAL",IsBoot:"True";SSD数据盘:DiskType:"CLOUD_SSD",IsBoot:"False";SSD系统盘:DiskType:"CLOUD_SSD",IsBoot:"True";RSSD数据盘:DiskType:"CLOUD_RSSD",IsBoot:"False";RSSD系统盘:DiskType:"CLOUD_RSSD",IsBoot:"True";高效数据盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"False";高效系统盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"True"。请求中的ProtocolVersion字段为0或没有该字段时,云硬盘类型参照如下:普通数据盘:DataDisk;普通系统盘:SystemDisk;SSD数据盘:SSDDataDisk;SSD系统盘:SSDSystemDisk;RSSD数据盘:RSSDDataDisk;RSSD系统盘:RSSDSystemDisk;高效数据盘:EfficiencyDataDisk;高效系统盘:EfficiencySystemDisk。 * @@ -457,11 +440,10 @@ public function getDiskType() * * @param string $diskType */ - public function setDiskType($diskType) + public function setDiskType(string $diskType) { $this->set("DiskType", $diskType); } - /** * CloneEnable: 是否支持克隆,1支持 ,0不支持 * @@ -477,11 +459,10 @@ public function getCloneEnable() * * @param int $cloneEnable */ - public function setCloneEnable($cloneEnable) + public function setCloneEnable(int $cloneEnable) { $this->set("CloneEnable", $cloneEnable); } - /** * SnapEnable: 是否支持快照,1支持 ,0不支持 * @@ -497,11 +478,10 @@ public function getSnapEnable() * * @param int $snapEnable */ - public function setSnapEnable($snapEnable) + public function setSnapEnable(int $snapEnable) { $this->set("SnapEnable", $snapEnable); } - /** * ArkSwitchEnable: 是否支持开启方舟,1支持 ,0不支持 * @@ -517,11 +497,10 @@ public function getArkSwitchEnable() * * @param int $arkSwitchEnable */ - public function setArkSwitchEnable($arkSwitchEnable) + public function setArkSwitchEnable(int $arkSwitchEnable) { $this->set("ArkSwitchEnable", $arkSwitchEnable); } - /** * UKmsMode: 是否是加密盘,是:"Yes", 否:"No" * @@ -537,11 +516,10 @@ public function getUKmsMode() * * @param string $uKmsMode */ - public function setUKmsMode($uKmsMode) + public function setUKmsMode(string $uKmsMode) { $this->set("UKmsMode", $uKmsMode); } - /** * CmkId: 该盘的cmk id * @@ -557,11 +535,10 @@ public function getCmkId() * * @param string $cmkId */ - public function setCmkId($cmkId) + public function setCmkId(string $cmkId) { $this->set("CmkId", $cmkId); } - /** * DataKey: 该盘的密文密钥 * @@ -577,11 +554,10 @@ public function getDataKey() * * @param string $dataKey */ - public function setDataKey($dataKey) + public function setDataKey(string $dataKey) { $this->set("DataKey", $dataKey); } - /** * CmkIdStatus: 该盘cmk的状态, Enabled(正常),Disabled(失效),Deleted(删除),NoCmkId(非加密盘) * @@ -597,11 +573,10 @@ public function getCmkIdStatus() * * @param string $cmkIdStatus */ - public function setCmkIdStatus($cmkIdStatus) + public function setCmkIdStatus(string $cmkIdStatus) { $this->set("CmkIdStatus", $cmkIdStatus); } - /** * CmkIdAlias: cmk id 别名 * @@ -617,11 +592,10 @@ public function getCmkIdAlias() * * @param string $cmkIdAlias */ - public function setCmkIdAlias($cmkIdAlias) + public function setCmkIdAlias(string $cmkIdAlias) { $this->set("CmkIdAlias", $cmkIdAlias); } - /** * IsBoot: 是否是系统盘,是:"True", 否:"False" * @@ -637,11 +611,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * BackupMode: 该盘的备份方式。快照服务:"SnapshotService";数据方舟:"UDataArk";无备份方式:"" * @@ -657,11 +630,10 @@ public function getBackupMode() * * @param string $backupMode */ - public function setBackupMode($backupMode) + public function setBackupMode(string $backupMode) { $this->set("BackupMode", $backupMode); } - /** * RdmaClusterId: RDMA集群id,仅RSSD返回该值;其他类型云盘返回""。当云盘的此值与快杰云主机的RdmaClusterId相同时,RSSD可以挂载到这台云主机。 * @@ -677,7 +649,7 @@ public function getRdmaClusterId() * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } diff --git a/src/UDisk/Models/UDiskPriceDataSet.php b/src/UDisk/Models/UDiskPriceDataSet.php index 48991219..1593e123 100644 --- a/src/UDisk/Models/UDiskPriceDataSet.php +++ b/src/UDisk/Models/UDiskPriceDataSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 实际价格 (单位: 分) * @@ -57,11 +59,10 @@ public function getPrice() * * @param int $price */ - public function setPrice($price) + public function setPrice(int $price) { $this->set("Price", $price); } - /** * ChargeName: "UDataArk","SnapshotService","UDisk","Total" * @@ -77,11 +78,10 @@ public function getChargeName() * * @param string $chargeName */ - public function setChargeName($chargeName) + public function setChargeName(string $chargeName) { $this->set("ChargeName", $chargeName); } - /** * OriginalPrice: 用户折后价(对应计费CustomPrice) * @@ -97,11 +97,10 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } - /** * ListPrice: 原价(对应计费OriginalPrice) * @@ -117,7 +116,7 @@ public function getListPrice() * * @param int $listPrice */ - public function setListPrice($listPrice) + public function setListPrice(int $listPrice) { $this->set("ListPrice", $listPrice); } diff --git a/src/UDisk/Models/UDiskSnapshotSet.php b/src/UDisk/Models/UDiskSnapshotSet.php index 526c33a2..85b79c53 100644 --- a/src/UDisk/Models/UDiskSnapshotSet.php +++ b/src/UDisk/Models/UDiskSnapshotSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * SnapshotId: 快照Id * @@ -57,11 +59,10 @@ public function getSnapshotId() * * @param string $snapshotId */ - public function setSnapshotId($snapshotId) + public function setSnapshotId(string $snapshotId) { $this->set("SnapshotId", $snapshotId); } - /** * Name: 快照名称 * @@ -77,11 +78,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * UDiskId: 快照的源UDisk的Id * @@ -97,11 +97,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * UDiskName: 快照的源UDisk的Name * @@ -117,11 +116,10 @@ public function getUDiskName() * * @param string $uDiskName */ - public function setUDiskName($uDiskName) + public function setUDiskName(string $uDiskName) { $this->set("UDiskName", $uDiskName); } - /** * CreateTime: 创建时间 * @@ -137,11 +135,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Size: 容量单位GB * @@ -157,11 +154,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Status: 快照状态,Normal:正常,Failed:失败,Creating:制作中 * @@ -177,11 +173,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * DiskType: 磁盘类型,0:普通数据盘;1:普通系统盘;2:SSD数据盘;3:SSD系统盘;4:RSSD数据盘;5:RSSD系统盘。 * @@ -197,11 +192,10 @@ public function getDiskType() * * @param int $diskType */ - public function setDiskType($diskType) + public function setDiskType(int $diskType) { $this->set("DiskType", $diskType); } - /** * ExpiredTime: 过期时间 * @@ -217,11 +211,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * Comment: 快照描述 * @@ -237,11 +230,10 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } - /** * IsUDiskAvailable: 对应磁盘是否处于可用状态 * @@ -257,11 +249,10 @@ public function getIsUDiskAvailable() * * @param boolean $isUDiskAvailable */ - public function setIsUDiskAvailable($isUDiskAvailable) + public function setIsUDiskAvailable(bool $isUDiskAvailable) { $this->set("IsUDiskAvailable", $isUDiskAvailable); } - /** * Version: 快照版本 * @@ -277,11 +268,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * UHostId: 对应磁盘制作快照时所挂载的主机 * @@ -297,11 +287,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * UKmsMode: 是否是加密盘快照,是:"Yes", 否:"No" * @@ -317,11 +306,10 @@ public function getUKmsMode() * * @param string $uKmsMode */ - public function setUKmsMode($uKmsMode) + public function setUKmsMode(string $uKmsMode) { $this->set("UKmsMode", $uKmsMode); } - /** * CmkId: 该快照的cmk id * @@ -337,11 +325,10 @@ public function getCmkId() * * @param string $cmkId */ - public function setCmkId($cmkId) + public function setCmkId(string $cmkId) { $this->set("CmkId", $cmkId); } - /** * DataKey: 该快照的密文密钥 * @@ -357,11 +344,10 @@ public function getDataKey() * * @param string $dataKey */ - public function setDataKey($dataKey) + public function setDataKey(string $dataKey) { $this->set("DataKey", $dataKey); } - /** * CmkIdStatus: 该快照cmk的状态, Enabled(正常),Disabled(失效),Deleted(删除),NoCmkId(非加密盘) * @@ -377,11 +363,10 @@ public function getCmkIdStatus() * * @param string $cmkIdStatus */ - public function setCmkIdStatus($cmkIdStatus) + public function setCmkIdStatus(string $cmkIdStatus) { $this->set("CmkIdStatus", $cmkIdStatus); } - /** * CmkIdAlias: cmk id 别名 * @@ -397,7 +382,7 @@ public function getCmkIdAlias() * * @param string $cmkIdAlias */ - public function setCmkIdAlias($cmkIdAlias) + public function setCmkIdAlias(string $cmkIdAlias) { $this->set("CmkIdAlias", $cmkIdAlias); } diff --git a/src/UDisk/UDiskClient.php b/src/UDisk/UDiskClient.php index bd87ce75..9aed162c 100644 --- a/src/UDisk/UDiskClient.php +++ b/src/UDisk/UDiskClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 需要挂载的UDisk实例ID. - * "UHostId" => (string) UHost实例ID。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 - * "MultiAttach" => (string) 是否允许多点挂载(Yes: 允许多点挂载, No: 不允许多点挂载, 不填默认Yes ) - * "HostId" => (string) Host实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) 挂载的UHost实例ID。【即将废弃,建议使用HostId】 - * "UDiskId" => (string) 挂载的UDisk实例ID - * "DeviceName" => (string) 挂载的设备名称 - * "HostId" => (string) 挂载的Host实例ID - * ] - * - * @return AttachUDiskResponse * @throws UCloudException */ public function attachUDisk(AttachUDiskRequest $request = null) @@ -99,38 +141,13 @@ public function attachUDisk(AttachUDiskRequest $request = null) $resp = $this->invoke($request); return new AttachUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CloneUDisk - 从UDisk创建UDisk克隆 * - * See also: https://docs.ucloud.cn/api/udisk-api/clone_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Name" => (string) 实例名称 - * "SourceId" => (string) 克隆父Disk的Id - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "Quantity" => (integer) 购买时长 默认: 1 - * "Comment" => (string) Disk注释 - * "ChargeType" => (string) Year , Month, Dynamic,Postpay,Trial 默认: Month - * "Tag" => (string) 业务组 默认:Default - * "RdmaClusterId" => (string) 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 - * "HostId" => (string) Host实例ID。克隆出的云盘可直接挂载到该主机上。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (array) 创建UDisk Id - * ] - * - * @return CloneUDiskResponse * @throws UCloudException */ public function cloneUDisk(CloneUDiskRequest $request = null) @@ -138,39 +155,13 @@ public function cloneUDisk(CloneUDiskRequest $request = null) $resp = $this->invoke($request); return new CloneUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CloneUDiskSnapshot - 从快照创建UDisk克隆 * - * See also: https://docs.ucloud.cn/api/udisk-api/clone_udisk_snapshot - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Name" => (string) 实例名称 - * "SourceId" => (string) 克隆父Snapshot的Id - * "Size" => (integer) 购买UDisk大小,单位:GB,范围[1~8000]。(UDisk大小设定对本地盘快照有效,对云盘快照无效) - * "Comment" => (string) Disk注释 - * "ChargeType" => (string) Year , Month, Dynamic,Postpay 默认: Dynamic - * "Quantity" => (integer) 购买时长 默认: 1 - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "Tag" => (string) 业务组 默认:Default - * "RdmaClusterId" => (string) 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 - * "HostId" => (string) Host实例ID。克隆出的云盘可直接挂载到该主机上。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (array) 创建UDisk Id - * ] - * - * @return CloneUDiskSnapshotResponse * @throws UCloudException */ public function cloneUDiskSnapshot(CloneUDiskSnapshotRequest $request = null) @@ -178,40 +169,13 @@ public function cloneUDiskSnapshot(CloneUDiskSnapshotRequest $request = null) $resp = $this->invoke($request); return new CloneUDiskSnapshotResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CloneUDiskUDataArk - 从数据方舟的备份创建UDisk * - * See also: https://docs.ucloud.cn/api/udisk-api/clone_udisk_udataark - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Name" => (string) 实例名称 - * "UDiskId" => (string) 需要克隆的源盘id - * "SnapshotTime" => (integer) 指定从方舟克隆的备份时间点 - * "Comment" => (string) Disk注释 - * "ChargeType" => (string) Year , Month, Dynamic,Postpay 默认: Dynamic - * "Quantity" => (integer) 购买时长 默认: 1 - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "Size" => (integer) 购买UDisk大小,单位:GB,范围[1~8000]。(UDisk大小设定对本地盘备份有效,对云盘备份无效) - * "Tag" => (string) 业务组 默认:Default - * "RdmaClusterId" => (string) 【已废弃】RDMA集群id。指定RSSD云盘克隆到对应的RDMA集群。 - * "HostId" => (string) Host实例ID。克隆出的云盘可直接挂载到该主机上。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (array) 创建UDisk Id - * ] - * - * @return CloneUDiskUDataArkResponse * @throws UCloudException */ public function cloneUDiskUDataArk(CloneUDiskUDataArkRequest $request = null) @@ -219,44 +183,13 @@ public function cloneUDiskUDataArk(CloneUDiskUDataArkRequest $request = null) $resp = $this->invoke($request); return new CloneUDiskUDataArkResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateAttachUDisk - 创建并挂载UDisk磁盘 * - * See also: https://docs.ucloud.cn/api/udisk-api/create_attach_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000];高效数据盘:范围[1~32000]。 - * "Name" => (string) 实例名称 - * "UHostId" => (string) UHost实例ID。当创建云盘类型为RSSDDataDisk时,根据传入的UHostId,创建与虚机在同一PodId下的云盘。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 - * "ChargeType" => (string) Year , Month, Dynamic, Postpay, Trial 。 Size小于等于2000时,默认为Dynamic;Size大于2000时,默认为Month。 - * "Quantity" => (integer) 购买时长 默认: 1 - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "Tag" => (string) 业务组 默认:Default - * "DiskType" => (string) UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),默认值(DataDisk) - * "UKmsMode" => (string) 是否加密。Yes:加密,No:不加密,默认值(No) - * "CmkId" => (string) 加密需要的cmk id,UKmsMode为Yes时,必填 - * "MultiAttach" => (string) 是否允许多点挂载(Yes: 允许多点挂载, No: 不允许多点挂载, 不填默认Yes ) - * "HostId" => (string) Host实例ID。当创建云盘类型为RSSDDataDisk时,根据传入的HostId,创建与虚机在同一PodId下的云盘。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (string) 挂载的UDisk实例ID - * "UHostId" => (string) 挂载的UHost实例ID。【即将废弃,建议使用HostId】 - * "HostId" => (string) 挂载的Host实例ID - * "DeviceName" => (string) 挂载设备名称 - * ] - * - * @return CreateAttachUDiskResponse * @throws UCloudException */ public function createAttachUDisk(CreateAttachUDiskRequest $request = null) @@ -264,39 +197,13 @@ public function createAttachUDisk(CreateAttachUDiskRequest $request = null) $resp = $this->invoke($request); return new CreateAttachUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDisk - 创建UDisk磁盘 * - * See also: https://docs.ucloud.cn/api/udisk-api/create_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000];高效数据盘:范围[1~32000]。 - * "Name" => (string) 实例名称 - * "ChargeType" => (string) Year , Month, Dynamic, Postpay, Trial 。默认为Dynamic。 - * "Quantity" => (integer) 购买时长 默认: 1 - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "Tag" => (string) 业务组 默认:Default - * "DiskType" => (string) UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),默认值(DataDisk) - * "UKmsMode" => (string) 是否加密。Yes:加密,No:不加密,默认值(No) - * "CmkId" => (string) 加密需要的cmk id,UKmsMode为Yes时,必填 - * "RdmaClusterId" => (string) RDMA集群id。DiskType为RSSDDataDisk可填,指定云盘创建到对应的RDMA集群。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (array) UDisk实例Id - * ] - * - * @return CreateUDiskResponse * @throws UCloudException */ public function createUDisk(CreateUDiskRequest $request = null) @@ -304,32 +211,13 @@ public function createUDisk(CreateUDiskRequest $request = null) $resp = $this->invoke($request); return new CreateUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUDiskSnapshot - 创建snapshot快照 * - * See also: https://docs.ucloud.cn/api/udisk-api/create_udisk_snapshot - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 快照的UDisk的Id - * "Name" => (string) 快照名称 - * "Quantity" => (integer) 购买时长 默认: 1 (已废弃) - * "ChargeType" => (string) Year , Month, Dynamic 默认: Dynamic (已废弃) - * "Comment" => (string) 快照描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "SnapshotId" => (array) 快照Id - * ] - * - * @return CreateUDiskSnapshotResponse * @throws UCloudException */ public function createUDiskSnapshot(CreateUDiskSnapshotRequest $request = null) @@ -337,27 +225,13 @@ public function createUDiskSnapshot(CreateUDiskSnapshotRequest $request = null) $resp = $this->invoke($request); return new CreateUDiskSnapshotResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUDisk - 删除UDisk * - * See also: https://docs.ucloud.cn/api/udisk-api/delete_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 要删除的UDisk的Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDiskResponse * @throws UCloudException */ public function deleteUDisk(DeleteUDiskRequest $request = null) @@ -365,28 +239,13 @@ public function deleteUDisk(DeleteUDiskRequest $request = null) $resp = $this->invoke($request); return new DeleteUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUDiskSnapshot - 删除Snapshot * - * See also: https://docs.ucloud.cn/api/udisk-api/delete_udisk_snapshot - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SnapshotId" => (string) 快照Id(填写后不能填写UDisk Id) - * "UDiskId" => (string) UDisk Id,删除该盘所创建出来的所有快照(填写后不能填写SnapshotId) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUDiskSnapshotResponse * @throws UCloudException */ public function deleteUDiskSnapshot(DeleteUDiskSnapshotRequest $request = null) @@ -394,41 +253,13 @@ public function deleteUDiskSnapshot(DeleteUDiskSnapshotRequest $request = null) $resp = $this->invoke($request); return new DeleteUDiskSnapshotResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeRecycleUDisk - 拉取回收站中云硬盘列表 * - * See also: https://docs.ucloud.cn/api/udisk-api/describe_recycle_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Limit" => (integer) 返回数据长度, 默认为20 - * "Offset" => (integer) 数据偏移量, 默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 磁盘数量 - * "DataSet" => (array) 回收站磁盘列表[ - * [ - * "UDiskId" => (string) 磁盘id - * "CreateTime" => (integer) 创建时间 - * "ExpiredTime" => (integer) 过期时间 - * "CountdownTime" => (integer) 销毁倒计时 - * "Name" => (string) 磁盘名称 - * "Size" => (integer) 磁盘容量 - * "Tag" => (string) 业务组 - * "Zone" => (string) 可用区 - * ] - * ] - * ] - * - * @return DescribeRecycleUDiskResponse * @throws UCloudException */ public function describeRecycleUDisk(DescribeRecycleUDiskRequest $request = null) @@ -436,77 +267,13 @@ public function describeRecycleUDisk(DescribeRecycleUDiskRequest $request = null $resp = $this->invoke($request); return new DescribeRecycleUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDisk - 获取UDisk实例 * - * See also: https://docs.ucloud.cn/api/udisk-api/describe_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UDiskId" => (string) UDisk Id(留空返回全部) - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 返回数据长度, 默认为20 - * "DiskType" => (string) ProtocolVersion字段为1时,需结合IsBoot确定具体磁盘类型:普通数据盘:DiskType:"CLOUD_NORMAL",IsBoot:"False";普通系统盘:DiskType:"CLOUD_NORMAL",IsBoot:"True";SSD数据盘:DiskType:"CLOUD_SSD",IsBoot:"False";SSD系统盘:DiskType:"CLOUD_SSD",IsBoot:"True";RSSD数据盘:DiskType:"CLOUD_RSSD",IsBoot:"False";RSSD系统盘:DiskType:"CLOUD_RSSD",IsBoot:"True";高效数据盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"False";高效系统盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"True";为空拉取所有。ProtocolVersion字段为0或没有该字段时,可设为以下几个值:普通数据盘:DataDisk;普通系统盘:SystemDisk;SSD数据盘:SSDDataDisk;SSD系统盘:SSDSystemDisk;RSSD数据盘:RSSDDataDisk;RSSD系统盘:RSSDSystemDisk:高效数据盘:EfficiencyDataDisk;高效系统盘:EfficiencySystemDisk;为空拉取所有。 - * "ProtocolVersion" => (integer) 请求协议版本,建议升级为1,为1时DiskType与UHost磁盘类型定义一致;默认为0 - * "IsBoot" => (string) ProtocolVersion字段为1且DiskType不为空时,必须设置,设置规则请参照DiskType;ProtocolVersion字段为1且DiskType为空时,该字段无效。ProtocolVersion字段为0或没有该字段时,该字段无效。 - * "IgnoreUBillInfo" => (string) 是否忽略计费信息。Yes:忽略,No:不忽略,默认值(No)。(如不关心账单信息,建议选填“Yes”,可降低请求延时) - * "IgnoreBackupMode" => (string) 是否忽略快照服务信息。Yes:忽略,No:不忽略,默认值(No)。(如不关心快照服务信息,建议选填“Yes”,可降低请求延时) - * "UDiskBasicInfo" => (string) 是否只返回云盘基础信息(只包含云盘及关联主机的资源信息)。Yes:是,No:否,默认值(No)。(如仅需要基础信息,建议选填“Yes”,可降低请求延时) - * "UHostIdForAttachment" => (string) 根据传入的UHostIdForAttachment,筛选出能被挂载在该主机上的云盘【本字段即将废弃,建议使用HostIdForAttachment】 - * "HostIdForAttachment" => (string) 根据传入的HostIdForAttachment,筛选出能被挂载在该主机上的云盘。目前主要针对RSSD云盘。 - * "HostId" => (string) 根据传入的HostId,返回与该主机关联的云盘信息。 - * "HostProduct" => (string) 宿主产品类型,可筛选挂载在该类型宿主上的云盘。可选值:uhost, uphost。为空拉取所有。(当HostIdForAttachment字段不为空时,该字段可以不填,若HostIdForAttachment与该字段宿主类型冲突,则以HostIdForAttachment字段为准。) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) JSON 格式的UDisk数据列表, 每项参数可见下面 UDiskDataSet[ - * [ - * "Zone" => (string) 可用区 - * "UDiskId" => (string) UDisk实例Id - * "Name" => (string) 实例名称 - * "Size" => (integer) 容量单位GB - * "Status" => (string) 状态:Available(可用),Attaching(挂载中), InUse(已挂载), Detaching(卸载中), Initializating(分配中), Failed(创建失败),Cloning(克隆中),Restoring(恢复中),RestoreFailed(恢复失败), - * "CreateTime" => (integer) 创建时间 - * "ExpiredTime" => (integer) 过期时间 - * "UHostId" => (string) 挂载的UHost的Id。【即将废弃,建议使用HostId】 - * "UHostName" => (string) 挂载的UHost的Name。【即将废弃,建议使用HostName】 - * "UHostIP" => (string) 挂载的UHost的IP。【即将废弃,建议使用HostIP】 - * "HostId" => (string) 挂载的Host的Id - * "HostName" => (string) 挂载的Host的Name - * "HostIP" => (string) 挂载的Host的IP - * "DeviceName" => (string) 挂载的设备名称 - * "ChargeType" => (string) Year,Month,Dynamic,Trial,Postpay - * "Tag" => (string) 业务组名称 - * "IsExpire" => (string) 资源是否过期,过期:"Yes", 未过期:"No" - * "Version" => (string) 是否支持数据方舟,支持:"2.0", 不支持:"1.0" - * "UDataArkMode" => (string) 是否开启数据方舟,开启:"Yes", 不支持:"No" - * "SnapshotCount" => (integer) 该盘快照个数 - * "SnapshotLimit" => (integer) 该盘快照上限 - * "DiskType" => (string) 请求中的ProtocolVersion字段为1时,需结合IsBoot确定具体磁盘类型:普通数据盘:DiskType:"CLOUD_NORMAL",IsBoot:"False"; 普通系统盘:DiskType:"CLOUD_NORMAL",IsBoot:"True";SSD数据盘:DiskType:"CLOUD_SSD",IsBoot:"False";SSD系统盘:DiskType:"CLOUD_SSD",IsBoot:"True";RSSD数据盘:DiskType:"CLOUD_RSSD",IsBoot:"False";RSSD系统盘:DiskType:"CLOUD_RSSD",IsBoot:"True";高效数据盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"False";高效系统盘:DiskType:"CLOUD_EFFICIENCY",IsBoot:"True"。请求中的ProtocolVersion字段为0或没有该字段时,云硬盘类型参照如下:普通数据盘:DataDisk;普通系统盘:SystemDisk;SSD数据盘:SSDDataDisk;SSD系统盘:SSDSystemDisk;RSSD数据盘:RSSDDataDisk;RSSD系统盘:RSSDSystemDisk;高效数据盘:EfficiencyDataDisk;高效系统盘:EfficiencySystemDisk。 - * "CloneEnable" => (integer) 是否支持克隆,1支持 ,0不支持 - * "SnapEnable" => (integer) 是否支持快照,1支持 ,0不支持 - * "ArkSwitchEnable" => (integer) 是否支持开启方舟,1支持 ,0不支持 - * "UKmsMode" => (string) 是否是加密盘,是:"Yes", 否:"No" - * "CmkId" => (string) 该盘的cmk id - * "DataKey" => (string) 该盘的密文密钥 - * "CmkIdStatus" => (string) 该盘cmk的状态, Enabled(正常),Disabled(失效),Deleted(删除),NoCmkId(非加密盘) - * "CmkIdAlias" => (string) cmk id 别名 - * "IsBoot" => (string) 是否是系统盘,是:"True", 否:"False" - * "BackupMode" => (string) 该盘的备份方式。快照服务:"SnapshotService";数据方舟:"UDataArk";无备份方式:"" - * "RdmaClusterId" => (string) RDMA集群id,仅RSSD返回该值;其他类型云盘返回""。当云盘的此值与快杰云主机的RdmaClusterId相同时,RSSD可以挂载到这台云主机。 - * ] - * ] - * "TotalCount" => (integer) 根据过滤条件得到的总数 - * ] - * - * @return DescribeUDiskResponse * @throws UCloudException */ public function describeUDisk(DescribeUDiskRequest $request = null) @@ -514,43 +281,13 @@ public function describeUDisk(DescribeUDiskRequest $request = null) $resp = $this->invoke($request); return new DescribeUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDiskPrice - 获取UDisk实例价格信息 * - * See also: https://docs.ucloud.cn/api/udisk-api/describe_udisk_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];普通系统盘:范围[1~8000];SSD系统盘:范围[1~4000];RSSD数据盘:范围[1~32000];RSSD系统盘:范围[1~4000];高效数据盘:范围[1~32000];高效系统盘:范围[1~500]。 - * "ChargeType" => (string) Year , Month, Dynamic,Postpay,Trial 默认: Month - * "Quantity" => (integer) 购买UDisk的时长,默认值为1 - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No - * "DiskType" => (string) UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),SystemDisk(普通系统盘),SSDSystemDisk(SSD系统盘),RSSDSystemDisk(RSSD系统盘),EfficiencySystemDisk(高效系统盘),默认值(DataDisk) - * "IsTotalPrice" => (string) 是否将快照服务(数据方舟),云硬盘放入一张订单, 是:"Yes",否:"No",默认是"No" - * "MachineType" => (string) 云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 价格参数列表,具体说明见 UDiskPriceDataSet[ - * [ - * "ChargeType" => (string) Year, Month, Dynamic,Trial - * "Price" => (integer) 实际价格 (单位: 分) - * "ChargeName" => (string) "UDataArk","SnapshotService","UDisk","Total" - * "OriginalPrice" => (integer) 用户折后价(对应计费CustomPrice) - * "ListPrice" => (integer) 原价(对应计费OriginalPrice) - * ] - * ] - * ] - * - * @return DescribeUDiskPriceResponse * @throws UCloudException */ public function describeUDiskPrice(DescribeUDiskPriceRequest $request = null) @@ -558,54 +295,13 @@ public function describeUDiskPrice(DescribeUDiskPriceRequest $request = null) $resp = $this->invoke($request); return new DescribeUDiskPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDiskSnapshot - 获取UDisk快照 * - * See also: https://docs.ucloud.cn/api/udisk-api/describe_udisk_snapshot - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 返回数据长度, 默认为20 - * "UDiskId" => (string) UDiskId,返回该盘所做快照.(必须同时传Zone) - * "SnapshotId" => (string) 快照id,SnapshotId , UDiskId 同时传SnapshotId优先 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) JSON 格式的Snapshot列表, 详细参见 UDiskSnapshotSet[ - * [ - * "Zone" => (string) 可用区 - * "SnapshotId" => (string) 快照Id - * "Name" => (string) 快照名称 - * "UDiskId" => (string) 快照的源UDisk的Id - * "UDiskName" => (string) 快照的源UDisk的Name - * "CreateTime" => (integer) 创建时间 - * "Size" => (integer) 容量单位GB - * "Status" => (string) 快照状态,Normal:正常,Failed:失败,Creating:制作中 - * "DiskType" => (integer) 磁盘类型,0:普通数据盘;1:普通系统盘;2:SSD数据盘;3:SSD系统盘;4:RSSD数据盘;5:RSSD系统盘。 - * "ExpiredTime" => (integer) 过期时间 - * "Comment" => (string) 快照描述 - * "IsUDiskAvailable" => (boolean) 对应磁盘是否处于可用状态 - * "Version" => (string) 快照版本 - * "UHostId" => (string) 对应磁盘制作快照时所挂载的主机 - * "UKmsMode" => (string) 是否是加密盘快照,是:"Yes", 否:"No" - * "CmkId" => (string) 该快照的cmk id - * "DataKey" => (string) 该快照的密文密钥 - * "CmkIdStatus" => (string) 该快照cmk的状态, Enabled(正常),Disabled(失效),Deleted(删除),NoCmkId(非加密盘) - * "CmkIdAlias" => (string) cmk id 别名 - * ] - * ] - * "TotalCount" => (integer) 根据过滤条件得到的总数 - * ] - * - * @return DescribeUDiskSnapshotResponse * @throws UCloudException */ public function describeUDiskSnapshot(DescribeUDiskSnapshotRequest $request = null) @@ -613,34 +309,13 @@ public function describeUDiskSnapshot(DescribeUDiskSnapshotRequest $request = nu $resp = $this->invoke($request); return new DescribeUDiskSnapshotResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUDiskUpgradePrice - 获取UDisk升级价格信息 * - * See also: https://docs.ucloud.cn/api/udisk-api/describe_udisk_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买UDisk大小,单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];普通系统盘:范围[1~8000];SSD系统盘:范围[1~4000];RSSD数据盘:范围[1~32000];RSSD系统盘:范围[1~4000];高效数据盘:范围[1~32000];高效系统盘:范围[1~500]。 - * "SourceId" => (string) 升级目标UDisk ID - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "SnapshotService" => (string) 是否开启快照服务(开启快照服务,可免费开启数据方舟)。Yes:开启,No:不开启,默认值:No。仅支持查询开启快照服务的价格。 - * "DiskType" => (string) 【已废弃】UDisk 类型: DataDisk(普通数据盘),SSDDataDisk(SSD数据盘),RSSDDataDisk(RSSD数据盘),EfficiencyDataDisk(高效数据盘),SystemDisk(普通系统盘),SSDSystemDisk(SSD系统盘),RSSDSystemDisk(RSSD系统盘),EfficiencySystemDisk(高效系统盘),默认值(DataDisk) - * "MachineType" => (string) 【已废弃】云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (integer) 价格 - * "OriginalPrice" => (integer) 用户折后价 (对应计费CustomPrice) - * ] - * - * @return DescribeUDiskUpgradePriceResponse * @throws UCloudException */ public function describeUDiskUpgradePrice(DescribeUDiskUpgradePriceRequest $request = null) @@ -648,32 +323,13 @@ public function describeUDiskUpgradePrice(DescribeUDiskUpgradePriceRequest $requ $resp = $this->invoke($request); return new DescribeUDiskUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DetachUDisk - 卸载某个已经挂载在指定UHost实例上的UDisk * - * See also: https://docs.ucloud.cn/api/udisk-api/detach_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 需要卸载的UDisk实例ID - * "UHostId" => (string) UHost实例ID。【UHostId和HostId必须选填一个,本字段即将废弃,建议使用HostId】 - * "HostId" => (string) Host实例ID - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) 卸载的UHost实例ID。【即将废弃,建议使用HostId】 - * "UDiskId" => (string) 卸载的UDisk实例ID - * "HostId" => (string) 卸载的Host实例ID - * ] - * - * @return DetachUDiskResponse * @throws UCloudException */ public function detachUDisk(DetachUDiskRequest $request = null) @@ -681,29 +337,13 @@ public function detachUDisk(DetachUDiskRequest $request = null) $resp = $this->invoke($request); return new DetachUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RecoverUDisk - 从回收站中恢复云硬盘 * - * See also: https://docs.ucloud.cn/api/udisk-api/recover_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 云硬盘资源ID - * "ChargeType" => (string) Year , Month, Dynamic 默认: Dynamic - * "Quantity" => (integer) 购买时长 默认: 1 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RecoverUDiskResponse * @throws UCloudException */ public function recoverUDisk(RecoverUDiskRequest $request = null) @@ -711,28 +351,13 @@ public function recoverUDisk(RecoverUDiskRequest $request = null) $resp = $this->invoke($request); return new RecoverUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RenameUDisk - 重命名UDisk * - * See also: https://docs.ucloud.cn/api/udisk-api/rename_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 重命名的UDisk的Id - * "UDiskName" => (string) 重命名UDisk的name - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RenameUDiskResponse * @throws UCloudException */ public function renameUDisk(RenameUDiskRequest $request = null) @@ -740,30 +365,13 @@ public function renameUDisk(RenameUDiskRequest $request = null) $resp = $this->invoke($request); return new RenameUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeUDisk - 调整UDisk容量 * - * See also: https://docs.ucloud.cn/api/udisk-api/resize_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) UDisk Id - * "Size" => (integer) 调整后大小, 单位:GB,普通数据盘:范围[1~8000];SSD数据盘:范围[1~8000];RSSD数据盘:范围[1~32000]。 - * "MachineType" => (string) 云主机机型(V2.0),枚举值["N", "C", "G", "O", "OM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ResizeUDiskResponse * @throws UCloudException */ public function resizeUDisk(ResizeUDiskRequest $request = null) @@ -771,29 +379,13 @@ public function resizeUDisk(ResizeUDiskRequest $request = null) $resp = $this->invoke($request); return new ResizeUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestoreUDisk - 从备份恢复数据至UDisk * - * See also: https://docs.ucloud.cn/api/udisk-api/restore_udisk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "UDiskId" => (string) 需要恢复的盘ID - * "SnapshotId" => (string) 从指定的快照恢复 - * "SnapshotTime" => (integer) 指定从方舟恢复的备份时间点 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestoreUDiskResponse * @throws UCloudException */ public function restoreUDisk(RestoreUDiskRequest $request = null) @@ -801,29 +393,13 @@ public function restoreUDisk(RestoreUDiskRequest $request = null) $resp = $this->invoke($request); return new RestoreUDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SetUDiskUDataArkMode - 设置UDisk数据方舟的状态 * - * See also: https://docs.ucloud.cn/api/udisk-api/set_udisk_udataark_mode - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UDiskId" => (string) 需要设置数据方舟的UDisk的Id - * "UDataArkMode" => (string) 【开启数据方舟入口已关闭】是否开启数据方舟。Yes:开启,No:不开启,默认值:No - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetUDiskUDataArkModeResponse * @throws UCloudException */ public function setUDiskUDataArkMode(SetUDiskUDataArkModeRequest $request = null) diff --git a/src/UEC/Apis/BindUEcFirewallRequest.php b/src/UEC/Apis/BindUEcFirewallRequest.php index 87c75b70..14c1c9a5 100644 --- a/src/UEC/Apis/BindUEcFirewallRequest.php +++ b/src/UEC/Apis/BindUEcFirewallRequest.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙Id * @@ -64,11 +64,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ResourceId: 虚拟机资源Id或容器组资源id * @@ -84,7 +83,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UEC/Apis/BindUEcFirewallResponse.php b/src/UEC/Apis/BindUEcFirewallResponse.php index da34665d..039187b9 100644 --- a/src/UEC/Apis/BindUEcFirewallResponse.php +++ b/src/UEC/Apis/BindUEcFirewallResponse.php @@ -1,6 +1,7 @@ "CreateUEcCustomImage"]); + $this->markRequired("NodeId"); + $this->markRequired("ImageName"); + } + + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * NodeId: 虚拟机实例ID + * + * @return string|null + */ + public function getNodeId() + { + return $this->get("NodeId"); + } + + /** + * NodeId: 虚拟机实例ID + * + * @param string $nodeId + */ + public function setNodeId(string $nodeId) + { + $this->set("NodeId", $nodeId); + } + /** + * ImageName: 镜像名称 + * + * @return string|null + */ + public function getImageName() + { + return $this->get("ImageName"); + } + + /** + * ImageName: 镜像名称 + * + * @param string $imageName + */ + public function setImageName(string $imageName) + { + $this->set("ImageName", $imageName); + } + /** + * ImageDescription: 镜像描述 + * + * @return string|null + */ + public function getImageDescription() + { + return $this->get("ImageDescription"); + } + + /** + * ImageDescription: 镜像描述 + * + * @param string $imageDescription + */ + public function setImageDescription(string $imageDescription) + { + $this->set("ImageDescription", $imageDescription); + } +} diff --git a/src/UEC/Apis/CreateUEcCustomImageResponse.php b/src/UEC/Apis/CreateUEcCustomImageResponse.php new file mode 100644 index 00000000..ad4d2463 --- /dev/null +++ b/src/UEC/Apis/CreateUEcCustomImageResponse.php @@ -0,0 +1,45 @@ +get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } +} diff --git a/src/UEC/Apis/CreateUEcFirewallRequest.php b/src/UEC/Apis/CreateUEcFirewallRequest.php index 4e701eb0..0bd10b02 100644 --- a/src/UEC/Apis/CreateUEcFirewallRequest.php +++ b/src/UEC/Apis/CreateUEcFirewallRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 防火墙名称 * @@ -64,15 +65,14 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Rule: * - * @return CreateUEcFirewallParamRule[]|null + * @return CreateUEcFirewallRequestRuleModel[]|null */ public function getRule() { @@ -82,7 +82,7 @@ public function getRule() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUEcFirewallParamRule($item)); + array_push($result, new CreateUEcFirewallRequestRuleModel($item)); } return $result; } @@ -90,7 +90,7 @@ public function getRule() /** * Rule: * - * @param CreateUEcFirewallParamRule[] $rule + * @param CreateUEcFirewallRequestRuleModel[] $rule */ public function setRule(array $rule) { @@ -100,7 +100,6 @@ public function setRule(array $rule) } return $result; } - /** * Remark: 描述 * @@ -116,7 +115,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Apis/CreateUEcFirewallResponse.php b/src/UEC/Apis/CreateUEcFirewallResponse.php index 1910a077..06e1665a 100644 --- a/src/UEC/Apis/CreateUEcFirewallResponse.php +++ b/src/UEC/Apis/CreateUEcFirewallResponse.php @@ -1,6 +1,7 @@ set("FirewallId", $firewallId); } diff --git a/src/UEC/Apis/CreateUEcHolderRequest.php b/src/UEC/Apis/CreateUEcHolderRequest.php index 87ce8a56..b72e44a7 100644 --- a/src/UEC/Apis/CreateUEcHolderRequest.php +++ b/src/UEC/Apis/CreateUEcHolderRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -49,11 +51,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: 机房id * @@ -69,11 +70,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * CpuCore: 容器组Cpu总核数 * @@ -89,11 +89,10 @@ public function getCpuCore() * * @param float $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(float $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 容器组总内存,单位MB * @@ -109,11 +108,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * SubnetId: 子网ID * @@ -129,11 +127,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Name: 容器组名称(默认default) * @@ -149,11 +146,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * ProductType: 机型(normal-经济型,hf-标准型,默认normal) * @@ -169,11 +165,10 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } - /** * RestartStrategy: 重启策略(0总是,1失败是,2永不,默认0) * @@ -189,11 +184,10 @@ public function getRestartStrategy() * * @param int $restartStrategy */ - public function setRestartStrategy($restartStrategy) + public function setRestartStrategy(int $restartStrategy) { $this->set("RestartStrategy", $restartStrategy); } - /** * ElasticIp: 绑定外网ip(yes-绑定,no-不绑定,默认no) * @@ -209,11 +203,10 @@ public function getElasticIp() * * @param string $elasticIp */ - public function setElasticIp($elasticIp) + public function setElasticIp(string $elasticIp) { $this->set("ElasticIp", $elasticIp); } - /** * Bandwidth: 外网绑定的带宽(单位M,默认0,只有当ElasticIp为yes时,默认1) * @@ -229,11 +222,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * FirewallId: 防火墙ID * @@ -249,11 +241,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ChargeType: 付费方式(2按月、3按年。默认2,默认月付) * @@ -269,11 +260,10 @@ public function getChargeType() * * @param int $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(int $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ChargeQuantity: 月数或者年数(默认值:1,当为按月计费时,0表示计费到月底,默认值为0) * @@ -289,15 +279,14 @@ public function getChargeQuantity() * * @param int $chargeQuantity */ - public function setChargeQuantity($chargeQuantity) + public function setChargeQuantity(int $chargeQuantity) { $this->set("ChargeQuantity", $chargeQuantity); } - /** * Pack: * - * @return CreateUEcHolderParamPack[]|null + * @return CreateUEcHolderRequestPackModel[]|null */ public function getPack() { @@ -307,7 +296,7 @@ public function getPack() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUEcHolderParamPack($item)); + array_push($result, new CreateUEcHolderRequestPackModel($item)); } return $result; } @@ -315,7 +304,7 @@ public function getPack() /** * Pack: * - * @param CreateUEcHolderParamPack[] $pack + * @param CreateUEcHolderRequestPackModel[] $pack */ public function setPack(array $pack) { @@ -325,11 +314,10 @@ public function setPack(array $pack) } return $result; } - /** * Image: * - * @return CreateUEcHolderParamImage[]|null + * @return CreateUEcHolderRequestImageModel[]|null */ public function getImage() { @@ -339,7 +327,7 @@ public function getImage() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUEcHolderParamImage($item)); + array_push($result, new CreateUEcHolderRequestImageModel($item)); } return $result; } @@ -347,7 +335,7 @@ public function getImage() /** * Image: * - * @param CreateUEcHolderParamImage[] $image + * @param CreateUEcHolderRequestImageModel[] $image */ public function setImage(array $image) { @@ -357,11 +345,10 @@ public function setImage(array $image) } return $result; } - /** * Storage: * - * @return CreateUEcHolderParamStorage[]|null + * @return CreateUEcHolderRequestStorageModel[]|null */ public function getStorage() { @@ -371,7 +358,7 @@ public function getStorage() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUEcHolderParamStorage($item)); + array_push($result, new CreateUEcHolderRequestStorageModel($item)); } return $result; } @@ -379,7 +366,7 @@ public function getStorage() /** * Storage: * - * @param CreateUEcHolderParamStorage[] $storage + * @param CreateUEcHolderRequestStorageModel[] $storage */ public function setStorage(array $storage) { diff --git a/src/UEC/Apis/CreateUEcHolderResponse.php b/src/UEC/Apis/CreateUEcHolderResponse.php index aa09ecec..0a40d86c 100644 --- a/src/UEC/Apis/CreateUEcHolderResponse.php +++ b/src/UEC/Apis/CreateUEcHolderResponse.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } diff --git a/src/UEC/Apis/CreateUEcSubnetRequest.php b/src/UEC/Apis/CreateUEcSubnetRequest.php index 43981e0c..0f5ae0b9 100644 --- a/src/UEC/Apis/CreateUEcSubnetRequest.php +++ b/src/UEC/Apis/CreateUEcSubnetRequest.php @@ -1,6 +1,7 @@ markRequired("CIDR"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: 机房ID * @@ -64,11 +64,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * CIDR: 子网cidr * @@ -84,11 +83,10 @@ public function getCIDR() * * @param string $cidr */ - public function setCIDR($cidr) + public function setCIDR(string $cidr) { $this->set("CIDR", $cidr); } - /** * SubnetName: 子网名称 * @@ -104,11 +102,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * Comment: 备注 * @@ -124,7 +121,7 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } diff --git a/src/UEC/Apis/CreateUEcSubnetResponse.php b/src/UEC/Apis/CreateUEcSubnetResponse.php index 9e9d674b..ce6870d9 100644 --- a/src/UEC/Apis/CreateUEcSubnetResponse.php +++ b/src/UEC/Apis/CreateUEcSubnetResponse.php @@ -1,6 +1,7 @@ set("SubnetId", $subnetId); } diff --git a/src/UEC/Apis/CreateUEcVHostRequest.php b/src/UEC/Apis/CreateUEcVHostRequest.php index 22ff1147..059da95a 100644 --- a/src/UEC/Apis/CreateUEcVHostRequest.php +++ b/src/UEC/Apis/CreateUEcVHostRequest.php @@ -1,6 +1,7 @@ markRequired("NetLimit"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -48,11 +49,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: 机房id * @@ -68,11 +68,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * CpuCore: cpu核心数 * @@ -88,11 +87,10 @@ public function getCpuCore() * * @param int $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(int $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 内存大小,单位GB * @@ -108,11 +106,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * DiskSize: 数据盘大小,单位GB * @@ -128,11 +125,10 @@ public function getDiskSize() * * @param int $diskSize */ - public function setDiskSize($diskSize) + public function setDiskSize(int $diskSize) { $this->set("DiskSize", $diskSize); } - /** * ImageId: 镜像ID * @@ -148,11 +144,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * NetLimit: 节点带宽限制,单位Mbs * @@ -168,11 +163,10 @@ public function getNetLimit() * * @param int $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(int $netLimit) { $this->set("NetLimit", $netLimit); } - /** * NodeName: 节点名称 * @@ -188,11 +182,10 @@ public function getNodeName() * * @param string $nodeName */ - public function setNodeName($nodeName) + public function setNodeName(string $nodeName) { $this->set("NodeName", $nodeName); } - /** * SysDiskSize: 系统盘大小,单位GB, 默认20GB * @@ -208,11 +201,10 @@ public function getSysDiskSize() * * @param int $sysDiskSize */ - public function setSysDiskSize($sysDiskSize) + public function setSysDiskSize(int $sysDiskSize) { $this->set("SysDiskSize", $sysDiskSize); } - /** * AccountName: 账户名,默认root * @@ -228,11 +220,10 @@ public function getAccountName() * * @param string $accountName */ - public function setAccountName($accountName) + public function setAccountName(string $accountName) { $this->set("AccountName", $accountName); } - /** * PassWord: 密码 * @@ -248,11 +239,10 @@ public function getPassWord() * * @param string $passWord */ - public function setPassWord($passWord) + public function setPassWord(string $passWord) { $this->set("PassWord", $passWord); } - /** * NodeCount: 创建节点数量,默认1 * @@ -268,11 +258,10 @@ public function getNodeCount() * * @param int $nodeCount */ - public function setNodeCount($nodeCount) + public function setNodeCount(int $nodeCount) { $this->set("NodeCount", $nodeCount); } - /** * ChargeType: 付费方式,1按时,2按月,3按年,默认2 * @@ -288,11 +277,10 @@ public function getChargeType() * * @param int $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(int $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ChargeQuantity: 月数或者年数,0计费到月底, 默认0 * @@ -308,11 +296,10 @@ public function getChargeQuantity() * * @param int $chargeQuantity */ - public function setChargeQuantity($chargeQuantity) + public function setChargeQuantity(int $chargeQuantity) { $this->set("ChargeQuantity", $chargeQuantity); } - /** * SubnetId: 子网ID * @@ -328,11 +315,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ProductType: 产品类型:normal(经济型),hf(标准型),g(Gpu型) * @@ -348,11 +334,10 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } - /** * FirewallId: 外网防护墙规则组,默认 * @@ -368,11 +353,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * Isp: 运营商(1-电信,2-联通,4移动) * @@ -392,7 +376,6 @@ public function setIsp(array $isp) { $this->set("Isp", $isp); } - /** * IsNeedOuterIp: 是否需要外网ip(no-否) * @@ -408,11 +391,10 @@ public function getIsNeedOuterIp() * * @param string $isNeedOuterIp */ - public function setIsNeedOuterIp($isNeedOuterIp) + public function setIsNeedOuterIp(string $isNeedOuterIp) { $this->set("IsNeedOuterIp", $isNeedOuterIp); } - /** * Gpu: Gpu卡核心数。仅Gpu机型支持此字段 * @@ -428,11 +410,10 @@ public function getGpu() * * @param int $gpu */ - public function setGpu($gpu) + public function setGpu(int $gpu) { $this->set("Gpu", $gpu); } - /** * GpuType: Gpu类型,枚举值["T4S"],ProductType为G时必填 * @@ -448,7 +429,7 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } diff --git a/src/UEC/Apis/CreateUEcVHostResponse.php b/src/UEC/Apis/CreateUEcVHostResponse.php index 4670cfe7..1f950c44 100644 --- a/src/UEC/Apis/CreateUEcVHostResponse.php +++ b/src/UEC/Apis/CreateUEcVHostResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NodeList($item)); + array_push($result, new NodeListModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getNodeList() /** * NodeList: 节点id(详情参考NodeList) * - * @param NodeList[] $nodeList + * @param NodeListModel[] $nodeList */ public function setNodeList(array $nodeList) { diff --git a/src/UEC/Apis/DeleteUEcCustomImageRequest.php b/src/UEC/Apis/DeleteUEcCustomImageRequest.php index 9b3d743a..07065116 100644 --- a/src/UEC/Apis/DeleteUEcCustomImageRequest.php +++ b/src/UEC/Apis/DeleteUEcCustomImageRequest.php @@ -1,6 +1,7 @@ markRequired("ImageId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageId: 镜像ID * @@ -63,11 +63,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * IdcId: 机房ID,带机房ID表示只删除指定机房镜像 * @@ -83,7 +82,7 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } diff --git a/src/UEC/Apis/DeleteUEcCustomImageResponse.php b/src/UEC/Apis/DeleteUEcCustomImageResponse.php index c78fcb59..a4f8896d 100644 --- a/src/UEC/Apis/DeleteUEcCustomImageResponse.php +++ b/src/UEC/Apis/DeleteUEcCustomImageResponse.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } diff --git a/src/UEC/Apis/DeleteUEcHolderRequest.php b/src/UEC/Apis/DeleteUEcHolderRequest.php index 5e09b0ad..5de858f3 100644 --- a/src/UEC/Apis/DeleteUEcHolderRequest.php +++ b/src/UEC/Apis/DeleteUEcHolderRequest.php @@ -1,6 +1,7 @@ markRequired("HolderId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * HolderId: 容器组资源id,n为0,1,2... * diff --git a/src/UEC/Apis/DeleteUEcHolderResponse.php b/src/UEC/Apis/DeleteUEcHolderResponse.php index 7101b3b0..60b54b77 100644 --- a/src/UEC/Apis/DeleteUEcHolderResponse.php +++ b/src/UEC/Apis/DeleteUEcHolderResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网ID * @@ -63,7 +63,7 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } diff --git a/src/UEC/Apis/DeleteUEcSubnetResponse.php b/src/UEC/Apis/DeleteUEcSubnetResponse.php index 42b8a671..138348a0 100644 --- a/src/UEC/Apis/DeleteUEcSubnetResponse.php +++ b/src/UEC/Apis/DeleteUEcSubnetResponse.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 节点id * diff --git a/src/UEC/Apis/DeleteUEcVHostResponse.php b/src/UEC/Apis/DeleteUEcVHostResponse.php index a121de7d..0ad7a88f 100644 --- a/src/UEC/Apis/DeleteUEcVHostResponse.php +++ b/src/UEC/Apis/DeleteUEcVHostResponse.php @@ -1,6 +1,7 @@ "DescribeUEcFirewall"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙ID,默认为返回所有防火墙 * @@ -62,11 +62,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ResourceId: 绑定防火墙组的虚拟机资源ID * @@ -82,11 +81,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * Limit: 返回数据长度,默认为20 * @@ -102,11 +100,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -122,7 +119,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UEC/Apis/DescribeUEcFirewallResourceRequest.php b/src/UEC/Apis/DescribeUEcFirewallResourceRequest.php index 4224d39d..6cf9f9bd 100644 --- a/src/UEC/Apis/DescribeUEcFirewallResourceRequest.php +++ b/src/UEC/Apis/DescribeUEcFirewallResourceRequest.php @@ -1,6 +1,7 @@ markRequired("FirewallId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙Id * @@ -63,7 +63,7 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } diff --git a/src/UEC/Apis/DescribeUEcFirewallResourceResponse.php b/src/UEC/Apis/DescribeUEcFirewallResourceResponse.php index e7509a08..ca9717d7 100644 --- a/src/UEC/Apis/DescribeUEcFirewallResourceResponse.php +++ b/src/UEC/Apis/DescribeUEcFirewallResourceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ResourceInfo($item)); + array_push($result, new ResourceInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getResourceSet() /** * ResourceSet: 资源列表,详情参见ResourceInfo * - * @param ResourceInfo[] $resourceSet + * @param ResourceInfoModel[] $resourceSet */ public function setResourceSet(array $resourceSet) { @@ -54,7 +56,6 @@ public function setResourceSet(array $resourceSet) } return $result; } - /** * TotalCount: 资源总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UEC/Apis/DescribeUEcFirewallResponse.php b/src/UEC/Apis/DescribeUEcFirewallResponse.php index 6a3f5ab2..6f997a71 100644 --- a/src/UEC/Apis/DescribeUEcFirewallResponse.php +++ b/src/UEC/Apis/DescribeUEcFirewallResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new FirewallInfo($item)); + array_push($result, new FirewallInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getFirewallSet() /** * FirewallSet: 防火墙组详细信息,参见 FirewallInfo * - * @param FirewallInfo[] $firewallSet + * @param FirewallInfoModel[] $firewallSet */ public function setFirewallSet(array $firewallSet) { @@ -55,7 +57,6 @@ public function setFirewallSet(array $firewallSet) } return $result; } - /** * TotalCount: 满足条件的节点总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UEC/Apis/DescribeUEcHolderIDCRequest.php b/src/UEC/Apis/DescribeUEcHolderIDCRequest.php index 198313e9..9756a052 100644 --- a/src/UEC/Apis/DescribeUEcHolderIDCRequest.php +++ b/src/UEC/Apis/DescribeUEcHolderIDCRequest.php @@ -1,6 +1,7 @@ markRequired("Memory"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Cpu: 容器组Cpu核数 * @@ -64,11 +64,10 @@ public function getCpu() * * @param float $cpu */ - public function setCpu($cpu) + public function setCpu(float $cpu) { $this->set("Cpu", $cpu); } - /** * Memory: 容器组内存大小(单位MB) * @@ -84,11 +83,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * IdcId: Idc机房id。默认全部机房 * @@ -108,7 +106,6 @@ public function setIdcId(array $idcId) { $this->set("IdcId", $idcId); } - /** * Type: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 * @@ -124,11 +121,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * ProductType: 产品类型,normal标准型,hf高性能型 * @@ -144,7 +140,7 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } diff --git a/src/UEC/Apis/DescribeUEcHolderIDCResponse.php b/src/UEC/Apis/DescribeUEcHolderIDCResponse.php index 871f865c..c4aab26c 100644 --- a/src/UEC/Apis/DescribeUEcHolderIDCResponse.php +++ b/src/UEC/Apis/DescribeUEcHolderIDCResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IdcInfo($item)); + array_push($result, new IdcInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getIdcList() /** * IdcList: 机房列表,具体参考下面IdcInfo * - * @param IdcInfo[] $idcList + * @param IdcInfoModel[] $idcList */ public function setIdcList(array $idcList) { diff --git a/src/UEC/Apis/DescribeUEcHolderRequest.php b/src/UEC/Apis/DescribeUEcHolderRequest.php index 1dc68734..dfdb4c90 100644 --- a/src/UEC/Apis/DescribeUEcHolderRequest.php +++ b/src/UEC/Apis/DescribeUEcHolderRequest.php @@ -1,6 +1,7 @@ "DescribeUEcHolder"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * HolderId: 容器组资源id * @@ -66,7 +66,6 @@ public function setHolderId(array $holderId) { $this->set("HolderId", $holderId); } - /** * Limit: 返回数据长度,默认为20,非负整数 * @@ -82,11 +81,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0。非负整数 * @@ -102,7 +100,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UEC/Apis/DescribeUEcHolderResponse.php b/src/UEC/Apis/DescribeUEcHolderResponse.php index cb387acc..d159c326 100644 --- a/src/UEC/Apis/DescribeUEcHolderResponse.php +++ b/src/UEC/Apis/DescribeUEcHolderResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new HolderList($item)); + array_push($result, new HolderListModel($item)); } return $result; } @@ -50,7 +52,7 @@ public function getHolderList() /** * HolderList: 容器组列表(详情参考HolderList) * - * @param HolderList[] $holderList + * @param HolderListModel[] $holderList */ public function setHolderList(array $holderList) { @@ -60,7 +62,6 @@ public function setHolderList(array $holderList) } return $result; } - /** * TotalCount: 满足条件的容器组总数 * @@ -76,7 +77,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UEC/Apis/DescribeUEcIDCRequest.php b/src/UEC/Apis/DescribeUEcIDCRequest.php index 40109173..6ea73f3e 100644 --- a/src/UEC/Apis/DescribeUEcIDCRequest.php +++ b/src/UEC/Apis/DescribeUEcIDCRequest.php @@ -1,6 +1,7 @@ markRequired("Memory"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Cpu: 节点cpu核数 * @@ -64,11 +64,10 @@ public function getCpu() * * @param int $cpu */ - public function setCpu($cpu) + public function setCpu(int $cpu) { $this->set("Cpu", $cpu); } - /** * Memory: 节点内存大小, 单位GB * @@ -84,11 +83,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * IdcId: Idc机房id。默认全部机房 * @@ -108,7 +106,6 @@ public function setIdcId(array $idcId) { $this->set("IdcId", $idcId); } - /** * Type: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 * @@ -124,13 +121,12 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** - * ProductType: 产品类型:normal(通用型),hf(高主频型) + * ProductType: 产品类型:normal(经济型),hf(标准型),g(GPU型) * * @return string|null */ @@ -140,12 +136,31 @@ public function getProductType() } /** - * ProductType: 产品类型:normal(通用型),hf(高主频型) + * ProductType: 产品类型:normal(经济型),hf(标准型),g(GPU型) * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } + /** + * Gpu: Gpu卡核心数 + * + * @return integer|null + */ + public function getGpu() + { + return $this->get("Gpu"); + } + + /** + * Gpu: Gpu卡核心数 + * + * @param int $gpu + */ + public function setGpu(int $gpu) + { + $this->set("Gpu", $gpu); + } } diff --git a/src/UEC/Apis/DescribeUEcIDCResponse.php b/src/UEC/Apis/DescribeUEcIDCResponse.php index 7159a602..8d1af8ad 100644 --- a/src/UEC/Apis/DescribeUEcIDCResponse.php +++ b/src/UEC/Apis/DescribeUEcIDCResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IdcInfo($item)); + array_push($result, new IdcInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getIdcList() /** * IdcList: 获取的机房信息,具体参考下面IdcInfo * - * @param IdcInfo[] $idcList + * @param IdcInfoModel[] $idcList */ public function setIdcList(array $idcList) { diff --git a/src/UEC/Apis/DescribeUEcSubnetRequest.php b/src/UEC/Apis/DescribeUEcSubnetRequest.php index 904a64b7..bbd9f215 100644 --- a/src/UEC/Apis/DescribeUEcSubnetRequest.php +++ b/src/UEC/Apis/DescribeUEcSubnetRequest.php @@ -1,6 +1,7 @@ "DescribeUEcSubnet"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: 机房ID * @@ -62,11 +62,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * SubnetId: 子网ID * @@ -82,7 +81,7 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } diff --git a/src/UEC/Apis/DescribeUEcSubnetResponse.php b/src/UEC/Apis/DescribeUEcSubnetResponse.php index e32ee79f..ec8ed7c4 100644 --- a/src/UEC/Apis/DescribeUEcSubnetResponse.php +++ b/src/UEC/Apis/DescribeUEcSubnetResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new SubnetInfo($item)); + array_push($result, new SubnetInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getSubnetList() /** * SubnetList: 子网信息列表 * - * @param SubnetInfo[] $subnetList + * @param SubnetInfoModel[] $subnetList */ public function setSubnetList(array $subnetList) { diff --git a/src/UEC/Apis/DescribeUEcVHostISPRequest.php b/src/UEC/Apis/DescribeUEcVHostISPRequest.php index b8dc3b57..26a9a0b1 100644 --- a/src/UEC/Apis/DescribeUEcVHostISPRequest.php +++ b/src/UEC/Apis/DescribeUEcVHostISPRequest.php @@ -1,6 +1,7 @@ "DescribeUEcVHostISP"]); } - /** * IspName: 运营商名称 @@ -42,11 +43,10 @@ public function getIspName() * * @param string $ispName */ - public function setIspName($ispName) + public function setIspName(string $ispName) { $this->set("IspName", $ispName); } - /** * Province: 省份 * @@ -62,11 +62,10 @@ public function getProvince() * * @param string $province */ - public function setProvince($province) + public function setProvince(string $province) { $this->set("Province", $province); } - /** * City: 城市 * @@ -82,7 +81,7 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } diff --git a/src/UEC/Apis/DescribeUEcVHostISPResponse.php b/src/UEC/Apis/DescribeUEcVHostISPResponse.php index 1ae20a20..0bac27c2 100644 --- a/src/UEC/Apis/DescribeUEcVHostISPResponse.php +++ b/src/UEC/Apis/DescribeUEcVHostISPResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NodeIspList($item)); + array_push($result, new NodeIspListModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getNodeIspList() /** * NodeIspList: 节点运营商列表 * - * @param NodeIspList[] $nodeIspList + * @param NodeIspListModel[] $nodeIspList */ public function setNodeIspList(array $nodeIspList) { diff --git a/src/UEC/Apis/DescribeUEcVHostRequest.php b/src/UEC/Apis/DescribeUEcVHostRequest.php index 8d064d7c..31b58e74 100644 --- a/src/UEC/Apis/DescribeUEcVHostRequest.php +++ b/src/UEC/Apis/DescribeUEcVHostRequest.php @@ -1,6 +1,7 @@ "DescribeUEcVHost"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: Idc机房id。默认全部机房 * @@ -66,7 +66,6 @@ public function setIdcId(array $idcId) { $this->set("IdcId", $idcId); } - /** * NodeId: 节点id,创建节点时生成的id。默认全部节点 * @@ -86,7 +85,6 @@ public function setNodeId(array $nodeId) { $this->set("NodeId", $nodeId); } - /** * Offset: 数据偏移量,默认0,非负整数 * @@ -102,11 +100,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认20,非负整数 * @@ -122,7 +119,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UEC/Apis/DescribeUEcVHostResponse.php b/src/UEC/Apis/DescribeUEcVHostResponse.php index f463be23..6ecb3d47 100644 --- a/src/UEC/Apis/DescribeUEcVHostResponse.php +++ b/src/UEC/Apis/DescribeUEcVHostResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * NodeList: 节点列表 * - * @return NodeInfo[]|null + * @return NodeInfoModel[]|null */ public function getNodeList() { @@ -57,7 +58,7 @@ public function getNodeList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NodeInfo($item)); + array_push($result, new NodeInfoModel($item)); } return $result; } @@ -65,7 +66,7 @@ public function getNodeList() /** * NodeList: 节点列表 * - * @param NodeInfo[] $nodeList + * @param NodeInfoModel[] $nodeList */ public function setNodeList(array $nodeList) { diff --git a/src/UEC/Apis/GetUEcHolderLogRequest.php b/src/UEC/Apis/GetUEcHolderLogRequest.php index 57b16cd0..50135c93 100644 --- a/src/UEC/Apis/GetUEcHolderLogRequest.php +++ b/src/UEC/Apis/GetUEcHolderLogRequest.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PackName: 容器名称 * @@ -64,11 +64,10 @@ public function getPackName() * * @param string $packName */ - public function setPackName($packName) + public function setPackName(string $packName) { $this->set("PackName", $packName); } - /** * ResourceId: 容器组资源id * @@ -84,7 +83,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UEC/Apis/GetUEcHolderLogResponse.php b/src/UEC/Apis/GetUEcHolderLogResponse.php index 95d76b04..9945cc3a 100644 --- a/src/UEC/Apis/GetUEcHolderLogResponse.php +++ b/src/UEC/Apis/GetUEcHolderLogResponse.php @@ -1,6 +1,7 @@ set("Data", $data); } diff --git a/src/UEC/Apis/GetUEcHolderMetricsRequest.php b/src/UEC/Apis/GetUEcHolderMetricsRequest.php index a7bcfc6c..9b833b22 100644 --- a/src/UEC/Apis/GetUEcHolderMetricsRequest.php +++ b/src/UEC/Apis/GetUEcHolderMetricsRequest.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PackName: 容器名称 * @@ -65,11 +65,10 @@ public function getPackName() * * @param string $packName */ - public function setPackName($packName) + public function setPackName(string $packName) { $this->set("PackName", $packName); } - /** * Type: n为0 CPU利用率, 1内存使用率, 2网卡出带宽, 3网卡入带宽, 4网卡出包数, 5网卡入包数 * @@ -89,7 +88,6 @@ public function setType(array $type) { $this->set("Type", $type); } - /** * ResourceId: 容器组资源id * @@ -105,11 +103,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * StartTime: 开始时间 * @@ -125,11 +122,10 @@ public function getStartTime() * * @param int $startTime */ - public function setStartTime($startTime) + public function setStartTime(int $startTime) { $this->set("StartTime", $startTime); } - /** * EndTime: 结束时间 * @@ -145,7 +141,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UEC/Apis/GetUEcHolderMetricsResponse.php b/src/UEC/Apis/GetUEcHolderMetricsResponse.php index 64522fac..b89fe9d8 100644 --- a/src/UEC/Apis/GetUEcHolderMetricsResponse.php +++ b/src/UEC/Apis/GetUEcHolderMetricsResponse.php @@ -1,6 +1,7 @@ get("DataSets")); + return new MetricisDataSetModel($this->get("DataSets")); } /** * DataSets: 获得的监控数据(详情参考MetricisDataSet) * - * @param MetricisDataSet $dataSets + * @param MetricisDataSetModel $dataSets */ - public function setDataSets(array $dataSets) + public function setDataSets(MetricisDataSetModel $dataSets) { $this->set("DataSets", $dataSets->getAll()); } diff --git a/src/UEC/Apis/GetUEcIDCCutInfoRequest.php b/src/UEC/Apis/GetUEcIDCCutInfoRequest.php index e6a60589..5ebf0dd0 100644 --- a/src/UEC/Apis/GetUEcIDCCutInfoRequest.php +++ b/src/UEC/Apis/GetUEcIDCCutInfoRequest.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IDCCutInfo($item)); + array_push($result, new IDCCutInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getIDCCutInfo() /** * IDCCutInfo: 机房割接信息 * - * @param IDCCutInfo[] $idcCutInfo + * @param IDCCutInfoModel[] $idcCutInfo */ public function setIDCCutInfo(array $idcCutInfo) { @@ -55,7 +57,6 @@ public function setIDCCutInfo(array $idcCutInfo) } return $result; } - /** * TotalCount: 满足条件的机房总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UEC/Apis/GetUEcIDCVHostDataRequest.php b/src/UEC/Apis/GetUEcIDCVHostDataRequest.php index 69a3e273..38d9387f 100644 --- a/src/UEC/Apis/GetUEcIDCVHostDataRequest.php +++ b/src/UEC/Apis/GetUEcIDCVHostDataRequest.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 节点资源id;n为0,1,2... * @@ -68,7 +68,6 @@ public function setNodeId(array $nodeId) { $this->set("NodeId", $nodeId); } - /** * Type: 监控数据类型;n为0,1,2,3,4...,9 * @@ -88,7 +87,6 @@ public function setType(array $type) { $this->set("Type", $type); } - /** * BeginTime: 开始时间戳 * @@ -104,11 +102,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 结束时间戳 * @@ -124,7 +121,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UEC/Apis/GetUEcIDCVHostDataResponse.php b/src/UEC/Apis/GetUEcIDCVHostDataResponse.php index aa5f2645..cd07bfd9 100644 --- a/src/UEC/Apis/GetUEcIDCVHostDataResponse.php +++ b/src/UEC/Apis/GetUEcIDCVHostDataResponse.php @@ -1,6 +1,7 @@ get("DataSets")); + return new DataSetModel($this->get("DataSets")); } /** * DataSets: 监控数据集合 * - * @param DataSet $dataSets + * @param DataSetModel $dataSets */ - public function setDataSets(array $dataSets) + public function setDataSets(DataSetModel $dataSets) { $this->set("DataSets", $dataSets->getAll()); } diff --git a/src/UEC/Apis/GetUEcImageRequest.php b/src/UEC/Apis/GetUEcImageRequest.php index 77e38e78..64c6a04d 100644 --- a/src/UEC/Apis/GetUEcImageRequest.php +++ b/src/UEC/Apis/GetUEcImageRequest.php @@ -1,6 +1,7 @@ "GetUEcImage"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageType: 镜像类型:1标准镜像,2行业镜像,3自定义镜像 * @@ -62,11 +62,10 @@ public function getImageType() * * @param string $imageType */ - public function setImageType($imageType) + public function setImageType(string $imageType) { $this->set("ImageType", $imageType); } - /** * Offset: 数据偏移量,默认0,非负整数 * @@ -82,11 +81,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认20,非负整数 * @@ -102,7 +100,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UEC/Apis/GetUEcImageResponse.php b/src/UEC/Apis/GetUEcImageResponse.php index 996c4019..417fb6a9 100644 --- a/src/UEC/Apis/GetUEcImageResponse.php +++ b/src/UEC/Apis/GetUEcImageResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ImageInfo($item)); + array_push($result, new ImageInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getImageList() /** * ImageList: 获取的镜像信息,具体参考下面ImageInfo * - * @param ImageInfo[] $imageList + * @param ImageInfoModel[] $imageList */ public function setImageList(array $imageList) { @@ -55,7 +57,6 @@ public function setImageList(array $imageList) } return $result; } - /** * TotalCount: 镜像总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UEC/Apis/GetUEcPodPriceRequest.php b/src/UEC/Apis/GetUEcPodPriceRequest.php index 0cd02d6a..55a7f7b9 100644 --- a/src/UEC/Apis/GetUEcPodPriceRequest.php +++ b/src/UEC/Apis/GetUEcPodPriceRequest.php @@ -1,6 +1,7 @@ markRequired("IdcId"); } - /** * IdcId: 机房id @@ -43,11 +44,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * CpuCore: 容器组总Cpu核心数 * @@ -63,11 +63,10 @@ public function getCpuCore() * * @param float $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(float $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 容器组总内存大小(单位M) * @@ -83,11 +82,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * ChargeType: 支付类型(2按月,3按年,默认2) * @@ -103,11 +101,10 @@ public function getChargeType() * * @param int $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(int $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ChargeQuantity: 月数或年数(默认值:1,当支付类型为按月时,默认值为0) * @@ -123,11 +120,10 @@ public function getChargeQuantity() * * @param int $chargeQuantity */ - public function setChargeQuantity($chargeQuantity) + public function setChargeQuantity(int $chargeQuantity) { $this->set("ChargeQuantity", $chargeQuantity); } - /** * ProductType: 产品类型(normal:标准型,hf:高性能型,默认:normal) * @@ -143,11 +139,10 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } - /** * ElasticIp: 是否绑定外网IP(yes:是,no:否,默认:no) * @@ -163,11 +158,10 @@ public function getElasticIp() * * @param string $elasticIp */ - public function setElasticIp($elasticIp) + public function setElasticIp(string $elasticIp) { $this->set("ElasticIp", $elasticIp); } - /** * Bandwidth: 绑定的带宽,默认0,当绑定外网IP时默认1(单位M) * @@ -183,7 +177,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UEC/Apis/GetUEcPodPriceResponse.php b/src/UEC/Apis/GetUEcPodPriceResponse.php index d51116f6..1e569c15 100644 --- a/src/UEC/Apis/GetUEcPodPriceResponse.php +++ b/src/UEC/Apis/GetUEcPodPriceResponse.php @@ -1,6 +1,7 @@ set("HolderPrice", $holderPrice); } - /** * IpPrice: IP和带宽价格 * @@ -57,7 +57,7 @@ public function getIpPrice() * * @param float $ipPrice */ - public function setIpPrice($ipPrice) + public function setIpPrice(float $ipPrice) { $this->set("IpPrice", $ipPrice); } diff --git a/src/UEC/Apis/GetUEcUpgradePriceRequest.php b/src/UEC/Apis/GetUEcUpgradePriceRequest.php index 9d5ea622..7ac412a0 100644 --- a/src/UEC/Apis/GetUEcUpgradePriceRequest.php +++ b/src/UEC/Apis/GetUEcUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 虚拟机资源ID * @@ -63,11 +63,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * CpuCore: cpu核心数 * @@ -83,11 +82,10 @@ public function getCpuCore() * * @param int $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(int $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 内存大小,单位GB * @@ -103,11 +101,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * SysDiskSize: 系统盘大小,单位GB * @@ -123,11 +120,10 @@ public function getSysDiskSize() * * @param int $sysDiskSize */ - public function setSysDiskSize($sysDiskSize) + public function setSysDiskSize(int $sysDiskSize) { $this->set("SysDiskSize", $sysDiskSize); } - /** * DiskSize: 数据盘大小,单位GB * @@ -143,11 +139,10 @@ public function getDiskSize() * * @param int $diskSize */ - public function setDiskSize($diskSize) + public function setDiskSize(int $diskSize) { $this->set("DiskSize", $diskSize); } - /** * NetLimit: 节点带宽限制,单位Mbs * @@ -163,7 +158,7 @@ public function getNetLimit() * * @param int $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(int $netLimit) { $this->set("NetLimit", $netLimit); } diff --git a/src/UEC/Apis/GetUEcUpgradePriceResponse.php b/src/UEC/Apis/GetUEcUpgradePriceResponse.php index d74d277e..9e446fa1 100644 --- a/src/UEC/Apis/GetUEcUpgradePriceResponse.php +++ b/src/UEC/Apis/GetUEcUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UEC/Apis/GetUEcVHostDataRequest.php b/src/UEC/Apis/GetUEcVHostDataRequest.php index c44c139b..c8488354 100644 --- a/src/UEC/Apis/GetUEcVHostDataRequest.php +++ b/src/UEC/Apis/GetUEcVHostDataRequest.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 节点id * @@ -64,11 +64,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * Type: 0CPU使用率, 1内存使用率, 2 网卡出流量, 3网卡入流量, 4网卡出包量, 5网卡入包量, 6磁盘读流量, 7磁盘写流量, 8磁盘读次数, 9磁盘写次数 * @@ -88,7 +87,6 @@ public function setType(array $type) { $this->set("Type", $type); } - /** * BeginTime: 查询起始时间 * @@ -104,11 +102,10 @@ public function getBeginTime() * * @param int $beginTime */ - public function setBeginTime($beginTime) + public function setBeginTime(int $beginTime) { $this->set("BeginTime", $beginTime); } - /** * EndTime: 查询结束时间 * @@ -124,7 +121,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UEC/Apis/GetUEcVHostDataResponse.php b/src/UEC/Apis/GetUEcVHostDataResponse.php index 823c7260..a1e0948c 100644 --- a/src/UEC/Apis/GetUEcVHostDataResponse.php +++ b/src/UEC/Apis/GetUEcVHostDataResponse.php @@ -1,6 +1,7 @@ get("DataSets")); + return new DataSetModel($this->get("DataSets")); } /** * DataSets: 带宽数据实例集合 * - * @param DataSet $dataSets + * @param DataSetModel $dataSets */ - public function setDataSets(array $dataSets) + public function setDataSets(DataSetModel $dataSets) { $this->set("DataSets", $dataSets->getAll()); } diff --git a/src/UEC/Apis/GetUEcVHostPriceRequest.php b/src/UEC/Apis/GetUEcVHostPriceRequest.php index 05b26a46..5e68219b 100644 --- a/src/UEC/Apis/GetUEcVHostPriceRequest.php +++ b/src/UEC/Apis/GetUEcVHostPriceRequest.php @@ -1,6 +1,7 @@ markRequired("IdcId"); } - /** * IdcId: 机房Id @@ -43,11 +44,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * NodeCount: 节点数量,默认1 * @@ -63,11 +63,10 @@ public function getNodeCount() * * @param int $nodeCount */ - public function setNodeCount($nodeCount) + public function setNodeCount(int $nodeCount) { $this->set("NodeCount", $nodeCount); } - /** * CpuCore: CPU核数 * @@ -83,11 +82,10 @@ public function getCpuCore() * * @param int $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(int $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 内存大小,单位GB * @@ -103,11 +101,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * SysDiskSize: 系统盘大小,单位GB * @@ -123,11 +120,10 @@ public function getSysDiskSize() * * @param int $sysDiskSize */ - public function setSysDiskSize($sysDiskSize) + public function setSysDiskSize(int $sysDiskSize) { $this->set("SysDiskSize", $sysDiskSize); } - /** * DiskSize: 数据盘大小,单位GB * @@ -143,11 +139,10 @@ public function getDiskSize() * * @param int $diskSize */ - public function setDiskSize($diskSize) + public function setDiskSize(int $diskSize) { $this->set("DiskSize", $diskSize); } - /** * NetLimit: 网络带宽限速,单位Mbs * @@ -163,11 +158,10 @@ public function getNetLimit() * * @param int $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(int $netLimit) { $this->set("NetLimit", $netLimit); } - /** * ChargeType: 付费方式,1按时,2按月,3按年,默认2 * @@ -183,11 +177,10 @@ public function getChargeType() * * @param int $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(int $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ChargeQuantity: 月数或者年数,0计费到月底, 默认0 * @@ -203,11 +196,10 @@ public function getChargeQuantity() * * @param int $chargeQuantity */ - public function setChargeQuantity($chargeQuantity) + public function setChargeQuantity(int $chargeQuantity) { $this->set("ChargeQuantity", $chargeQuantity); } - /** * ProductType: 产品类型:normal(经济型),hf(标准型),g(Gpu型),默认normal * @@ -223,11 +215,10 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } - /** * IpCount: 外网IP的数量,默认1 * @@ -243,11 +234,10 @@ public function getIpCount() * * @param int $ipCount */ - public function setIpCount($ipCount) + public function setIpCount(int $ipCount) { $this->set("IpCount", $ipCount); } - /** * Gpu: Gpu卡核心数。仅Gpu机型支持此字段 * @@ -263,11 +253,10 @@ public function getGpu() * * @param int $gpu */ - public function setGpu($gpu) + public function setGpu(int $gpu) { $this->set("Gpu", $gpu); } - /** * GpuType: Gpu类型,枚举值["T4"],ProductType为g时必填 * @@ -283,7 +272,7 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } diff --git a/src/UEC/Apis/GetUEcVHostPriceResponse.php b/src/UEC/Apis/GetUEcVHostPriceResponse.php index dc2fc64a..9dc6c547 100644 --- a/src/UEC/Apis/GetUEcVHostPriceResponse.php +++ b/src/UEC/Apis/GetUEcVHostPriceResponse.php @@ -1,6 +1,7 @@ set("NodePrice", $nodePrice); } - /** * IpPrice: Ip和带宽价格 * @@ -57,7 +57,7 @@ public function getIpPrice() * * @param float $ipPrice */ - public function setIpPrice($ipPrice) + public function setIpPrice(float $ipPrice) { $this->set("IpPrice", $ipPrice); } diff --git a/src/UEC/Apis/ImportUEcCustomImageRequest.php b/src/UEC/Apis/ImportUEcCustomImageRequest.php index d1488cfb..df3e816a 100644 --- a/src/UEC/Apis/ImportUEcCustomImageRequest.php +++ b/src/UEC/Apis/ImportUEcCustomImageRequest.php @@ -1,6 +1,7 @@ "ImportUEcCustomImage"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * IdcId: 镜像需要导入机房,默认分发到所有机房 * @@ -66,7 +66,6 @@ public function setIdcId(array $idcId) { $this->set("IdcId", $idcId); } - /** * ImageId: 镜像Id,不传参表示新导入镜像,传参表示已有镜像分发到指定机房 * @@ -82,11 +81,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * ImageName: 镜像名称,不带镜像ID时必填 * @@ -102,11 +100,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * UFileUrl: UFile镜像文件下载地址,不带镜像ID时必填 * @@ -122,11 +119,10 @@ public function getUFileUrl() * * @param string $uFileUrl */ - public function setUFileUrl($uFileUrl) + public function setUFileUrl(string $uFileUrl) { $this->set("UFileUrl", $uFileUrl); } - /** * OsType: 操作系统平台,linux、windows(当前版本暂不支持windows),不带镜像ID时必填 * @@ -142,11 +138,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * Format: 镜像格式,可选RAW、qcow2, 不带镜像ID时必填 * @@ -162,11 +157,10 @@ public function getFormat() * * @param string $format */ - public function setFormat($format) + public function setFormat(string $format) { $this->set("Format", $format); } - /** * ImageDesc: 镜像描述 * @@ -182,7 +176,7 @@ public function getImageDesc() * * @param string $imageDesc */ - public function setImageDesc($imageDesc) + public function setImageDesc(string $imageDesc) { $this->set("ImageDesc", $imageDesc); } diff --git a/src/UEC/Apis/ImportUEcCustomImageResponse.php b/src/UEC/Apis/ImportUEcCustomImageResponse.php index fab52374..31cf5e5f 100644 --- a/src/UEC/Apis/ImportUEcCustomImageResponse.php +++ b/src/UEC/Apis/ImportUEcCustomImageResponse.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } diff --git a/src/UEC/Apis/LoginUEcDockerRequest.php b/src/UEC/Apis/LoginUEcDockerRequest.php index 4cd5d5e2..1239b1f5 100644 --- a/src/UEC/Apis/LoginUEcDockerRequest.php +++ b/src/UEC/Apis/LoginUEcDockerRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ResourceId: 容器组资源id * @@ -64,11 +64,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * Name: 容器名称 * @@ -84,7 +83,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UEC/Apis/LoginUEcDockerResponse.php b/src/UEC/Apis/LoginUEcDockerResponse.php index 4f3257f7..b54ecd61 100644 --- a/src/UEC/Apis/LoginUEcDockerResponse.php +++ b/src/UEC/Apis/LoginUEcDockerResponse.php @@ -1,6 +1,7 @@ set("SessionId", $sessionId); } - /** * Link: 登录地址 * @@ -57,11 +57,10 @@ public function getLink() * * @param string $link */ - public function setLink($link) + public function setLink(string $link) { $this->set("Link", $link); } - /** * LinkPort: 登录端口 * @@ -77,7 +76,7 @@ public function getLinkPort() * * @param int $linkPort */ - public function setLinkPort($linkPort) + public function setLinkPort(int $linkPort) { $this->set("LinkPort", $linkPort); } diff --git a/src/UEC/Apis/ModifyUEcBandwidthRequest.php b/src/UEC/Apis/ModifyUEcBandwidthRequest.php index f120ebbf..9d2ed524 100644 --- a/src/UEC/Apis/ModifyUEcBandwidthRequest.php +++ b/src/UEC/Apis/ModifyUEcBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("NetLimit"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 节点Id * @@ -64,11 +64,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * NetLimit: 节点带宽限制,单位Mbs * @@ -84,7 +83,7 @@ public function getNetLimit() * * @param string $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(string $netLimit) { $this->set("NetLimit", $netLimit); } diff --git a/src/UEC/Apis/ModifyUEcBandwidthResponse.php b/src/UEC/Apis/ModifyUEcBandwidthResponse.php index 06c8c3ca..28f470af 100644 --- a/src/UEC/Apis/ModifyUEcBandwidthResponse.php +++ b/src/UEC/Apis/ModifyUEcBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ResourceId: 容器组资源id * @@ -64,11 +64,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * Name: 容器组名称 * @@ -84,7 +83,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UEC/Apis/ModifyUEcHolderNameResponse.php b/src/UEC/Apis/ModifyUEcHolderNameResponse.php index 5d52636c..37a13650 100644 --- a/src/UEC/Apis/ModifyUEcHolderNameResponse.php +++ b/src/UEC/Apis/ModifyUEcHolderNameResponse.php @@ -1,6 +1,7 @@ markRequired("ImageName"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageId: 镜像ID * @@ -64,11 +64,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * ImageName: 镜像名称 * @@ -84,11 +83,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * ImageDesc: 镜像描述 * @@ -104,7 +102,7 @@ public function getImageDesc() * * @param string $imageDesc */ - public function setImageDesc($imageDesc) + public function setImageDesc(string $imageDesc) { $this->set("ImageDesc", $imageDesc); } diff --git a/src/UEC/Apis/ModifyUEcImageNameResponse.php b/src/UEC/Apis/ModifyUEcImageNameResponse.php index 11c9c130..5ca88fc5 100644 --- a/src/UEC/Apis/ModifyUEcImageNameResponse.php +++ b/src/UEC/Apis/ModifyUEcImageNameResponse.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 虚拟机资源ID * diff --git a/src/UEC/Apis/PoweroffUEcVHostResponse.php b/src/UEC/Apis/PoweroffUEcVHostResponse.php index 0c7ede28..9f69a648 100644 --- a/src/UEC/Apis/PoweroffUEcVHostResponse.php +++ b/src/UEC/Apis/PoweroffUEcVHostResponse.php @@ -1,6 +1,7 @@ markRequired("ImageId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 虚拟机资源ID * @@ -64,11 +64,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * ImageId: 镜像ID * @@ -84,11 +83,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * KeepData: 是否保留数据盘数据, 0-不保留,1-保留,默认为1 * @@ -104,11 +102,10 @@ public function getKeepData() * * @param int $keepData */ - public function setKeepData($keepData) + public function setKeepData(int $keepData) { $this->set("KeepData", $keepData); } - /** * Password: 节点密码 * @@ -124,11 +121,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * SysDiskSize: 系统盘大小,单位GB * @@ -144,7 +140,7 @@ public function getSysDiskSize() * * @param int $sysDiskSize */ - public function setSysDiskSize($sysDiskSize) + public function setSysDiskSize(int $sysDiskSize) { $this->set("SysDiskSize", $sysDiskSize); } diff --git a/src/UEC/Apis/ReinstallUEcVHostResponse.php b/src/UEC/Apis/ReinstallUEcVHostResponse.php index 23d08d25..54becc4f 100644 --- a/src/UEC/Apis/ReinstallUEcVHostResponse.php +++ b/src/UEC/Apis/ReinstallUEcVHostResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ResourceId: 容器组资源id,n为0,1,2... * diff --git a/src/UEC/Apis/RestartUEcHolderResponse.php b/src/UEC/Apis/RestartUEcHolderResponse.php index c25806a0..0acdc863 100644 --- a/src/UEC/Apis/RestartUEcHolderResponse.php +++ b/src/UEC/Apis/RestartUEcHolderResponse.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 节点id * diff --git a/src/UEC/Apis/RestartUEcVHostResponse.php b/src/UEC/Apis/RestartUEcVHostResponse.php index 8b4cde44..41382576 100644 --- a/src/UEC/Apis/RestartUEcVHostResponse.php +++ b/src/UEC/Apis/RestartUEcVHostResponse.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 虚拟机资源ID * diff --git a/src/UEC/Apis/StartUEcVHostResponse.php b/src/UEC/Apis/StartUEcVHostResponse.php index c59aab15..9b048672 100644 --- a/src/UEC/Apis/StartUEcVHostResponse.php +++ b/src/UEC/Apis/StartUEcVHostResponse.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NodeId: 虚拟机资源ID * diff --git a/src/UEC/Apis/StopUEcVHostResponse.php b/src/UEC/Apis/StopUEcVHostResponse.php index 39f19059..3d9b70c6 100644 --- a/src/UEC/Apis/StopUEcVHostResponse.php +++ b/src/UEC/Apis/StopUEcVHostResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙Id * @@ -64,11 +64,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ResourceId: 节点Id或容器组资源id * @@ -84,7 +83,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UEC/Apis/UnBindUEcFirewallResponse.php b/src/UEC/Apis/UnBindUEcFirewallResponse.php index c919bca0..219806e3 100644 --- a/src/UEC/Apis/UnBindUEcFirewallResponse.php +++ b/src/UEC/Apis/UnBindUEcFirewallResponse.php @@ -1,6 +1,7 @@ markRequired("FirewallId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙Id * @@ -63,11 +63,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * Name: 防火墙名称 * @@ -83,11 +82,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 描述 * @@ -103,7 +101,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Apis/UpdateUEcFirewallAttributeResponse.php b/src/UEC/Apis/UpdateUEcFirewallAttributeResponse.php index 2913b413..cf1f1c01 100644 --- a/src/UEC/Apis/UpdateUEcFirewallAttributeResponse.php +++ b/src/UEC/Apis/UpdateUEcFirewallAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("FirewallId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FirewallId: 防火墙Id * @@ -64,15 +65,14 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * Rule: * - * @return UpdateUEcFirewallParamRule[]|null + * @return UpdateUEcFirewallRequestRuleModel[]|null */ public function getRule() { @@ -82,7 +82,7 @@ public function getRule() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UpdateUEcFirewallParamRule($item)); + array_push($result, new UpdateUEcFirewallRequestRuleModel($item)); } return $result; } @@ -90,7 +90,7 @@ public function getRule() /** * Rule: * - * @param UpdateUEcFirewallParamRule[] $rule + * @param UpdateUEcFirewallRequestRuleModel[] $rule */ public function setRule(array $rule) { diff --git a/src/UEC/Apis/UpdateUEcFirewallResponse.php b/src/UEC/Apis/UpdateUEcFirewallResponse.php index 1afe933c..d4e3dee9 100644 --- a/src/UEC/Apis/UpdateUEcFirewallResponse.php +++ b/src/UEC/Apis/UpdateUEcFirewallResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网ID * @@ -63,11 +63,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * SubnetName: 子网名称 * @@ -83,11 +82,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * Comment: 备注 * @@ -103,7 +101,7 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } diff --git a/src/UEC/Apis/UpdateUEcSubnetResponse.php b/src/UEC/Apis/UpdateUEcSubnetResponse.php index 33ec57fa..314d7499 100644 --- a/src/UEC/Apis/UpdateUEcSubnetResponse.php +++ b/src/UEC/Apis/UpdateUEcSubnetResponse.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * MountPath: 挂载路径 * @@ -57,11 +62,10 @@ public function getMountPath() * * @param string $mountPath */ - public function setMountPath($mountPath) + public function setMountPath(string $mountPath) { $this->set("MountPath", $mountPath); } - /** * ResourceId: 资源id * @@ -77,7 +81,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UEC/Params/CreateUEcFirewallParamRule.php b/src/UEC/Models/CreateUEcFirewallRequestRule.php similarity index 83% rename from src/UEC/Params/CreateUEcFirewallParamRule.php rename to src/UEC/Models/CreateUEcFirewallRequestRule.php index 32f73f2b..1a6cc94f 100644 --- a/src/UEC/Params/CreateUEcFirewallParamRule.php +++ b/src/UEC/Models/CreateUEcFirewallRequestRule.php @@ -1,6 +1,7 @@ set("ProtocolType", $protocolType); } - /** * Port: 端口,范围用"-"符号分隔,如:1-65535 * @@ -57,11 +59,10 @@ public function getPort() * * @param string $port */ - public function setPort($port) + public function setPort(string $port) { $this->set("Port", $port); } - /** * SrcIp: 源ip * @@ -77,11 +78,10 @@ public function getSrcIp() * * @param string $srcIp */ - public function setSrcIp($srcIp) + public function setSrcIp(string $srcIp) { $this->set("SrcIp", $srcIp); } - /** * Action: ACCEPT(接受)和DROP(拒绝) * @@ -97,11 +97,10 @@ public function getAction() * * @param string $action */ - public function setAction($action) + public function setAction(string $action) { $this->set("Action", $action); } - /** * Priority: 优先级:HIGH(高),MEDIUM(中),LOW(低) * @@ -117,11 +116,10 @@ public function getPriority() * * @param string $priority */ - public function setPriority($priority) + public function setPriority(string $priority) { $this->set("Priority", $priority); } - /** * Remark: 备注 * @@ -137,7 +135,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Params/CreateUEcHolderParamImage.php b/src/UEC/Models/CreateUEcHolderRequestImage.php similarity index 80% rename from src/UEC/Params/CreateUEcHolderParamImage.php rename to src/UEC/Models/CreateUEcHolderRequestImage.php index 57a6644a..1742412b 100644 --- a/src/UEC/Params/CreateUEcHolderParamImage.php +++ b/src/UEC/Models/CreateUEcHolderRequestImage.php @@ -1,6 +1,7 @@ set("Message", $message); } - /** * StoreAddress: 镜像仓库地址 * @@ -57,7 +59,7 @@ public function getStoreAddress() * * @param string $storeAddress */ - public function setStoreAddress($storeAddress) + public function setStoreAddress(string $storeAddress) { $this->set("StoreAddress", $storeAddress); } diff --git a/src/UEC/Params/CreateUEcHolderParamPack.php b/src/UEC/Models/CreateUEcHolderRequestPack.php similarity index 85% rename from src/UEC/Params/CreateUEcHolderParamPack.php rename to src/UEC/Models/CreateUEcHolderRequestPack.php index 6a050c9b..e689e88a 100644 --- a/src/UEC/Params/CreateUEcHolderParamPack.php +++ b/src/UEC/Models/CreateUEcHolderRequestPack.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * CpuCore: 容器Cpu核数 * @@ -57,11 +59,10 @@ public function getCpuCore() * * @param float $cpuCore */ - public function setCpuCore($cpuCore) + public function setCpuCore(float $cpuCore) { $this->set("CpuCore", $cpuCore); } - /** * MemSize: 容器内存,单位MB * @@ -77,11 +78,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * ImageName: 容器镜像名称 * @@ -97,11 +97,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * WorkDir: 容器工作目录 * @@ -117,11 +116,10 @@ public function getWorkDir() * * @param string $workDir */ - public function setWorkDir($workDir) + public function setWorkDir(string $workDir) { $this->set("WorkDir", $workDir); } - /** * Cmd: 开启容器的命令 * @@ -137,11 +135,10 @@ public function getCmd() * * @param string $cmd */ - public function setCmd($cmd) + public function setCmd(string $cmd) { $this->set("Cmd", $cmd); } - /** * Args: 容器参数(多个用;隔开) * @@ -157,11 +154,10 @@ public function getArgs() * * @param string $args */ - public function setArgs($args) + public function setArgs(string $args) { $this->set("Args", $args); } - /** * Environment: 容器环境变量(多个用;隔开,如:key1:value1;key2:value2) * @@ -177,11 +173,10 @@ public function getEnvironment() * * @param string $environment */ - public function setEnvironment($environment) + public function setEnvironment(string $environment) { $this->set("Environment", $environment); } - /** * ConfigDict: 容器配置字典(多个用;隔开,如:/data1:resId1;/data2:resId2) * @@ -197,7 +192,7 @@ public function getConfigDict() * * @param string $configDict */ - public function setConfigDict($configDict) + public function setConfigDict(string $configDict) { $this->set("ConfigDict", $configDict); } diff --git a/src/UEC/Params/CreateUEcHolderParamStorage.php b/src/UEC/Models/CreateUEcHolderRequestStorage.php similarity index 79% rename from src/UEC/Params/CreateUEcHolderParamStorage.php rename to src/UEC/Models/CreateUEcHolderRequestStorage.php index 7ed2e6fd..ea125e2b 100644 --- a/src/UEC/Params/CreateUEcHolderParamStorage.php +++ b/src/UEC/Models/CreateUEcHolderRequestStorage.php @@ -1,6 +1,7 @@ set("Path", $path); } - /** * ResourceId: 存储卷资源id * @@ -57,7 +59,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UEC/Models/DataSet.php b/src/UEC/Models/DataSet.php index fba6373f..febfd8eb 100644 --- a/src/UEC/Models/DataSet.php +++ b/src/UEC/Models/DataSet.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -43,7 +48,7 @@ public function getCPUUtilization() /** * CPUUtilization: cpu使用率 * - * @param MonitorInfo[] $cpuUtilization + * @param MonitorInfoModel[] $cpuUtilization */ public function setCPUUtilization(array $cpuUtilization) { @@ -53,11 +58,10 @@ public function setCPUUtilization(array $cpuUtilization) } return $result; } - /** * MemUtilization: 内存使用率 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getMemUtilization() { @@ -67,7 +71,7 @@ public function getMemUtilization() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -75,7 +79,7 @@ public function getMemUtilization() /** * MemUtilization: 内存使用率 * - * @param MonitorInfo[] $memUtilization + * @param MonitorInfoModel[] $memUtilization */ public function setMemUtilization(array $memUtilization) { @@ -85,11 +89,10 @@ public function setMemUtilization(array $memUtilization) } return $result; } - /** * NICOut: 网卡出带宽 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNICOut() { @@ -99,7 +102,7 @@ public function getNICOut() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -107,7 +110,7 @@ public function getNICOut() /** * NICOut: 网卡出带宽 * - * @param MonitorInfo[] $nicOut + * @param MonitorInfoModel[] $nicOut */ public function setNICOut(array $nicOut) { @@ -117,11 +120,10 @@ public function setNICOut(array $nicOut) } return $result; } - /** * NICIn: 网卡入带宽 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNICIn() { @@ -131,7 +133,7 @@ public function getNICIn() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -139,7 +141,7 @@ public function getNICIn() /** * NICIn: 网卡入带宽 * - * @param MonitorInfo[] $nicIn + * @param MonitorInfoModel[] $nicIn */ public function setNICIn(array $nicIn) { @@ -149,11 +151,10 @@ public function setNICIn(array $nicIn) } return $result; } - /** * NetPacketOut: 网卡出包量 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNetPacketOut() { @@ -163,7 +164,7 @@ public function getNetPacketOut() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -171,7 +172,7 @@ public function getNetPacketOut() /** * NetPacketOut: 网卡出包量 * - * @param MonitorInfo[] $netPacketOut + * @param MonitorInfoModel[] $netPacketOut */ public function setNetPacketOut(array $netPacketOut) { @@ -181,11 +182,10 @@ public function setNetPacketOut(array $netPacketOut) } return $result; } - /** * NetPacketIn: 网卡入包量 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNetPacketIn() { @@ -195,7 +195,7 @@ public function getNetPacketIn() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -203,7 +203,7 @@ public function getNetPacketIn() /** * NetPacketIn: 网卡入包量 * - * @param MonitorInfo[] $netPacketIn + * @param MonitorInfoModel[] $netPacketIn */ public function setNetPacketIn(array $netPacketIn) { @@ -213,11 +213,10 @@ public function setNetPacketIn(array $netPacketIn) } return $result; } - /** * IORead: 磁盘读取量 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getIORead() { @@ -227,7 +226,7 @@ public function getIORead() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -235,7 +234,7 @@ public function getIORead() /** * IORead: 磁盘读取量 * - * @param MonitorInfo[] $ioRead + * @param MonitorInfoModel[] $ioRead */ public function setIORead(array $ioRead) { @@ -245,11 +244,10 @@ public function setIORead(array $ioRead) } return $result; } - /** * IOWrite: 磁盘写入量 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getIOWrite() { @@ -259,7 +257,7 @@ public function getIOWrite() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -267,7 +265,7 @@ public function getIOWrite() /** * IOWrite: 磁盘写入量 * - * @param MonitorInfo[] $ioWrite + * @param MonitorInfoModel[] $ioWrite */ public function setIOWrite(array $ioWrite) { @@ -277,11 +275,10 @@ public function setIOWrite(array $ioWrite) } return $result; } - /** * DiskReadOps: 磁盘读取次数 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getDiskReadOps() { @@ -291,7 +288,7 @@ public function getDiskReadOps() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -299,7 +296,7 @@ public function getDiskReadOps() /** * DiskReadOps: 磁盘读取次数 * - * @param MonitorInfo[] $diskReadOps + * @param MonitorInfoModel[] $diskReadOps */ public function setDiskReadOps(array $diskReadOps) { @@ -309,11 +306,10 @@ public function setDiskReadOps(array $diskReadOps) } return $result; } - /** * DiskWriteOps: 磁盘写入次数 * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getDiskWriteOps() { @@ -323,7 +319,7 @@ public function getDiskWriteOps() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -331,7 +327,7 @@ public function getDiskWriteOps() /** * DiskWriteOps: 磁盘写入次数 * - * @param MonitorInfo[] $diskWriteOps + * @param MonitorInfoModel[] $diskWriteOps */ public function setDiskWriteOps(array $diskWriteOps) { diff --git a/src/UEC/Models/DeployImageInfo.php b/src/UEC/Models/DeployImageInfo.php index 5ddefa45..3a453236 100644 --- a/src/UEC/Models/DeployImageInfo.php +++ b/src/UEC/Models/DeployImageInfo.php @@ -1,6 +1,7 @@ set("IdcId", $idcId); } - /** * State: 镜像状态 1-可用, 2-不可用, 3-获取中, 4-转换中, 5-部署中 * @@ -57,7 +60,7 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } diff --git a/src/UEC/Models/DockerInfo.php b/src/UEC/Models/DockerInfo.php index f1d198ec..c754376a 100644 --- a/src/UEC/Models/DockerInfo.php +++ b/src/UEC/Models/DockerInfo.php @@ -1,6 +1,7 @@ set("CpuCores", $cpuCores); } - /** * MemSize: 内存大小(Gi) * @@ -57,11 +63,10 @@ public function getMemSize() * * @param float $memSize */ - public function setMemSize($memSize) + public function setMemSize(float $memSize) { $this->set("MemSize", $memSize); } - /** * Name: 容器名称 * @@ -77,11 +82,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * State: 容器状态,0:初始化;1:拉取镜像;2:拉取镜像失败;3:启动中;4:运行中;5:正在停止;6:已停止;7:已删除;8:镜像拉取成功;9:启动失败;99:异常 * @@ -97,11 +101,10 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } - /** * ImageName: 镜像名称 * @@ -117,11 +120,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * WorkDir: 工作目录 * @@ -137,11 +139,10 @@ public function getWorkDir() * * @param string $workDir */ - public function setWorkDir($workDir) + public function setWorkDir(string $workDir) { $this->set("WorkDir", $workDir); } - /** * Command: 命令 * @@ -157,11 +158,10 @@ public function getCommand() * * @param string $command */ - public function setCommand($command) + public function setCommand(string $command) { $this->set("Command", $command); } - /** * Args: 参数 * @@ -177,15 +177,14 @@ public function getArgs() * * @param string $args */ - public function setArgs($args) + public function setArgs(string $args) { $this->set("Args", $args); } - /** * EnvList: 环境变量(详情参考EnvList) * - * @return EnvList[]|null + * @return EnvListModel[]|null */ public function getEnvList() { @@ -195,7 +194,7 @@ public function getEnvList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EnvList($item)); + array_push($result, new EnvListModel($item)); } return $result; } @@ -203,7 +202,7 @@ public function getEnvList() /** * EnvList: 环境变量(详情参考EnvList) * - * @param EnvList[] $envList + * @param EnvListModel[] $envList */ public function setEnvList(array $envList) { @@ -213,11 +212,10 @@ public function setEnvList(array $envList) } return $result; } - /** * CfgDictList: 容器配置字典(详情参考CfgDictList) * - * @return CfgDictList[]|null + * @return CfgDictListModel[]|null */ public function getCfgDictList() { @@ -227,7 +225,7 @@ public function getCfgDictList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CfgDictList($item)); + array_push($result, new CfgDictListModel($item)); } return $result; } @@ -235,7 +233,7 @@ public function getCfgDictList() /** * CfgDictList: 容器配置字典(详情参考CfgDictList) * - * @param CfgDictList[] $cfgDictList + * @param CfgDictListModel[] $cfgDictList */ public function setCfgDictList(array $cfgDictList) { diff --git a/src/UEC/Models/EnvList.php b/src/UEC/Models/EnvList.php index 7e88ef2d..f2f3c169 100644 --- a/src/UEC/Models/EnvList.php +++ b/src/UEC/Models/EnvList.php @@ -1,6 +1,7 @@ set("Key", $key); } - /** * Value: 环境变量Value值 * @@ -57,7 +62,7 @@ public function getValue() * * @param string $value */ - public function setValue($value) + public function setValue(string $value) { $this->set("Value", $value); } diff --git a/src/UEC/Models/FirewallInfo.php b/src/UEC/Models/FirewallInfo.php index 1f2513cd..cbc92739 100644 --- a/src/UEC/Models/FirewallInfo.php +++ b/src/UEC/Models/FirewallInfo.php @@ -1,6 +1,7 @@ set("FirewallId", $firewallId); } - /** * Name: 防火墙名称 * @@ -57,11 +60,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * CreateTime: 创建时间 * @@ -77,15 +79,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Rule: 防火墙规则组,详情参见RuleInfo * - * @return RuleInfo[]|null + * @return RuleInfoModel[]|null */ public function getRule() { @@ -95,7 +96,7 @@ public function getRule() } $result = []; foreach ($items as $i => $item) { - array_push($result, new RuleInfo($item)); + array_push($result, new RuleInfoModel($item)); } return $result; } @@ -103,7 +104,7 @@ public function getRule() /** * Rule: 防火墙规则组,详情参见RuleInfo * - * @param RuleInfo[] $rule + * @param RuleInfoModel[] $rule */ public function setRule(array $rule) { @@ -113,7 +114,6 @@ public function setRule(array $rule) } return $result; } - /** * ResourceCount: 防火墙绑定资源数量 * @@ -129,11 +129,10 @@ public function getResourceCount() * * @param int $resourceCount */ - public function setResourceCount($resourceCount) + public function setResourceCount(int $resourceCount) { $this->set("ResourceCount", $resourceCount); } - /** * Type: 防火墙组类型,枚举值为: "user defined", 用户自定义防火墙; "recommend web", 默认Web防火墙; "recommend non web", 默认非Web防火墙 * @@ -149,11 +148,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Remark: 描述 * @@ -169,7 +167,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Models/HolderList.php b/src/UEC/Models/HolderList.php index 5c8be3b4..1d5caf8c 100644 --- a/src/UEC/Models/HolderList.php +++ b/src/UEC/Models/HolderList.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * HolderName: 容器组名称 * @@ -57,11 +66,10 @@ public function getHolderName() * * @param string $holderName */ - public function setHolderName($holderName) + public function setHolderName(string $holderName) { $this->set("HolderName", $holderName); } - /** * SubnetId: 容器组子网id * @@ -77,11 +85,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * InnerIp: 容器组内网ip * @@ -97,15 +104,14 @@ public function getInnerIp() * * @param string $innerIp */ - public function setInnerIp($innerIp) + public function setInnerIp(string $innerIp) { $this->set("InnerIp", $innerIp); } - /** * IpList: 容器组外网ip集合(详情参考IpList) * - * @return IpList[]|null + * @return IpListModel[]|null */ public function getIpList() { @@ -115,7 +121,7 @@ public function getIpList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new IpList($item)); + array_push($result, new IpListModel($item)); } return $result; } @@ -123,7 +129,7 @@ public function getIpList() /** * IpList: 容器组外网ip集合(详情参考IpList) * - * @param IpList[] $ipList + * @param IpListModel[] $ipList */ public function setIpList(array $ipList) { @@ -133,7 +139,6 @@ public function setIpList(array $ipList) } return $result; } - /** * State: 容器组运行状态0:初始化;1:拉取镜像;2:启动中;3:运行中;4:错误;5:正在重启;6:正在删除;7:已经删除;8:容器运行错误;9:启动失败;99:异常 * @@ -149,11 +154,10 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } - /** * CreateTime: 创建时间 * @@ -169,11 +173,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 过期时间 * @@ -189,11 +192,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Type: 线路类型(运营商类型: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通) * @@ -209,11 +211,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * IdcId: 机房id * @@ -229,11 +230,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * OcName: 机房名称 * @@ -249,11 +249,10 @@ public function getOcName() * * @param string $ocName */ - public function setOcName($ocName) + public function setOcName(string $ocName) { $this->set("OcName", $ocName); } - /** * Province: 省份名称 * @@ -269,11 +268,10 @@ public function getProvince() * * @param string $province */ - public function setProvince($province) + public function setProvince(string $province) { $this->set("Province", $province); } - /** * City: 城市名称 * @@ -289,11 +287,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * RestartStrategy: 0:总是;1:失败是;2:永不 * @@ -309,11 +306,10 @@ public function getRestartStrategy() * * @param int $restartStrategy */ - public function setRestartStrategy($restartStrategy) + public function setRestartStrategy(int $restartStrategy) { $this->set("RestartStrategy", $restartStrategy); } - /** * DockerCount: 容器数量 * @@ -329,15 +325,14 @@ public function getDockerCount() * * @param int $dockerCount */ - public function setDockerCount($dockerCount) + public function setDockerCount(int $dockerCount) { $this->set("DockerCount", $dockerCount); } - /** * DockerInfo: 容器信息(详情参考DockerInfo) * - * @return DockerInfo[]|null + * @return DockerInfoModel[]|null */ public function getDockerInfo() { @@ -347,7 +342,7 @@ public function getDockerInfo() } $result = []; foreach ($items as $i => $item) { - array_push($result, new DockerInfo($item)); + array_push($result, new DockerInfoModel($item)); } return $result; } @@ -355,7 +350,7 @@ public function getDockerInfo() /** * DockerInfo: 容器信息(详情参考DockerInfo) * - * @param DockerInfo[] $dockerInfo + * @param DockerInfoModel[] $dockerInfo */ public function setDockerInfo(array $dockerInfo) { @@ -365,7 +360,6 @@ public function setDockerInfo(array $dockerInfo) } return $result; } - /** * ProductType: 机器类型(normal经济型,hf标准型) * @@ -381,11 +375,10 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } - /** * NetLimit: 外网绑定的带宽 * @@ -401,11 +394,10 @@ public function getNetLimit() * * @param int $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(int $netLimit) { $this->set("NetLimit", $netLimit); } - /** * FirewallId: 外网防火墙id * @@ -421,15 +413,14 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * StorVolumeInfo: 存储卷信息(详情参考StorVolumeInfo) * - * @return StorVolumeInfo[]|null + * @return StorVolumeInfoModel[]|null */ public function getStorVolumeInfo() { @@ -439,7 +430,7 @@ public function getStorVolumeInfo() } $result = []; foreach ($items as $i => $item) { - array_push($result, new StorVolumeInfo($item)); + array_push($result, new StorVolumeInfoModel($item)); } return $result; } @@ -447,7 +438,7 @@ public function getStorVolumeInfo() /** * StorVolumeInfo: 存储卷信息(详情参考StorVolumeInfo) * - * @param StorVolumeInfo[] $storVolumeInfo + * @param StorVolumeInfoModel[] $storVolumeInfo */ public function setStorVolumeInfo(array $storVolumeInfo) { @@ -457,7 +448,6 @@ public function setStorVolumeInfo(array $storVolumeInfo) } return $result; } - /** * StorVolumeCount: 存储卷数量 * @@ -473,15 +463,14 @@ public function getStorVolumeCount() * * @param int $storVolumeCount */ - public function setStorVolumeCount($storVolumeCount) + public function setStorVolumeCount(int $storVolumeCount) { $this->set("StorVolumeCount", $storVolumeCount); } - /** * ImageList: 容器组镜像密钥列表(详情参考ImageList) * - * @return ImageList[]|null + * @return ImageListModel[]|null */ public function getImageList() { @@ -491,7 +480,7 @@ public function getImageList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ImageList($item)); + array_push($result, new ImageListModel($item)); } return $result; } @@ -499,7 +488,7 @@ public function getImageList() /** * ImageList: 容器组镜像密钥列表(详情参考ImageList) * - * @param ImageList[] $imageList + * @param ImageListModel[] $imageList */ public function setImageList(array $imageList) { diff --git a/src/UEC/Models/IDCCutInfo.php b/src/UEC/Models/IDCCutInfo.php index 74a1392e..a8fafb64 100644 --- a/src/UEC/Models/IDCCutInfo.php +++ b/src/UEC/Models/IDCCutInfo.php @@ -1,6 +1,7 @@ set("IDCName", $idcName); } - /** * Province: 省份 * @@ -57,11 +60,10 @@ public function getProvince() * * @param string $province */ - public function setProvince($province) + public function setProvince(string $province) { $this->set("Province", $province); } - /** * City: 城市 * @@ -77,11 +79,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * StartTime: 割接开始时间 * @@ -97,11 +98,10 @@ public function getStartTime() * * @param int $startTime */ - public function setStartTime($startTime) + public function setStartTime(int $startTime) { $this->set("StartTime", $startTime); } - /** * EndTime: 割接结束时间 * @@ -117,11 +117,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * CutType: 割接类型(中断、抖动、断电) * @@ -137,15 +136,14 @@ public function getCutType() * * @param string $cutType */ - public function setCutType($cutType) + public function setCutType(string $cutType) { $this->set("CutType", $cutType); } - /** * ResourceSet: 受影响的资源信息列表 * - * @return ResourceSet[]|null + * @return ResourceSetModel[]|null */ public function getResourceSet() { @@ -155,7 +153,7 @@ public function getResourceSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ResourceSet($item)); + array_push($result, new ResourceSetModel($item)); } return $result; } @@ -163,7 +161,7 @@ public function getResourceSet() /** * ResourceSet: 受影响的资源信息列表 * - * @param ResourceSet[] $resourceSet + * @param ResourceSetModel[] $resourceSet */ public function setResourceSet(array $resourceSet) { diff --git a/src/UEC/Models/IdcInfo.php b/src/UEC/Models/IdcInfo.php index 5eb785b0..af2f1f53 100644 --- a/src/UEC/Models/IdcInfo.php +++ b/src/UEC/Models/IdcInfo.php @@ -1,6 +1,7 @@ set("IdcId", $idcId); } - /** * Name: 机房名称 * @@ -57,11 +60,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Isp: 运营商 * @@ -77,11 +79,10 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } - /** * Province: 省份 * @@ -97,11 +98,10 @@ public function getProvince() * * @param string $province */ - public function setProvince($province) + public function setProvince(string $province) { $this->set("Province", $province); } - /** * City: 城市 * @@ -117,11 +117,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * Type: 运营商类型:0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 * @@ -137,11 +136,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * MaxNodeCnt: 机房可创建节点最大数量 * @@ -157,7 +155,7 @@ public function getMaxNodeCnt() * * @param int $maxNodeCnt */ - public function setMaxNodeCnt($maxNodeCnt) + public function setMaxNodeCnt(int $maxNodeCnt) { $this->set("MaxNodeCnt", $maxNodeCnt); } diff --git a/src/UEC/Models/ImageInfo.php b/src/UEC/Models/ImageInfo.php index 8b3c4e7f..218bc543 100644 --- a/src/UEC/Models/ImageInfo.php +++ b/src/UEC/Models/ImageInfo.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } - /** * ImageName: 镜像名称 * @@ -57,11 +60,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * ImageType: 镜像类型:1标准镜像,2行业镜像,3自定义镜像 * @@ -77,11 +79,10 @@ public function getImageType() * * @param int $imageType */ - public function setImageType($imageType) + public function setImageType(int $imageType) { $this->set("ImageType", $imageType); } - /** * OcType: 系统类型:unix, windows * @@ -97,11 +98,10 @@ public function getOcType() * * @param string $ocType */ - public function setOcType($ocType) + public function setOcType(string $ocType) { $this->set("OcType", $ocType); } - /** * ImageDesc: 镜像描述 * @@ -117,11 +117,10 @@ public function getImageDesc() * * @param string $imageDesc */ - public function setImageDesc($imageDesc) + public function setImageDesc(string $imageDesc) { $this->set("ImageDesc", $imageDesc); } - /** * State: 镜像状态:镜像状态 1可用,2不可用,3制作中 * @@ -137,11 +136,10 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } - /** * ImageSize: 镜像大小,单位GB * @@ -157,11 +155,10 @@ public function getImageSize() * * @param int $imageSize */ - public function setImageSize($imageSize) + public function setImageSize(int $imageSize) { $this->set("ImageSize", $imageSize); } - /** * CreateTime: 镜像创建时间戳 * @@ -177,15 +174,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * DeployInfoList: 部署详情列表 * - * @return DeployImageInfo[]|null + * @return DeployImageInfoModel[]|null */ public function getDeployInfoList() { @@ -195,7 +191,7 @@ public function getDeployInfoList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new DeployImageInfo($item)); + array_push($result, new DeployImageInfoModel($item)); } return $result; } @@ -203,7 +199,7 @@ public function getDeployInfoList() /** * DeployInfoList: 部署详情列表 * - * @param DeployImageInfo[] $deployInfoList + * @param DeployImageInfoModel[] $deployInfoList */ public function setDeployInfoList(array $deployInfoList) { @@ -213,7 +209,6 @@ public function setDeployInfoList(array $deployInfoList) } return $result; } - /** * Gpu: 是否支持Gpu(1-支持,0-不支持) * @@ -229,7 +224,7 @@ public function getGpu() * * @param int $gpu */ - public function setGpu($gpu) + public function setGpu(int $gpu) { $this->set("Gpu", $gpu); } diff --git a/src/UEC/Models/ImageList.php b/src/UEC/Models/ImageList.php index 8d4fe79f..9a624b60 100644 --- a/src/UEC/Models/ImageList.php +++ b/src/UEC/Models/ImageList.php @@ -1,6 +1,7 @@ set("StoreAddr", $storeAddr); } - /** * UserName: 用户名称 * @@ -57,11 +61,10 @@ public function getUserName() * * @param string $userName */ - public function setUserName($userName) + public function setUserName(string $userName) { $this->set("UserName", $userName); } - /** * ImageKey: 镜像密钥 * @@ -77,7 +80,7 @@ public function getImageKey() * * @param string $imageKey */ - public function setImageKey($imageKey) + public function setImageKey(string $imageKey) { $this->set("ImageKey", $imageKey); } diff --git a/src/UEC/Models/IpList.php b/src/UEC/Models/IpList.php index ca6db8cb..02c0037b 100644 --- a/src/UEC/Models/IpList.php +++ b/src/UEC/Models/IpList.php @@ -1,6 +1,7 @@ set("Ip", $ip); } - /** * Isp: 运营商 * @@ -57,7 +61,7 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } diff --git a/src/UEC/Models/MetricisDataSet.php b/src/UEC/Models/MetricisDataSet.php index ee72fb3d..12681a47 100644 --- a/src/UEC/Models/MetricisDataSet.php +++ b/src/UEC/Models/MetricisDataSet.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -43,7 +47,7 @@ public function getCPUUtilization() /** * CPUUtilization: cpu利用率(详情参考MonitorInfo) * - * @param MonitorInfo[] $cpuUtilization + * @param MonitorInfoModel[] $cpuUtilization */ public function setCPUUtilization(array $cpuUtilization) { @@ -53,11 +57,10 @@ public function setCPUUtilization(array $cpuUtilization) } return $result; } - /** * MemUtilization: 内存使用率(详情参考MonitorInfo) * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getMemUtilization() { @@ -67,7 +70,7 @@ public function getMemUtilization() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -75,7 +78,7 @@ public function getMemUtilization() /** * MemUtilization: 内存使用率(详情参考MonitorInfo) * - * @param MonitorInfo[] $memUtilization + * @param MonitorInfoModel[] $memUtilization */ public function setMemUtilization(array $memUtilization) { @@ -85,11 +88,10 @@ public function setMemUtilization(array $memUtilization) } return $result; } - /** * NetPacketOut: 网卡出包数(详情参考MonitorInfo) * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNetPacketOut() { @@ -99,7 +101,7 @@ public function getNetPacketOut() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -107,7 +109,7 @@ public function getNetPacketOut() /** * NetPacketOut: 网卡出包数(详情参考MonitorInfo) * - * @param MonitorInfo[] $netPacketOut + * @param MonitorInfoModel[] $netPacketOut */ public function setNetPacketOut(array $netPacketOut) { @@ -117,11 +119,10 @@ public function setNetPacketOut(array $netPacketOut) } return $result; } - /** * NetPacketIn: 网卡入包数(详情参考MonitorInfo) * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNetPacketIn() { @@ -131,7 +132,7 @@ public function getNetPacketIn() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -139,7 +140,7 @@ public function getNetPacketIn() /** * NetPacketIn: 网卡入包数(详情参考MonitorInfo) * - * @param MonitorInfo[] $netPacketIn + * @param MonitorInfoModel[] $netPacketIn */ public function setNetPacketIn(array $netPacketIn) { @@ -149,11 +150,10 @@ public function setNetPacketIn(array $netPacketIn) } return $result; } - /** * NICOut: 网卡出带宽(详情参考MonitorInfo) * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNICOut() { @@ -163,7 +163,7 @@ public function getNICOut() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -171,7 +171,7 @@ public function getNICOut() /** * NICOut: 网卡出带宽(详情参考MonitorInfo) * - * @param MonitorInfo[] $nicOut + * @param MonitorInfoModel[] $nicOut */ public function setNICOut(array $nicOut) { @@ -181,11 +181,10 @@ public function setNICOut(array $nicOut) } return $result; } - /** * NICIn: 网卡入带宽(详情参考MonitorInfo) * - * @return MonitorInfo[]|null + * @return MonitorInfoModel[]|null */ public function getNICIn() { @@ -195,7 +194,7 @@ public function getNICIn() } $result = []; foreach ($items as $i => $item) { - array_push($result, new MonitorInfo($item)); + array_push($result, new MonitorInfoModel($item)); } return $result; } @@ -203,7 +202,7 @@ public function getNICIn() /** * NICIn: 网卡入带宽(详情参考MonitorInfo) * - * @param MonitorInfo[] $nicIn + * @param MonitorInfoModel[] $nicIn */ public function setNICIn(array $nicIn) { diff --git a/src/UEC/Models/MonitorInfo.php b/src/UEC/Models/MonitorInfo.php index 73007709..6b99dcff 100644 --- a/src/UEC/Models/MonitorInfo.php +++ b/src/UEC/Models/MonitorInfo.php @@ -1,6 +1,7 @@ set("TimeStamp", $timeStamp); } - /** * Value: 值 * @@ -57,7 +63,7 @@ public function getValue() * * @param int $value */ - public function setValue($value) + public function setValue(int $value) { $this->set("Value", $value); } diff --git a/src/UEC/Models/NodeInfo.php b/src/UEC/Models/NodeInfo.php index c34f6735..bfb2510e 100644 --- a/src/UEC/Models/NodeInfo.php +++ b/src/UEC/Models/NodeInfo.php @@ -1,6 +1,7 @@ set("NodeName", $nodeName); } - /** * NodeId: 节点ID * @@ -57,11 +60,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * CoreNum: Cpu核数 * @@ -77,11 +79,10 @@ public function getCoreNum() * * @param int $coreNum */ - public function setCoreNum($coreNum) + public function setCoreNum(int $coreNum) { $this->set("CoreNum", $coreNum); } - /** * MemSize: 节点内存大小,单位GB * @@ -97,11 +98,10 @@ public function getMemSize() * * @param int $memSize */ - public function setMemSize($memSize) + public function setMemSize(int $memSize) { $this->set("MemSize", $memSize); } - /** * SysDiskSize: 系统盘大小, 单位GB * @@ -117,11 +117,10 @@ public function getSysDiskSize() * * @param int $sysDiskSize */ - public function setSysDiskSize($sysDiskSize) + public function setSysDiskSize(int $sysDiskSize) { $this->set("SysDiskSize", $sysDiskSize); } - /** * DiskSize: 数据盘大小, 单位GB * @@ -137,11 +136,10 @@ public function getDiskSize() * * @param int $diskSize */ - public function setDiskSize($diskSize) + public function setDiskSize(int $diskSize) { $this->set("DiskSize", $diskSize); } - /** * State: 节点状态,1部署中,2待启动,3启动中,4运行中,5正在停止,6已停止,7正在更新,8正在重启,9正在删除, 10已经删除,11异常 * @@ -157,11 +155,10 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } - /** * NetLimit: 节点带宽限制, 单位Mbs * @@ -177,11 +174,10 @@ public function getNetLimit() * * @param int $netLimit */ - public function setNetLimit($netLimit) + public function setNetLimit(int $netLimit) { $this->set("NetLimit", $netLimit); } - /** * IdcId: 机房ID * @@ -197,11 +193,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * OcName: 机房名称 * @@ -217,11 +212,10 @@ public function getOcName() * * @param string $ocName */ - public function setOcName($ocName) + public function setOcName(string $ocName) { $this->set("OcName", $ocName); } - /** * Province: 省份 * @@ -237,11 +231,10 @@ public function getProvince() * * @param string $province */ - public function setProvince($province) + public function setProvince(string $province) { $this->set("Province", $province); } - /** * City: 城市 * @@ -257,11 +250,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * Type: 运营商类型: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 * @@ -277,11 +269,10 @@ public function getType() * * @param int $type */ - public function setType($type) + public function setType(int $type) { $this->set("Type", $type); } - /** * ChargeType: 付费类型:1按时, 2按月,3按年 * @@ -297,11 +288,10 @@ public function getChargeType() * * @param int $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(int $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CreateTime: 创建时间 * @@ -317,11 +307,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpiredTime: 过期时间 * @@ -337,11 +326,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * ImageName: 镜像名称 * @@ -357,15 +345,14 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * NodeIpList: 外网ip集合(详情参考NodeIpList) * - * @return NodeIpList[]|null + * @return NodeIpListModel[]|null */ public function getNodeIpList() { @@ -375,7 +362,7 @@ public function getNodeIpList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NodeIpList($item)); + array_push($result, new NodeIpListModel($item)); } return $result; } @@ -383,7 +370,7 @@ public function getNodeIpList() /** * NodeIpList: 外网ip集合(详情参考NodeIpList) * - * @param NodeIpList[] $nodeIpList + * @param NodeIpListModel[] $nodeIpList */ public function setNodeIpList(array $nodeIpList) { @@ -393,7 +380,6 @@ public function setNodeIpList(array $nodeIpList) } return $result; } - /** * FirewallId: 防火墙Id * @@ -409,11 +395,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ProductType: 机器类型(normal-经济型,hf-标准型,g-GPU型) * @@ -429,8 +414,27 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } + /** + * InnerIps: 内网ip列表 + * + * @return string[]|null + */ + public function getInnerIps() + { + return $this->get("InnerIps"); + } + + /** + * InnerIps: 内网ip列表 + * + * @param string[] $innerIps + */ + public function setInnerIps(array $innerIps) + { + $this->set("InnerIps", $innerIps); + } } diff --git a/src/UEC/Models/NodeIpList.php b/src/UEC/Models/NodeIpList.php index 9e4c3066..eaf90f0b 100644 --- a/src/UEC/Models/NodeIpList.php +++ b/src/UEC/Models/NodeIpList.php @@ -1,6 +1,7 @@ set("Ip", $ip); } - /** * Isp: 运营商 * @@ -57,11 +60,10 @@ public function getIsp() * * @param string $isp */ - public function setIsp($isp) + public function setIsp(string $isp) { $this->set("Isp", $isp); } - /** * IspName: 运营商名称 * @@ -77,7 +79,7 @@ public function getIspName() * * @param string $ispName */ - public function setIspName($ispName) + public function setIspName(string $ispName) { $this->set("IspName", $ispName); } diff --git a/src/UEC/Models/NodeIspList.php b/src/UEC/Models/NodeIspList.php index 385edd30..faaf0802 100644 --- a/src/UEC/Models/NodeIspList.php +++ b/src/UEC/Models/NodeIspList.php @@ -1,6 +1,7 @@ set("Province", $province); } - /** * City: 城市 * @@ -57,11 +59,10 @@ public function getCity() * * @param string $city */ - public function setCity($city) + public function setCity(string $city) { $this->set("City", $city); } - /** * LineType: 线路类型 * @@ -77,11 +78,10 @@ public function getLineType() * * @param string $lineType */ - public function setLineType($lineType) + public function setLineType(string $lineType) { $this->set("LineType", $lineType); } - /** * IspName: 机房运营商名称 * @@ -97,11 +97,10 @@ public function getIspName() * * @param string $ispName */ - public function setIspName($ispName) + public function setIspName(string $ispName) { $this->set("IspName", $ispName); } - /** * IdcName: 机房名称 * @@ -117,7 +116,7 @@ public function getIdcName() * * @param string $idcName */ - public function setIdcName($idcName) + public function setIdcName(string $idcName) { $this->set("IdcName", $idcName); } diff --git a/src/UEC/Models/NodeList.php b/src/UEC/Models/NodeList.php index b272c944..f3761f33 100644 --- a/src/UEC/Models/NodeList.php +++ b/src/UEC/Models/NodeList.php @@ -1,6 +1,7 @@ set("NodeId", $nodeId); } diff --git a/src/UEC/Models/ResourceInfo.php b/src/UEC/Models/ResourceInfo.php index cb72cb09..6d36a499 100644 --- a/src/UEC/Models/ResourceInfo.php +++ b/src/UEC/Models/ResourceInfo.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * PublicIpList: 节点公网Ip列表 * @@ -61,7 +63,6 @@ public function setPublicIpList(array $publicIpList) { $this->set("PublicIpList", $publicIpList); } - /** * Name: 节点名称 * @@ -77,11 +78,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * State: 节点状态,1部署中,2待启动,3启动中,4运行中,5正在停止,6已停止,7正在更新,8正在重启,9正在删除, 10已经删除,11异常 * @@ -97,11 +97,10 @@ public function getState() * * @param int $state */ - public function setState($state) + public function setState(int $state) { $this->set("State", $state); } - /** * Remark: 节点备注 * @@ -117,7 +116,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Models/ResourceSet.php b/src/UEC/Models/ResourceSet.php index 02c291a8..df53732c 100644 --- a/src/UEC/Models/ResourceSet.php +++ b/src/UEC/Models/ResourceSet.php @@ -1,6 +1,7 @@ set("NodeId", $nodeId); } - /** * OuterIps: 机器外网ip集合 * diff --git a/src/UEC/Models/RuleInfo.php b/src/UEC/Models/RuleInfo.php index 14612d39..63126480 100644 --- a/src/UEC/Models/RuleInfo.php +++ b/src/UEC/Models/RuleInfo.php @@ -1,6 +1,7 @@ set("ProtocolType", $protocolType); } - /** * Port: 端口,范围用"-"符号分隔,如:1-65535 * @@ -57,11 +60,10 @@ public function getPort() * * @param string $port */ - public function setPort($port) + public function setPort(string $port) { $this->set("Port", $port); } - /** * SrcIp: 源ip * @@ -77,11 +79,10 @@ public function getSrcIp() * * @param string $srcIp */ - public function setSrcIp($srcIp) + public function setSrcIp(string $srcIp) { $this->set("SrcIp", $srcIp); } - /** * Action: ACCEPT(接受)和DROP(拒绝) * @@ -97,11 +98,10 @@ public function getAction() * * @param string $action */ - public function setAction($action) + public function setAction(string $action) { $this->set("Action", $action); } - /** * Priority: 优先级:HIGH(高),MEDIUM(中),LOW(低) * @@ -117,11 +117,10 @@ public function getPriority() * * @param string $priority */ - public function setPriority($priority) + public function setPriority(string $priority) { $this->set("Priority", $priority); } - /** * Remark: 备注 * @@ -137,7 +136,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/Models/StorVolumeInfo.php b/src/UEC/Models/StorVolumeInfo.php index 1a2fec3e..f260180a 100644 --- a/src/UEC/Models/StorVolumeInfo.php +++ b/src/UEC/Models/StorVolumeInfo.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * ResourceId: 资源id * @@ -57,11 +62,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * MountPoint: 挂载点 * @@ -77,11 +81,10 @@ public function getMountPoint() * * @param string $mountPoint */ - public function setMountPoint($mountPoint) + public function setMountPoint(string $mountPoint) { $this->set("MountPoint", $mountPoint); } - /** * DiskSize: 容量(单位GB) * @@ -97,7 +100,7 @@ public function getDiskSize() * * @param int $diskSize */ - public function setDiskSize($diskSize) + public function setDiskSize(int $diskSize) { $this->set("DiskSize", $diskSize); } diff --git a/src/UEC/Models/SubnetInfo.php b/src/UEC/Models/SubnetInfo.php index 3bd6b1c0..88648b8e 100644 --- a/src/UEC/Models/SubnetInfo.php +++ b/src/UEC/Models/SubnetInfo.php @@ -1,6 +1,7 @@ set("SubnetId", $subnetId); } - /** * SubnetName: 子网名称 * @@ -57,11 +59,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * IdcId: 机房ID * @@ -77,11 +78,10 @@ public function getIdcId() * * @param string $idcId */ - public function setIdcId($idcId) + public function setIdcId(string $idcId) { $this->set("IdcId", $idcId); } - /** * CIDR: 子网cidr * @@ -97,11 +97,10 @@ public function getCIDR() * * @param string $cidr */ - public function setCIDR($cidr) + public function setCIDR(string $cidr) { $this->set("CIDR", $cidr); } - /** * CreateTime: 创建时间 * @@ -117,11 +116,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Comment: 备注 * @@ -137,11 +135,10 @@ public function getComment() * * @param string $comment */ - public function setComment($comment) + public function setComment(string $comment) { $this->set("Comment", $comment); } - /** * TotalIpCnt: 总ip数 * @@ -157,11 +154,10 @@ public function getTotalIpCnt() * * @param int $totalIpCnt */ - public function setTotalIpCnt($totalIpCnt) + public function setTotalIpCnt(int $totalIpCnt) { $this->set("TotalIpCnt", $totalIpCnt); } - /** * AvailableIPCnt: 可用ip数 * @@ -177,7 +173,7 @@ public function getAvailableIPCnt() * * @param int $availableIPCnt */ - public function setAvailableIPCnt($availableIPCnt) + public function setAvailableIPCnt(int $availableIPCnt) { $this->set("AvailableIPCnt", $availableIPCnt); } diff --git a/src/UEC/Params/UpdateUEcFirewallParamRule.php b/src/UEC/Models/UpdateUEcFirewallRequestRule.php similarity index 84% rename from src/UEC/Params/UpdateUEcFirewallParamRule.php rename to src/UEC/Models/UpdateUEcFirewallRequestRule.php index f0309ab9..66ec148d 100644 --- a/src/UEC/Params/UpdateUEcFirewallParamRule.php +++ b/src/UEC/Models/UpdateUEcFirewallRequestRule.php @@ -1,6 +1,7 @@ set("ProtocolType", $protocolType); } - /** * Port: 端口,范围用"-"符号分隔,如:1-65535 * @@ -57,11 +59,10 @@ public function getPort() * * @param string $port */ - public function setPort($port) + public function setPort(string $port) { $this->set("Port", $port); } - /** * SrcIp: 源ip * @@ -77,11 +78,10 @@ public function getSrcIp() * * @param string $srcIp */ - public function setSrcIp($srcIp) + public function setSrcIp(string $srcIp) { $this->set("SrcIp", $srcIp); } - /** * Action: ACCEPT(接受)和DROP(拒绝) * @@ -97,11 +97,10 @@ public function getAction() * * @param string $action */ - public function setAction($action) + public function setAction(string $action) { $this->set("Action", $action); } - /** * Priority: 优先级:HIGH(高),MEDIUM(中),LOW(低) * @@ -117,11 +116,10 @@ public function getPriority() * * @param string $priority */ - public function setPriority($priority) + public function setPriority(string $priority) { $this->set("Priority", $priority); } - /** * Remark: 备注 * @@ -137,7 +135,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UEC/UECClient.php b/src/UEC/UECClient.php index 77b895a0..33b5a51f 100644 --- a/src/UEC/UECClient.php +++ b/src/UEC/UECClient.php @@ -1,6 +1,7 @@ (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙Id - * "ResourceId" => (string) 虚拟机资源Id或容器组资源id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BindUEcFirewallResponse * @throws UCloudException */ public function bindUEcFirewall(BindUEcFirewallRequest $request = null) @@ -133,37 +251,27 @@ public function bindUEcFirewall(BindUEcFirewallRequest $request = null) $resp = $this->invoke($request); return new BindUEcFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * CreateUEcFirewall - 创建外网防火墙 - * - * See also: https://docs.ucloud.cn/api/uec-api/create_u_ec_firewall + * CreateUEcCustomImage - 从指定虚拟机,生成自定义镜像。 * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Name" => (string) 防火墙名称 - * "Rule" => (array) [ - * [ - * "ProtocolType" => (string) 协议,可选值:TCP,UDP,ICMP - * "Port" => (string) 端口,范围用"-"符号分隔,如:1-65535 - * "SrcIp" => (string) 源ip - * "Action" => (string) ACCEPT(接受)和DROP(拒绝) - * "Priority" => (string) 优先级:HIGH(高),MEDIUM(中),LOW(低) - * "Remark" => (string) 备注 - * ] - * ] - * "Remark" => (string) 描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "FirewallId" => (string) 防火墙Id - * ] + * @throws UCloudException + */ + public function createUEcCustomImage(CreateUEcCustomImageRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateUEcCustomImageResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateUEcFirewall - 创建外网防火墙 * - * @return CreateUEcFirewallResponse * @throws UCloudException */ public function createUEcFirewall(CreateUEcFirewallRequest $request = null) @@ -171,62 +279,13 @@ public function createUEcFirewall(CreateUEcFirewallRequest $request = null) $resp = $this->invoke($request); return new CreateUEcFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUEcHolder - 创建容器组 * - * See also: https://docs.ucloud.cn/api/uec-api/create_u_ec_holder - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (string) 机房id - * "CpuCore" => (number) 容器组Cpu总核数 - * "MemSize" => (integer) 容器组总内存,单位MB - * "SubnetId" => (string) 子网ID - * "Name" => (string) 容器组名称(默认default) - * "ProductType" => (string) 机型(normal-经济型,hf-标准型,默认normal) - * "RestartStrategy" => (integer) 重启策略(0总是,1失败是,2永不,默认0) - * "ElasticIp" => (string) 绑定外网ip(yes-绑定,no-不绑定,默认no) - * "Bandwidth" => (integer) 外网绑定的带宽(单位M,默认0,只有当ElasticIp为yes时,默认1) - * "FirewallId" => (string) 防火墙ID - * "ChargeType" => (integer) 付费方式(2按月、3按年。默认2,默认月付) - * "ChargeQuantity" => (integer) 月数或者年数(默认值:1,当为按月计费时,0表示计费到月底,默认值为0) - * "Pack" => (array) [ - * [ - * "Name" => (string) 容器名称 - * "CpuCore" => (number) 容器Cpu核数 - * "MemSize" => (integer) 容器内存,单位MB - * "ImageName" => (string) 容器镜像名称 - * "WorkDir" => (string) 容器工作目录 - * "Cmd" => (string) 开启容器的命令 - * "Args" => (string) 容器参数(多个用;隔开) - * "Environment" => (string) 容器环境变量(多个用;隔开,如:key1:value1;key2:value2) - * "ConfigDict" => (string) 容器配置字典(多个用;隔开,如:/data1:resId1;/data2:resId2) - * ] - * ] - * "Image" => (array) [ - * [ - * "Message" => (string) 镜像用户名和密码(如镜像名:密码) - * "StoreAddress" => (string) 镜像仓库地址 - * ] - * ] - * "Storage" => (array) [ - * [ - * "Path" => (string) 存储卷挂载路径 - * "ResourceId" => (string) 存储卷资源id - * ] - * ] - * ] - * - * Outputs: - * - * $outputs = [ - * "ResourceId" => (string) 容器组资源id - * ] - * - * @return CreateUEcHolderResponse * @throws UCloudException */ public function createUEcHolder(CreateUEcHolderRequest $request = null) @@ -234,29 +293,13 @@ public function createUEcHolder(CreateUEcHolderRequest $request = null) $resp = $this->invoke($request); return new CreateUEcHolderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUEcSubnet - 创建子网 * - * See also: https://docs.ucloud.cn/api/uec-api/create_u_ec_subnet - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (string) 机房ID - * "CIDR" => (string) 子网cidr - * "SubnetName" => (string) 子网名称 - * "Comment" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "SubnetId" => (string) 子网ID - * ] - * - * @return CreateUEcSubnetResponse * @throws UCloudException */ public function createUEcSubnet(CreateUEcSubnetRequest $request = null) @@ -264,49 +307,13 @@ public function createUEcSubnet(CreateUEcSubnetRequest $request = null) $resp = $this->invoke($request); return new CreateUEcSubnetResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUEcVHost - 创建虚拟机v2.0 * - * See also: https://docs.ucloud.cn/api/uec-api/create_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (string) 机房id - * "CpuCore" => (integer) cpu核心数 - * "MemSize" => (integer) 内存大小,单位GB - * "DiskSize" => (integer) 数据盘大小,单位GB - * "ImageId" => (string) 镜像ID - * "NetLimit" => (integer) 节点带宽限制,单位Mbs - * "NodeName" => (string) 节点名称 - * "SysDiskSize" => (integer) 系统盘大小,单位GB, 默认20GB - * "AccountName" => (string) 账户名,默认root - * "PassWord" => (string) 密码 - * "NodeCount" => (integer) 创建节点数量,默认1 - * "ChargeType" => (integer) 付费方式,1按时,2按月,3按年,默认2 - * "ChargeQuantity" => (integer) 月数或者年数,0计费到月底, 默认0 - * "SubnetId" => (string) 子网ID - * "ProductType" => (string) 产品类型:normal(经济型),hf(标准型),g(Gpu型) - * "FirewallId" => (string) 外网防护墙规则组,默认 - * "Isp" => (array) 运营商(1-电信,2-联通,4移动) - * "IsNeedOuterIp" => (string) 是否需要外网ip(no-否) - * "Gpu" => (integer) Gpu卡核心数。仅Gpu机型支持此字段 - * "GpuType" => (string) Gpu类型,枚举值["T4S"],ProductType为G时必填 - * ] - * - * Outputs: - * - * $outputs = [ - * "NodeList" => (array) 节点id(详情参考NodeList)[ - * [ - * "NodeId" => (string) 虚拟机资源id - * ] - * ] - * ] - * - * @return CreateUEcVHostResponse * @throws UCloudException */ public function createUEcVHost(CreateUEcVHostRequest $request = null) @@ -314,27 +321,13 @@ public function createUEcVHost(CreateUEcVHostRequest $request = null) $resp = $this->invoke($request); return new CreateUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUEcCustomImage - 删除UEDN客户自定义镜像 * - * See also: https://docs.ucloud.cn/api/uec-api/delete_u_ec_custom_image - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageId" => (string) 镜像ID - * "IdcId" => (string) 机房ID,带机房ID表示只删除指定机房镜像 - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageId" => (integer) 镜像ID - * ] - * - * @return DeleteUEcCustomImageResponse * @throws UCloudException */ public function deleteUEcCustomImage(DeleteUEcCustomImageRequest $request = null) @@ -342,25 +335,13 @@ public function deleteUEcCustomImage(DeleteUEcCustomImageRequest $request = null $resp = $this->invoke($request); return new DeleteUEcCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUEcHolder - 删除容器组 * - * See also: https://docs.ucloud.cn/api/uec-api/delete_u_ec_holder - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "HolderId" => (array) 容器组资源id,n为0,1,2... - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUEcHolderResponse * @throws UCloudException */ public function deleteUEcHolder(DeleteUEcHolderRequest $request = null) @@ -368,25 +349,13 @@ public function deleteUEcHolder(DeleteUEcHolderRequest $request = null) $resp = $this->invoke($request); return new DeleteUEcHolderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUEcSubnet - 删除子网 * - * See also: https://docs.ucloud.cn/api/uec-api/delete_u_ec_subnet - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SubnetId" => (string) 子网ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUEcSubnetResponse * @throws UCloudException */ public function deleteUEcSubnet(DeleteUEcSubnetRequest $request = null) @@ -394,25 +363,13 @@ public function deleteUEcSubnet(DeleteUEcSubnetRequest $request = null) $resp = $this->invoke($request); return new DeleteUEcSubnetResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUEcVHost - 删除vhost虚拟机 v2.0 * - * See also: https://docs.ucloud.cn/api/uec-api/delete_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 节点id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUEcVHostResponse * @throws UCloudException */ public function deleteUEcVHost(DeleteUEcVHostRequest $request = null) @@ -420,49 +377,13 @@ public function deleteUEcVHost(DeleteUEcVHostRequest $request = null) $resp = $this->invoke($request); return new DeleteUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcFirewall - 获取防火墙信息 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_firewall - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙ID,默认为返回所有防火墙 - * "ResourceId" => (string) 绑定防火墙组的虚拟机资源ID - * "Limit" => (integer) 返回数据长度,默认为20 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "FirewallSet" => (array) 防火墙组详细信息,参见 FirewallInfo[ - * [ - * "FirewallId" => (string) 防火墙Id - * "Name" => (string) 防火墙名称 - * "CreateTime" => (integer) 创建时间 - * "Rule" => (array) 防火墙规则组,详情参见RuleInfo[ - * [ - * "ProtocolType" => (string) 协议,可选值:TCP,UDP,ICMP - * "Port" => (string) 端口,范围用"-"符号分隔,如:1-65535 - * "SrcIp" => (string) 源ip - * "Action" => (string) ACCEPT(接受)和DROP(拒绝) - * "Priority" => (string) 优先级:HIGH(高),MEDIUM(中),LOW(低) - * "Remark" => (string) 备注 - * ] - * ] - * "ResourceCount" => (integer) 防火墙绑定资源数量 - * "Type" => (string) 防火墙组类型,枚举值为: "user defined", 用户自定义防火墙; "recommend web", 默认Web防火墙; "recommend non web", 默认非Web防火墙 - * "Remark" => (string) 描述 - * ] - * ] - * "TotalCount" => (integer) 满足条件的节点总数 - * ] - * - * @return DescribeUEcFirewallResponse * @throws UCloudException */ public function describeUEcFirewall(DescribeUEcFirewallRequest $request = null) @@ -470,35 +391,13 @@ public function describeUEcFirewall(DescribeUEcFirewallRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcFirewallResource - 防火墙绑定的资源列表 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_firewall_resource - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙Id - * ] - * - * Outputs: - * - * $outputs = [ - * "ResourceSet" => (array) 资源列表,详情参见ResourceInfo[ - * [ - * "ResourceId" => (string) 资源Id - * "PublicIpList" => (array) 节点公网Ip列表 - * "Name" => (string) 节点名称 - * "State" => (integer) 节点状态,1部署中,2待启动,3启动中,4运行中,5正在停止,6已停止,7正在更新,8正在重启,9正在删除, 10已经删除,11异常 - * "Remark" => (string) 节点备注 - * ] - * ] - * "TotalCount" => (integer) 资源总数 - * ] - * - * @return DescribeUEcFirewallResourceResponse * @throws UCloudException */ public function describeUEcFirewallResource(DescribeUEcFirewallResourceRequest $request = null) @@ -506,96 +405,13 @@ public function describeUEcFirewallResource(DescribeUEcFirewallResourceRequest $ $resp = $this->invoke($request); return new DescribeUEcFirewallResourceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcHolder - 获得容器组信息 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_holder - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "HolderId" => (array) 容器组资源id - * "Limit" => (integer) 返回数据长度,默认为20,非负整数 - * "Offset" => (integer) 列表起始位置偏移量,默认为0。非负整数 - * ] - * - * Outputs: - * - * $outputs = [ - * "HolderList" => (array) 容器组列表(详情参考HolderList)[ - * [ - * "ResourceId" => (string) 容器组资源id - * "HolderName" => (string) 容器组名称 - * "SubnetId" => (string) 容器组子网id - * "InnerIp" => (string) 容器组内网ip - * "IpList" => (array) 容器组外网ip集合(详情参考IpList)[ - * [ - * "Ip" => (string) 外网ip - * "Isp" => (string) 运营商 - * ] - * ] - * "State" => (integer) 容器组运行状态0:初始化;1:拉取镜像;2:启动中;3:运行中;4:错误;5:正在重启;6:正在删除;7:已经删除;8:容器运行错误;9:启动失败;99:异常 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 过期时间 - * "Type" => (integer) 线路类型(运营商类型: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通) - * "IdcId" => (string) 机房id - * "OcName" => (string) 机房名称 - * "Province" => (string) 省份名称 - * "City" => (string) 城市名称 - * "RestartStrategy" => (integer) 0:总是;1:失败是;2:永不 - * "DockerCount" => (integer) 容器数量 - * "DockerInfo" => (array) 容器信息(详情参考DockerInfo)[ - * [ - * "CpuCores" => (number) CPU核数(/核)精度0.1核 - * "MemSize" => (number) 内存大小(Gi) - * "Name" => (string) 容器名称 - * "State" => (integer) 容器状态,0:初始化;1:拉取镜像;2:拉取镜像失败;3:启动中;4:运行中;5:正在停止;6:已停止;7:已删除;8:镜像拉取成功;9:启动失败;99:异常 - * "ImageName" => (string) 镜像名称 - * "WorkDir" => (string) 工作目录 - * "Command" => (string) 命令 - * "Args" => (string) 参数 - * "EnvList" => (array) 环境变量(详情参考EnvList)[ - * [ - * "Key" => (string) 环境变量key值 - * "Value" => (string) 环境变量Value值 - * ] - * ] - * "CfgDictList" => (array) 容器配置字典(详情参考CfgDictList)[ - * [ - * "Name" => (string) 名称 - * "MountPath" => (string) 挂载路径 - * "ResourceId" => (string) 资源id - * ] - * ] - * ] - * ] - * "ProductType" => (string) 机器类型(normal经济型,hf标准型) - * "NetLimit" => (integer) 外网绑定的带宽 - * "FirewallId" => (string) 外网防火墙id - * "StorVolumeInfo" => (array) 存储卷信息(详情参考StorVolumeInfo)[ - * [ - * "Name" => (string) 名称 - * "ResourceId" => (string) 资源id - * "MountPoint" => (string) 挂载点 - * "DiskSize" => (integer) 容量(单位GB) - * ] - * ] - * "StorVolumeCount" => (integer) 存储卷数量 - * "ImageList" => (array) 容器组镜像密钥列表(详情参考ImageList)[ - * [ - * "StoreAddr" => (string) 仓库地址 - * "UserName" => (string) 用户名称 - * "ImageKey" => (string) 镜像密钥 - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 满足条件的容器组总数 - * ] - * - * @return DescribeUEcHolderResponse * @throws UCloudException */ public function describeUEcHolder(DescribeUEcHolderRequest $request = null) @@ -603,40 +419,13 @@ public function describeUEcHolder(DescribeUEcHolderRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcHolderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcHolderIDC - 获取容器组机房信息 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_holder_idc - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Cpu" => (number) 容器组Cpu核数 - * "Memory" => (integer) 容器组内存大小(单位MB) - * "IdcId" => (array) Idc机房id。默认全部机房 - * "Type" => (integer) 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 - * "ProductType" => (string) 产品类型,normal标准型,hf高性能型 - * ] - * - * Outputs: - * - * $outputs = [ - * "IdcList" => (array) 机房列表,具体参考下面IdcInfo[ - * [ - * "IdcId" => (string) 机房ID - * "Name" => (string) 机房名称 - * "Isp" => (string) 运营商 - * "Province" => (string) 省份 - * "City" => (string) 城市 - * "Type" => (integer) 运营商类型:0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 - * "MaxNodeCnt" => (integer) 机房可创建节点最大数量 - * ] - * ] - * ] - * - * @return DescribeUEcHolderIDCResponse * @throws UCloudException */ public function describeUEcHolderIDC(DescribeUEcHolderIDCRequest $request = null) @@ -644,40 +433,13 @@ public function describeUEcHolderIDC(DescribeUEcHolderIDCRequest $request = null $resp = $this->invoke($request); return new DescribeUEcHolderIDCResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcIDC - 获取IDC机房列表 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_idc - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Cpu" => (integer) 节点cpu核数 - * "Memory" => (integer) 节点内存大小, 单位GB - * "IdcId" => (array) Idc机房id。默认全部机房 - * "Type" => (integer) 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 - * "ProductType" => (string) 产品类型:normal(通用型),hf(高主频型) - * ] - * - * Outputs: - * - * $outputs = [ - * "IdcList" => (array) 获取的机房信息,具体参考下面IdcInfo[ - * [ - * "IdcId" => (string) 机房ID - * "Name" => (string) 机房名称 - * "Isp" => (string) 运营商 - * "Province" => (string) 省份 - * "City" => (string) 城市 - * "Type" => (integer) 运营商类型:0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 - * "MaxNodeCnt" => (integer) 机房可创建节点最大数量 - * ] - * ] - * ] - * - * @return DescribeUEcIDCResponse * @throws UCloudException */ public function describeUEcIDC(DescribeUEcIDCRequest $request = null) @@ -685,38 +447,13 @@ public function describeUEcIDC(DescribeUEcIDCRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcIDCResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcSubnet - 获取子网列表 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_subnet - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (string) 机房ID - * "SubnetId" => (string) 子网ID - * ] - * - * Outputs: - * - * $outputs = [ - * "SubnetList" => (array) 子网信息列表[ - * [ - * "SubnetId" => (string) 子网ID - * "SubnetName" => (string) 子网名称 - * "IdcId" => (string) 机房ID - * "CIDR" => (string) 子网cidr - * "CreateTime" => (integer) 创建时间 - * "Comment" => (string) 备注 - * "TotalIpCnt" => (integer) 总ip数 - * "AvailableIPCnt" => (integer) 可用ip数 - * ] - * ] - * ] - * - * @return DescribeUEcSubnetResponse * @throws UCloudException */ public function describeUEcSubnet(DescribeUEcSubnetRequest $request = null) @@ -724,59 +461,13 @@ public function describeUEcSubnet(DescribeUEcSubnetRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcSubnetResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcVHost - 获取虚拟机列表 2.0 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (array) Idc机房id。默认全部机房 - * "NodeId" => (array) 节点id,创建节点时生成的id。默认全部节点 - * "Offset" => (integer) 数据偏移量,默认0,非负整数 - * "Limit" => (integer) 返回数据长度, 默认20,非负整数 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的节点总数 - * "NodeList" => (array) 节点列表[ - * [ - * "NodeName" => (string) 节点名称 - * "NodeId" => (string) 节点ID - * "CoreNum" => (integer) Cpu核数 - * "MemSize" => (integer) 节点内存大小,单位GB - * "SysDiskSize" => (integer) 系统盘大小, 单位GB - * "DiskSize" => (integer) 数据盘大小, 单位GB - * "State" => (integer) 节点状态,1部署中,2待启动,3启动中,4运行中,5正在停止,6已停止,7正在更新,8正在重启,9正在删除, 10已经删除,11异常 - * "NetLimit" => (integer) 节点带宽限制, 单位Mbs - * "IdcId" => (string) 机房ID - * "OcName" => (string) 机房名称 - * "Province" => (string) 省份 - * "City" => (string) 城市 - * "Type" => (integer) 运营商类型: 0-其它, 1-一线城市单线,2-二线城市单线, 3-全国教育网, 4-全国三通 - * "ChargeType" => (integer) 付费类型:1按时, 2按月,3按年 - * "CreateTime" => (integer) 创建时间 - * "ExpiredTime" => (integer) 过期时间 - * "ImageName" => (string) 镜像名称 - * "NodeIpList" => (array) 外网ip集合(详情参考NodeIpList)[ - * [ - * "Ip" => (string) 外网ip - * "Isp" => (string) 运营商 - * "IspName" => (string) 运营商名称 - * ] - * ] - * "FirewallId" => (string) 防火墙Id - * "ProductType" => (string) 机器类型(normal-经济型,hf-标准型,g-GPU型) - * ] - * ] - * ] - * - * @return DescribeUEcVHostResponse * @throws UCloudException */ public function describeUEcVHost(DescribeUEcVHostRequest $request = null) @@ -784,35 +475,13 @@ public function describeUEcVHost(DescribeUEcVHostRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUEcVHostISP - 获取虚拟机运营商信息 * - * See also: https://docs.ucloud.cn/api/uec-api/describe_u_ec_v_host_isp - * - * Arguments: - * - * $args = [ - * "IspName" => (string) 运营商名称 - * "Province" => (string) 省份 - * "City" => (string) 城市 - * ] - * - * Outputs: - * - * $outputs = [ - * "NodeIspList" => (array) 节点运营商列表[ - * [ - * "Province" => (string) 省份 - * "City" => (string) 城市 - * "LineType" => (string) 线路类型 - * "IspName" => (string) 机房运营商名称 - * "IdcName" => (string) 机房名称 - * ] - * ] - * ] - * - * @return DescribeUEcVHostISPResponse * @throws UCloudException */ public function describeUEcVHostISP(DescribeUEcVHostISPRequest $request = null) @@ -820,27 +489,13 @@ public function describeUEcVHostISP(DescribeUEcVHostISPRequest $request = null) $resp = $this->invoke($request); return new DescribeUEcVHostISPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcHolderLog - 获取单个容器日志 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_holder_log - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PackName" => (string) 容器名称 - * "ResourceId" => (string) 容器组资源id - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (string) 返回的日志数据 - * ] - * - * @return GetUEcHolderLogResponse * @throws UCloudException */ public function getUEcHolderLog(GetUEcHolderLogRequest $request = null) @@ -848,67 +503,13 @@ public function getUEcHolderLog(GetUEcHolderLogRequest $request = null) $resp = $this->invoke($request); return new GetUEcHolderLogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcHolderMetrics - 获取容器(CPU利用率,带宽,内存)数据 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_holder_metrics - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PackName" => (string) 容器名称 - * "Type" => (array) n为0 CPU利用率, 1内存使用率, 2网卡出带宽, 3网卡入带宽, 4网卡出包数, 5网卡入包数 - * "ResourceId" => (string) 容器组资源id - * "StartTime" => (integer) 开始时间 - * "EndTime" => (integer) 结束时间 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSets" => (object) 获得的监控数据(详情参考MetricisDataSet)[ - * "CPUUtilization" => (array) cpu利用率(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "MemUtilization" => (array) 内存使用率(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketOut" => (array) 网卡出包数(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketIn" => (array) 网卡入包数(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICOut" => (array) 网卡出带宽(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICIn" => (array) 网卡入带宽(详情参考MonitorInfo)[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * ] - * ] - * - * @return GetUEcHolderMetricsResponse * @throws UCloudException */ public function getUEcHolderMetrics(GetUEcHolderMetricsRequest $request = null) @@ -916,40 +517,13 @@ public function getUEcHolderMetrics(GetUEcHolderMetricsRequest $request = null) $resp = $this->invoke($request); return new GetUEcHolderMetricsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcIDCCutInfo - 获取机房割接信息 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_idc_cut_info - * - * Arguments: - * - * $args = [ - * ] - * - * Outputs: - * - * $outputs = [ - * "IDCCutInfo" => (array) 机房割接信息[ - * [ - * "IDCName" => (string) 机房名称 - * "Province" => (string) 省份 - * "City" => (string) 城市 - * "StartTime" => (integer) 割接开始时间 - * "EndTime" => (integer) 割接结束时间 - * "CutType" => (string) 割接类型(中断、抖动、断电) - * "ResourceSet" => (array) 受影响的资源信息列表[ - * [ - * "NodeId" => (string) 节点id - * "OuterIps" => (array) 机器外网ip集合 - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 满足条件的机房总数 - * ] - * - * @return GetUEcIDCCutInfoResponse * @throws UCloudException */ public function getUEcIDCCutInfo(GetUEcIDCCutInfoRequest $request = null) @@ -957,90 +531,13 @@ public function getUEcIDCCutInfo(GetUEcIDCCutInfoRequest $request = null) $resp = $this->invoke($request); return new GetUEcIDCCutInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcIDCVHostData - 获取机房虚拟机监控数据 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_idcv_host_data - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 节点资源id;n为0,1,2... - * "Type" => (array) 监控数据类型;n为0,1,2,3,4...,9 - * "BeginTime" => (integer) 开始时间戳 - * "EndTime" => (integer) 结束时间戳 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSets" => (object) 监控数据集合[ - * "CPUUtilization" => (array) cpu使用率[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "MemUtilization" => (array) 内存使用率[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICOut" => (array) 网卡出带宽[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICIn" => (array) 网卡入带宽[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketOut" => (array) 网卡出包量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketIn" => (array) 网卡入包量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "IORead" => (array) 磁盘读取量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "IOWrite" => (array) 磁盘写入量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "DiskReadOps" => (array) 磁盘读取次数[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "DiskWriteOps" => (array) 磁盘写入次数[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * ] - * ] - * - * @return GetUEcIDCVHostDataResponse * @throws UCloudException */ public function getUEcIDCVHostData(GetUEcIDCVHostDataRequest $request = null) @@ -1048,47 +545,13 @@ public function getUEcIDCVHostData(GetUEcIDCVHostDataRequest $request = null) $resp = $this->invoke($request); return new GetUEcIDCVHostDataResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcImage - uec2.0 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_image - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageType" => (string) 镜像类型:1标准镜像,2行业镜像,3自定义镜像 - * "Offset" => (integer) 数据偏移量,默认0,非负整数 - * "Limit" => (integer) 返回数据长度, 默认20,非负整数 - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageList" => (array) 获取的镜像信息,具体参考下面ImageInfo[ - * [ - * "ImageId" => (string) 镜像ID - * "ImageName" => (string) 镜像名称 - * "ImageType" => (integer) 镜像类型:1标准镜像,2行业镜像,3自定义镜像 - * "OcType" => (string) 系统类型:unix, windows - * "ImageDesc" => (string) 镜像描述 - * "State" => (integer) 镜像状态:镜像状态 1可用,2不可用,3制作中 - * "ImageSize" => (integer) 镜像大小,单位GB - * "CreateTime" => (integer) 镜像创建时间戳 - * "DeployInfoList" => (array) 部署详情列表[ - * [ - * "IdcId" => (string) 机房ID - * "State" => (integer) 镜像状态 1-可用, 2-不可用, 3-获取中, 4-转换中, 5-部署中 - * ] - * ] - * "Gpu" => (integer) 是否支持Gpu(1-支持,0-不支持) - * ] - * ] - * "TotalCount" => (integer) 镜像总数 - * ] - * - * @return GetUEcImageResponse * @throws UCloudException */ public function getUEcImage(GetUEcImageRequest $request = null) @@ -1096,33 +559,13 @@ public function getUEcImage(GetUEcImageRequest $request = null) $resp = $this->invoke($request); return new GetUEcImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcPodPrice - 获得容器组价格 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_pod_price - * - * Arguments: - * - * $args = [ - * "IdcId" => (string) 机房id - * "CpuCore" => (number) 容器组总Cpu核心数 - * "MemSize" => (integer) 容器组总内存大小(单位M) - * "ChargeType" => (integer) 支付类型(2按月,3按年,默认2) - * "ChargeQuantity" => (integer) 月数或年数(默认值:1,当支付类型为按月时,默认值为0) - * "ProductType" => (string) 产品类型(normal:标准型,hf:高性能型,默认:normal) - * "ElasticIp" => (string) 是否绑定外网IP(yes:是,no:否,默认:no) - * "Bandwidth" => (integer) 绑定的带宽,默认0,当绑定外网IP时默认1(单位M) - * ] - * - * Outputs: - * - * $outputs = [ - * "HolderPrice" => (number) 容器组价格 - * "IpPrice" => (number) IP和带宽价格 - * ] - * - * @return GetUEcPodPriceResponse * @throws UCloudException */ public function getUEcPodPrice(GetUEcPodPriceRequest $request = null) @@ -1130,31 +573,13 @@ public function getUEcPodPrice(GetUEcPodPriceRequest $request = null) $resp = $this->invoke($request); return new GetUEcPodPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcUpgradePrice - 获取虚拟机调整差价 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_upgrade_price - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (string) 虚拟机资源ID - * "CpuCore" => (integer) cpu核心数 - * "MemSize" => (integer) 内存大小,单位GB - * "SysDiskSize" => (integer) 系统盘大小,单位GB - * "DiskSize" => (integer) 数据盘大小,单位GB - * "NetLimit" => (integer) 节点带宽限制,单位Mbs - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (integer) 规格调整差价 - * ] - * - * @return GetUEcUpgradePriceResponse * @throws UCloudException */ public function getUEcUpgradePrice(GetUEcUpgradePriceRequest $request = null) @@ -1162,90 +587,13 @@ public function getUEcUpgradePrice(GetUEcUpgradePriceRequest $request = null) $resp = $this->invoke($request); return new GetUEcUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcVHostData - 获取虚拟机监控数据 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_v_host_data - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (string) 节点id - * "Type" => (array) 0CPU使用率, 1内存使用率, 2 网卡出流量, 3网卡入流量, 4网卡出包量, 5网卡入包量, 6磁盘读流量, 7磁盘写流量, 8磁盘读次数, 9磁盘写次数 - * "BeginTime" => (integer) 查询起始时间 - * "EndTime" => (integer) 查询结束时间 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSets" => (object) 带宽数据实例集合[ - * "CPUUtilization" => (array) cpu使用率[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "MemUtilization" => (array) 内存使用率[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICOut" => (array) 网卡出带宽[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NICIn" => (array) 网卡入带宽[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketOut" => (array) 网卡出包量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "NetPacketIn" => (array) 网卡入包量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "IORead" => (array) 磁盘读取量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "IOWrite" => (array) 磁盘写入量[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "DiskReadOps" => (array) 磁盘读取次数[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * "DiskWriteOps" => (array) 磁盘写入次数[ - * [ - * "TimeStamp" => (integer) 时间戳 - * "Value" => (integer) 值 - * ] - * ] - * ] - * ] - * - * @return GetUEcVHostDataResponse * @throws UCloudException */ public function getUEcVHostData(GetUEcVHostDataRequest $request = null) @@ -1253,38 +601,13 @@ public function getUEcVHostData(GetUEcVHostDataRequest $request = null) $resp = $this->invoke($request); return new GetUEcVHostDataResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUEcVHostPrice - 获取虚拟机价格 * - * See also: https://docs.ucloud.cn/api/uec-api/get_u_ec_v_host_price - * - * Arguments: - * - * $args = [ - * "IdcId" => (string) 机房Id - * "NodeCount" => (integer) 节点数量,默认1 - * "CpuCore" => (integer) CPU核数 - * "MemSize" => (integer) 内存大小,单位GB - * "SysDiskSize" => (integer) 系统盘大小,单位GB - * "DiskSize" => (integer) 数据盘大小,单位GB - * "NetLimit" => (integer) 网络带宽限速,单位Mbs - * "ChargeType" => (integer) 付费方式,1按时,2按月,3按年,默认2 - * "ChargeQuantity" => (integer) 月数或者年数,0计费到月底, 默认0 - * "ProductType" => (string) 产品类型:normal(经济型),hf(标准型),g(Gpu型),默认normal - * "IpCount" => (integer) 外网IP的数量,默认1 - * "Gpu" => (integer) Gpu卡核心数。仅Gpu机型支持此字段 - * "GpuType" => (string) Gpu类型,枚举值["T4"],ProductType为g时必填 - * ] - * - * Outputs: - * - * $outputs = [ - * "NodePrice" => (number) 节点价格 - * "IpPrice" => (number) Ip和带宽价格 - * ] - * - * @return GetUEcVHostPriceResponse * @throws UCloudException */ public function getUEcVHostPrice(GetUEcVHostPriceRequest $request = null) @@ -1292,32 +615,13 @@ public function getUEcVHostPrice(GetUEcVHostPriceRequest $request = null) $resp = $this->invoke($request); return new GetUEcVHostPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ImportUEcCustomImage - 导入自定义镜像 * - * See also: https://docs.ucloud.cn/api/uec-api/import_u_ec_custom_image - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "IdcId" => (array) 镜像需要导入机房,默认分发到所有机房 - * "ImageId" => (string) 镜像Id,不传参表示新导入镜像,传参表示已有镜像分发到指定机房 - * "ImageName" => (string) 镜像名称,不带镜像ID时必填 - * "UFileUrl" => (string) UFile镜像文件下载地址,不带镜像ID时必填 - * "OsType" => (string) 操作系统平台,linux、windows(当前版本暂不支持windows),不带镜像ID时必填 - * "Format" => (string) 镜像格式,可选RAW、qcow2, 不带镜像ID时必填 - * "ImageDesc" => (string) 镜像描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageId" => (string) 镜像Id - * ] - * - * @return ImportUEcCustomImageResponse * @throws UCloudException */ public function importUEcCustomImage(ImportUEcCustomImageRequest $request = null) @@ -1325,29 +629,13 @@ public function importUEcCustomImage(ImportUEcCustomImageRequest $request = null $resp = $this->invoke($request); return new ImportUEcCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * LoginUEcDocker - 登录容器 * - * See also: https://docs.ucloud.cn/api/uec-api/login_u_ec_docker - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ResourceId" => (string) 容器组资源id - * "Name" => (string) 容器名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "SessionId" => (string) 返回的token - * "Link" => (string) 登录地址 - * "LinkPort" => (integer) 登录端口 - * ] - * - * @return LoginUEcDockerResponse * @throws UCloudException */ public function loginUEcDocker(LoginUEcDockerRequest $request = null) @@ -1355,26 +643,13 @@ public function loginUEcDocker(LoginUEcDockerRequest $request = null) $resp = $this->invoke($request); return new LoginUEcDockerResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUEcBandwidth - 修改节点带宽限制 * - * See also: https://docs.ucloud.cn/api/uec-api/modify_u_ec_bandwidth - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (string) 节点Id - * "NetLimit" => (string) 节点带宽限制,单位Mbs - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUEcBandwidthResponse * @throws UCloudException */ public function modifyUEcBandwidth(ModifyUEcBandwidthRequest $request = null) @@ -1382,26 +657,13 @@ public function modifyUEcBandwidth(ModifyUEcBandwidthRequest $request = null) $resp = $this->invoke($request); return new ModifyUEcBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUEcHolderName - 修改容器组名称 * - * See also: https://docs.ucloud.cn/api/uec-api/modify_u_ec_holder_name - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ResourceId" => (string) 容器组资源id - * "Name" => (string) 容器组名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUEcHolderNameResponse * @throws UCloudException */ public function modifyUEcHolderName(ModifyUEcHolderNameRequest $request = null) @@ -1409,27 +671,13 @@ public function modifyUEcHolderName(ModifyUEcHolderNameRequest $request = null) $resp = $this->invoke($request); return new ModifyUEcHolderNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUEcImageName - 修改镜像名称 * - * See also: https://docs.ucloud.cn/api/uec-api/modify_u_ec_image_name - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageId" => (string) 镜像ID - * "ImageName" => (string) 镜像名称 - * "ImageDesc" => (string) 镜像描述 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUEcImageNameResponse * @throws UCloudException */ public function modifyUEcImageName(ModifyUEcImageNameRequest $request = null) @@ -1437,25 +685,13 @@ public function modifyUEcImageName(ModifyUEcImageNameRequest $request = null) $resp = $this->invoke($request); return new ModifyUEcImageNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PoweroffUEcVHost - 虚拟机断电 * - * See also: https://docs.ucloud.cn/api/uec-api/poweroff_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 虚拟机资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return PoweroffUEcVHostResponse * @throws UCloudException */ public function poweroffUEcVHost(PoweroffUEcVHostRequest $request = null) @@ -1463,29 +699,13 @@ public function poweroffUEcVHost(PoweroffUEcVHostRequest $request = null) $resp = $this->invoke($request); return new PoweroffUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReinstallUEcVHost - 虚拟机重装系统 * - * See also: https://docs.ucloud.cn/api/uec-api/reinstall_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (string) 虚拟机资源ID - * "ImageId" => (string) 镜像ID - * "KeepData" => (integer) 是否保留数据盘数据, 0-不保留,1-保留,默认为1 - * "Password" => (string) 节点密码 - * "SysDiskSize" => (integer) 系统盘大小,单位GB - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReinstallUEcVHostResponse * @throws UCloudException */ public function reinstallUEcVHost(ReinstallUEcVHostRequest $request = null) @@ -1493,25 +713,13 @@ public function reinstallUEcVHost(ReinstallUEcVHostRequest $request = null) $resp = $this->invoke($request); return new ReinstallUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartUEcHolder - 重启容器组 * - * See also: https://docs.ucloud.cn/api/uec-api/restart_u_ec_holder - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ResourceId" => (array) 容器组资源id,n为0,1,2... - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartUEcHolderResponse * @throws UCloudException */ public function restartUEcHolder(RestartUEcHolderRequest $request = null) @@ -1519,25 +727,13 @@ public function restartUEcHolder(RestartUEcHolderRequest $request = null) $resp = $this->invoke($request); return new RestartUEcHolderResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartUEcVHost - 重启虚拟机v2.0 * - * See also: https://docs.ucloud.cn/api/uec-api/restart_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 节点id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartUEcVHostResponse * @throws UCloudException */ public function restartUEcVHost(RestartUEcVHostRequest $request = null) @@ -1545,25 +741,13 @@ public function restartUEcVHost(RestartUEcVHostRequest $request = null) $resp = $this->invoke($request); return new RestartUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StartUEcVHost - 启动UEC虚拟机 * - * See also: https://docs.ucloud.cn/api/uec-api/start_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 虚拟机资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return StartUEcVHostResponse * @throws UCloudException */ public function startUEcVHost(StartUEcVHostRequest $request = null) @@ -1571,25 +755,13 @@ public function startUEcVHost(StartUEcVHostRequest $request = null) $resp = $this->invoke($request); return new StartUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StopUEcVHost - 停止UEC虚拟机 * - * See also: https://docs.ucloud.cn/api/uec-api/stop_u_ec_v_host - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NodeId" => (array) 虚拟机资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return StopUEcVHostResponse * @throws UCloudException */ public function stopUEcVHost(StopUEcVHostRequest $request = null) @@ -1597,26 +769,13 @@ public function stopUEcVHost(StopUEcVHostRequest $request = null) $resp = $this->invoke($request); return new StopUEcVHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UnBindUEcFirewall - 解绑防火墙 * - * See also: https://docs.ucloud.cn/api/uec-api/un_bind_u_ec_firewall - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙Id - * "ResourceId" => (string) 节点Id或容器组资源id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UnBindUEcFirewallResponse * @throws UCloudException */ public function unBindUEcFirewall(UnBindUEcFirewallRequest $request = null) @@ -1624,35 +783,13 @@ public function unBindUEcFirewall(UnBindUEcFirewallRequest $request = null) $resp = $this->invoke($request); return new UnBindUEcFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUEcFirewall - 更新防火墙信息,新增和删除规则 * - * See also: https://docs.ucloud.cn/api/uec-api/update_u_ec_firewall - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙Id - * "Rule" => (array) [ - * [ - * "ProtocolType" => (string) 协议,可选值:TCP,UDP,ICMP - * "Port" => (string) 端口,范围用"-"符号分隔,如:1-65535 - * "SrcIp" => (string) 源ip - * "Action" => (string) ACCEPT(接受)和DROP(拒绝) - * "Priority" => (string) 优先级:HIGH(高),MEDIUM(中),LOW(低) - * "Remark" => (string) 备注 - * ] - * ] - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUEcFirewallResponse * @throws UCloudException */ public function updateUEcFirewall(UpdateUEcFirewallRequest $request = null) @@ -1660,27 +797,13 @@ public function updateUEcFirewall(UpdateUEcFirewallRequest $request = null) $resp = $this->invoke($request); return new UpdateUEcFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUEcFirewallAttribute - 更新防火墙名称及描述 * - * See also: https://docs.ucloud.cn/api/uec-api/update_u_ec_firewall_attribute - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FirewallId" => (string) 防火墙Id - * "Name" => (string) 防火墙名称 - * "Remark" => (string) 描述 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUEcFirewallAttributeResponse * @throws UCloudException */ public function updateUEcFirewallAttribute(UpdateUEcFirewallAttributeRequest $request = null) @@ -1688,27 +811,13 @@ public function updateUEcFirewallAttribute(UpdateUEcFirewallAttributeRequest $re $resp = $this->invoke($request); return new UpdateUEcFirewallAttributeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUEcSubnet - 更新子网信息 * - * See also: https://docs.ucloud.cn/api/uec-api/update_u_ec_subnet - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SubnetId" => (string) 子网ID - * "SubnetName" => (string) 子网名称 - * "Comment" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUEcSubnetResponse * @throws UCloudException */ public function updateUEcSubnet(UpdateUEcSubnetRequest $request = null) diff --git a/src/UFS/Apis/AddUFSVolumeMountPointRequest.php b/src/UFS/Apis/AddUFSVolumeMountPointRequest.php new file mode 100644 index 00000000..c777dc6e --- /dev/null +++ b/src/UFS/Apis/AddUFSVolumeMountPointRequest.php @@ -0,0 +1,150 @@ + "AddUFSVolumeMountPoint"]); + $this->markRequired("Region"); + $this->markRequired("VolumeId"); + $this->markRequired("MountPointName"); + $this->markRequired("VpcId"); + $this->markRequired("SubnetId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * VolumeId: 文件系统ID + * + * @return string|null + */ + public function getVolumeId() + { + return $this->get("VolumeId"); + } + + /** + * VolumeId: 文件系统ID + * + * @param string $volumeId + */ + public function setVolumeId(string $volumeId) + { + $this->set("VolumeId", $volumeId); + } + /** + * MountPointName: 挂载点名称 + * + * @return string|null + */ + public function getMountPointName() + { + return $this->get("MountPointName"); + } + + /** + * MountPointName: 挂载点名称 + * + * @param string $mountPointName + */ + public function setMountPointName(string $mountPointName) + { + $this->set("MountPointName", $mountPointName); + } + /** + * VpcId: Vpc ID + * + * @return string|null + */ + public function getVpcId() + { + return $this->get("VpcId"); + } + + /** + * VpcId: Vpc ID + * + * @param string $vpcId + */ + public function setVpcId(string $vpcId) + { + $this->set("VpcId", $vpcId); + } + /** + * SubnetId: Subnet ID + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: Subnet ID + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } +} diff --git a/src/UFS/Apis/AddUFSVolumeMountPointResponse.php b/src/UFS/Apis/AddUFSVolumeMountPointResponse.php new file mode 100644 index 00000000..cbf5d0de --- /dev/null +++ b/src/UFS/Apis/AddUFSVolumeMountPointResponse.php @@ -0,0 +1,26 @@ +markRequired("ProtocolType"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -42,17 +43,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -62,17 +62,16 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * Size: 文件系统大小,单位为GB,最大不超过20T,香港容量型必须为100的整数倍,Size最小为500GB,北京,上海,广州的容量型必须为1024的整数倍,Size最小为1024GB。性能型文件系统Size最小为100GB + * Size: 文件系统大小,单位为GB,必须为100的整数倍,容量型Size最小为500GB,性能型文件系统Size最小为100GB * * @return integer|null */ @@ -82,17 +81,16 @@ public function getSize() } /** - * Size: 文件系统大小,单位为GB,最大不超过20T,香港容量型必须为100的整数倍,Size最小为500GB,北京,上海,广州的容量型必须为1024的整数倍,Size最小为1024GB。性能型文件系统Size最小为100GB + * Size: 文件系统大小,单位为GB,必须为100的整数倍,容量型Size最小为500GB,性能型文件系统Size最小为100GB * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** - * StorageType: 文件系统存储类型,枚举值,Basic表示容量型,Advanced表示性能型 + * StorageType: 文件系统存储类型,Basic表示容量型,Advanced表示性能型 * * @return string|null */ @@ -102,17 +100,16 @@ public function getStorageType() } /** - * StorageType: 文件系统存储类型,枚举值,Basic表示容量型,Advanced表示性能型 + * StorageType: 文件系统存储类型,Basic表示容量型,Advanced表示性能型 * * @param string $storageType */ - public function setStorageType($storageType) + public function setStorageType(string $storageType) { $this->set("StorageType", $storageType); } - /** - * ProtocolType: 文件系统协议,枚举值,NFSv3表示NFS V3协议,NFSv4表示NFS V4协议 + * ProtocolType: 文件系统协议,目前仅支持NFSv4 * * @return string|null */ @@ -122,15 +119,14 @@ public function getProtocolType() } /** - * ProtocolType: 文件系统协议,枚举值,NFSv3表示NFS V3协议,NFSv4表示NFS V4协议 + * ProtocolType: 文件系统协议,目前仅支持NFSv4 * * @param string $protocolType */ - public function setProtocolType($protocolType) + public function setProtocolType(string $protocolType) { $this->set("ProtocolType", $protocolType); } - /** * VolumeName: 文件系统名称 * @@ -146,11 +142,10 @@ public function getVolumeName() * * @param string $volumeName */ - public function setVolumeName($volumeName) + public function setVolumeName(string $volumeName) { $this->set("VolumeName", $volumeName); } - /** * Remark: 备注 * @@ -166,11 +161,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 文件系统所属业务组 * @@ -186,11 +180,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ChargeType: 计费模式,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费(需开启权限); Trial,试用(需开启权限) 默认为Dynamic * @@ -206,11 +199,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -226,11 +218,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * CouponId: 使用的代金券id * @@ -246,7 +237,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UFS/Apis/CreateUFSVolumeResponse.php b/src/UFS/Apis/CreateUFSVolumeResponse.php index e8e5e70b..e46dab5e 100644 --- a/src/UFS/Apis/CreateUFSVolumeResponse.php +++ b/src/UFS/Apis/CreateUFSVolumeResponse.php @@ -1,6 +1,7 @@ set("VolumeName", $volumeName); } - /** * VolumeId: 文件系统ID * @@ -57,11 +57,10 @@ public function getVolumeId() * * @param string $volumeId */ - public function setVolumeId($volumeId) + public function setVolumeId(string $volumeId) { $this->set("VolumeId", $volumeId); } - /** * VolumeStatus: 文件系统挂载点状态 * @@ -77,7 +76,7 @@ public function getVolumeStatus() * * @param string $volumeStatus */ - public function setVolumeStatus($volumeStatus) + public function setVolumeStatus(string $volumeStatus) { $this->set("VolumeStatus", $volumeStatus); } diff --git a/src/UFS/Apis/DescribeUFSVolume2Request.php b/src/UFS/Apis/DescribeUFSVolume2Request.php index 9442351c..47da3491 100644 --- a/src/UFS/Apis/DescribeUFSVolume2Request.php +++ b/src/UFS/Apis/DescribeUFSVolume2Request.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VolumeId: 文件系统ID * @@ -83,11 +82,10 @@ public function getVolumeId() * * @param string $volumeId */ - public function setVolumeId($volumeId) + public function setVolumeId(string $volumeId) { $this->set("VolumeId", $volumeId); } - /** * Offset: 文件列表起始 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 文件列表长度 * @@ -123,7 +120,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UFS/Apis/DescribeUFSVolume2Response.php b/src/UFS/Apis/DescribeUFSVolume2Response.php index 815db5c2..96d2cbb7 100644 --- a/src/UFS/Apis/DescribeUFSVolume2Response.php +++ b/src/UFS/Apis/DescribeUFSVolume2Response.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 文件系统详细信息列表 * - * @return UFSVolumeInfo2[]|null + * @return UFSVolumeInfo2Model[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UFSVolumeInfo2($item)); + array_push($result, new UFSVolumeInfo2Model($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 文件系统详细信息列表 * - * @param UFSVolumeInfo2[] $dataSet + * @param UFSVolumeInfo2Model[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFS/Apis/DescribeUFSVolumeMountpointRequest.php b/src/UFS/Apis/DescribeUFSVolumeMountpointRequest.php new file mode 100644 index 00000000..44c2ff6d --- /dev/null +++ b/src/UFS/Apis/DescribeUFSVolumeMountpointRequest.php @@ -0,0 +1,90 @@ + "DescribeUFSVolumeMountpoint"]); + $this->markRequired("Region"); + $this->markRequired("VolumeId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * VolumeId: 文件系统ID + * + * @return string|null + */ + public function getVolumeId() + { + return $this->get("VolumeId"); + } + + /** + * VolumeId: 文件系统ID + * + * @param string $volumeId + */ + public function setVolumeId(string $volumeId) + { + $this->set("VolumeId", $volumeId); + } +} diff --git a/src/UFS/Apis/DescribeUFSVolumeMountpointResponse.php b/src/UFS/Apis/DescribeUFSVolumeMountpointResponse.php new file mode 100644 index 00000000..ddd70a3d --- /dev/null +++ b/src/UFS/Apis/DescribeUFSVolumeMountpointResponse.php @@ -0,0 +1,97 @@ +get("DataSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new MountPointInfoModel($item)); + } + return $result; + } + + /** + * DataSet: + * + * @param MountPointInfoModel[] $dataSet + */ + public function setDataSet(array $dataSet) + { + $result = []; + foreach ($dataSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * TotalMountPointNum: 目前的挂载点总数 + * + * @return integer|null + */ + public function getTotalMountPointNum() + { + return $this->get("TotalMountPointNum"); + } + + /** + * TotalMountPointNum: 目前的挂载点总数 + * + * @param int $totalMountPointNum + */ + public function setTotalMountPointNum(int $totalMountPointNum) + { + $this->set("TotalMountPointNum", $totalMountPointNum); + } + /** + * MaxMountPointNum: 文件系统能创建的最大挂载点数目 + * + * @return integer|null + */ + public function getMaxMountPointNum() + { + return $this->get("MaxMountPointNum"); + } + + /** + * MaxMountPointNum: 文件系统能创建的最大挂载点数目 + * + * @param int $maxMountPointNum + */ + public function setMaxMountPointNum(int $maxMountPointNum) + { + $this->set("MaxMountPointNum", $maxMountPointNum); + } +} diff --git a/src/UFS/Apis/DescribeUFSVolumePriceRequest.php b/src/UFS/Apis/DescribeUFSVolumePriceRequest.php new file mode 100644 index 00000000..514466e3 --- /dev/null +++ b/src/UFS/Apis/DescribeUFSVolumePriceRequest.php @@ -0,0 +1,167 @@ + "DescribeUFSVolumePrice"]); + $this->markRequired("Region"); + $this->markRequired("Size"); + $this->markRequired("StorageType"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * Size: 文件系统大小,单位为GB,新架构容量型最小容量为500GB,以100GB递增,最大不超过100TB。新架构性能型最小容量为100GB,以100GB递增,最大不超过20TB + * + * @return integer|null + */ + public function getSize() + { + return $this->get("Size"); + } + + /** + * Size: 文件系统大小,单位为GB,新架构容量型最小容量为500GB,以100GB递增,最大不超过100TB。新架构性能型最小容量为100GB,以100GB递增,最大不超过20TB + * + * @param int $size + */ + public function setSize(int $size) + { + $this->set("Size", $size); + } + /** + * StorageType: 文件存储类型,枚举值,Basic表示容量型产品,Advanced表示性能型产品 + * + * @return string|null + */ + public function getStorageType() + { + return $this->get("StorageType"); + } + + /** + * StorageType: 文件存储类型,枚举值,Basic表示容量型产品,Advanced表示性能型产品 + * + * @param string $storageType + */ + public function setStorageType(string $storageType) + { + $this->set("StorageType", $storageType); + } + /** + * Quantity: 购买UFS的时长, 默认为1 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买UFS的时长, 默认为1 + * + * @param int $quantity + */ + public function setQuantity(int $quantity) + { + $this->set("Quantity", $quantity); + } + /** + * ChargeType: Year, Month, Dynamic,Trial,默认: Dynamic + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: Year, Month, Dynamic,Trial,默认: Dynamic + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * VolumeId: 文件系统id,第一次创建文件系统时不需要传这个参数 + * + * @return string|null + */ + public function getVolumeId() + { + return $this->get("VolumeId"); + } + + /** + * VolumeId: 文件系统id,第一次创建文件系统时不需要传这个参数 + * + * @param string $volumeId + */ + public function setVolumeId(string $volumeId) + { + $this->set("VolumeId", $volumeId); + } +} diff --git a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeResponse.php b/src/UFS/Apis/DescribeUFSVolumePriceResponse.php similarity index 59% rename from src/UCDN/Apis/GetNewUcdnDomainHttpCodeResponse.php rename to src/UFS/Apis/DescribeUFSVolumePriceResponse.php index 80025a08..320dec6b 100644 --- a/src/UCDN/Apis/GetNewUcdnDomainHttpCodeResponse.php +++ b/src/UFS/Apis/DescribeUFSVolumePriceResponse.php @@ -1,6 +1,7 @@ get("HttpCodeDetail"); + $items = $this->get("DataSet"); if ($items == null) { return []; } $result = []; foreach ($items as $i => $item) { - array_push($result, new HttpCodeInfo($item)); + array_push($result, new UFSPriceDataSetModel($item)); } return $result; } /** - * HttpCodeDetail: 状态码实例表。详细见HttpCodeInfo + * DataSet: ufs 价格信息 * - * @param HttpCodeInfo[] $httpCodeDetail + * @param UFSPriceDataSetModel[] $dataSet */ - public function setHttpCodeDetail(array $httpCodeDetail) + public function setDataSet(array $dataSet) { $result = []; - foreach ($httpCodeDetail as $i => $item) { + foreach ($dataSet as $i => $item) { array_push($result, $item->getAll()); } return $result; diff --git a/src/UFS/Apis/ExtendUFSVolumeRequest.php b/src/UFS/Apis/ExtendUFSVolumeRequest.php index 36fbd607..9715b0c9 100644 --- a/src/UFS/Apis/ExtendUFSVolumeRequest.php +++ b/src/UFS/Apis/ExtendUFSVolumeRequest.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VolumeId: 文件系统ID * @@ -85,11 +84,10 @@ public function getVolumeId() * * @param string $volumeId */ - public function setVolumeId($volumeId) + public function setVolumeId(string $volumeId) { $this->set("VolumeId", $volumeId); } - /** * Size: 文件系统大小,单位为GB,最大不超过20T,香港容量型必须为100的整数倍,Size最小为500GB,北京,上海,广州的容量型必须为1024的整数倍,Size最小为1024GB。性能型文件系统Size最小为100GB * @@ -105,7 +103,7 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } diff --git a/src/UFS/Apis/ExtendUFSVolumeResponse.php b/src/UFS/Apis/ExtendUFSVolumeResponse.php index adba4756..d67d7c65 100644 --- a/src/UFS/Apis/ExtendUFSVolumeResponse.php +++ b/src/UFS/Apis/ExtendUFSVolumeResponse.php @@ -1,6 +1,7 @@ "RemoveUFSVolumeMountPoint"]); + $this->markRequired("Region"); + $this->markRequired("VolumeId"); + $this->markRequired("VpcId"); + $this->markRequired("SubnetId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * VolumeId: 文件系统ID + * + * @return string|null + */ + public function getVolumeId() + { + return $this->get("VolumeId"); + } + + /** + * VolumeId: 文件系统ID + * + * @param string $volumeId + */ + public function setVolumeId(string $volumeId) + { + $this->set("VolumeId", $volumeId); + } + /** + * VpcId: Vpc ID + * + * @return string|null + */ + public function getVpcId() + { + return $this->get("VpcId"); + } + + /** + * VpcId: Vpc ID + * + * @param string $vpcId + */ + public function setVpcId(string $vpcId) + { + $this->set("VpcId", $vpcId); + } + /** + * SubnetId: Subnet ID + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: Subnet ID + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } +} diff --git a/src/UFS/Apis/RemoveUFSVolumeMountPointResponse.php b/src/UFS/Apis/RemoveUFSVolumeMountPointResponse.php new file mode 100644 index 00000000..33fb48b9 --- /dev/null +++ b/src/UFS/Apis/RemoveUFSVolumeMountPointResponse.php @@ -0,0 +1,26 @@ +markRequired("VolumeId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VolumeId: 文件系统ID * @@ -84,7 +83,7 @@ public function getVolumeId() * * @param string $volumeId */ - public function setVolumeId($volumeId) + public function setVolumeId(string $volumeId) { $this->set("VolumeId", $volumeId); } diff --git a/src/UFS/Apis/RemoveUFSVolumeResponse.php b/src/UFS/Apis/RemoveUFSVolumeResponse.php index 8286c869..c3cf99aa 100644 --- a/src/UFS/Apis/RemoveUFSVolumeResponse.php +++ b/src/UFS/Apis/RemoveUFSVolumeResponse.php @@ -1,6 +1,7 @@ "UpdateUFSVolumeInfo"]); + $this->markRequired("Region"); + $this->markRequired("VolumeId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * VolumeId: 文件系统ID + * + * @return string|null + */ + public function getVolumeId() + { + return $this->get("VolumeId"); + } + + /** + * VolumeId: 文件系统ID + * + * @param string $volumeId + */ + public function setVolumeId(string $volumeId) + { + $this->set("VolumeId", $volumeId); + } + /** + * VolumeName: 文件系统名称(文件系统名称/备注至少传入其中一个) + * + * @return string|null + */ + public function getVolumeName() + { + return $this->get("VolumeName"); + } + + /** + * VolumeName: 文件系统名称(文件系统名称/备注至少传入其中一个) + * + * @param string $volumeName + */ + public function setVolumeName(string $volumeName) + { + $this->set("VolumeName", $volumeName); + } + /** + * Remark: 文件系统备注(文件系统名称/备注至少传入其中一个) + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 文件系统备注(文件系统名称/备注至少传入其中一个) + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } +} diff --git a/src/UFS/Apis/UpdateUFSVolumeInfoResponse.php b/src/UFS/Apis/UpdateUFSVolumeInfoResponse.php new file mode 100644 index 00000000..07a1f567 --- /dev/null +++ b/src/UFS/Apis/UpdateUFSVolumeInfoResponse.php @@ -0,0 +1,26 @@ +get("MountPointName"); + } + + /** + * MountPointName: 挂载点名称 + * + * @param string $mountPointName + */ + public function setMountPointName(string $mountPointName) + { + $this->set("MountPointName", $mountPointName); + } + /** + * VpcId: Vpc ID + * + * @return string|null + */ + public function getVpcId() + { + return $this->get("VpcId"); + } + + /** + * VpcId: Vpc ID + * + * @param string $vpcId + */ + public function setVpcId(string $vpcId) + { + $this->set("VpcId", $vpcId); + } + /** + * SubnetId: Subnet ID + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: Subnet ID + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } + /** + * MountPointIp: ${挂载点IP}:/ + * + * @return string|null + */ + public function getMountPointIp() + { + return $this->get("MountPointIp"); + } + + /** + * MountPointIp: ${挂载点IP}:/ + * + * @param string $mountPointIp + */ + public function setMountPointIp(string $mountPointIp) + { + $this->set("MountPointIp", $mountPointIp); + } + /** + * CreateTime: 文件系统创建时间(unix时间戳) + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 文件系统创建时间(unix时间戳) + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * SubnetDescription: Subnet ID + 网段的形式,方便前端展示 + * + * @return string|null + */ + public function getSubnetDescription() + { + return $this->get("SubnetDescription"); + } + + /** + * SubnetDescription: Subnet ID + 网段的形式,方便前端展示 + * + * @param string $subnetDescription + */ + public function setSubnetDescription(string $subnetDescription) + { + $this->set("SubnetDescription", $subnetDescription); + } +} diff --git a/src/UFS/Models/UFSPriceDataSet.php b/src/UFS/Models/UFSPriceDataSet.php new file mode 100644 index 00000000..0b693d5f --- /dev/null +++ b/src/UFS/Models/UFSPriceDataSet.php @@ -0,0 +1,85 @@ +get("ChargeType"); + } + + /** + * ChargeType: Year, Month, Dynamic,Trial + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * Price: 价格 (单位: 分) + * + * @return float|null + */ + public function getPrice() + { + return $this->get("Price"); + } + + /** + * Price: 价格 (单位: 分) + * + * @param float $price + */ + public function setPrice(float $price) + { + $this->set("Price", $price); + } + /** + * ChargeName: “UFS” + * + * @return string|null + */ + public function getChargeName() + { + return $this->get("ChargeName"); + } + + /** + * ChargeName: “UFS” + * + * @param string $chargeName + */ + public function setChargeName(string $chargeName) + { + $this->set("ChargeName", $chargeName); + } +} diff --git a/src/UFS/Models/UFSVolumeInfo2.php b/src/UFS/Models/UFSVolumeInfo2.php index 11bea829..faf01a58 100644 --- a/src/UFS/Models/UFSVolumeInfo2.php +++ b/src/UFS/Models/UFSVolumeInfo2.php @@ -1,6 +1,7 @@ set("VolumeName", $volumeName); } - /** * VolumeId: 文件系统ID * @@ -57,11 +59,10 @@ public function getVolumeId() * * @param string $volumeId */ - public function setVolumeId($volumeId) + public function setVolumeId(string $volumeId) { $this->set("VolumeId", $volumeId); } - /** * TotalMountPointNum: 当前文件系统已创建的挂载点数目 * @@ -77,11 +78,10 @@ public function getTotalMountPointNum() * * @param int $totalMountPointNum */ - public function setTotalMountPointNum($totalMountPointNum) + public function setTotalMountPointNum(int $totalMountPointNum) { $this->set("TotalMountPointNum", $totalMountPointNum); } - /** * MaxMountPointNum: 文件系统允许创建的最大挂载点数目 * @@ -97,11 +97,10 @@ public function getMaxMountPointNum() * * @param int $maxMountPointNum */ - public function setMaxMountPointNum($maxMountPointNum) + public function setMaxMountPointNum(int $maxMountPointNum) { $this->set("MaxMountPointNum", $maxMountPointNum); } - /** * StorageType: 文件系统存储类型,枚举值,Basic表示容量型,Advanced表示性能型 * @@ -117,11 +116,10 @@ public function getStorageType() * * @param string $storageType */ - public function setStorageType($storageType) + public function setStorageType(string $storageType) { $this->set("StorageType", $storageType); } - /** * ProtocolType: 文件系统协议,枚举值,NFSv3表示NFS V3协议,NFSv4表示NFS V4协议 * @@ -137,11 +135,10 @@ public function getProtocolType() * * @param string $protocolType */ - public function setProtocolType($protocolType) + public function setProtocolType(string $protocolType) { $this->set("ProtocolType", $protocolType); } - /** * Remark: 文件系统备注信息 * @@ -157,11 +154,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 文件系统所属业务组 * @@ -177,11 +173,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * CreateTime: 文件系统创建时间(unix时间戳) * @@ -197,11 +192,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpiredTime: 文件系统过期时间(unix时间戳) * @@ -217,11 +211,10 @@ public function getExpiredTime() * * @param int $expiredTime */ - public function setExpiredTime($expiredTime) + public function setExpiredTime(int $expiredTime) { $this->set("ExpiredTime", $expiredTime); } - /** * Size: 文件系统大小,单位GB * @@ -237,11 +230,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 文件系统当前使用容量,单位GB * @@ -257,11 +249,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * IsExpired: 是否过期 * @@ -277,7 +268,7 @@ public function getIsExpired() * * @param string $isExpired */ - public function setIsExpired($isExpired) + public function setIsExpired(string $isExpired) { $this->set("IsExpired", $isExpired); } diff --git a/src/UFS/UFSClient.php b/src/UFS/UFSClient.php index 26edd25f..428896b6 100644 --- a/src/UFS/UFSClient.php +++ b/src/UFS/UFSClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Size" => (integer) 文件系统大小,单位为GB,最大不超过20T,香港容量型必须为100的整数倍,Size最小为500GB,北京,上海,广州的容量型必须为1024的整数倍,Size最小为1024GB。性能型文件系统Size最小为100GB - * "StorageType" => (string) 文件系统存储类型,枚举值,Basic表示容量型,Advanced表示性能型 - * "ProtocolType" => (string) 文件系统协议,枚举值,NFSv3表示NFS V3协议,NFSv4表示NFS V4协议 - * "VolumeName" => (string) 文件系统名称 - * "Remark" => (string) 备注 - * "Tag" => (string) 文件系统所属业务组 - * "ChargeType" => (string) 计费模式,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费(需开启权限); Trial,试用(需开启权限) 默认为Dynamic - * "Quantity" => (integer) 购买时长 默认: 1 - * "CouponId" => (string) 使用的代金券id - * ] + * AddUFSVolumeMountPoint - 添加文件系统挂载点 * - * Outputs: - * - * $outputs = [ - * "VolumeName" => (string) 文件系统名称 - * "VolumeId" => (string) 文件系统ID - * "VolumeStatus" => (string) 文件系统挂载点状态 - * ] + * @throws UCloudException + */ + public function addUFSVolumeMountPoint(AddUFSVolumeMountPointRequest $request = null) + { + $resp = $this->invoke($request); + return new AddUFSVolumeMountPointResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateUFSVolume - 创建文件系统 * - * @return CreateUFSVolumeResponse * @throws UCloudException */ public function createUFSVolume(CreateUFSVolumeRequest $request = null) @@ -70,46 +100,13 @@ public function createUFSVolume(CreateUFSVolumeRequest $request = null) $resp = $this->invoke($request); return new CreateUFSVolumeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUFSVolume2 - 获取文件系统列表 * - * See also: https://docs.ucloud.cn/api/ufs-api/describe_ufs_volume2 - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VolumeId" => (string) 文件系统ID - * "Offset" => (integer) 文件列表起始 - * "Limit" => (integer) 文件列表长度 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 文件系统总数 - * "DataSet" => (array) 文件系统详细信息列表[ - * [ - * "VolumeName" => (string) 文件系统名称 - * "VolumeId" => (string) 文件系统ID - * "TotalMountPointNum" => (integer) 当前文件系统已创建的挂载点数目 - * "MaxMountPointNum" => (integer) 文件系统允许创建的最大挂载点数目 - * "StorageType" => (string) 文件系统存储类型,枚举值,Basic表示容量型,Advanced表示性能型 - * "ProtocolType" => (string) 文件系统协议,枚举值,NFSv3表示NFS V3协议,NFSv4表示NFS V4协议 - * "Remark" => (string) 文件系统备注信息 - * "Tag" => (string) 文件系统所属业务组 - * "CreateTime" => (integer) 文件系统创建时间(unix时间戳) - * "ExpiredTime" => (integer) 文件系统过期时间(unix时间戳) - * "Size" => (integer) 文件系统大小,单位GB - * "UsedSize" => (integer) 文件系统当前使用容量,单位GB - * "IsExpired" => (string) 是否过期 - * ] - * ] - * ] - * - * @return DescribeUFSVolume2Response * @throws UCloudException */ public function describeUFSVolume2(DescribeUFSVolume2Request $request = null) @@ -117,27 +114,41 @@ public function describeUFSVolume2(DescribeUFSVolume2Request $request = null) $resp = $this->invoke($request); return new DescribeUFSVolume2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ExtendUFSVolume - 文件系统扩容 - * - * See also: https://docs.ucloud.cn/api/ufs-api/extend_ufs_volume - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VolumeId" => (string) 文件系统ID - * "Size" => (integer) 文件系统大小,单位为GB,最大不超过20T,香港容量型必须为100的整数倍,Size最小为500GB,北京,上海,广州的容量型必须为1024的整数倍,Size最小为1024GB。性能型文件系统Size最小为100GB - * ] + * DescribeUFSVolumeMountpoint - 获取文件系统挂载点信息 * - * Outputs: + * @throws UCloudException + */ + public function describeUFSVolumeMountpoint(DescribeUFSVolumeMountpointRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUFSVolumeMountpointResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUFSVolumePrice - 获取文件系统价格 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function describeUFSVolumePrice(DescribeUFSVolumePriceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUFSVolumePriceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ExtendUFSVolume - 文件系统扩容 * - * @return ExtendUFSVolumeResponse * @throws UCloudException */ public function extendUFSVolume(ExtendUFSVolumeRequest $request = null) @@ -145,26 +156,13 @@ public function extendUFSVolume(ExtendUFSVolumeRequest $request = null) $resp = $this->invoke($request); return new ExtendUFSVolumeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RemoveUFSVolume - 删除UFS文件系统 * - * See also: https://docs.ucloud.cn/api/ufs-api/remove_ufs_volume - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VolumeId" => (string) 文件系统ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RemoveUFSVolumeResponse * @throws UCloudException */ public function removeUFSVolume(RemoveUFSVolumeRequest $request = null) @@ -172,4 +170,32 @@ public function removeUFSVolume(RemoveUFSVolumeRequest $request = null) $resp = $this->invoke($request); return new RemoveUFSVolumeResponse($resp->toArray(), $resp->getRequestId()); } + + + + + /** + * RemoveUFSVolumeMountPoint - 删除文件系统挂载点 + * + * @throws UCloudException + */ + public function removeUFSVolumeMountPoint(RemoveUFSVolumeMountPointRequest $request = null) + { + $resp = $this->invoke($request); + return new RemoveUFSVolumeMountPointResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateUFSVolumeInfo - 更改文件系统相关信息(名称/备注) + * + * @throws UCloudException + */ + public function updateUFSVolumeInfo(UpdateUFSVolumeInfoRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateUFSVolumeInfoResponse($resp->toArray(), $resp->getRequestId()); + } } diff --git a/src/UFile/Apis/CreateBucketRequest.php b/src/UFile/Apis/CreateBucketRequest.php index b4203819..4ea4bd99 100644 --- a/src/UFile/Apis/CreateBucketRequest.php +++ b/src/UFile/Apis/CreateBucketRequest.php @@ -1,6 +1,7 @@ markRequired("BucketName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BucketName: 待创建Bucket的名称,具有全局唯一性 * @@ -84,11 +83,10 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } - /** * Type: Bucket访问类型,public或private; 默认为private * @@ -104,7 +102,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/UFile/Apis/CreateBucketResponse.php b/src/UFile/Apis/CreateBucketResponse.php index dbaab315..8c85475c 100644 --- a/src/UFile/Apis/CreateBucketResponse.php +++ b/src/UFile/Apis/CreateBucketResponse.php @@ -1,6 +1,7 @@ set("BucketName", $bucketName); } - /** * BucketId: 已创建Bucket的ID * @@ -57,7 +57,7 @@ public function getBucketId() * * @param string $bucketId */ - public function setBucketId($bucketId) + public function setBucketId(string $bucketId) { $this->set("BucketId", $bucketId); } diff --git a/src/UFile/Apis/CreateUFileLifeCycleRequest.php b/src/UFile/Apis/CreateUFileLifeCycleRequest.php new file mode 100644 index 00000000..d4ecb3c5 --- /dev/null +++ b/src/UFile/Apis/CreateUFileLifeCycleRequest.php @@ -0,0 +1,206 @@ + "CreateUFileLifeCycle"]); + $this->markRequired("LifeCycleName"); + $this->markRequired("Prefix"); + $this->markRequired("Status"); + $this->markRequired("BucketName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * LifeCycleName: 生命周期名称 + * + * @return string|null + */ + public function getLifeCycleName() + { + return $this->get("LifeCycleName"); + } + + /** + * LifeCycleName: 生命周期名称 + * + * @param string $lifeCycleName + */ + public function setLifeCycleName(string $lifeCycleName) + { + $this->set("LifeCycleName", $lifeCycleName); + } + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件;一条规则只支持一个文件前缀; + * + * @return string|null + */ + public function getPrefix() + { + return $this->get("Prefix"); + } + + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件;一条规则只支持一个文件前缀; + * + * @param string $prefix + */ + public function setPrefix(string $prefix) + { + $this->set("Prefix", $prefix); + } + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @param string $status + */ + public function setStatus(string $status) + { + $this->set("Status", $status); + } + /** + * BucketName: 存储空间名称 + * + * @return string|null + */ + public function getBucketName() + { + return $this->get("BucketName"); + } + + /** + * BucketName: 存储空间名称 + * + * @param string $bucketName + */ + public function setBucketName(string $bucketName) + { + $this->set("BucketName", $bucketName); + } + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除;参数范围:[7,36500],0代表不启用 + * + * @return integer|null + */ + public function getDays() + { + return $this->get("Days"); + } + + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除;参数范围:[7,36500],0代表不启用 + * + * @param int $days + */ + public function setDays(int $days) + { + $this->set("Days", $days); + } + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后,自动变为归档存储类型;参数范围:[7,36500],0代表不启用 + * + * @return integer|null + */ + public function getArchivalDays() + { + return $this->get("ArchivalDays"); + } + + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后,自动变为归档存储类型;参数范围:[7,36500],0代表不启用 + * + * @param int $archivalDays + */ + public function setArchivalDays(int $archivalDays) + { + $this->set("ArchivalDays", $archivalDays); + } + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后,自动变为低频存储类型;参数范围:[7,36500],0代表不启用 + * + * @return integer|null + */ + public function getIADays() + { + return $this->get("IADays"); + } + + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后,自动变为低频存储类型;参数范围:[7,36500],0代表不启用 + * + * @param int $iaDays + */ + public function setIADays(int $iaDays) + { + $this->set("IADays", $iaDays); + } +} diff --git a/src/UFile/Apis/CreateUFileLifeCycleResponse.php b/src/UFile/Apis/CreateUFileLifeCycleResponse.php new file mode 100644 index 00000000..42bab03e --- /dev/null +++ b/src/UFile/Apis/CreateUFileLifeCycleResponse.php @@ -0,0 +1,45 @@ +get("LifeCycleId"); + } + + /** + * LifeCycleId: 生命周期Id + * + * @param string $lifeCycleId + */ + public function setLifeCycleId(string $lifeCycleId) + { + $this->set("LifeCycleId", $lifeCycleId); + } +} diff --git a/src/UFile/Apis/CreateUFileTokenRequest.php b/src/UFile/Apis/CreateUFileTokenRequest.php index 2ddfd5ab..f6d1be6a 100644 --- a/src/UFile/Apis/CreateUFileTokenRequest.php +++ b/src/UFile/Apis/CreateUFileTokenRequest.php @@ -1,6 +1,7 @@ markRequired("TokenName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TokenName: 令牌名称 * @@ -83,11 +82,10 @@ public function getTokenName() * * @param string $tokenName */ - public function setTokenName($tokenName) + public function setTokenName(string $tokenName) { $this->set("TokenName", $tokenName); } - /** * AllowedOps: 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ]。默认TOKEN_ALLOW_NONE * @@ -107,7 +105,6 @@ public function setAllowedOps(array $allowedOps) { $this->set("AllowedOps", $allowedOps); } - /** * AllowedPrefixes: 令牌允许操作的key前缀,默认*表示全部 * @@ -127,7 +124,6 @@ public function setAllowedPrefixes(array $allowedPrefixes) { $this->set("AllowedPrefixes", $allowedPrefixes); } - /** * AllowedBuckets: 令牌允许操作的bucket,默认*表示全部 * @@ -147,7 +143,6 @@ public function setAllowedBuckets(array $allowedBuckets) { $this->set("AllowedBuckets", $allowedBuckets); } - /** * ExpireTime: Unix 时间戳,精确到秒,为令牌过期时间点。默认过期时间为一天(即当前Unix时间戳+86400);注意:过期时间不能超过 4102416000 * @@ -163,7 +158,7 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } diff --git a/src/UFile/Apis/CreateUFileTokenResponse.php b/src/UFile/Apis/CreateUFileTokenResponse.php index 979e6b33..2d610f52 100644 --- a/src/UFile/Apis/CreateUFileTokenResponse.php +++ b/src/UFile/Apis/CreateUFileTokenResponse.php @@ -1,6 +1,7 @@ set("TokenId", $tokenId); } diff --git a/src/UFile/Apis/DeleteBucketRequest.php b/src/UFile/Apis/DeleteBucketRequest.php index 82abf3b0..a3b52ccd 100644 --- a/src/UFile/Apis/DeleteBucketRequest.php +++ b/src/UFile/Apis/DeleteBucketRequest.php @@ -1,6 +1,7 @@ markRequired("BucketName"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BucketName: 待删除Bucket的名称 * @@ -63,7 +63,7 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } diff --git a/src/UFile/Apis/DeleteBucketResponse.php b/src/UFile/Apis/DeleteBucketResponse.php index 2c2f33c0..2645375a 100644 --- a/src/UFile/Apis/DeleteBucketResponse.php +++ b/src/UFile/Apis/DeleteBucketResponse.php @@ -1,6 +1,7 @@ set("BucketName", $bucketName); } - /** * BucketId: Bucket的ID * @@ -57,7 +57,7 @@ public function getBucketId() * * @param string $bucketId */ - public function setBucketId($bucketId) + public function setBucketId(string $bucketId) { $this->set("BucketId", $bucketId); } diff --git a/src/UFile/Apis/DeleteUFileLifeCycleRequest.php b/src/UFile/Apis/DeleteUFileLifeCycleRequest.php new file mode 100644 index 00000000..2ff5c504 --- /dev/null +++ b/src/UFile/Apis/DeleteUFileLifeCycleRequest.php @@ -0,0 +1,109 @@ + "DeleteUFileLifeCycle"]); + $this->markRequired("LifeCycleId"); + $this->markRequired("BucketName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * LifeCycleId: 生命周期Id + * + * @return string|null + */ + public function getLifeCycleId() + { + return $this->get("LifeCycleId"); + } + + /** + * LifeCycleId: 生命周期Id + * + * @param string $lifeCycleId + */ + public function setLifeCycleId(string $lifeCycleId) + { + $this->set("LifeCycleId", $lifeCycleId); + } + /** + * BucketName: 存储空间名称 + * + * @return string|null + */ + public function getBucketName() + { + return $this->get("BucketName"); + } + + /** + * BucketName: 存储空间名称 + * + * @param string $bucketName + */ + public function setBucketName(string $bucketName) + { + $this->set("BucketName", $bucketName); + } +} diff --git a/src/UFile/Apis/DeleteUFileLifeCycleResponse.php b/src/UFile/Apis/DeleteUFileLifeCycleResponse.php new file mode 100644 index 00000000..7fa2c3d4 --- /dev/null +++ b/src/UFile/Apis/DeleteUFileLifeCycleResponse.php @@ -0,0 +1,26 @@ +markRequired("TokenId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TokenId: 令牌ID * @@ -85,7 +84,7 @@ public function getTokenId() * * @param string $tokenId */ - public function setTokenId($tokenId) + public function setTokenId(string $tokenId) { $this->set("TokenId", $tokenId); } diff --git a/src/UFile/Apis/DeleteUFileTokenResponse.php b/src/UFile/Apis/DeleteUFileTokenResponse.php index b2d22173..3dc24e1d 100644 --- a/src/UFile/Apis/DeleteUFileTokenResponse.php +++ b/src/UFile/Apis/DeleteUFileTokenResponse.php @@ -1,6 +1,7 @@ "DescribeBucket"]); } - /** * Region: 如果提供此参数,则获取相应地域下所有空间的空间名称(只返回空间名称信息) @@ -42,11 +43,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -62,11 +62,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BucketName: 待获取Bucket的名称,若不提供,则获取所有Bucket * @@ -82,11 +81,10 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } - /** * Offset: 获取所有Bucket列表的偏移数目,默认为0 * @@ -102,11 +100,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 获取所有Bucket列表的限制数目,默认为20 * @@ -122,7 +119,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UFile/Apis/DescribeBucketResponse.php b/src/UFile/Apis/DescribeBucketResponse.php index 2999400b..4ec13f61 100644 --- a/src/UFile/Apis/DescribeBucketResponse.php +++ b/src/UFile/Apis/DescribeBucketResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileBucketSet($item)); + array_push($result, new UFileBucketSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: Bucket的描述信息 参数见 UFileBucketSet * - * @param UFileBucketSet[] $dataSet + * @param UFileBucketSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFile/Apis/DescribeUFileLifeCycleRequest.php b/src/UFile/Apis/DescribeUFileLifeCycleRequest.php new file mode 100644 index 00000000..bb986522 --- /dev/null +++ b/src/UFile/Apis/DescribeUFileLifeCycleRequest.php @@ -0,0 +1,108 @@ + "DescribeUFileLifeCycle"]); + $this->markRequired("BucketName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * BucketName: 存储空间名称 + * + * @return string|null + */ + public function getBucketName() + { + return $this->get("BucketName"); + } + + /** + * BucketName: 存储空间名称 + * + * @param string $bucketName + */ + public function setBucketName(string $bucketName) + { + $this->set("BucketName", $bucketName); + } + /** + * LifeCycleId: 生命周期Id;不传递此参数拉取存储空间下面的所有生命周期信息 + * + * @return string|null + */ + public function getLifeCycleId() + { + return $this->get("LifeCycleId"); + } + + /** + * LifeCycleId: 生命周期Id;不传递此参数拉取存储空间下面的所有生命周期信息 + * + * @param string $lifeCycleId + */ + public function setLifeCycleId(string $lifeCycleId) + { + $this->set("LifeCycleId", $lifeCycleId); + } +} diff --git a/src/UFile/Apis/DescribeUFileLifeCycleResponse.php b/src/UFile/Apis/DescribeUFileLifeCycleResponse.php new file mode 100644 index 00000000..aaf1b614 --- /dev/null +++ b/src/UFile/Apis/DescribeUFileLifeCycleResponse.php @@ -0,0 +1,59 @@ +get("DateSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new LifeCycleItemModel($item)); + } + return $result; + } + + /** + * DateSet: 生命周期信息 + * + * @param LifeCycleItemModel[] $dateSet + */ + public function setDateSet(array $dateSet) + { + $result = []; + foreach ($dateSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UFile/Apis/DescribeUFileTokenRequest.php b/src/UFile/Apis/DescribeUFileTokenRequest.php index 467f110b..f49f0dca 100644 --- a/src/UFile/Apis/DescribeUFileTokenRequest.php +++ b/src/UFile/Apis/DescribeUFileTokenRequest.php @@ -1,6 +1,7 @@ "DescribeUFileToken"]); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -42,11 +43,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -62,11 +62,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TokenId: 令牌ID,只返回指定ID信息,否则拉取所有令牌 * @@ -82,11 +81,10 @@ public function getTokenId() * * @param string $tokenId */ - public function setTokenId($tokenId) + public function setTokenId(string $tokenId) { $this->set("TokenId", $tokenId); } - /** * TokenName: 令牌名称,只返回指定令牌名称信息,否则拉取所有令牌 * @@ -102,11 +100,10 @@ public function getTokenName() * * @param string $tokenName */ - public function setTokenName($tokenName) + public function setTokenName(string $tokenName) { $this->set("TokenName", $tokenName); } - /** * Display: 0表示显示部分token信息;不传递和其他情况表示显示全部token信息 * @@ -122,7 +119,7 @@ public function getDisplay() * * @param int $display */ - public function setDisplay($display) + public function setDisplay(int $display) { $this->set("Display", $display); } diff --git a/src/UFile/Apis/DescribeUFileTokenResponse.php b/src/UFile/Apis/DescribeUFileTokenResponse.php index 06a9b37a..253924f8 100644 --- a/src/UFile/Apis/DescribeUFileTokenResponse.php +++ b/src/UFile/Apis/DescribeUFileTokenResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileTokenSet($item)); + array_push($result, new UFileTokenSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 令牌描述信息 * - * @param UFileTokenSet[] $dataSet + * @param UFileTokenSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFile/Apis/GetUFileDailyReportRequest.php b/src/UFile/Apis/GetUFileDailyReportRequest.php index 1aa78a94..65324d05 100644 --- a/src/UFile/Apis/GetUFileDailyReportRequest.php +++ b/src/UFile/Apis/GetUFileDailyReportRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * StartTime: 查询开始时间;unix时间戳,单位s * @@ -85,11 +84,10 @@ public function getStartTime() * * @param int $startTime */ - public function setStartTime($startTime) + public function setStartTime(int $startTime) { $this->set("StartTime", $startTime); } - /** * EndTime: 查询结束时间;unix时间戳,单位s * @@ -105,11 +103,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * BucketName: 空间名称。此字段不为空,返回此Bucket日使用量;否则,返回这个项目的日使用量 * @@ -125,7 +122,7 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } diff --git a/src/UFile/Apis/GetUFileDailyReportResponse.php b/src/UFile/Apis/GetUFileDailyReportResponse.php index 0561d74d..6b061e91 100644 --- a/src/UFile/Apis/GetUFileDailyReportResponse.php +++ b/src/UFile/Apis/GetUFileDailyReportResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileReportItem($item)); + array_push($result, new UFileReportItemModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getDataSet() /** * DataSet: 消费情况 * - * @param UFileReportItem[] $dataSet + * @param UFileReportItemModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFile/Apis/GetUFileQuotaInfoRequest.php b/src/UFile/Apis/GetUFileQuotaInfoRequest.php index bf7674df..aa1e7d6f 100644 --- a/src/UFile/Apis/GetUFileQuotaInfoRequest.php +++ b/src/UFile/Apis/GetUFileQuotaInfoRequest.php @@ -1,6 +1,7 @@ markRequired("QuotaType"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * QuotaType: 配额类型,取值为storage-volume, download-traffic或request-count * diff --git a/src/UFile/Apis/GetUFileQuotaInfoResponse.php b/src/UFile/Apis/GetUFileQuotaInfoResponse.php index 9e62b462..dea8db53 100644 --- a/src/UFile/Apis/GetUFileQuotaInfoResponse.php +++ b/src/UFile/Apis/GetUFileQuotaInfoResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileQuotaDataSetItem($item)); + array_push($result, new UFileQuotaDataSetItemModel($item)); } return $result; } @@ -47,7 +47,7 @@ public function getDataSet() /** * DataSet: 配额信息数据集 * - * @param UFileQuotaDataSetItem[] $dataSet + * @param UFileQuotaDataSetItemModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFile/Apis/GetUFileQuotaPriceRequest.php b/src/UFile/Apis/GetUFileQuotaPriceRequest.php index fa61efd9..ae34507d 100644 --- a/src/UFile/Apis/GetUFileQuotaPriceRequest.php +++ b/src/UFile/Apis/GetUFileQuotaPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * StorageVolume: 存储容量,单位: GB*天,范围: [0, 30 000 000],步长:100GB*天 * @@ -63,11 +63,10 @@ public function getStorageVolume() * * @param int $storageVolume */ - public function setStorageVolume($storageVolume) + public function setStorageVolume(int $storageVolume) { $this->set("StorageVolume", $storageVolume); } - /** * DownloadTraffic: 下载流量,单位: GB,范围: [0, 60 000],步长:1GB * @@ -83,11 +82,10 @@ public function getDownloadTraffic() * * @param int $downloadTraffic */ - public function setDownloadTraffic($downloadTraffic) + public function setDownloadTraffic(int $downloadTraffic) { $this->set("DownloadTraffic", $downloadTraffic); } - /** * RequestCount: 请求次数,单位:万次,范围:[0, 1 000 000],步长:1万次 * @@ -103,7 +101,7 @@ public function getRequestCount() * * @param int $requestCount */ - public function setRequestCount($requestCount) + public function setRequestCount(int $requestCount) { $this->set("RequestCount", $requestCount); } diff --git a/src/UFile/Apis/GetUFileQuotaPriceResponse.php b/src/UFile/Apis/GetUFileQuotaPriceResponse.php index 9a17c8df..ba1ed104 100644 --- a/src/UFile/Apis/GetUFileQuotaPriceResponse.php +++ b/src/UFile/Apis/GetUFileQuotaPriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UFile/Apis/GetUFileQuotaRequest.php b/src/UFile/Apis/GetUFileQuotaRequest.php index d89f7fd1..0a96c9cb 100644 --- a/src/UFile/Apis/GetUFileQuotaRequest.php +++ b/src/UFile/Apis/GetUFileQuotaRequest.php @@ -1,6 +1,7 @@ markRequired("QuotaType"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -43,11 +44,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * QuotaType: 配额类型,取值为storage-volume, download-traffic或request-count * @@ -63,7 +63,7 @@ public function getQuotaType() * * @param string $quotaType */ - public function setQuotaType($quotaType) + public function setQuotaType(string $quotaType) { $this->set("QuotaType", $quotaType); } diff --git a/src/UFile/Apis/GetUFileQuotaResponse.php b/src/UFile/Apis/GetUFileQuotaResponse.php index e130a4a9..035ec348 100644 --- a/src/UFile/Apis/GetUFileQuotaResponse.php +++ b/src/UFile/Apis/GetUFileQuotaResponse.php @@ -1,6 +1,7 @@ set("LeftQuota", $leftQuota); } diff --git a/src/UFile/Apis/GetUFileReportRequest.php b/src/UFile/Apis/GetUFileReportRequest.php index 27588774..fb9ae9d8 100644 --- a/src/UFile/Apis/GetUFileReportRequest.php +++ b/src/UFile/Apis/GetUFileReportRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * StartTime: 查询开始时间 * @@ -85,11 +84,10 @@ public function getStartTime() * * @param int $startTime */ - public function setStartTime($startTime) + public function setStartTime(int $startTime) { $this->set("StartTime", $startTime); } - /** * EndTime: 查询结束时间 * @@ -105,7 +103,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UFile/Apis/GetUFileReportResponse.php b/src/UFile/Apis/GetUFileReportResponse.php index 3fb8cfd3..af0c0f81 100644 --- a/src/UFile/Apis/GetUFileReportResponse.php +++ b/src/UFile/Apis/GetUFileReportResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileReportSet($item)); + array_push($result, new UFileReportSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 报表内容 参数见 UFileReportSet * - * @param UFileReportSet[] $dataSet + * @param UFileReportSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UFile/Apis/SetUFileRefererRequest.php b/src/UFile/Apis/SetUFileRefererRequest.php index 4adc9433..5390c05b 100644 --- a/src/UFile/Apis/SetUFileRefererRequest.php +++ b/src/UFile/Apis/SetUFileRefererRequest.php @@ -1,6 +1,7 @@ markRequired("RefererStatus"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BucketName: 存储空间名称 * @@ -84,11 +83,10 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } - /** * RefererStatus: 开启关闭referer防盗链;关闭防盗链会清空防盗链参数设置,开启防盗链必须指定 RefererType、Referers;开启:on, 关闭:off; * @@ -104,11 +102,10 @@ public function getRefererStatus() * * @param string $refererStatus */ - public function setRefererStatus($refererStatus) + public function setRefererStatus(string $refererStatus) { $this->set("RefererStatus", $refererStatus); } - /** * RefererAllowNull: RefererType为白名单时,RefererAllowNull为false代表不允许空referer访问,为true代表允许空referer访问;此参数默认为 true; * @@ -124,11 +121,10 @@ public function getRefererAllowNull() * * @param boolean $refererAllowNull */ - public function setRefererAllowNull($refererAllowNull) + public function setRefererAllowNull(bool $refererAllowNull) { $this->set("RefererAllowNull", $refererAllowNull); } - /** * RefererType: 防盗链Referer类型,支持两种类型,黑名单和白名单; 1黑名单,2白名单;RefererStatus为"on"时此参数必填; * @@ -144,11 +140,10 @@ public function getRefererType() * * @param int $refererType */ - public function setRefererType($refererType) + public function setRefererType(int $refererType) { $this->set("RefererType", $refererType); } - /** * Referers: 防盗链Referer规则,支持正则表达式(不支持符号';') * diff --git a/src/UFile/Apis/SetUFileRefererResponse.php b/src/UFile/Apis/SetUFileRefererResponse.php index e908d562..02b19a4e 100644 --- a/src/UFile/Apis/SetUFileRefererResponse.php +++ b/src/UFile/Apis/SetUFileRefererResponse.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BucketName: 待修改Bucket的名称 * @@ -64,11 +64,10 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } - /** * Type: Bucket访问类型;public或private * @@ -84,7 +83,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/UFile/Apis/UpdateBucketResponse.php b/src/UFile/Apis/UpdateBucketResponse.php index 18bbce98..24e1514b 100644 --- a/src/UFile/Apis/UpdateBucketResponse.php +++ b/src/UFile/Apis/UpdateBucketResponse.php @@ -1,6 +1,7 @@ set("BucketName", $bucketName); } - /** * BucketId: Bucket的ID * @@ -57,7 +57,7 @@ public function getBucketId() * * @param string $bucketId */ - public function setBucketId($bucketId) + public function setBucketId(string $bucketId) { $this->set("BucketId", $bucketId); } diff --git a/src/UFile/Apis/UpdateUFileLifeCycleRequest.php b/src/UFile/Apis/UpdateUFileLifeCycleRequest.php new file mode 100644 index 00000000..1cfff643 --- /dev/null +++ b/src/UFile/Apis/UpdateUFileLifeCycleRequest.php @@ -0,0 +1,226 @@ + "UpdateUFileLifeCycle"]); + $this->markRequired("LifeCycleId"); + $this->markRequired("LifeCycleName"); + $this->markRequired("Prefix"); + $this->markRequired("Status"); + $this->markRequired("BucketName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * LifeCycleId: 生命周期Id + * + * @return string|null + */ + public function getLifeCycleId() + { + return $this->get("LifeCycleId"); + } + + /** + * LifeCycleId: 生命周期Id + * + * @param string $lifeCycleId + */ + public function setLifeCycleId(string $lifeCycleId) + { + $this->set("LifeCycleId", $lifeCycleId); + } + /** + * LifeCycleName: 生命周期名称 + * + * @return string|null + */ + public function getLifeCycleName() + { + return $this->get("LifeCycleName"); + } + + /** + * LifeCycleName: 生命周期名称 + * + * @param string $lifeCycleName + */ + public function setLifeCycleName(string $lifeCycleName) + { + $this->set("LifeCycleName", $lifeCycleName); + } + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件;一条规则只支持一个文件前缀; + * + * @return string|null + */ + public function getPrefix() + { + return $this->get("Prefix"); + } + + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件;一条规则只支持一个文件前缀; + * + * @param string $prefix + */ + public function setPrefix(string $prefix) + { + $this->set("Prefix", $prefix); + } + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @param string $status + */ + public function setStatus(string $status) + { + $this->set("Status", $status); + } + /** + * BucketName: 存储空间名称 + * + * @return string|null + */ + public function getBucketName() + { + return $this->get("BucketName"); + } + + /** + * BucketName: 存储空间名称 + * + * @param string $bucketName + */ + public function setBucketName(string $bucketName) + { + $this->set("BucketName", $bucketName); + } + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除;范围: [7,36500] + * + * @return integer|null + */ + public function getDays() + { + return $this->get("Days"); + } + + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除;范围: [7,36500] + * + * @param int $days + */ + public function setDays(int $days) + { + $this->set("Days", $days); + } + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为归档存储类型;范围: [7,36500],0代表不启用 + * + * @return integer|null + */ + public function getArchivalDays() + { + return $this->get("ArchivalDays"); + } + + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为归档存储类型;范围: [7,36500],0代表不启用 + * + * @param int $archivalDays + */ + public function setArchivalDays(int $archivalDays) + { + $this->set("ArchivalDays", $archivalDays); + } + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为低频存储类型;范围: [7,36500],0代表不启用 + * + * @return integer|null + */ + public function getIADays() + { + return $this->get("IADays"); + } + + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为低频存储类型;范围: [7,36500],0代表不启用 + * + * @param int $iaDays + */ + public function setIADays(int $iaDays) + { + $this->set("IADays", $iaDays); + } +} diff --git a/src/UFile/Apis/UpdateUFileLifeCycleResponse.php b/src/UFile/Apis/UpdateUFileLifeCycleResponse.php new file mode 100644 index 00000000..e4f76787 --- /dev/null +++ b/src/UFile/Apis/UpdateUFileLifeCycleResponse.php @@ -0,0 +1,26 @@ +markRequired("TokenId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TokenId: 令牌ID * @@ -84,11 +83,10 @@ public function getTokenId() * * @param string $tokenId */ - public function setTokenId($tokenId) + public function setTokenId(string $tokenId) { $this->set("TokenId", $tokenId); } - /** * TokenName: 令牌名称 * @@ -104,11 +102,10 @@ public function getTokenName() * * @param string $tokenName */ - public function setTokenName($tokenName) + public function setTokenName(string $tokenName) { $this->set("TokenName", $tokenName); } - /** * AllowedOps: 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ] * @@ -128,7 +125,6 @@ public function setAllowedOps(array $allowedOps) { $this->set("AllowedOps", $allowedOps); } - /** * AllowedPrefixes: 令牌允许操作的key前缀 * @@ -148,7 +144,6 @@ public function setAllowedPrefixes(array $allowedPrefixes) { $this->set("AllowedPrefixes", $allowedPrefixes); } - /** * AllowedBuckets: 令牌允许操作的bucket * @@ -168,7 +163,6 @@ public function setAllowedBuckets(array $allowedBuckets) { $this->set("AllowedBuckets", $allowedBuckets); } - /** * ExpireTime: 令牌的超时时间点(时间戳);注意:过期时间不能超过 4102416000 * @@ -184,7 +178,7 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } diff --git a/src/UFile/Apis/UpdateUFileTokenResponse.php b/src/UFile/Apis/UpdateUFileTokenResponse.php index 8353977f..94510103 100644 --- a/src/UFile/Apis/UpdateUFileTokenResponse.php +++ b/src/UFile/Apis/UpdateUFileTokenResponse.php @@ -1,6 +1,7 @@ get("LifeCycleId"); + } + + /** + * LifeCycleId: 生命周期Id + * + * @param string $lifeCycleId + */ + public function setLifeCycleId(string $lifeCycleId) + { + $this->set("LifeCycleId", $lifeCycleId); + } + /** + * LifeCycleName: 生命周期名称 + * + * @return string|null + */ + public function getLifeCycleName() + { + return $this->get("LifeCycleName"); + } + + /** + * LifeCycleName: 生命周期名称 + * + * @param string $lifeCycleName + */ + public function setLifeCycleName(string $lifeCycleName) + { + $this->set("LifeCycleName", $lifeCycleName); + } + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件; + * + * @return string|null + */ + public function getPrefix() + { + return $this->get("Prefix"); + } + + /** + * Prefix: 生命周期所适用的前缀;*为整个存储空间文件; + * + * @param string $prefix + */ + public function setPrefix(string $prefix) + { + $this->set("Prefix", $prefix); + } + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除,0代表不启用; + * + * @return integer|null + */ + public function getDays() + { + return $this->get("Days"); + } + + /** + * Days: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动删除,0代表不启用; + * + * @param int $days + */ + public function setDays(int $days) + { + $this->set("Days", $days); + } + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: Enabled -- 启用,Disabled -- 不启用 + * + * @param string $status + */ + public function setStatus(string $status) + { + $this->set("Status", $status); + } + /** + * BucketName: 存储空间名称 + * + * @return string|null + */ + public function getBucketName() + { + return $this->get("BucketName"); + } + + /** + * BucketName: 存储空间名称 + * + * @param string $bucketName + */ + public function setBucketName(string $bucketName) + { + $this->set("BucketName", $bucketName); + } + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为归档存储类型,0代表不启用; + * + * @return integer|null + */ + public function getArchivalDays() + { + return $this->get("ArchivalDays"); + } + + /** + * ArchivalDays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为归档存储类型,0代表不启用; + * + * @param int $archivalDays + */ + public function setArchivalDays(int $archivalDays) + { + $this->set("ArchivalDays", $archivalDays); + } + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为低频存储类型,0代表不启用; + * + * @return integer|null + */ + public function getIADays() + { + return $this->get("IADays"); + } + + /** + * IADays: 指定一个过期天数N,文件会在其最近更新时间点的N天后过期,自动转换为低频存储类型,0代表不启用; + * + * @param int $iaDays + */ + public function setIADays(int $iaDays) + { + $this->set("IADays", $iaDays); + } +} diff --git a/src/UFile/Models/UFileBucketSet.php b/src/UFile/Models/UFileBucketSet.php index 983c9ac4..1b5eccf9 100644 --- a/src/UFile/Models/UFileBucketSet.php +++ b/src/UFile/Models/UFileBucketSet.php @@ -1,6 +1,7 @@ set("Region", $region); } - /** * BucketName: Bucket名称 * @@ -57,11 +60,10 @@ public function getBucketName() * * @param string $bucketName */ - public function setBucketName($bucketName) + public function setBucketName(string $bucketName) { $this->set("BucketName", $bucketName); } - /** * BucketId: Bucket的ID * @@ -77,31 +79,29 @@ public function getBucketId() * * @param string $bucketId */ - public function setBucketId($bucketId) + public function setBucketId(string $bucketId) { $this->set("BucketId", $bucketId); } - /** * Domain: Bucket的域名集合 参数见 UFileDomainSet * - * @return UFileDomainSet|null + * @return UFileDomainSetModel|null */ public function getDomain() { - return new UFileDomainSet($this->get("Domain")); + return new UFileDomainSetModel($this->get("Domain")); } /** * Domain: Bucket的域名集合 参数见 UFileDomainSet * - * @param UFileDomainSet $domain + * @param UFileDomainSetModel $domain */ - public function setDomain(array $domain) + public function setDomain(UFileDomainSetModel $domain) { $this->set("Domain", $domain->getAll()); } - /** * CdnDomainId: 与Bucket关联的CND加速域名的ID列表 * @@ -121,7 +121,6 @@ public function setCdnDomainId(array $cdnDomainId) { $this->set("CdnDomainId", $cdnDomainId); } - /** * Type: Bucket访问类型 * @@ -137,11 +136,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * CreateTime: Bucket的创建时间 * @@ -157,11 +155,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: Bucket的修改时间 * @@ -177,11 +174,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * Biz: Bucket所属业务, general或vod或udb general: 普通业务; vod: 视频云业务; udb: 云数据库业务 * @@ -197,11 +193,10 @@ public function getBiz() * * @param string $biz */ - public function setBiz($biz) + public function setBiz(string $biz) { $this->set("Biz", $biz); } - /** * Tag: 所属业务组 * @@ -217,11 +212,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * HasUserDomain: 是否存在自定义域名。0不存在,1存在,2错误 * @@ -237,7 +231,7 @@ public function getHasUserDomain() * * @param int $hasUserDomain */ - public function setHasUserDomain($hasUserDomain) + public function setHasUserDomain(int $hasUserDomain) { $this->set("HasUserDomain", $hasUserDomain); } diff --git a/src/UFile/Models/UFileDailyReportItem.php b/src/UFile/Models/UFileDailyReportItem.php index bf59d732..c9c59cfc 100644 --- a/src/UFile/Models/UFileDailyReportItem.php +++ b/src/UFile/Models/UFileDailyReportItem.php @@ -1,6 +1,7 @@ set("Storage", $storage); } - /** * IaStorage: 低频存储量;单位byte * @@ -57,11 +61,10 @@ public function getIaStorage() * * @param float $iaStorage */ - public function setIaStorage($iaStorage) + public function setIaStorage(float $iaStorage) { $this->set("IaStorage", $iaStorage); } - /** * AcStorage: 冷存(归档)存储量;单位byte * @@ -77,11 +80,10 @@ public function getAcStorage() * * @param float $acStorage */ - public function setAcStorage($acStorage) + public function setAcStorage(float $acStorage) { $this->set("AcStorage", $acStorage); } - /** * IaGetSize: 低频数据取回量;单位byte * @@ -97,11 +99,10 @@ public function getIaGetSize() * * @param float $iaGetSize */ - public function setIaGetSize($iaGetSize) + public function setIaGetSize(float $iaGetSize) { $this->set("IaGetSize", $iaGetSize); } - /** * AcRestore: 冷存激活量,即归档数据取回量;单位byte * @@ -117,11 +118,10 @@ public function getAcRestore() * * @param float $acRestore */ - public function setAcRestore($acRestore) + public function setAcRestore(float $acRestore) { $this->set("AcRestore", $acRestore); } - /** * BusyFlow: 忙时流量;单位byte;海外无此字段 * @@ -137,11 +137,10 @@ public function getBusyFlow() * * @param float $busyFlow */ - public function setBusyFlow($busyFlow) + public function setBusyFlow(float $busyFlow) { $this->set("BusyFlow", $busyFlow); } - /** * IdleFlow: 闲时流量;单位byte;海外无此字段 * @@ -157,11 +156,10 @@ public function getIdleFlow() * * @param float $idleFlow */ - public function setIdleFlow($idleFlow) + public function setIdleFlow(float $idleFlow) { $this->set("IdleFlow", $idleFlow); } - /** * CdnFlow: cdn回源流量;单位byte * @@ -177,11 +175,10 @@ public function getCdnFlow() * * @param float $cdnFlow */ - public function setCdnFlow($cdnFlow) + public function setCdnFlow(float $cdnFlow) { $this->set("CdnFlow", $cdnFlow); } - /** * Flow: 下载流量:单位byte;国内无此字段 * @@ -197,11 +194,10 @@ public function getFlow() * * @param float $flow */ - public function setFlow($flow) + public function setFlow(float $flow) { $this->set("Flow", $flow); } - /** * Date: 配额消费时间,unix时间戳(单位s),精确到日期 * @@ -217,13 +213,12 @@ public function getDate() * * @param int $date */ - public function setDate($date) + public function setDate(int $date) { $this->set("Date", $date); } - /** - * ApiTimes: API请求次数(次) + * ApiTimes: API请求次数(万次) * * @return float|null */ @@ -233,11 +228,11 @@ public function getApiTimes() } /** - * ApiTimes: API请求次数(次) + * ApiTimes: API请求次数(万次) * * @param float $apiTimes */ - public function setApiTimes($apiTimes) + public function setApiTimes(float $apiTimes) { $this->set("ApiTimes", $apiTimes); } diff --git a/src/UFile/Models/UFileDomainSet.php b/src/UFile/Models/UFileDomainSet.php index 5afe0098..0f6c13e8 100644 --- a/src/UFile/Models/UFileDomainSet.php +++ b/src/UFile/Models/UFileDomainSet.php @@ -1,6 +1,7 @@ set("Src", $src); } - /** * Cdn: UCDN加速域名 * @@ -61,7 +64,6 @@ public function setCdn(array $cdn) { $this->set("Cdn", $cdn); } - /** * CustomSrc: 用户自定义源站域名 * @@ -81,7 +83,6 @@ public function setCustomSrc(array $customSrc) { $this->set("CustomSrc", $customSrc); } - /** * CustomCdn: 用户自定义CDN加速域名 * diff --git a/src/UFile/Models/UFileQuotaDataSetItem.php b/src/UFile/Models/UFileQuotaDataSetItem.php index 3d157e56..81dbd66b 100644 --- a/src/UFile/Models/UFileQuotaDataSetItem.php +++ b/src/UFile/Models/UFileQuotaDataSetItem.php @@ -1,6 +1,7 @@ set("Region", $region); } - /** * Owe: 是否欠费:1表示欠费;0表示未欠费 * @@ -57,67 +60,64 @@ public function getOwe() * * @param int $owe */ - public function setOwe($owe) + public function setOwe(int $owe) { $this->set("Owe", $owe); } - /** * Storage: 剩余存储容量 * - * @return UFileQuotaLeft|null + * @return UFileQuotaLeftModel|null */ public function getStorage() { - return new UFileQuotaLeft($this->get("Storage")); + return new UFileQuotaLeftModel($this->get("Storage")); } /** * Storage: 剩余存储容量 * - * @param UFileQuotaLeft $storage + * @param UFileQuotaLeftModel $storage */ - public function setStorage(array $storage) + public function setStorage(UFileQuotaLeftModel $storage) { $this->set("Storage", $storage->getAll()); } - /** * DownloadFlow: 剩余下载流量 * - * @return UFileQuotaLeft|null + * @return UFileQuotaLeftModel|null */ public function getDownloadFlow() { - return new UFileQuotaLeft($this->get("DownloadFlow")); + return new UFileQuotaLeftModel($this->get("DownloadFlow")); } /** * DownloadFlow: 剩余下载流量 * - * @param UFileQuotaLeft $downloadFlow + * @param UFileQuotaLeftModel $downloadFlow */ - public function setDownloadFlow(array $downloadFlow) + public function setDownloadFlow(UFileQuotaLeftModel $downloadFlow) { $this->set("DownloadFlow", $downloadFlow->getAll()); } - /** * RequestCnt: 剩余请求次数 * - * @return UFileQuotaLeft|null + * @return UFileQuotaLeftModel|null */ public function getRequestCnt() { - return new UFileQuotaLeft($this->get("RequestCnt")); + return new UFileQuotaLeftModel($this->get("RequestCnt")); } /** * RequestCnt: 剩余请求次数 * - * @param UFileQuotaLeft $requestCnt + * @param UFileQuotaLeftModel $requestCnt */ - public function setRequestCnt(array $requestCnt) + public function setRequestCnt(UFileQuotaLeftModel $requestCnt) { $this->set("RequestCnt", $requestCnt->getAll()); } diff --git a/src/UFile/Models/UFileQuotaLeft.php b/src/UFile/Models/UFileQuotaLeft.php index bc9420b8..23ca2092 100644 --- a/src/UFile/Models/UFileQuotaLeft.php +++ b/src/UFile/Models/UFileQuotaLeft.php @@ -1,6 +1,7 @@ set("Left", $left); } diff --git a/src/UFile/Models/UFileReportItem.php b/src/UFile/Models/UFileReportItem.php index b833030f..f851771d 100644 --- a/src/UFile/Models/UFileReportItem.php +++ b/src/UFile/Models/UFileReportItem.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UFileTotalReportItem($item)); + array_push($result, new UFileTotalReportItemModel($item)); } return $result; } @@ -43,7 +49,7 @@ public function getTotal() /** * Total: 总消费情况 * - * @param UFileTotalReportItem[] $total + * @param UFileTotalReportItemModel[] $total */ public function setTotal(array $total) { @@ -53,11 +59,10 @@ public function setTotal(array $total) } return $result; } - /** * Daily: 日消费情况 * - * @return UFileDailyReportItem[]|null + * @return UFileDailyReportItemModel[]|null */ public function getDaily() { @@ -67,7 +72,7 @@ public function getDaily() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UFileDailyReportItem($item)); + array_push($result, new UFileDailyReportItemModel($item)); } return $result; } @@ -75,7 +80,7 @@ public function getDaily() /** * Daily: 日消费情况 * - * @param UFileDailyReportItem[] $daily + * @param UFileDailyReportItemModel[] $daily */ public function setDaily(array $daily) { diff --git a/src/UFile/Models/UFileReportSet.php b/src/UFile/Models/UFileReportSet.php index 6ad43e9f..c4369e62 100644 --- a/src/UFile/Models/UFileReportSet.php +++ b/src/UFile/Models/UFileReportSet.php @@ -1,6 +1,7 @@ set("Time", $time); } - /** * StorageVolume: 配额消费当日使用的存储容量,单位:GB*天 * @@ -57,11 +59,10 @@ public function getStorageVolume() * * @param float $storageVolume */ - public function setStorageVolume($storageVolume) + public function setStorageVolume(float $storageVolume) { $this->set("StorageVolume", $storageVolume); } - /** * DownloadTraffic: 配额消费当日使用的下载流量,单位:GB * @@ -77,11 +78,10 @@ public function getDownloadTraffic() * * @param float $downloadTraffic */ - public function setDownloadTraffic($downloadTraffic) + public function setDownloadTraffic(float $downloadTraffic) { $this->set("DownloadTraffic", $downloadTraffic); } - /** * RequestCount: 配额消费当日使用的请求次数,单位:万次 * @@ -97,7 +97,7 @@ public function getRequestCount() * * @param float $requestCount */ - public function setRequestCount($requestCount) + public function setRequestCount(float $requestCount) { $this->set("RequestCount", $requestCount); } diff --git a/src/UFile/Models/UFileTokenSet.php b/src/UFile/Models/UFileTokenSet.php index d2e68d36..6e992dc6 100644 --- a/src/UFile/Models/UFileTokenSet.php +++ b/src/UFile/Models/UFileTokenSet.php @@ -1,6 +1,7 @@ set("TokenId", $tokenId); } - /** * TokenName: 令牌名称 * @@ -57,11 +59,10 @@ public function getTokenName() * * @param string $tokenName */ - public function setTokenName($tokenName) + public function setTokenName(string $tokenName) { $this->set("TokenName", $tokenName); } - /** * PublicKey: 令牌公钥 * @@ -77,11 +78,10 @@ public function getPublicKey() * * @param string $publicKey */ - public function setPublicKey($publicKey) + public function setPublicKey(string $publicKey) { $this->set("PublicKey", $publicKey); } - /** * PrivateKey: 令牌私钥 * @@ -97,11 +97,10 @@ public function getPrivateKey() * * @param string $privateKey */ - public function setPrivateKey($privateKey) + public function setPrivateKey(string $privateKey) { $this->set("PrivateKey", $privateKey); } - /** * AllowedOps: 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ] * @@ -121,7 +120,6 @@ public function setAllowedOps(array $allowedOps) { $this->set("AllowedOps", $allowedOps); } - /** * AllowedPrefixes: 令牌允许操作的key前缀 * @@ -141,7 +139,6 @@ public function setAllowedPrefixes(array $allowedPrefixes) { $this->set("AllowedPrefixes", $allowedPrefixes); } - /** * AllowedBuckets: 令牌允许操作的bucket * @@ -161,7 +158,6 @@ public function setAllowedBuckets(array $allowedBuckets) { $this->set("AllowedBuckets", $allowedBuckets); } - /** * ExpireTime: 令牌的超时时间点 * @@ -177,11 +173,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * CreateTime: 创建时间 * @@ -197,11 +192,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: 修改时间 * @@ -217,11 +211,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * Region: 所属地区 * @@ -237,7 +230,7 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } diff --git a/src/UFile/Models/UFileTotalReportItem.php b/src/UFile/Models/UFileTotalReportItem.php index 175d9719..b686236d 100644 --- a/src/UFile/Models/UFileTotalReportItem.php +++ b/src/UFile/Models/UFileTotalReportItem.php @@ -1,6 +1,7 @@ set("Flow", $flow); } - /** * IdleFlow: 闲时流量;单位byte;海外无此字段 * @@ -57,11 +61,10 @@ public function getIdleFlow() * * @param float $idleFlow */ - public function setIdleFlow($idleFlow) + public function setIdleFlow(float $idleFlow) { $this->set("IdleFlow", $idleFlow); } - /** * BusyFlow: 忙时流量;单位byte;海外无此字段 * @@ -77,11 +80,10 @@ public function getBusyFlow() * * @param float $busyFlow */ - public function setBusyFlow($busyFlow) + public function setBusyFlow(float $busyFlow) { $this->set("BusyFlow", $busyFlow); } - /** * CdnFlow: cdn回源流量;单位byte * @@ -97,13 +99,12 @@ public function getCdnFlow() * * @param float $cdnFlow */ - public function setCdnFlow($cdnFlow) + public function setCdnFlow(float $cdnFlow) { $this->set("CdnFlow", $cdnFlow); } - /** - * ApiTimes: API请求次数(次) + * ApiTimes: API请求次数(万次) * * @return float|null */ @@ -113,11 +114,11 @@ public function getApiTimes() } /** - * ApiTimes: API请求次数(次) + * ApiTimes: API请求次数(万次) * * @param float $apiTimes */ - public function setApiTimes($apiTimes) + public function setApiTimes(float $apiTimes) { $this->set("ApiTimes", $apiTimes); } diff --git a/src/UFile/UFileClient.php b/src/UFile/UFileClient.php index 1b67fa77..02992231 100644 --- a/src/UFile/UFileClient.php +++ b/src/UFile/UFileClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BucketName" => (string) 待创建Bucket的名称,具有全局唯一性 - * "Type" => (string) Bucket访问类型,public或private; 默认为private - * ] - * - * Outputs: - * - * $outputs = [ - * "BucketName" => (string) 已创建Bucket的名称 - * "BucketId" => (string) 已创建Bucket的ID - * ] - * - * @return CreateBucketResponse * @throws UCloudException */ public function createBucket(CreateBucketRequest $request = null) @@ -82,31 +131,27 @@ public function createBucket(CreateBucketRequest $request = null) $resp = $this->invoke($request); return new CreateBucketResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * CreateUFileToken - 创建US3令牌 - * - * See also: https://docs.ucloud.cn/api/ufile-api/create_ufile_token - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TokenName" => (string) 令牌名称 - * "AllowedOps" => (array) 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ]。默认TOKEN_ALLOW_NONE - * "AllowedPrefixes" => (array) 令牌允许操作的key前缀,默认*表示全部 - * "AllowedBuckets" => (array) 令牌允许操作的bucket,默认*表示全部 - * "ExpireTime" => (integer) Unix 时间戳,精确到秒,为令牌过期时间点。默认过期时间为一天(即当前Unix时间戳+86400);注意:过期时间不能超过 4102416000 - * ] - * - * Outputs: + * CreateUFileLifeCycle - 创建生命周期管理 * - * $outputs = [ - * "TokenId" => (string) 创建令牌的token_id - * ] + * @throws UCloudException + */ + public function createUFileLifeCycle(CreateUFileLifeCycleRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateUFileLifeCycleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateUFileToken - 创建US3令牌 * - * @return CreateUFileTokenResponse * @throws UCloudException */ public function createUFileToken(CreateUFileTokenRequest $request = null) @@ -114,27 +159,13 @@ public function createUFileToken(CreateUFileTokenRequest $request = null) $resp = $this->invoke($request); return new CreateUFileTokenResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteBucket - 删除Bucket * - * See also: https://docs.ucloud.cn/api/ufile-api/delete_bucket - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BucketName" => (string) 待删除Bucket的名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "BucketName" => (string) Bucket的名称 - * "BucketId" => (string) Bucket的ID - * ] - * - * @return DeleteBucketResponse * @throws UCloudException */ public function deleteBucket(DeleteBucketRequest $request = null) @@ -142,26 +173,27 @@ public function deleteBucket(DeleteBucketRequest $request = null) $resp = $this->invoke($request); return new DeleteBucketResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DeleteUFileToken - 删除令牌 - * - * See also: https://docs.ucloud.cn/api/ufile-api/delete_ufile_token - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TokenId" => (string) 令牌ID - * ] + * DeleteUFileLifeCycle - 删除生命周期管理 * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function deleteUFileLifeCycle(DeleteUFileLifeCycleRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteUFileLifeCycleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteUFileToken - 删除令牌 * - * @return DeleteUFileTokenResponse * @throws UCloudException */ public function deleteUFileToken(DeleteUFileTokenRequest $request = null) @@ -169,48 +201,13 @@ public function deleteUFileToken(DeleteUFileTokenRequest $request = null) $resp = $this->invoke($request); return new DeleteUFileTokenResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeBucket - 获取Bucket的描述信息 * - * See also: https://docs.ucloud.cn/api/ufile-api/describe_bucket - * - * Arguments: - * - * $args = [ - * "Region" => (string) 如果提供此参数,则获取相应地域下所有空间的空间名称(只返回空间名称信息) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BucketName" => (string) 待获取Bucket的名称,若不提供,则获取所有Bucket - * "Offset" => (integer) 获取所有Bucket列表的偏移数目,默认为0 - * "Limit" => (integer) 获取所有Bucket列表的限制数目,默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) Bucket的描述信息 参数见 UFileBucketSet[ - * [ - * "Region" => (string) Bucket所属地域 - * "BucketName" => (string) Bucket名称 - * "BucketId" => (string) Bucket的ID - * "Domain" => (object) Bucket的域名集合 参数见 UFileDomainSet[ - * "Src" => (array) 源站域名 - * "Cdn" => (array) UCDN加速域名 - * "CustomSrc" => (array) 用户自定义源站域名 - * "CustomCdn" => (array) 用户自定义CDN加速域名 - * ] - * "CdnDomainId" => (array) 与Bucket关联的CND加速域名的ID列表 - * "Type" => (string) Bucket访问类型 - * "CreateTime" => (integer) Bucket的创建时间 - * "ModifyTime" => (integer) Bucket的修改时间 - * "Biz" => (string) Bucket所属业务, general或vod或udb general: 普通业务; vod: 视频云业务; udb: 云数据库业务 - * "Tag" => (string) 所属业务组 - * "HasUserDomain" => (integer) 是否存在自定义域名。0不存在,1存在,2错误 - * ] - * ] - * ] - * - * @return DescribeBucketResponse * @throws UCloudException */ public function describeBucket(DescribeBucketRequest $request = null) @@ -218,43 +215,27 @@ public function describeBucket(DescribeBucketRequest $request = null) $resp = $this->invoke($request); return new DescribeBucketResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DescribeUFileToken - 获取令牌信息 - * - * See also: https://docs.ucloud.cn/api/ufile-api/describe_ufile_token - * - * Arguments: + * DescribeUFileLifeCycle - 获取生命周期信息 * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TokenId" => (string) 令牌ID,只返回指定ID信息,否则拉取所有令牌 - * "TokenName" => (string) 令牌名称,只返回指定令牌名称信息,否则拉取所有令牌 - * "Display" => (integer) 0表示显示部分token信息;不传递和其他情况表示显示全部token信息 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 令牌描述信息[ - * [ - * "TokenId" => (string) 令牌ID - * "TokenName" => (string) 令牌名称 - * "PublicKey" => (string) 令牌公钥 - * "PrivateKey" => (string) 令牌私钥 - * "AllowedOps" => (array) 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ] - * "AllowedPrefixes" => (array) 令牌允许操作的key前缀 - * "AllowedBuckets" => (array) 令牌允许操作的bucket - * "ExpireTime" => (integer) 令牌的超时时间点 - * "CreateTime" => (integer) 创建时间 - * "ModifyTime" => (integer) 修改时间 - * "Region" => (string) 所属地区 - * ] - * ] - * ] + * @throws UCloudException + */ + public function describeUFileLifeCycle(DescribeUFileLifeCycleRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUFileLifeCycleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUFileToken - 获取令牌信息 * - * @return DescribeUFileTokenResponse * @throws UCloudException */ public function describeUFileToken(DescribeUFileTokenRequest $request = null) @@ -262,56 +243,13 @@ public function describeUFileToken(DescribeUFileTokenRequest $request = null) $resp = $this->invoke($request); return new DescribeUFileTokenResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUFileDailyReport - 查看日消费报表 * - * See also: https://docs.ucloud.cn/api/ufile-api/get_ufile_daily_report - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "StartTime" => (integer) 查询开始时间;unix时间戳,单位s - * "EndTime" => (integer) 查询结束时间;unix时间戳,单位s - * "BucketName" => (string) 空间名称。此字段不为空,返回此Bucket日使用量;否则,返回这个项目的日使用量 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 消费情况[ - * [ - * "Total" => (array) 总消费情况[ - * [ - * "Flow" => (number) 下载流量:单位byte;国内无此字段 - * "IdleFlow" => (number) 闲时流量;单位byte;海外无此字段 - * "BusyFlow" => (number) 忙时流量;单位byte;海外无此字段 - * "CdnFlow" => (number) cdn回源流量;单位byte - * "ApiTimes" => (number) API请求次数(次) - * ] - * ] - * "Daily" => (array) 日消费情况[ - * [ - * "Storage" => (number) 标准存储量;单位byte - * "IaStorage" => (number) 低频存储量;单位byte - * "AcStorage" => (number) 冷存(归档)存储量;单位byte - * "IaGetSize" => (number) 低频数据取回量;单位byte - * "AcRestore" => (number) 冷存激活量,即归档数据取回量;单位byte - * "BusyFlow" => (number) 忙时流量;单位byte;海外无此字段 - * "IdleFlow" => (number) 闲时流量;单位byte;海外无此字段 - * "CdnFlow" => (number) cdn回源流量;单位byte - * "Flow" => (number) 下载流量:单位byte;国内无此字段 - * "Date" => (integer) 配额消费时间,unix时间戳(单位s),精确到日期 - * "ApiTimes" => (number) API请求次数(次) - * ] - * ] - * ] - * ] - * ] - * - * @return GetUFileDailyReportResponse * @throws UCloudException */ public function getUFileDailyReport(GetUFileDailyReportRequest $request = null) @@ -319,26 +257,13 @@ public function getUFileDailyReport(GetUFileDailyReportRequest $request = null) $resp = $this->invoke($request); return new GetUFileDailyReportResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUFileQuota - 查看配额状态 * - * See also: https://docs.ucloud.cn/api/ufile-api/get_ufile_quota - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "QuotaType" => (string) 配额类型,取值为storage-volume, download-traffic或request-count - * ] - * - * Outputs: - * - * $outputs = [ - * "LeftQuota" => (number) 剩余的配额数值 - * ] - * - * @return GetUFileQuotaResponse * @throws UCloudException */ public function getUFileQuota(GetUFileQuotaRequest $request = null) @@ -346,41 +271,13 @@ public function getUFileQuota(GetUFileQuotaRequest $request = null) $resp = $this->invoke($request); return new GetUFileQuotaResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUFileQuotaInfo - 获取配额信息 * - * See also: https://docs.ucloud.cn/api/ufile-api/get_ufile_quota_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "QuotaType" => (array) 配额类型,取值为storage-volume, download-traffic或request-count - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 配额信息数据集[ - * [ - * "Region" => (string) 可用地域 - * "Owe" => (integer) 是否欠费:1表示欠费;0表示未欠费 - * "Storage" => (object) 剩余存储容量[ - * "Left" => (number) 配额剩余量 - * ] - * "DownloadFlow" => (object) 剩余下载流量[ - * "Left" => (number) 配额剩余量 - * ] - * "RequestCnt" => (object) 剩余请求次数[ - * "Left" => (number) 配额剩余量 - * ] - * ] - * ] - * ] - * - * @return GetUFileQuotaInfoResponse * @throws UCloudException */ public function getUFileQuotaInfo(GetUFileQuotaInfoRequest $request = null) @@ -388,28 +285,13 @@ public function getUFileQuotaInfo(GetUFileQuotaInfoRequest $request = null) $resp = $this->invoke($request); return new GetUFileQuotaInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUFileQuotaPrice - 根据US3的购买配额,查询需要支付的价格。 * - * See also: https://docs.ucloud.cn/api/ufile-api/get_ufile_quota_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "StorageVolume" => (integer) 存储容量,单位: GB*天,范围: [0, 30 000 000],步长:100GB*天 - * "DownloadTraffic" => (integer) 下载流量,单位: GB,范围: [0, 60 000],步长:1GB - * "RequestCount" => (integer) 请求次数,单位:万次,范围:[0, 1 000 000],步长:1万次 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 待支付价格,单位:分 - * ] - * - * @return GetUFileQuotaPriceResponse * @throws UCloudException */ public function getUFileQuotaPrice(GetUFileQuotaPriceRequest $request = null) @@ -417,35 +299,13 @@ public function getUFileQuotaPrice(GetUFileQuotaPriceRequest $request = null) $resp = $this->invoke($request); return new GetUFileQuotaPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUFileReport - 查看配额使用报表 * - * See also: https://docs.ucloud.cn/api/ufile-api/get_ufile_report - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "StartTime" => (integer) 查询开始时间 - * "EndTime" => (integer) 查询结束时间 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 报表内容 参数见 UFileReportSet[ - * [ - * "Time" => (integer) 配额消费时间,unix时间戳,精确到日期 - * "StorageVolume" => (number) 配额消费当日使用的存储容量,单位:GB*天 - * "DownloadTraffic" => (number) 配额消费当日使用的下载流量,单位:GB - * "RequestCount" => (number) 配额消费当日使用的请求次数,单位:万次 - * ] - * ] - * ] - * - * @return GetUFileReportResponse * @throws UCloudException */ public function getUFileReport(GetUFileReportRequest $request = null) @@ -453,30 +313,13 @@ public function getUFileReport(GetUFileReportRequest $request = null) $resp = $this->invoke($request); return new GetUFileReportResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SetUFileReferer - 设置对象存储防盗链 * - * See also: https://docs.ucloud.cn/api/ufile-api/set_ufile_referer - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "BucketName" => (string) 存储空间名称 - * "RefererStatus" => (string) 开启关闭referer防盗链;关闭防盗链会清空防盗链参数设置,开启防盗链必须指定 RefererType、Referers;开启:on, 关闭:off; - * "RefererAllowNull" => (boolean) RefererType为白名单时,RefererAllowNull为false代表不允许空referer访问,为true代表允许空referer访问;此参数默认为 true; - * "RefererType" => (integer) 防盗链Referer类型,支持两种类型,黑名单和白名单; 1黑名单,2白名单;RefererStatus为"on"时此参数必填; - * "Referers" => (array) 防盗链Referer规则,支持正则表达式(不支持符号';') - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetUFileRefererResponse * @throws UCloudException */ public function setUFileReferer(SetUFileRefererRequest $request = null) @@ -484,28 +327,13 @@ public function setUFileReferer(SetUFileRefererRequest $request = null) $resp = $this->invoke($request); return new SetUFileRefererResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateBucket - 更改Bucket的属性 * - * See also: https://docs.ucloud.cn/api/ufile-api/update_bucket - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BucketName" => (string) 待修改Bucket的名称 - * "Type" => (string) Bucket访问类型;public或private - * ] - * - * Outputs: - * - * $outputs = [ - * "BucketName" => (string) Bucket的名称 - * "BucketId" => (string) Bucket的ID - * ] - * - * @return UpdateBucketResponse * @throws UCloudException */ public function updateBucket(UpdateBucketRequest $request = null) @@ -513,31 +341,27 @@ public function updateBucket(UpdateBucketRequest $request = null) $resp = $this->invoke($request); return new UpdateBucketResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * UpdateUFileToken - 更新令牌的操作权限,可操作key的前缀,可操作bucket和令牌超时时间点 - * - * See also: https://docs.ucloud.cn/api/ufile-api/update_ufile_token - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TokenId" => (string) 令牌ID - * "TokenName" => (string) 令牌名称 - * "AllowedOps" => (array) 令牌允许执行的操作,[ TOKEN_ALLOW_NONE , TOKEN_ALLOW_READ , TOKEN_ALLOW_WRITE , TOKEN_ALLOW_DELETE , TOKEN_ALLOW_LIST, TOKEN_ALLOW_IOP , TOKEN_ALLOW_DP ] - * "AllowedPrefixes" => (array) 令牌允许操作的key前缀 - * "AllowedBuckets" => (array) 令牌允许操作的bucket - * "ExpireTime" => (integer) 令牌的超时时间点(时间戳);注意:过期时间不能超过 4102416000 - * ] - * - * Outputs: + * UpdateUFileLifeCycle - 更新生命周期管理 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function updateUFileLifeCycle(UpdateUFileLifeCycleRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateUFileLifeCycleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateUFileToken - 更新令牌的操作权限,可操作key的前缀,可操作bucket和令牌超时时间点 * - * @return UpdateUFileTokenResponse * @throws UCloudException */ public function updateUFileToken(UpdateUFileTokenRequest $request = null) diff --git a/src/UHost/Apis/CopyCustomImageRequest.php b/src/UHost/Apis/CopyCustomImageRequest.php index 1ba80ca2..d92b657d 100644 --- a/src/UHost/Apis/CopyCustomImageRequest.php +++ b/src/UHost/Apis/CopyCustomImageRequest.php @@ -1,6 +1,7 @@ markRequired("TargetProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SourceImageId: 源镜像Id, 参见 DescribeImage * @@ -105,11 +103,10 @@ public function getSourceImageId() * * @param string $sourceImageId */ - public function setSourceImageId($sourceImageId) + public function setSourceImageId(string $sourceImageId) { $this->set("SourceImageId", $sourceImageId); } - /** * TargetProjectId: 目标项目Id, 参见 GetProjectList * @@ -125,11 +122,10 @@ public function getTargetProjectId() * * @param string $targetProjectId */ - public function setTargetProjectId($targetProjectId) + public function setTargetProjectId(string $targetProjectId) { $this->set("TargetProjectId", $targetProjectId); } - /** * TargetRegion: 目标地域,不跨地域不用填 * @@ -145,11 +141,10 @@ public function getTargetRegion() * * @param string $targetRegion */ - public function setTargetRegion($targetRegion) + public function setTargetRegion(string $targetRegion) { $this->set("TargetRegion", $targetRegion); } - /** * TargetImageName: 目标镜像名称 * @@ -165,11 +160,10 @@ public function getTargetImageName() * * @param string $targetImageName */ - public function setTargetImageName($targetImageName) + public function setTargetImageName(string $targetImageName) { $this->set("TargetImageName", $targetImageName); } - /** * TargetImageDescription: 目标镜像描述 * @@ -185,7 +179,7 @@ public function getTargetImageDescription() * * @param string $targetImageDescription */ - public function setTargetImageDescription($targetImageDescription) + public function setTargetImageDescription(string $targetImageDescription) { $this->set("TargetImageDescription", $targetImageDescription); } diff --git a/src/UHost/Apis/CopyCustomImageResponse.php b/src/UHost/Apis/CopyCustomImageResponse.php index ebd22395..c1373c6d 100644 --- a/src/UHost/Apis/CopyCustomImageResponse.php +++ b/src/UHost/Apis/CopyCustomImageResponse.php @@ -1,6 +1,7 @@ set("TargetImageId", $targetImageId); } diff --git a/src/UHost/Apis/CreateCustomImageRequest.php b/src/UHost/Apis/CreateCustomImageRequest.php index 72566081..1aa355a5 100644 --- a/src/UHost/Apis/CreateCustomImageRequest.php +++ b/src/UHost/Apis/CreateCustomImageRequest.php @@ -1,6 +1,7 @@ markRequired("ImageName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -105,11 +103,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * ImageName: 镜像名称 * @@ -125,11 +122,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * ImageDescription: 镜像描述 * @@ -145,7 +141,7 @@ public function getImageDescription() * * @param string $imageDescription */ - public function setImageDescription($imageDescription) + public function setImageDescription(string $imageDescription) { $this->set("ImageDescription", $imageDescription); } diff --git a/src/UHost/Apis/CreateCustomImageResponse.php b/src/UHost/Apis/CreateCustomImageResponse.php index 2ea9ed32..aa73dd49 100644 --- a/src/UHost/Apis/CreateCustomImageResponse.php +++ b/src/UHost/Apis/CreateCustomImageResponse.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } diff --git a/src/UHost/Apis/CreateIsolationGroupRequest.php b/src/UHost/Apis/CreateIsolationGroupRequest.php index bd55c3da..a73f8ad4 100644 --- a/src/UHost/Apis/CreateIsolationGroupRequest.php +++ b/src/UHost/Apis/CreateIsolationGroupRequest.php @@ -1,6 +1,7 @@ markRequired("GroupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目id * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupName: 硬件隔离组名称。请遵照[[api:uhost-api:specification|字段规范]]设定隔离组名称。 * @@ -84,11 +83,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * Remark: 备注。请遵照[[api:uhost-api:specification|字段规范]]设定隔离组备注。 * @@ -104,7 +102,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UHost/Apis/CreateIsolationGroupResponse.php b/src/UHost/Apis/CreateIsolationGroupResponse.php index 21b4dbca..fd985d5f 100644 --- a/src/UHost/Apis/CreateIsolationGroupResponse.php +++ b/src/UHost/Apis/CreateIsolationGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UHost/Apis/CreateUHostInstanceRequest.php b/src/UHost/Apis/CreateUHostInstanceRequest.php index c75f8551..28b33edc 100644 --- a/src/UHost/Apis/CreateUHostInstanceRequest.php +++ b/src/UHost/Apis/CreateUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("LoginMode"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -53,11 +54,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -73,11 +73,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -93,11 +92,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageId: 镜像ID。 请通过 [DescribeImage](describe_image.html)获取 * @@ -113,15 +111,14 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * Disks: * - * @return CreateUHostInstanceParamDisks[]|null + * @return CreateUHostInstanceRequestDisksModel[]|null */ public function getDisks() { @@ -131,7 +128,7 @@ public function getDisks() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUHostInstanceParamDisks($item)); + array_push($result, new CreateUHostInstanceRequestDisksModel($item)); } return $result; } @@ -139,7 +136,7 @@ public function getDisks() /** * Disks: * - * @param CreateUHostInstanceParamDisks[] $disks + * @param CreateUHostInstanceRequestDisksModel[] $disks */ public function setDisks(array $disks) { @@ -149,7 +146,6 @@ public function setDisks(array $disks) } return $result; } - /** * LoginMode: 主机登陆模式。密码(默认选项): Password,密钥:KeyPair。 * @@ -165,11 +161,10 @@ public function getLoginMode() * * @param string $loginMode */ - public function setLoginMode($loginMode) + public function setLoginMode(string $loginMode) { $this->set("LoginMode", $loginMode); } - /** * Password: UHost密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,举例如下:# echo -n Password1 | base64UGFzc3dvcmQx。 * @@ -185,11 +180,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * Name: UHost实例名称。默认:UHost。请遵照[[api:uhost-api:specification|字段规范]]设定实例名称。 * @@ -205,11 +199,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务组。默认:Default(Default即为未分组)。请遵照[[api:uhost-api:specification|字段规范]]设定业务组。 * @@ -225,13 +218,12 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** - * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\Preemptive计费为抢占式实例 \\ 默认为月付 + * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\Preemptive计费为抢占式实例(内测阶段) \\ 默认为月付 * * @return string|null */ @@ -241,15 +233,14 @@ public function getChargeType() } /** - * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\Preemptive计费为抢占式实例 \\ 默认为月付 + * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\Preemptive计费为抢占式实例(内测阶段) \\ 默认为月付 * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长。默认:值 1。按小时购买(Dynamic/Postpay)时无需此参数。 月付时,此参数传0,代表购买至月末。 * @@ -265,11 +256,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * UHostType: 【建议后续不再使用】云主机机型(V1.0),在本字段和字段MachineType中,仅需要其中1个字段即可。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -285,11 +275,10 @@ public function getUHostType() * * @param string $uHostType */ - public function setUHostType($uHostType) + public function setUHostType(string $uHostType) { $this->set("UHostType", $uHostType); } - /** * CPU: 虚拟CPU核数。可选参数:1-64(具体机型与CPU的对应关系参照控制台)。默认值: 4。 * @@ -305,11 +294,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参考控制台)。默认值:8192 * @@ -325,11 +313,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * GpuType: GPU类型,枚举值["K80", "P40", "V100", "T4", "T4S","2080Ti","2080Ti-4C","1080Ti", "T4/4", "MI100", "V100S"],MachineType为G时必填 * @@ -345,11 +332,10 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } - /** * GPU: GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) * @@ -365,11 +351,10 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } - /** * NetCapability: 网络增强特性。枚举值:Normal(默认),不开启; Super,开启网络增强1.0; Ultra,开启网络增强2.0(仅支持部分可用区,请参考控制台) * @@ -385,11 +370,10 @@ public function getNetCapability() * * @param string $netCapability */ - public function setNetCapability($netCapability) + public function setNetCapability(string $netCapability) { $this->set("NetCapability", $netCapability); } - /** * HotplugFeature: 热升级特性。True为开启,False为未开启,默认False。 * @@ -405,11 +389,10 @@ public function getHotplugFeature() * * @param boolean $hotplugFeature */ - public function setHotplugFeature($hotplugFeature) + public function setHotplugFeature(bool $hotplugFeature) { $this->set("HotplugFeature", $hotplugFeature); } - /** * VPCId: VPC ID。默认为当前地域的默认VPC。 * @@ -425,11 +408,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网 ID。默认为当前地域的默认子网。 * @@ -445,11 +427,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * PrivateIp: 【数组】创建云主机时指定内网IP。若不传值,则随机分配当前子网下的IP。调用方式举例:PrivateIp.0=x.x.x.x。当前只支持一个内网IP。 * @@ -469,7 +450,6 @@ public function setPrivateIp(array $privateIp) { $this->set("PrivateIp", $privateIp); } - /** * SecurityGroupId: 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。 * @@ -485,11 +465,10 @@ public function getSecurityGroupId() * * @param string $securityGroupId */ - public function setSecurityGroupId($securityGroupId) + public function setSecurityGroupId(string $securityGroupId) { $this->set("SecurityGroupId", $securityGroupId); } - /** * IsolationGroup: 硬件隔离组id。可通过DescribeIsolationGroup获取。 * @@ -505,11 +484,10 @@ public function getIsolationGroup() * * @param string $isolationGroup */ - public function setIsolationGroup($isolationGroup) + public function setIsolationGroup(string $isolationGroup) { $this->set("IsolationGroup", $isolationGroup); } - /** * AlarmTemplateId: 告警模板id,如果传了告警模板id,且告警模板id正确,则绑定告警模板。绑定告警模板失败只会在后台有日志,不会影响创建主机流程,也不会在前端报错。 * @@ -525,11 +503,10 @@ public function getAlarmTemplateId() * * @param int $alarmTemplateId */ - public function setAlarmTemplateId($alarmTemplateId) + public function setAlarmTemplateId(int $alarmTemplateId) { $this->set("AlarmTemplateId", $alarmTemplateId); } - /** * MachineType: 云主机机型(V2.0),在本字段和字段UHostType中,仅需要其中1个字段即可。枚举值["N", "C", "G", "O", "OS", "OM", "OPRO", "OMAX", "O.BM", "O.EPC"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -545,11 +522,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * MinimalCpuPlatform: 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake", "Intel/CascadelakeR", "Intel/IceLake", "Amd/Epyc2", "Amd/Auto"],默认值是"Intel/Auto"。 * @@ -565,11 +541,10 @@ public function getMinimalCpuPlatform() * * @param string $minimalCpuPlatform */ - public function setMinimalCpuPlatform($minimalCpuPlatform) + public function setMinimalCpuPlatform(string $minimalCpuPlatform) { $this->set("MinimalCpuPlatform", $minimalCpuPlatform); } - /** * MaxCount: 本次最大创建主机数量,取值范围是[1,100],默认值为1。 * @@ -585,15 +560,14 @@ public function getMaxCount() * * @param int $maxCount */ - public function setMaxCount($maxCount) + public function setMaxCount(int $maxCount) { $this->set("MaxCount", $maxCount); } - /** * NetworkInterface: * - * @return CreateUHostInstanceParamNetworkInterface[]|null + * @return CreateUHostInstanceRequestNetworkInterfaceModel[]|null */ public function getNetworkInterface() { @@ -603,7 +577,7 @@ public function getNetworkInterface() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUHostInstanceParamNetworkInterface($item)); + array_push($result, new CreateUHostInstanceRequestNetworkInterfaceModel($item)); } return $result; } @@ -611,7 +585,7 @@ public function getNetworkInterface() /** * NetworkInterface: * - * @param CreateUHostInstanceParamNetworkInterface[] $networkInterface + * @param CreateUHostInstanceRequestNetworkInterfaceModel[] $networkInterface */ public function setNetworkInterface(array $networkInterface) { @@ -621,7 +595,6 @@ public function setNetworkInterface(array $networkInterface) } return $result; } - /** * UserData: 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码 * @@ -637,11 +610,10 @@ public function getUserData() * * @param string $userData */ - public function setUserData($userData) + public function setUserData(string $userData) { $this->set("UserData", $userData); } - /** * AutoDataDiskInit: 数据盘是否需要自动分区挂载。当镜像支持“Cloud-init”Feature时可填写此字段。取值 >“On” 自动挂载(默认值)> “Off” 不自动挂载。 * @@ -657,15 +629,14 @@ public function getAutoDataDiskInit() * * @param string $autoDataDiskInit */ - public function setAutoDataDiskInit($autoDataDiskInit) + public function setAutoDataDiskInit(string $autoDataDiskInit) { $this->set("AutoDataDiskInit", $autoDataDiskInit); } - /** * Volumes: * - * @return CreateUHostInstanceParamVolumes[]|null + * @return CreateUHostInstanceRequestVolumesModel[]|null */ public function getVolumes() { @@ -675,7 +646,7 @@ public function getVolumes() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUHostInstanceParamVolumes($item)); + array_push($result, new CreateUHostInstanceRequestVolumesModel($item)); } return $result; } @@ -683,7 +654,7 @@ public function getVolumes() /** * Volumes: * - * @param CreateUHostInstanceParamVolumes[] $volumes + * @param CreateUHostInstanceRequestVolumesModel[] $volumes */ public function setVolumes(array $volumes) { @@ -693,7 +664,6 @@ public function setVolumes(array $volumes) } return $result; } - /** * KeyPairId: KeypairId 密钥对ID,LoginMode为KeyPair时此项必须 * @@ -709,31 +679,29 @@ public function getKeyPairId() * * @param string $keyPairId */ - public function setKeyPairId($keyPairId) + public function setKeyPairId(string $keyPairId) { $this->set("KeyPairId", $keyPairId); } - /** * Features: * - * @return CreateUHostInstanceParamFeatures|null + * @return CreateUHostInstanceRequestFeaturesModel|null */ public function getFeatures() { - return new CreateUHostInstanceParamFeatures($this->get("Features")); + return new CreateUHostInstanceRequestFeaturesModel($this->get("Features")); } /** * Features: * - * @param CreateUHostInstanceParamFeatures $features + * @param CreateUHostInstanceRequestFeaturesModel $features */ - public function setFeatures(array $features) + public function setFeatures(CreateUHostInstanceRequestFeaturesModel $features) { $this->set("Features", $features->getAll()); } - /** * CouponId: 主机代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看 * @@ -749,7 +717,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UHost/Apis/CreateUHostInstanceResponse.php b/src/UHost/Apis/CreateUHostInstanceResponse.php index 7351b387..84d5bbcb 100644 --- a/src/UHost/Apis/CreateUHostInstanceResponse.php +++ b/src/UHost/Apis/CreateUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostIds", $uHostIds); } - /** * IPs: 【批量创建不会返回】IP信息 * diff --git a/src/UHost/Apis/CreateUHostKeyPairRequest.php b/src/UHost/Apis/CreateUHostKeyPairRequest.php index cb18a938..6f8a00ba 100644 --- a/src/UHost/Apis/CreateUHostKeyPairRequest.php +++ b/src/UHost/Apis/CreateUHostKeyPairRequest.php @@ -1,6 +1,7 @@ markRequired("KeyPairName"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * KeyPairName: 密钥对名称。 由字母,数字,符号组成,长度为1-63位。 * @@ -103,7 +101,7 @@ public function getKeyPairName() * * @param string $keyPairName */ - public function setKeyPairName($keyPairName) + public function setKeyPairName(string $keyPairName) { $this->set("KeyPairName", $keyPairName); } diff --git a/src/UHost/Apis/CreateUHostKeyPairResponse.php b/src/UHost/Apis/CreateUHostKeyPairResponse.php index 49098f38..ad26a804 100644 --- a/src/UHost/Apis/CreateUHostKeyPairResponse.php +++ b/src/UHost/Apis/CreateUHostKeyPairResponse.php @@ -1,6 +1,7 @@ get("KeyPair")); + return new KeyPairModel($this->get("KeyPair")); } /** * KeyPair: 密钥信息 * - * @param KeyPair $keyPair + * @param KeyPairModel $keyPair */ - public function setKeyPair(array $keyPair) + public function setKeyPair(KeyPairModel $keyPair) { $this->set("KeyPair", $keyPair->getAll()); } diff --git a/src/UHost/Apis/DeleteIsolationGroupRequest.php b/src/UHost/Apis/DeleteIsolationGroupRequest.php index c8a42371..5769ae33 100644 --- a/src/UHost/Apis/DeleteIsolationGroupRequest.php +++ b/src/UHost/Apis/DeleteIsolationGroupRequest.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目id * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 硬件隔离组id * @@ -84,7 +83,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UHost/Apis/DeleteIsolationGroupResponse.php b/src/UHost/Apis/DeleteIsolationGroupResponse.php index 2593e0a4..40a368eb 100644 --- a/src/UHost/Apis/DeleteIsolationGroupResponse.php +++ b/src/UHost/Apis/DeleteIsolationGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UHost/Apis/DeleteUHostKeyPairsRequest.php b/src/UHost/Apis/DeleteUHostKeyPairsRequest.php index d4f3efc5..786425bc 100644 --- a/src/UHost/Apis/DeleteUHostKeyPairsRequest.php +++ b/src/UHost/Apis/DeleteUHostKeyPairsRequest.php @@ -1,6 +1,7 @@ markRequired("KeyPairIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * KeyPairIds: 密钥对ID,最多支持 100 对。 * diff --git a/src/UHost/Apis/DeleteUHostKeyPairsResponse.php b/src/UHost/Apis/DeleteUHostKeyPairsResponse.php index ab5048c6..0f99dd42 100644 --- a/src/UHost/Apis/DeleteUHostKeyPairsResponse.php +++ b/src/UHost/Apis/DeleteUHostKeyPairsResponse.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageType: 镜像类型。标准镜像:Base,镜像市场:Business, 自定义镜像:Custom,默认返回所有类型 * @@ -103,11 +101,10 @@ public function getImageType() * * @param string $imageType */ - public function setImageType($imageType) + public function setImageType(string $imageType) { $this->set("ImageType", $imageType); } - /** * OsType: 操作系统类型:Linux, Windows 默认返回所有类型 * @@ -123,11 +120,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * ImageId: 镜像Id * @@ -143,11 +139,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -163,11 +158,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20 * @@ -183,11 +177,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * PriceSet: 是否返回价格:1返回,0不返回;默认不返回 * @@ -203,7 +196,7 @@ public function getPriceSet() * * @param int $priceSet */ - public function setPriceSet($priceSet) + public function setPriceSet(int $priceSet) { $this->set("PriceSet", $priceSet); } diff --git a/src/UHost/Apis/DescribeImageResponse.php b/src/UHost/Apis/DescribeImageResponse.php index ff8c32b8..c287506c 100644 --- a/src/UHost/Apis/DescribeImageResponse.php +++ b/src/UHost/Apis/DescribeImageResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * ImageSet: 镜像列表详见 UHostImageSet * - * @return UHostImageSet[]|null + * @return UHostImageSetModel[]|null */ public function getImageSet() { @@ -56,7 +57,7 @@ public function getImageSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostImageSet($item)); + array_push($result, new UHostImageSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getImageSet() /** * ImageSet: 镜像列表详见 UHostImageSet * - * @param UHostImageSet[] $imageSet + * @param UHostImageSetModel[] $imageSet */ public function setImageSet(array $imageSet) { diff --git a/src/UHost/Apis/DescribeIsolationGroupRequest.php b/src/UHost/Apis/DescribeIsolationGroupRequest.php index 372cb322..2e590abe 100644 --- a/src/UHost/Apis/DescribeIsolationGroupRequest.php +++ b/src/UHost/Apis/DescribeIsolationGroupRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目id * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 待查的硬件隔离组id * @@ -83,11 +82,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20,最大100 * @@ -123,7 +120,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UHost/Apis/DescribeIsolationGroupResponse.php b/src/UHost/Apis/DescribeIsolationGroupResponse.php index 38e90339..526a9d31 100644 --- a/src/UHost/Apis/DescribeIsolationGroupResponse.php +++ b/src/UHost/Apis/DescribeIsolationGroupResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IsolationGroup($item)); + array_push($result, new IsolationGroupModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getIsolationGroupSet() /** * IsolationGroupSet: 硬件隔离组集合。参见数据结构IsolationGroup。 * - * @param IsolationGroup[] $isolationGroupSet + * @param IsolationGroupModel[] $isolationGroupSet */ public function setIsolationGroupSet(array $isolationGroupSet) { @@ -55,7 +57,6 @@ public function setIsolationGroupSet(array $isolationGroupSet) } return $result; } - /** * TotalCount: 硬件隔离组总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UHost/Apis/DescribeUHostInstanceRequest.php b/src/UHost/Apis/DescribeUHostInstanceRequest.php index 6213a369..25a03ff3 100644 --- a/src/UHost/Apis/DescribeUHostInstanceRequest.php +++ b/src/UHost/Apis/DescribeUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostIds: 【数组】UHost主机的资源ID,例如UHostIds.0代表希望获取信息 的主机1,UHostIds.1代表主机2。 如果不传入,则返回当前Region 所有符合条件的UHost实例。 * @@ -107,7 +105,6 @@ public function setUHostIds(array $uHostIds) { $this->set("UHostIds", $uHostIds); } - /** * Tag: 要查询的业务组名称 * @@ -123,11 +120,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -143,11 +139,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20,最大100 * @@ -163,11 +158,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * IsolationGroup: 硬件隔离组id。通过硬件隔离组筛选主机。 * @@ -183,11 +177,10 @@ public function getIsolationGroup() * * @param string $isolationGroup */ - public function setIsolationGroup($isolationGroup) + public function setIsolationGroup(string $isolationGroup) { $this->set("IsolationGroup", $isolationGroup); } - /** * VPCId: vpc id。通过VPC筛选主机。北京一地域无效。 * @@ -203,11 +196,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网id。通过子网筛选主机。北京一地域无效。 * @@ -223,11 +215,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * UDiskIdForAttachment: 要挂载的云盘id,过滤返回能被UDiskId挂载的云主机。目前主要针对rssd云盘使用 * @@ -243,7 +234,7 @@ public function getUDiskIdForAttachment() * * @param string $uDiskIdForAttachment */ - public function setUDiskIdForAttachment($uDiskIdForAttachment) + public function setUDiskIdForAttachment(string $uDiskIdForAttachment) { $this->set("UDiskIdForAttachment", $uDiskIdForAttachment); } diff --git a/src/UHost/Apis/DescribeUHostInstanceResponse.php b/src/UHost/Apis/DescribeUHostInstanceResponse.php index 259ee0e6..2dd68001 100644 --- a/src/UHost/Apis/DescribeUHostInstanceResponse.php +++ b/src/UHost/Apis/DescribeUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * UHostSet: 云主机实例列表,每项参数可见下面 UHostInstanceSet * - * @return UHostInstanceSet[]|null + * @return UHostInstanceSetModel[]|null */ public function getUHostSet() { @@ -59,7 +60,7 @@ public function getUHostSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostInstanceSet($item)); + array_push($result, new UHostInstanceSetModel($item)); } return $result; } @@ -67,7 +68,7 @@ public function getUHostSet() /** * UHostSet: 云主机实例列表,每项参数可见下面 UHostInstanceSet * - * @param UHostInstanceSet[] $uHostSet + * @param UHostInstanceSetModel[] $uHostSet */ public function setUHostSet(array $uHostSet) { diff --git a/src/UHost/Apis/DescribeUHostKeyPairsRequest.php b/src/UHost/Apis/DescribeUHostKeyPairsRequest.php index 7b7974b1..de263578 100644 --- a/src/UHost/Apis/DescribeUHostKeyPairsRequest.php +++ b/src/UHost/Apis/DescribeUHostKeyPairsRequest.php @@ -1,6 +1,7 @@ "DescribeUHostKeyPairs"]); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -42,11 +43,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -62,11 +62,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -82,11 +81,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * KeyPairName: 密钥对名称。 * @@ -102,11 +100,10 @@ public function getKeyPairName() * * @param string $keyPairName */ - public function setKeyPairName($keyPairName) + public function setKeyPairName(string $keyPairName) { $this->set("KeyPairName", $keyPairName); } - /** * KeyPairFingerPrint: 密钥对的指纹。 * @@ -122,11 +119,10 @@ public function getKeyPairFingerPrint() * * @param string $keyPairFingerPrint */ - public function setKeyPairFingerPrint($keyPairFingerPrint) + public function setKeyPairFingerPrint(string $keyPairFingerPrint) { $this->set("KeyPairFingerPrint", $keyPairFingerPrint); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -142,11 +138,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20,最大100 * @@ -162,7 +157,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UHost/Apis/DescribeUHostKeyPairsResponse.php b/src/UHost/Apis/DescribeUHostKeyPairsResponse.php index ce64b02a..12f06bd6 100644 --- a/src/UHost/Apis/DescribeUHostKeyPairsResponse.php +++ b/src/UHost/Apis/DescribeUHostKeyPairsResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new KeyPairDesc($item)); + array_push($result, new KeyPairDescModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getKeyPairs() /** * KeyPairs: 密钥对信息集合 * - * @param KeyPairDesc[] $keyPairs + * @param KeyPairDescModel[] $keyPairs */ public function setKeyPairs(array $keyPairs) { @@ -54,7 +56,6 @@ public function setKeyPairs(array $keyPairs) } return $result; } - /** * TotalCount: 密钥对总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UHost/Apis/DescribeUHostTagsRequest.php b/src/UHost/Apis/DescribeUHostTagsRequest.php index 3a66a115..800943e6 100644 --- a/src/UHost/Apis/DescribeUHostTagsRequest.php +++ b/src/UHost/Apis/DescribeUHostTagsRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,7 +82,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UHost/Apis/DescribeUHostTagsResponse.php b/src/UHost/Apis/DescribeUHostTagsResponse.php index 060b1d7e..d18cabbf 100644 --- a/src/UHost/Apis/DescribeUHostTagsResponse.php +++ b/src/UHost/Apis/DescribeUHostTagsResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * TagSet: 业务组集合见 UHostTagSet * - * @return UHostTagSet[]|null + * @return UHostTagSetModel[]|null */ public function getTagSet() { @@ -56,7 +57,7 @@ public function getTagSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostTagSet($item)); + array_push($result, new UHostTagSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getTagSet() /** * TagSet: 业务组集合见 UHostTagSet * - * @param UHostTagSet[] $tagSet + * @param UHostTagSetModel[] $tagSet */ public function setTagSet(array $tagSet) { diff --git a/src/UHost/Apis/GetAttachedDiskUpgradePriceRequest.php b/src/UHost/Apis/GetAttachedDiskUpgradePriceRequest.php index 6b865b58..ed3daafb 100644 --- a/src/UHost/Apis/GetAttachedDiskUpgradePriceRequest.php +++ b/src/UHost/Apis/GetAttachedDiskUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * DiskSpace: 磁盘大小,单位GB,步长为10。取值范围需大于当前磁盘大小,最大值请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -106,11 +104,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * DiskId: 磁盘ID。参见 [DescribeUHostInstance](describe_uhost_instance.html)返回值中的DiskSet。 * @@ -126,11 +123,10 @@ public function getDiskId() * * @param string $diskId */ - public function setDiskId($diskId) + public function setDiskId(string $diskId) { $this->set("DiskId", $diskId); } - /** * UHostId: UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 * @@ -146,11 +142,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * BackupMode: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\> SNAPSHOT(SNAPSHOT模式目前仅在上海C支持),快照 \\ 当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]]。默认值为当前的备份模式。 * @@ -166,7 +161,7 @@ public function getBackupMode() * * @param string $backupMode */ - public function setBackupMode($backupMode) + public function setBackupMode(string $backupMode) { $this->set("BackupMode", $backupMode); } diff --git a/src/UHost/Apis/GetAttachedDiskUpgradePriceResponse.php b/src/UHost/Apis/GetAttachedDiskUpgradePriceResponse.php index 143a082a..3fef8164 100644 --- a/src/UHost/Apis/GetAttachedDiskUpgradePriceResponse.php +++ b/src/UHost/Apis/GetAttachedDiskUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UHost/Apis/GetUHostInstancePriceRequest.php b/src/UHost/Apis/GetUHostInstancePriceRequest.php index 33759f70..8c30659a 100644 --- a/src/UHost/Apis/GetUHostInstancePriceRequest.php +++ b/src/UHost/Apis/GetUHostInstancePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Count"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -49,11 +51,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -69,11 +70,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -89,11 +89,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * CPU: CPU核数。可选参数:1-64。可选范围参照控制台。默认值: 4 * @@ -109,11 +108,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参照好控制台)。默认值:8192 * @@ -129,11 +127,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * Count: 购买台数,范围[1,5] * @@ -149,15 +146,14 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Disks: * - * @return GetUHostInstancePriceParamDisks[]|null + * @return GetUHostInstancePriceRequestDisksModel[]|null */ public function getDisks() { @@ -167,7 +163,7 @@ public function getDisks() } $result = []; foreach ($items as $i => $item) { - array_push($result, new GetUHostInstancePriceParamDisks($item)); + array_push($result, new GetUHostInstancePriceRequestDisksModel($item)); } return $result; } @@ -175,7 +171,7 @@ public function getDisks() /** * Disks: * - * @param GetUHostInstancePriceParamDisks[] $disks + * @param GetUHostInstancePriceRequestDisksModel[] $disks */ public function setDisks(array $disks) { @@ -185,7 +181,6 @@ public function setDisks(array $disks) } return $result; } - /** * ImageId: 镜像Id,可通过 [DescribeImage](describe_image.html) 获取镜像ID, 如果镜像ID不传,系统盘大小必传 * @@ -201,11 +196,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * GPU: GPU卡核心数。仅GPU机型支持此字段。 * @@ -221,11 +215,10 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时付费 // >Preemptive 抢占式实例 \\ 如果不传某个枚举值,默认返回年付、月付、时付的价格组合集。 * @@ -241,11 +234,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * NetCapability: 网络增强。枚举值:Normal,不开启; Super,开启网络增强1.0。 默认值为Normal。 * @@ -261,11 +253,10 @@ public function getNetCapability() * * @param string $netCapability */ - public function setNetCapability($netCapability) + public function setNetCapability(string $netCapability) { $this->set("NetCapability", $netCapability); } - /** * UHostType: 【待废弃】云主机机型(V1版本概念)。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -281,11 +272,10 @@ public function getUHostType() * * @param string $uHostType */ - public function setUHostType($uHostType) + public function setUHostType(string $uHostType) { $this->set("UHostType", $uHostType); } - /** * MachineType: 云主机机型(V2版本概念)。枚举值["N", "C", "G", "O", "OS", "OPRO", "OMAX", "O.BM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -301,11 +291,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * GpuType: GPU类型,枚举值["K80", "P40", "V100", "T4","T4S","2080Ti","2080Ti-4C","1080Ti"] * @@ -321,11 +310,10 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } - /** * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 * @@ -341,11 +329,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * CpuPlatform: 取值"Intel" "Amd",默认值“Intel” * @@ -361,15 +348,14 @@ public function getCpuPlatform() * * @param string $cpuPlatform */ - public function setCpuPlatform($cpuPlatform) + public function setCpuPlatform(string $cpuPlatform) { $this->set("CpuPlatform", $cpuPlatform); } - /** * Volumes: * - * @return GetUHostInstancePriceParamVolumes[]|null + * @return GetUHostInstancePriceRequestVolumesModel[]|null */ public function getVolumes() { @@ -379,7 +365,7 @@ public function getVolumes() } $result = []; foreach ($items as $i => $item) { - array_push($result, new GetUHostInstancePriceParamVolumes($item)); + array_push($result, new GetUHostInstancePriceRequestVolumesModel($item)); } return $result; } @@ -387,7 +373,7 @@ public function getVolumes() /** * Volumes: * - * @param GetUHostInstancePriceParamVolumes[] $volumes + * @param GetUHostInstancePriceRequestVolumesModel[] $volumes */ public function setVolumes(array $volumes) { @@ -397,23 +383,22 @@ public function setVolumes(array $volumes) } return $result; } - /** * VirtualGpu: * - * @return GetUHostInstancePriceParamVirtualGpu|null + * @return GetUHostInstancePriceRequestVirtualGpuModel|null */ public function getVirtualGpu() { - return new GetUHostInstancePriceParamVirtualGpu($this->get("VirtualGpu")); + return new GetUHostInstancePriceRequestVirtualGpuModel($this->get("VirtualGpu")); } /** * VirtualGpu: * - * @param GetUHostInstancePriceParamVirtualGpu $virtualGpu + * @param GetUHostInstancePriceRequestVirtualGpuModel $virtualGpu */ - public function setVirtualGpu(array $virtualGpu) + public function setVirtualGpu(GetUHostInstancePriceRequestVirtualGpuModel $virtualGpu) { $this->set("VirtualGpu", $virtualGpu->getAll()); } diff --git a/src/UHost/Apis/GetUHostInstancePriceResponse.php b/src/UHost/Apis/GetUHostInstancePriceResponse.php index 812d6f35..39717e1a 100644 --- a/src/UHost/Apis/GetUHostInstancePriceResponse.php +++ b/src/UHost/Apis/GetUHostInstancePriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UHostPriceSet($item)); + array_push($result, new UHostPriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getPriceSet() /** * PriceSet: 价格列表 UHostPriceSet * - * @param UHostPriceSet[] $priceSet + * @param UHostPriceSetModel[] $priceSet */ public function setPriceSet(array $priceSet) { diff --git a/src/UHost/Apis/GetUHostInstanceVncInfoRequest.php b/src/UHost/Apis/GetUHostInstanceVncInfoRequest.php index b47431c1..ab44d12f 100644 --- a/src/UHost/Apis/GetUHostInstanceVncInfoRequest.php +++ b/src/UHost/Apis/GetUHostInstanceVncInfoRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](./describe_uhost_instance.html) * @@ -104,7 +102,7 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/GetUHostInstanceVncInfoResponse.php b/src/UHost/Apis/GetUHostInstanceVncInfoResponse.php index 583e4fc5..1f916a0d 100644 --- a/src/UHost/Apis/GetUHostInstanceVncInfoResponse.php +++ b/src/UHost/Apis/GetUHostInstanceVncInfoResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } - /** * VncIP: Vnc登录IP * @@ -57,11 +57,10 @@ public function getVncIP() * * @param string $vncIP */ - public function setVncIP($vncIP) + public function setVncIP(string $vncIP) { $this->set("VncIP", $vncIP); } - /** * VncPort: Vnc登录端口 * @@ -77,11 +76,10 @@ public function getVncPort() * * @param int $vncPort */ - public function setVncPort($vncPort) + public function setVncPort(int $vncPort) { $this->set("VncPort", $vncPort); } - /** * VncPassword: Vnc 登录密码 * @@ -97,7 +95,7 @@ public function getVncPassword() * * @param string $vncPassword */ - public function setVncPassword($vncPassword) + public function setVncPassword(string $vncPassword) { $this->set("VncPassword", $vncPassword); } diff --git a/src/UHost/Apis/GetUHostUpgradePriceRequest.php b/src/UHost/Apis/GetUHostUpgradePriceRequest.php index 7b8ce9c1..83054059 100644 --- a/src/UHost/Apis/GetUHostUpgradePriceRequest.php +++ b/src/UHost/Apis/GetUHostUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * CPU: 虚拟CPU核数。可选参数:1-64(可选范围参考控制台)。默认值为当前实例的CPU核数。 * @@ -124,11 +121,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参考控制台)。默认值为当前实例的内存大小。 * @@ -144,11 +140,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * NetCapValue: 网卡升降级(1,表示升级,2表示降级,0表示不变) * @@ -164,7 +159,7 @@ public function getNetCapValue() * * @param int $netCapValue */ - public function setNetCapValue($netCapValue) + public function setNetCapValue(int $netCapValue) { $this->set("NetCapValue", $netCapValue); } diff --git a/src/UHost/Apis/GetUHostUpgradePriceResponse.php b/src/UHost/Apis/GetUHostUpgradePriceResponse.php index 2ef6d558..ca03a188 100644 --- a/src/UHost/Apis/GetUHostUpgradePriceResponse.php +++ b/src/UHost/Apis/GetUHostUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } - /** * OriginalPrice: 限时优惠的折前原价 * @@ -57,7 +57,7 @@ public function getOriginalPrice() * * @param float $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(float $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UHost/Apis/ImportCustomImageRequest.php b/src/UHost/Apis/ImportCustomImageRequest.php index 15d0cd5d..fe25c6da 100644 --- a/src/UHost/Apis/ImportCustomImageRequest.php +++ b/src/UHost/Apis/ImportCustomImageRequest.php @@ -1,6 +1,7 @@ markRequired("Auth"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -49,11 +50,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -69,11 +69,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageName: 镜像名称 * @@ -89,11 +88,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * UFileUrl: UFile私有空间地址 * @@ -109,11 +107,10 @@ public function getUFileUrl() * * @param string $uFileUrl */ - public function setUFileUrl($uFileUrl) + public function setUFileUrl(string $uFileUrl) { $this->set("UFileUrl", $uFileUrl); } - /** * OsType: 操作系统平台,比如CentOS、Ubuntu、Windows、RedHat等,请参考控制台的镜像版本;若导入控制台上没有的操作系统,参数为Other * @@ -129,11 +126,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * OsName: 操作系统详细版本,请参考控制台的镜像版本;OsType为Other时,输入参数为Other * @@ -149,11 +145,10 @@ public function getOsName() * * @param string $osName */ - public function setOsName($osName) + public function setOsName(string $osName) { $this->set("OsName", $osName); } - /** * Format: 镜像格式,可选RAW、VHD、VMDK、qcow2 * @@ -169,11 +164,10 @@ public function getFormat() * * @param string $format */ - public function setFormat($format) + public function setFormat(string $format) { $this->set("Format", $format); } - /** * Auth: 是否授权。必须填true * @@ -189,11 +183,10 @@ public function getAuth() * * @param boolean $auth */ - public function setAuth($auth) + public function setAuth(bool $auth) { $this->set("Auth", $auth); } - /** * ImageDescription: 镜像描述 * @@ -209,7 +202,7 @@ public function getImageDescription() * * @param string $imageDescription */ - public function setImageDescription($imageDescription) + public function setImageDescription(string $imageDescription) { $this->set("ImageDescription", $imageDescription); } diff --git a/src/UHost/Apis/ImportCustomImageResponse.php b/src/UHost/Apis/ImportCustomImageResponse.php index 2d1cdda7..ff667997 100644 --- a/src/UHost/Apis/ImportCustomImageResponse.php +++ b/src/UHost/Apis/ImportCustomImageResponse.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } diff --git a/src/UHost/Apis/ImportUHostKeyPairsRequest.php b/src/UHost/Apis/ImportUHostKeyPairsRequest.php index cf974047..df6b9874 100644 --- a/src/UHost/Apis/ImportUHostKeyPairsRequest.php +++ b/src/UHost/Apis/ImportUHostKeyPairsRequest.php @@ -1,6 +1,7 @@ markRequired("PublicKeyBody"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * KeyPairName: 密钥对名称。由字母,数字,符号组成,长度为1-63位。 * @@ -104,11 +102,10 @@ public function getKeyPairName() * * @param string $keyPairName */ - public function setKeyPairName($keyPairName) + public function setKeyPairName(string $keyPairName) { $this->set("KeyPairName", $keyPairName); } - /** * PublicKeyBody: 密钥对的公钥内容。 * @@ -124,7 +121,7 @@ public function getPublicKeyBody() * * @param string $publicKeyBody */ - public function setPublicKeyBody($publicKeyBody) + public function setPublicKeyBody(string $publicKeyBody) { $this->set("PublicKeyBody", $publicKeyBody); } diff --git a/src/UHost/Apis/ImportUHostKeyPairsResponse.php b/src/UHost/Apis/ImportUHostKeyPairsResponse.php index 7636bc12..81e1324e 100644 --- a/src/UHost/Apis/ImportUHostKeyPairsResponse.php +++ b/src/UHost/Apis/ImportUHostKeyPairsResponse.php @@ -1,6 +1,7 @@ set("KeyPairName", $keyPairName); } - /** * KeyPairId: 密钥对标识 * @@ -57,11 +57,10 @@ public function getKeyPairId() * * @param string $keyPairId */ - public function setKeyPairId($keyPairId) + public function setKeyPairId(string $keyPairId) { $this->set("KeyPairId", $keyPairId); } - /** * KeyPairFingerPrint: 密钥对指纹。根据RFC4716定义的公钥指纹格式,采用MD5信息摘要算法。算法处理的具体信息格式:`ProjectIdKeyPairId|PublicKeyBody`。 * @@ -77,7 +76,7 @@ public function getKeyPairFingerPrint() * * @param string $keyPairFingerPrint */ - public function setKeyPairFingerPrint($keyPairFingerPrint) + public function setKeyPairFingerPrint(string $keyPairFingerPrint) { $this->set("KeyPairFingerPrint", $keyPairFingerPrint); } diff --git a/src/UHost/Apis/LeaveIsolationGroupRequest.php b/src/UHost/Apis/LeaveIsolationGroupRequest.php index 1e8884ef..5285b842 100644 --- a/src/UHost/Apis/LeaveIsolationGroupRequest.php +++ b/src/UHost/Apis/LeaveIsolationGroupRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区信息 * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目id * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 硬件隔离组id * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * UHostId: 主机id * @@ -125,7 +122,7 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/LeaveIsolationGroupResponse.php b/src/UHost/Apis/LeaveIsolationGroupResponse.php index 9e44e8bb..9e11c39c 100644 --- a/src/UHost/Apis/LeaveIsolationGroupResponse.php +++ b/src/UHost/Apis/LeaveIsolationGroupResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ModifyUHostIPRequest.php b/src/UHost/Apis/ModifyUHostIPRequest.php index 8a46a2b6..0d65e0e9 100644 --- a/src/UHost/Apis/ModifyUHostIPRequest.php +++ b/src/UHost/Apis/ModifyUHostIPRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写时为默认项目。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PresentIpAddress: 需要修改为的 IP 地址。新的IP地址和旧IP地址必须属于统一子网,且和主机内部的配置文件一致。 * @@ -106,11 +104,10 @@ public function getPresentIpAddress() * * @param string $presentIpAddress */ - public function setPresentIpAddress($presentIpAddress) + public function setPresentIpAddress(string $presentIpAddress) { $this->set("PresentIpAddress", $presentIpAddress); } - /** * UHostId: 指定云主机 ID。 * @@ -126,11 +123,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * PreviousIpAddress: 所需修改的原 IP 地址 ,当云主机只有一个IP地址时,此参数不必填写。 * @@ -146,7 +142,7 @@ public function getPreviousIpAddress() * * @param string $previousIpAddress */ - public function setPreviousIpAddress($previousIpAddress) + public function setPreviousIpAddress(string $previousIpAddress) { $this->set("PreviousIpAddress", $previousIpAddress); } diff --git a/src/UHost/Apis/ModifyUHostIPResponse.php b/src/UHost/Apis/ModifyUHostIPResponse.php index 7f53aa28..1b9d457d 100644 --- a/src/UHost/Apis/ModifyUHostIPResponse.php +++ b/src/UHost/Apis/ModifyUHostIPResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ModifyUHostInstanceNameRequest.php b/src/UHost/Apis/ModifyUHostInstanceNameRequest.php index 2c35aa84..bcab4e99 100644 --- a/src/UHost/Apis/ModifyUHostInstanceNameRequest.php +++ b/src/UHost/Apis/ModifyUHostInstanceNameRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * Name: UHost实例名称 * @@ -124,7 +121,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UHost/Apis/ModifyUHostInstanceNameResponse.php b/src/UHost/Apis/ModifyUHostInstanceNameResponse.php index 8d1aef25..22494a00 100644 --- a/src/UHost/Apis/ModifyUHostInstanceNameResponse.php +++ b/src/UHost/Apis/ModifyUHostInstanceNameResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ModifyUHostInstanceRemarkRequest.php b/src/UHost/Apis/ModifyUHostInstanceRemarkRequest.php index 9a740f60..87832f41 100644 --- a/src/UHost/Apis/ModifyUHostInstanceRemarkRequest.php +++ b/src/UHost/Apis/ModifyUHostInstanceRemarkRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * Remark: 备注 * @@ -124,7 +121,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UHost/Apis/ModifyUHostInstanceRemarkResponse.php b/src/UHost/Apis/ModifyUHostInstanceRemarkResponse.php index dba409b2..1b1dbcc5 100644 --- a/src/UHost/Apis/ModifyUHostInstanceRemarkResponse.php +++ b/src/UHost/Apis/ModifyUHostInstanceRemarkResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ModifyUHostInstanceTagRequest.php b/src/UHost/Apis/ModifyUHostInstanceTagRequest.php index bad89227..ba5d0df8 100644 --- a/src/UHost/Apis/ModifyUHostInstanceTagRequest.php +++ b/src/UHost/Apis/ModifyUHostInstanceTagRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * Tag: 业务组名称 * @@ -124,7 +121,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/UHost/Apis/ModifyUHostInstanceTagResponse.php b/src/UHost/Apis/ModifyUHostInstanceTagResponse.php index fcccddc0..14253850 100644 --- a/src/UHost/Apis/ModifyUHostInstanceTagResponse.php +++ b/src/UHost/Apis/ModifyUHostInstanceTagResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/PoweroffUHostInstanceRequest.php b/src/UHost/Apis/PoweroffUHostInstanceRequest.php index 82acfcba..6a9ae812 100644 --- a/src/UHost/Apis/PoweroffUHostInstanceRequest.php +++ b/src/UHost/Apis/PoweroffUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](./describe_uhost_instance.html) * @@ -104,7 +102,7 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/PoweroffUHostInstanceResponse.php b/src/UHost/Apis/PoweroffUHostInstanceResponse.php index 4af33d77..d719a257 100644 --- a/src/UHost/Apis/PoweroffUHostInstanceResponse.php +++ b/src/UHost/Apis/PoweroffUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/RebootUHostInstanceRequest.php b/src/UHost/Apis/RebootUHostInstanceRequest.php index b824f696..7399bb68 100644 --- a/src/UHost/Apis/RebootUHostInstanceRequest.php +++ b/src/UHost/Apis/RebootUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * DiskPassword: 加密盘密码 * @@ -124,7 +121,7 @@ public function getDiskPassword() * * @param string $diskPassword */ - public function setDiskPassword($diskPassword) + public function setDiskPassword(string $diskPassword) { $this->set("DiskPassword", $diskPassword); } diff --git a/src/UHost/Apis/RebootUHostInstanceResponse.php b/src/UHost/Apis/RebootUHostInstanceResponse.php index 1c4f9cdc..3556744e 100644 --- a/src/UHost/Apis/RebootUHostInstanceResponse.php +++ b/src/UHost/Apis/RebootUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ReinstallUHostInstanceRequest.php b/src/UHost/Apis/ReinstallUHostInstanceRequest.php index 850756f5..1c0e50fb 100644 --- a/src/UHost/Apis/ReinstallUHostInstanceRequest.php +++ b/src/UHost/Apis/ReinstallUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例资源ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * Password: 如果重装UHost实例时LoginMode为Password,则必须填写,如果LoginMode为KeyPair,不需要填写 (密码格式使用BASE64编码;举例如下:# echo -n Password1 | base64UGFzc3dvcmQx。) * @@ -124,11 +121,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * ImageId: 镜像Id,默认使用原镜像 参见 [DescribeImage](describe_image.html) * @@ -144,11 +140,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * ReserveDisk: 是否保留数据盘,保留:Yes,不报留:No, 默认:Yes;如果是从Windows重装为Linux或反之,则无法保留数据盘(该参数目前仅对本地数据盘起作用) * @@ -164,11 +159,10 @@ public function getReserveDisk() * * @param string $reserveDisk */ - public function setReserveDisk($reserveDisk) + public function setReserveDisk(string $reserveDisk) { $this->set("ReserveDisk", $reserveDisk); } - /** * BootDiskSpace: 系统盘大小。 单位:GB, 范围[20,100], 步长:10 * @@ -184,11 +178,10 @@ public function getBootDiskSpace() * * @param int $bootDiskSpace */ - public function setBootDiskSpace($bootDiskSpace) + public function setBootDiskSpace(int $bootDiskSpace) { $this->set("BootDiskSpace", $bootDiskSpace); } - /** * UserData: cloudinit初始化使用。注意:1、总数据量大小不超多16K 2、使用base64编码 * @@ -204,11 +197,10 @@ public function getUserData() * * @param string $userData */ - public function setUserData($userData) + public function setUserData(string $userData) { $this->set("UserData", $userData); } - /** * AutoDataDiskInit: 数据盘是否需要自动分区挂载。当镜像支持Cloud-init Feature时可填写此字段。取值“On”(默认值), “Off” * @@ -224,11 +216,10 @@ public function getAutoDataDiskInit() * * @param string $autoDataDiskInit */ - public function setAutoDataDiskInit($autoDataDiskInit) + public function setAutoDataDiskInit(string $autoDataDiskInit) { $this->set("AutoDataDiskInit", $autoDataDiskInit); } - /** * LoginMode: 主机登陆模式。密码(默认选项): Password,密钥 KeyPair。 * @@ -244,11 +235,10 @@ public function getLoginMode() * * @param string $loginMode */ - public function setLoginMode($loginMode) + public function setLoginMode(string $loginMode) { $this->set("LoginMode", $loginMode); } - /** * KeyPairId: KeypairId 密钥对ID,LoginMode为KeyPair时此项必须。 * @@ -264,7 +254,7 @@ public function getKeyPairId() * * @param string $keyPairId */ - public function setKeyPairId($keyPairId) + public function setKeyPairId(string $keyPairId) { $this->set("KeyPairId", $keyPairId); } diff --git a/src/UHost/Apis/ReinstallUHostInstanceResponse.php b/src/UHost/Apis/ReinstallUHostInstanceResponse.php index 6aaed447..53cf838a 100644 --- a/src/UHost/Apis/ReinstallUHostInstanceResponse.php +++ b/src/UHost/Apis/ReinstallUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ResetUHostInstancePasswordRequest.php b/src/UHost/Apis/ResetUHostInstancePasswordRequest.php index d9f5be38..814d14e3 100644 --- a/src/UHost/Apis/ResetUHostInstancePasswordRequest.php +++ b/src/UHost/Apis/ResetUHostInstancePasswordRequest.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID * @@ -105,11 +103,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * Password: UHost新密码(密码格式使用BASE64编码) * @@ -125,7 +122,7 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } diff --git a/src/UHost/Apis/ResetUHostInstancePasswordResponse.php b/src/UHost/Apis/ResetUHostInstancePasswordResponse.php index 2eb7ae9a..d67a1fa3 100644 --- a/src/UHost/Apis/ResetUHostInstancePasswordResponse.php +++ b/src/UHost/Apis/ResetUHostInstancePasswordResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/ResizeAttachedDiskRequest.php b/src/UHost/Apis/ResizeAttachedDiskRequest.php index 1966f56e..9d306d95 100644 --- a/src/UHost/Apis/ResizeAttachedDiskRequest.php +++ b/src/UHost/Apis/ResizeAttachedDiskRequest.php @@ -1,6 +1,7 @@ markRequired("DiskId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 * @@ -107,11 +105,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * DiskSpace: 磁盘大小,单位GB,步长为10。取值范围需大于当前磁盘大小,最大值请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -127,11 +124,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * DiskId: 磁盘ID。参见 [DescribeUHostInstance](describe_uhost_instance.html)返回值中的DiskSet。 * @@ -147,11 +143,10 @@ public function getDiskId() * * @param string $diskId */ - public function setDiskId($diskId) + public function setDiskId(string $diskId) { $this->set("DiskId", $diskId); } - /** * DryRun: 用于测试磁盘是否支持在线扩容。DryRun=true,不会执行实际操作,只会返回操作的预期结果。DryRun = false ,正常执行扩容操作。 * @@ -167,7 +162,7 @@ public function getDryRun() * * @param boolean $dryRun */ - public function setDryRun($dryRun) + public function setDryRun(bool $dryRun) { $this->set("DryRun", $dryRun); } diff --git a/src/UHost/Apis/ResizeAttachedDiskResponse.php b/src/UHost/Apis/ResizeAttachedDiskResponse.php index 1e7ec15e..5ec96eb3 100644 --- a/src/UHost/Apis/ResizeAttachedDiskResponse.php +++ b/src/UHost/Apis/ResizeAttachedDiskResponse.php @@ -1,6 +1,7 @@ set("DiskId", $diskId); } - /** * NeedRestart: 扩容后的状态。NeedRestart = true,必须关闭后启动实例才能使用扩容的磁盘空间。NeedRestart = false,磁盘扩容后无需重启操作。 * @@ -57,7 +57,7 @@ public function getNeedRestart() * * @param boolean $needRestart */ - public function setNeedRestart($needRestart) + public function setNeedRestart(bool $needRestart) { $this->set("NeedRestart", $needRestart); } diff --git a/src/UHost/Apis/ResizeUHostInstanceRequest.php b/src/UHost/Apis/ResizeUHostInstanceRequest.php index d122bf92..9abeb66e 100644 --- a/src/UHost/Apis/ResizeUHostInstanceRequest.php +++ b/src/UHost/Apis/ResizeUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * CPU: 虚拟CPU核数。可选参数:1-240(可选范围与UHostType相关)。默认值为当前实例的CPU核数 * @@ -124,11 +121,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小。单位:MB。范围 :[1024, 1966080],取值为1024的倍数(可选范围与UHostType相关)。默认值为当前实例的内存大小。 * @@ -144,11 +140,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * NetCapValue: 网卡升降级(1,表示升级,2表示降级,0表示不变) * @@ -164,7 +159,7 @@ public function getNetCapValue() * * @param int $netCapValue */ - public function setNetCapValue($netCapValue) + public function setNetCapValue(int $netCapValue) { $this->set("NetCapValue", $netCapValue); } diff --git a/src/UHost/Apis/ResizeUHostInstanceResponse.php b/src/UHost/Apis/ResizeUHostInstanceResponse.php index d1cf3bfb..96b48e8e 100644 --- a/src/UHost/Apis/ResizeUHostInstanceResponse.php +++ b/src/UHost/Apis/ResizeUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/StartUHostInstanceRequest.php b/src/UHost/Apis/StartUHostInstanceRequest.php index 4664f6c8..6fd4b7ac 100644 --- a/src/UHost/Apis/StartUHostInstanceRequest.php +++ b/src/UHost/Apis/StartUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * DiskPassword: 加密盘密码 * @@ -124,7 +121,7 @@ public function getDiskPassword() * * @param string $diskPassword */ - public function setDiskPassword($diskPassword) + public function setDiskPassword(string $diskPassword) { $this->set("DiskPassword", $diskPassword); } diff --git a/src/UHost/Apis/StartUHostInstanceResponse.php b/src/UHost/Apis/StartUHostInstanceResponse.php index 903c3ef9..314ae2c3 100644 --- a/src/UHost/Apis/StartUHostInstanceResponse.php +++ b/src/UHost/Apis/StartUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/StopUHostInstanceRequest.php b/src/UHost/Apis/StopUHostInstanceRequest.php index 1053b5cd..48eb7bb8 100644 --- a/src/UHost/Apis/StopUHostInstanceRequest.php +++ b/src/UHost/Apis/StopUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,7 +102,7 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/StopUHostInstanceResponse.php b/src/UHost/Apis/StopUHostInstanceResponse.php index 60bca90f..377aaf4a 100644 --- a/src/UHost/Apis/StopUHostInstanceResponse.php +++ b/src/UHost/Apis/StopUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/TerminateCustomImageRequest.php b/src/UHost/Apis/TerminateCustomImageRequest.php index 5dd83dc6..77c5a8a4 100644 --- a/src/UHost/Apis/TerminateCustomImageRequest.php +++ b/src/UHost/Apis/TerminateCustomImageRequest.php @@ -1,6 +1,7 @@ markRequired("ImageId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageId: 自制镜像ID 参见 [DescribeImage](describe_image.html) * @@ -84,7 +83,7 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } diff --git a/src/UHost/Apis/TerminateCustomImageResponse.php b/src/UHost/Apis/TerminateCustomImageResponse.php index 33c192c3..7e2d3efa 100644 --- a/src/UHost/Apis/TerminateCustomImageResponse.php +++ b/src/UHost/Apis/TerminateCustomImageResponse.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } diff --git a/src/UHost/Apis/TerminateUHostInstanceRequest.php b/src/UHost/Apis/TerminateUHostInstanceRequest.php index 8ee59e08..d9b62121 100644 --- a/src/UHost/Apis/TerminateUHostInstanceRequest.php +++ b/src/UHost/Apis/TerminateUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * UHostId: UHost资源Id 参见 [DescribeUHostInstance](describe_uhost_instance.html) * @@ -104,11 +102,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * ReleaseEIP: 删除主机时是否释放绑定的EIP。默认为false。 * @@ -124,11 +121,10 @@ public function getReleaseEIP() * * @param boolean $releaseEIP */ - public function setReleaseEIP($releaseEIP) + public function setReleaseEIP(bool $releaseEIP) { $this->set("ReleaseEIP", $releaseEIP); } - /** * ReleaseUDisk: 删除主机时是否同时删除挂载的数据盘。默认为false。 * @@ -144,7 +140,7 @@ public function getReleaseUDisk() * * @param boolean $releaseUDisk */ - public function setReleaseUDisk($releaseUDisk) + public function setReleaseUDisk(bool $releaseUDisk) { $this->set("ReleaseUDisk", $releaseUDisk); } diff --git a/src/UHost/Apis/TerminateUHostInstanceResponse.php b/src/UHost/Apis/TerminateUHostInstanceResponse.php index 28f6f014..0555939a 100644 --- a/src/UHost/Apis/TerminateUHostInstanceResponse.php +++ b/src/UHost/Apis/TerminateUHostInstanceResponse.php @@ -1,6 +1,7 @@ set("InRecycle", $inRecycle); } - /** * UHostId: UHost 实例 Id * @@ -57,7 +57,7 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } diff --git a/src/UHost/Apis/UpgradeToArkUHostInstanceRequest.php b/src/UHost/Apis/UpgradeToArkUHostInstanceRequest.php index 49bcf7d3..f0e2f64d 100644 --- a/src/UHost/Apis/UpgradeToArkUHostInstanceRequest.php +++ b/src/UHost/Apis/UpgradeToArkUHostInstanceRequest.php @@ -1,6 +1,7 @@ markRequired("UHostIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * UHostIds: UHost主机的资源ID,例如UHostIds.0代表希望升级的主机1,UHostIds.1代表主机2。 * @@ -89,7 +88,6 @@ public function setUHostIds(array $uHostIds) { $this->set("UHostIds", $uHostIds); } - /** * CouponId: 代金券ID 请参考DescribeCoupon接口 * @@ -105,7 +103,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UHost/Apis/UpgradeToArkUHostInstanceResponse.php b/src/UHost/Apis/UpgradeToArkUHostInstanceResponse.php index 509949ca..bc355112 100644 --- a/src/UHost/Apis/UpgradeToArkUHostInstanceResponse.php +++ b/src/UHost/Apis/UpgradeToArkUHostInstanceResponse.php @@ -1,6 +1,7 @@ True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 @@ -37,11 +40,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * Type: 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -57,11 +59,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Size: 磁盘大小,单位GB,必须是10GB的整数倍。请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -77,13 +78,12 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** - * BackupType: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT(SNAPSHOT模式目前仅在上海C支持),快照 \\当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]],默认值:NONE + * BackupType: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT,快照 \\当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]],默认值:NONE * * @return string|null */ @@ -93,15 +93,14 @@ public function getBackupType() } /** - * BackupType: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT(SNAPSHOT模式目前仅在上海C支持),快照 \\当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]],默认值:NONE + * BackupType: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT,快照 \\当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]],默认值:NONE * * @param string $backupType */ - public function setBackupType($backupType) + public function setBackupType(string $backupType) { $this->set("BackupType", $backupType); } - /** * Encrypted: 【功能仅部分可用区开放,详询技术支持】磁盘是否加密。加密:true, 不加密: false加密必须传入对应的的KmsKeyId,默认值false * @@ -117,11 +116,10 @@ public function getEncrypted() * * @param boolean $encrypted */ - public function setEncrypted($encrypted) + public function setEncrypted(bool $encrypted) { $this->set("Encrypted", $encrypted); } - /** * KmsKeyId: 【功能仅部分可用区开放,详询技术支持】kms key id。选择加密盘时必填。 * @@ -137,11 +135,10 @@ public function getKmsKeyId() * * @param string $kmsKeyId */ - public function setKmsKeyId($kmsKeyId) + public function setKmsKeyId(string $kmsKeyId) { $this->set("KmsKeyId", $kmsKeyId); } - /** * CouponId: 云盘代金券id。不适用于系统盘/本地盘。请通过DescribeCoupon接口查询,或登录用户中心查看 * @@ -157,7 +154,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UHost/Params/CreateUHostInstanceParamFeatures.php b/src/UHost/Models/CreateUHostInstanceRequestFeatures.php similarity index 81% rename from src/UHost/Params/CreateUHostInstanceParamFeatures.php rename to src/UHost/Models/CreateUHostInstanceRequestFeatures.php index d8fac1c4..c8189542 100644 --- a/src/UHost/Params/CreateUHostInstanceParamFeatures.php +++ b/src/UHost/Models/CreateUHostInstanceRequestFeatures.php @@ -1,6 +1,7 @@ set("UNI", $uni); } diff --git a/src/UHost/Params/CreateUHostInstanceParamNetworkInterface.php b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterface.php similarity index 58% rename from src/UHost/Params/CreateUHostInstanceParamNetworkInterface.php rename to src/UHost/Models/CreateUHostInstanceRequestNetworkInterface.php index df692b0c..6d2909f3 100644 --- a/src/UHost/Params/CreateUHostInstanceParamNetworkInterface.php +++ b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterface.php @@ -1,6 +1,7 @@ get("EIP")); + return new CreateUHostInstanceRequestNetworkInterfaceEIPModel($this->get("EIP")); } /** * EIP: * - * @param CreateUHostInstanceParamNetworkInterfaceEIP $eip + * @param CreateUHostInstanceRequestNetworkInterfaceEIPModel $eip */ - public function setEIP(array $eip) + public function setEIP(CreateUHostInstanceRequestNetworkInterfaceEIPModel $eip) { $this->set("EIP", $eip->getAll()); } - /** * IPv6: * - * @return CreateUHostInstanceParamNetworkInterfaceIPv6|null + * @return CreateUHostInstanceRequestNetworkInterfaceIPv6Model|null */ public function getIPv6() { - return new CreateUHostInstanceParamNetworkInterfaceIPv6($this->get("IPv6")); + return new CreateUHostInstanceRequestNetworkInterfaceIPv6Model($this->get("IPv6")); } /** * IPv6: * - * @param CreateUHostInstanceParamNetworkInterfaceIPv6 $iPv6 + * @param CreateUHostInstanceRequestNetworkInterfaceIPv6Model $iPv6 */ - public function setIPv6(array $iPv6) + public function setIPv6(CreateUHostInstanceRequestNetworkInterfaceIPv6Model $iPv6) { $this->set("IPv6", $iPv6->getAll()); } - /** * CreateCernetIp: 申请并绑定一个教育网EIP。True为申请并绑定,False为不会申请绑定,默认False。当前只支持具有HPC特性的机型。 * @@ -77,7 +80,7 @@ public function getCreateCernetIp() * * @param boolean $createCernetIp */ - public function setCreateCernetIp($createCernetIp) + public function setCreateCernetIp(bool $createCernetIp) { $this->set("CreateCernetIp", $createCernetIp); } diff --git a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIP.php b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceEIP.php similarity index 81% rename from src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIP.php rename to src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceEIP.php index 3378bb7b..cf115764 100644 --- a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIP.php +++ b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceEIP.php @@ -1,6 +1,7 @@ set("Bandwidth", $bandwidth); } - /** * PayMode: 弹性IP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; "ShareBandwidth",共享带宽模式. "Free":免费带宽模式,默认为 "Bandwidth" * @@ -57,11 +60,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * ShareBandwidthId: 绑定的共享带宽Id,仅当PayMode为ShareBandwidth时有效 * @@ -77,31 +79,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - - /** - * GlobalSSH: - * - * @return CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH|null - */ - public function getGlobalSSH() - { - return new CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH($this->get("GlobalSSH")); - } - - /** - * GlobalSSH: - * - * @param CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH $globalSSH - */ - public function setGlobalSSH(array $globalSSH) - { - $this->set("GlobalSSH", $globalSSH->getAll()); - } - /** * OperatorName: 【若绑定EIP,此参数必填】弹性IP的线路。枚举值: 国际: International BGP: Bgp 各地域允许的线路参数如下: cn-sh1: Bgp cn-sh2: Bgp cn-gd: Bgp cn-bj1: Bgp cn-bj2: Bgp hk: International us-ca: International th-bkk: International kr-seoul:International us-ws:International ge-fra:International sg:International tw-kh:International.其他海外线路均为 International * @@ -117,11 +98,10 @@ public function getOperatorName() * * @param string $operatorName */ - public function setOperatorName($operatorName) + public function setOperatorName(string $operatorName) { $this->set("OperatorName", $operatorName); } - /** * CouponId: 当前EIP代金券id。请通过DescribeCoupon接口查询,或登录用户中心查看。 * @@ -137,7 +117,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceIPv6.php b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceIPv6.php new file mode 100644 index 00000000..adc3407e --- /dev/null +++ b/src/UHost/Models/CreateUHostInstanceRequestNetworkInterfaceIPv6.php @@ -0,0 +1,29 @@ + True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 @@ -37,11 +40,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * Size: 磁盘大小,单位GB。请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -57,11 +59,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Type: 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。 * @@ -77,11 +78,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * BackupType: 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT,快照\\ 当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]] * @@ -97,7 +97,7 @@ public function getBackupType() * * @param string $backupType */ - public function setBackupType($backupType) + public function setBackupType(string $backupType) { $this->set("BackupType", $backupType); } diff --git a/src/UHost/Models/GetUHostInstancePriceRequestVirtualGpu.php b/src/UHost/Models/GetUHostInstancePriceRequestVirtualGpu.php new file mode 100644 index 00000000..d08d3a69 --- /dev/null +++ b/src/UHost/Models/GetUHostInstancePriceRequestVirtualGpu.php @@ -0,0 +1,28 @@ +set("GroupName", $groupName); } - /** * GroupId: 硬件隔离组id * @@ -57,15 +60,14 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * SpreadInfoSet: 每个可用区中的机器数量。参见数据结构SpreadInfo。 * - * @return SpreadInfo[]|null + * @return SpreadInfoModel[]|null */ public function getSpreadInfoSet() { @@ -75,7 +77,7 @@ public function getSpreadInfoSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SpreadInfo($item)); + array_push($result, new SpreadInfoModel($item)); } return $result; } @@ -83,7 +85,7 @@ public function getSpreadInfoSet() /** * SpreadInfoSet: 每个可用区中的机器数量。参见数据结构SpreadInfo。 * - * @param SpreadInfo[] $spreadInfoSet + * @param SpreadInfoModel[] $spreadInfoSet */ public function setSpreadInfoSet(array $spreadInfoSet) { @@ -93,7 +95,6 @@ public function setSpreadInfoSet(array $spreadInfoSet) } return $result; } - /** * Remark: 备注 * @@ -109,7 +110,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UHost/Models/KeyPair.php b/src/UHost/Models/KeyPair.php index 0c568bd8..8605e19f 100644 --- a/src/UHost/Models/KeyPair.php +++ b/src/UHost/Models/KeyPair.php @@ -1,6 +1,7 @@ set("ProjectId", $projectId); } - /** * KeyPairId: 密钥对ID。 * @@ -57,11 +59,10 @@ public function getKeyPairId() * * @param string $keyPairId */ - public function setKeyPairId($keyPairId) + public function setKeyPairId(string $keyPairId) { $this->set("KeyPairId", $keyPairId); } - /** * KeyPairName: 密钥对名称。 长度为1~63个英文或中文字符。 * @@ -77,11 +78,10 @@ public function getKeyPairName() * * @param string $keyPairName */ - public function setKeyPairName($keyPairName) + public function setKeyPairName(string $keyPairName) { $this->set("KeyPairName", $keyPairName); } - /** * KeyPairFingerPrint: 密钥对指纹。md5(ProjectId|KeyPairId|PublicKey) * @@ -97,11 +97,10 @@ public function getKeyPairFingerPrint() * * @param string $keyPairFingerPrint */ - public function setKeyPairFingerPrint($keyPairFingerPrint) + public function setKeyPairFingerPrint(string $keyPairFingerPrint) { $this->set("KeyPairFingerPrint", $keyPairFingerPrint); } - /** * PrivateKeyBody: 密钥对的私钥内容。只有创建接口才会返回。 * @@ -117,11 +116,10 @@ public function getPrivateKeyBody() * * @param string $privateKeyBody */ - public function setPrivateKeyBody($privateKeyBody) + public function setPrivateKeyBody(string $privateKeyBody) { $this->set("PrivateKeyBody", $privateKeyBody); } - /** * CreateTime: 密钥对的创建时间,格式为Unix Timestamp。 * @@ -137,7 +135,7 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } diff --git a/src/UHost/Models/KeyPairDesc.php b/src/UHost/Models/KeyPairDesc.php index 42b3b725..a9e58ded 100644 --- a/src/UHost/Models/KeyPairDesc.php +++ b/src/UHost/Models/KeyPairDesc.php @@ -1,6 +1,7 @@ set("ProjectId", $projectId); } - /** * KeyPairId: 密钥对ID。 * @@ -57,11 +59,10 @@ public function getKeyPairId() * * @param string $keyPairId */ - public function setKeyPairId($keyPairId) + public function setKeyPairId(string $keyPairId) { $this->set("KeyPairId", $keyPairId); } - /** * KeyPairName: 密钥对名称。 长度为1~63个英文或中文字符。 * @@ -77,11 +78,10 @@ public function getKeyPairName() * * @param string $keyPairName */ - public function setKeyPairName($keyPairName) + public function setKeyPairName(string $keyPairName) { $this->set("KeyPairName", $keyPairName); } - /** * KeyPairFingerPrint: 密钥对指纹。md5(ProjectId|KeyPairId|PublicKey) * @@ -97,11 +97,10 @@ public function getKeyPairFingerPrint() * * @param string $keyPairFingerPrint */ - public function setKeyPairFingerPrint($keyPairFingerPrint) + public function setKeyPairFingerPrint(string $keyPairFingerPrint) { $this->set("KeyPairFingerPrint", $keyPairFingerPrint); } - /** * CreateTime: 密钥对的创建时间,格式为Unix Timestamp。 * @@ -117,7 +116,7 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } diff --git a/src/UHost/Models/SpreadInfo.php b/src/UHost/Models/SpreadInfo.php index 8b5d37bf..c09a817c 100644 --- a/src/UHost/Models/SpreadInfo.php +++ b/src/UHost/Models/SpreadInfo.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * UHostCount: 当前地域所有可用区中硬件隔离组中云主机的数量,不超过7。 * @@ -57,7 +60,7 @@ public function getUHostCount() * * @param int $uHostCount */ - public function setUHostCount($uHostCount) + public function setUHostCount(int $uHostCount) { $this->set("UHostCount", $uHostCount); } diff --git a/src/UHost/Models/UHostDiskSet.php b/src/UHost/Models/UHostDiskSet.php index 94b304a0..08d3998e 100644 --- a/src/UHost/Models/UHostDiskSet.php +++ b/src/UHost/Models/UHostDiskSet.php @@ -1,6 +1,7 @@ set("DiskType", $diskType); } - /** * IsBoot: 是否是系统盘。枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 * @@ -57,11 +63,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * Encrypted: "true": 加密盘 "false":非加密盘 * @@ -77,11 +82,10 @@ public function getEncrypted() * * @param string $encrypted */ - public function setEncrypted($encrypted) + public function setEncrypted(string $encrypted) { $this->set("Encrypted", $encrypted); } - /** * Type: 【建议不再使用】磁盘类型。系统盘: Boot,数据盘: Data,网络盘:Udisk * @@ -97,11 +101,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * DiskId: 磁盘ID * @@ -117,11 +120,10 @@ public function getDiskId() * * @param string $diskId */ - public function setDiskId($diskId) + public function setDiskId(string $diskId) { $this->set("DiskId", $diskId); } - /** * Name: UDisk名字(仅当磁盘是UDisk时返回) * @@ -137,11 +139,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Drive: 磁盘盘符 * @@ -157,11 +158,10 @@ public function getDrive() * * @param string $drive */ - public function setDrive($drive) + public function setDrive(string $drive) { $this->set("Drive", $drive); } - /** * Size: 磁盘大小,单位: GB * @@ -177,11 +177,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * BackupType: 备份方案。若开通了数据方舟,则为DATAARK * @@ -197,7 +196,7 @@ public function getBackupType() * * @param string $backupType */ - public function setBackupType($backupType) + public function setBackupType(string $backupType) { $this->set("BackupType", $backupType); } diff --git a/src/UHost/Models/UHostIPSet.php b/src/UHost/Models/UHostIPSet.php index 1035f2b5..15049074 100644 --- a/src/UHost/Models/UHostIPSet.php +++ b/src/UHost/Models/UHostIPSet.php @@ -1,6 +1,7 @@ set("IPMode", $ipMode); } - /** * Default: 内网 Private 类型下,表示是否为默认网卡。true: 是默认网卡;其他值:不是。 * @@ -57,11 +63,10 @@ public function getDefault() * * @param string $default */ - public function setDefault($default) + public function setDefault(string $default) { $this->set("Default", $default); } - /** * Mac: 内网 Private 类型下,当前网卡的Mac。 * @@ -77,11 +82,10 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } - /** * Weight: 当前EIP的权重。权重最大的为当前的出口IP。 * @@ -97,11 +101,10 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } - /** * Type: 国际: Internation,BGP: Bgp,内网: Private * @@ -117,11 +120,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * IPId: 外网IP资源ID 。(内网IP无对应的资源ID) * @@ -137,11 +139,10 @@ public function getIPId() * * @param string $ipId */ - public function setIPId($ipId) + public function setIPId(string $ipId) { $this->set("IPId", $ipId); } - /** * IP: IP地址 * @@ -157,11 +158,10 @@ public function getIP() * * @param string $ip */ - public function setIP($ip) + public function setIP(string $ip) { $this->set("IP", $ip); } - /** * Bandwidth: IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) * @@ -177,11 +177,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * VPCId: IP地址对应的VPC ID。(北京一不支持,字段返回为空) * @@ -197,11 +196,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: IP地址对应的子网 ID。(北京一不支持,字段返回为空) * @@ -217,11 +215,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * NetworkInterfaceId: 弹性网卡为默认网卡时,返回对应的 ID 值 * @@ -237,7 +234,7 @@ public function getNetworkInterfaceId() * * @param string $networkInterfaceId */ - public function setNetworkInterfaceId($networkInterfaceId) + public function setNetworkInterfaceId(string $networkInterfaceId) { $this->set("NetworkInterfaceId", $networkInterfaceId); } diff --git a/src/UHost/Models/UHostImageSet.php b/src/UHost/Models/UHostImageSet.php index 237277f2..38709774 100644 --- a/src/UHost/Models/UHostImageSet.php +++ b/src/UHost/Models/UHostImageSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * ImageId: 镜像ID * @@ -57,11 +60,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * ImageName: 镜像名称 * @@ -77,11 +79,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * OsType: 操作系统类型:Linux,Windows * @@ -97,11 +98,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * OsName: 操作系统名称 * @@ -117,11 +117,10 @@ public function getOsName() * * @param string $osName */ - public function setOsName($osName) + public function setOsName(string $osName) { $this->set("OsName", $osName); } - /** * ImageType: 镜像类型 标准镜像:Base, 行业镜像:Business,自定义镜像:Custom * @@ -137,11 +136,10 @@ public function getImageType() * * @param string $imageType */ - public function setImageType($imageType) + public function setImageType(string $imageType) { $this->set("ImageType", $imageType); } - /** * Features: 特殊状态标识, 目前包含NetEnhnced(网络增强1.0), NetEnhanced_Ultra](网络增强2.0), HotPlug(热升级), CloudInit, IPv6 * @@ -161,7 +159,6 @@ public function setFeatures(array $features) { $this->set("Features", $features); } - /** * FuncType: 行业镜像类型(仅行业镜像将返回这个值) * @@ -177,11 +174,10 @@ public function getFuncType() * * @param string $funcType */ - public function setFuncType($funcType) + public function setFuncType(string $funcType) { $this->set("FuncType", $funcType); } - /** * IntegratedSoftware: 集成软件名称(仅行业镜像将返回这个值) * @@ -197,11 +193,10 @@ public function getIntegratedSoftware() * * @param string $integratedSoftware */ - public function setIntegratedSoftware($integratedSoftware) + public function setIntegratedSoftware(string $integratedSoftware) { $this->set("IntegratedSoftware", $integratedSoftware); } - /** * Vendor: 供应商(仅行业镜像将返回这个值) * @@ -217,11 +212,10 @@ public function getVendor() * * @param string $vendor */ - public function setVendor($vendor) + public function setVendor(string $vendor) { $this->set("Vendor", $vendor); } - /** * Links: 介绍链接(仅行业镜像将返回这个值) * @@ -237,11 +231,10 @@ public function getLinks() * * @param string $links */ - public function setLinks($links) + public function setLinks(string $links) { $this->set("Links", $links); } - /** * State: 镜像状态, 可用:Available,制作中:Making, 不可用:Unavailable * @@ -257,11 +250,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * ImageDescription: 镜像描述 * @@ -277,11 +269,10 @@ public function getImageDescription() * * @param string $imageDescription */ - public function setImageDescription($imageDescription) + public function setImageDescription(string $imageDescription) { $this->set("ImageDescription", $imageDescription); } - /** * CreateTime: 创建时间,格式为Unix时间戳 * @@ -297,11 +288,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ImageSize: 镜像大小 * @@ -317,11 +307,10 @@ public function getImageSize() * * @param int $imageSize */ - public function setImageSize($imageSize) + public function setImageSize(int $imageSize) { $this->set("ImageSize", $imageSize); } - /** * MinimalCPU: 默认值为空'''。当CentOS 7.3/7.4/7.5等镜像会标记为“Broadwell” * @@ -337,7 +326,7 @@ public function getMinimalCPU() * * @param string $minimalCPU */ - public function setMinimalCPU($minimalCPU) + public function setMinimalCPU(string $minimalCPU) { $this->set("MinimalCPU", $minimalCPU); } diff --git a/src/UHost/Models/UHostInstanceSet.php b/src/UHost/Models/UHostInstanceSet.php index 781e21a6..e4904674 100644 --- a/src/UHost/Models/UHostInstanceSet.php +++ b/src/UHost/Models/UHostInstanceSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * IPv6Feature: true:有ipv6特性;false,没有ipv6特性 * @@ -57,11 +63,10 @@ public function getIPv6Feature() * * @param boolean $iPv6Feature */ - public function setIPv6Feature($iPv6Feature) + public function setIPv6Feature(bool $iPv6Feature) { $this->set("IPv6Feature", $iPv6Feature); } - /** * UHostId: UHost实例ID * @@ -77,11 +82,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * UHostType: 【建议不再使用】云主机机型(旧)。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -97,11 +101,10 @@ public function getUHostType() * * @param string $uHostType */ - public function setUHostType($uHostType) + public function setUHostType(string $uHostType) { $this->set("UHostType", $uHostType); } - /** * MachineType: 云主机机型(新)。参考[[api:uhost-api:uhost_type#主机概念20版本|云主机机型说明]]。 * @@ -117,11 +120,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * CpuPlatform: 云主机CPU平台。参考[[api:uhost-api:uhost_type#主机概念20版本|云主机机型说明]]。 * @@ -137,11 +139,10 @@ public function getCpuPlatform() * * @param string $cpuPlatform */ - public function setCpuPlatform($cpuPlatform) + public function setCpuPlatform(string $cpuPlatform) { $this->set("CpuPlatform", $cpuPlatform); } - /** * StorageType: 【建议不再使用】主机磁盘类型。 枚举值为:\\ > LocalDisk,本地磁盘; \\ > UDisk 云盘。\\只要有一块磁盘为本地盘,即返回LocalDisk。 * @@ -157,11 +158,10 @@ public function getStorageType() * * @param string $storageType */ - public function setStorageType($storageType) + public function setStorageType(string $storageType) { $this->set("StorageType", $storageType); } - /** * ImageId: 【建议不再使用】主机的系统盘ID。 * @@ -177,11 +177,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * BasicImageId: 基础镜像ID(指当前自定义镜像的来源镜像) * @@ -197,11 +196,10 @@ public function getBasicImageId() * * @param string $basicImageId */ - public function setBasicImageId($basicImageId) + public function setBasicImageId(string $basicImageId) { $this->set("BasicImageId", $basicImageId); } - /** * BasicImageName: 基础镜像名称(指当前自定义镜像的来源镜像) * @@ -217,11 +215,10 @@ public function getBasicImageName() * * @param string $basicImageName */ - public function setBasicImageName($basicImageName) + public function setBasicImageName(string $basicImageName) { $this->set("BasicImageName", $basicImageName); } - /** * Tag: 业务组名称 * @@ -237,11 +234,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -257,11 +253,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Name: UHost实例名称 * @@ -277,11 +272,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * State: 实例状态,枚举值:\\ >初始化: Initializing; \\ >启动中: Starting; \\> 运行中: Running; \\> 关机中: Stopping; \\ >关机: Stopped \\ >安装失败: Install Fail; \\ >重启中: Rebooting; \\ > 未知(空字符串,获取状态超时或出错):"" * @@ -297,11 +291,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: 创建时间,格式为Unix时间戳 * @@ -317,11 +310,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ChargeType: 计费模式,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费(需开启权限);Preemptive 为抢占式实例; * @@ -337,11 +329,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ExpireTime: 到期时间,格式为Unix时间戳 * @@ -357,11 +348,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * CPU: 虚拟CPU核数,单位: 个 * @@ -377,11 +367,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小,单位: MB * @@ -397,11 +386,10 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * AutoRenew: 是否自动续费,自动续费:“Yes”,不自动续费:“No” * @@ -417,15 +405,14 @@ public function getAutoRenew() * * @param string $autoRenew */ - public function setAutoRenew($autoRenew) + public function setAutoRenew(string $autoRenew) { $this->set("AutoRenew", $autoRenew); } - /** * DiskSet: 磁盘信息见 UHostDiskSet * - * @return UHostDiskSet[]|null + * @return UHostDiskSetModel[]|null */ public function getDiskSet() { @@ -435,7 +422,7 @@ public function getDiskSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostDiskSet($item)); + array_push($result, new UHostDiskSetModel($item)); } return $result; } @@ -443,7 +430,7 @@ public function getDiskSet() /** * DiskSet: 磁盘信息见 UHostDiskSet * - * @param UHostDiskSet[] $diskSet + * @param UHostDiskSetModel[] $diskSet */ public function setDiskSet(array $diskSet) { @@ -453,11 +440,10 @@ public function setDiskSet(array $diskSet) } return $result; } - /** * IPSet: 详细信息见 UHostIPSet * - * @return UHostIPSet[]|null + * @return UHostIPSetModel[]|null */ public function getIPSet() { @@ -467,7 +453,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostIPSet($item)); + array_push($result, new UHostIPSetModel($item)); } return $result; } @@ -475,7 +461,7 @@ public function getIPSet() /** * IPSet: 详细信息见 UHostIPSet * - * @param UHostIPSet[] $ipSet + * @param UHostIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -485,7 +471,6 @@ public function setIPSet(array $ipSet) } return $result; } - /** * NetCapability: 网络增强。Normal: 无;Super: 网络增强1.0; Ultra: 网络增强2.0 * @@ -501,11 +486,10 @@ public function getNetCapability() * * @param string $netCapability */ - public function setNetCapability($netCapability) + public function setNetCapability(string $netCapability) { $this->set("NetCapability", $netCapability); } - /** * NetworkState: 【建议不再使用】网络状态。 连接:Connected, 断开:NotConnected * @@ -521,11 +505,10 @@ public function getNetworkState() * * @param string $networkState */ - public function setNetworkState($networkState) + public function setNetworkState(string $networkState) { $this->set("NetworkState", $networkState); } - /** * TimemachineFeature: 【建议不再使用】数据方舟模式。枚举值:\\ > Yes: 开启方舟; \\ > no,未开启方舟 * @@ -541,11 +524,10 @@ public function getTimemachineFeature() * * @param string $timemachineFeature */ - public function setTimemachineFeature($timemachineFeature) + public function setTimemachineFeature(string $timemachineFeature) { $this->set("TimemachineFeature", $timemachineFeature); } - /** * HotplugFeature: true: 开启热升级; false,未开启热升级 * @@ -561,11 +543,10 @@ public function getHotplugFeature() * * @param boolean $hotplugFeature */ - public function setHotplugFeature($hotplugFeature) + public function setHotplugFeature(bool $hotplugFeature) { $this->set("HotplugFeature", $hotplugFeature); } - /** * SubnetType: 【建议不再使用】仅北京A的云主机会返回此字段。基础网络模式:Default;子网模式:Private * @@ -581,11 +562,10 @@ public function getSubnetType() * * @param string $subnetType */ - public function setSubnetType($subnetType) + public function setSubnetType(string $subnetType) { $this->set("SubnetType", $subnetType); } - /** * OsName: 创建主机的最初来源镜像的操作系统名称(若直接通过基础镜像创建,此处返回和BasicImageName一致) * @@ -601,11 +581,10 @@ public function getOsName() * * @param string $osName */ - public function setOsName($osName) + public function setOsName(string $osName) { $this->set("OsName", $osName); } - /** * OsType: 操作系统类别。返回"Linux"或者"Windows" * @@ -621,11 +600,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * HostType: 【建议不再使用】主机系列:N2,表示系列2;N1,表示系列1 * @@ -641,11 +619,10 @@ public function getHostType() * * @param string $hostType */ - public function setHostType($hostType) + public function setHostType(string $hostType) { $this->set("HostType", $hostType); } - /** * LifeCycle: 主机的生命周期类型。目前仅支持Normal:普通; * @@ -661,11 +638,10 @@ public function getLifeCycle() * * @param string $lifeCycle */ - public function setLifeCycle($lifeCycle) + public function setLifeCycle(string $lifeCycle) { $this->set("LifeCycle", $lifeCycle); } - /** * GPU: GPU个数 * @@ -681,11 +657,10 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } - /** * BootDiskState: 系统盘状态 Normal表示初始化完成;Initializing表示在初始化。仍在初始化的系统盘无法制作镜像。 * @@ -701,11 +676,10 @@ public function getBootDiskState() * * @param string $bootDiskState */ - public function setBootDiskState($bootDiskState) + public function setBootDiskState(string $bootDiskState) { $this->set("BootDiskState", $bootDiskState); } - /** * TotalDiskSpace: 总的数据盘存储空间。 * @@ -721,11 +695,10 @@ public function getTotalDiskSpace() * * @param int $totalDiskSpace */ - public function setTotalDiskSpace($totalDiskSpace) + public function setTotalDiskSpace(int $totalDiskSpace) { $this->set("TotalDiskSpace", $totalDiskSpace); } - /** * IsolationGroup: 隔离组id,不在隔离组则返回"" * @@ -741,11 +714,10 @@ public function getIsolationGroup() * * @param string $isolationGroup */ - public function setIsolationGroup($isolationGroup) + public function setIsolationGroup(string $isolationGroup) { $this->set("IsolationGroup", $isolationGroup); } - /** * CloudInitFeature: true,支持cloutinit方式初始化;false,不支持 * @@ -761,11 +733,10 @@ public function getCloudInitFeature() * * @param boolean $cloudInitFeature */ - public function setCloudInitFeature($cloudInitFeature) + public function setCloudInitFeature(bool $cloudInitFeature) { $this->set("CloudInitFeature", $cloudInitFeature); } - /** * RdmaClusterId: RDMA集群id,仅快杰云主机返回该值;其他类型云主机返回""。当云主机的此值与RSSD云盘的RdmaClusterId相同时,RSSD可以挂载到这台云主机。 * @@ -781,11 +752,10 @@ public function getRdmaClusterId() * * @param string $rdmaClusterId */ - public function setRdmaClusterId($rdmaClusterId) + public function setRdmaClusterId(string $rdmaClusterId) { $this->set("RdmaClusterId", $rdmaClusterId); } - /** * RestrictMode: 仅抢占式实例返回,LowSpeed为低速模式,PowerOff为关机模式 * @@ -801,11 +771,10 @@ public function getRestrictMode() * * @param string $restrictMode */ - public function setRestrictMode($restrictMode) + public function setRestrictMode(string $restrictMode) { $this->set("RestrictMode", $restrictMode); } - /** * HpcFeature: true: 开启 hpc 系列功能;false: 未开启 * @@ -821,27 +790,26 @@ public function getHpcFeature() * * @param boolean $hpcFeature */ - public function setHpcFeature($hpcFeature) + public function setHpcFeature(bool $hpcFeature) { $this->set("HpcFeature", $hpcFeature); } - /** * KeyPair: 密钥信息见 UHostKeyPair * - * @return UHostKeyPair|null + * @return UHostKeyPairModel|null */ public function getKeyPair() { - return new UHostKeyPair($this->get("KeyPair")); + return new UHostKeyPairModel($this->get("KeyPair")); } /** * KeyPair: 密钥信息见 UHostKeyPair * - * @param UHostKeyPair $keyPair + * @param UHostKeyPairModel $keyPair */ - public function setKeyPair(array $keyPair) + public function setKeyPair(UHostKeyPairModel $keyPair) { $this->set("KeyPair", $keyPair->getAll()); } diff --git a/src/UHost/Models/UHostKeyPair.php b/src/UHost/Models/UHostKeyPair.php index 61522e8c..3f3903db 100644 --- a/src/UHost/Models/UHostKeyPair.php +++ b/src/UHost/Models/UHostKeyPair.php @@ -1,6 +1,7 @@ set("KeyPairId", $keyPairId); } - /** * KeyPairState: 主机密钥对状态,Normal 正常,Deleted 删除 * @@ -57,7 +61,7 @@ public function getKeyPairState() * * @param string $keyPairState */ - public function setKeyPairState($keyPairState) + public function setKeyPairState(string $keyPairState) { $this->set("KeyPairState", $keyPairState); } diff --git a/src/UHost/Models/UHostPriceSet.php b/src/UHost/Models/UHostPriceSet.php index c7007008..e97db70c 100644 --- a/src/UHost/Models/UHostPriceSet.php +++ b/src/UHost/Models/UHostPriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 价格,单位: 元,保留小数点后两位有效数字 * @@ -57,11 +60,10 @@ public function getPrice() * * @param float $price */ - public function setPrice($price) + public function setPrice(float $price) { $this->set("Price", $price); } - /** * OriginalPrice: 限时优惠的折前原价(即列表价乘以商务折扣后的单价)。 * @@ -77,11 +79,10 @@ public function getOriginalPrice() * * @param float $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(float $originalPrice) { $this->set("OriginalPrice", $originalPrice); } - /** * ListPrice: 产品列表价。 * @@ -97,7 +98,7 @@ public function getListPrice() * * @param float $listPrice */ - public function setListPrice($listPrice) + public function setListPrice(float $listPrice) { $this->set("ListPrice", $listPrice); } diff --git a/src/UHost/Models/UHostTagSet.php b/src/UHost/Models/UHostTagSet.php index 053500c5..8011aa0a 100644 --- a/src/UHost/Models/UHostTagSet.php +++ b/src/UHost/Models/UHostTagSet.php @@ -1,6 +1,7 @@ set("Tag", $tag); } - /** * TotalCount: 该业务组中包含的主机个数 * @@ -57,11 +59,10 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } - /** * Zone: 可用区 * @@ -77,7 +78,7 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } diff --git a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH.php b/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH.php deleted file mode 100644 index 288b63c5..00000000 --- a/src/UHost/Params/CreateUHostInstanceParamNetworkInterfaceEIPGlobalSSH.php +++ /dev/null @@ -1,84 +0,0 @@ -get("Area"); - } - - /** - * Area: 填写支持SSH访问IP的地区名称,如“洛杉矶”,“新加坡”,“香港”,“东京”,“华盛顿”,“法兰克福”。Area和AreaCode两者必填其中之一。 - * - * @param string $area - */ - public function setArea($area) - { - $this->set("Area", $area); - } - - /** - * Port: SSH端口,1-65535且不能使用80,443端口 - * - * @return integer|null - */ - public function getPort() - { - return $this->get("Port"); - } - - /** - * Port: SSH端口,1-65535且不能使用80,443端口 - * - * @param int $port - */ - public function setPort($port) - { - $this->set("Port", $port); - } - - /** - * AreaCode: GlobalSSH的地区编码,格式为区域航空港国际通用代码。Area和AreaCode两者必填其中之一。 - * - * @return string|null - */ - public function getAreaCode() - { - return $this->get("AreaCode"); - } - - /** - * AreaCode: GlobalSSH的地区编码,格式为区域航空港国际通用代码。Area和AreaCode两者必填其中之一。 - * - * @param string $areaCode - */ - public function setAreaCode($areaCode) - { - $this->set("AreaCode", $areaCode); - } -} diff --git a/src/UHost/UHostClient.php b/src/UHost/UHostClient.php index ef537ec6..ca0ef732 100644 --- a/src/UHost/UHostClient.php +++ b/src/UHost/UHostClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SourceImageId" => (string) 源镜像Id, 参见 DescribeImage - * "TargetProjectId" => (string) 目标项目Id, 参见 GetProjectList - * "TargetRegion" => (string) 目标地域,不跨地域不用填 - * "TargetImageName" => (string) 目标镜像名称 - * "TargetImageDescription" => (string) 目标镜像描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "TargetImageId" => (string) 目标镜像Id - * ] - * - * @return CopyCustomImageResponse * @throws UCloudException */ public function copyCustomImage(CopyCustomImageRequest $request = null) @@ -125,30 +211,13 @@ public function copyCustomImage(CopyCustomImageRequest $request = null) $resp = $this->invoke($request); return new CopyCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateCustomImage - 从指定UHost实例,生成自定义镜像。 * - * See also: https://docs.ucloud.cn/api/uhost-api/create_custom_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "ImageName" => (string) 镜像名称 - * "ImageDescription" => (string) 镜像描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageId" => (string) 镜像Id - * ] - * - * @return CreateCustomImageResponse * @throws UCloudException */ public function createCustomImage(CreateCustomImageRequest $request = null) @@ -156,28 +225,13 @@ public function createCustomImage(CreateCustomImageRequest $request = null) $resp = $this->invoke($request); return new CreateCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateIsolationGroup - 创建硬件隔离组,组内机器严格隔离在不同宿主机上。 * - * See also: https://docs.ucloud.cn/api/uhost-api/create_isolation_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目id - * "GroupName" => (string) 硬件隔离组名称。请遵照[[api:uhost-api:specification|字段规范]]设定隔离组名称。 - * "Remark" => (string) 备注。请遵照[[api:uhost-api:specification|字段规范]]设定隔离组备注。 - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (string) 硬件隔离组id - * ] - * - * @return CreateIsolationGroupResponse * @throws UCloudException */ public function createIsolationGroup(CreateIsolationGroupRequest $request = null) @@ -185,88 +239,13 @@ public function createIsolationGroup(CreateIsolationGroupRequest $request = null $resp = $this->invoke($request); return new CreateIsolationGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUHostInstance - 创建UHost实例。 * - * See also: https://docs.ucloud.cn/api/uhost-api/create_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageId" => (string) 镜像ID。 请通过 [DescribeImage](describe_image.html)获取 - * "Disks" => (array) [ - * [ - * "IsBoot" => (string) 是否是系统盘。枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 - * "Type" => (string) 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "Size" => (integer) 磁盘大小,单位GB,必须是10GB的整数倍。请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "BackupType" => (string) 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT(SNAPSHOT模式目前仅在上海C支持),快照 \\当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]],默认值:NONE - * "Encrypted" => (boolean) 【功能仅部分可用区开放,详询技术支持】磁盘是否加密。加密:true, 不加密: false加密必须传入对应的的KmsKeyId,默认值false - * "KmsKeyId" => (string) 【功能仅部分可用区开放,详询技术支持】kms key id。选择加密盘时必填。 - * "CouponId" => (string) 云盘代金券id。不适用于系统盘/本地盘。请通过DescribeCoupon接口查询,或登录用户中心查看 - * ] - * ] - * "LoginMode" => (string) 主机登陆模式。密码(默认选项): Password,密钥:KeyPair。 - * "Password" => (string) UHost密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,举例如下:# echo -n Password1 | base64UGFzc3dvcmQx。 - * "Name" => (string) UHost实例名称。默认:UHost。请遵照[[api:uhost-api:specification|字段规范]]设定实例名称。 - * "Tag" => (string) 业务组。默认:Default(Default即为未分组)。请遵照[[api:uhost-api:specification|字段规范]]设定业务组。 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\Preemptive计费为抢占式实例 \\ 默认为月付 - * "Quantity" => (integer) 购买时长。默认:值 1。按小时购买(Dynamic/Postpay)时无需此参数。 月付时,此参数传0,代表购买至月末。 - * "UHostType" => (string) 【建议后续不再使用】云主机机型(V1.0),在本字段和字段MachineType中,仅需要其中1个字段即可。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "CPU" => (integer) 虚拟CPU核数。可选参数:1-64(具体机型与CPU的对应关系参照控制台)。默认值: 4。 - * "Memory" => (integer) 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参考控制台)。默认值:8192 - * "GpuType" => (string) GPU类型,枚举值["K80", "P40", "V100", "T4", "T4S","2080Ti","2080Ti-4C","1080Ti", "T4/4", "MI100", "V100S"],MachineType为G时必填 - * "GPU" => (integer) GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) - * "NetCapability" => (string) 网络增强特性。枚举值:Normal(默认),不开启; Super,开启网络增强1.0; Ultra,开启网络增强2.0(仅支持部分可用区,请参考控制台) - * "HotplugFeature" => (boolean) 热升级特性。True为开启,False为未开启,默认False。 - * "VPCId" => (string) VPC ID。默认为当前地域的默认VPC。 - * "SubnetId" => (string) 子网 ID。默认为当前地域的默认子网。 - * "PrivateIp" => (array) 【数组】创建云主机时指定内网IP。若不传值,则随机分配当前子网下的IP。调用方式举例:PrivateIp.0=x.x.x.x。当前只支持一个内网IP。 - * "SecurityGroupId" => (string) 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。 - * "IsolationGroup" => (string) 硬件隔离组id。可通过DescribeIsolationGroup获取。 - * "AlarmTemplateId" => (integer) 告警模板id,如果传了告警模板id,且告警模板id正确,则绑定告警模板。绑定告警模板失败只会在后台有日志,不会影响创建主机流程,也不会在前端报错。 - * "MachineType" => (string) 云主机机型(V2.0),在本字段和字段UHostType中,仅需要其中1个字段即可。枚举值["N", "C", "G", "O", "OS", "OM", "OPRO", "OMAX", "O.BM", "O.EPC"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "MinimalCpuPlatform" => (string) 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake", "Intel/CascadelakeR", "Intel/IceLake", "Amd/Epyc2", "Amd/Auto"],默认值是"Intel/Auto"。 - * "MaxCount" => (integer) 本次最大创建主机数量,取值范围是[1,100],默认值为1。 - * "NetworkInterface" => (array) [ - * [ - * "EIP" => (object) [ - * "Bandwidth" => (integer) 【若绑定EIP,此参数必填】弹性IP的外网带宽, 单位为Mbps. 共享带宽模式必须指定0M带宽, 非共享带宽模式必须指定非0Mbps带宽. 各地域非共享带宽的带宽范围如下: 流量计费[1-300],带宽计费[1-800] - * "PayMode" => (string) 弹性IP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; "ShareBandwidth",共享带宽模式. "Free":免费带宽模式,默认为 "Bandwidth" - * "ShareBandwidthId" => (string) 绑定的共享带宽Id,仅当PayMode为ShareBandwidth时有效 - * "GlobalSSH" => (object) [ - * "Area" => (string) 填写支持SSH访问IP的地区名称,如“洛杉矶”,“新加坡”,“香港”,“东京”,“华盛顿”,“法兰克福”。Area和AreaCode两者必填其中之一。 - * "Port" => (integer) SSH端口,1-65535且不能使用80,443端口 - * "AreaCode" => (string) GlobalSSH的地区编码,格式为区域航空港国际通用代码。Area和AreaCode两者必填其中之一。 - * ] - * "OperatorName" => (string) 【若绑定EIP,此参数必填】弹性IP的线路。枚举值: 国际: International BGP: Bgp 各地域允许的线路参数如下: cn-sh1: Bgp cn-sh2: Bgp cn-gd: Bgp cn-bj1: Bgp cn-bj2: Bgp hk: International us-ca: International th-bkk: International kr-seoul:International us-ws:International ge-fra:International sg:International tw-kh:International.其他海外线路均为 International - * "CouponId" => (string) 当前EIP代金券id。请通过DescribeCoupon接口查询,或登录用户中心查看。 - * ] - * "IPv6" => (object) - * "CreateCernetIp" => (boolean) 申请并绑定一个教育网EIP。True为申请并绑定,False为不会申请绑定,默认False。当前只支持具有HPC特性的机型。 - * ] - * ] - * "UserData" => (string) 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码 - * "AutoDataDiskInit" => (string) 数据盘是否需要自动分区挂载。当镜像支持“Cloud-init”Feature时可填写此字段。取值 >“On” 自动挂载(默认值)> “Off” 不自动挂载。 - * "Volumes" => (array) - * "KeyPairId" => (string) KeypairId 密钥对ID,LoginMode为KeyPair时此项必须 - * "Features" => (object) [ - * "UNI" => (boolean) 弹性网卡特性。开启了弹性网卡权限位,此特性才生效,默认 false 未开启,true 开启,仅与 NetCapability Normal 兼容。 - * ] - * "CouponId" => (string) 主机代金券ID。请通过DescribeCoupon接口查询,或登录用户中心查看 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostIds" => (array) UHost实例Id集合 - * "IPs" => (array) 【批量创建不会返回】IP信息 - * ] - * - * @return CreateUHostInstanceResponse * @throws UCloudException */ public function createUHostInstance(CreateUHostInstanceRequest $request = null) @@ -274,35 +253,13 @@ public function createUHostInstance(CreateUHostInstanceRequest $request = null) $resp = $this->invoke($request); return new CreateUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUHostKeyPair - 创建主机密钥对信息 * - * See also: https://docs.ucloud.cn/api/uhost-api/create_uhost_key_pair - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "KeyPairName" => (string) 密钥对名称。 由字母,数字,符号组成,长度为1-63位。 - * ] - * - * Outputs: - * - * $outputs = [ - * "KeyPair" => (object) 密钥信息[ - * "ProjectId" => (string) 项目ID。 - * "KeyPairId" => (string) 密钥对ID。 - * "KeyPairName" => (string) 密钥对名称。 长度为1~63个英文或中文字符。 - * "KeyPairFingerPrint" => (string) 密钥对指纹。md5(ProjectId|KeyPairId|PublicKey) - * "PrivateKeyBody" => (string) 密钥对的私钥内容。只有创建接口才会返回。 - * "CreateTime" => (integer) 密钥对的创建时间,格式为Unix Timestamp。 - * ] - * ] - * - * @return CreateUHostKeyPairResponse * @throws UCloudException */ public function createUHostKeyPair(CreateUHostKeyPairRequest $request = null) @@ -310,27 +267,13 @@ public function createUHostKeyPair(CreateUHostKeyPairRequest $request = null) $resp = $this->invoke($request); return new CreateUHostKeyPairResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteIsolationGroup - 删除硬件隔离组。 * - * See also: https://docs.ucloud.cn/api/uhost-api/delete_isolation_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目id - * "GroupId" => (string) 硬件隔离组id - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (string) 硬件隔离组id - * ] - * - * @return DeleteIsolationGroupResponse * @throws UCloudException */ public function deleteIsolationGroup(DeleteIsolationGroupRequest $request = null) @@ -338,27 +281,13 @@ public function deleteIsolationGroup(DeleteIsolationGroupRequest $request = null $resp = $this->invoke($request); return new DeleteIsolationGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUHostKeyPairs - 删除一对或者多对密钥对。 * - * See also: https://docs.ucloud.cn/api/uhost-api/delete_uhost_key_pairs - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "KeyPairIds" => (array) 密钥对ID,最多支持 100 对。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUHostKeyPairsResponse * @throws UCloudException */ public function deleteUHostKeyPairs(DeleteUHostKeyPairsRequest $request = null) @@ -366,53 +295,13 @@ public function deleteUHostKeyPairs(DeleteUHostKeyPairsRequest $request = null) $resp = $this->invoke($request); return new DeleteUHostKeyPairsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeImage - 获取指定数据中心镜像列表,用户可通过指定操作系统类型,镜像Id进行过滤。 * - * See also: https://docs.ucloud.cn/api/uhost-api/describe_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageType" => (string) 镜像类型。标准镜像:Base,镜像市场:Business, 自定义镜像:Custom,默认返回所有类型 - * "OsType" => (string) 操作系统类型:Linux, Windows 默认返回所有类型 - * "ImageId" => (string) 镜像Id - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20 - * "PriceSet" => (integer) 是否返回价格:1返回,0不返回;默认不返回 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的镜像总数 - * "ImageSet" => (array) 镜像列表详见 UHostImageSet[ - * [ - * "Zone" => (string) 可用区,参见 [可用区列表](../summary/regionlist.html) - * "ImageId" => (string) 镜像ID - * "ImageName" => (string) 镜像名称 - * "OsType" => (string) 操作系统类型:Linux,Windows - * "OsName" => (string) 操作系统名称 - * "ImageType" => (string) 镜像类型 标准镜像:Base, 行业镜像:Business,自定义镜像:Custom - * "Features" => (array) 特殊状态标识, 目前包含NetEnhnced(网络增强1.0), NetEnhanced_Ultra](网络增强2.0), HotPlug(热升级), CloudInit, IPv6 - * "FuncType" => (string) 行业镜像类型(仅行业镜像将返回这个值) - * "IntegratedSoftware" => (string) 集成软件名称(仅行业镜像将返回这个值) - * "Vendor" => (string) 供应商(仅行业镜像将返回这个值) - * "Links" => (string) 介绍链接(仅行业镜像将返回这个值) - * "State" => (string) 镜像状态, 可用:Available,制作中:Making, 不可用:Unavailable - * "ImageDescription" => (string) 镜像描述 - * "CreateTime" => (integer) 创建时间,格式为Unix时间戳 - * "ImageSize" => (integer) 镜像大小 - * "MinimalCPU" => (string) 默认值为空'''。当CentOS 7.3/7.4/7.5等镜像会标记为“Broadwell” - * ] - * ] - * ] - * - * @return DescribeImageResponse * @throws UCloudException */ public function describeImage(DescribeImageRequest $request = null) @@ -420,42 +309,13 @@ public function describeImage(DescribeImageRequest $request = null) $resp = $this->invoke($request); return new DescribeImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeIsolationGroup - 查询硬件隔离组列表。 * - * See also: https://docs.ucloud.cn/api/uhost-api/describe_isolation_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目id - * "GroupId" => (string) 待查的硬件隔离组id - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20,最大100 - * ] - * - * Outputs: - * - * $outputs = [ - * "IsolationGroupSet" => (array) 硬件隔离组集合。参见数据结构IsolationGroup。[ - * [ - * "GroupName" => (string) 硬件隔离组名称 - * "GroupId" => (string) 硬件隔离组id - * "SpreadInfoSet" => (array) 每个可用区中的机器数量。参见数据结构SpreadInfo。[ - * [ - * "Zone" => (string) 可用区信息 - * "UHostCount" => (integer) 当前地域所有可用区中硬件隔离组中云主机的数量,不超过7。 - * ] - * ] - * "Remark" => (string) 备注 - * ] - * ] - * "TotalCount" => (integer) 硬件隔离组总数 - * ] - * - * @return DescribeIsolationGroupResponse * @throws UCloudException */ public function describeIsolationGroup(DescribeIsolationGroupRequest $request = null) @@ -463,108 +323,13 @@ public function describeIsolationGroup(DescribeIsolationGroupRequest $request = $resp = $this->invoke($request); return new DescribeIsolationGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUHostInstance - 获取主机或主机列表信息,并可根据数据中心,主机ID等参数进行过滤。 * - * See also: https://docs.ucloud.cn/api/uhost-api/describe_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostIds" => (array) 【数组】UHost主机的资源ID,例如UHostIds.0代表希望获取信息 的主机1,UHostIds.1代表主机2。 如果不传入,则返回当前Region 所有符合条件的UHost实例。 - * "Tag" => (string) 要查询的业务组名称 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20,最大100 - * "IsolationGroup" => (string) 硬件隔离组id。通过硬件隔离组筛选主机。 - * "VPCId" => (string) vpc id。通过VPC筛选主机。北京一地域无效。 - * "SubnetId" => (string) 子网id。通过子网筛选主机。北京一地域无效。 - * "UDiskIdForAttachment" => (string) 要挂载的云盘id,过滤返回能被UDiskId挂载的云主机。目前主要针对rssd云盘使用 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) UHostInstance总数 - * "UHostSet" => (array) 云主机实例列表,每项参数可见下面 UHostInstanceSet[ - * [ - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "IPv6Feature" => (boolean) true:有ipv6特性;false,没有ipv6特性 - * "UHostId" => (string) UHost实例ID - * "UHostType" => (string) 【建议不再使用】云主机机型(旧)。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "MachineType" => (string) 云主机机型(新)。参考[[api:uhost-api:uhost_type#主机概念20版本|云主机机型说明]]。 - * "CpuPlatform" => (string) 云主机CPU平台。参考[[api:uhost-api:uhost_type#主机概念20版本|云主机机型说明]]。 - * "StorageType" => (string) 【建议不再使用】主机磁盘类型。 枚举值为:\\ > LocalDisk,本地磁盘; \\ > UDisk 云盘。\\只要有一块磁盘为本地盘,即返回LocalDisk。 - * "ImageId" => (string) 【建议不再使用】主机的系统盘ID。 - * "BasicImageId" => (string) 基础镜像ID(指当前自定义镜像的来源镜像) - * "BasicImageName" => (string) 基础镜像名称(指当前自定义镜像的来源镜像) - * "Tag" => (string) 业务组名称 - * "Remark" => (string) 备注 - * "Name" => (string) UHost实例名称 - * "State" => (string) 实例状态,枚举值:\\ >初始化: Initializing; \\ >启动中: Starting; \\> 运行中: Running; \\> 关机中: Stopping; \\ >关机: Stopped \\ >安装失败: Install Fail; \\ >重启中: Rebooting; \\ > 未知(空字符串,获取状态超时或出错):"" - * "CreateTime" => (integer) 创建时间,格式为Unix时间戳 - * "ChargeType" => (string) 计费模式,枚举值为: Year,按年付费; Month,按月付费; Dynamic,按需付费(需开启权限);Preemptive 为抢占式实例; - * "ExpireTime" => (integer) 到期时间,格式为Unix时间戳 - * "CPU" => (integer) 虚拟CPU核数,单位: 个 - * "Memory" => (integer) 内存大小,单位: MB - * "AutoRenew" => (string) 是否自动续费,自动续费:“Yes”,不自动续费:“No” - * "DiskSet" => (array) 磁盘信息见 UHostDiskSet[ - * [ - * "DiskType" => (string) 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "IsBoot" => (string) 是否是系统盘。枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 - * "Encrypted" => (string) "true": 加密盘 "false":非加密盘 - * "Type" => (string) 【建议不再使用】磁盘类型。系统盘: Boot,数据盘: Data,网络盘:Udisk - * "DiskId" => (string) 磁盘ID - * "Name" => (string) UDisk名字(仅当磁盘是UDisk时返回) - * "Drive" => (string) 磁盘盘符 - * "Size" => (integer) 磁盘大小,单位: GB - * "BackupType" => (string) 备份方案。若开通了数据方舟,则为DATAARK - * ] - * ] - * "IPSet" => (array) 详细信息见 UHostIPSet[ - * [ - * "IPMode" => (string) IPv4/IPv6; - * "Default" => (string) 内网 Private 类型下,表示是否为默认网卡。true: 是默认网卡;其他值:不是。 - * "Mac" => (string) 内网 Private 类型下,当前网卡的Mac。 - * "Weight" => (integer) 当前EIP的权重。权重最大的为当前的出口IP。 - * "Type" => (string) 国际: Internation,BGP: Bgp,内网: Private - * "IPId" => (string) 外网IP资源ID 。(内网IP无对应的资源ID) - * "IP" => (string) IP地址 - * "Bandwidth" => (integer) IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) - * "VPCId" => (string) IP地址对应的VPC ID。(北京一不支持,字段返回为空) - * "SubnetId" => (string) IP地址对应的子网 ID。(北京一不支持,字段返回为空) - * "NetworkInterfaceId" => (string) 弹性网卡为默认网卡时,返回对应的 ID 值 - * ] - * ] - * "NetCapability" => (string) 网络增强。Normal: 无;Super: 网络增强1.0; Ultra: 网络增强2.0 - * "NetworkState" => (string) 【建议不再使用】网络状态。 连接:Connected, 断开:NotConnected - * "TimemachineFeature" => (string) 【建议不再使用】数据方舟模式。枚举值:\\ > Yes: 开启方舟; \\ > no,未开启方舟 - * "HotplugFeature" => (boolean) true: 开启热升级; false,未开启热升级 - * "SubnetType" => (string) 【建议不再使用】仅北京A的云主机会返回此字段。基础网络模式:Default;子网模式:Private - * "OsName" => (string) 创建主机的最初来源镜像的操作系统名称(若直接通过基础镜像创建,此处返回和BasicImageName一致) - * "OsType" => (string) 操作系统类别。返回"Linux"或者"Windows" - * "HostType" => (string) 【建议不再使用】主机系列:N2,表示系列2;N1,表示系列1 - * "LifeCycle" => (string) 主机的生命周期类型。目前仅支持Normal:普通; - * "GPU" => (integer) GPU个数 - * "BootDiskState" => (string) 系统盘状态 Normal表示初始化完成;Initializing表示在初始化。仍在初始化的系统盘无法制作镜像。 - * "TotalDiskSpace" => (integer) 总的数据盘存储空间。 - * "IsolationGroup" => (string) 隔离组id,不在隔离组则返回"" - * "CloudInitFeature" => (boolean) true,支持cloutinit方式初始化;false,不支持 - * "RdmaClusterId" => (string) RDMA集群id,仅快杰云主机返回该值;其他类型云主机返回""。当云主机的此值与RSSD云盘的RdmaClusterId相同时,RSSD可以挂载到这台云主机。 - * "RestrictMode" => (string) 仅抢占式实例返回,LowSpeed为低速模式,PowerOff为关机模式 - * "HpcFeature" => (boolean) true: 开启 hpc 系列功能;false: 未开启 - * "KeyPair" => (object) 密钥信息见 UHostKeyPair[ - * "KeyPairId" => (string) 密钥对ID - * "KeyPairState" => (string) 主机密钥对状态,Normal 正常,Deleted 删除 - * ] - * ] - * ] - * ] - * - * @return DescribeUHostInstanceResponse * @throws UCloudException */ public function describeUHostInstance(DescribeUHostInstanceRequest $request = null) @@ -572,40 +337,13 @@ public function describeUHostInstance(DescribeUHostInstanceRequest $request = nu $resp = $this->invoke($request); return new DescribeUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUHostKeyPairs - 查询一个或多个密钥对。 * - * See also: https://docs.ucloud.cn/api/uhost-api/describe_uhost_key_pairs - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "KeyPairName" => (string) 密钥对名称。 - * "KeyPairFingerPrint" => (string) 密钥对的指纹。 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20,最大100 - * ] - * - * Outputs: - * - * $outputs = [ - * "KeyPairs" => (array) 密钥对信息集合[ - * [ - * "ProjectId" => (string) 项目ID。 - * "KeyPairId" => (string) 密钥对ID。 - * "KeyPairName" => (string) 密钥对名称。 长度为1~63个英文或中文字符。 - * "KeyPairFingerPrint" => (string) 密钥对指纹。md5(ProjectId|KeyPairId|PublicKey) - * "CreateTime" => (integer) 密钥对的创建时间,格式为Unix Timestamp。 - * ] - * ] - * "TotalCount" => (integer) 密钥对总数 - * ] - * - * @return DescribeUHostKeyPairsResponse * @throws UCloudException */ public function describeUHostKeyPairs(DescribeUHostKeyPairsRequest $request = null) @@ -613,34 +351,13 @@ public function describeUHostKeyPairs(DescribeUHostKeyPairsRequest $request = nu $resp = $this->invoke($request); return new DescribeUHostKeyPairsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUHostTags - 获取指定数据中心的业务组列表。 * - * See also: https://docs.ucloud.cn/api/uhost-api/describe_uhost_tags - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 已有主机的业务组总数 - * "TagSet" => (array) 业务组集合见 UHostTagSet[ - * [ - * "Tag" => (string) 业务组名称 - * "TotalCount" => (integer) 该业务组中包含的主机个数 - * "Zone" => (string) 可用区 - * ] - * ] - * ] - * - * @return DescribeUHostTagsResponse * @throws UCloudException */ public function describeUHostTags(DescribeUHostTagsRequest $request = null) @@ -648,31 +365,13 @@ public function describeUHostTags(DescribeUHostTagsRequest $request = null) $resp = $this->invoke($request); return new DescribeUHostTagsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetAttachedDiskUpgradePrice - 获取挂载磁盘的升级价格 * - * See also: https://docs.ucloud.cn/api/uhost-api/get_attached_disk_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "DiskSpace" => (integer) 磁盘大小,单位GB,步长为10。取值范围需大于当前磁盘大小,最大值请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "DiskId" => (string) 磁盘ID。参见 [DescribeUHostInstance](describe_uhost_instance.html)返回值中的DiskSet。 - * "UHostId" => (string) UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 - * "BackupMode" => (string) 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\> SNAPSHOT(SNAPSHOT模式目前仅在上海C支持),快照 \\ 当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]]。默认值为当前的备份模式。 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 升级差价。精度为小数点后2位。 - * ] - * - * @return GetAttachedDiskUpgradePriceResponse * @throws UCloudException */ public function getAttachedDiskUpgradePrice(GetAttachedDiskUpgradePriceRequest $request = null) @@ -680,56 +379,13 @@ public function getAttachedDiskUpgradePrice(GetAttachedDiskUpgradePriceRequest $ $resp = $this->invoke($request); return new GetAttachedDiskUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUHostInstancePrice - 根据UHost实例配置,获取UHost实例的价格。 * - * See also: https://docs.ucloud.cn/api/uhost-api/get_uhost_instance_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "CPU" => (integer) CPU核数。可选参数:1-64。可选范围参照控制台。默认值: 4 - * "Memory" => (integer) 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参照好控制台)。默认值:8192 - * "Count" => (integer) 购买台数,范围[1,5] - * "Disks" => (array) [ - * [ - * "IsBoot" => (string) 是否是系统盘。枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 - * "Size" => (integer) 磁盘大小,单位GB。请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "Type" => (string) 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "BackupType" => (string) 磁盘备份方案。枚举值:\\ > NONE,无备份 \\ > DATAARK,数据方舟 \\ > SNAPSHOT,快照\\ 当前磁盘支持的备份模式参考 [[api:uhost-api:disk_type|磁盘类型]] - * ] - * ] - * "ImageId" => (string) 镜像Id,可通过 [DescribeImage](describe_image.html) 获取镜像ID, 如果镜像ID不传,系统盘大小必传 - * "GPU" => (integer) GPU卡核心数。仅GPU机型支持此字段。 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时付费 // >Preemptive 抢占式实例 \\ 如果不传某个枚举值,默认返回年付、月付、时付的价格组合集。 - * "NetCapability" => (string) 网络增强。枚举值:Normal,不开启; Super,开启网络增强1.0。 默认值为Normal。 - * "UHostType" => (string) 【待废弃】云主机机型(V1版本概念)。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "MachineType" => (string) 云主机机型(V2版本概念)。枚举值["N", "C", "G", "O", "OS", "OPRO", "OMAX", "O.BM"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "GpuType" => (string) GPU类型,枚举值["K80", "P40", "V100", "T4","T4S","2080Ti","2080Ti-4C","1080Ti"] - * "Quantity" => (integer) 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 - * "CpuPlatform" => (string) 取值"Intel" "Amd",默认值“Intel” - * "Volumes" => (array) - * "VirtualGpu" => (object) - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceSet" => (array) 价格列表 UHostPriceSet[ - * [ - * "ChargeType" => (string) 计费类型。Year,Month,Dynamic - * "Price" => (number) 价格,单位: 元,保留小数点后两位有效数字 - * "OriginalPrice" => (number) 限时优惠的折前原价(即列表价乘以商务折扣后的单价)。 - * "ListPrice" => (number) 产品列表价。 - * ] - * ] - * ] - * - * @return GetUHostInstancePriceResponse * @throws UCloudException */ public function getUHostInstancePrice(GetUHostInstancePriceRequest $request = null) @@ -737,31 +393,13 @@ public function getUHostInstancePrice(GetUHostInstancePriceRequest $request = nu $resp = $this->invoke($request); return new GetUHostInstancePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUHostInstanceVncInfo - 获取指定UHost实例的管理VNC配置详细信息。 * - * See also: https://docs.ucloud.cn/api/uhost-api/get_uhost_instance_vnc_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](./describe_uhost_instance.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * "VncIP" => (string) Vnc登录IP - * "VncPort" => (integer) Vnc登录端口 - * "VncPassword" => (string) Vnc 登录密码 - * ] - * - * @return GetUHostInstanceVncInfoResponse * @throws UCloudException */ public function getUHostInstanceVncInfo(GetUHostInstanceVncInfoRequest $request = null) @@ -769,32 +407,13 @@ public function getUHostInstanceVncInfo(GetUHostInstanceVncInfoRequest $request $resp = $this->invoke($request); return new GetUHostInstanceVncInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUHostUpgradePrice - 获取UHost实例升级配置的价格。可选配置范围请参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * - * See also: https://docs.ucloud.cn/api/uhost-api/get_uhost_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 - * "CPU" => (integer) 虚拟CPU核数。可选参数:1-64(可选范围参考控制台)。默认值为当前实例的CPU核数。 - * "Memory" => (integer) 内存大小。单位:MB。范围 :[1024, 262144],取值为1024的倍数(可选范围参考控制台)。默认值为当前实例的内存大小。 - * "NetCapValue" => (integer) 网卡升降级(1,表示升级,2表示降级,0表示不变) - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 规格调整差价。精确到小数点后2位。 - * "OriginalPrice" => (number) 限时优惠的折前原价 - * ] - * - * @return GetUHostUpgradePriceResponse * @throws UCloudException */ public function getUHostUpgradePrice(GetUHostUpgradePriceRequest $request = null) @@ -802,33 +421,13 @@ public function getUHostUpgradePrice(GetUHostUpgradePriceRequest $request = null $resp = $this->invoke($request); return new GetUHostUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ImportCustomImage - 把UFile的镜像文件导入到UHost,生成自定义镜像 * - * See also: https://docs.ucloud.cn/api/uhost-api/import_custom_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageName" => (string) 镜像名称 - * "UFileUrl" => (string) UFile私有空间地址 - * "OsType" => (string) 操作系统平台,比如CentOS、Ubuntu、Windows、RedHat等,请参考控制台的镜像版本;若导入控制台上没有的操作系统,参数为Other - * "OsName" => (string) 操作系统详细版本,请参考控制台的镜像版本;OsType为Other时,输入参数为Other - * "Format" => (string) 镜像格式,可选RAW、VHD、VMDK、qcow2 - * "Auth" => (boolean) 是否授权。必须填true - * "ImageDescription" => (string) 镜像描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageId" => (string) 镜像Id - * ] - * - * @return ImportCustomImageResponse * @throws UCloudException */ public function importCustomImage(ImportCustomImageRequest $request = null) @@ -836,31 +435,13 @@ public function importCustomImage(ImportCustomImageRequest $request = null) $resp = $this->invoke($request); return new ImportCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ImportUHostKeyPairs - 导入密钥对后,仅保管公钥部分,需自行妥善保存密钥对的私钥部分。 * - * See also: https://docs.ucloud.cn/api/uhost-api/import_uhost_key_pairs - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "KeyPairName" => (string) 密钥对名称。由字母,数字,符号组成,长度为1-63位。 - * "PublicKeyBody" => (string) 密钥对的公钥内容。 - * ] - * - * Outputs: - * - * $outputs = [ - * "KeyPairName" => (string) 密钥对名称 - * "KeyPairId" => (string) 密钥对标识 - * "KeyPairFingerPrint" => (string) 密钥对指纹。根据RFC4716定义的公钥指纹格式,采用MD5信息摘要算法。算法处理的具体信息格式:`ProjectIdKeyPairId|PublicKeyBody`。 - * ] - * - * @return ImportUHostKeyPairsResponse * @throws UCloudException */ public function importUHostKeyPairs(ImportUHostKeyPairsRequest $request = null) @@ -868,29 +449,13 @@ public function importUHostKeyPairs(ImportUHostKeyPairsRequest $request = null) $resp = $this->invoke($request); return new ImportUHostKeyPairsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * LeaveIsolationGroup - 移除硬件隔离组中的主机 * - * See also: https://docs.ucloud.cn/api/uhost-api/leave_isolation_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区信息 - * "ProjectId" => (string) 项目id - * "GroupId" => (string) 硬件隔离组id - * "UHostId" => (string) 主机id - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) 主机id - * ] - * - * @return LeaveIsolationGroupResponse * @throws UCloudException */ public function leaveIsolationGroup(LeaveIsolationGroupRequest $request = null) @@ -898,30 +463,13 @@ public function leaveIsolationGroup(LeaveIsolationGroupRequest $request = null) $resp = $this->invoke($request); return new LeaveIsolationGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUHostIP - 修改云主机内网 IP 地址 * - * See also: https://docs.ucloud.cn/api/uhost-api/modify_uhost_ip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写时为默认项目。请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PresentIpAddress" => (string) 需要修改为的 IP 地址。新的IP地址和旧IP地址必须属于统一子网,且和主机内部的配置文件一致。 - * "UHostId" => (string) 指定云主机 ID。 - * "PreviousIpAddress" => (string) 所需修改的原 IP 地址 ,当云主机只有一个IP地址时,此参数不必填写。 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) 目标云主机 ID - * ] - * - * @return ModifyUHostIPResponse * @throws UCloudException */ public function modifyUHostIP(ModifyUHostIPRequest $request = null) @@ -929,29 +477,13 @@ public function modifyUHostIP(ModifyUHostIPRequest $request = null) $resp = $this->invoke($request); return new ModifyUHostIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUHostInstanceName - 修改指定UHost实例名称,需要给出数据中心,UHostId,及新的实例名称。 * - * See also: https://docs.ucloud.cn/api/uhost-api/modify_uhost_instance_name - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "Name" => (string) UHost实例名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return ModifyUHostInstanceNameResponse * @throws UCloudException */ public function modifyUHostInstanceName(ModifyUHostInstanceNameRequest $request = null) @@ -959,29 +491,13 @@ public function modifyUHostInstanceName(ModifyUHostInstanceNameRequest $request $resp = $this->invoke($request); return new ModifyUHostInstanceNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUHostInstanceRemark - 修改指定UHost实例备注信息。 * - * See also: https://docs.ucloud.cn/api/uhost-api/modify_uhost_instance_remark - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return ModifyUHostInstanceRemarkResponse * @throws UCloudException */ public function modifyUHostInstanceRemark(ModifyUHostInstanceRemarkRequest $request = null) @@ -989,29 +505,13 @@ public function modifyUHostInstanceRemark(ModifyUHostInstanceRemarkRequest $requ $resp = $this->invoke($request); return new ModifyUHostInstanceRemarkResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUHostInstanceTag - 修改指定UHost实例业务组标识。 * - * See also: https://docs.ucloud.cn/api/uhost-api/modify_uhost_instance_tag - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "Tag" => (string) 业务组名称 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return ModifyUHostInstanceTagResponse * @throws UCloudException */ public function modifyUHostInstanceTag(ModifyUHostInstanceTagRequest $request = null) @@ -1019,28 +519,13 @@ public function modifyUHostInstanceTag(ModifyUHostInstanceTagRequest $request = $resp = $this->invoke($request); return new ModifyUHostInstanceTagResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PoweroffUHostInstance - 直接关闭UHost实例电源,无需等待实例正常关闭。 * - * See also: https://docs.ucloud.cn/api/uhost-api/poweroff_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](./describe_uhost_instance.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost的实例ID - * ] - * - * @return PoweroffUHostInstanceResponse * @throws UCloudException */ public function poweroffUHostInstance(PoweroffUHostInstanceRequest $request = null) @@ -1048,29 +533,13 @@ public function poweroffUHostInstance(PoweroffUHostInstanceRequest $request = nu $resp = $this->invoke($request); return new PoweroffUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RebootUHostInstance - 重新启动UHost实例,需要指定数据中心及UHostID两个参数的值。 * - * See also: https://docs.ucloud.cn/api/uhost-api/reboot_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "DiskPassword" => (string) 加密盘密码 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return RebootUHostInstanceResponse * @throws UCloudException */ public function rebootUHostInstance(RebootUHostInstanceRequest $request = null) @@ -1078,36 +547,13 @@ public function rebootUHostInstance(RebootUHostInstanceRequest $request = null) $resp = $this->invoke($request); return new RebootUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReinstallUHostInstance - 重新安装指定UHost实例的操作系统 * - * See also: https://docs.ucloud.cn/api/uhost-api/reinstall_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例资源ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "Password" => (string) 如果重装UHost实例时LoginMode为Password,则必须填写,如果LoginMode为KeyPair,不需要填写 (密码格式使用BASE64编码;举例如下:# echo -n Password1 | base64UGFzc3dvcmQx。) - * "ImageId" => (string) 镜像Id,默认使用原镜像 参见 [DescribeImage](describe_image.html) - * "ReserveDisk" => (string) 是否保留数据盘,保留:Yes,不报留:No, 默认:Yes;如果是从Windows重装为Linux或反之,则无法保留数据盘(该参数目前仅对本地数据盘起作用) - * "BootDiskSpace" => (integer) 系统盘大小。 单位:GB, 范围[20,100], 步长:10 - * "UserData" => (string) cloudinit初始化使用。注意:1、总数据量大小不超多16K 2、使用base64编码 - * "AutoDataDiskInit" => (string) 数据盘是否需要自动分区挂载。当镜像支持Cloud-init Feature时可填写此字段。取值“On”(默认值), “Off” - * "LoginMode" => (string) 主机登陆模式。密码(默认选项): Password,密钥 KeyPair。 - * "KeyPairId" => (string) KeypairId 密钥对ID,LoginMode为KeyPair时此项必须。 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例资源ID - * ] - * - * @return ReinstallUHostInstanceResponse * @throws UCloudException */ public function reinstallUHostInstance(ReinstallUHostInstanceRequest $request = null) @@ -1115,29 +561,13 @@ public function reinstallUHostInstance(ReinstallUHostInstanceRequest $request = $resp = $this->invoke($request); return new ReinstallUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResetUHostInstancePassword - 重置UHost实例的管理员密码。 * - * See also: https://docs.ucloud.cn/api/uhost-api/reset_uhost_instance_password - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID - * "Password" => (string) UHost新密码(密码格式使用BASE64编码) - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return ResetUHostInstancePasswordResponse * @throws UCloudException */ public function resetUHostInstancePassword(ResetUHostInstancePasswordRequest $request = null) @@ -1145,32 +575,13 @@ public function resetUHostInstancePassword(ResetUHostInstancePasswordRequest $re $resp = $this->invoke($request); return new ResetUHostInstancePasswordResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeAttachedDisk - 修改挂载的磁盘大小,包含系统盘和数据盘 * - * See also: https://docs.ucloud.cn/api/uhost-api/resize_attached_disk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID。 参见 [DescribeUHostInstance](describe_uhost_instance.html)。 - * "DiskSpace" => (integer) 磁盘大小,单位GB,步长为10。取值范围需大于当前磁盘大小,最大值请参考[[api:uhost-api:disk_type|磁盘类型]]。 - * "DiskId" => (string) 磁盘ID。参见 [DescribeUHostInstance](describe_uhost_instance.html)返回值中的DiskSet。 - * "DryRun" => (boolean) 用于测试磁盘是否支持在线扩容。DryRun=true,不会执行实际操作,只会返回操作的预期结果。DryRun = false ,正常执行扩容操作。 - * ] - * - * Outputs: - * - * $outputs = [ - * "DiskId" => (string) 改配成功的磁盘id - * "NeedRestart" => (boolean) 扩容后的状态。NeedRestart = true,必须关闭后启动实例才能使用扩容的磁盘空间。NeedRestart = false,磁盘扩容后无需重启操作。 - * ] - * - * @return ResizeAttachedDiskResponse * @throws UCloudException */ public function resizeAttachedDisk(ResizeAttachedDiskRequest $request = null) @@ -1178,31 +589,13 @@ public function resizeAttachedDisk(ResizeAttachedDiskRequest $request = null) $resp = $this->invoke($request); return new ResizeAttachedDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeUHostInstance - 修改指定UHost实例的资源配置,如CPU核心数,内存容量大小,网络增强等。可选配置范围请参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * - * See also: https://docs.ucloud.cn/api/uhost-api/resize_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "CPU" => (integer) 虚拟CPU核数。可选参数:1-240(可选范围与UHostType相关)。默认值为当前实例的CPU核数 - * "Memory" => (integer) 内存大小。单位:MB。范围 :[1024, 1966080],取值为1024的倍数(可选范围与UHostType相关)。默认值为当前实例的内存大小。 - * "NetCapValue" => (integer) 网卡升降级(1,表示升级,2表示降级,0表示不变) - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return ResizeUHostInstanceResponse * @throws UCloudException */ public function resizeUHostInstance(ResizeUHostInstanceRequest $request = null) @@ -1210,29 +603,13 @@ public function resizeUHostInstance(ResizeUHostInstanceRequest $request = null) $resp = $this->invoke($request); return new ResizeUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StartUHostInstance - 启动处于关闭状态的UHost实例,需要指定数据中心及UHostID两个参数的值。 * - * See also: https://docs.ucloud.cn/api/uhost-api/start_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "DiskPassword" => (string) 加密盘密码 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return StartUHostInstanceResponse * @throws UCloudException */ public function startUHostInstance(StartUHostInstanceRequest $request = null) @@ -1240,28 +617,13 @@ public function startUHostInstance(StartUHostInstanceRequest $request = null) $resp = $this->invoke($request); return new StartUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StopUHostInstance - 指停止处于运行状态的UHost实例,需指定数据中心及UhostID。 * - * See also: https://docs.ucloud.cn/api/uhost-api/stop_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost实例ID 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostId" => (string) UHost实例ID - * ] - * - * @return StopUHostInstanceResponse * @throws UCloudException */ public function stopUHostInstance(StopUHostInstanceRequest $request = null) @@ -1269,27 +631,13 @@ public function stopUHostInstance(StopUHostInstanceRequest $request = null) $resp = $this->invoke($request); return new StopUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * TerminateCustomImage - 删除用户自定义镜像 * - * See also: https://docs.ucloud.cn/api/uhost-api/terminate_custom_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageId" => (string) 自制镜像ID 参见 [DescribeImage](describe_image.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "ImageId" => (string) 自制镜像Id - * ] - * - * @return TerminateCustomImageResponse * @throws UCloudException */ public function terminateCustomImage(TerminateCustomImageRequest $request = null) @@ -1297,31 +645,13 @@ public function terminateCustomImage(TerminateCustomImageRequest $request = null $resp = $this->invoke($request); return new TerminateCustomImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * TerminateUHostInstance - 删除指定数据中心的UHost实例。 * - * See also: https://docs.ucloud.cn/api/uhost-api/terminate_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "UHostId" => (string) UHost资源Id 参见 [DescribeUHostInstance](describe_uhost_instance.html) - * "ReleaseEIP" => (boolean) 删除主机时是否释放绑定的EIP。默认为false。 - * "ReleaseUDisk" => (boolean) 删除主机时是否同时删除挂载的数据盘。默认为false。 - * ] - * - * Outputs: - * - * $outputs = [ - * "InRecycle" => (string) 用于判断主机删除时是否进入回收站。放入回收站:"Yes", 彻底删除:“No”。 - * "UHostId" => (string) UHost 实例 Id - * ] - * - * @return TerminateUHostInstanceResponse * @throws UCloudException */ public function terminateUHostInstance(TerminateUHostInstanceRequest $request = null) @@ -1329,28 +659,13 @@ public function terminateUHostInstance(TerminateUHostInstanceRequest $request = $resp = $this->invoke($request); return new TerminateUHostInstanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpgradeToArkUHostInstance - 普通升级为方舟机型 * - * See also: https://docs.ucloud.cn/api/uhost-api/upgrade_to_ark_uhost_instance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "UHostIds" => (array) UHost主机的资源ID,例如UHostIds.0代表希望升级的主机1,UHostIds.1代表主机2。 - * "CouponId" => (string) 代金券ID 请参考DescribeCoupon接口 - * ] - * - * Outputs: - * - * $outputs = [ - * "UHostSet" => (array) UHost主机的资源ID数组 - * ] - * - * @return UpgradeToArkUHostInstanceResponse * @throws UCloudException */ public function upgradeToArkUHostInstance(UpgradeToArkUHostInstanceRequest $request = null) diff --git a/src/UK8S/Apis/AddUK8SExistingUHostRequest.php b/src/UK8S/Apis/AddUK8SExistingUHostRequest.php index 968bd54d..283a568e 100644 --- a/src/UK8S/Apis/AddUK8SExistingUHostRequest.php +++ b/src/UK8S/Apis/AddUK8SExistingUHostRequest.php @@ -1,6 +1,7 @@ markRequired("UHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Password: Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 * @@ -106,11 +104,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * ClusterId: UK8S集群ID。 可从UK8S控制台获取。 * @@ -126,11 +123,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * UHostId: 云主机Id,为了保证节点正常运行,该主机配置不得低于2C4G。 * @@ -146,11 +142,10 @@ public function getUHostId() * * @param string $uHostId */ - public function setUHostId($uHostId) + public function setUHostId(string $uHostId) { $this->set("UHostId", $uHostId); } - /** * MaxPods: 默认110,生产环境建议小于等于110。 * @@ -166,11 +161,10 @@ public function getMaxPods() * * @param int $maxPods */ - public function setMaxPods($maxPods) + public function setMaxPods(int $maxPods) { $this->set("MaxPods", $maxPods); } - /** * Labels: Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game * @@ -186,11 +180,10 @@ public function getLabels() * * @param string $labels */ - public function setLabels($labels) + public function setLabels(string $labels) { $this->set("Labels", $labels); } - /** * SubnetId: 该云主机所属子网Id。 * @@ -206,11 +199,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ImageId: 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 * @@ -226,11 +218,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * DisableSchedule: 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 * @@ -246,11 +237,10 @@ public function getDisableSchedule() * * @param boolean $disableSchedule */ - public function setDisableSchedule($disableSchedule) + public function setDisableSchedule(bool $disableSchedule) { $this->set("DisableSchedule", $disableSchedule); } - /** * UserData: 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码。 * @@ -266,11 +256,10 @@ public function getUserData() * * @param string $userData */ - public function setUserData($userData) + public function setUserData(string $userData) { $this->set("UserData", $userData); } - /** * InitScript: 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行,UserData则是云主机初始化时执行。 * @@ -286,7 +275,7 @@ public function getInitScript() * * @param string $initScript */ - public function setInitScript($initScript) + public function setInitScript(string $initScript) { $this->set("InitScript", $initScript); } diff --git a/src/UK8S/Apis/AddUK8SExistingUHostResponse.php b/src/UK8S/Apis/AddUK8SExistingUHostResponse.php index 80b2f757..c840c53a 100644 --- a/src/UK8S/Apis/AddUK8SExistingUHostResponse.php +++ b/src/UK8S/Apis/AddUK8SExistingUHostResponse.php @@ -1,6 +1,7 @@ "AddUK8SNodeGroup"]); + $this->markRequired("Region"); + $this->markRequired("NodeGroupName"); + $this->markRequired("ClusterId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * NodeGroupName: 节点池名字 + * + * @return string|null + */ + public function getNodeGroupName() + { + return $this->get("NodeGroupName"); + } + + /** + * NodeGroupName: 节点池名字 + * + * @param string $nodeGroupName + */ + public function setNodeGroupName(string $nodeGroupName) + { + $this->set("NodeGroupName", $nodeGroupName); + } + /** + * ClusterId: 集群ID + * + * @return string|null + */ + public function getClusterId() + { + return $this->get("ClusterId"); + } + + /** + * ClusterId: 集群ID + * + * @param string $clusterId + */ + public function setClusterId(string $clusterId) + { + $this->set("ClusterId", $clusterId); + } + /** + * ImageId: 镜像ID + * + * @return string|null + */ + public function getImageId() + { + return $this->get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } + /** + * MachineType: 云主机机型。枚举值["N", "C", "G", "O", "OS"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 + * + * @return string|null + */ + public function getMachineType() + { + return $this->get("MachineType"); + } + + /** + * MachineType: 云主机机型。枚举值["N", "C", "G", "O", "OS"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 + * + * @param string $machineType + */ + public function setMachineType(string $machineType) + { + $this->set("MachineType", $machineType); + } + /** + * MinimalCpuPlatform: 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake";"Intel/CascadelakeR"; “Amd/Epyc2”,"Amd/Auto"],默认值是"Intel/Auto" + * + * @return string|null + */ + public function getMinimalCpuPlatform() + { + return $this->get("MinimalCpuPlatform"); + } + + /** + * MinimalCpuPlatform: 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake";"Intel/CascadelakeR"; “Amd/Epyc2”,"Amd/Auto"],默认值是"Intel/Auto" + * + * @param string $minimalCpuPlatform + */ + public function setMinimalCpuPlatform(string $minimalCpuPlatform) + { + $this->set("MinimalCpuPlatform", $minimalCpuPlatform); + } + /** + * CPU: GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) + * + * @return integer|null + */ + public function getCPU() + { + return $this->get("CPU"); + } + + /** + * CPU: GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) + * + * @param int $cpu + */ + public function setCPU(int $cpu) + { + $this->set("CPU", $cpu); + } + /** + * Mem: 内存大小。单位:MB + * + * @return integer|null + */ + public function getMem() + { + return $this->get("Mem"); + } + + /** + * Mem: 内存大小。单位:MB + * + * @param int $mem + */ + public function setMem(int $mem) + { + $this->set("Mem", $mem); + } + /** + * GpuType: GPU类型 + * + * @return string|null + */ + public function getGpuType() + { + return $this->get("GpuType"); + } + + /** + * GpuType: GPU类型 + * + * @param string $gpuType + */ + public function setGpuType(string $gpuType) + { + $this->set("GpuType", $gpuType); + } + /** + * GPU: GPU卡核心数 + * + * @return integer|null + */ + public function getGPU() + { + return $this->get("GPU"); + } + + /** + * GPU: GPU卡核心数 + * + * @param int $gpu + */ + public function setGPU(int $gpu) + { + $this->set("GPU", $gpu); + } + /** + * BootDiskType: 磁盘类型 + * + * @return string|null + */ + public function getBootDiskType() + { + return $this->get("BootDiskType"); + } + + /** + * BootDiskType: 磁盘类型 + * + * @param string $bootDiskType + */ + public function setBootDiskType(string $bootDiskType) + { + $this->set("BootDiskType", $bootDiskType); + } + /** + * DataDiskSize: 数据磁盘大小 + * + * @return integer|null + */ + public function getDataDiskSize() + { + return $this->get("DataDiskSize"); + } + + /** + * DataDiskSize: 数据磁盘大小 + * + * @param int $dataDiskSize + */ + public function setDataDiskSize(int $dataDiskSize) + { + $this->set("DataDiskSize", $dataDiskSize); + } + /** + * DataDiskType: 磁盘类型 + * + * @return string|null + */ + public function getDataDiskType() + { + return $this->get("DataDiskType"); + } + + /** + * DataDiskType: 磁盘类型 + * + * @param string $dataDiskType + */ + public function setDataDiskType(string $dataDiskType) + { + $this->set("DataDiskType", $dataDiskType); + } + /** + * Tag: 业务组 + * + * @return string|null + */ + public function getTag() + { + return $this->get("Tag"); + } + + /** + * Tag: 业务组 + * + * @param string $tag + */ + public function setTag(string $tag) + { + $this->set("Tag", $tag); + } + /** + * ChargeType: 计费模式 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 计费模式 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } +} diff --git a/src/UK8S/Apis/AddUK8SNodeGroupResponse.php b/src/UK8S/Apis/AddUK8SNodeGroupResponse.php new file mode 100644 index 00000000..b0772d67 --- /dev/null +++ b/src/UK8S/Apis/AddUK8SNodeGroupResponse.php @@ -0,0 +1,45 @@ +get("NodeGroupId"); + } + + /** + * NodeGroupId: 节点池ID + * + * @param string $nodeGroupId + */ + public function setNodeGroupId(string $nodeGroupId) + { + $this->set("NodeGroupId", $nodeGroupId); + } +} diff --git a/src/UK8S/Apis/AddUK8SPHostNodeRequest.php b/src/UK8S/Apis/AddUK8SPHostNodeRequest.php index c55b9fdd..c48e7f28 100644 --- a/src/UK8S/Apis/AddUK8SPHostNodeRequest.php +++ b/src/UK8S/Apis/AddUK8SPHostNodeRequest.php @@ -1,6 +1,7 @@ markRequired("ChargeType"); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -68,11 +68,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) * @@ -88,11 +87,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ClusterId: UK8S集群ID。 可从UK8S控制台获取。 * @@ -108,11 +106,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * Count: 最大创建Node节点数量,取值范围是[1,10]。 * @@ -128,11 +125,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Password: Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 * @@ -148,11 +144,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ 默认为月付 * @@ -168,11 +163,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长。默认: 1。月付时,此参数传0,代表了购买至月末。 * @@ -188,11 +182,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Labels: Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game * @@ -208,11 +201,10 @@ public function getLabels() * * @param string $labels */ - public function setLabels($labels) + public function setLabels(string $labels) { $this->set("Labels", $labels); } - /** * MaxPods: 默认110,生产环境建议小于等于110。 * @@ -228,11 +220,10 @@ public function getMaxPods() * * @param int $maxPods */ - public function setMaxPods($maxPods) + public function setMaxPods(int $maxPods) { $this->set("MaxPods", $maxPods); } - /** * Type: 物理机类型,默认为:db-2(基础型-SAS-V3) * @@ -248,11 +239,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Raid: Raid配置,默认Raid10 支持:Raid0、Raid1、Raid5、Raid10,NoRaid * @@ -268,11 +258,10 @@ public function getRaid() * * @param string $raid */ - public function setRaid($raid) + public function setRaid(string $raid) { $this->set("Raid", $raid); } - /** * NIC: 网络环境,可选千兆:1G ,万兆:10G, 默认1G。 * @@ -288,11 +277,10 @@ public function getNIC() * * @param string $nic */ - public function setNIC($nic) + public function setNIC(string $nic) { $this->set("NIC", $nic); } - /** * SubnetId: 子网 ID。默认为集群创建时填写的子网ID,也可以填写集群同VPC内的子网ID。 * @@ -308,11 +296,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ImageId: 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 * @@ -328,11 +315,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * DisableSchedule: 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 * @@ -348,11 +334,10 @@ public function getDisableSchedule() * * @param boolean $disableSchedule */ - public function setDisableSchedule($disableSchedule) + public function setDisableSchedule(bool $disableSchedule) { $this->set("DisableSchedule", $disableSchedule); } - /** * InitScript: 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行。 * @@ -368,7 +353,7 @@ public function getInitScript() * * @param string $initScript */ - public function setInitScript($initScript) + public function setInitScript(string $initScript) { $this->set("InitScript", $initScript); } diff --git a/src/UK8S/Apis/AddUK8SPHostNodeResponse.php b/src/UK8S/Apis/AddUK8SPHostNodeResponse.php index 6bcf55b1..43426f14 100644 --- a/src/UK8S/Apis/AddUK8SPHostNodeResponse.php +++ b/src/UK8S/Apis/AddUK8SPHostNodeResponse.php @@ -1,6 +1,7 @@ markRequired("ChargeType"); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -50,11 +51,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -70,11 +70,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -90,11 +89,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ClusterId: UK8S集群ID。 可从UK8S控制台获取。 * @@ -110,11 +108,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * CPU: 虚拟CPU核数。可选参数:2-64(具体机型与CPU的对应关系参照控制台)。默认值: 4。 * @@ -130,11 +127,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Count: 创建Node节点数量,取值范围是[1,50]。 * @@ -150,11 +146,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Password: Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 * @@ -170,11 +165,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * Mem: 内存大小。单位:MB。范围 :[4096, 262144],取值为1024的倍数(可选范围参考控制台)。默认值:8192 * @@ -190,11 +184,10 @@ public function getMem() * * @param int $mem */ - public function setMem($mem) + public function setMem(int $mem) { $this->set("Mem", $mem); } - /** * ChargeType: 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\ 默认为月付 * @@ -210,11 +203,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * BootDiskType: 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -230,11 +222,10 @@ public function getBootDiskType() * * @param string $bootDiskType */ - public function setBootDiskType($bootDiskType) + public function setBootDiskType(string $bootDiskType) { $this->set("BootDiskType", $bootDiskType); } - /** * DataDiskType: 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -250,11 +241,10 @@ public function getDataDiskType() * * @param string $dataDiskType */ - public function setDataDiskType($dataDiskType) + public function setDataDiskType(string $dataDiskType) { $this->set("DataDiskType", $dataDiskType); } - /** * DataDiskSize: 数据磁盘大小,单位GB。默认0。范围 :[20, 1000] * @@ -270,11 +260,10 @@ public function getDataDiskSize() * * @param int $dataDiskSize */ - public function setDataDiskSize($dataDiskSize) + public function setDataDiskSize(int $dataDiskSize) { $this->set("DataDiskSize", $dataDiskSize); } - /** * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 * @@ -290,11 +279,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * MachineType: 云主机机型。枚举值["N", "C", "G", "O", "OS"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 * @@ -310,11 +298,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * MinmalCpuPlatform: 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake";"Intel/CascadelakeR"; “Amd/Epyc2”,"Amd/Auto"],默认值是"Intel/Auto" * @@ -330,11 +317,10 @@ public function getMinmalCpuPlatform() * * @param string $minmalCpuPlatform */ - public function setMinmalCpuPlatform($minmalCpuPlatform) + public function setMinmalCpuPlatform(string $minmalCpuPlatform) { $this->set("MinmalCpuPlatform", $minmalCpuPlatform); } - /** * GpuType: GPU类型,枚举值["K80", "P40", "V100",],MachineType为G时必填 * @@ -350,11 +336,10 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } - /** * GPU: GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) * @@ -370,11 +355,10 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } - /** * Labels: Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game * @@ -390,11 +374,10 @@ public function getLabels() * * @param string $labels */ - public function setLabels($labels) + public function setLabels(string $labels) { $this->set("Labels", $labels); } - /** * MaxPods: 默认110,生产环境建议小于等于110。 * @@ -410,11 +393,10 @@ public function getMaxPods() * * @param int $maxPods */ - public function setMaxPods($maxPods) + public function setMaxPods(int $maxPods) { $this->set("MaxPods", $maxPods); } - /** * IsolationGroup: 硬件隔离组id。可通过DescribeIsolationGroup获取。 * @@ -430,11 +412,10 @@ public function getIsolationGroup() * * @param string $isolationGroup */ - public function setIsolationGroup($isolationGroup) + public function setIsolationGroup(string $isolationGroup) { $this->set("IsolationGroup", $isolationGroup); } - /** * ImageId: 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 * @@ -450,11 +431,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * SubnetId: 子网 ID。默认为集群创建时填写的子网ID,也可以填写集群同VPC内的子网ID。 * @@ -470,11 +450,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * DisableSchedule: 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 * @@ -490,11 +469,10 @@ public function getDisableSchedule() * * @param boolean $disableSchedule */ - public function setDisableSchedule($disableSchedule) + public function setDisableSchedule(bool $disableSchedule) { $this->set("DisableSchedule", $disableSchedule); } - /** * UserData: 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码。 * @@ -510,11 +488,10 @@ public function getUserData() * * @param string $userData */ - public function setUserData($userData) + public function setUserData(string $userData) { $this->set("UserData", $userData); } - /** * InitScript: 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行,UserData则是云主机初始化时执行。 * @@ -530,7 +507,7 @@ public function getInitScript() * * @param string $initScript */ - public function setInitScript($initScript) + public function setInitScript(string $initScript) { $this->set("InitScript", $initScript); } diff --git a/src/UK8S/Apis/AddUK8SUHostNodeResponse.php b/src/UK8S/Apis/AddUK8SUHostNodeResponse.php index 56cb1a40..6963891a 100644 --- a/src/UK8S/Apis/AddUK8SUHostNodeResponse.php +++ b/src/UK8S/Apis/AddUK8SUHostNodeResponse.php @@ -1,6 +1,7 @@ markRequired("MasterMem"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -55,11 +57,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -75,11 +76,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 集群Node及Pod所属VPC * @@ -95,11 +95,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 集群Node及Pod所属子网 * @@ -115,11 +114,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ServiceCIDR: Service 网段,用于分配ClusterIP,如172.17.0.0/16。该网段不能与集群所属VPC网段重叠。 * @@ -135,11 +133,10 @@ public function getServiceCIDR() * * @param string $serviceCIDR */ - public function setServiceCIDR($serviceCIDR) + public function setServiceCIDR(string $serviceCIDR) { $this->set("ServiceCIDR", $serviceCIDR); } - /** * ClusterName: 集群名称 * @@ -155,11 +152,10 @@ public function getClusterName() * * @param string $clusterName */ - public function setClusterName($clusterName) + public function setClusterName(string $clusterName) { $this->set("ClusterName", $clusterName); } - /** * Password: 集群节点密码,包括Master和Node。密码需包含最少一个大写字母,请使用base64进行编码,举例如下:# echo -n Password1 | base64 * @@ -175,15 +171,14 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * Master: * - * @return CreateUK8SClusterV2ParamMaster[]|null + * @return CreateUK8SClusterV2RequestMasterModel[]|null */ public function getMaster() { @@ -193,7 +188,7 @@ public function getMaster() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUK8SClusterV2ParamMaster($item)); + array_push($result, new CreateUK8SClusterV2RequestMasterModel($item)); } return $result; } @@ -201,7 +196,7 @@ public function getMaster() /** * Master: * - * @param CreateUK8SClusterV2ParamMaster[] $master + * @param CreateUK8SClusterV2RequestMasterModel[] $master */ public function setMaster(array $master) { @@ -211,7 +206,6 @@ public function setMaster(array $master) } return $result; } - /** * MasterMachineType: Master节点的云主机机型(V2.0),如["N", "C", "O", "OS"],具体请参照云主机机型。 * @@ -227,11 +221,10 @@ public function getMasterMachineType() * * @param string $masterMachineType */ - public function setMasterMachineType($masterMachineType) + public function setMasterMachineType(string $masterMachineType) { $this->set("MasterMachineType", $masterMachineType); } - /** * MasterCPU: Master节点的虚拟CPU核数。可选参数:2-64(具体机型与CPU的对应关系参照控制台)。 * @@ -247,11 +240,10 @@ public function getMasterCPU() * * @param int $masterCPU */ - public function setMasterCPU($masterCPU) + public function setMasterCPU(int $masterCPU) { $this->set("MasterCPU", $masterCPU); } - /** * MasterMem: Master节点的内存大小。单位:MB。范围 :[4096, 262144],取值为1024的倍数(可选范围参考控制台)。 * @@ -267,15 +259,14 @@ public function getMasterMem() * * @param int $masterMem */ - public function setMasterMem($masterMem) + public function setMasterMem(int $masterMem) { $this->set("MasterMem", $masterMem); } - /** * Nodes: * - * @return CreateUK8SClusterV2ParamNodes[]|null + * @return CreateUK8SClusterV2RequestNodesModel[]|null */ public function getNodes() { @@ -285,7 +276,7 @@ public function getNodes() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreateUK8SClusterV2ParamNodes($item)); + array_push($result, new CreateUK8SClusterV2RequestNodesModel($item)); } return $result; } @@ -293,7 +284,7 @@ public function getNodes() /** * Nodes: * - * @param CreateUK8SClusterV2ParamNodes[] $nodes + * @param CreateUK8SClusterV2RequestNodesModel[] $nodes */ public function setNodes(array $nodes) { @@ -303,7 +294,6 @@ public function setNodes(array $nodes) } return $result; } - /** * MasterBootDiskType: Master节点系统盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -319,11 +309,10 @@ public function getMasterBootDiskType() * * @param string $masterBootDiskType */ - public function setMasterBootDiskType($masterBootDiskType) + public function setMasterBootDiskType(string $masterBootDiskType) { $this->set("MasterBootDiskType", $masterBootDiskType); } - /** * MasterDataDiskType: Master节点数据盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -339,11 +328,10 @@ public function getMasterDataDiskType() * * @param string $masterDataDiskType */ - public function setMasterDataDiskType($masterDataDiskType) + public function setMasterDataDiskType(string $masterDataDiskType) { $this->set("MasterDataDiskType", $masterDataDiskType); } - /** * MasterMinmalCpuPlatform: Master节点的最低cpu平台,不选则随机。枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake"。 * @@ -359,11 +347,10 @@ public function getMasterMinmalCpuPlatform() * * @param string $masterMinmalCpuPlatform */ - public function setMasterMinmalCpuPlatform($masterMinmalCpuPlatform) + public function setMasterMinmalCpuPlatform(string $masterMinmalCpuPlatform) { $this->set("MasterMinmalCpuPlatform", $masterMinmalCpuPlatform); } - /** * MasterDataDiskSize: Master节点的数据盘大小,单位GB,默认为0。范围 :[20, 1000] * @@ -379,11 +366,10 @@ public function getMasterDataDiskSize() * * @param int $masterDataDiskSize */ - public function setMasterDataDiskSize($masterDataDiskSize) + public function setMasterDataDiskSize(int $masterDataDiskSize) { $this->set("MasterDataDiskSize", $masterDataDiskSize); } - /** * ChargeType: 集群所有节点的付费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限),默认按月。 * @@ -399,11 +385,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * K8sVersion: k8s集群的版本,版本信息请参考UK8S集群创建页,不指定的话默认为当前支持的最高版本。 * @@ -419,11 +404,10 @@ public function getK8sVersion() * * @param string $k8sVersion */ - public function setK8sVersion($k8sVersion) + public function setK8sVersion(string $k8sVersion) { $this->set("K8sVersion", $k8sVersion); } - /** * Quantity: 购买时长。默认为1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 * @@ -439,11 +423,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * ExternalApiServer: 是否允许外网访问apiserver,开启:Yes 不开启:No。默认为No。 * @@ -459,11 +442,10 @@ public function getExternalApiServer() * * @param string $externalApiServer */ - public function setExternalApiServer($externalApiServer) + public function setExternalApiServer(string $externalApiServer) { $this->set("ExternalApiServer", $externalApiServer); } - /** * MasterIsolationGroup: 【无效,已删除】当前将自动为Master节点创建隔离组,确保Master节点归属于不同物理机。 * @@ -479,31 +461,29 @@ public function getMasterIsolationGroup() * * @param string $masterIsolationGroup */ - public function setMasterIsolationGroup($masterIsolationGroup) + public function setMasterIsolationGroup(string $masterIsolationGroup) { $this->set("MasterIsolationGroup", $masterIsolationGroup); } - /** * KubeProxy: * - * @return CreateUK8SClusterV2ParamKubeProxy|null + * @return CreateUK8SClusterV2RequestKubeProxyModel|null */ public function getKubeProxy() { - return new CreateUK8SClusterV2ParamKubeProxy($this->get("KubeProxy")); + return new CreateUK8SClusterV2RequestKubeProxyModel($this->get("KubeProxy")); } /** * KubeProxy: * - * @param CreateUK8SClusterV2ParamKubeProxy $kubeProxy + * @param CreateUK8SClusterV2RequestKubeProxyModel $kubeProxy */ - public function setKubeProxy(array $kubeProxy) + public function setKubeProxy(CreateUK8SClusterV2RequestKubeProxyModel $kubeProxy) { $this->set("KubeProxy", $kubeProxy->getAll()); } - /** * ImageId: Master节点和Node节点的镜像 ID,不填则随机选择可用的基础镜像。支持用户自定义镜像。 * @@ -519,11 +499,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * UserData: 用户自定义数据。注意:1、总数据量大小不超多16K;2、使用base64编码。 * @@ -539,11 +518,10 @@ public function getUserData() * * @param string $userData */ - public function setUserData($userData) + public function setUserData(string $userData) { $this->set("UserData", $userData); } - /** * InitScript: 用户自定义脚本,与UserData不同,自定义脚本将在集群安装完毕后执行。注意:1、总数据量大小不超多16K;2、使用base64编码。 * @@ -559,7 +537,7 @@ public function getInitScript() * * @param string $initScript */ - public function setInitScript($initScript) + public function setInitScript(string $initScript) { $this->set("InitScript", $initScript); } diff --git a/src/UK8S/Apis/CreateUK8SClusterV2Response.php b/src/UK8S/Apis/CreateUK8SClusterV2Response.php index 95ca8557..dd36f2e8 100644 --- a/src/UK8S/Apis/CreateUK8SClusterV2Response.php +++ b/src/UK8S/Apis/CreateUK8SClusterV2Response.php @@ -1,6 +1,7 @@ set("ClusterId", $clusterId); } diff --git a/src/UK8S/Apis/DelUK8SClusterNodeV2Request.php b/src/UK8S/Apis/DelUK8SClusterNodeV2Request.php index 47aa0ba4..32169094 100644 --- a/src/UK8S/Apis/DelUK8SClusterNodeV2Request.php +++ b/src/UK8S/Apis/DelUK8SClusterNodeV2Request.php @@ -1,6 +1,7 @@ markRequired("NodeId"); } - /** * ProjectId: 项目ID项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ClusterId: UK8S集群ID。 可从UK8S控制台获取。 * @@ -85,11 +84,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * NodeId: Node在UK8S处的唯一标示,如uk8s-reewqe5-sdasadsda。**非云主机或物理云主机资源Id** * @@ -105,11 +103,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * ReleaseDataUDisk: 删除节点时是否释放数据盘。 枚举值[true:释放,false: 不释放],默认为true。 * @@ -125,7 +122,7 @@ public function getReleaseDataUDisk() * * @param boolean $releaseDataUDisk */ - public function setReleaseDataUDisk($releaseDataUDisk) + public function setReleaseDataUDisk(bool $releaseDataUDisk) { $this->set("ReleaseDataUDisk", $releaseDataUDisk); } diff --git a/src/UK8S/Apis/DelUK8SClusterNodeV2Response.php b/src/UK8S/Apis/DelUK8SClusterNodeV2Response.php index 12e67e60..569376e3 100644 --- a/src/UK8S/Apis/DelUK8SClusterNodeV2Response.php +++ b/src/UK8S/Apis/DelUK8SClusterNodeV2Response.php @@ -1,6 +1,7 @@ markRequired("ClusterId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ClusterId: 集群id * @@ -84,11 +83,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * ReleaseUDisk: 是否删除节点挂载的数据盘。枚举值[true:删除,false: 不删除],默认不删除 * @@ -104,7 +102,7 @@ public function getReleaseUDisk() * * @param boolean $releaseUDisk */ - public function setReleaseUDisk($releaseUDisk) + public function setReleaseUDisk(bool $releaseUDisk) { $this->set("ReleaseUDisk", $releaseUDisk); } diff --git a/src/UK8S/Apis/DelUK8SClusterResponse.php b/src/UK8S/Apis/DelUK8SClusterResponse.php index 3496462b..bbf7a0c7 100644 --- a/src/UK8S/Apis/DelUK8SClusterResponse.php +++ b/src/UK8S/Apis/DelUK8SClusterResponse.php @@ -1,6 +1,7 @@ "DescribeUK8SCluster"]); + $this->markRequired("Region"); + $this->markRequired("ClusterId"); + } + + + /** + * Region: 所属区域 + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 所属区域 + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目id + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目id + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * ClusterId: k8s集群ID + * + * @return string|null + */ + public function getClusterId() + { + return $this->get("ClusterId"); + } + + /** + * ClusterId: k8s集群ID + * + * @param string $clusterId + */ + public function setClusterId(string $clusterId) + { + $this->set("ClusterId", $clusterId); + } +} diff --git a/src/UK8S/Apis/DescribeUK8SClusterResponse.php b/src/UK8S/Apis/DescribeUK8SClusterResponse.php new file mode 100644 index 00000000..1e02e2ae --- /dev/null +++ b/src/UK8S/Apis/DescribeUK8SClusterResponse.php @@ -0,0 +1,434 @@ +get("ClusterName"); + } + + /** + * ClusterName: 资源名字 + * + * @param string $clusterName + */ + public function setClusterName(string $clusterName) + { + $this->set("ClusterName", $clusterName); + } + /** + * ClusterId: 集群ID + * + * @return string|null + */ + public function getClusterId() + { + return $this->get("ClusterId"); + } + + /** + * ClusterId: 集群ID + * + * @param string $clusterId + */ + public function setClusterId(string $clusterId) + { + $this->set("ClusterId", $clusterId); + } + /** + * VPCId: 所属VPC + * + * @return string|null + */ + public function getVPCId() + { + return $this->get("VPCId"); + } + + /** + * VPCId: 所属VPC + * + * @param string $vpcId + */ + public function setVPCId(string $vpcId) + { + $this->set("VPCId", $vpcId); + } + /** + * SubnetId: 所属子网 + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: 所属子网 + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } + /** + * PodCIDR: Pod网段 + * + * @return string|null + */ + public function getPodCIDR() + { + return $this->get("PodCIDR"); + } + + /** + * PodCIDR: Pod网段 + * + * @param string $podCIDR + */ + public function setPodCIDR(string $podCIDR) + { + $this->set("PodCIDR", $podCIDR); + } + /** + * ServiceCIDR: 服务网段 + * + * @return string|null + */ + public function getServiceCIDR() + { + return $this->get("ServiceCIDR"); + } + + /** + * ServiceCIDR: 服务网段 + * + * @param string $serviceCIDR + */ + public function setServiceCIDR(string $serviceCIDR) + { + $this->set("ServiceCIDR", $serviceCIDR); + } + /** + * MasterList: Master节点配置信息,具体参考UhostInfo。托管版不返回该信息 + * + * @return UhostInfoModel[]|null + */ + public function getMasterList() + { + $items = $this->get("MasterList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new UhostInfoModel($item)); + } + return $result; + } + + /** + * MasterList: Master节点配置信息,具体参考UhostInfo。托管版不返回该信息 + * + * @param UhostInfoModel[] $masterList + */ + public function setMasterList(array $masterList) + { + $result = []; + foreach ($masterList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * MasterCount: Master 节点数量 + * + * @return integer|null + */ + public function getMasterCount() + { + return $this->get("MasterCount"); + } + + /** + * MasterCount: Master 节点数量 + * + * @param int $masterCount + */ + public function setMasterCount(int $masterCount) + { + $this->set("MasterCount", $masterCount); + } + /** + * NodeList: Node节点配置信息,具体参考UhostInfo + * + * @return UhostInfoModel[]|null + */ + public function getNodeList() + { + $items = $this->get("NodeList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new UhostInfoModel($item)); + } + return $result; + } + + /** + * NodeList: Node节点配置信息,具体参考UhostInfo + * + * @param UhostInfoModel[] $nodeList + */ + public function setNodeList(array $nodeList) + { + $result = []; + foreach ($nodeList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * CreateTime: 创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * NodeCount: Node节点数量 + * + * @return integer|null + */ + public function getNodeCount() + { + return $this->get("NodeCount"); + } + + /** + * NodeCount: Node节点数量 + * + * @param int $nodeCount + */ + public function setNodeCount(int $nodeCount) + { + $this->set("NodeCount", $nodeCount); + } + /** + * ApiServer: 集群apiserver地址 + * + * @return string|null + */ + public function getApiServer() + { + return $this->get("ApiServer"); + } + + /** + * ApiServer: 集群apiserver地址 + * + * @param string $apiServer + */ + public function setApiServer(string $apiServer) + { + $this->set("ApiServer", $apiServer); + } + /** + * Status: 状态 + * + * @return string|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: 状态 + * + * @param string $status + */ + public function setStatus(string $status) + { + $this->set("Status", $status); + } + /** + * ExternalApiServer: 集群外部apiserver地址 + * + * @return string|null + */ + public function getExternalApiServer() + { + return $this->get("ExternalApiServer"); + } + + /** + * ExternalApiServer: 集群外部apiserver地址 + * + * @param string $externalApiServer + */ + public function setExternalApiServer(string $externalApiServer) + { + $this->set("ExternalApiServer", $externalApiServer); + } + /** + * KubeProxy: kube-proxy配置 + * + * @return Model|null + */ + public function getKubeProxy() + { + return new Model($this->get("KubeProxy")); + } + + /** + * KubeProxy: kube-proxy配置 + * + * @param Model $kubeProxy + */ + public function setKubeProxy(Model $kubeProxy) + { + $this->set("KubeProxy", $kubeProxy->getAll()); + } + /** + * Version: K8S版本 + * + * @return string|null + */ + public function getVersion() + { + return $this->get("Version"); + } + + /** + * Version: K8S版本 + * + * @param string $version + */ + public function setVersion(string $version) + { + $this->set("Version", $version); + } + /** + * ClusterDomain: 自定义或者默认的clusterdomain + * + * @return string|null + */ + public function getClusterDomain() + { + return $this->get("ClusterDomain"); + } + + /** + * ClusterDomain: 自定义或者默认的clusterdomain + * + * @param string $clusterDomain + */ + public function setClusterDomain(string $clusterDomain) + { + $this->set("ClusterDomain", $clusterDomain); + } + /** + * EtcdCert: 集群etcd服务证书 + * + * @return string|null + */ + public function getEtcdCert() + { + return $this->get("EtcdCert"); + } + + /** + * EtcdCert: 集群etcd服务证书 + * + * @param string $etcdCert + */ + public function setEtcdCert(string $etcdCert) + { + $this->set("EtcdCert", $etcdCert); + } + /** + * EtcdKey: 集群etcd服务密钥 + * + * @return string|null + */ + public function getEtcdKey() + { + return $this->get("EtcdKey"); + } + + /** + * EtcdKey: 集群etcd服务密钥 + * + * @param string $etcdKey + */ + public function setEtcdKey(string $etcdKey) + { + $this->set("EtcdKey", $etcdKey); + } + /** + * CACert: 集群CA根证书 + * + * @return string|null + */ + public function getCACert() + { + return $this->get("CACert"); + } + + /** + * CACert: 集群CA根证书 + * + * @param string $caCert + */ + public function setCACert(string $caCert) + { + $this->set("CACert", $caCert); + } +} diff --git a/src/UK8S/Apis/DescribeUK8SImageRequest.php b/src/UK8S/Apis/DescribeUK8SImageRequest.php index 667d9f13..31294a20 100644 --- a/src/UK8S/Apis/DescribeUK8SImageRequest.php +++ b/src/UK8S/Apis/DescribeUK8SImageRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -83,7 +82,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UK8S/Apis/DescribeUK8SImageResponse.php b/src/UK8S/Apis/DescribeUK8SImageResponse.php index 8a4a05e3..88bb48fd 100644 --- a/src/UK8S/Apis/DescribeUK8SImageResponse.php +++ b/src/UK8S/Apis/DescribeUK8SImageResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ImageInfo($item)); + array_push($result, new ImageInfoModel($item)); } return $result; } @@ -45,7 +46,7 @@ public function getImageSet() /** * ImageSet: 虚拟机可用镜像集合, 详见ImageInfo 数组 * - * @param ImageInfo[] $imageSet + * @param ImageInfoModel[] $imageSet */ public function setImageSet(array $imageSet) { @@ -55,11 +56,10 @@ public function setImageSet(array $imageSet) } return $result; } - /** * PHostImageSet: 物理机可用镜像集合, 详见ImageInfo 数组 * - * @return ImageInfo[]|null + * @return ImageInfoModel[]|null */ public function getPHostImageSet() { @@ -69,7 +69,7 @@ public function getPHostImageSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ImageInfo($item)); + array_push($result, new ImageInfoModel($item)); } return $result; } @@ -77,7 +77,7 @@ public function getPHostImageSet() /** * PHostImageSet: 物理机可用镜像集合, 详见ImageInfo 数组 * - * @param ImageInfo[] $pHostImageSet + * @param ImageInfoModel[] $pHostImageSet */ public function setPHostImageSet(array $pHostImageSet) { diff --git a/src/UK8S/Apis/DescribeUK8SNodeRequest.php b/src/UK8S/Apis/DescribeUK8SNodeRequest.php index e3fe6e72..4e866af2 100644 --- a/src/UK8S/Apis/DescribeUK8SNodeRequest.php +++ b/src/UK8S/Apis/DescribeUK8SNodeRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ClusterId: UK8S 集群 Id * @@ -85,11 +84,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * Name: K8S 节点IP或者节点ID * @@ -105,7 +103,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UK8S/Apis/DescribeUK8SNodeResponse.php b/src/UK8S/Apis/DescribeUK8SNodeResponse.php index d2f16511..0a10d4fd 100644 --- a/src/UK8S/Apis/DescribeUK8SNodeResponse.php +++ b/src/UK8S/Apis/DescribeUK8SNodeResponse.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * Labels: 字符串数组,每一项是类似 "kubernetes.io/arch=amd64" 的标签 * @@ -62,7 +63,6 @@ public function setLabels(array $labels) { $this->set("Labels", $labels); } - /** * Annotations: 字符串数组,每一项是类似 "node.alpha.kubernetes.io/ttl=0" 的注解 * @@ -82,7 +82,6 @@ public function setAnnotations(array $annotations) { $this->set("Annotations", $annotations); } - /** * CreationTimestamp: 时间戳,单位是 秒 * @@ -98,11 +97,10 @@ public function getCreationTimestamp() * * @param int $creationTimestamp */ - public function setCreationTimestamp($creationTimestamp) + public function setCreationTimestamp(int $creationTimestamp) { $this->set("CreationTimestamp", $creationTimestamp); } - /** * ProviderID: 字符串,如:"UCloud://cn-sh2-02//uk8s-vsc0vgob-n-mpzxc" * @@ -118,11 +116,10 @@ public function getProviderID() * * @param string $providerID */ - public function setProviderID($providerID) + public function setProviderID(string $providerID) { $this->set("ProviderID", $providerID); } - /** * KernelVersion: 内核版本,如:"4.19.0-6.el7.ucloud.x86_64" * @@ -138,11 +135,10 @@ public function getKernelVersion() * * @param string $kernelVersion */ - public function setKernelVersion($kernelVersion) + public function setKernelVersion(string $kernelVersion) { $this->set("KernelVersion", $kernelVersion); } - /** * OSImage: 操作系统类型,如:"CentOS Linux 7 (Core)" * @@ -158,11 +154,10 @@ public function getOSImage() * * @param string $osImage */ - public function setOSImage($osImage) + public function setOSImage(string $osImage) { $this->set("OSImage", $osImage); } - /** * ContainerRuntimeVersion: 容器运行时版本,如:"docker://18.9.9" * @@ -178,11 +173,10 @@ public function getContainerRuntimeVersion() * * @param string $containerRuntimeVersion */ - public function setContainerRuntimeVersion($containerRuntimeVersion) + public function setContainerRuntimeVersion(string $containerRuntimeVersion) { $this->set("ContainerRuntimeVersion", $containerRuntimeVersion); } - /** * KubeletVersion: kubelet 版本 * @@ -198,11 +192,10 @@ public function getKubeletVersion() * * @param string $kubeletVersion */ - public function setKubeletVersion($kubeletVersion) + public function setKubeletVersion(string $kubeletVersion) { $this->set("KubeletVersion", $kubeletVersion); } - /** * KubeProxyVersion: kubeproxy 版本 * @@ -218,11 +211,10 @@ public function getKubeProxyVersion() * * @param string $kubeProxyVersion */ - public function setKubeProxyVersion($kubeProxyVersion) + public function setKubeProxyVersion(string $kubeProxyVersion) { $this->set("KubeProxyVersion", $kubeProxyVersion); } - /** * InternalIP: 内部 IP 地址 * @@ -238,11 +230,10 @@ public function getInternalIP() * * @param string $internalIP */ - public function setInternalIP($internalIP) + public function setInternalIP(string $internalIP) { $this->set("InternalIP", $internalIP); } - /** * Hostname: 主机名 * @@ -258,11 +249,10 @@ public function getHostname() * * @param string $hostname */ - public function setHostname($hostname) + public function setHostname(string $hostname) { $this->set("Hostname", $hostname); } - /** * AllocatedPodCount: 已分配到当前节点的 Pod 数量 * @@ -278,11 +268,10 @@ public function getAllocatedPodCount() * * @param int $allocatedPodCount */ - public function setAllocatedPodCount($allocatedPodCount) + public function setAllocatedPodCount(int $allocatedPodCount) { $this->set("AllocatedPodCount", $allocatedPodCount); } - /** * PodCapacity: 节点允许的可分配 Pod 最大数量 * @@ -298,11 +287,10 @@ public function getPodCapacity() * * @param int $podCapacity */ - public function setPodCapacity($podCapacity) + public function setPodCapacity(int $podCapacity) { $this->set("PodCapacity", $podCapacity); } - /** * Unschedulable: 是否禁止调度 * @@ -318,11 +306,10 @@ public function getUnschedulable() * * @param boolean $unschedulable */ - public function setUnschedulable($unschedulable) + public function setUnschedulable(bool $unschedulable) { $this->set("Unschedulable", $unschedulable); } - /** * CPUCapacity: 节点 CPU 总量 * @@ -338,11 +325,10 @@ public function getCPUCapacity() * * @param string $cpuCapacity */ - public function setCPUCapacity($cpuCapacity) + public function setCPUCapacity(string $cpuCapacity) { $this->set("CPUCapacity", $cpuCapacity); } - /** * MemoryCapacity: 节点内存总量 * @@ -358,11 +344,10 @@ public function getMemoryCapacity() * * @param string $memoryCapacity */ - public function setMemoryCapacity($memoryCapacity) + public function setMemoryCapacity(string $memoryCapacity) { $this->set("MemoryCapacity", $memoryCapacity); } - /** * MemoryRequests: 节点上已分配 Pod 的内存请求量 * @@ -378,11 +363,10 @@ public function getMemoryRequests() * * @param string $memoryRequests */ - public function setMemoryRequests($memoryRequests) + public function setMemoryRequests(string $memoryRequests) { $this->set("MemoryRequests", $memoryRequests); } - /** * MemoryRequestsFraction: 节点上已分配 Pod 的内存请求量占内存总量的比例,如返回值为 "4.5",则意味着请求量占总量的 4.5% * @@ -398,11 +382,10 @@ public function getMemoryRequestsFraction() * * @param string $memoryRequestsFraction */ - public function setMemoryRequestsFraction($memoryRequestsFraction) + public function setMemoryRequestsFraction(string $memoryRequestsFraction) { $this->set("MemoryRequestsFraction", $memoryRequestsFraction); } - /** * MemoryLimits: 节点上已分配 Pod 的内存限制量 * @@ -418,11 +401,10 @@ public function getMemoryLimits() * * @param string $memoryLimits */ - public function setMemoryLimits($memoryLimits) + public function setMemoryLimits(string $memoryLimits) { $this->set("MemoryLimits", $memoryLimits); } - /** * MemoryLimitsFraction: 节点上已分配 Pod 的内存限制量占内存总量的比例,如返回值为 "18",则意味着限制量占总量的 18% * @@ -438,11 +420,10 @@ public function getMemoryLimitsFraction() * * @param string $memoryLimitsFraction */ - public function setMemoryLimitsFraction($memoryLimitsFraction) + public function setMemoryLimitsFraction(string $memoryLimitsFraction) { $this->set("MemoryLimitsFraction", $memoryLimitsFraction); } - /** * CPURequests: 节点上已分配 Pod 的 CPU 请求量 * @@ -458,11 +439,10 @@ public function getCPURequests() * * @param string $cpuRequests */ - public function setCPURequests($cpuRequests) + public function setCPURequests(string $cpuRequests) { $this->set("CPURequests", $cpuRequests); } - /** * CPURequestsFraction: 节点上已分配 Pod 的 CPU 请求量占 CPU 总量的比例 * @@ -478,11 +458,10 @@ public function getCPURequestsFraction() * * @param string $cpuRequestsFraction */ - public function setCPURequestsFraction($cpuRequestsFraction) + public function setCPURequestsFraction(string $cpuRequestsFraction) { $this->set("CPURequestsFraction", $cpuRequestsFraction); } - /** * CPULimits: 节点上已分配 Pod 的 CPU 限制值 * @@ -498,11 +477,10 @@ public function getCPULimits() * * @param string $cpuLimits */ - public function setCPULimits($cpuLimits) + public function setCPULimits(string $cpuLimits) { $this->set("CPULimits", $cpuLimits); } - /** * CPULimitsFraction: 节点上已分配 Pod 的 CPU 限制值占 CPU 总量的比例 * @@ -518,15 +496,14 @@ public function getCPULimitsFraction() * * @param string $cpuLimitsFraction */ - public function setCPULimitsFraction($cpuLimitsFraction) + public function setCPULimitsFraction(string $cpuLimitsFraction) { $this->set("CPULimitsFraction", $cpuLimitsFraction); } - /** * Conditions: 节点状态数组 * - * @return K8SNodeCondition[]|null + * @return K8SNodeConditionModel[]|null */ public function getConditions() { @@ -536,7 +513,7 @@ public function getConditions() } $result = []; foreach ($items as $i => $item) { - array_push($result, new K8SNodeCondition($item)); + array_push($result, new K8SNodeConditionModel($item)); } return $result; } @@ -544,7 +521,7 @@ public function getConditions() /** * Conditions: 节点状态数组 * - * @param K8SNodeCondition[] $conditions + * @param K8SNodeConditionModel[] $conditions */ public function setConditions(array $conditions) { @@ -554,7 +531,6 @@ public function setConditions(array $conditions) } return $result; } - /** * ContainerImages: 节点上镜像名称数组 * @@ -574,7 +550,6 @@ public function setContainerImages(array $containerImages) { $this->set("ContainerImages", $containerImages); } - /** * Taints: 字符串数组,每一项是类似 "node-role.kubernetes.io/master:NoSchedule" 的污点 * diff --git a/src/UK8S/Apis/ListUK8SClusterNodeV2Request.php b/src/UK8S/Apis/ListUK8SClusterNodeV2Request.php index f8c5310a..c917e34f 100644 --- a/src/UK8S/Apis/ListUK8SClusterNodeV2Request.php +++ b/src/UK8S/Apis/ListUK8SClusterNodeV2Request.php @@ -1,6 +1,7 @@ markRequired("ClusterId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ClusterId: UK8S集群ID * @@ -84,7 +83,7 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } diff --git a/src/UK8S/Apis/ListUK8SClusterNodeV2Response.php b/src/UK8S/Apis/ListUK8SClusterNodeV2Response.php index e4841e8b..3305c9cb 100644 --- a/src/UK8S/Apis/ListUK8SClusterNodeV2Response.php +++ b/src/UK8S/Apis/ListUK8SClusterNodeV2Response.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NodeInfoV2($item)); + array_push($result, new NodeInfoV2Model($item)); } return $result; } @@ -46,7 +48,7 @@ public function getNodeSet() /** * NodeSet: 节点详细信息,见NodeInfoV2。 * - * @param NodeInfoV2[] $nodeSet + * @param NodeInfoV2Model[] $nodeSet */ public function setNodeSet(array $nodeSet) { @@ -56,7 +58,6 @@ public function setNodeSet(array $nodeSet) } return $result; } - /** * TotalCount: 满足条件的节点数量,包括Master。 * @@ -72,7 +73,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UK8S/Apis/ListUK8SClusterV2Request.php b/src/UK8S/Apis/ListUK8SClusterV2Request.php index bbbca709..0f46a5d5 100644 --- a/src/UK8S/Apis/ListUK8SClusterV2Request.php +++ b/src/UK8S/Apis/ListUK8SClusterV2Request.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 列表起始位置偏移量,默认为0。 * @@ -83,11 +82,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20。 * @@ -103,11 +101,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * ClusterId: UK8S集群ID * @@ -123,7 +120,7 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } diff --git a/src/UK8S/Apis/ListUK8SClusterV2Response.php b/src/UK8S/Apis/ListUK8SClusterV2Response.php index c5da22a0..3bc7598a 100644 --- a/src/UK8S/Apis/ListUK8SClusterV2Response.php +++ b/src/UK8S/Apis/ListUK8SClusterV2Response.php @@ -1,6 +1,7 @@ set("ClusterCount", $clusterCount); } - /** * ClusterSet: 集群信息,具体参考ClusterSet * - * @return ClusterSet[]|null + * @return ClusterSetModel[]|null */ public function getClusterSet() { @@ -56,7 +57,7 @@ public function getClusterSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ClusterSet($item)); + array_push($result, new ClusterSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getClusterSet() /** * ClusterSet: 集群信息,具体参考ClusterSet * - * @param ClusterSet[] $clusterSet + * @param ClusterSetModel[] $clusterSet */ public function setClusterSet(array $clusterSet) { diff --git a/src/UK8S/Apis/ListUK8SNodeGroupRequest.php b/src/UK8S/Apis/ListUK8SNodeGroupRequest.php new file mode 100644 index 00000000..155b034e --- /dev/null +++ b/src/UK8S/Apis/ListUK8SNodeGroupRequest.php @@ -0,0 +1,90 @@ + "ListUK8SNodeGroup"]); + $this->markRequired("Region"); + $this->markRequired("ClusterId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * ClusterId: 集群ID + * + * @return string|null + */ + public function getClusterId() + { + return $this->get("ClusterId"); + } + + /** + * ClusterId: 集群ID + * + * @param string $clusterId + */ + public function setClusterId(string $clusterId) + { + $this->set("ClusterId", $clusterId); + } +} diff --git a/src/UK8S/Apis/ListUK8SNodeGroupResponse.php b/src/UK8S/Apis/ListUK8SNodeGroupResponse.php new file mode 100644 index 00000000..eb494ae8 --- /dev/null +++ b/src/UK8S/Apis/ListUK8SNodeGroupResponse.php @@ -0,0 +1,59 @@ +get("NodeGroupList"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new NodeGroupSetModel($item)); + } + return $result; + } + + /** + * NodeGroupList: 节点池列表 + * + * @param NodeGroupSetModel[] $nodeGroupList + */ + public function setNodeGroupList(array $nodeGroupList) + { + $result = []; + foreach ($nodeGroupList as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UK8S/Apis/RemoveUK8SNodeGroupRequest.php b/src/UK8S/Apis/RemoveUK8SNodeGroupRequest.php new file mode 100644 index 00000000..e8ce93ba --- /dev/null +++ b/src/UK8S/Apis/RemoveUK8SNodeGroupRequest.php @@ -0,0 +1,110 @@ + "RemoveUK8SNodeGroup"]); + $this->markRequired("Region"); + $this->markRequired("NodeGroupId"); + $this->markRequired("ClusterId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * NodeGroupId: 节点池Id + * + * @return string|null + */ + public function getNodeGroupId() + { + return $this->get("NodeGroupId"); + } + + /** + * NodeGroupId: 节点池Id + * + * @param string $nodeGroupId + */ + public function setNodeGroupId(string $nodeGroupId) + { + $this->set("NodeGroupId", $nodeGroupId); + } + /** + * ClusterId: 集群id + * + * @return string|null + */ + public function getClusterId() + { + return $this->get("ClusterId"); + } + + /** + * ClusterId: 集群id + * + * @param string $clusterId + */ + public function setClusterId(string $clusterId) + { + $this->set("ClusterId", $clusterId); + } +} diff --git a/src/UK8S/Apis/RemoveUK8SNodeGroupResponse.php b/src/UK8S/Apis/RemoveUK8SNodeGroupResponse.php new file mode 100644 index 00000000..f691bd47 --- /dev/null +++ b/src/UK8S/Apis/RemoveUK8SNodeGroupResponse.php @@ -0,0 +1,26 @@ +set("ClusterName", $clusterName); } - /** * ClusterId: 集群ID * @@ -57,11 +59,10 @@ public function getClusterId() * * @param string $clusterId */ - public function setClusterId($clusterId) + public function setClusterId(string $clusterId) { $this->set("ClusterId", $clusterId); } - /** * VPCId: 所属VPC * @@ -77,11 +78,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 所属子网 * @@ -97,11 +97,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * PodCIDR: Pod网段 * @@ -117,11 +116,10 @@ public function getPodCIDR() * * @param string $podCIDR */ - public function setPodCIDR($podCIDR) + public function setPodCIDR(string $podCIDR) { $this->set("PodCIDR", $podCIDR); } - /** * ServiceCIDR: 服务网段 * @@ -137,11 +135,10 @@ public function getServiceCIDR() * * @param string $serviceCIDR */ - public function setServiceCIDR($serviceCIDR) + public function setServiceCIDR(string $serviceCIDR) { $this->set("ServiceCIDR", $serviceCIDR); } - /** * MasterCount: Master 节点数量 * @@ -157,11 +154,10 @@ public function getMasterCount() * * @param int $masterCount */ - public function setMasterCount($masterCount) + public function setMasterCount(int $masterCount) { $this->set("MasterCount", $masterCount); } - /** * ApiServer: 集群apiserver地址 * @@ -177,11 +173,10 @@ public function getApiServer() * * @param string $apiServer */ - public function setApiServer($apiServer) + public function setApiServer(string $apiServer) { $this->set("ApiServer", $apiServer); } - /** * K8sVersion: 集群版本 * @@ -197,11 +192,10 @@ public function getK8sVersion() * * @param string $k8sVersion */ - public function setK8sVersion($k8sVersion) + public function setK8sVersion(string $k8sVersion) { $this->set("K8sVersion", $k8sVersion); } - /** * ClusterLogInfo: 创建集群时判断如果为NORESOURCE则为没资源,否则为空 * @@ -217,11 +211,10 @@ public function getClusterLogInfo() * * @param string $clusterLogInfo */ - public function setClusterLogInfo($clusterLogInfo) + public function setClusterLogInfo(string $clusterLogInfo) { $this->set("ClusterLogInfo", $clusterLogInfo); } - /** * CreateTime: 创建时间 * @@ -237,11 +230,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * NodeCount: Node节点数量 * @@ -257,11 +249,10 @@ public function getNodeCount() * * @param int $nodeCount */ - public function setNodeCount($nodeCount) + public function setNodeCount(int $nodeCount) { $this->set("NodeCount", $nodeCount); } - /** * ExternalApiServer: 集群外部apiserver地址 * @@ -277,11 +268,10 @@ public function getExternalApiServer() * * @param string $externalApiServer */ - public function setExternalApiServer($externalApiServer) + public function setExternalApiServer(string $externalApiServer) { $this->set("ExternalApiServer", $externalApiServer); } - /** * Status: 集群状态,枚举值:初始化:"INITIALIZING";启动中:"STARTING";创建失败:"CREATEFAILED";正常运行:"RUNNING";添加节点:"ADDNODE";删除节点:"DELNODE";删除中:"DELETING";删除失败:"DELETEFAILED";错误:"ERROR";升级插件:"UPDATE_PLUGIN";更新插件信息:"UPDATE_PLUGIN_INFO";异常:"ABNORMAL";升级集群中:"UPGRADING";容器运行时切换:"CONVERTING" * @@ -297,7 +287,7 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } diff --git a/src/UK8S/Params/CreateUK8SClusterV2ParamKubeProxy.php b/src/UK8S/Models/CreateUK8SClusterV2RequestKubeProxy.php similarity index 78% rename from src/UK8S/Params/CreateUK8SClusterV2ParamKubeProxy.php rename to src/UK8S/Models/CreateUK8SClusterV2RequestKubeProxy.php index 1a8a5400..062847af 100644 --- a/src/UK8S/Params/CreateUK8SClusterV2ParamKubeProxy.php +++ b/src/UK8S/Models/CreateUK8SClusterV2RequestKubeProxy.php @@ -1,6 +1,7 @@ set("Mode", $mode); } diff --git a/src/UK8S/Params/CreateUK8SClusterV2ParamMaster.php b/src/UK8S/Models/CreateUK8SClusterV2RequestMaster.php similarity index 82% rename from src/UK8S/Params/CreateUK8SClusterV2ParamMaster.php rename to src/UK8S/Models/CreateUK8SClusterV2RequestMaster.php index e31ce418..973459a2 100644 --- a/src/UK8S/Params/CreateUK8SClusterV2ParamMaster.php +++ b/src/UK8S/Models/CreateUK8SClusterV2RequestMaster.php @@ -1,6 +1,7 @@ set("Zone", $zone); } diff --git a/src/UK8S/Params/CreateUK8SClusterV2ParamNodes.php b/src/UK8S/Models/CreateUK8SClusterV2RequestNodes.php similarity index 89% rename from src/UK8S/Params/CreateUK8SClusterV2ParamNodes.php rename to src/UK8S/Models/CreateUK8SClusterV2RequestNodes.php index cc93956b..65048b3d 100644 --- a/src/UK8S/Params/CreateUK8SClusterV2ParamNodes.php +++ b/src/UK8S/Models/CreateUK8SClusterV2RequestNodes.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * MachineType: 一组Nodes节点云主机机型,如["N", "C", "O", "OS"],具体请参照云主机机型。 * @@ -57,11 +59,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * CPU: 一组Node节点的虚拟CPU核数。单位:核,范围:[2, 64],可选范围参考控制台。 * @@ -77,11 +78,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Mem: 一组Node节点的内存大小。单位:MB,范围 :[4096, 262144],取值为1024的倍数,可选范围参考控制台。 * @@ -97,11 +97,10 @@ public function getMem() * * @param int $mem */ - public function setMem($mem) + public function setMem(int $mem) { $this->set("Mem", $mem); } - /** * Count: 一组Node节点的数量,范围:[1,10]。 * @@ -117,11 +116,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * IsolationGroup: 一组Node节点的隔离组Id,归属于同一隔离组的虚拟机节点将落在不同的物理机上,单个隔离组最多只能容纳8个节点。参见DescribeIsolationGroup。 * @@ -137,11 +135,10 @@ public function getIsolationGroup() * * @param string $isolationGroup */ - public function setIsolationGroup($isolationGroup) + public function setIsolationGroup(string $isolationGroup) { $this->set("IsolationGroup", $isolationGroup); } - /** * MaxPods: Node节点上可运行最大节点数,默认为110。 * @@ -157,11 +154,10 @@ public function getMaxPods() * * @param int $maxPods */ - public function setMaxPods($maxPods) + public function setMaxPods(int $maxPods) { $this->set("MaxPods", $maxPods); } - /** * Labels: Node节点标签,形式为key=value,多组Labels用”,“隔开,最多支持五组。 * @@ -177,11 +173,10 @@ public function getLabels() * * @param string $labels */ - public function setLabels($labels) + public function setLabels(string $labels) { $this->set("Labels", $labels); } - /** * BootDiskType: 一组Node节点的系统盘类型,请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -197,11 +192,10 @@ public function getBootDiskType() * * @param string $bootDiskType */ - public function setBootDiskType($bootDiskType) + public function setBootDiskType(string $bootDiskType) { $this->set("BootDiskType", $bootDiskType); } - /** * DataDiskType: 一组Node节点的数据盘类型,请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 * @@ -217,11 +211,10 @@ public function getDataDiskType() * * @param string $dataDiskType */ - public function setDataDiskType($dataDiskType) + public function setDataDiskType(string $dataDiskType) { $this->set("DataDiskType", $dataDiskType); } - /** * MinmalCpuPlatform: Node节点的最低cpu平台,不选则随机。枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake"。 * @@ -237,11 +230,10 @@ public function getMinmalCpuPlatform() * * @param string $minmalCpuPlatform */ - public function setMinmalCpuPlatform($minmalCpuPlatform) + public function setMinmalCpuPlatform(string $minmalCpuPlatform) { $this->set("MinmalCpuPlatform", $minmalCpuPlatform); } - /** * GpuType: 一组Node节点的GPU类型,枚举值["K80", "P40", "V100"],最新值参考Console。 * @@ -257,11 +249,10 @@ public function getGpuType() * * @param string $gpuType */ - public function setGpuType($gpuType) + public function setGpuType(string $gpuType) { $this->set("GpuType", $gpuType); } - /** * GPU: 一组Node节点的GPU卡核心数,仅GPU机型支持此字段。 * @@ -277,11 +268,10 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } - /** * DataDiskSize: 数据磁盘大小,单位GB。默认0。范围 :[20, 1000] * @@ -297,7 +287,7 @@ public function getDataDiskSize() * * @param int $dataDiskSize */ - public function setDataDiskSize($dataDiskSize) + public function setDataDiskSize(int $dataDiskSize) { $this->set("DataDiskSize", $dataDiskSize); } diff --git a/src/UK8S/Models/DiskSet.php b/src/UK8S/Models/DiskSet.php new file mode 100644 index 00000000..e4301327 --- /dev/null +++ b/src/UK8S/Models/DiskSet.php @@ -0,0 +1,220 @@ +get("Type"); + } + + /** + * Type: 磁盘类型。系统盘: Boot,数据盘: Data,网络盘:Udisk + * + * @param string $type + */ + public function setType(string $type) + { + $this->set("Type", $type); + } + /** + * DiskId: 磁盘长ID + * + * @return string|null + */ + public function getDiskId() + { + return $this->get("DiskId"); + } + + /** + * DiskId: 磁盘长ID + * + * @param string $diskId + */ + public function setDiskId(string $diskId) + { + $this->set("DiskId", $diskId); + } + /** + * Name: UDisk名字(仅当磁盘是UDisk时返回) + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: UDisk名字(仅当磁盘是UDisk时返回) + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * Drive: 磁盘盘符 + * + * @return string|null + */ + public function getDrive() + { + return $this->get("Drive"); + } + + /** + * Drive: 磁盘盘符 + * + * @param string $drive + */ + public function setDrive(string $drive) + { + $this->set("Drive", $drive); + } + /** + * Size: 磁盘大小,单位: GB + * + * @return integer|null + */ + public function getSize() + { + return $this->get("Size"); + } + + /** + * Size: 磁盘大小,单位: GB + * + * @param int $size + */ + public function setSize(int $size) + { + $this->set("Size", $size); + } + /** + * BackupType: 备份方案,枚举类型:BASIC_SNAPSHOT,普通快照;DATAARK,方舟。无快照则不返回该字段。 + * + * @return string|null + */ + public function getBackupType() + { + return $this->get("BackupType"); + } + + /** + * BackupType: 备份方案,枚举类型:BASIC_SNAPSHOT,普通快照;DATAARK,方舟。无快照则不返回该字段。 + * + * @param string $backupType + */ + public function setBackupType(string $backupType) + { + $this->set("BackupType", $backupType); + } + /** + * IOPS: 当前主机的IOPS值 + * + * @return integer|null + */ + public function getIOPS() + { + return $this->get("IOPS"); + } + + /** + * IOPS: 当前主机的IOPS值 + * + * @param int $iops + */ + public function setIOPS(int $iops) + { + $this->set("IOPS", $iops); + } + /** + * Encrypted: Yes: 加密 No: 非加密 + * + * @return string|null + */ + public function getEncrypted() + { + return $this->get("Encrypted"); + } + + /** + * Encrypted: Yes: 加密 No: 非加密 + * + * @param string $encrypted + */ + public function setEncrypted(string $encrypted) + { + $this->set("Encrypted", $encrypted); + } + /** + * DiskType: LOCAL_NOMAL| CLOUD_NORMAL| LOCAL_SSD| CLOUD_SSD|EXCLUSIVE_LOCAL_DISK + * + * @return string|null + */ + public function getDiskType() + { + return $this->get("DiskType"); + } + + /** + * DiskType: LOCAL_NOMAL| CLOUD_NORMAL| LOCAL_SSD| CLOUD_SSD|EXCLUSIVE_LOCAL_DISK + * + * @param string $diskType + */ + public function setDiskType(string $diskType) + { + $this->set("DiskType", $diskType); + } + /** + * IsBoot: True| False + * + * @return string|null + */ + public function getIsBoot() + { + return $this->get("IsBoot"); + } + + /** + * IsBoot: True| False + * + * @param string $isBoot + */ + public function setIsBoot(string $isBoot) + { + $this->set("IsBoot", $isBoot); + } +} diff --git a/src/UK8S/Models/IPSet.php b/src/UK8S/Models/IPSet.php new file mode 100644 index 00000000..012d54e5 --- /dev/null +++ b/src/UK8S/Models/IPSet.php @@ -0,0 +1,125 @@ +get("Type"); + } + + /** + * Type: 国际: Internation,BGP: Bgp,内网: Private + * + * @param string $type + */ + public function setType(string $type) + { + $this->set("Type", $type); + } + /** + * IPId: IP资源ID (内网IP无对应的资源ID) + * + * @return string|null + */ + public function getIPId() + { + return $this->get("IPId"); + } + + /** + * IPId: IP资源ID (内网IP无对应的资源ID) + * + * @param string $ipId + */ + public function setIPId(string $ipId) + { + $this->set("IPId", $ipId); + } + /** + * IP: IP地址 + * + * @return string|null + */ + public function getIP() + { + return $this->get("IP"); + } + + /** + * IP: IP地址 + * + * @param string $ip + */ + public function setIP(string $ip) + { + $this->set("IP", $ip); + } + /** + * Bandwidth: IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) + * + * @return integer|null + */ + public function getBandwidth() + { + return $this->get("Bandwidth"); + } + + /** + * Bandwidth: IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) + * + * @param int $bandwidth + */ + public function setBandwidth(int $bandwidth) + { + $this->set("Bandwidth", $bandwidth); + } + /** + * Default: 是否默认的弹性网卡的信息。true: 是默认弹性网卡;其他值:不是。 + * + * @return string|null + */ + public function getDefault() + { + return $this->get("Default"); + } + + /** + * Default: 是否默认的弹性网卡的信息。true: 是默认弹性网卡;其他值:不是。 + * + * @param string $default + */ + public function setDefault(string $default) + { + $this->set("Default", $default); + } +} diff --git a/src/UK8S/Models/ImageInfo.php b/src/UK8S/Models/ImageInfo.php index ef07f86e..db90e0d5 100644 --- a/src/UK8S/Models/ImageInfo.php +++ b/src/UK8S/Models/ImageInfo.php @@ -1,6 +1,7 @@ set("ZoneId", $zoneId); } - /** * ImageId: 镜像 Id * @@ -57,11 +59,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * ImageName: 镜像名称 * @@ -77,11 +78,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * NotSupportGPU: 该镜像是否支持GPU机型,枚举值[true:不支持,false:支持]。 * @@ -97,7 +97,7 @@ public function getNotSupportGPU() * * @param boolean $notSupportGPU */ - public function setNotSupportGPU($notSupportGPU) + public function setNotSupportGPU(bool $notSupportGPU) { $this->set("NotSupportGPU", $notSupportGPU); } diff --git a/src/UK8S/Models/K8SNodeCondition.php b/src/UK8S/Models/K8SNodeCondition.php index e13b9c1a..ce9864a2 100644 --- a/src/UK8S/Models/K8SNodeCondition.php +++ b/src/UK8S/Models/K8SNodeCondition.php @@ -1,6 +1,7 @@ set("Type", $type); } - /** * Status: 状态,False、True * @@ -57,11 +59,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * LastProbeTime: 最后一次上报状态的时间 * @@ -77,11 +78,10 @@ public function getLastProbeTime() * * @param string $lastProbeTime */ - public function setLastProbeTime($lastProbeTime) + public function setLastProbeTime(string $lastProbeTime) { $this->set("LastProbeTime", $lastProbeTime); } - /** * LastTransitionTime: 最后一次状态转变时间 * @@ -97,11 +97,10 @@ public function getLastTransitionTime() * * @param string $lastTransitionTime */ - public function setLastTransitionTime($lastTransitionTime) + public function setLastTransitionTime(string $lastTransitionTime) { $this->set("LastTransitionTime", $lastTransitionTime); } - /** * Reason: 状态变化的原因 * @@ -117,11 +116,10 @@ public function getReason() * * @param string $reason */ - public function setReason($reason) + public function setReason(string $reason) { $this->set("Reason", $reason); } - /** * Message: 状态变化的描述信息 * @@ -137,7 +135,7 @@ public function getMessage() * * @param string $message */ - public function setMessage($message) + public function setMessage(string $message) { $this->set("Message", $message); } diff --git a/src/UK8S/Models/KubeProxy.php b/src/UK8S/Models/KubeProxy.php index 28c696ef..6d944253 100644 --- a/src/UK8S/Models/KubeProxy.php +++ b/src/UK8S/Models/KubeProxy.php @@ -1,6 +1,7 @@ set("Mode", $mode); } diff --git a/src/UK8S/Models/NodeGroupSet.php b/src/UK8S/Models/NodeGroupSet.php new file mode 100644 index 00000000..39254192 --- /dev/null +++ b/src/UK8S/Models/NodeGroupSet.php @@ -0,0 +1,313 @@ +get("NodeGroupId"); + } + + /** + * NodeGroupId: 节点池ID + * + * @param string $nodeGroupId + */ + public function setNodeGroupId(string $nodeGroupId) + { + $this->set("NodeGroupId", $nodeGroupId); + } + /** + * NodeGroupName: 节点池名字 + * + * @return string|null + */ + public function getNodeGroupName() + { + return $this->get("NodeGroupName"); + } + + /** + * NodeGroupName: 节点池名字 + * + * @param string $nodeGroupName + */ + public function setNodeGroupName(string $nodeGroupName) + { + $this->set("NodeGroupName", $nodeGroupName); + } + /** + * ImageId: 镜像ID + * + * @return string|null + */ + public function getImageId() + { + return $this->get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } + /** + * MachineType: 机型 + * + * @return string|null + */ + public function getMachineType() + { + return $this->get("MachineType"); + } + + /** + * MachineType: 机型 + * + * @param string $machineType + */ + public function setMachineType(string $machineType) + { + $this->set("MachineType", $machineType); + } + /** + * MinimalCpuPlatform: cpu平台 + * + * @return string|null + */ + public function getMinimalCpuPlatform() + { + return $this->get("MinimalCpuPlatform"); + } + + /** + * MinimalCpuPlatform: cpu平台 + * + * @param string $minimalCpuPlatform + */ + public function setMinimalCpuPlatform(string $minimalCpuPlatform) + { + $this->set("MinimalCpuPlatform", $minimalCpuPlatform); + } + /** + * CPU: 虚拟CPU核数 + * + * @return integer|null + */ + public function getCPU() + { + return $this->get("CPU"); + } + + /** + * CPU: 虚拟CPU核数 + * + * @param int $cpu + */ + public function setCPU(int $cpu) + { + $this->set("CPU", $cpu); + } + /** + * Mem: 内存大小 + * + * @return integer|null + */ + public function getMem() + { + return $this->get("Mem"); + } + + /** + * Mem: 内存大小 + * + * @param int $mem + */ + public function setMem(int $mem) + { + $this->set("Mem", $mem); + } + /** + * GpuType: GPU类型 + * + * @return string|null + */ + public function getGpuType() + { + return $this->get("GpuType"); + } + + /** + * GpuType: GPU类型 + * + * @param string $gpuType + */ + public function setGpuType(string $gpuType) + { + $this->set("GpuType", $gpuType); + } + /** + * GPU: GPU卡核心数 + * + * @return integer|null + */ + public function getGPU() + { + return $this->get("GPU"); + } + + /** + * GPU: GPU卡核心数 + * + * @param int $gpu + */ + public function setGPU(int $gpu) + { + $this->set("GPU", $gpu); + } + /** + * BootDiskType: 系统盘类型 + * + * @return string|null + */ + public function getBootDiskType() + { + return $this->get("BootDiskType"); + } + + /** + * BootDiskType: 系统盘类型 + * + * @param string $bootDiskType + */ + public function setBootDiskType(string $bootDiskType) + { + $this->set("BootDiskType", $bootDiskType); + } + /** + * DataDiskSize: 数据盘大小 + * + * @return integer|null + */ + public function getDataDiskSize() + { + return $this->get("DataDiskSize"); + } + + /** + * DataDiskSize: 数据盘大小 + * + * @param int $dataDiskSize + */ + public function setDataDiskSize(int $dataDiskSize) + { + $this->set("DataDiskSize", $dataDiskSize); + } + /** + * DataDiskType: 数据盘类型 + * + * @return string|null + */ + public function getDataDiskType() + { + return $this->get("DataDiskType"); + } + + /** + * DataDiskType: 数据盘类型 + * + * @param string $dataDiskType + */ + public function setDataDiskType(string $dataDiskType) + { + $this->set("DataDiskType", $dataDiskType); + } + /** + * Tag: 业务组 + * + * @return string|null + */ + public function getTag() + { + return $this->get("Tag"); + } + + /** + * Tag: 业务组 + * + * @param string $tag + */ + public function setTag(string $tag) + { + $this->set("Tag", $tag); + } + /** + * ChargeType: 付费方式 + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 付费方式 + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * NodeList: 节点id列表 + * + * @return string[]|null + */ + public function getNodeList() + { + return $this->get("NodeList"); + } + + /** + * NodeList: 节点id列表 + * + * @param string[] $nodeList + */ + public function setNodeList(array $nodeList) + { + $this->set("NodeList", $nodeList); + } +} diff --git a/src/UK8S/Models/NodeInfoV2.php b/src/UK8S/Models/NodeInfoV2.php index c81d9e61..69891226 100644 --- a/src/UK8S/Models/NodeInfoV2.php +++ b/src/UK8S/Models/NodeInfoV2.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * NodeId: NodeId,Node在UK8S处的唯一标示,如uk8s-reewqe5-sdasadsda * @@ -57,11 +61,10 @@ public function getNodeId() * * @param string $nodeId */ - public function setNodeId($nodeId) + public function setNodeId(string $nodeId) { $this->set("NodeId", $nodeId); } - /** * NodeRole: node角色,枚举值为master、node * @@ -77,11 +80,10 @@ public function getNodeRole() * * @param string $nodeRole */ - public function setNodeRole($nodeRole) + public function setNodeRole(string $nodeRole) { $this->set("NodeRole", $nodeRole); } - /** * NodeStatus: Node的状态:枚举值:初始化:"Initializing";启动中:"Starting";运行:"Running";停止中:"Stopping";停止:"Stopped";待删除:"ToBeDeleted";删除中:"Deleting";异常:"Error";安装失败:"Install Fail"; * @@ -97,11 +99,10 @@ public function getNodeStatus() * * @param string $nodeStatus */ - public function setNodeStatus($nodeStatus) + public function setNodeStatus(string $nodeStatus) { $this->set("NodeStatus", $nodeStatus); } - /** * InstanceType: Node节点的资源类型,枚举值为UHost或UPHost。 * @@ -117,11 +118,10 @@ public function getInstanceType() * * @param string $instanceType */ - public function setInstanceType($instanceType) + public function setInstanceType(string $instanceType) { $this->set("InstanceType", $instanceType); } - /** * InstanceName: 资源名称,初始值等于NodeId,用户可在UHost或UPHost处修改。 * @@ -137,11 +137,10 @@ public function getInstanceName() * * @param string $instanceName */ - public function setInstanceName($instanceName) + public function setInstanceName(string $instanceName) { $this->set("InstanceName", $instanceName); } - /** * InstanceId: 资源ID,如uhost-xxxx,或uphost-xxxxx。 * @@ -157,11 +156,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * MachineType: 机型类别,分别对应Uhost的MachineType或PHost的PHostType。 * @@ -177,11 +175,10 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } - /** * OsType: Node节点的操作系统类别,如Linux或Windows。 * @@ -197,11 +194,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * OsName: Node节点的镜像名称。 * @@ -217,11 +213,10 @@ public function getOsName() * * @param string $osName */ - public function setOsName($osName) + public function setOsName(string $osName) { $this->set("OsName", $osName); } - /** * CPU: Node节点CPU核数,单位: 个。 * @@ -237,11 +232,10 @@ public function getCPU() * * @param int $cpu */ - public function setCPU($cpu) + public function setCPU(int $cpu) { $this->set("CPU", $cpu); } - /** * Memory: 内存大小,单位: MB。 * @@ -257,15 +251,14 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * IPSet: 节点IP信息,详细信息见 UHostIPSet。 * - * @return UHostIPSet[]|null + * @return UHostIPSetModel[]|null */ public function getIPSet() { @@ -275,7 +268,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UHostIPSet($item)); + array_push($result, new UHostIPSetModel($item)); } return $result; } @@ -283,7 +276,7 @@ public function getIPSet() /** * IPSet: 节点IP信息,详细信息见 UHostIPSet。 * - * @param UHostIPSet[] $ipSet + * @param UHostIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -293,7 +286,6 @@ public function setIPSet(array $ipSet) } return $result; } - /** * CreateTime: 节点创建时间 * @@ -309,11 +301,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 节点计费到期时间 * @@ -329,11 +320,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * AsgId: 节点所属伸缩组ID,非伸缩组创建出来的节点,伸缩组ID为Default。 * @@ -349,11 +339,10 @@ public function getAsgId() * * @param string $asgId */ - public function setAsgId($asgId) + public function setAsgId(string $asgId) { $this->set("AsgId", $asgId); } - /** * Unschedulable: 是否允许Pod调度到该节点,枚举值为true或false。 * @@ -369,31 +358,29 @@ public function getUnschedulable() * * @param boolean $unschedulable */ - public function setUnschedulable($unschedulable) + public function setUnschedulable(bool $unschedulable) { $this->set("Unschedulable", $unschedulable); } - /** * KubeProxy: kubeproxy信息,详细信息见KubeProxy。 * - * @return KubeProxy|null + * @return KubeProxyModel|null */ public function getKubeProxy() { - return new KubeProxy($this->get("KubeProxy")); + return new KubeProxyModel($this->get("KubeProxy")); } /** * KubeProxy: kubeproxy信息,详细信息见KubeProxy。 * - * @param KubeProxy $kubeProxy + * @param KubeProxyModel $kubeProxy */ - public function setKubeProxy(array $kubeProxy) + public function setKubeProxy(KubeProxyModel $kubeProxy) { $this->set("KubeProxy", $kubeProxy->getAll()); } - /** * NodeLogInfo: 加节点时判断是否没有资源,如果返回NORESOURCE则代表没有资源了 * @@ -409,11 +396,10 @@ public function getNodeLogInfo() * * @param string $nodeLogInfo */ - public function setNodeLogInfo($nodeLogInfo) + public function setNodeLogInfo(string $nodeLogInfo) { $this->set("NodeLogInfo", $nodeLogInfo); } - /** * GPU: 节点的GPU颗数。 * @@ -429,7 +415,7 @@ public function getGPU() * * @param int $gpu */ - public function setGPU($gpu) + public function setGPU(int $gpu) { $this->set("GPU", $gpu); } diff --git a/src/UK8S/Models/UHostIPSet.php b/src/UK8S/Models/UHostIPSet.php index 77595276..08b51706 100644 --- a/src/UK8S/Models/UHostIPSet.php +++ b/src/UK8S/Models/UHostIPSet.php @@ -1,6 +1,7 @@ set("Type", $type); } - /** * IPId: IP资源ID (内网IP无对应的资源ID) * @@ -57,11 +65,10 @@ public function getIPId() * * @param string $ipId */ - public function setIPId($ipId) + public function setIPId(string $ipId) { $this->set("IPId", $ipId); } - /** * IP: IP地址 * @@ -77,11 +84,10 @@ public function getIP() * * @param string $ip */ - public function setIP($ip) + public function setIP(string $ip) { $this->set("IP", $ip); } - /** * Bandwidth: IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) * @@ -97,11 +103,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * VPCId: IP地址对应的VPC ID * @@ -117,11 +122,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: IP地址对应的子网 ID * @@ -137,11 +141,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Mac: Mac地址 * @@ -157,7 +160,7 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } diff --git a/src/UK8S/Models/UhostInfo.php b/src/UK8S/Models/UhostInfo.php new file mode 100644 index 00000000..445acf5e --- /dev/null +++ b/src/UK8S/Models/UhostInfo.php @@ -0,0 +1,283 @@ +get("Zone"); + } + + /** + * Zone: 所在机房 + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * Name: 主机名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 主机名称 + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * CPU: Cpu数量 + * + * @return integer|null + */ + public function getCPU() + { + return $this->get("CPU"); + } + + /** + * CPU: Cpu数量 + * + * @param int $cpu + */ + public function setCPU(int $cpu) + { + $this->set("CPU", $cpu); + } + /** + * Memory: 内存 + * + * @return integer|null + */ + public function getMemory() + { + return $this->get("Memory"); + } + + /** + * Memory: 内存 + * + * @param int $memory + */ + public function setMemory(int $memory) + { + $this->set("Memory", $memory); + } + /** + * IPSet: 节点IP信息 + * + * @return IPSetModel[]|null + */ + public function getIPSet() + { + $items = $this->get("IPSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new IPSetModel($item)); + } + return $result; + } + + /** + * IPSet: 节点IP信息 + * + * @param IPSetModel[] $ipSet + */ + public function setIPSet(array $ipSet) + { + $result = []; + foreach ($ipSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * DiskSet: 节点磁盘信息 + * + * @return DiskSetModel[]|null + */ + public function getDiskSet() + { + $items = $this->get("DiskSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new DiskSetModel($item)); + } + return $result; + } + + /** + * DiskSet: 节点磁盘信息 + * + * @param DiskSetModel[] $diskSet + */ + public function setDiskSet(array $diskSet) + { + $result = []; + foreach ($diskSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * NodeId: 主机ID + * + * @return string|null + */ + public function getNodeId() + { + return $this->get("NodeId"); + } + + /** + * NodeId: 主机ID + * + * @param string $nodeId + */ + public function setNodeId(string $nodeId) + { + $this->set("NodeId", $nodeId); + } + /** + * OsName: 镜像信息 + * + * @return string|null + */ + public function getOsName() + { + return $this->get("OsName"); + } + + /** + * OsName: 镜像信息 + * + * @param string $osName + */ + public function setOsName(string $osName) + { + $this->set("OsName", $osName); + } + /** + * CreateTime: 创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * ExpireTime: 到期时间 + * + * @return integer|null + */ + public function getExpireTime() + { + return $this->get("ExpireTime"); + } + + /** + * ExpireTime: 到期时间 + * + * @param int $expireTime + */ + public function setExpireTime(int $expireTime) + { + $this->set("ExpireTime", $expireTime); + } + /** + * State: 主机状态 + * + * @return string|null + */ + public function getState() + { + return $this->get("State"); + } + + /** + * State: 主机状态 + * + * @param string $state + */ + public function setState(string $state) + { + $this->set("State", $state); + } + /** + * NodeType: 节点类型:uhost表示云主机;uphost表示物理云主机 + * + * @return string|null + */ + public function getNodeType() + { + return $this->get("NodeType"); + } + + /** + * NodeType: 节点类型:uhost表示云主机;uphost表示物理云主机 + * + * @param string $nodeType + */ + public function setNodeType(string $nodeType) + { + $this->set("NodeType", $nodeType); + } +} diff --git a/src/UK8S/UK8SClient.php b/src/UK8S/UK8SClient.php index b52cbca5..9b42d206 100644 --- a/src/UK8S/UK8SClient.php +++ b/src/UK8S/UK8SClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Password" => (string) Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 - * "ClusterId" => (string) UK8S集群ID。 可从UK8S控制台获取。 - * "UHostId" => (string) 云主机Id,为了保证节点正常运行,该主机配置不得低于2C4G。 - * "MaxPods" => (integer) 默认110,生产环境建议小于等于110。 - * "Labels" => (string) Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game - * "SubnetId" => (string) 该云主机所属子网Id。 - * "ImageId" => (string) 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 - * "DisableSchedule" => (boolean) 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 - * "UserData" => (string) 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码。 - * "InitScript" => (string) 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行,UserData则是云主机初始化时执行。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddUK8SExistingUHostResponse * @throws UCloudException */ public function addUK8SExistingUHost(AddUK8SExistingUHostRequest $request = null) @@ -81,40 +111,27 @@ public function addUK8SExistingUHost(AddUK8SExistingUHostRequest $request = null $resp = $this->invoke($request); return new AddUK8SExistingUHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * AddUK8SPHostNode - 为UK8S集群添加一台或多台物理云主机类型的节点。 - * - * See also: https://docs.ucloud.cn/api/uk8s-api/add_uk8s_phost_node + * AddUK8SNodeGroup - 添加UK8S节点池 * - * Arguments: - * - * $args = [ - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ClusterId" => (string) UK8S集群ID。 可从UK8S控制台获取。 - * "Count" => (integer) 最大创建Node节点数量,取值范围是[1,10]。 - * "Password" => (string) Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ 默认为月付 - * "Quantity" => (integer) 购买时长。默认: 1。月付时,此参数传0,代表了购买至月末。 - * "Labels" => (string) Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game - * "MaxPods" => (integer) 默认110,生产环境建议小于等于110。 - * "Type" => (string) 物理机类型,默认为:db-2(基础型-SAS-V3) - * "Raid" => (string) Raid配置,默认Raid10 支持:Raid0、Raid1、Raid5、Raid10,NoRaid - * "NIC" => (string) 网络环境,可选千兆:1G ,万兆:10G, 默认1G。 - * "SubnetId" => (string) 子网 ID。默认为集群创建时填写的子网ID,也可以填写集群同VPC内的子网ID。 - * "ImageId" => (string) 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 - * "DisableSchedule" => (boolean) 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 - * "InitScript" => (string) 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function addUK8SNodeGroup(AddUK8SNodeGroupRequest $request = null) + { + $resp = $this->invoke($request); + return new AddUK8SNodeGroupResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AddUK8SPHostNode - 为UK8S集群添加一台或多台物理云主机类型的节点。 * - * @return AddUK8SPHostNodeResponse * @throws UCloudException */ public function addUK8SPHostNode(AddUK8SPHostNodeRequest $request = null) @@ -122,49 +139,13 @@ public function addUK8SPHostNode(AddUK8SPHostNodeRequest $request = null) $resp = $this->invoke($request); return new AddUK8SPHostNodeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * AddUK8SUHostNode - 为UK8S集群添加一台Node节点,机型类型为云主机 * - * See also: https://docs.ucloud.cn/api/uk8s-api/add_uk8s_uhost_node - * - * Arguments: - * - * $args = [ - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ClusterId" => (string) UK8S集群ID。 可从UK8S控制台获取。 - * "CPU" => (integer) 虚拟CPU核数。可选参数:2-64(具体机型与CPU的对应关系参照控制台)。默认值: 4。 - * "Count" => (integer) 创建Node节点数量,取值范围是[1,50]。 - * "Password" => (string) Node节点密码。请遵照[[api:uhost-api:specification|字段规范]]设定密码。密码需使用base64进行编码,如下:# echo -n Password1 | base64 - * "Mem" => (integer) 内存大小。单位:MB。范围 :[4096, 262144],取值为1024的倍数(可选范围参考控制台)。默认值:8192 - * "ChargeType" => (string) 计费模式。枚举值为: \\ > Year,按年付费; \\ > Month,按月付费;\\ > Dynamic,按小时预付费 \\ > Postpay,按小时后付费(支持关机不收费,目前仅部分可用区支持,请联系您的客户经理) \\ 默认为月付 - * "BootDiskType" => (string) 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "DataDiskType" => (string) 磁盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "DataDiskSize" => (integer) 数据磁盘大小,单位GB。默认0。范围 :[20, 1000] - * "Quantity" => (integer) 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 - * "MachineType" => (string) 云主机机型。枚举值["N", "C", "G", "O", "OS"]。参考[[api:uhost-api:uhost_type|云主机机型说明]]。 - * "MinmalCpuPlatform" => (string) 最低cpu平台,枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake";"Intel/CascadelakeR"; “Amd/Epyc2”,"Amd/Auto"],默认值是"Intel/Auto" - * "GpuType" => (string) GPU类型,枚举值["K80", "P40", "V100",],MachineType为G时必填 - * "GPU" => (integer) GPU卡核心数。仅GPU机型支持此字段(可选范围与MachineType+GpuType相关) - * "Labels" => (string) Node节点标签。key=value形式,多组用”,“隔开,最多5组。 如env=pro,type=game - * "MaxPods" => (integer) 默认110,生产环境建议小于等于110。 - * "IsolationGroup" => (string) 硬件隔离组id。可通过DescribeIsolationGroup获取。 - * "ImageId" => (string) 镜像 Id,不填时后台程序会自动选用一个可用的镜像 Id,支持用户自定义镜像,自定义镜像必须基于基础镜像制作。 - * "SubnetId" => (string) 子网 ID。默认为集群创建时填写的子网ID,也可以填写集群同VPC内的子网ID。 - * "DisableSchedule" => (boolean) 用于标示添加完节点后是否将节点临时禁用. 传入 "true" 表示禁用,传入其它或不传表示不禁用 - * "UserData" => (string) 用户自定义数据。当镜像支持Cloud-init Feature时可填写此字段。注意:1、总数据量大小不超过 16K;2、使用base64编码。 - * "InitScript" => (string) 用户自定义Shell脚本。与UserData的区别在于InitScript在节点初始化完毕后才执行,UserData则是云主机初始化时执行。 - * ] - * - * Outputs: - * - * $outputs = [ - * "NodeIds" => (array) Node实例Id集合 - * ] - * - * @return AddUK8SUHostNodeResponse * @throws UCloudException */ public function addUK8SUHostNode(AddUK8SUHostNodeRequest $request = null) @@ -172,72 +153,13 @@ public function addUK8SUHostNode(AddUK8SUHostNodeRequest $request = null) $resp = $this->invoke($request); return new AddUK8SUHostNodeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUK8SClusterV2 - 创建UK8S集群 * - * See also: https://docs.ucloud.cn/api/uk8s-api/create_uk8s_cluster_v2 - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 集群Node及Pod所属VPC - * "SubnetId" => (string) 集群Node及Pod所属子网 - * "ServiceCIDR" => (string) Service 网段,用于分配ClusterIP,如172.17.0.0/16。该网段不能与集群所属VPC网段重叠。 - * "ClusterName" => (string) 集群名称 - * "Password" => (string) 集群节点密码,包括Master和Node。密码需包含最少一个大写字母,请使用base64进行编码,举例如下:# echo -n Password1 | base64 - * "Master" => (array) [ - * [ - * "Zone" => (string) Master节点所属可用区,需要设置 Master.0.Zone、 Master.1.Zone、Master.2.Zone 三个 Master 节点的可用区。 三个节点可部署在不同可用区。参见 [可用区列表](../summary/regionlist.html) - * ] - * ] - * "MasterMachineType" => (string) Master节点的云主机机型(V2.0),如["N", "C", "O", "OS"],具体请参照云主机机型。 - * "MasterCPU" => (integer) Master节点的虚拟CPU核数。可选参数:2-64(具体机型与CPU的对应关系参照控制台)。 - * "MasterMem" => (integer) Master节点的内存大小。单位:MB。范围 :[4096, 262144],取值为1024的倍数(可选范围参考控制台)。 - * "Nodes" => (array) [ - * [ - * "Zone" => (string) 一组Nodes节点所属可用区,可创建多组Nodes节点,如一组是CPU Nodes节点,另一组是GPU Nodes节点。参见 [可用区列表](../summary/regionlist.html) - * "MachineType" => (string) 一组Nodes节点云主机机型,如["N", "C", "O", "OS"],具体请参照云主机机型。 - * "CPU" => (integer) 一组Node节点的虚拟CPU核数。单位:核,范围:[2, 64],可选范围参考控制台。 - * "Mem" => (integer) 一组Node节点的内存大小。单位:MB,范围 :[4096, 262144],取值为1024的倍数,可选范围参考控制台。 - * "Count" => (integer) 一组Node节点的数量,范围:[1,10]。 - * "IsolationGroup" => (string) 一组Node节点的隔离组Id,归属于同一隔离组的虚拟机节点将落在不同的物理机上,单个隔离组最多只能容纳8个节点。参见DescribeIsolationGroup。 - * "MaxPods" => (integer) Node节点上可运行最大节点数,默认为110。 - * "Labels" => (string) Node节点标签,形式为key=value,多组Labels用”,“隔开,最多支持五组。 - * "BootDiskType" => (string) 一组Node节点的系统盘类型,请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "DataDiskType" => (string) 一组Node节点的数据盘类型,请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "MinmalCpuPlatform" => (string) Node节点的最低cpu平台,不选则随机。枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake"。 - * "GpuType" => (string) 一组Node节点的GPU类型,枚举值["K80", "P40", "V100"],最新值参考Console。 - * "GPU" => (integer) 一组Node节点的GPU卡核心数,仅GPU机型支持此字段。 - * "DataDiskSize" => (integer) 数据磁盘大小,单位GB。默认0。范围 :[20, 1000] - * ] - * ] - * "MasterBootDiskType" => (string) Master节点系统盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "MasterDataDiskType" => (string) Master节点数据盘类型。请参考[[api:uhost-api:disk_type|磁盘类型]]。默认为SSD云盘 - * "MasterMinmalCpuPlatform" => (string) Master节点的最低cpu平台,不选则随机。枚举值["Intel/Auto", "Intel/IvyBridge", "Intel/Haswell", "Intel/Broadwell", "Intel/Skylake", "Intel/Cascadelake"。 - * "MasterDataDiskSize" => (integer) Master节点的数据盘大小,单位GB,默认为0。范围 :[20, 1000] - * "ChargeType" => (string) 集群所有节点的付费模式。枚举值为: Year,按年付费; Month,按月付费; Dynamic,按小时付费(需开启权限),默认按月。 - * "K8sVersion" => (string) k8s集群的版本,版本信息请参考UK8S集群创建页,不指定的话默认为当前支持的最高版本。 - * "Quantity" => (integer) 购买时长。默认为1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末。 - * "ExternalApiServer" => (string) 是否允许外网访问apiserver,开启:Yes 不开启:No。默认为No。 - * "MasterIsolationGroup" => (string) 【无效,已删除】当前将自动为Master节点创建隔离组,确保Master节点归属于不同物理机。 - * "KubeProxy" => (object) [ - * "Mode" => (string) 集群kube-proxy模式。支持iptables和ipvs,默认为iptables。 - * ] - * "ImageId" => (string) Master节点和Node节点的镜像 ID,不填则随机选择可用的基础镜像。支持用户自定义镜像。 - * "UserData" => (string) 用户自定义数据。注意:1、总数据量大小不超多16K;2、使用base64编码。 - * "InitScript" => (string) 用户自定义脚本,与UserData不同,自定义脚本将在集群安装完毕后执行。注意:1、总数据量大小不超多16K;2、使用base64编码。 - * ] - * - * Outputs: - * - * $outputs = [ - * "ClusterId" => (string) 集群ID - * ] - * - * @return CreateUK8SClusterV2Response * @throws UCloudException */ public function createUK8SClusterV2(CreateUK8SClusterV2Request $request = null) @@ -245,27 +167,13 @@ public function createUK8SClusterV2(CreateUK8SClusterV2Request $request = null) $resp = $this->invoke($request); return new CreateUK8SClusterV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DelUK8SCluster - 删除UK8S集群 * - * See also: https://docs.ucloud.cn/api/uk8s-api/del_uk8s_cluster - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ClusterId" => (string) 集群id - * "ReleaseUDisk" => (boolean) 是否删除节点挂载的数据盘。枚举值[true:删除,false: 不删除],默认不删除 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DelUK8SClusterResponse * @throws UCloudException */ public function delUK8SCluster(DelUK8SClusterRequest $request = null) @@ -273,28 +181,13 @@ public function delUK8SCluster(DelUK8SClusterRequest $request = null) $resp = $this->invoke($request); return new DelUK8SClusterResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DelUK8SClusterNodeV2 - 删除集群中的Node节点,删除前务必先将其中的Pod驱逐。 * - * See also: https://docs.ucloud.cn/api/uk8s-api/del_uk8s_cluster_node_v2 - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ClusterId" => (string) UK8S集群ID。 可从UK8S控制台获取。 - * "NodeId" => (string) Node在UK8S处的唯一标示,如uk8s-reewqe5-sdasadsda。**非云主机或物理云主机资源Id** - * "ReleaseDataUDisk" => (boolean) 删除节点时是否释放数据盘。 枚举值[true:释放,false: 不释放],默认为true。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DelUK8SClusterNodeV2Response * @throws UCloudException */ public function delUK8SClusterNodeV2(DelUK8SClusterNodeV2Request $request = null) @@ -302,42 +195,27 @@ public function delUK8SClusterNodeV2(DelUK8SClusterNodeV2Request $request = null $resp = $this->invoke($request); return new DelUK8SClusterNodeV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DescribeUK8SImage - 获取UK8S支持的Node节点操作系统,可基于该操作系统制定自定义镜像 - * - * See also: https://docs.ucloud.cn/api/uk8s-api/describe_uk8s_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: + * DescribeUK8SCluster - 获取集群信息 * - * $outputs = [ - * "ImageSet" => (array) 虚拟机可用镜像集合, 详见ImageInfo 数组[ - * [ - * "ZoneId" => (integer) 可用区 Id - * "ImageId" => (string) 镜像 Id - * "ImageName" => (string) 镜像名称 - * "NotSupportGPU" => (boolean) 该镜像是否支持GPU机型,枚举值[true:不支持,false:支持]。 - * ] - * ] - * "PHostImageSet" => (array) 物理机可用镜像集合, 详见ImageInfo 数组[ - * [ - * "ZoneId" => (integer) 可用区 Id - * "ImageId" => (string) 镜像 Id - * "ImageName" => (string) 镜像名称 - * "NotSupportGPU" => (boolean) 该镜像是否支持GPU机型,枚举值[true:不支持,false:支持]。 - * ] - * ] - * ] + * @throws UCloudException + */ + public function describeUK8SCluster(DescribeUK8SClusterRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUK8SClusterResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUK8SImage - 获取UK8S支持的Node节点操作系统,可基于该操作系统制定自定义镜像 * - * @return DescribeUK8SImageResponse * @throws UCloudException */ public function describeUK8SImage(DescribeUK8SImageRequest $request = null) @@ -345,64 +223,13 @@ public function describeUK8SImage(DescribeUK8SImageRequest $request = null) $resp = $this->invoke($request); return new DescribeUK8SImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUK8SNode - 用于获取 UK8S 节点详情 * - * See also: https://docs.ucloud.cn/api/uk8s-api/describe_uk8s_node - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ClusterId" => (string) UK8S 集群 Id - * "Name" => (string) K8S 节点IP或者节点ID - * ] - * - * Outputs: - * - * $outputs = [ - * "Name" => (string) 节点名称 - * "Labels" => (array) 字符串数组,每一项是类似 "kubernetes.io/arch=amd64" 的标签 - * "Annotations" => (array) 字符串数组,每一项是类似 "node.alpha.kubernetes.io/ttl=0" 的注解 - * "CreationTimestamp" => (integer) 时间戳,单位是 秒 - * "ProviderID" => (string) 字符串,如:"UCloud://cn-sh2-02//uk8s-vsc0vgob-n-mpzxc" - * "KernelVersion" => (string) 内核版本,如:"4.19.0-6.el7.ucloud.x86_64" - * "OSImage" => (string) 操作系统类型,如:"CentOS Linux 7 (Core)" - * "ContainerRuntimeVersion" => (string) 容器运行时版本,如:"docker://18.9.9" - * "KubeletVersion" => (string) kubelet 版本 - * "KubeProxyVersion" => (string) kubeproxy 版本 - * "InternalIP" => (string) 内部 IP 地址 - * "Hostname" => (string) 主机名 - * "AllocatedPodCount" => (integer) 已分配到当前节点的 Pod 数量 - * "PodCapacity" => (integer) 节点允许的可分配 Pod 最大数量 - * "Unschedulable" => (boolean) 是否禁止调度 - * "CPUCapacity" => (string) 节点 CPU 总量 - * "MemoryCapacity" => (string) 节点内存总量 - * "MemoryRequests" => (string) 节点上已分配 Pod 的内存请求量 - * "MemoryRequestsFraction" => (string) 节点上已分配 Pod 的内存请求量占内存总量的比例,如返回值为 "4.5",则意味着请求量占总量的 4.5% - * "MemoryLimits" => (string) 节点上已分配 Pod 的内存限制量 - * "MemoryLimitsFraction" => (string) 节点上已分配 Pod 的内存限制量占内存总量的比例,如返回值为 "18",则意味着限制量占总量的 18% - * "CPURequests" => (string) 节点上已分配 Pod 的 CPU 请求量 - * "CPURequestsFraction" => (string) 节点上已分配 Pod 的 CPU 请求量占 CPU 总量的比例 - * "CPULimits" => (string) 节点上已分配 Pod 的 CPU 限制值 - * "CPULimitsFraction" => (string) 节点上已分配 Pod 的 CPU 限制值占 CPU 总量的比例 - * "Conditions" => (array) 节点状态数组[ - * [ - * "Type" => (string) Condition 类型,如 MemoryPressure、DiskPressure、PIDPressure、Ready - * "Status" => (string) 状态,False、True - * "LastProbeTime" => (string) 最后一次上报状态的时间 - * "LastTransitionTime" => (string) 最后一次状态转变时间 - * "Reason" => (string) 状态变化的原因 - * "Message" => (string) 状态变化的描述信息 - * ] - * ] - * "ContainerImages" => (array) 节点上镜像名称数组 - * "Taints" => (array) 字符串数组,每一项是类似 "node-role.kubernetes.io/master:NoSchedule" 的污点 - * ] - * - * @return DescribeUK8SNodeResponse * @throws UCloudException */ public function describeUK8SNode(DescribeUK8SNodeRequest $request = null) @@ -410,63 +237,13 @@ public function describeUK8SNode(DescribeUK8SNodeRequest $request = null) $resp = $this->invoke($request); return new DescribeUK8SNodeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ListUK8SClusterNodeV2 - 获取UK8S集群节点信息 * - * See also: https://docs.ucloud.cn/api/uk8s-api/list_uk8s_cluster_node_v2 - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ClusterId" => (string) UK8S集群ID - * ] - * - * Outputs: - * - * $outputs = [ - * "NodeSet" => (array) 节点详细信息,见NodeInfoV2。[ - * [ - * "Zone" => (string) Node所在可用区 - * "NodeId" => (string) NodeId,Node在UK8S处的唯一标示,如uk8s-reewqe5-sdasadsda - * "NodeRole" => (string) node角色,枚举值为master、node - * "NodeStatus" => (string) Node的状态:枚举值:初始化:"Initializing";启动中:"Starting";运行:"Running";停止中:"Stopping";停止:"Stopped";待删除:"ToBeDeleted";删除中:"Deleting";异常:"Error";安装失败:"Install Fail"; - * "InstanceType" => (string) Node节点的资源类型,枚举值为UHost或UPHost。 - * "InstanceName" => (string) 资源名称,初始值等于NodeId,用户可在UHost或UPHost处修改。 - * "InstanceId" => (string) 资源ID,如uhost-xxxx,或uphost-xxxxx。 - * "MachineType" => (string) 机型类别,分别对应Uhost的MachineType或PHost的PHostType。 - * "OsType" => (string) Node节点的操作系统类别,如Linux或Windows。 - * "OsName" => (string) Node节点的镜像名称。 - * "CPU" => (integer) Node节点CPU核数,单位: 个。 - * "Memory" => (integer) 内存大小,单位: MB。 - * "IPSet" => (array) 节点IP信息,详细信息见 UHostIPSet。[ - * [ - * "Type" => (string) 国际: Internation,BGP: Bgp,内网: Private - * "IPId" => (string) IP资源ID (内网IP无对应的资源ID) - * "IP" => (string) IP地址 - * "Bandwidth" => (integer) IP对应的带宽, 单位: Mb (内网IP不显示带宽信息) - * "VPCId" => (string) IP地址对应的VPC ID - * "SubnetId" => (string) IP地址对应的子网 ID - * "Mac" => (string) Mac地址 - * ] - * ] - * "CreateTime" => (integer) 节点创建时间 - * "ExpireTime" => (integer) 节点计费到期时间 - * "AsgId" => (string) 节点所属伸缩组ID,非伸缩组创建出来的节点,伸缩组ID为Default。 - * "Unschedulable" => (boolean) 是否允许Pod调度到该节点,枚举值为true或false。 - * "KubeProxy" => (object) kubeproxy信息,详细信息见KubeProxy。[ - * "Mode" => (string) KubeProxy模式,枚举值为[ipvs,iptables] - * ] - * "NodeLogInfo" => (string) 加节点时判断是否没有资源,如果返回NORESOURCE则代表没有资源了 - * "GPU" => (integer) 节点的GPU颗数。 - * ] - * ] - * "TotalCount" => (integer) 满足条件的节点数量,包括Master。 - * ] - * - * @return ListUK8SClusterNodeV2Response * @throws UCloudException */ public function listUK8SClusterNodeV2(ListUK8SClusterNodeV2Request $request = null) @@ -474,47 +251,13 @@ public function listUK8SClusterNodeV2(ListUK8SClusterNodeV2Request $request = nu $resp = $this->invoke($request); return new ListUK8SClusterNodeV2Response($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ListUK8SClusterV2 - 获取UK8S集群列表信息 * - * See also: https://docs.ucloud.cn/api/uk8s-api/list_uk8s_cluster_v2 - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 列表起始位置偏移量,默认为0。 - * "Limit" => (integer) 返回数据长度,默认为20。 - * "ClusterId" => (string) UK8S集群ID - * ] - * - * Outputs: - * - * $outputs = [ - * "ClusterCount" => (integer) 满足条件的集群数量 - * "ClusterSet" => (array) 集群信息,具体参考ClusterSet[ - * [ - * "ClusterName" => (string) 资源名字 - * "ClusterId" => (string) 集群ID - * "VPCId" => (string) 所属VPC - * "SubnetId" => (string) 所属子网 - * "PodCIDR" => (string) Pod网段 - * "ServiceCIDR" => (string) 服务网段 - * "MasterCount" => (integer) Master 节点数量 - * "ApiServer" => (string) 集群apiserver地址 - * "K8sVersion" => (string) 集群版本 - * "ClusterLogInfo" => (string) 创建集群时判断如果为NORESOURCE则为没资源,否则为空 - * "CreateTime" => (integer) 创建时间 - * "NodeCount" => (integer) Node节点数量 - * "ExternalApiServer" => (string) 集群外部apiserver地址 - * "Status" => (string) 集群状态,枚举值:初始化:"INITIALIZING";启动中:"STARTING";创建失败:"CREATEFAILED";正常运行:"RUNNING";添加节点:"ADDNODE";删除节点:"DELNODE";删除中:"DELETING";删除失败:"DELETEFAILED";错误:"ERROR";升级插件:"UPDATE_PLUGIN";更新插件信息:"UPDATE_PLUGIN_INFO";异常:"ABNORMAL";升级集群中:"UPGRADING";容器运行时切换:"CONVERTING" - * ] - * ] - * ] - * - * @return ListUK8SClusterV2Response * @throws UCloudException */ public function listUK8SClusterV2(ListUK8SClusterV2Request $request = null) @@ -522,4 +265,32 @@ public function listUK8SClusterV2(ListUK8SClusterV2Request $request = null) $resp = $this->invoke($request); return new ListUK8SClusterV2Response($resp->toArray(), $resp->getRequestId()); } + + + + + /** + * ListUK8SNodeGroup - 列出UK8S节点池 + * + * @throws UCloudException + */ + public function listUK8SNodeGroup(ListUK8SNodeGroupRequest $request = null) + { + $resp = $this->invoke($request); + return new ListUK8SNodeGroupResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * RemoveUK8SNodeGroup - 删除UK8S节点池 + * + * @throws UCloudException + */ + public function removeUK8SNodeGroup(RemoveUK8SNodeGroupRequest $request = null) + { + $resp = $this->invoke($request); + return new RemoveUK8SNodeGroupResponse($resp->toArray(), $resp->getRequestId()); + } } diff --git a/src/ULB/Apis/AllocateBackendRequest.php b/src/ULB/Apis/AllocateBackendRequest.php index 9d1945a6..c45fffd0 100644 --- a/src/ULB/Apis/AllocateBackendRequest.php +++ b/src/ULB/Apis/AllocateBackendRequest.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -44,17 +45,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -64,15 +64,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例的ID * @@ -88,11 +87,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: VServer实例的ID * @@ -108,13 +106,12 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** - * ResourceType: 所添加的后端资源的类型,枚举值:UHost -> 云主机;UNI -> 虚拟网卡;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;默认值为UHost。报文转发模式不支持UDocker、UHybrid、CUBE + * ResourceType: 所添加的后端资源的类型,枚举值:UHost -> 云主机;UNI -> 虚拟网卡;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube,USDP->智能大数据平台;默认值为UHost。报文转发模式不支持UDocker、UHybrid、CUBE * * @return string|null */ @@ -124,15 +121,14 @@ public function getResourceType() } /** - * ResourceType: 所添加的后端资源的类型,枚举值:UHost -> 云主机;UNI -> 虚拟网卡;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;默认值为UHost。报文转发模式不支持UDocker、UHybrid、CUBE + * ResourceType: 所添加的后端资源的类型,枚举值:UHost -> 云主机;UNI -> 虚拟网卡;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube,USDP->智能大数据平台;默认值为UHost。报文转发模式不支持UDocker、UHybrid、CUBE * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 所添加的后端资源的资源ID * @@ -148,11 +144,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceIP: 所添加的后端服务器的资源实例IP,当ResourceType 为 UHybrid 时有效,且必填 * @@ -168,11 +163,10 @@ public function getResourceIP() * * @param string $resourceIP */ - public function setResourceIP($resourceIP) + public function setResourceIP(string $resourceIP) { $this->set("ResourceIP", $resourceIP); } - /** * VPCId: 所添加的后端服务器所在的vpc,当ResourceType 为 UHybrid 时有效,且必填 * @@ -188,11 +182,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 所添加的后端服务器所在的子网,当ResourceType 为 UHybrid 时有效,且必填 * @@ -208,11 +201,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Port: 所添加的后端资源服务端口,取值范围[1-65535],默认80 * @@ -228,13 +220,12 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** - * Weight: 所添加的后端RS权重(在加权轮询算法下有效),取值范围[0-100],默认为1 + * Weight: 所添加的后端RS权重(在加权轮询算法下有效),取值范围[1-100],默认为1 * * @return integer|null */ @@ -244,15 +235,14 @@ public function getWeight() } /** - * Weight: 所添加的后端RS权重(在加权轮询算法下有效),取值范围[0-100],默认为1 + * Weight: 所添加的后端RS权重(在加权轮询算法下有效),取值范围[1-100],默认为1 * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } - /** * Enabled: 后端实例状态开关,枚举值: 1:启用; 0:禁用 默认为启用 * @@ -268,11 +258,10 @@ public function getEnabled() * * @param int $enabled */ - public function setEnabled($enabled) + public function setEnabled(int $enabled) { $this->set("Enabled", $enabled); } - /** * IsBackup: rs是否为backup,默认为00:普通rs1:backup的rs * @@ -288,7 +277,7 @@ public function getIsBackup() * * @param int $isBackup */ - public function setIsBackup($isBackup) + public function setIsBackup(int $isBackup) { $this->set("IsBackup", $isBackup); } diff --git a/src/ULB/Apis/AllocateBackendResponse.php b/src/ULB/Apis/AllocateBackendResponse.php index f531b22a..f1625c5b 100644 --- a/src/ULB/Apis/AllocateBackendResponse.php +++ b/src/ULB/Apis/AllocateBackendResponse.php @@ -1,6 +1,7 @@ set("BackendId", $backendId); } diff --git a/src/ULB/Apis/BindSSLRequest.php b/src/ULB/Apis/BindSSLRequest.php index d874f421..e5070012 100644 --- a/src/ULB/Apis/BindSSLRequest.php +++ b/src/ULB/Apis/BindSSLRequest.php @@ -1,6 +1,7 @@ markRequired("SSLId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 所绑定ULB实例ID * @@ -87,11 +86,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: 所绑定VServer实例ID * @@ -107,11 +105,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * SSLId: SSL证书的Id * @@ -127,7 +124,7 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } diff --git a/src/ULB/Apis/BindSSLResponse.php b/src/ULB/Apis/BindSSLResponse.php index f7aa4f99..dce663cd 100644 --- a/src/ULB/Apis/BindSSLResponse.php +++ b/src/ULB/Apis/BindSSLResponse.php @@ -1,6 +1,7 @@ markRequired("Match"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -68,11 +68,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 需要添加内容转发策略的负载均衡实例ID * @@ -88,11 +87,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: 需要添加内容转发策略的VServer实例ID * @@ -108,11 +106,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * BackendId: 内容转发策略应用的后端资源实例的ID,来源于 AllocateBackend 返回的 BackendId * @@ -132,7 +129,6 @@ public function setBackendId(array $backendId) { $this->set("BackendId", $backendId); } - /** * Match: 内容转发匹配字段 * @@ -148,11 +144,10 @@ public function getMatch() * * @param string $match */ - public function setMatch($match) + public function setMatch(string $match) { $this->set("Match", $match); } - /** * Type: 内容转发匹配字段的类型 * @@ -168,11 +163,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * PolicyPriority: 策略优先级,1-9999 * @@ -188,7 +182,7 @@ public function getPolicyPriority() * * @param int $policyPriority */ - public function setPolicyPriority($policyPriority) + public function setPolicyPriority(int $policyPriority) { $this->set("PolicyPriority", $policyPriority); } diff --git a/src/ULB/Apis/CreatePolicyResponse.php b/src/ULB/Apis/CreatePolicyResponse.php index 9eb34ed5..acdd3ed1 100644 --- a/src/ULB/Apis/CreatePolicyResponse.php +++ b/src/ULB/Apis/CreatePolicyResponse.php @@ -1,6 +1,7 @@ set("PolicyId", $policyId); } diff --git a/src/ULB/Apis/CreateSSLRequest.php b/src/ULB/Apis/CreateSSLRequest.php index b2e9d880..e049ef95 100644 --- a/src/ULB/Apis/CreateSSLRequest.php +++ b/src/ULB/Apis/CreateSSLRequest.php @@ -1,6 +1,7 @@ markRequired("SSLName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLName: SSL证书的名字,默认值为空 * @@ -85,11 +84,10 @@ public function getSSLName() * * @param string $sslName */ - public function setSSLName($sslName) + public function setSSLName(string $sslName) { $this->set("SSLName", $sslName); } - /** * SSLType: 所添加的SSL证书类型,目前只支持Pem格式 * @@ -105,11 +103,10 @@ public function getSSLType() * * @param string $sslType */ - public function setSSLType($sslType) + public function setSSLType(string $sslType) { $this->set("SSLType", $sslType); } - /** * SSLContent: SSL证书的完整内容,包括用户证书、加密证书的私钥、CA证书 * @@ -125,11 +122,10 @@ public function getSSLContent() * * @param string $sslContent */ - public function setSSLContent($sslContent) + public function setSSLContent(string $sslContent) { $this->set("SSLContent", $sslContent); } - /** * UserCert: 用户的证书 * @@ -145,11 +141,10 @@ public function getUserCert() * * @param string $userCert */ - public function setUserCert($userCert) + public function setUserCert(string $userCert) { $this->set("UserCert", $userCert); } - /** * PrivateKey: 加密证书的私钥 * @@ -165,11 +160,10 @@ public function getPrivateKey() * * @param string $privateKey */ - public function setPrivateKey($privateKey) + public function setPrivateKey(string $privateKey) { $this->set("PrivateKey", $privateKey); } - /** * CaCert: CA证书 * @@ -185,7 +179,7 @@ public function getCaCert() * * @param string $caCert */ - public function setCaCert($caCert) + public function setCaCert(string $caCert) { $this->set("CaCert", $caCert); } diff --git a/src/ULB/Apis/CreateSSLResponse.php b/src/ULB/Apis/CreateSSLResponse.php index 682fccea..f0f558ba 100644 --- a/src/ULB/Apis/CreateSSLResponse.php +++ b/src/ULB/Apis/CreateSSLResponse.php @@ -1,6 +1,7 @@ set("SSLId", $sslId); } diff --git a/src/ULB/Apis/CreateULBRequest.php b/src/ULB/Apis/CreateULBRequest.php index 6ef4b012..a25005d5 100644 --- a/src/ULB/Apis/CreateULBRequest.php +++ b/src/ULB/Apis/CreateULBRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBName: 负载均衡的名字,默认值为“ULB” * @@ -83,11 +82,10 @@ public function getULBName() * * @param string $ulbName */ - public function setULBName($ulbName) + public function setULBName(string $ulbName) { $this->set("ULBName", $ulbName); } - /** * Tag: 业务组 * @@ -103,11 +101,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -123,11 +120,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * OuterMode: 创建的ULB是否为外网模式,默认即为外网模式 * @@ -143,11 +139,10 @@ public function getOuterMode() * * @param string $outerMode */ - public function setOuterMode($outerMode) + public function setOuterMode(string $outerMode) { $this->set("OuterMode", $outerMode); } - /** * InnerMode: 创建的ULB是否为内网模式 * @@ -163,11 +158,10 @@ public function getInnerMode() * * @param string $innerMode */ - public function setInnerMode($innerMode) + public function setInnerMode(string $innerMode) { $this->set("InnerMode", $innerMode); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费 * @@ -183,11 +177,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * VPCId: ULB所在的VPC的ID, 如果不传则使用默认的VPC * @@ -203,11 +196,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: ULB 所属的子网ID,如果不传则随机选择一个。 * @@ -223,11 +215,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * BusinessId: ULB 所属的业务组ID,如果不传则使用默认的业务组 * @@ -243,11 +234,10 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } - /** * FirewallId: 防火墙ID,如果不传,则默认不绑定防火墙 * @@ -263,11 +253,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * ListenType: ULB 监听器类型,外网ULB默认RequestProxy,内网ULB默认PacketsTransmit。枚举值:RequestProxy,请求代理; PacketsTransmit ,报文转发。 * @@ -283,7 +272,7 @@ public function getListenType() * * @param string $listenType */ - public function setListenType($listenType) + public function setListenType(string $listenType) { $this->set("ListenType", $listenType); } diff --git a/src/ULB/Apis/CreateULBResponse.php b/src/ULB/Apis/CreateULBResponse.php index 6323b78d..c6576827 100644 --- a/src/ULB/Apis/CreateULBResponse.php +++ b/src/ULB/Apis/CreateULBResponse.php @@ -1,6 +1,7 @@ set("ULBId", $ulbId); } - /** * IPv6AddressId: IPv6地址Id * @@ -57,7 +57,7 @@ public function getIPv6AddressId() * * @param string $iPv6AddressId */ - public function setIPv6AddressId($iPv6AddressId) + public function setIPv6AddressId(string $iPv6AddressId) { $this->set("IPv6AddressId", $iPv6AddressId); } diff --git a/src/ULB/Apis/CreateVServerRequest.php b/src/ULB/Apis/CreateVServerRequest.php index 8036b03a..2247b221 100644 --- a/src/ULB/Apis/CreateVServerRequest.php +++ b/src/ULB/Apis/CreateVServerRequest.php @@ -1,6 +1,7 @@ markRequired("ULBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例ID * @@ -84,11 +83,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerName: VServer实例名称,默认为"VServer" * @@ -104,11 +102,10 @@ public function getVServerName() * * @param string $vServerName */ - public function setVServerName($vServerName) + public function setVServerName(string $vServerName) { $this->set("VServerName", $vServerName); } - /** * ListenType: 监听器类型,枚举值,RequestProxy ,请求代理;PacketsTransmit ,报文转发。默认为RequestProxy * @@ -124,11 +121,10 @@ public function getListenType() * * @param string $listenType */ - public function setListenType($listenType) + public function setListenType(string $listenType) { $this->set("ListenType", $listenType); } - /** * Protocol: VServer实例的协议,请求代理模式下有 HTTP、HTTPS、TCP,报文转发下有 TCP,UDP。默认为“HTTP" * @@ -144,11 +140,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * FrontendPort: VServer后端端口,取值范围[1-65535];默认值为80 * @@ -164,11 +159,10 @@ public function getFrontendPort() * * @param int $frontendPort */ - public function setFrontendPort($frontendPort) + public function setFrontendPort(int $frontendPort) { $this->set("FrontendPort", $frontendPort); } - /** * Method: VServer负载均衡模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口); WeightRoundrobin -> 加权轮询; Leastconn -> 最小连接数;Backup ->主备模式。ConsistentHash,SourcePort,ConsistentHashPort 只在报文转发中使用;Leastconn只在请求代理中使用;Roundrobin、Source和WeightRoundrobin,Backup在请求代理和报文转发中使用。默认为:"Roundrobin" * @@ -184,11 +178,10 @@ public function getMethod() * * @param string $method */ - public function setMethod($method) + public function setMethod(string $method) { $this->set("Method", $method); } - /** * PersistenceType: VServer会话保持方式,默认关闭会话保持。枚举值:None -> 关闭;ServerInsert -> 自动生成KEY;UserDefined -> 用户自定义KEY。 * @@ -204,11 +197,10 @@ public function getPersistenceType() * * @param string $persistenceType */ - public function setPersistenceType($persistenceType) + public function setPersistenceType(string $persistenceType) { $this->set("PersistenceType", $persistenceType); } - /** * PersistenceInfo: 根据PersistenceType确认; None和ServerInsert: 此字段无意义; UserDefined:此字段传入自定义会话保持String * @@ -224,11 +216,10 @@ public function getPersistenceInfo() * * @param string $persistenceInfo */ - public function setPersistenceInfo($persistenceInfo) + public function setPersistenceInfo(string $persistenceInfo) { $this->set("PersistenceInfo", $persistenceInfo); } - /** * ClientTimeout: ListenType为RequestProxy时表示空闲连接的回收时间,单位:秒,取值范围:时(0,86400],默认值为60;ListenType为PacketsTransmit时表示连接保持的时间,单位:秒,取值范围:[60,900],0 表示禁用连接保持 * @@ -244,11 +235,10 @@ public function getClientTimeout() * * @param int $clientTimeout */ - public function setClientTimeout($clientTimeout) + public function setClientTimeout(int $clientTimeout) { $this->set("ClientTimeout", $clientTimeout); } - /** * MonitorType: 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测;Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path;报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize,默认值为Ping * @@ -264,11 +254,10 @@ public function getMonitorType() * * @param string $monitorType */ - public function setMonitorType($monitorType) + public function setMonitorType(string $monitorType) { $this->set("MonitorType", $monitorType); } - /** * Domain: 根据MonitorType确认; 当MonitorType为Path时,此字段有意义,代表HTTP检查域名 * @@ -284,11 +273,10 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * Path: 根据MonitorType确认; 当MonitorType为Path时,此字段有意义,代表HTTP检查路径 * @@ -304,11 +292,10 @@ public function getPath() * * @param string $path */ - public function setPath($path) + public function setPath(string $path) { $this->set("Path", $path); } - /** * RequestMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 * @@ -324,11 +311,10 @@ public function getRequestMsg() * * @param string $requestMsg */ - public function setRequestMsg($requestMsg) + public function setRequestMsg(string $requestMsg) { $this->set("RequestMsg", $requestMsg); } - /** * ResponseMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 * @@ -344,7 +330,7 @@ public function getResponseMsg() * * @param string $responseMsg */ - public function setResponseMsg($responseMsg) + public function setResponseMsg(string $responseMsg) { $this->set("ResponseMsg", $responseMsg); } diff --git a/src/ULB/Apis/CreateVServerResponse.php b/src/ULB/Apis/CreateVServerResponse.php index 6c0ac61a..178f5f92 100644 --- a/src/ULB/Apis/CreateVServerResponse.php +++ b/src/ULB/Apis/CreateVServerResponse.php @@ -1,6 +1,7 @@ set("VServerId", $vServerId); } diff --git a/src/ULB/Apis/DeletePolicyRequest.php b/src/ULB/Apis/DeletePolicyRequest.php index 4bccf26e..68488629 100644 --- a/src/ULB/Apis/DeletePolicyRequest.php +++ b/src/ULB/Apis/DeletePolicyRequest.php @@ -1,6 +1,7 @@ markRequired("PolicyId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PolicyId: 内容转发策略ID * @@ -85,11 +84,10 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } - /** * VServerId: VServer 资源ID * @@ -105,7 +103,7 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } diff --git a/src/ULB/Apis/DeletePolicyResponse.php b/src/ULB/Apis/DeletePolicyResponse.php index e3fe7b12..436fd4d7 100644 --- a/src/ULB/Apis/DeletePolicyResponse.php +++ b/src/ULB/Apis/DeletePolicyResponse.php @@ -1,6 +1,7 @@ markRequired("SSLId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLId: SSL证书的ID * @@ -85,7 +84,7 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } diff --git a/src/ULB/Apis/DeleteSSLResponse.php b/src/ULB/Apis/DeleteSSLResponse.php index 25af2e3a..9829ef87 100644 --- a/src/ULB/Apis/DeleteSSLResponse.php +++ b/src/ULB/Apis/DeleteSSLResponse.php @@ -1,6 +1,7 @@ markRequired("ULBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例的ID * @@ -84,11 +83,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * ReleaseEip: 删除ulb时是否释放绑定的EIP,false标识只解绑EIP,true表示会释放绑定的EIP,默认是false。Anycast IP 此参数无效 * @@ -104,7 +102,7 @@ public function getReleaseEip() * * @param boolean $releaseEip */ - public function setReleaseEip($releaseEip) + public function setReleaseEip(bool $releaseEip) { $this->set("ReleaseEip", $releaseEip); } diff --git a/src/ULB/Apis/DeleteULBResponse.php b/src/ULB/Apis/DeleteULBResponse.php index 64bdb5e2..0dab43b5 100644 --- a/src/ULB/Apis/DeleteULBResponse.php +++ b/src/ULB/Apis/DeleteULBResponse.php @@ -1,6 +1,7 @@ markRequired("VServerId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例的ID * @@ -86,11 +85,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: VServer实例的ID * @@ -106,7 +104,7 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } diff --git a/src/ULB/Apis/DeleteVServerResponse.php b/src/ULB/Apis/DeleteVServerResponse.php index f8712c7d..056331a5 100644 --- a/src/ULB/Apis/DeleteVServerResponse.php +++ b/src/ULB/Apis/DeleteVServerResponse.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SSLId: SSL证书的Id * @@ -84,11 +83,10 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } - /** * Limit: 数据分页值,默认为20 * @@ -104,11 +102,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 数据偏移量,默认值为0 * @@ -124,7 +121,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/ULB/Apis/DescribeSSLResponse.php b/src/ULB/Apis/DescribeSSLResponse.php index c317762c..e87877dc 100644 --- a/src/ULB/Apis/DescribeSSLResponse.php +++ b/src/ULB/Apis/DescribeSSLResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: SSL证书详细信息,具体结构见 ULBSSLSet * - * @return ULBSSLSet[]|null + * @return ULBSSLSetModel[]|null */ public function getDataSet() { @@ -57,7 +58,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBSSLSet($item)); + array_push($result, new ULBSSLSetModel($item)); } return $result; } @@ -65,7 +66,7 @@ public function getDataSet() /** * DataSet: SSL证书详细信息,具体结构见 ULBSSLSet * - * @param ULBSSLSet[] $dataSet + * @param ULBSSLSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/ULB/Apis/DescribeULBRequest.php b/src/ULB/Apis/DescribeULBRequest.php index a6f051b2..56d97e00 100644 --- a/src/ULB/Apis/DescribeULBRequest.php +++ b/src/ULB/Apis/DescribeULBRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 数据偏移量,默认为0 * @@ -83,11 +82,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值,默认为20 * @@ -103,11 +101,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * ULBId: 负载均衡实例的Id。 若指定则返回指定的负载均衡实例的信息; 若不指定则返回当前数据中心中所有的负载均衡实例的信息 * @@ -123,11 +120,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VPCId: ULB所属的VPC * @@ -143,11 +139,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: ULB所属的子网ID * @@ -163,11 +158,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * BusinessId: ULB所属的业务组ID * @@ -183,7 +177,7 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } diff --git a/src/ULB/Apis/DescribeULBResponse.php b/src/ULB/Apis/DescribeULBResponse.php index 5b86190d..907a5c78 100644 --- a/src/ULB/Apis/DescribeULBResponse.php +++ b/src/ULB/Apis/DescribeULBResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: ULB列表,每项参数详见 ULBSet * - * @return ULBSet[]|null + * @return ULBSetModel[]|null */ public function getDataSet() { @@ -65,7 +66,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBSet($item)); + array_push($result, new ULBSetModel($item)); } return $result; } @@ -73,7 +74,7 @@ public function getDataSet() /** * DataSet: ULB列表,每项参数详见 ULBSet * - * @param ULBSet[] $dataSet + * @param ULBSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/ULB/Apis/DescribeULBSimpleRequest.php b/src/ULB/Apis/DescribeULBSimpleRequest.php index 5b0824bb..64b0656b 100644 --- a/src/ULB/Apis/DescribeULBSimpleRequest.php +++ b/src/ULB/Apis/DescribeULBSimpleRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 数据偏移量,默认为0 * @@ -83,11 +82,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值,默认为10000 * @@ -103,11 +101,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * ULBId: 负载均衡实例的Id。 若指定则返回指定的负载均衡实例的信息; 若不指定则返回当前数据中心中所有的负载均衡实例的信息 * @@ -123,11 +120,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VPCId: ULB所属的VPC * @@ -143,11 +139,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: ULB所属的子网ID * @@ -163,11 +158,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * BusinessId: ULB所属的业务组ID * @@ -183,7 +177,7 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } diff --git a/src/ULB/Apis/DescribeULBSimpleResponse.php b/src/ULB/Apis/DescribeULBSimpleResponse.php index 47137aaa..3625b408 100644 --- a/src/ULB/Apis/DescribeULBSimpleResponse.php +++ b/src/ULB/Apis/DescribeULBSimpleResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: ULB列表,每项参数详见 ULBSimpleSet * - * @return ULBSimpleSet[]|null + * @return ULBSimpleSetModel[]|null */ public function getDataSet() { @@ -59,7 +60,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBSimpleSet($item)); + array_push($result, new ULBSimpleSetModel($item)); } return $result; } @@ -67,7 +68,7 @@ public function getDataSet() /** * DataSet: ULB列表,每项参数详见 ULBSimpleSet * - * @param ULBSimpleSet[] $dataSet + * @param ULBSimpleSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/ULB/Apis/DescribeVServerRequest.php b/src/ULB/Apis/DescribeVServerRequest.php index e064dd66..3c4da493 100644 --- a/src/ULB/Apis/DescribeVServerRequest.php +++ b/src/ULB/Apis/DescribeVServerRequest.php @@ -1,6 +1,7 @@ "DescribeVServer"]); $this->markRequired("Region"); $this->markRequired("ProjectId"); - $this->markRequired("ULBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例的Id * @@ -85,11 +83,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: VServer实例的Id;若指定则返回指定的VServer实例的信息; 若不指定则返回当前负载均衡实例下所有VServer的信息 * @@ -105,11 +102,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * Limit: 数据分页值 * @@ -125,11 +121,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 数据偏移量 * @@ -145,7 +140,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/ULB/Apis/DescribeVServerResponse.php b/src/ULB/Apis/DescribeVServerResponse.php index 0be387ba..529dee7f 100644 --- a/src/ULB/Apis/DescribeVServerResponse.php +++ b/src/ULB/Apis/DescribeVServerResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: VServer列表,每项参数详见 ULBVServerSet * - * @return ULBVServerSet[]|null + * @return ULBVServerSetModel[]|null */ public function getDataSet() { @@ -61,7 +62,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBVServerSet($item)); + array_push($result, new ULBVServerSetModel($item)); } return $result; } @@ -69,7 +70,7 @@ public function getDataSet() /** * DataSet: VServer列表,每项参数详见 ULBVServerSet * - * @param ULBVServerSet[] $dataSet + * @param ULBVServerSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/ULB/Apis/ReleaseBackendRequest.php b/src/ULB/Apis/ReleaseBackendRequest.php index 6a0e7147..43455511 100644 --- a/src/ULB/Apis/ReleaseBackendRequest.php +++ b/src/ULB/Apis/ReleaseBackendRequest.php @@ -1,6 +1,7 @@ markRequired("BackendId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例的ID * @@ -86,11 +85,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * BackendId: 后端资源实例的ID(ULB后端ID,非资源自身ID) * @@ -106,7 +104,7 @@ public function getBackendId() * * @param string $backendId */ - public function setBackendId($backendId) + public function setBackendId(string $backendId) { $this->set("BackendId", $backendId); } diff --git a/src/ULB/Apis/ReleaseBackendResponse.php b/src/ULB/Apis/ReleaseBackendResponse.php index 412a54e1..0792c110 100644 --- a/src/ULB/Apis/ReleaseBackendResponse.php +++ b/src/ULB/Apis/ReleaseBackendResponse.php @@ -1,6 +1,7 @@ markRequired("SSLId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 所绑定ULB实例ID * @@ -87,11 +86,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: 所绑定VServer实例ID * @@ -107,11 +105,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * SSLId: SSL证书的Id * @@ -127,7 +124,7 @@ public function getSSLId() * * @param string $sslId */ - public function setSSLId($sslId) + public function setSSLId(string $sslId) { $this->set("SSLId", $sslId); } diff --git a/src/ULB/Apis/UnbindSSLResponse.php b/src/ULB/Apis/UnbindSSLResponse.php index f507f0c4..77ace78d 100644 --- a/src/ULB/Apis/UnbindSSLResponse.php +++ b/src/ULB/Apis/UnbindSSLResponse.php @@ -1,6 +1,7 @@ markRequired("BackendId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡资源ID * @@ -86,11 +85,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * BackendId: 后端资源实例的ID(ULB后端ID,非资源自身ID) * @@ -106,11 +104,10 @@ public function getBackendId() * * @param string $backendId */ - public function setBackendId($backendId) + public function setBackendId(string $backendId) { $this->set("BackendId", $backendId); } - /** * Port: 后端资源服务端口,取值范围[1-65535] * @@ -126,11 +123,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * Weight: 所添加的后端RS权重(在加权轮询算法下有效),取值范围[0-100],默认为1 * @@ -146,11 +142,10 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } - /** * Enabled: 后端实例状态开关 * @@ -166,11 +161,10 @@ public function getEnabled() * * @param int $enabled */ - public function setEnabled($enabled) + public function setEnabled(int $enabled) { $this->set("Enabled", $enabled); } - /** * IsBackup: 是否为backup0:主rs1:备rs默认为0 * @@ -186,7 +180,7 @@ public function getIsBackup() * * @param int $isBackup */ - public function setIsBackup($isBackup) + public function setIsBackup(int $isBackup) { $this->set("IsBackup", $isBackup); } diff --git a/src/ULB/Apis/UpdateBackendAttributeResponse.php b/src/ULB/Apis/UpdateBackendAttributeResponse.php index 3818b4b8..5f66b0dd 100644 --- a/src/ULB/Apis/UpdateBackendAttributeResponse.php +++ b/src/ULB/Apis/UpdateBackendAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("Match"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 需要添加内容转发策略的负载均衡实例ID * @@ -87,11 +86,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: 需要添加内容转发策略的VServer实例ID,只支持请求代理模式下,HTTP或HTTPS协议的VServer * @@ -107,11 +105,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * Match: 内容转发匹配字段 * @@ -127,11 +124,10 @@ public function getMatch() * * @param string $match */ - public function setMatch($match) + public function setMatch(string $match) { $this->set("Match", $match); } - /** * PolicyId: 转发规则的ID,当Type为Default时,可以不传或为空 * @@ -147,11 +143,10 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } - /** * BackendId: 内容转发策略应用的后端资源实例的ID,来源于 AllocateBackend 返回的 BackendId,不传表示更新转发节点为空 * @@ -171,7 +166,6 @@ public function setBackendId(array $backendId) { $this->set("BackendId", $backendId); } - /** * Type: 内容转发匹配字段的类型,枚举值:Domain -> 域名转发规则;Path -> 路径转发规则;Default -> 默认转发规则,不传默认值Domain * @@ -187,7 +181,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/ULB/Apis/UpdatePolicyResponse.php b/src/ULB/Apis/UpdatePolicyResponse.php index ea64c446..4e703bb3 100644 --- a/src/ULB/Apis/UpdatePolicyResponse.php +++ b/src/ULB/Apis/UpdatePolicyResponse.php @@ -1,6 +1,7 @@ "UpdateSSLAttribute"]); + $this->markRequired("Region"); + $this->markRequired("ProjectId"); + $this->markRequired("SSLId"); + $this->markRequired("SSLName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * SSLId: SSL的资源id + * + * @return string|null + */ + public function getSSLId() + { + return $this->get("SSLId"); + } + + /** + * SSLId: SSL的资源id + * + * @param string $sslId + */ + public function setSSLId(string $sslId) + { + $this->set("SSLId", $sslId); + } + /** + * SSLName: SSL实例名称,不允许传空 + * + * @return string|null + */ + public function getSSLName() + { + return $this->get("SSLName"); + } + + /** + * SSLName: SSL实例名称,不允许传空 + * + * @param string $sslName + */ + public function setSSLName(string $sslName) + { + $this->set("SSLName", $sslName); + } +} diff --git a/src/ULB/Apis/UpdateSSLAttributeResponse.php b/src/ULB/Apis/UpdateSSLAttributeResponse.php new file mode 100644 index 00000000..b99413bc --- /dev/null +++ b/src/ULB/Apis/UpdateSSLAttributeResponse.php @@ -0,0 +1,26 @@ +markRequired("ULBId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: ULB资源ID * @@ -85,11 +84,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * Name: 名字 * @@ -105,11 +103,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务 * @@ -125,11 +122,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -145,7 +141,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/ULB/Apis/UpdateULBAttributeResponse.php b/src/ULB/Apis/UpdateULBAttributeResponse.php index 3db1e8fb..9d665e44 100644 --- a/src/ULB/Apis/UpdateULBAttributeResponse.php +++ b/src/ULB/Apis/UpdateULBAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("VServerId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ULBId: 负载均衡实例ID * @@ -86,11 +85,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * VServerId: VServer实例ID * @@ -106,11 +104,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * VServerName: VServer实例名称,若无此字段则不做修改 * @@ -126,11 +123,10 @@ public function getVServerName() * * @param string $vServerName */ - public function setVServerName($vServerName) + public function setVServerName(string $vServerName) { $this->set("VServerName", $vServerName); } - /** * Method: VServer负载均衡模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口); WeightRoundrobin -> 加权轮询; Leastconn -> 最小连接数;Backup -> 主备模式。ConsistentHash,SourcePort,ConsistentHashPort 只在报文转发中使用;Leastconn只在请求代理中使用;Roundrobin、Source和WeightRoundrobin,Backup在请求代理和报文转发中使用。默认为:"Roundrobin" * @@ -146,11 +142,10 @@ public function getMethod() * * @param string $method */ - public function setMethod($method) + public function setMethod(string $method) { $this->set("Method", $method); } - /** * PersistenceType: VServer会话保持模式,若无此字段则不做修改。枚举值:None:关闭;ServerInsert:自动生成KEY;UserDefined:用户自定义KEY。 * @@ -166,11 +161,10 @@ public function getPersistenceType() * * @param string $persistenceType */ - public function setPersistenceType($persistenceType) + public function setPersistenceType(string $persistenceType) { $this->set("PersistenceType", $persistenceType); } - /** * PersistenceInfo: 根据PersistenceType确定: None或ServerInsert, 此字段无意义; UserDefined, 则此字段传入用户自定义会话保持String. 若无此字段则不做修改 * @@ -186,11 +180,10 @@ public function getPersistenceInfo() * * @param string $persistenceInfo */ - public function setPersistenceInfo($persistenceInfo) + public function setPersistenceInfo(string $persistenceInfo) { $this->set("PersistenceInfo", $persistenceInfo); } - /** * ClientTimeout: 请求代理的VServer下表示空闲连接的回收时间,单位:秒,取值范围:时(0,86400],默认值为60;报文转发的VServer下表示回话保持的时间,单位:秒,取值范围:[60,900],0 表示禁用连接保持 * @@ -206,11 +199,10 @@ public function getClientTimeout() * * @param int $clientTimeout */ - public function setClientTimeout($clientTimeout) + public function setClientTimeout(int $clientTimeout) { $this->set("ClientTimeout", $clientTimeout); } - /** * MonitorType: 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测,Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path;报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize,默认值为Ping * @@ -226,11 +218,10 @@ public function getMonitorType() * * @param string $monitorType */ - public function setMonitorType($monitorType) + public function setMonitorType(string $monitorType) { $this->set("MonitorType", $monitorType); } - /** * Domain: MonitorType 为 Path 时指定健康检查发送请求时HTTP HEADER 里的域名 * @@ -246,11 +237,10 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * Path: MonitorType 为 Path 时指定健康检查发送请求时的路径,默认为 / * @@ -266,11 +256,10 @@ public function getPath() * * @param string $path */ - public function setPath($path) + public function setPath(string $path) { $this->set("Path", $path); } - /** * RequestMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 * @@ -286,11 +275,10 @@ public function getRequestMsg() * * @param string $requestMsg */ - public function setRequestMsg($requestMsg) + public function setRequestMsg(string $requestMsg) { $this->set("RequestMsg", $requestMsg); } - /** * ResponseMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 * @@ -306,7 +294,7 @@ public function getResponseMsg() * * @param string $responseMsg */ - public function setResponseMsg($responseMsg) + public function setResponseMsg(string $responseMsg) { $this->set("ResponseMsg", $responseMsg); } diff --git a/src/ULB/Apis/UpdateVServerAttributeResponse.php b/src/ULB/Apis/UpdateVServerAttributeResponse.php index a70b7969..7365cb2b 100644 --- a/src/ULB/Apis/UpdateVServerAttributeResponse.php +++ b/src/ULB/Apis/UpdateVServerAttributeResponse.php @@ -1,6 +1,7 @@ set("FirewallName", $firewallName); } - /** * FirewallId: 防火墙ID * @@ -57,7 +62,7 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } diff --git a/src/ULB/Models/LoggerSet.php b/src/ULB/Models/LoggerSet.php index 0f22ff15..3f98113f 100644 --- a/src/ULB/Models/LoggerSet.php +++ b/src/ULB/Models/LoggerSet.php @@ -1,6 +1,7 @@ set("BucketName", $bucketName); } - /** * TokenID: 上传到bucket使用的token的tokenid * @@ -57,11 +62,10 @@ public function getTokenID() * * @param string $tokenID */ - public function setTokenID($tokenID) + public function setTokenID(string $tokenID) { $this->set("TokenID", $tokenID); } - /** * TokenName: bucket的token名称 * @@ -77,7 +81,7 @@ public function getTokenName() * * @param string $tokenName */ - public function setTokenName($tokenName) + public function setTokenName(string $tokenName) { $this->set("TokenName", $tokenName); } diff --git a/src/ULB/Models/PolicyBackendSet.php b/src/ULB/Models/PolicyBackendSet.php index d4373bda..50d6153e 100644 --- a/src/ULB/Models/PolicyBackendSet.php +++ b/src/ULB/Models/PolicyBackendSet.php @@ -1,6 +1,7 @@ set("BackendId", $backendId); } - /** * ResourceType: 所添加的后端资源的类型,枚举值:UHost -> 云主机;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;UNI -> 虚拟网卡 * @@ -57,11 +63,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceName: 后端资源的实例名称 * @@ -77,11 +82,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * SubResourceId: 如果资源绑定了弹性网卡,则展示弹性网卡的资源ID * @@ -97,11 +101,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * SubResourceName: 如果资源绑定了弹性网卡,则展示弹性网卡的资源名称 * @@ -117,11 +120,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * SubResourceType: "UNI"或者为空 * @@ -137,11 +139,10 @@ public function getSubResourceType() * * @param string $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(string $subResourceType) { $this->set("SubResourceType", $subResourceType); } - /** * ObjectId: 后端资源的对象ID * @@ -157,11 +158,10 @@ public function getObjectId() * * @param string $objectId */ - public function setObjectId($objectId) + public function setObjectId(string $objectId) { $this->set("ObjectId", $objectId); } - /** * Port: 所添加的后端资源服务端口 * @@ -177,11 +177,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * PrivateIP: 后端资源的内网IP * @@ -197,7 +196,7 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } diff --git a/src/ULB/Models/SSLBindedTargetSet.php b/src/ULB/Models/SSLBindedTargetSet.php index 921fa995..b65d9ae2 100644 --- a/src/ULB/Models/SSLBindedTargetSet.php +++ b/src/ULB/Models/SSLBindedTargetSet.php @@ -1,6 +1,7 @@ set("VServerId", $vServerId); } - /** * VServerName: 对应的VServer的名字 * @@ -57,11 +64,10 @@ public function getVServerName() * * @param string $vServerName */ - public function setVServerName($vServerName) + public function setVServerName(string $vServerName) { $this->set("VServerName", $vServerName); } - /** * ULBId: VServer 所属的ULB实例的资源ID * @@ -77,11 +83,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * ULBName: ULB实例的名称 * @@ -97,7 +102,7 @@ public function getULBName() * * @param string $ulbName */ - public function setULBName($ulbName) + public function setULBName(string $ulbName) { $this->set("ULBName", $ulbName); } diff --git a/src/ULB/Models/ULBBackendSet.php b/src/ULB/Models/ULBBackendSet.php index 942f4b91..ae5aee3f 100644 --- a/src/ULB/Models/ULBBackendSet.php +++ b/src/ULB/Models/ULBBackendSet.php @@ -1,6 +1,7 @@ set("BackendId", $backendId); } - /** * ResourceType: 资源实例的类型 * @@ -57,11 +62,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 资源实例的资源Id * @@ -77,11 +81,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceName: 资源实例的资源名称 * @@ -97,11 +100,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * SubResourceType: 资源绑定的虚拟网卡实例的类型 * @@ -117,11 +119,10 @@ public function getSubResourceType() * * @param string $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(string $subResourceType) { $this->set("SubResourceType", $subResourceType); } - /** * SubResourceId: 资源绑定的虚拟网卡实例的资源Id * @@ -137,11 +138,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * SubResourceName: 资源绑定的虚拟网卡实例的资源名称 * @@ -157,11 +157,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * PrivateIP: 后端提供服务的内网IP * @@ -177,11 +176,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * Port: 后端提供服务的端口 * @@ -197,11 +195,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * Enabled: 后端提供服务的实例启用与否,枚举值:0 禁用 1 启用 * @@ -217,11 +214,10 @@ public function getEnabled() * * @param int $enabled */ - public function setEnabled($enabled) + public function setEnabled(int $enabled) { $this->set("Enabled", $enabled); } - /** * Status: 后端提供服务的实例运行状态,枚举值:0健康检查健康状态 1 健康检查异常 * @@ -237,11 +233,10 @@ public function getStatus() * * @param int $status */ - public function setStatus($status) + public function setStatus(int $status) { $this->set("Status", $status); } - /** * SubnetId: 后端提供服务的资源所在的子网的ID * @@ -257,11 +252,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * IsBackup: 是否为backup,只有当vserver的Backup属性为1时才会有此字段,说明:0:主rs1:备rs * @@ -277,7 +271,7 @@ public function getIsBackup() * * @param int $isBackup */ - public function setIsBackup($isBackup) + public function setIsBackup(int $isBackup) { $this->set("IsBackup", $isBackup); } diff --git a/src/ULB/Models/ULBIPSet.php b/src/ULB/Models/ULBIPSet.php index b38976d8..84d6585d 100644 --- a/src/ULB/Models/ULBIPSet.php +++ b/src/ULB/Models/ULBIPSet.php @@ -1,6 +1,7 @@ set("OperatorName", $operatorName); } - /** * EIP: 弹性IP地址 * @@ -57,11 +62,10 @@ public function getEIP() * * @param string $eip */ - public function setEIP($eip) + public function setEIP(string $eip) { $this->set("EIP", $eip); } - /** * EIPId: 弹性IP的ID * @@ -77,11 +81,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * BandwidthType: 弹性IP的带宽类型,枚举值:1 表示是共享带宽,0 普通带宽类型(暂未对外开放) * @@ -97,11 +100,10 @@ public function getBandwidthType() * * @param int $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(int $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * Bandwidth: 弹性IP的带宽值(暂未对外开放) * @@ -117,7 +119,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/ULB/Models/ULBPolicySet.php b/src/ULB/Models/ULBPolicySet.php index c94f507e..ad1647b5 100644 --- a/src/ULB/Models/ULBPolicySet.php +++ b/src/ULB/Models/ULBPolicySet.php @@ -1,6 +1,7 @@ get("DomainMatchMode"); + } + + /** + * DomainMatchMode: 内容转发规则中域名的匹配方式。枚举值:Regular,正则;Wildcard,泛域名 + * + * @param string $domainMatchMode + */ + public function setDomainMatchMode(string $domainMatchMode) + { + $this->set("DomainMatchMode", $domainMatchMode); + } /** * PolicyId: 内容转发Id,默认内容转发类型下为空。 * @@ -37,11 +63,10 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } - /** * PolicyType: 内容类型,枚举值:Custom -> 客户自定义;Default -> 默认内容转发 * @@ -57,11 +82,10 @@ public function getPolicyType() * * @param string $policyType */ - public function setPolicyType($policyType) + public function setPolicyType(string $policyType) { $this->set("PolicyType", $policyType); } - /** * Type: 内容转发匹配字段的类型,枚举值:Domain -> 域名;Path -> 路径; 默认内容转发类型下为空 * @@ -77,11 +101,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Match: 内容转发匹配字段;默认内容转发类型下为空。 * @@ -97,11 +120,10 @@ public function getMatch() * * @param string $match */ - public function setMatch($match) + public function setMatch(string $match) { $this->set("Match", $match); } - /** * PolicyPriority: 内容转发优先级,范围[1,9999],数字越大优先级越高。默认内容转发规则下为0。 * @@ -117,11 +139,10 @@ public function getPolicyPriority() * * @param int $policyPriority */ - public function setPolicyPriority($policyPriority) + public function setPolicyPriority(int $policyPriority) { $this->set("PolicyPriority", $policyPriority); } - /** * VServerId: 所属VServerId * @@ -137,11 +158,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * TotalCount: 默认内容转发类型下返回当前rs总数 * @@ -157,15 +177,14 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } - /** * BackendSet: 内容转发下rs的详细信息,参考PolicyBackendSet * - * @return PolicyBackendSet[]|null + * @return PolicyBackendSetModel[]|null */ public function getBackendSet() { @@ -175,7 +194,7 @@ public function getBackendSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PolicyBackendSet($item)); + array_push($result, new PolicyBackendSetModel($item)); } return $result; } @@ -183,7 +202,7 @@ public function getBackendSet() /** * BackendSet: 内容转发下rs的详细信息,参考PolicyBackendSet * - * @param PolicyBackendSet[] $backendSet + * @param PolicyBackendSetModel[] $backendSet */ public function setBackendSet(array $backendSet) { diff --git a/src/ULB/Models/ULBSSLSet.php b/src/ULB/Models/ULBSSLSet.php index e4820f3e..03b161ca 100644 --- a/src/ULB/Models/ULBSSLSet.php +++ b/src/ULB/Models/ULBSSLSet.php @@ -1,6 +1,7 @@ set("SSLId", $sslId); } - /** * SSLName: SSL证书的名字 * @@ -57,11 +64,10 @@ public function getSSLName() * * @param string $sslName */ - public function setSSLName($sslName) + public function setSSLName(string $sslName) { $this->set("SSLName", $sslName); } - /** * SSLType: SSL证书类型,暂时只有 Pem 一种类型 * @@ -77,11 +83,10 @@ public function getSSLType() * * @param string $sslType */ - public function setSSLType($sslType) + public function setSSLType(string $sslType) { $this->set("SSLType", $sslType); } - /** * SSLContent: SSL证书的内容 * @@ -97,11 +102,10 @@ public function getSSLContent() * * @param string $sslContent */ - public function setSSLContent($sslContent) + public function setSSLContent(string $sslContent) { $this->set("SSLContent", $sslContent); } - /** * CreateTime: SSL证书的创建时间 * @@ -117,11 +121,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * HashValue: SSL证书的HASH值 * @@ -137,15 +140,14 @@ public function getHashValue() * * @param string $hashValue */ - public function setHashValue($hashValue) + public function setHashValue(string $hashValue) { $this->set("HashValue", $hashValue); } - /** * BindedTargetSet: SSL证书绑定到的对象 * - * @return SSLBindedTargetSet[]|null + * @return SSLBindedTargetSetModel[]|null */ public function getBindedTargetSet() { @@ -155,7 +157,7 @@ public function getBindedTargetSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SSLBindedTargetSet($item)); + array_push($result, new SSLBindedTargetSetModel($item)); } return $result; } @@ -163,7 +165,7 @@ public function getBindedTargetSet() /** * BindedTargetSet: SSL证书绑定到的对象 * - * @param SSLBindedTargetSet[] $bindedTargetSet + * @param SSLBindedTargetSetModel[] $bindedTargetSet */ public function setBindedTargetSet(array $bindedTargetSet) { diff --git a/src/ULB/Models/ULBSet.php b/src/ULB/Models/ULBSet.php index 0630464a..ced7f228 100644 --- a/src/ULB/Models/ULBSet.php +++ b/src/ULB/Models/ULBSet.php @@ -1,6 +1,7 @@ set("ULBId", $ulbId); } - /** * Name: 负载均衡的资源名称 * @@ -57,11 +68,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 负载均衡的业务组名称 * @@ -77,11 +87,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 负载均衡的备注 * @@ -97,11 +106,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * BandwidthType: 带宽类型,枚举值为: 0,非共享带宽; 1,共享带宽 * @@ -117,11 +125,10 @@ public function getBandwidthType() * * @param int $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(int $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * Bandwidth: 带宽 * @@ -137,11 +144,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * CreateTime: ULB的创建时间,格式为Unix Timestamp * @@ -157,15 +163,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * IPSet: ULB的详细信息列表,具体结构见下方 ULBIPSet * - * @return ULBIPSet[]|null + * @return ULBIPSetModel[]|null */ public function getIPSet() { @@ -175,7 +180,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBIPSet($item)); + array_push($result, new ULBIPSetModel($item)); } return $result; } @@ -183,7 +188,7 @@ public function getIPSet() /** * IPSet: ULB的详细信息列表,具体结构见下方 ULBIPSet * - * @param ULBIPSet[] $ipSet + * @param ULBIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -193,11 +198,10 @@ public function setIPSet(array $ipSet) } return $result; } - /** * VServerSet: 负载均衡实例中存在的VServer实例列表,具体结构见下方 ULBVServerSet * - * @return ULBVServerSet[]|null + * @return ULBVServerSetModel[]|null */ public function getVServerSet() { @@ -207,7 +211,7 @@ public function getVServerSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBVServerSet($item)); + array_push($result, new ULBVServerSetModel($item)); } return $result; } @@ -215,7 +219,7 @@ public function getVServerSet() /** * VServerSet: 负载均衡实例中存在的VServer实例列表,具体结构见下方 ULBVServerSet * - * @param ULBVServerSet[] $vServerSet + * @param ULBVServerSetModel[] $vServerSet */ public function setVServerSet(array $vServerSet) { @@ -225,7 +229,6 @@ public function setVServerSet(array $vServerSet) } return $result; } - /** * ULBType: ULB 的类型 * @@ -241,11 +244,10 @@ public function getULBType() * * @param string $ulbType */ - public function setULBType($ulbType) + public function setULBType(string $ulbType) { $this->set("ULBType", $ulbType); } - /** * IPVersion: ULB ip类型,枚举值:IPv6 / IPv4 (内部测试,暂未对外开放) * @@ -261,11 +263,10 @@ public function getIPVersion() * * @param string $ipVersion */ - public function setIPVersion($ipVersion) + public function setIPVersion(string $ipVersion) { $this->set("IPVersion", $ipVersion); } - /** * ListenType: ULB 监听器类型,枚举值:RequestProxy,请求代理; PacketsTransmit ,报文转发;Comprehensive,兼容型;Pending,未定型 * @@ -281,11 +282,10 @@ public function getListenType() * * @param string $listenType */ - public function setListenType($listenType) + public function setListenType(string $listenType) { $this->set("ListenType", $listenType); } - /** * VPCId: ULB所在的VPC的ID * @@ -301,11 +301,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: ULB 为 InnerMode 时,ULB 所属的子网ID,默认为空 * @@ -321,11 +320,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * BusinessId: ULB 所属的业务组ID * @@ -341,11 +339,10 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } - /** * PrivateIP: ULB的内网IP,当ULBType为OuterMode时,该值为空 * @@ -361,15 +358,14 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * FirewallSet: 防火墙信息,具体结构见下方 FirewallSet * - * @return FirewallSet[]|null + * @return FirewallSetModel[]|null */ public function getFirewallSet() { @@ -379,7 +375,7 @@ public function getFirewallSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new FirewallSet($item)); + array_push($result, new FirewallSetModel($item)); } return $result; } @@ -387,7 +383,7 @@ public function getFirewallSet() /** * FirewallSet: 防火墙信息,具体结构见下方 FirewallSet * - * @param FirewallSet[] $firewallSet + * @param FirewallSetModel[] $firewallSet */ public function setFirewallSet(array $firewallSet) { @@ -397,7 +393,6 @@ public function setFirewallSet(array $firewallSet) } return $result; } - /** * EnableLog: ULB是否开启日志功能。0,关闭;1,开启 * @@ -413,27 +408,26 @@ public function getEnableLog() * * @param int $enableLog */ - public function setEnableLog($enableLog) + public function setEnableLog(int $enableLog) { $this->set("EnableLog", $enableLog); } - /** * LogSet: 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet * - * @return LoggerSet|null + * @return LoggerSetModel|null */ public function getLogSet() { - return new LoggerSet($this->get("LogSet")); + return new LoggerSetModel($this->get("LogSet")); } /** * LogSet: 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet * - * @param LoggerSet $logSet + * @param LoggerSetModel $logSet */ - public function setLogSet(array $logSet) + public function setLogSet(LoggerSetModel $logSet) { $this->set("LogSet", $logSet->getAll()); } diff --git a/src/ULB/Models/ULBSimpleSet.php b/src/ULB/Models/ULBSimpleSet.php index 81f17a76..dc955490 100644 --- a/src/ULB/Models/ULBSimpleSet.php +++ b/src/ULB/Models/ULBSimpleSet.php @@ -1,6 +1,7 @@ set("ListenType", $listenType); } - /** * IPVersion: ULB提供服务的IP类型。枚举值,“IPv4”,"IPv6"。默认为“IPv4” * @@ -57,11 +62,10 @@ public function getIPVersion() * * @param string $ipVersion */ - public function setIPVersion($ipVersion) + public function setIPVersion(string $ipVersion) { $this->set("IPVersion", $ipVersion); } - /** * ULBId: 负载均衡的资源ID * @@ -77,11 +81,10 @@ public function getULBId() * * @param string $ulbId */ - public function setULBId($ulbId) + public function setULBId(string $ulbId) { $this->set("ULBId", $ulbId); } - /** * Name: 负载均衡的资源名称 * @@ -97,11 +100,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 负载均衡的业务组名称 * @@ -117,11 +119,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 负载均衡的备注 * @@ -137,11 +138,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * CreateTime: ULB的创建时间,格式为Unix Timestamp * @@ -157,11 +157,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * VPCId: ULB所在的VPC的ID * @@ -177,11 +176,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: ULB 为 InnerMode 时,ULB 所属的子网ID * @@ -197,11 +195,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * BusinessId: ULB 所属的业务组ID * @@ -217,11 +214,10 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } - /** * PrivateIP: ULB的内网IP,当ULBType为OuterMode时,该值为空 * @@ -237,11 +233,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * BandwidthType: 带宽类型,枚举值为: 0,非共享带宽; 1,共享带宽 * @@ -257,11 +252,10 @@ public function getBandwidthType() * * @param int $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(int $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * Bandwidth: 带宽 * @@ -277,15 +271,14 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * IPSet: ULB的详细信息列表,具体结构见下方 ULBIPSet * - * @return ULBIPSet[]|null + * @return ULBIPSetModel[]|null */ public function getIPSet() { @@ -295,7 +288,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBIPSet($item)); + array_push($result, new ULBIPSetModel($item)); } return $result; } @@ -303,7 +296,7 @@ public function getIPSet() /** * IPSet: ULB的详细信息列表,具体结构见下方 ULBIPSet * - * @param ULBIPSet[] $ipSet + * @param ULBIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -313,7 +306,6 @@ public function setIPSet(array $ipSet) } return $result; } - /** * VServerCount: ulb下vserver数量 * @@ -329,11 +321,10 @@ public function getVServerCount() * * @param int $vServerCount */ - public function setVServerCount($vServerCount) + public function setVServerCount(int $vServerCount) { $this->set("VServerCount", $vServerCount); } - /** * ULBType: ULB 的类型(InnerMode or OuterMode) * @@ -349,15 +340,14 @@ public function getULBType() * * @param string $ulbType */ - public function setULBType($ulbType) + public function setULBType(string $ulbType) { $this->set("ULBType", $ulbType); } - /** * FirewallSet: 防火墙信息,具体结构见下方 FirewallSet * - * @return FirewallSet[]|null + * @return FirewallSetModel[]|null */ public function getFirewallSet() { @@ -367,7 +357,7 @@ public function getFirewallSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new FirewallSet($item)); + array_push($result, new FirewallSetModel($item)); } return $result; } @@ -375,7 +365,7 @@ public function getFirewallSet() /** * FirewallSet: 防火墙信息,具体结构见下方 FirewallSet * - * @param FirewallSet[] $firewallSet + * @param FirewallSetModel[] $firewallSet */ public function setFirewallSet(array $firewallSet) { @@ -385,7 +375,6 @@ public function setFirewallSet(array $firewallSet) } return $result; } - /** * EnableLog: ULB是否开启日志功能。0,关闭;1,开启 * @@ -401,27 +390,26 @@ public function getEnableLog() * * @param int $enableLog */ - public function setEnableLog($enableLog) + public function setEnableLog(int $enableLog) { $this->set("EnableLog", $enableLog); } - /** * LogSet: 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet * - * @return LoggerSet|null + * @return LoggerSetModel|null */ public function getLogSet() { - return new LoggerSet($this->get("LogSet")); + return new LoggerSetModel($this->get("LogSet")); } /** * LogSet: 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet * - * @param LoggerSet $logSet + * @param LoggerSetModel $logSet */ - public function setLogSet(array $logSet) + public function setLogSet(LoggerSetModel $logSet) { $this->set("LogSet", $logSet->getAll()); } diff --git a/src/ULB/Models/ULBVServerSet.php b/src/ULB/Models/ULBVServerSet.php index e56e6b7a..fea446c0 100644 --- a/src/ULB/Models/ULBVServerSet.php +++ b/src/ULB/Models/ULBVServerSet.php @@ -1,6 +1,7 @@ 端口检查;Path -> 路径检查;Ping -> Ping探测, Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path; 报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize @@ -37,11 +47,29 @@ public function getMonitorType() * * @param string $monitorType */ - public function setMonitorType($monitorType) + public function setMonitorType(string $monitorType) { $this->set("MonitorType", $monitorType); } + /** + * ULBId: 负载均衡实例的Id + * + * @return string|null + */ + public function getULBId() + { + return $this->get("ULBId"); + } + /** + * ULBId: 负载均衡实例的Id + * + * @param string $ulbId + */ + public function setULBId(string $ulbId) + { + $this->set("ULBId", $ulbId); + } /** * Domain: 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查域名 * @@ -57,11 +85,10 @@ public function getDomain() * * @param string $domain */ - public function setDomain($domain) + public function setDomain(string $domain) { $this->set("Domain", $domain); } - /** * Path: 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查路径 * @@ -77,11 +104,10 @@ public function getPath() * * @param string $path */ - public function setPath($path) + public function setPath(string $path) { $this->set("Path", $path); } - /** * RequestMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 * @@ -97,11 +123,10 @@ public function getRequestMsg() * * @param string $requestMsg */ - public function setRequestMsg($requestMsg) + public function setRequestMsg(string $requestMsg) { $this->set("RequestMsg", $requestMsg); } - /** * ResponseMsg: 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 * @@ -117,11 +142,10 @@ public function getResponseMsg() * * @param string $responseMsg */ - public function setResponseMsg($responseMsg) + public function setResponseMsg(string $responseMsg) { $this->set("ResponseMsg", $responseMsg); } - /** * VServerId: VServer实例的Id * @@ -137,11 +161,10 @@ public function getVServerId() * * @param string $vServerId */ - public function setVServerId($vServerId) + public function setVServerId(string $vServerId) { $this->set("VServerId", $vServerId); } - /** * VServerName: VServer实例的名字 * @@ -157,11 +180,10 @@ public function getVServerName() * * @param string $vServerName */ - public function setVServerName($vServerName) + public function setVServerName(string $vServerName) { $this->set("VServerName", $vServerName); } - /** * Protocol: VServer实例的协议。 枚举值为:HTTP,TCP,UDP,HTTPS。 * @@ -177,11 +199,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * FrontendPort: VServer服务端口 * @@ -197,11 +218,10 @@ public function getFrontendPort() * * @param int $frontendPort */ - public function setFrontendPort($frontendPort) + public function setFrontendPort(int $frontendPort) { $this->set("FrontendPort", $frontendPort); } - /** * Method: VServer负载均衡的模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口)。 * @@ -217,11 +237,10 @@ public function getMethod() * * @param string $method */ - public function setMethod($method) + public function setMethod(string $method) { $this->set("Method", $method); } - /** * PersistenceType: VServer会话保持方式。枚举值为: None -> 关闭会话保持; ServerInsert -> 自动生成; UserDefined -> 用户自定义。 * @@ -237,11 +256,10 @@ public function getPersistenceType() * * @param string $persistenceType */ - public function setPersistenceType($persistenceType) + public function setPersistenceType(string $persistenceType) { $this->set("PersistenceType", $persistenceType); } - /** * PersistenceInfo: 根据PersistenceType确定: None或ServerInsert,此字段为空; UserDefined,此字段展示用户自定义会话string。 * @@ -257,11 +275,10 @@ public function getPersistenceInfo() * * @param string $persistenceInfo */ - public function setPersistenceInfo($persistenceInfo) + public function setPersistenceInfo(string $persistenceInfo) { $this->set("PersistenceInfo", $persistenceInfo); } - /** * ClientTimeout: 空闲连接的回收时间,单位:秒。 * @@ -277,11 +294,10 @@ public function getClientTimeout() * * @param int $clientTimeout */ - public function setClientTimeout($clientTimeout) + public function setClientTimeout(int $clientTimeout) { $this->set("ClientTimeout", $clientTimeout); } - /** * Status: VServer的运行状态。枚举值: 0 -> rs全部运行正常;1 -> rs全部运行异常;2 -> rs部分运行异常。 * @@ -297,15 +313,14 @@ public function getStatus() * * @param int $status */ - public function setStatus($status) + public function setStatus(int $status) { $this->set("Status", $status); } - /** * SSLSet: VServer绑定的SSL证书信息,具体结构见下方 ULBSSLSet。 * - * @return ULBSSLSet[]|null + * @return ULBSSLSetModel[]|null */ public function getSSLSet() { @@ -315,7 +330,7 @@ public function getSSLSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBSSLSet($item)); + array_push($result, new ULBSSLSetModel($item)); } return $result; } @@ -323,7 +338,7 @@ public function getSSLSet() /** * SSLSet: VServer绑定的SSL证书信息,具体结构见下方 ULBSSLSet。 * - * @param ULBSSLSet[] $sslSet + * @param ULBSSLSetModel[] $sslSet */ public function setSSLSet(array $sslSet) { @@ -333,11 +348,10 @@ public function setSSLSet(array $sslSet) } return $result; } - /** * BackendSet: 后端资源信息列表,具体结构见下方 ULBBackendSet * - * @return ULBBackendSet[]|null + * @return ULBBackendSetModel[]|null */ public function getBackendSet() { @@ -347,7 +361,7 @@ public function getBackendSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBBackendSet($item)); + array_push($result, new ULBBackendSetModel($item)); } return $result; } @@ -355,7 +369,7 @@ public function getBackendSet() /** * BackendSet: 后端资源信息列表,具体结构见下方 ULBBackendSet * - * @param ULBBackendSet[] $backendSet + * @param ULBBackendSetModel[] $backendSet */ public function setBackendSet(array $backendSet) { @@ -365,7 +379,6 @@ public function setBackendSet(array $backendSet) } return $result; } - /** * ListenType: 监听器类型,枚举值为: RequestProxy -> 请求代理;PacketsTransmit -> 报文转发 * @@ -381,15 +394,14 @@ public function getListenType() * * @param string $listenType */ - public function setListenType($listenType) + public function setListenType(string $listenType) { $this->set("ListenType", $listenType); } - /** * PolicySet: 内容转发信息列表,具体结构见下方 ULBPolicySet * - * @return ULBPolicySet[]|null + * @return ULBPolicySetModel[]|null */ public function getPolicySet() { @@ -399,7 +411,7 @@ public function getPolicySet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ULBPolicySet($item)); + array_push($result, new ULBPolicySetModel($item)); } return $result; } @@ -407,7 +419,7 @@ public function getPolicySet() /** * PolicySet: 内容转发信息列表,具体结构见下方 ULBPolicySet * - * @param ULBPolicySet[] $policySet + * @param ULBPolicySetModel[] $policySet */ public function setPolicySet(array $policySet) { diff --git a/src/ULB/ULBClient.php b/src/ULB/ULBClient.php index dff26f54..246cc88c 100644 --- a/src/ULB/ULBClient.php +++ b/src/ULB/ULBClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 负载均衡实例的ID - * "VServerId" => (string) VServer实例的ID - * "ResourceType" => (string) 所添加的后端资源的类型,枚举值:UHost -> 云主机;UNI -> 虚拟网卡;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;默认值为UHost。报文转发模式不支持UDocker、UHybrid、CUBE - * "ResourceId" => (string) 所添加的后端资源的资源ID - * "ResourceIP" => (string) 所添加的后端服务器的资源实例IP,当ResourceType 为 UHybrid 时有效,且必填 - * "VPCId" => (string) 所添加的后端服务器所在的vpc,当ResourceType 为 UHybrid 时有效,且必填 - * "SubnetId" => (string) 所添加的后端服务器所在的子网,当ResourceType 为 UHybrid 时有效,且必填 - * "Port" => (integer) 所添加的后端资源服务端口,取值范围[1-65535],默认80 - * "Weight" => (integer) 所添加的后端RS权重(在加权轮询算法下有效),取值范围[0-100],默认为1 - * "Enabled" => (integer) 后端实例状态开关,枚举值: 1:启用; 0:禁用 默认为启用 - * "IsBackup" => (integer) rs是否为backup,默认为00:普通rs1:backup的rs - * ] - * - * Outputs: - * - * $outputs = [ - * "BackendId" => (string) 所添加的后端资源在ULB中的对象ID,(为ULB系统中使用,与资源自身ID无关),可用于 UpdateBackendAttribute/UpdateBackendAttributeBatch/ReleaseBackend - * ] - * - * @return AllocateBackendResponse * @throws UCloudException */ public function allocateBackend(AllocateBackendRequest $request = null) @@ -102,28 +146,13 @@ public function allocateBackend(AllocateBackendRequest $request = null) $resp = $this->invoke($request); return new AllocateBackendResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * BindSSL - 将SSL证书绑定到VServer * - * See also: https://docs.ucloud.cn/api/ulb-api/bind_ssl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 所绑定ULB实例ID - * "VServerId" => (string) 所绑定VServer实例ID - * "SSLId" => (string) SSL证书的Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BindSSLResponse * @throws UCloudException */ public function bindSSL(BindSSLRequest $request = null) @@ -131,32 +160,13 @@ public function bindSSL(BindSSLRequest $request = null) $resp = $this->invoke($request); return new BindSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreatePolicy - 创建VServer内容转发策略 * - * See also: https://docs.ucloud.cn/api/ulb-api/create_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 需要添加内容转发策略的负载均衡实例ID - * "VServerId" => (string) 需要添加内容转发策略的VServer实例ID - * "BackendId" => (array) 内容转发策略应用的后端资源实例的ID,来源于 AllocateBackend 返回的 BackendId - * "Match" => (string) 内容转发匹配字段 - * "Type" => (string) 内容转发匹配字段的类型 - * "PolicyPriority" => (integer) 策略优先级,1-9999 - * ] - * - * Outputs: - * - * $outputs = [ - * "PolicyId" => (string) 内容转发策略ID - * ] - * - * @return CreatePolicyResponse * @throws UCloudException */ public function createPolicy(CreatePolicyRequest $request = null) @@ -164,32 +174,13 @@ public function createPolicy(CreatePolicyRequest $request = null) $resp = $this->invoke($request); return new CreatePolicyResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateSSL - 创建SSL证书,可以把整个 Pem 证书内容传过来,或者把证书、私钥、CA证书分别传过来 * - * See also: https://docs.ucloud.cn/api/ulb-api/create_ssl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLName" => (string) SSL证书的名字,默认值为空 - * "SSLType" => (string) 所添加的SSL证书类型,目前只支持Pem格式 - * "SSLContent" => (string) SSL证书的完整内容,包括用户证书、加密证书的私钥、CA证书 - * "UserCert" => (string) 用户的证书 - * "PrivateKey" => (string) 加密证书的私钥 - * "CaCert" => (string) CA证书 - * ] - * - * Outputs: - * - * $outputs = [ - * "SSLId" => (string) SSL证书的Id - * ] - * - * @return CreateSSLResponse * @throws UCloudException */ public function createSSL(CreateSSLRequest $request = null) @@ -197,38 +188,13 @@ public function createSSL(CreateSSLRequest $request = null) $resp = $this->invoke($request); return new CreateSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateULB - 创建负载均衡实例,可以选择内网或者外网 * - * See also: https://docs.ucloud.cn/api/ulb-api/create_ulb - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ULBName" => (string) 负载均衡的名字,默认值为“ULB” - * "Tag" => (string) 业务组 - * "Remark" => (string) 备注 - * "OuterMode" => (string) 创建的ULB是否为外网模式,默认即为外网模式 - * "InnerMode" => (string) 创建的ULB是否为内网模式 - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费 - * "VPCId" => (string) ULB所在的VPC的ID, 如果不传则使用默认的VPC - * "SubnetId" => (string) ULB 所属的子网ID,如果不传则随机选择一个。 - * "BusinessId" => (string) ULB 所属的业务组ID,如果不传则使用默认的业务组 - * "FirewallId" => (string) 防火墙ID,如果不传,则默认不绑定防火墙 - * "ListenType" => (string) ULB 监听器类型,外网ULB默认RequestProxy,内网ULB默认PacketsTransmit。枚举值:RequestProxy,请求代理; PacketsTransmit ,报文转发。 - * ] - * - * Outputs: - * - * $outputs = [ - * "ULBId" => (string) 负载均衡实例的Id - * "IPv6AddressId" => (string) IPv6地址Id - * ] - * - * @return CreateULBResponse * @throws UCloudException */ public function createULB(CreateULBRequest $request = null) @@ -236,40 +202,13 @@ public function createULB(CreateULBRequest $request = null) $resp = $this->invoke($request); return new CreateULBResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateVServer - 创建VServer实例,定义监听的协议和端口以及负载均衡算法 * - * See also: https://docs.ucloud.cn/api/ulb-api/create_vserver - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ULBId" => (string) 负载均衡实例ID - * "VServerName" => (string) VServer实例名称,默认为"VServer" - * "ListenType" => (string) 监听器类型,枚举值,RequestProxy ,请求代理;PacketsTransmit ,报文转发。默认为RequestProxy - * "Protocol" => (string) VServer实例的协议,请求代理模式下有 HTTP、HTTPS、TCP,报文转发下有 TCP,UDP。默认为“HTTP" - * "FrontendPort" => (integer) VServer后端端口,取值范围[1-65535];默认值为80 - * "Method" => (string) VServer负载均衡模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口); WeightRoundrobin -> 加权轮询; Leastconn -> 最小连接数;Backup ->主备模式。ConsistentHash,SourcePort,ConsistentHashPort 只在报文转发中使用;Leastconn只在请求代理中使用;Roundrobin、Source和WeightRoundrobin,Backup在请求代理和报文转发中使用。默认为:"Roundrobin" - * "PersistenceType" => (string) VServer会话保持方式,默认关闭会话保持。枚举值:None -> 关闭;ServerInsert -> 自动生成KEY;UserDefined -> 用户自定义KEY。 - * "PersistenceInfo" => (string) 根据PersistenceType确认; None和ServerInsert: 此字段无意义; UserDefined:此字段传入自定义会话保持String - * "ClientTimeout" => (integer) ListenType为RequestProxy时表示空闲连接的回收时间,单位:秒,取值范围:时(0,86400],默认值为60;ListenType为PacketsTransmit时表示连接保持的时间,单位:秒,取值范围:[60,900],0 表示禁用连接保持 - * "MonitorType" => (string) 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测;Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path;报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize,默认值为Ping - * "Domain" => (string) 根据MonitorType确认; 当MonitorType为Path时,此字段有意义,代表HTTP检查域名 - * "Path" => (string) 根据MonitorType确认; 当MonitorType为Path时,此字段有意义,代表HTTP检查路径 - * "RequestMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 - * "ResponseMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 - * ] - * - * Outputs: - * - * $outputs = [ - * "VServerId" => (string) VServer实例的Id - * ] - * - * @return CreateVServerResponse * @throws UCloudException */ public function createVServer(CreateVServerRequest $request = null) @@ -277,27 +216,13 @@ public function createVServer(CreateVServerRequest $request = null) $resp = $this->invoke($request); return new CreateVServerResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeletePolicy - 删除内容转发策略 * - * See also: https://docs.ucloud.cn/api/ulb-api/delete_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PolicyId" => (string) 内容转发策略ID - * "VServerId" => (string) VServer 资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeletePolicyResponse * @throws UCloudException */ public function deletePolicy(DeletePolicyRequest $request = null) @@ -305,26 +230,13 @@ public function deletePolicy(DeletePolicyRequest $request = null) $resp = $this->invoke($request); return new DeletePolicyResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteSSL - 删除SSL证书 * - * See also: https://docs.ucloud.cn/api/ulb-api/delete_ssl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLId" => (string) SSL证书的ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteSSLResponse * @throws UCloudException */ public function deleteSSL(DeleteSSLRequest $request = null) @@ -332,27 +244,13 @@ public function deleteSSL(DeleteSSLRequest $request = null) $resp = $this->invoke($request); return new DeleteSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteULB - 删除负载均衡实例 * - * See also: https://docs.ucloud.cn/api/ulb-api/delete_ulb - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 负载均衡实例的ID - * "ReleaseEip" => (boolean) 删除ulb时是否释放绑定的EIP,false标识只解绑EIP,true表示会释放绑定的EIP,默认是false。Anycast IP 此参数无效 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteULBResponse * @throws UCloudException */ public function deleteULB(DeleteULBRequest $request = null) @@ -360,27 +258,13 @@ public function deleteULB(DeleteULBRequest $request = null) $resp = $this->invoke($request); return new DeleteULBResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteVServer - 删除VServer实例 * - * See also: https://docs.ucloud.cn/api/ulb-api/delete_vserver - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 负载均衡实例的ID - * "VServerId" => (string) VServer实例的ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteVServerResponse * @throws UCloudException */ public function deleteVServer(DeleteVServerRequest $request = null) @@ -388,47 +272,13 @@ public function deleteVServer(DeleteVServerRequest $request = null) $resp = $this->invoke($request); return new DeleteVServerResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeSSL - 获取SSL证书信息 * - * See also: https://docs.ucloud.cn/api/ulb-api/describe_ssl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SSLId" => (string) SSL证书的Id - * "Limit" => (integer) 数据分页值,默认为20 - * "Offset" => (integer) 数据偏移量,默认值为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的SSL证书总数 - * "DataSet" => (array) SSL证书详细信息,具体结构见 ULBSSLSet[ - * [ - * "SSLId" => (string) SSL证书的Id - * "SSLName" => (string) SSL证书的名字 - * "SSLType" => (string) SSL证书类型,暂时只有 Pem 一种类型 - * "SSLContent" => (string) SSL证书的内容 - * "CreateTime" => (integer) SSL证书的创建时间 - * "HashValue" => (string) SSL证书的HASH值 - * "BindedTargetSet" => (array) SSL证书绑定到的对象[ - * [ - * "VServerId" => (string) SSL证书绑定到的VServer的资源ID - * "VServerName" => (string) 对应的VServer的名字 - * "ULBId" => (string) VServer 所属的ULB实例的资源ID - * "ULBName" => (string) ULB实例的名称 - * ] - * ] - * ] - * ] - * ] - * - * @return DescribeSSLResponse * @throws UCloudException */ public function describeSSL(DescribeSSLRequest $request = null) @@ -436,149 +286,13 @@ public function describeSSL(DescribeSSLRequest $request = null) $resp = $this->invoke($request); return new DescribeSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeULB - 获取ULB详细信息 * - * See also: https://docs.ucloud.cn/api/ulb-api/describe_ulb - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 数据偏移量,默认为0 - * "Limit" => (integer) 数据分页值,默认为20 - * "ULBId" => (string) 负载均衡实例的Id。 若指定则返回指定的负载均衡实例的信息; 若不指定则返回当前数据中心中所有的负载均衡实例的信息 - * "VPCId" => (string) ULB所属的VPC - * "SubnetId" => (string) ULB所属的子网ID - * "BusinessId" => (string) ULB所属的业务组ID - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的ULB总数 - * "DataSet" => (array) ULB列表,每项参数详见 ULBSet[ - * [ - * "ULBId" => (string) 负载均衡的资源ID - * "Name" => (string) 负载均衡的资源名称 - * "Tag" => (string) 负载均衡的业务组名称 - * "Remark" => (string) 负载均衡的备注 - * "BandwidthType" => (integer) 带宽类型,枚举值为: 0,非共享带宽; 1,共享带宽 - * "Bandwidth" => (integer) 带宽 - * "CreateTime" => (integer) ULB的创建时间,格式为Unix Timestamp - * "IPSet" => (array) ULB的详细信息列表,具体结构见下方 ULBIPSet[ - * [ - * "OperatorName" => (string) 弹性IP的运营商信息,枚举值为: Bgp:BGP IP International:国际IP - * "EIP" => (string) 弹性IP地址 - * "EIPId" => (string) 弹性IP的ID - * "BandwidthType" => (integer) 弹性IP的带宽类型,枚举值:1 表示是共享带宽,0 普通带宽类型(暂未对外开放) - * "Bandwidth" => (integer) 弹性IP的带宽值(暂未对外开放) - * ] - * ] - * "VServerSet" => (array) 负载均衡实例中存在的VServer实例列表,具体结构见下方 ULBVServerSet[ - * [ - * "MonitorType" => (string) 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测, Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path; 报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize - * "Domain" => (string) 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查域名 - * "Path" => (string) 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查路径 - * "RequestMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 - * "ResponseMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 - * "VServerId" => (string) VServer实例的Id - * "VServerName" => (string) VServer实例的名字 - * "Protocol" => (string) VServer实例的协议。 枚举值为:HTTP,TCP,UDP,HTTPS。 - * "FrontendPort" => (integer) VServer服务端口 - * "Method" => (string) VServer负载均衡的模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口)。 - * "PersistenceType" => (string) VServer会话保持方式。枚举值为: None -> 关闭会话保持; ServerInsert -> 自动生成; UserDefined -> 用户自定义。 - * "PersistenceInfo" => (string) 根据PersistenceType确定: None或ServerInsert,此字段为空; UserDefined,此字段展示用户自定义会话string。 - * "ClientTimeout" => (integer) 空闲连接的回收时间,单位:秒。 - * "Status" => (integer) VServer的运行状态。枚举值: 0 -> rs全部运行正常;1 -> rs全部运行异常;2 -> rs部分运行异常。 - * "SSLSet" => (array) VServer绑定的SSL证书信息,具体结构见下方 ULBSSLSet。[ - * [ - * "SSLId" => (string) SSL证书的Id - * "SSLName" => (string) SSL证书的名字 - * "SSLType" => (string) SSL证书类型,暂时只有 Pem 一种类型 - * "SSLContent" => (string) SSL证书的内容 - * "CreateTime" => (integer) SSL证书的创建时间 - * "HashValue" => (string) SSL证书的HASH值 - * "BindedTargetSet" => (array) SSL证书绑定到的对象[ - * [ - * "VServerId" => (string) SSL证书绑定到的VServer的资源ID - * "VServerName" => (string) 对应的VServer的名字 - * "ULBId" => (string) VServer 所属的ULB实例的资源ID - * "ULBName" => (string) ULB实例的名称 - * ] - * ] - * ] - * ] - * "BackendSet" => (array) 后端资源信息列表,具体结构见下方 ULBBackendSet[ - * [ - * "BackendId" => (string) 后端资源实例的Id - * "ResourceType" => (string) 资源实例的类型 - * "ResourceId" => (string) 资源实例的资源Id - * "ResourceName" => (string) 资源实例的资源名称 - * "SubResourceType" => (string) 资源绑定的虚拟网卡实例的类型 - * "SubResourceId" => (string) 资源绑定的虚拟网卡实例的资源Id - * "SubResourceName" => (string) 资源绑定的虚拟网卡实例的资源名称 - * "PrivateIP" => (string) 后端提供服务的内网IP - * "Port" => (integer) 后端提供服务的端口 - * "Enabled" => (integer) 后端提供服务的实例启用与否,枚举值:0 禁用 1 启用 - * "Status" => (integer) 后端提供服务的实例运行状态,枚举值:0健康检查健康状态 1 健康检查异常 - * "SubnetId" => (string) 后端提供服务的资源所在的子网的ID - * "IsBackup" => (integer) 是否为backup,只有当vserver的Backup属性为1时才会有此字段,说明:0:主rs1:备rs - * ] - * ] - * "ListenType" => (string) 监听器类型,枚举值为: RequestProxy -> 请求代理;PacketsTransmit -> 报文转发 - * "PolicySet" => (array) 内容转发信息列表,具体结构见下方 ULBPolicySet[ - * [ - * "PolicyId" => (string) 内容转发Id,默认内容转发类型下为空。 - * "PolicyType" => (string) 内容类型,枚举值:Custom -> 客户自定义;Default -> 默认内容转发 - * "Type" => (string) 内容转发匹配字段的类型,枚举值:Domain -> 域名;Path -> 路径; 默认内容转发类型下为空 - * "Match" => (string) 内容转发匹配字段;默认内容转发类型下为空。 - * "PolicyPriority" => (integer) 内容转发优先级,范围[1,9999],数字越大优先级越高。默认内容转发规则下为0。 - * "VServerId" => (string) 所属VServerId - * "TotalCount" => (integer) 默认内容转发类型下返回当前rs总数 - * "BackendSet" => (array) 内容转发下rs的详细信息,参考PolicyBackendSet[ - * [ - * "BackendId" => (string) 所添加的后端资源在ULB中的对象ID,(为ULB系统中使用,与资源自身ID无关 - * "ResourceType" => (string) 所添加的后端资源的类型,枚举值:UHost -> 云主机;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;UNI -> 虚拟网卡 - * "ResourceName" => (string) 后端资源的实例名称 - * "SubResourceId" => (string) 如果资源绑定了弹性网卡,则展示弹性网卡的资源ID - * "SubResourceName" => (string) 如果资源绑定了弹性网卡,则展示弹性网卡的资源名称 - * "SubResourceType" => (string) "UNI"或者为空 - * "ObjectId" => (string) 后端资源的对象ID - * "Port" => (integer) 所添加的后端资源服务端口 - * "PrivateIP" => (string) 后端资源的内网IP - * ] - * ] - * ] - * ] - * ] - * ] - * "ULBType" => (string) ULB 的类型 - * "IPVersion" => (string) ULB ip类型,枚举值:IPv6 / IPv4 (内部测试,暂未对外开放) - * "ListenType" => (string) ULB 监听器类型,枚举值:RequestProxy,请求代理; PacketsTransmit ,报文转发;Comprehensive,兼容型;Pending,未定型 - * "VPCId" => (string) ULB所在的VPC的ID - * "SubnetId" => (string) ULB 为 InnerMode 时,ULB 所属的子网ID,默认为空 - * "BusinessId" => (string) ULB 所属的业务组ID - * "PrivateIP" => (string) ULB的内网IP,当ULBType为OuterMode时,该值为空 - * "FirewallSet" => (array) 防火墙信息,具体结构见下方 FirewallSet[ - * [ - * "FirewallName" => (string) 防火墙名称 - * "FirewallId" => (string) 防火墙ID - * ] - * ] - * "EnableLog" => (integer) ULB是否开启日志功能。0,关闭;1,开启 - * "LogSet" => (object) 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet[ - * "BucketName" => (string) ulb日志上传的bucket - * "TokenID" => (string) 上传到bucket使用的token的tokenid - * "TokenName" => (string) bucket的token名称 - * ] - * ] - * ] - * ] - * - * @return DescribeULBResponse * @throws UCloudException */ public function describeULB(DescribeULBRequest $request = null) @@ -586,72 +300,13 @@ public function describeULB(DescribeULBRequest $request = null) $resp = $this->invoke($request); return new DescribeULBResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeULBSimple - 获取ULB信息 * - * See also: https://docs.ucloud.cn/api/ulb-api/describe_ulb_simple - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Offset" => (integer) 数据偏移量,默认为0 - * "Limit" => (integer) 数据分页值,默认为10000 - * "ULBId" => (string) 负载均衡实例的Id。 若指定则返回指定的负载均衡实例的信息; 若不指定则返回当前数据中心中所有的负载均衡实例的信息 - * "VPCId" => (string) ULB所属的VPC - * "SubnetId" => (string) ULB所属的子网ID - * "BusinessId" => (string) ULB所属的业务组ID - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的ULB总数 - * "DataSet" => (array) ULB列表,每项参数详见 ULBSimpleSet[ - * [ - * "ListenType" => (string) ULB 监听器类型,枚举值:RequestProxy,请求代理; PacketsTransmit ,报文转发;Comprehensive,兼容型;Pending,未定型 - * "IPVersion" => (string) ULB提供服务的IP类型。枚举值,“IPv4”,"IPv6"。默认为“IPv4” - * "ULBId" => (string) 负载均衡的资源ID - * "Name" => (string) 负载均衡的资源名称 - * "Tag" => (string) 负载均衡的业务组名称 - * "Remark" => (string) 负载均衡的备注 - * "CreateTime" => (integer) ULB的创建时间,格式为Unix Timestamp - * "VPCId" => (string) ULB所在的VPC的ID - * "SubnetId" => (string) ULB 为 InnerMode 时,ULB 所属的子网ID - * "BusinessId" => (string) ULB 所属的业务组ID - * "PrivateIP" => (string) ULB的内网IP,当ULBType为OuterMode时,该值为空 - * "BandwidthType" => (integer) 带宽类型,枚举值为: 0,非共享带宽; 1,共享带宽 - * "Bandwidth" => (integer) 带宽 - * "IPSet" => (array) ULB的详细信息列表,具体结构见下方 ULBIPSet[ - * [ - * "OperatorName" => (string) 弹性IP的运营商信息,枚举值为: Bgp:BGP IP International:国际IP - * "EIP" => (string) 弹性IP地址 - * "EIPId" => (string) 弹性IP的ID - * "BandwidthType" => (integer) 弹性IP的带宽类型,枚举值:1 表示是共享带宽,0 普通带宽类型(暂未对外开放) - * "Bandwidth" => (integer) 弹性IP的带宽值(暂未对外开放) - * ] - * ] - * "VServerCount" => (integer) ulb下vserver数量 - * "ULBType" => (string) ULB 的类型(InnerMode or OuterMode) - * "FirewallSet" => (array) 防火墙信息,具体结构见下方 FirewallSet[ - * [ - * "FirewallName" => (string) 防火墙名称 - * "FirewallId" => (string) 防火墙ID - * ] - * ] - * "EnableLog" => (integer) ULB是否开启日志功能。0,关闭;1,开启 - * "LogSet" => (object) 日志功能相关信息,仅当EnableLog为true时会返回,具体结构见下方 LoggerSet[ - * "BucketName" => (string) ulb日志上传的bucket - * "TokenID" => (string) 上传到bucket使用的token的tokenid - * "TokenName" => (string) bucket的token名称 - * ] - * ] - * ] - * ] - * - * @return DescribeULBSimpleResponse * @throws UCloudException */ public function describeULBSimple(DescribeULBSimpleRequest $request = null) @@ -659,108 +314,13 @@ public function describeULBSimple(DescribeULBSimpleRequest $request = null) $resp = $this->invoke($request); return new DescribeULBSimpleResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeVServer - 获取ULB下的VServer的详细信息 * - * See also: https://docs.ucloud.cn/api/ulb-api/describe_vserver - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ULBId" => (string) 负载均衡实例的Id - * "VServerId" => (string) VServer实例的Id;若指定则返回指定的VServer实例的信息; 若不指定则返回当前负载均衡实例下所有VServer的信息 - * "Limit" => (integer) 数据分页值 - * "Offset" => (integer) 数据偏移量 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的VServer总数 - * "DataSet" => (array) VServer列表,每项参数详见 ULBVServerSet[ - * [ - * "MonitorType" => (string) 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测, Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path; 报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize - * "Domain" => (string) 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查域名 - * "Path" => (string) 根据MonitorType确认; 当MonitorType为Port时,此字段无意义。当MonitorType为Path时,代表HTTP检查路径 - * "RequestMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 - * "ResponseMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 - * "VServerId" => (string) VServer实例的Id - * "VServerName" => (string) VServer实例的名字 - * "Protocol" => (string) VServer实例的协议。 枚举值为:HTTP,TCP,UDP,HTTPS。 - * "FrontendPort" => (integer) VServer服务端口 - * "Method" => (string) VServer负载均衡的模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口)。 - * "PersistenceType" => (string) VServer会话保持方式。枚举值为: None -> 关闭会话保持; ServerInsert -> 自动生成; UserDefined -> 用户自定义。 - * "PersistenceInfo" => (string) 根据PersistenceType确定: None或ServerInsert,此字段为空; UserDefined,此字段展示用户自定义会话string。 - * "ClientTimeout" => (integer) 空闲连接的回收时间,单位:秒。 - * "Status" => (integer) VServer的运行状态。枚举值: 0 -> rs全部运行正常;1 -> rs全部运行异常;2 -> rs部分运行异常。 - * "SSLSet" => (array) VServer绑定的SSL证书信息,具体结构见下方 ULBSSLSet。[ - * [ - * "SSLId" => (string) SSL证书的Id - * "SSLName" => (string) SSL证书的名字 - * "SSLType" => (string) SSL证书类型,暂时只有 Pem 一种类型 - * "SSLContent" => (string) SSL证书的内容 - * "CreateTime" => (integer) SSL证书的创建时间 - * "HashValue" => (string) SSL证书的HASH值 - * "BindedTargetSet" => (array) SSL证书绑定到的对象[ - * [ - * "VServerId" => (string) SSL证书绑定到的VServer的资源ID - * "VServerName" => (string) 对应的VServer的名字 - * "ULBId" => (string) VServer 所属的ULB实例的资源ID - * "ULBName" => (string) ULB实例的名称 - * ] - * ] - * ] - * ] - * "BackendSet" => (array) 后端资源信息列表,具体结构见下方 ULBBackendSet[ - * [ - * "BackendId" => (string) 后端资源实例的Id - * "ResourceType" => (string) 资源实例的类型 - * "ResourceId" => (string) 资源实例的资源Id - * "ResourceName" => (string) 资源实例的资源名称 - * "SubResourceType" => (string) 资源绑定的虚拟网卡实例的类型 - * "SubResourceId" => (string) 资源绑定的虚拟网卡实例的资源Id - * "SubResourceName" => (string) 资源绑定的虚拟网卡实例的资源名称 - * "PrivateIP" => (string) 后端提供服务的内网IP - * "Port" => (integer) 后端提供服务的端口 - * "Enabled" => (integer) 后端提供服务的实例启用与否,枚举值:0 禁用 1 启用 - * "Status" => (integer) 后端提供服务的实例运行状态,枚举值:0健康检查健康状态 1 健康检查异常 - * "SubnetId" => (string) 后端提供服务的资源所在的子网的ID - * "IsBackup" => (integer) 是否为backup,只有当vserver的Backup属性为1时才会有此字段,说明:0:主rs1:备rs - * ] - * ] - * "ListenType" => (string) 监听器类型,枚举值为: RequestProxy -> 请求代理;PacketsTransmit -> 报文转发 - * "PolicySet" => (array) 内容转发信息列表,具体结构见下方 ULBPolicySet[ - * [ - * "PolicyId" => (string) 内容转发Id,默认内容转发类型下为空。 - * "PolicyType" => (string) 内容类型,枚举值:Custom -> 客户自定义;Default -> 默认内容转发 - * "Type" => (string) 内容转发匹配字段的类型,枚举值:Domain -> 域名;Path -> 路径; 默认内容转发类型下为空 - * "Match" => (string) 内容转发匹配字段;默认内容转发类型下为空。 - * "PolicyPriority" => (integer) 内容转发优先级,范围[1,9999],数字越大优先级越高。默认内容转发规则下为0。 - * "VServerId" => (string) 所属VServerId - * "TotalCount" => (integer) 默认内容转发类型下返回当前rs总数 - * "BackendSet" => (array) 内容转发下rs的详细信息,参考PolicyBackendSet[ - * [ - * "BackendId" => (string) 所添加的后端资源在ULB中的对象ID,(为ULB系统中使用,与资源自身ID无关 - * "ResourceType" => (string) 所添加的后端资源的类型,枚举值:UHost -> 云主机;UPM -> 物理云主机; UDHost -> 私有专区主机;UDocker -> 容器;UHybrid->混合云主机;CUBE->Cube;UNI -> 虚拟网卡 - * "ResourceName" => (string) 后端资源的实例名称 - * "SubResourceId" => (string) 如果资源绑定了弹性网卡,则展示弹性网卡的资源ID - * "SubResourceName" => (string) 如果资源绑定了弹性网卡,则展示弹性网卡的资源名称 - * "SubResourceType" => (string) "UNI"或者为空 - * "ObjectId" => (string) 后端资源的对象ID - * "Port" => (integer) 所添加的后端资源服务端口 - * "PrivateIP" => (string) 后端资源的内网IP - * ] - * ] - * ] - * ] - * ] - * ] - * ] - * - * @return DescribeVServerResponse * @throws UCloudException */ public function describeVServer(DescribeVServerRequest $request = null) @@ -768,27 +328,13 @@ public function describeVServer(DescribeVServerRequest $request = null) $resp = $this->invoke($request); return new DescribeVServerResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReleaseBackend - 从VServer释放后端资源实例 * - * See also: https://docs.ucloud.cn/api/ulb-api/release_backend - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 负载均衡实例的ID - * "BackendId" => (string) 后端资源实例的ID(ULB后端ID,非资源自身ID) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReleaseBackendResponse * @throws UCloudException */ public function releaseBackend(ReleaseBackendRequest $request = null) @@ -796,28 +342,13 @@ public function releaseBackend(ReleaseBackendRequest $request = null) $resp = $this->invoke($request); return new ReleaseBackendResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UnbindSSL - 从VServer解绑SSL证书 * - * See also: https://docs.ucloud.cn/api/ulb-api/unbind_ssl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 所绑定ULB实例ID - * "VServerId" => (string) 所绑定VServer实例ID - * "SSLId" => (string) SSL证书的Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UnbindSSLResponse * @throws UCloudException */ public function unbindSSL(UnbindSSLRequest $request = null) @@ -825,31 +356,13 @@ public function unbindSSL(UnbindSSLRequest $request = null) $resp = $this->invoke($request); return new UnbindSSLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateBackendAttribute - 更新ULB后端资源实例(服务节点)属性 * - * See also: https://docs.ucloud.cn/api/ulb-api/update_backend_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ULBId" => (string) 负载均衡资源ID - * "BackendId" => (string) 后端资源实例的ID(ULB后端ID,非资源自身ID) - * "Port" => (integer) 后端资源服务端口,取值范围[1-65535] - * "Weight" => (integer) 所添加的后端RS权重(在加权轮询算法下有效),取值范围[0-100],默认为1 - * "Enabled" => (integer) 后端实例状态开关 - * "IsBackup" => (integer) 是否为backup0:主rs1:备rs默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateBackendAttributeResponse * @throws UCloudException */ public function updateBackendAttribute(UpdateBackendAttributeRequest $request = null) @@ -857,31 +370,13 @@ public function updateBackendAttribute(UpdateBackendAttributeRequest $request = $resp = $this->invoke($request); return new UpdateBackendAttributeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdatePolicy - 更新内容转发规则,包括转发规则后的服务节点 * - * See also: https://docs.ucloud.cn/api/ulb-api/update_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) 需要添加内容转发策略的负载均衡实例ID - * "VServerId" => (string) 需要添加内容转发策略的VServer实例ID,只支持请求代理模式下,HTTP或HTTPS协议的VServer - * "Match" => (string) 内容转发匹配字段 - * "PolicyId" => (string) 转发规则的ID,当Type为Default时,可以不传或为空 - * "BackendId" => (array) 内容转发策略应用的后端资源实例的ID,来源于 AllocateBackend 返回的 BackendId,不传表示更新转发节点为空 - * "Type" => (string) 内容转发匹配字段的类型,枚举值:Domain -> 域名转发规则;Path -> 路径转发规则;Default -> 默认转发规则,不传默认值Domain - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdatePolicyResponse * @throws UCloudException */ public function updatePolicy(UpdatePolicyRequest $request = null) @@ -889,29 +384,27 @@ public function updatePolicy(UpdatePolicyRequest $request = null) $resp = $this->invoke($request); return new UpdatePolicyResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * UpdateULBAttribute - 更新ULB名字业务组备注等属性字段 - * - * See also: https://docs.ucloud.cn/api/ulb-api/update_ulb_attribute + * UpdateSSLAttribute - 更新修改SSL的属性,如:修改SSLName * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ULBId" => (string) ULB资源ID - * "Name" => (string) 名字 - * "Tag" => (string) 业务 - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function updateSSLAttribute(UpdateSSLAttributeRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateSSLAttributeResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateULBAttribute - 更新ULB名字业务组备注等属性字段 * - * @return UpdateULBAttributeResponse * @throws UCloudException */ public function updateULBAttribute(UpdateULBAttributeRequest $request = null) @@ -919,37 +412,13 @@ public function updateULBAttribute(UpdateULBAttributeRequest $request = null) $resp = $this->invoke($request); return new UpdateULBAttributeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateVServerAttribute - 更新VServer实例属性 * - * See also: https://docs.ucloud.cn/api/ulb-api/update_vserver_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ULBId" => (string) 负载均衡实例ID - * "VServerId" => (string) VServer实例ID - * "VServerName" => (string) VServer实例名称,若无此字段则不做修改 - * "Method" => (string) VServer负载均衡模式,枚举值:Roundrobin -> 轮询;Source -> 源地址;ConsistentHash -> 一致性哈希;SourcePort -> 源地址(计算端口);ConsistentHashPort -> 一致性哈希(计算端口); WeightRoundrobin -> 加权轮询; Leastconn -> 最小连接数;Backup -> 主备模式。ConsistentHash,SourcePort,ConsistentHashPort 只在报文转发中使用;Leastconn只在请求代理中使用;Roundrobin、Source和WeightRoundrobin,Backup在请求代理和报文转发中使用。默认为:"Roundrobin" - * "PersistenceType" => (string) VServer会话保持模式,若无此字段则不做修改。枚举值:None:关闭;ServerInsert:自动生成KEY;UserDefined:用户自定义KEY。 - * "PersistenceInfo" => (string) 根据PersistenceType确定: None或ServerInsert, 此字段无意义; UserDefined, 则此字段传入用户自定义会话保持String. 若无此字段则不做修改 - * "ClientTimeout" => (integer) 请求代理的VServer下表示空闲连接的回收时间,单位:秒,取值范围:时(0,86400],默认值为60;报文转发的VServer下表示回话保持的时间,单位:秒,取值范围:[60,900],0 表示禁用连接保持 - * "MonitorType" => (string) 健康检查类型,枚举值:Port -> 端口检查;Path -> 路径检查;Ping -> Ping探测,Customize -> UDP检查请求代理型默认值为Port,其中TCP协议仅支持Port,其他协议支持Port和Path;报文转发型TCP协议仅支持Port,UDP协议支持Ping、Port和Customize,默认值为Ping - * "Domain" => (string) MonitorType 为 Path 时指定健康检查发送请求时HTTP HEADER 里的域名 - * "Path" => (string) MonitorType 为 Path 时指定健康检查发送请求时的路径,默认为 / - * "RequestMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查发出的请求报文 - * "ResponseMsg" => (string) 根据MonitorType确认; 当MonitorType为Customize时,此字段有意义,代表UDP检查请求应收到的响应报文 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateVServerAttributeResponse * @throws UCloudException */ public function updateVServerAttribute(UpdateVServerAttributeRequest $request = null) diff --git a/src/UMem/Apis/CheckUDredisSpaceAllowanceRequest.php b/src/UMem/Apis/CheckUDredisSpaceAllowanceRequest.php index 70f17b83..9bce39a2 100644 --- a/src/UMem/Apis/CheckUDredisSpaceAllowanceRequest.php +++ b/src/UMem/Apis/CheckUDredisSpaceAllowanceRequest.php @@ -1,6 +1,7 @@ markRequired("Count"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * Size: 创建实例的容量大小,,扩容时的分片目标容量大小 * @@ -86,11 +85,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Count: 创建实例的数量,[1-10] * @@ -106,11 +104,10 @@ public function getCount() * * @param string $count */ - public function setCount($count) + public function setCount(string $count) { $this->set("Count", $count); } - /** * GroupId: 资源ID,扩缩容时的必传参数 * @@ -126,7 +123,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/CheckUDredisSpaceAllowanceResponse.php b/src/UMem/Apis/CheckUDredisSpaceAllowanceResponse.php index 89ddb982..ad3f7b4d 100644 --- a/src/UMem/Apis/CheckUDredisSpaceAllowanceResponse.php +++ b/src/UMem/Apis/CheckUDredisSpaceAllowanceResponse.php @@ -1,6 +1,7 @@ set("Count", $count); } diff --git a/src/UMem/Apis/CheckURedisAllowanceRequest.php b/src/UMem/Apis/CheckURedisAllowanceRequest.php index b4a79b91..f1c9b804 100644 --- a/src/UMem/Apis/CheckURedisAllowanceRequest.php +++ b/src/UMem/Apis/CheckURedisAllowanceRequest.php @@ -1,6 +1,7 @@ markRequired("Count"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 创建实例的容量大小, 单位:GB 目前仅支持1/2/4/8/16/32六种规格;扩缩容时,表示实例的目标资源大小 * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Count: 创建实例的数量,[1-10] * @@ -126,11 +123,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Protocol: * @@ -146,11 +142,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * RegionFlag: 是否是跨机房URedis(默认false) * @@ -166,11 +161,10 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } - /** * GroupId: 资源ID,扩容实例资源时的必传参数 * @@ -186,7 +180,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/CheckURedisAllowanceResponse.php b/src/UMem/Apis/CheckURedisAllowanceResponse.php index bb6818cc..8f61e695 100644 --- a/src/UMem/Apis/CheckURedisAllowanceResponse.php +++ b/src/UMem/Apis/CheckURedisAllowanceResponse.php @@ -1,6 +1,7 @@ set("Count", $count); } diff --git a/src/UMem/Apis/CreateUMemBackupRequest.php b/src/UMem/Apis/CreateUMemBackupRequest.php index b62697d7..2d654c55 100644 --- a/src/UMem/Apis/CreateUMemBackupRequest.php +++ b/src/UMem/Apis/CreateUMemBackupRequest.php @@ -1,6 +1,7 @@ markRequired("BackupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: 资源id * @@ -106,11 +104,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * BackupName: 请求创建备份的名称 (范围[6-63],只能包含英文、数字以及符号-和_) * @@ -126,7 +123,7 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } diff --git a/src/UMem/Apis/CreateUMemBackupResponse.php b/src/UMem/Apis/CreateUMemBackupResponse.php index 1f338341..6cdeb83d 100644 --- a/src/UMem/Apis/CreateUMemBackupResponse.php +++ b/src/UMem/Apis/CreateUMemBackupResponse.php @@ -1,6 +1,7 @@ set("BackupId", $backupId); } diff --git a/src/UMem/Apis/CreateUMemSpaceRequest.php b/src/UMem/Apis/CreateUMemSpaceRequest.php index 3941432a..5cd72515 100644 --- a/src/UMem/Apis/CreateUMemSpaceRequest.php +++ b/src/UMem/Apis/CreateUMemSpaceRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 内存大小, 单位:GB, 范围[1~1024] * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Name: 空间名称,长度(6<=size<=63) * @@ -126,11 +123,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Protocol: 协议:memcache, redis (默认redis).注意:redis无single类型 * @@ -146,11 +142,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * Type: 空间类型:single(无热备),double(热备)(默认: double) * @@ -166,11 +161,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * ChargeType: Year , Month, Dynamic, Trial 默认: Month * @@ -186,11 +180,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长 默认: 1 * @@ -206,11 +199,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * CouponId: 使用的代金券id * @@ -226,7 +218,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UMem/Apis/CreateUMemSpaceResponse.php b/src/UMem/Apis/CreateUMemSpaceResponse.php index 7350c203..351cf730 100644 --- a/src/UMem/Apis/CreateUMemSpaceResponse.php +++ b/src/UMem/Apis/CreateUMemSpaceResponse.php @@ -1,6 +1,7 @@ set("SpaceId", $spaceId); } diff --git a/src/UMem/Apis/CreateUMemcacheGroupRequest.php b/src/UMem/Apis/CreateUMemcacheGroupRequest.php index c9f28313..2045dc6b 100644 --- a/src/UMem/Apis/CreateUMemcacheGroupRequest.php +++ b/src/UMem/Apis/CreateUMemcacheGroupRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 请求创建组的名称 范围[6-60] * @@ -104,11 +102,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Size: 每个节点的内存大小,单位GB,默认1GB 目前仅支持1/2/4/8/16/32这几档 * @@ -124,11 +121,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * ConfigId: 配置ID,目前仅支持默认配置id 默认配置id:"9a891891-c245-4b66-bce8-67e59430d67c" * @@ -144,11 +140,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * Version: Memcache版本信息,默认为1.4.31 * @@ -164,11 +159,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * ChargeType: 计费模式,Year , Month, Dynamic 默认: Month * @@ -184,11 +178,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认为1 * @@ -204,11 +197,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Tag: 业务组 默认:Default * @@ -224,11 +216,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Protocol: * @@ -244,11 +235,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * CouponId: 代金券ID * @@ -264,7 +254,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UMem/Apis/CreateUMemcacheGroupResponse.php b/src/UMem/Apis/CreateUMemcacheGroupResponse.php index cf70849e..3590f9b5 100644 --- a/src/UMem/Apis/CreateUMemcacheGroupResponse.php +++ b/src/UMem/Apis/CreateUMemcacheGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UMem/Apis/CreateURedisBackupRequest.php b/src/UMem/Apis/CreateURedisBackupRequest.php index 73bd1a64..6c27e0ee 100644 --- a/src/UMem/Apis/CreateURedisBackupRequest.php +++ b/src/UMem/Apis/CreateURedisBackupRequest.php @@ -1,6 +1,7 @@ markRequired("BackupName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 资源id * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * BackupName: 请求创建组的名称 (范围[6-63],只能包含英文、数字以及符号-和_) * @@ -125,11 +122,10 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -145,7 +141,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Apis/CreateURedisBackupResponse.php b/src/UMem/Apis/CreateURedisBackupResponse.php index e94c8864..eff08fd5 100644 --- a/src/UMem/Apis/CreateURedisBackupResponse.php +++ b/src/UMem/Apis/CreateURedisBackupResponse.php @@ -1,6 +1,7 @@ set("BackupId", $backupId); } diff --git a/src/UMem/Apis/CreateURedisGroupRequest.php b/src/UMem/Apis/CreateURedisGroupRequest.php index 8d8780a2..814ec744 100644 --- a/src/UMem/Apis/CreateURedisGroupRequest.php +++ b/src/UMem/Apis/CreateURedisGroupRequest.php @@ -1,6 +1,7 @@ markRequired("HighAvailability"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 请求创建组的名称 (范围[6-63],只能包含英文、数字以及符号-和_) * @@ -106,11 +104,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * HighAvailability: 是否开启高可用,enable或disable * @@ -126,11 +123,10 @@ public function getHighAvailability() * * @param string $highAvailability */ - public function setHighAvailability($highAvailability) + public function setHighAvailability(string $highAvailability) { $this->set("HighAvailability", $highAvailability); } - /** * Size: 每个节点的内存大小,单位GB,默认1GB,目前仅支持1/2/4/8/16/32,六种 * @@ -146,11 +142,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * AutoBackup: 是否自动备份,enable或disable,默认disable * @@ -166,11 +161,10 @@ public function getAutoBackup() * * @param string $autoBackup */ - public function setAutoBackup($autoBackup) + public function setAutoBackup(string $autoBackup) { $this->set("AutoBackup", $autoBackup); } - /** * BackupTime: 自动备份开始时间,范围[0-23],默认3点 * @@ -186,11 +180,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * ConfigId: 配置ID,目前支持 3.0版本配置ID:"03f58ca9-b64d-4bdd-abc7-c6b9a46fd801",3.2版本配置ID:"3e45ac48-f8a2-a9q2-261d-l342dab130gf", 4.0版本配置ID:"6c9298a3-9d7f-428c-b1d0-e87ab3b8a1ea",默认版本3.0,从备份创建为必传项 * @@ -206,11 +199,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * Version: Redis版本信息(详见DescribeURedisVersion返回结果),默认版本3.0 * @@ -226,11 +218,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * ChargeType: 计费模式,Year , Month, Dynamic 默认: Month * @@ -246,11 +237,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,默认为1 * @@ -266,11 +256,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Tag: 业务组名称 * @@ -286,11 +275,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Password: 初始化密码,需要 base64 编码 * @@ -306,11 +294,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * BackupId: 有此项代表从备份中创建,无代表正常创建 * @@ -326,11 +313,10 @@ public function getBackupId() * * @param string $backupId */ - public function setBackupId($backupId) + public function setBackupId(string $backupId) { $this->set("BackupId", $backupId); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -346,11 +332,10 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } - /** * MasterGroupId: Master Redis Group的ID,创建只读Slave时,必须填写 * @@ -366,11 +351,10 @@ public function getMasterGroupId() * * @param string $masterGroupId */ - public function setMasterGroupId($masterGroupId) + public function setMasterGroupId(string $masterGroupId) { $this->set("MasterGroupId", $masterGroupId); } - /** * EnableIpV6: 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true * @@ -386,11 +370,10 @@ public function getEnableIpV6() * * @param boolean $enableIpV6 */ - public function setEnableIpV6($enableIpV6) + public function setEnableIpV6(bool $enableIpV6) { $this->set("EnableIpV6", $enableIpV6); } - /** * SubnetId: 子网ID * @@ -406,11 +389,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC的ID * @@ -426,11 +408,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * CouponId: 代金券ID * @@ -446,7 +427,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UMem/Apis/CreateURedisGroupResponse.php b/src/UMem/Apis/CreateURedisGroupResponse.php index 131956d1..2eea9c89 100644 --- a/src/UMem/Apis/CreateURedisGroupResponse.php +++ b/src/UMem/Apis/CreateURedisGroupResponse.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DeleteUMemSpaceRequest.php b/src/UMem/Apis/DeleteUMemSpaceRequest.php index 2bd5fc18..c20fce62 100644 --- a/src/UMem/Apis/DeleteUMemSpaceRequest.php +++ b/src/UMem/Apis/DeleteUMemSpaceRequest.php @@ -1,6 +1,7 @@ markRequired("SpaceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: UMem内存空间ID * @@ -104,7 +102,7 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } diff --git a/src/UMem/Apis/DeleteUMemSpaceResponse.php b/src/UMem/Apis/DeleteUMemSpaceResponse.php index 7064fffb..79029b7b 100644 --- a/src/UMem/Apis/DeleteUMemSpaceResponse.php +++ b/src/UMem/Apis/DeleteUMemSpaceResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组ID * @@ -104,7 +102,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DeleteUMemcacheGroupResponse.php b/src/UMem/Apis/DeleteUMemcacheGroupResponse.php index b22c5478..344c8004 100644 --- a/src/UMem/Apis/DeleteUMemcacheGroupResponse.php +++ b/src/UMem/Apis/DeleteUMemcacheGroupResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组ID * @@ -84,7 +83,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DeleteURedisGroupResponse.php b/src/UMem/Apis/DeleteURedisGroupResponse.php index 8693d130..6e2d106e 100644 --- a/src/UMem/Apis/DeleteURedisGroupResponse.php +++ b/src/UMem/Apis/DeleteURedisGroupResponse.php @@ -1,6 +1,7 @@ "DescribeUDRedisProxyInfo"]); + $this->markRequired("Region"); + $this->markRequired("Zone"); + $this->markRequired("SpaceId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * SpaceId: udredis实例id + * + * @return string|null + */ + public function getSpaceId() + { + return $this->get("SpaceId"); + } + + /** + * SpaceId: udredis实例id + * + * @param string $spaceId + */ + public function setSpaceId(string $spaceId) + { + $this->set("SpaceId", $spaceId); + } +} diff --git a/src/UMem/Apis/DescribeUDRedisProxyInfoResponse.php b/src/UMem/Apis/DescribeUDRedisProxyInfoResponse.php new file mode 100644 index 00000000..4bac3537 --- /dev/null +++ b/src/UMem/Apis/DescribeUDRedisProxyInfoResponse.php @@ -0,0 +1,59 @@ +get("DataSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new UDRedisProxyInfoModel($item)); + } + return $result; + } + + /** + * DataSet: 代理数据集 + * + * @param UDRedisProxyInfoModel[] $dataSet + */ + public function setDataSet(array $dataSet) + { + $result = []; + foreach ($dataSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/UMem/Apis/DescribeUDRedisSlowlogRequest.php b/src/UMem/Apis/DescribeUDRedisSlowlogRequest.php index 0fef4bdd..2e968441 100644 --- a/src/UMem/Apis/DescribeUDRedisSlowlogRequest.php +++ b/src/UMem/Apis/DescribeUDRedisSlowlogRequest.php @@ -1,6 +1,7 @@ markRequired("InstanceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * InstanceId: 实例id * @@ -105,11 +103,10 @@ public function getInstanceId() * * @param string $instanceId */ - public function setInstanceId($instanceId) + public function setInstanceId(string $instanceId) { $this->set("InstanceId", $instanceId); } - /** * Limit: 分页显示的条目数,默认为10 * @@ -125,7 +122,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeUDRedisSlowlogResponse.php b/src/UMem/Apis/DescribeUDRedisSlowlogResponse.php index 33e2885e..54155e7f 100644 --- a/src/UMem/Apis/DescribeUDRedisSlowlogResponse.php +++ b/src/UMem/Apis/DescribeUDRedisSlowlogResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 条目数据 * - * @return UDRedisSlowlogSet[]|null + * @return UDRedisSlowlogSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UDRedisSlowlogSet($item)); + array_push($result, new UDRedisSlowlogSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 条目数据 * - * @param UDRedisSlowlogSet[] $dataSet + * @param UDRedisSlowlogSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemBackupRequest.php b/src/UMem/Apis/DescribeUMemBackupRequest.php index 68f5bfff..5f7613ff 100644 --- a/src/UMem/Apis/DescribeUMemBackupRequest.php +++ b/src/UMem/Apis/DescribeUMemBackupRequest.php @@ -1,6 +1,7 @@ markRequired("SpaceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: 资源id * @@ -105,11 +103,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -125,11 +122,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为10 * @@ -145,7 +141,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeUMemBackupResponse.php b/src/UMem/Apis/DescribeUMemBackupResponse.php index 79a361ab..5a971913 100644 --- a/src/UMem/Apis/DescribeUMemBackupResponse.php +++ b/src/UMem/Apis/DescribeUMemBackupResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UMemBackupSet($item)); + array_push($result, new UMemBackupSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 分布式redis 备份,数组的每个元素为每个分片的备份 * - * @param UMemBackupSet[] $dataSet + * @param UMemBackupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemBackupURLRequest.php b/src/UMem/Apis/DescribeUMemBackupURLRequest.php index 544f1c35..75b6ad91 100644 --- a/src/UMem/Apis/DescribeUMemBackupURLRequest.php +++ b/src/UMem/Apis/DescribeUMemBackupURLRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: 资源id * @@ -106,11 +104,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * BackupId: 备份Id * @@ -126,11 +123,10 @@ public function getBackupId() * * @param string $backupId */ - public function setBackupId($backupId) + public function setBackupId(string $backupId) { $this->set("BackupId", $backupId); } - /** * BlockId: 分片id * @@ -146,7 +142,7 @@ public function getBlockId() * * @param string $blockId */ - public function setBlockId($blockId) + public function setBlockId(string $blockId) { $this->set("BlockId", $blockId); } diff --git a/src/UMem/Apis/DescribeUMemBackupURLResponse.php b/src/UMem/Apis/DescribeUMemBackupURLResponse.php index de9174d9..7add54d9 100644 --- a/src/UMem/Apis/DescribeUMemBackupURLResponse.php +++ b/src/UMem/Apis/DescribeUMemBackupURLResponse.php @@ -1,6 +1,7 @@ markRequired("Limit"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -43,17 +44,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -63,17 +63,16 @@ public function getZone() } /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -83,15 +82,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: UMem内存资源ID * @@ -107,11 +105,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -127,11 +124,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为10 * @@ -147,7 +143,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeUMemBlockInfoResponse.php b/src/UMem/Apis/DescribeUMemBlockInfoResponse.php index 5a19b8c1..3c8bb597 100644 --- a/src/UMem/Apis/DescribeUMemBlockInfoResponse.php +++ b/src/UMem/Apis/DescribeUMemBlockInfoResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UMemBlockInfo($item)); + array_push($result, new UMemBlockInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 分布式redis 分片信息 * - * @param UMemBlockInfo[] $dataSet + * @param UMemBlockInfoModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemPriceRequest.php b/src/UMem/Apis/DescribeUMemPriceRequest.php index 08b0f36c..9f680f73 100644 --- a/src/UMem/Apis/DescribeUMemPriceRequest.php +++ b/src/UMem/Apis/DescribeUMemPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Type"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买umem大小,单位:GB,范围[1~1024] * @@ -107,11 +105,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Type: 空间类型:single(无热备),double(热备)(默认: double) * @@ -127,11 +124,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * ChargeType: Year, Month, Dynamic 如果不指定,则一次性获取三种计费 * @@ -147,11 +143,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买UMem的时长,默认值为1 * @@ -167,7 +162,7 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } diff --git a/src/UMem/Apis/DescribeUMemPriceResponse.php b/src/UMem/Apis/DescribeUMemPriceResponse.php index 77ba7ba1..a440ea85 100644 --- a/src/UMem/Apis/DescribeUMemPriceResponse.php +++ b/src/UMem/Apis/DescribeUMemPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UMemPriceSet($item)); + array_push($result, new UMemPriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 价格 参数见 UMemPriceSet * - * @param UMemPriceSet[] $dataSet + * @param UMemPriceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemRequest.php b/src/UMem/Apis/DescribeUMemRequest.php index 46959c1c..ba7d215a 100644 --- a/src/UMem/Apis/DescribeUMemRequest.php +++ b/src/UMem/Apis/DescribeUMemRequest.php @@ -1,6 +1,7 @@ markRequired("Protocol"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Protocol: 协议类型: memcache, redis * @@ -104,11 +102,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -124,11 +121,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为20 * @@ -144,11 +140,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * ResourceId: 资源ID * @@ -164,7 +159,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UMem/Apis/DescribeUMemResponse.php b/src/UMem/Apis/DescribeUMemResponse.php index a31340d3..558a7189 100644 --- a/src/UMem/Apis/DescribeUMemResponse.php +++ b/src/UMem/Apis/DescribeUMemResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: UMem实例列表, 详细参见UMemDataSet * - * @return UMemDataSet[]|null + * @return UMemDataSetModel[]|null */ public function getDataSet() { @@ -58,7 +59,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UMemDataSet($item)); + array_push($result, new UMemDataSetModel($item)); } return $result; } @@ -66,7 +67,7 @@ public function getDataSet() /** * DataSet: UMem实例列表, 详细参见UMemDataSet * - * @param UMemDataSet[] $dataSet + * @param UMemDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemSpaceRequest.php b/src/UMem/Apis/DescribeUMemSpaceRequest.php index f4b6265e..8015969b 100644 --- a/src/UMem/Apis/DescribeUMemSpaceRequest.php +++ b/src/UMem/Apis/DescribeUMemSpaceRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 数据偏移量, 默认为0 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度, 默认为20 * @@ -123,11 +120,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * SpaceId: 内存空间ID (无ID,则获取所有) * @@ -143,11 +139,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * Protocol: 协议类型: memcache, redis * @@ -163,7 +158,7 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } diff --git a/src/UMem/Apis/DescribeUMemSpaceResponse.php b/src/UMem/Apis/DescribeUMemSpaceResponse.php index 6349887b..445f7f59 100644 --- a/src/UMem/Apis/DescribeUMemSpaceResponse.php +++ b/src/UMem/Apis/DescribeUMemSpaceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UMemSpaceSet($item)); + array_push($result, new UMemSpaceSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: JSON 格式的UMem内存空间实例列表, 详细参见 UMemSpaceSet * - * @param UMemSpaceSet[] $dataSet + * @param UMemSpaceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -55,7 +57,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 根据过滤条件得到的总数 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UMem/Apis/DescribeUMemUpgradePriceRequest.php b/src/UMem/Apis/DescribeUMemUpgradePriceRequest.php index 7f7dcc2d..00337057 100644 --- a/src/UMem/Apis/DescribeUMemUpgradePriceRequest.php +++ b/src/UMem/Apis/DescribeUMemUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("SpaceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 购买UMem大小,单位:GB * @@ -106,11 +104,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * Type: 空间类型:single(无热备),double(热备)(默认: double) * @@ -126,11 +123,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * SpaceId: 需要升级的空间的SpaceId * @@ -146,7 +142,7 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } diff --git a/src/UMem/Apis/DescribeUMemUpgradePriceResponse.php b/src/UMem/Apis/DescribeUMemUpgradePriceResponse.php index 56cd1dc8..8c40f60b 100644 --- a/src/UMem/Apis/DescribeUMemUpgradePriceResponse.php +++ b/src/UMem/Apis/DescribeUMemUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } - /** * OriginalPrice: 原价 * @@ -57,7 +57,7 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UMem/Apis/DescribeUMemcacheGroupRequest.php b/src/UMem/Apis/DescribeUMemcacheGroupRequest.php index 95625bd2..5b4f3aa5 100644 --- a/src/UMem/Apis/DescribeUMemcacheGroupRequest.php +++ b/src/UMem/Apis/DescribeUMemcacheGroupRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID,如果指定则获取描述,否则为列表操 作,需指定Offset/Limit * @@ -103,11 +101,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -123,11 +120,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为20 * @@ -143,7 +139,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeUMemcacheGroupResponse.php b/src/UMem/Apis/DescribeUMemcacheGroupResponse.php index 6973b48e..196f1694 100644 --- a/src/UMem/Apis/DescribeUMemcacheGroupResponse.php +++ b/src/UMem/Apis/DescribeUMemcacheGroupResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 组列表,参见 UMemcacheGroupSet * - * @return UMemcacheGroupSet[]|null + * @return UMemcacheGroupSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UMemcacheGroupSet($item)); + array_push($result, new UMemcacheGroupSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 组列表,参见 UMemcacheGroupSet * - * @param UMemcacheGroupSet[] $dataSet + * @param UMemcacheGroupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemcachePriceRequest.php b/src/UMem/Apis/DescribeUMemcachePriceRequest.php index 8db1fd90..be51ba8f 100644 --- a/src/UMem/Apis/DescribeUMemcachePriceRequest.php +++ b/src/UMem/Apis/DescribeUMemcachePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 容量大小,单位:GB 取值范围[1-32] * @@ -105,11 +103,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * ChargeType: 计费模式,Year, Month, Dynamic,默认: Dynamic 默认: 获取所有计费模式的价格 * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买umemcache的时长,默认值为1 * @@ -145,11 +141,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Type: 空间类型:single(无热备),double(热备)(默认: double) * @@ -165,7 +160,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/UMem/Apis/DescribeUMemcachePriceResponse.php b/src/UMem/Apis/DescribeUMemcachePriceResponse.php index b20628ea..9eca3982 100644 --- a/src/UMem/Apis/DescribeUMemcachePriceResponse.php +++ b/src/UMem/Apis/DescribeUMemcachePriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UMemcachePriceSet($item)); + array_push($result, new UMemcachePriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 价格列表, 参见 UMemcachePriceSet * - * @param UMemcachePriceSet[] $dataSet + * @param UMemcachePriceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeUMemcacheUpgradePriceRequest.php b/src/UMem/Apis/DescribeUMemcacheUpgradePriceRequest.php index 84f14d15..55d99902 100644 --- a/src/UMem/Apis/DescribeUMemcacheUpgradePriceRequest.php +++ b/src/UMem/Apis/DescribeUMemcacheUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Size: 购买umemcache大小,单位:GB @@ -44,11 +45,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * GroupId: 需要升级的空间的GroupId,请参考DescribeUMemcacheGroup接口 * @@ -64,7 +64,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DescribeUMemcacheUpgradePriceResponse.php b/src/UMem/Apis/DescribeUMemcacheUpgradePriceResponse.php index fa0dbcc0..f407a5c6 100644 --- a/src/UMem/Apis/DescribeUMemcacheUpgradePriceResponse.php +++ b/src/UMem/Apis/DescribeUMemcacheUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UMem/Apis/DescribeURedisBackupRequest.php b/src/UMem/Apis/DescribeURedisBackupRequest.php index 7ff53601..73071e65 100644 --- a/src/UMem/Apis/DescribeURedisBackupRequest.php +++ b/src/UMem/Apis/DescribeURedisBackupRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -83,11 +82,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为10 * @@ -103,11 +101,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * GroupId: 组的ID * @@ -123,7 +120,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DescribeURedisBackupResponse.php b/src/UMem/Apis/DescribeURedisBackupResponse.php index 0f2f465e..a0f46556 100644 --- a/src/UMem/Apis/DescribeURedisBackupResponse.php +++ b/src/UMem/Apis/DescribeURedisBackupResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 备份列表 参见 URedisBackupSet * - * @return URedisBackupSet[]|null + * @return URedisBackupSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new URedisBackupSet($item)); + array_push($result, new URedisBackupSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 备份列表 参见 URedisBackupSet * - * @param URedisBackupSet[] $dataSet + * @param URedisBackupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeURedisBackupURLRequest.php b/src/UMem/Apis/DescribeURedisBackupURLRequest.php index f71519fd..e451d4fe 100644 --- a/src/UMem/Apis/DescribeURedisBackupURLRequest.php +++ b/src/UMem/Apis/DescribeURedisBackupURLRequest.php @@ -1,6 +1,7 @@ markRequired("BackupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BackupId: 备份ID * @@ -104,11 +102,10 @@ public function getBackupId() * * @param string $backupId */ - public function setBackupId($backupId) + public function setBackupId(string $backupId) { $this->set("BackupId", $backupId); } - /** * RegionFlag: 是否是跨机房URedis(默认false) * @@ -124,11 +121,10 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } - /** * GroupId: 实例名称 * @@ -144,11 +140,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -164,7 +159,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Apis/DescribeURedisBackupURLResponse.php b/src/UMem/Apis/DescribeURedisBackupURLResponse.php index 58c041a1..144d7c96 100644 --- a/src/UMem/Apis/DescribeURedisBackupURLResponse.php +++ b/src/UMem/Apis/DescribeURedisBackupURLResponse.php @@ -1,6 +1,7 @@ set("BackupURL", $backupURL); } - /** * BackupPath: 备份文件公网的地址 * @@ -57,7 +57,7 @@ public function getBackupPath() * * @param string $backupPath */ - public function setBackupPath($backupPath) + public function setBackupPath(string $backupPath) { $this->set("BackupPath", $backupPath); } diff --git a/src/UMem/Apis/DescribeURedisConfigRequest.php b/src/UMem/Apis/DescribeURedisConfigRequest.php index c3fb151c..2c2396aa 100644 --- a/src/UMem/Apis/DescribeURedisConfigRequest.php +++ b/src/UMem/Apis/DescribeURedisConfigRequest.php @@ -1,6 +1,7 @@ markRequired("RegionFlag"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RegionFlag: 是否是跨机房URedis(默认false) * @@ -105,11 +103,10 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } - /** * Version: Redis版本号 * @@ -125,11 +122,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * ConfigId: 配置文件ID * @@ -145,11 +141,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * Offset: 页显示的起始偏移, 默认值为0 * @@ -165,11 +160,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 页显示的条目数, 默认值为10 * @@ -185,7 +179,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeURedisConfigResponse.php b/src/UMem/Apis/DescribeURedisConfigResponse.php index 35d3ccaf..a8a36dee 100644 --- a/src/UMem/Apis/DescribeURedisConfigResponse.php +++ b/src/UMem/Apis/DescribeURedisConfigResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 配置文件列表 参见 URedisConfigSet * - * @return URedisConfigSet[]|null + * @return URedisConfigSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new URedisConfigSet($item)); + array_push($result, new URedisConfigSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 配置文件列表 参见 URedisConfigSet * - * @param URedisConfigSet[] $dataSet + * @param URedisConfigSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeURedisGroupRequest.php b/src/UMem/Apis/DescribeURedisGroupRequest.php index 5b868aae..cb14e080 100644 --- a/src/UMem/Apis/DescribeURedisGroupRequest.php +++ b/src/UMem/Apis/DescribeURedisGroupRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID,如果指定则获取描述,否则为列表操 作,需指定Offset/Limit * @@ -103,11 +101,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Offset: 分页显示的起始偏移, 默认值为0 * @@ -123,11 +120,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页显示的条目数, 默认值为20 * @@ -143,7 +139,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeURedisGroupResponse.php b/src/UMem/Apis/DescribeURedisGroupResponse.php index 0f217ff8..4a355b98 100644 --- a/src/UMem/Apis/DescribeURedisGroupResponse.php +++ b/src/UMem/Apis/DescribeURedisGroupResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 组列表 参见 URedisGroupSet * - * @return URedisGroupSet[]|null + * @return URedisGroupSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new URedisGroupSet($item)); + array_push($result, new URedisGroupSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 组列表 参见 URedisGroupSet * - * @param URedisGroupSet[] $dataSet + * @param URedisGroupSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeURedisPriceRequest.php b/src/UMem/Apis/DescribeURedisPriceRequest.php index 3d995246..36da60b1 100644 --- a/src/UMem/Apis/DescribeURedisPriceRequest.php +++ b/src/UMem/Apis/DescribeURedisPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Size: 量大小,单位:GB 取值范围[1-32] * @@ -105,11 +103,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * ChargeType: 计费模式,Year, Month, Dynamic;如果不指定,则一次性获取三种计费 * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 计费模式为Dynamic时,购买的时长, 默认为1 * @@ -145,11 +141,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * RegionFlag: 是否是跨机房URedis(默认false) * @@ -165,11 +160,10 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } - /** * ProductType: 产品类型:MS_Redis(标准主备版),S_Redis(从库),默认为MS_Redis * @@ -185,7 +179,7 @@ public function getProductType() * * @param string $productType */ - public function setProductType($productType) + public function setProductType(string $productType) { $this->set("ProductType", $productType); } diff --git a/src/UMem/Apis/DescribeURedisPriceResponse.php b/src/UMem/Apis/DescribeURedisPriceResponse.php index c4b8dc2f..69fb3fb1 100644 --- a/src/UMem/Apis/DescribeURedisPriceResponse.php +++ b/src/UMem/Apis/DescribeURedisPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new URedisPriceSet($item)); + array_push($result, new URedisPriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 价格 参数见 UMemPriceSet * - * @param URedisPriceSet[] $dataSet + * @param URedisPriceSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeURedisSlowlogRequest.php b/src/UMem/Apis/DescribeURedisSlowlogRequest.php index f4d7874e..82a05889 100644 --- a/src/UMem/Apis/DescribeURedisSlowlogRequest.php +++ b/src/UMem/Apis/DescribeURedisSlowlogRequest.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 资源ID * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Limit: 分页显示的条目数,默认为10 * @@ -125,7 +122,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/UMem/Apis/DescribeURedisSlowlogResponse.php b/src/UMem/Apis/DescribeURedisSlowlogResponse.php index 3aeb7063..b93ce75b 100644 --- a/src/UMem/Apis/DescribeURedisSlowlogResponse.php +++ b/src/UMem/Apis/DescribeURedisSlowlogResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 条目数据 * - * @return URedisSlowlogSet[]|null + * @return URedisSlowlogSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new URedisSlowlogSet($item)); + array_push($result, new URedisSlowlogSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 条目数据 * - * @param URedisSlowlogSet[] $dataSet + * @param URedisSlowlogSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/UMem/Apis/DescribeURedisUpgradePriceRequest.php b/src/UMem/Apis/DescribeURedisUpgradePriceRequest.php index 25ea59c9..b2472fee 100644 --- a/src/UMem/Apis/DescribeURedisUpgradePriceRequest.php +++ b/src/UMem/Apis/DescribeURedisUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * Size: 购买uredis大小,单位:GB,范围是[1-32] * @@ -85,11 +84,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * GroupId: 要升级的空间的GroupId,请参考DescribeURedisGroup接口 * @@ -105,7 +103,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/DescribeURedisUpgradePriceResponse.php b/src/UMem/Apis/DescribeURedisUpgradePriceResponse.php index a3ffbc88..30e6f4df 100644 --- a/src/UMem/Apis/DescribeURedisUpgradePriceResponse.php +++ b/src/UMem/Apis/DescribeURedisUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UMem/Apis/DescribeURedisVersionRequest.php b/src/UMem/Apis/DescribeURedisVersionRequest.php index 61c78270..05767dc5 100644 --- a/src/UMem/Apis/DescribeURedisVersionRequest.php +++ b/src/UMem/Apis/DescribeURedisVersionRequest.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,7 +83,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UMem/Apis/DescribeURedisVersionResponse.php b/src/UMem/Apis/DescribeURedisVersionResponse.php index def5df99..bc3c676a 100644 --- a/src/UMem/Apis/DescribeURedisVersionResponse.php +++ b/src/UMem/Apis/DescribeURedisVersionResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new URedisVersionSet($item)); + array_push($result, new URedisVersionSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 组列表 参见 URedisVersionSet * - * @param URedisVersionSet[] $dataSet + * @param URedisVersionSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 总版本个数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UMem/Apis/FlushallURedisGroupRequest.php b/src/UMem/Apis/FlushallURedisGroupRequest.php index aa12a271..b16656ba 100644 --- a/src/UMem/Apis/FlushallURedisGroupRequest.php +++ b/src/UMem/Apis/FlushallURedisGroupRequest.php @@ -1,6 +1,7 @@ markRequired("FlushType"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -106,11 +104,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * FlushType: FlushDb或FlushAll * @@ -126,11 +123,10 @@ public function getFlushType() * * @param string $flushType */ - public function setFlushType($flushType) + public function setFlushType(string $flushType) { $this->set("FlushType", $flushType); } - /** * DbNum: 清空的db,FlushType为FlushDb,此项为必传项 * @@ -146,11 +142,10 @@ public function getDbNum() * * @param int $dbNum */ - public function setDbNum($dbNum) + public function setDbNum(int $dbNum) { $this->set("DbNum", $dbNum); } - /** * TopOrganizationId: company_id * @@ -166,11 +161,10 @@ public function getTopOrganizationId() * * @param int $topOrganizationId */ - public function setTopOrganizationId($topOrganizationId) + public function setTopOrganizationId(int $topOrganizationId) { $this->set("TopOrganizationId", $topOrganizationId); } - /** * OrganizationId: OrganizationId * @@ -186,11 +180,10 @@ public function getOrganizationId() * * @param int $organizationId */ - public function setOrganizationId($organizationId) + public function setOrganizationId(int $organizationId) { $this->set("OrganizationId", $organizationId); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -206,7 +199,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Apis/FlushallURedisGroupResponse.php b/src/UMem/Apis/FlushallURedisGroupResponse.php index 34e157e7..1765d433 100644 --- a/src/UMem/Apis/FlushallURedisGroupResponse.php +++ b/src/UMem/Apis/FlushallURedisGroupResponse.php @@ -1,6 +1,7 @@ markRequired("SpaceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: 内存空间ID * @@ -104,7 +102,7 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } diff --git a/src/UMem/Apis/GetUMemSpaceStateResponse.php b/src/UMem/Apis/GetUMemSpaceStateResponse.php index c22ec477..d41f325f 100644 --- a/src/UMem/Apis/GetUMemSpaceStateResponse.php +++ b/src/UMem/Apis/GetUMemSpaceStateResponse.php @@ -1,6 +1,7 @@ set("State", $state); } diff --git a/src/UMem/Apis/ISolationURedisGroupRequest.php b/src/UMem/Apis/ISolationURedisGroupRequest.php index 1d2da03a..7a46d948 100644 --- a/src/UMem/Apis/ISolationURedisGroupRequest.php +++ b/src/UMem/Apis/ISolationURedisGroupRequest.php @@ -1,6 +1,7 @@ markRequired("TransformType"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -106,11 +104,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * TransformType: UNBind(关闭)或Bind(打开) * @@ -126,11 +123,10 @@ public function getTransformType() * * @param string $transformType */ - public function setTransformType($transformType) + public function setTransformType(string $transformType) { $this->set("TransformType", $transformType); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -146,7 +142,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Apis/ISolationURedisGroupResponse.php b/src/UMem/Apis/ISolationURedisGroupResponse.php index 8ade8094..42e4f0c0 100644 --- a/src/UMem/Apis/ISolationURedisGroupResponse.php +++ b/src/UMem/Apis/ISolationURedisGroupResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: UMem内存空间ID * @@ -105,11 +103,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * Name: 新的名称,长度(6<=size<=63) * @@ -125,7 +122,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UMem/Apis/ModifyUMemSpaceNameResponse.php b/src/UMem/Apis/ModifyUMemSpaceNameResponse.php index 21e5982d..90239360 100644 --- a/src/UMem/Apis/ModifyUMemSpaceNameResponse.php +++ b/src/UMem/Apis/ModifyUMemSpaceNameResponse.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -85,11 +84,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Name: Redis组名称 (范围[6-63],只能包含英文、数字以及符号-和_) * @@ -105,7 +103,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UMem/Apis/ModifyURedisGroupNameResponse.php b/src/UMem/Apis/ModifyURedisGroupNameResponse.php index b017abc4..8e04d9d9 100644 --- a/src/UMem/Apis/ModifyURedisGroupNameResponse.php +++ b/src/UMem/Apis/ModifyURedisGroupNameResponse.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Password: 新密码字符串,要求长度为6~36个字符,且只能包含英文、数字以及-和下划线;并且需要base64加密;如要取消密码,此值为空字符串, * @@ -125,7 +122,7 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } diff --git a/src/UMem/Apis/ModifyURedisGroupPasswordResponse.php b/src/UMem/Apis/ModifyURedisGroupPasswordResponse.php index 0bcbc2d6..f0ba61af 100644 --- a/src/UMem/Apis/ModifyURedisGroupPasswordResponse.php +++ b/src/UMem/Apis/ModifyURedisGroupPasswordResponse.php @@ -1,6 +1,7 @@ markRequired("SpaceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: 实例id * @@ -105,7 +103,7 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } diff --git a/src/UMem/Apis/RemoveUDRedisDataResponse.php b/src/UMem/Apis/RemoveUDRedisDataResponse.php index 0645a61e..2e8c168f 100644 --- a/src/UMem/Apis/RemoveUDRedisDataResponse.php +++ b/src/UMem/Apis/RemoveUDRedisDataResponse.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SpaceId: UMem 内存空间Id * @@ -105,11 +103,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * Size: 内存大小, 单位:GB (需要大于原size,<= 1024) * @@ -125,11 +122,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * CouponId: 使用的代金券Id * @@ -145,7 +141,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UMem/Apis/ResizeUMemSpaceResponse.php b/src/UMem/Apis/ResizeUMemSpaceResponse.php index e0119705..f1103285 100644 --- a/src/UMem/Apis/ResizeUMemSpaceResponse.php +++ b/src/UMem/Apis/ResizeUMemSpaceResponse.php @@ -1,6 +1,7 @@ markRequired("Size"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组ID * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Size: 内存大小, 单位:GB (需要大于原size,且小于等于32) 目前仅支持1/2/4/8/16/32 G 六种容量规格 * @@ -125,11 +122,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * ChargeType: * @@ -145,11 +141,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Type: 空间类型:single(无热备),double(热备)(默认: double) * @@ -165,11 +160,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * CouponId: 代金券ID 请参考DescribeCoupon接口 * @@ -185,7 +179,7 @@ public function getCouponId() * * @param int $couponId */ - public function setCouponId($couponId) + public function setCouponId(int $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UMem/Apis/ResizeURedisGroupResponse.php b/src/UMem/Apis/ResizeURedisGroupResponse.php index d07c2ac8..f73778cf 100644 --- a/src/UMem/Apis/ResizeURedisGroupResponse.php +++ b/src/UMem/Apis/ResizeURedisGroupResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -105,7 +103,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/RestartUMemcacheGroupResponse.php b/src/UMem/Apis/RestartUMemcacheGroupResponse.php index 0c1de7b5..7b9d269c 100644 --- a/src/UMem/Apis/RestartUMemcacheGroupResponse.php +++ b/src/UMem/Apis/RestartUMemcacheGroupResponse.php @@ -1,6 +1,7 @@ markRequired("GroupId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 资源ID * @@ -104,7 +102,7 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } diff --git a/src/UMem/Apis/RestartURedisGroupResponse.php b/src/UMem/Apis/RestartURedisGroupResponse.php index 57a803fb..2eceae44 100644 --- a/src/UMem/Apis/RestartURedisGroupResponse.php +++ b/src/UMem/Apis/RestartURedisGroupResponse.php @@ -1,6 +1,7 @@ markRequired("BackupTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * GroupId: 组的ID * @@ -105,11 +103,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * BackupTime: 备份时间,默认为0 * @@ -125,11 +122,10 @@ public function getBackupTime() * * @param string $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(string $backupTime) { $this->set("BackupTime", $backupTime); } - /** * AutoBackup: 是否打开默认备份功能。enable(打开),disable(关闭),默认enable * @@ -145,11 +141,10 @@ public function getAutoBackup() * * @param string $autoBackup */ - public function setAutoBackup($autoBackup) + public function setAutoBackup(string $autoBackup) { $this->set("AutoBackup", $autoBackup); } - /** * SlaveZone: 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) * @@ -165,7 +160,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Apis/UpdateURedisBackupStrategyResponse.php b/src/UMem/Apis/UpdateURedisBackupStrategyResponse.php index 49a717be..9b4b5b18 100644 --- a/src/UMem/Apis/UpdateURedisBackupStrategyResponse.php +++ b/src/UMem/Apis/UpdateURedisBackupStrategyResponse.php @@ -1,6 +1,7 @@ get("ResourceId"); + } + + /** + * ResourceId: 代理资源id + * + * @param string $resourceId + */ + public function setResourceId(string $resourceId) + { + $this->set("ResourceId", $resourceId); + } + /** + * ProxyId: 代理id + * + * @return string|null + */ + public function getProxyId() + { + return $this->get("ProxyId"); + } + + /** + * ProxyId: 代理id + * + * @param string $proxyId + */ + public function setProxyId(string $proxyId) + { + $this->set("ProxyId", $proxyId); + } + /** + * Vip: 代理ip + * + * @return string|null + */ + public function getVip() + { + return $this->get("Vip"); + } + + /** + * Vip: 代理ip + * + * @param string $vip + */ + public function setVip(string $vip) + { + $this->set("Vip", $vip); + } + /** + * State: 代理状态 + * + * @return string|null + */ + public function getState() + { + return $this->get("State"); + } + + /** + * State: 代理状态 + * + * @param string $state + */ + public function setState(string $state) + { + $this->set("State", $state); + } +} diff --git a/src/UMem/Models/UDRedisSlowlogSet.php b/src/UMem/Models/UDRedisSlowlogSet.php index e6bba3e7..eed167f6 100644 --- a/src/UMem/Models/UDRedisSlowlogSet.php +++ b/src/UMem/Models/UDRedisSlowlogSet.php @@ -1,6 +1,7 @@ set("StartTime", $startTime); } - /** * SpendTime: 查询消耗的时间 * @@ -57,11 +59,10 @@ public function getSpendTime() * * @param int $spendTime */ - public function setSpendTime($spendTime) + public function setSpendTime(int $spendTime) { $this->set("SpendTime", $spendTime); } - /** * Command: 查询命令 * @@ -77,11 +78,10 @@ public function getCommand() * * @param string $command */ - public function setCommand($command) + public function setCommand(string $command) { $this->set("Command", $command); } - /** * BlockId: 分片id * @@ -97,7 +97,7 @@ public function getBlockId() * * @param string $blockId */ - public function setBlockId($blockId) + public function setBlockId(string $blockId) { $this->set("BlockId", $blockId); } diff --git a/src/UMem/Models/UMemBackupSet.php b/src/UMem/Models/UMemBackupSet.php index aa19b1f8..4948f7b2 100644 --- a/src/UMem/Models/UMemBackupSet.php +++ b/src/UMem/Models/UMemBackupSet.php @@ -1,6 +1,7 @@ set("BackupName", $backupName); } - /** * CreateTime: 创建时间 * @@ -57,11 +59,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * State: Starting:备份中 Done:完成 * @@ -77,11 +78,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * BackupId: 空间的备份ID * @@ -97,11 +97,10 @@ public function getBackupId() * * @param string $backupId */ - public function setBackupId($backupId) + public function setBackupId(string $backupId) { $this->set("BackupId", $backupId); } - /** * BackupType: 备份类型: auto(自动) ,manual(手动) * @@ -117,11 +116,10 @@ public function getBackupType() * * @param string $backupType */ - public function setBackupType($backupType) + public function setBackupType(string $backupType) { $this->set("BackupType", $backupType); } - /** * BlockCount: 本次备份,分片的数量 * @@ -137,7 +135,7 @@ public function getBlockCount() * * @param int $blockCount */ - public function setBlockCount($blockCount) + public function setBlockCount(int $blockCount) { $this->set("BlockCount", $blockCount); } diff --git a/src/UMem/Models/UMemBlockInfo.php b/src/UMem/Models/UMemBlockInfo.php index 9c3e51f5..9f0d45ee 100644 --- a/src/UMem/Models/UMemBlockInfo.php +++ b/src/UMem/Models/UMemBlockInfo.php @@ -1,6 +1,7 @@ set("BlockId", $blockId); } - - /** - * BlockVip: 分片ip - * - * @return string|null - */ - public function getBlockVip() - { - return $this->get("BlockVip"); - } - - /** - * BlockVip: 分片ip - * - * @param string $blockVip - */ - public function setBlockVip($blockVip) - { - $this->set("BlockVip", $blockVip); - } - /** * BlockPort: 分片端口 * @@ -77,11 +59,10 @@ public function getBlockPort() * * @param int $blockPort */ - public function setBlockPort($blockPort) + public function setBlockPort(int $blockPort) { $this->set("BlockPort", $blockPort); } - /** * BlockSize: 容量单位GB * @@ -97,31 +78,10 @@ public function getBlockSize() * * @param int $blockSize */ - public function setBlockSize($blockSize) + public function setBlockSize(int $blockSize) { $this->set("BlockSize", $blockSize); } - - /** - * BlockUsedSize: 使用量单位MB - * - * @return integer|null - */ - public function getBlockUsedSize() - { - return $this->get("BlockUsedSize"); - } - - /** - * BlockUsedSize: 使用量单位MB - * - * @param int $blockUsedSize - */ - public function setBlockUsedSize($blockUsedSize) - { - $this->set("BlockUsedSize", $blockUsedSize); - } - /** * BlockState: 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中 SetPasswordFail //设置密码失败 * @@ -137,11 +97,10 @@ public function getBlockState() * * @param string $blockState */ - public function setBlockState($blockState) + public function setBlockState(string $blockState) { $this->set("BlockState", $blockState); } - /** * BlockSlotBegin: 分片维护的键槽起始值 * @@ -157,11 +116,10 @@ public function getBlockSlotBegin() * * @param int $blockSlotBegin */ - public function setBlockSlotBegin($blockSlotBegin) + public function setBlockSlotBegin(int $blockSlotBegin) { $this->set("BlockSlotBegin", $blockSlotBegin); } - /** * BlockSlotEnd: 分片维护的键槽结束值 * @@ -177,8 +135,46 @@ public function getBlockSlotEnd() * * @param int $blockSlotEnd */ - public function setBlockSlotEnd($blockSlotEnd) + public function setBlockSlotEnd(int $blockSlotEnd) { $this->set("BlockSlotEnd", $blockSlotEnd); } + /** + * BlockVip: 分片ip + * + * @return string|null + */ + public function getBlockVip() + { + return $this->get("BlockVip"); + } + + /** + * BlockVip: 分片ip + * + * @param string $blockVip + */ + public function setBlockVip(string $blockVip) + { + $this->set("BlockVip", $blockVip); + } + /** + * BlockUsedSize: 使用量单位MB + * + * @return integer|null + */ + public function getBlockUsedSize() + { + return $this->get("BlockUsedSize"); + } + + /** + * BlockUsedSize: 使用量单位MB + * + * @param int $blockUsedSize + */ + public function setBlockUsedSize(int $blockUsedSize) + { + $this->set("BlockUsedSize", $blockUsedSize); + } } diff --git a/src/UMem/Models/UMemDataSet.php b/src/UMem/Models/UMemDataSet.php index d0ae3ed2..3c106272 100644 --- a/src/UMem/Models/UMemDataSet.php +++ b/src/UMem/Models/UMemDataSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * OwnSlave: 是否拥有只读Slave“Yes” 包含“No” 不包含 * @@ -57,15 +61,14 @@ public function getOwnSlave() * * @param string $ownSlave */ - public function setOwnSlave($ownSlave) + public function setOwnSlave(string $ownSlave) { $this->set("OwnSlave", $ownSlave); } - /** * DataSet: UMEM实例列表 UMemSlaveDataSet 如果没有slave,则没有该字段 * - * @return UMemSlaveDataSet[]|null + * @return UMemSlaveDataSetModel[]|null */ public function getDataSet() { @@ -75,7 +78,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UMemSlaveDataSet($item)); + array_push($result, new UMemSlaveDataSetModel($item)); } return $result; } @@ -83,7 +86,7 @@ public function getDataSet() /** * DataSet: UMEM实例列表 UMemSlaveDataSet 如果没有slave,则没有该字段 * - * @param UMemSlaveDataSet[] $dataSet + * @param UMemSlaveDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -93,7 +96,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * Role: 表示实例是主库还是从库,master,slave仅主备redis返回该项参数 * @@ -109,11 +111,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * RewriteTime: 主备redis和分布式redis运维时间0 //0点1 //1点以此类推单机版memcache不返回该项 * @@ -129,11 +130,10 @@ public function getRewriteTime() * * @param int $rewriteTime */ - public function setRewriteTime($rewriteTime) + public function setRewriteTime(int $rewriteTime) { $this->set("RewriteTime", $rewriteTime); } - /** * VPCId: vpc * @@ -149,11 +149,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网 * @@ -169,11 +168,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ResourceId: 资源ID * @@ -189,11 +187,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * Name: 资源名称 * @@ -209,11 +206,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * CreateTime: 创建时间 * @@ -229,11 +225,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 到期时间 * @@ -249,11 +244,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Type: 空间类型:single(无热备),double(热备) * @@ -269,11 +263,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Protocol: 协议类型: memcache, redis * @@ -289,11 +282,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * Size: 容量单位GB * @@ -309,11 +301,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 使用量单位MB * @@ -329,11 +320,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * State: 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中SetPasswordFail //设置密码失败 * @@ -349,11 +339,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * ChargeType: 计费模式,Year, Month, Dynamic, Trial * @@ -369,15 +358,14 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Address: IP端口信息请,参见UMemSpaceAddressSet * - * @return UMemSpaceAddressSet[]|null + * @return UMemSpaceAddressSetModel[]|null */ public function getAddress() { @@ -387,7 +375,7 @@ public function getAddress() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UMemSpaceAddressSet($item)); + array_push($result, new UMemSpaceAddressSetModel($item)); } return $result; } @@ -395,7 +383,7 @@ public function getAddress() /** * Address: IP端口信息请,参见UMemSpaceAddressSet * - * @param UMemSpaceAddressSet[] $address + * @param UMemSpaceAddressSetModel[] $address */ public function setAddress(array $address) { @@ -405,7 +393,6 @@ public function setAddress(array $address) } return $result; } - /** * Tag: 业务组名称 * @@ -421,11 +408,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ResourceType: distributed: 分布式版Redis,或者分布式Memcache;single:主备版Redis,或者单机Memcache;performance:高性能版 * @@ -441,11 +427,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ConfigId: 节点的配置ID * @@ -461,11 +446,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * AutoBackup: 是否需要自动备份,enable,disable * @@ -481,11 +465,10 @@ public function getAutoBackup() * * @param string $autoBackup */ - public function setAutoBackup($autoBackup) + public function setAutoBackup(string $autoBackup) { $this->set("AutoBackup", $autoBackup); } - /** * BackupTime: 自动备份开始时间,单位小时计,范围[0-23] * @@ -501,11 +484,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * HighAvailability: 是否开启高可用,enable,disable * @@ -521,11 +503,10 @@ public function getHighAvailability() * * @param string $highAvailability */ - public function setHighAvailability($highAvailability) + public function setHighAvailability(string $highAvailability) { $this->set("HighAvailability", $highAvailability); } - /** * Version: Redis版本信息 * @@ -541,11 +522,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * SlaveZone: 跨机房URedis,slave redis所在可用区,参见 [可用区列表](../summary/regionlist.html) * @@ -561,7 +541,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Models/UMemPriceSet.php b/src/UMem/Models/UMemPriceSet.php index b42c6ba9..9559a43e 100644 --- a/src/UMem/Models/UMemPriceSet.php +++ b/src/UMem/Models/UMemPriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 现价 * @@ -57,11 +59,10 @@ public function getPrice() * * @param int $price */ - public function setPrice($price) + public function setPrice(int $price) { $this->set("Price", $price); } - /** * OriginalPrice: 原价 * @@ -77,7 +78,7 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UMem/Models/UMemSlaveDataSet.php b/src/UMem/Models/UMemSlaveDataSet.php index 84b84eec..cd05716b 100644 --- a/src/UMem/Models/UMemSlaveDataSet.php +++ b/src/UMem/Models/UMemSlaveDataSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * SubnetId: 子网 * @@ -57,11 +60,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: vpc * @@ -77,11 +79,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * VirtualIP: * @@ -97,11 +98,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * RewriteTime: 主备Redis返回运维时间 0//0点 1 //1点 以此类推 * @@ -117,11 +117,10 @@ public function getRewriteTime() * * @param int $rewriteTime */ - public function setRewriteTime($rewriteTime) + public function setRewriteTime(int $rewriteTime) { $this->set("RewriteTime", $rewriteTime); } - /** * MasterGroupId: 主实例id * @@ -137,11 +136,10 @@ public function getMasterGroupId() * * @param string $masterGroupId */ - public function setMasterGroupId($masterGroupId) + public function setMasterGroupId(string $masterGroupId) { $this->set("MasterGroupId", $masterGroupId); } - /** * GroupId: 资源id * @@ -157,11 +155,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Port: 端口 * @@ -177,11 +174,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * MemorySize: 实力大小 * @@ -197,11 +193,10 @@ public function getMemorySize() * * @param int $memorySize */ - public function setMemorySize($memorySize) + public function setMemorySize(int $memorySize) { $this->set("MemorySize", $memorySize); } - /** * GroupName: 资源名称 * @@ -217,11 +212,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * Role: 表示实例是主库还是从库,master,slave * @@ -237,11 +231,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * ModifyTime: 修改时间 * @@ -257,11 +250,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * Name: 资源名称 * @@ -277,11 +269,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * CreateTime: 创建时间 * @@ -297,11 +288,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 到期时间 * @@ -317,11 +307,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Size: 容量单位GB * @@ -337,11 +326,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 使用量单位MB * @@ -357,11 +345,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * State: 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中SetPasswordFail //设置密码失败 * @@ -377,11 +364,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * ChargeType: 计费模式,Year, Month, Dynamic, Trial * @@ -397,11 +383,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Tag: 业务组名称 * @@ -417,11 +402,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ResourceType: distributed: 分布式版Redis,或者分布式Memcache;single:主备版Redis,或者单机Memcache;performance:高性能版 * @@ -437,11 +421,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ConfigId: 节点的配置ID * @@ -457,11 +440,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * Version: Redis版本信息 * @@ -477,7 +459,7 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } diff --git a/src/UMem/Models/UMemSpaceAddressSet.php b/src/UMem/Models/UMemSpaceAddressSet.php index e26f3aad..7e43e141 100644 --- a/src/UMem/Models/UMemSpaceAddressSet.php +++ b/src/UMem/Models/UMemSpaceAddressSet.php @@ -1,6 +1,7 @@ set("IP", $ip); } - /** * Port: UMem实例访问Port * @@ -57,7 +62,7 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } diff --git a/src/UMem/Models/UMemSpaceSet.php b/src/UMem/Models/UMemSpaceSet.php index f026e95e..52b860a8 100644 --- a/src/UMem/Models/UMemSpaceSet.php +++ b/src/UMem/Models/UMemSpaceSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * Tag: * @@ -57,11 +60,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * RewriteTime: 运维时间0 //0点1 //1点依次类推 * @@ -77,11 +79,10 @@ public function getRewriteTime() * * @param int $rewriteTime */ - public function setRewriteTime($rewriteTime) + public function setRewriteTime(int $rewriteTime) { $this->set("RewriteTime", $rewriteTime); } - /** * SpaceId: 内存空间ID * @@ -97,11 +98,10 @@ public function getSpaceId() * * @param string $spaceId */ - public function setSpaceId($spaceId) + public function setSpaceId(string $spaceId) { $this->set("SpaceId", $spaceId); } - /** * SubnetId: * @@ -117,11 +117,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: * @@ -137,11 +136,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Name: 内存空间名称 * @@ -157,11 +155,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * CreateTime: 创建时间 * @@ -177,11 +174,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 到期时间 * @@ -197,11 +193,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Type: 空间类型:single(无热备),double(热备) * @@ -217,11 +212,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Protocol: 协议类型: memcache, redis * @@ -237,11 +231,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * Size: 容量单位GB * @@ -257,11 +250,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 使用量单位MB * @@ -277,11 +269,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * State: Starting:创建中 Running:运行中 Fail:失败 * @@ -297,11 +288,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * ChargeType: Year, Month, Dynamic, Trial * @@ -317,15 +307,14 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Address: IP端口信息请参见 UMemSpaceAddressSet * - * @return UMemSpaceAddressSet[]|null + * @return UMemSpaceAddressSetModel[]|null */ public function getAddress() { @@ -335,7 +324,7 @@ public function getAddress() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UMemSpaceAddressSet($item)); + array_push($result, new UMemSpaceAddressSetModel($item)); } return $result; } @@ -343,7 +332,7 @@ public function getAddress() /** * Address: IP端口信息请参见 UMemSpaceAddressSet * - * @param UMemSpaceAddressSet[] $address + * @param UMemSpaceAddressSetModel[] $address */ public function setAddress(array $address) { diff --git a/src/UMem/Models/UMemcacheGroupSet.php b/src/UMem/Models/UMemcacheGroupSet.php index c45f99f3..f989a3cc 100644 --- a/src/UMem/Models/UMemcacheGroupSet.php +++ b/src/UMem/Models/UMemcacheGroupSet.php @@ -1,6 +1,7 @@ set("GroupId", $groupId); } - /** * Name: 组名称 * @@ -57,11 +59,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * ConfigId: 节点的配置ID * @@ -77,11 +78,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * VirtualIP: 节点的虚拟IP地址 * @@ -97,11 +97,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * Port: 节点分配的服务端口 * @@ -117,11 +116,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * Size: 容量单位GB * @@ -137,11 +135,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 使用量单位MB * @@ -157,11 +154,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * Version: Memcache版本信息,默认为1.4.31 * @@ -177,11 +173,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * State: 状态标记 Creating // 初始化中 CreateFail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中 * @@ -197,11 +192,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: 创建时间 (UNIX时间戳) * @@ -217,11 +211,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: 修改时间 (UNIX时间戳) * @@ -237,11 +230,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * ExpireTime: 过期时间 (UNIX时间戳) * @@ -257,11 +249,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * ChargeType: 计费类型:Year,Month,Dynamic 默认Dynamic * @@ -277,11 +268,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Tag: 业务组名称 * @@ -297,7 +287,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/UMem/Models/UMemcachePriceSet.php b/src/UMem/Models/UMemcachePriceSet.php index e204bd0f..a433d975 100644 --- a/src/UMem/Models/UMemcachePriceSet.php +++ b/src/UMem/Models/UMemcachePriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 总价格 * @@ -57,11 +59,10 @@ public function getPrice() * * @param int $price */ - public function setPrice($price) + public function setPrice(int $price) { $this->set("Price", $price); } - /** * ListPrice: 产品列表价 * @@ -77,11 +78,10 @@ public function getListPrice() * * @param int $listPrice */ - public function setListPrice($listPrice) + public function setListPrice(int $listPrice) { $this->set("ListPrice", $listPrice); } - /** * OriginalPrice: 原价 * @@ -97,7 +97,7 @@ public function getOriginalPrice() * * @param int $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(int $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UMem/Models/URedisBackupSet.php b/src/UMem/Models/URedisBackupSet.php index bd58a341..f65d35d1 100644 --- a/src/UMem/Models/URedisBackupSet.php +++ b/src/UMem/Models/URedisBackupSet.php @@ -1,6 +1,7 @@ set("BackupId", $backupId); } - /** * Zone: 可用区,参见[可用区列表](../summary/regionlist.html) * @@ -57,11 +59,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * GroupId: 对应的实例ID * @@ -77,11 +78,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * GroupName: 组名称 * @@ -97,11 +97,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * BackupName: 备份的名称 * @@ -117,11 +116,10 @@ public function getBackupName() * * @param string $backupName */ - public function setBackupName($backupName) + public function setBackupName(string $backupName) { $this->set("BackupName", $backupName); } - /** * BackupTime: 备份时间 (UNIX时间戳) * @@ -137,11 +135,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * BackupSize: 备份文件大小, 以字节为单位 * @@ -157,11 +154,10 @@ public function getBackupSize() * * @param int $backupSize */ - public function setBackupSize($backupSize) + public function setBackupSize(int $backupSize) { $this->set("BackupSize", $backupSize); } - /** * BackupType: 备份类型: Manual 手动 Auto 自动 * @@ -177,11 +173,10 @@ public function getBackupType() * * @param string $backupType */ - public function setBackupType($backupType) + public function setBackupType(string $backupType) { $this->set("BackupType", $backupType); } - /** * State: 备份的状态: Backuping 备份中 Success 备份成功 Error 备份失败 Expired 备份过期 * @@ -197,7 +192,7 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } diff --git a/src/UMem/Models/URedisConfigSet.php b/src/UMem/Models/URedisConfigSet.php index 4f41e7f5..425a39de 100644 --- a/src/UMem/Models/URedisConfigSet.php +++ b/src/UMem/Models/URedisConfigSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * ConfigId: 配置ID * @@ -57,11 +59,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * Name: 配置名称 * @@ -77,11 +78,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Description: 配置描述 * @@ -97,11 +97,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * Version: 配置对应的Redis版本 * @@ -117,11 +116,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * IsModify: 置是否可以修改 * @@ -137,11 +135,10 @@ public function getIsModify() * * @param string $isModify */ - public function setIsModify($isModify) + public function setIsModify(string $isModify) { $this->set("IsModify", $isModify); } - /** * State: 配置所处的状态 * @@ -157,11 +154,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: 创建时间 (UNIX时间戳) * @@ -177,11 +173,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: 修改时间 (UNIX时间戳) * @@ -197,11 +192,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * RegionFlag: 是否是跨机房URedis(默认false) * @@ -217,7 +211,7 @@ public function getRegionFlag() * * @param boolean $regionFlag */ - public function setRegionFlag($regionFlag) + public function setRegionFlag(bool $regionFlag) { $this->set("RegionFlag", $regionFlag); } diff --git a/src/UMem/Models/URedisGroupSet.php b/src/UMem/Models/URedisGroupSet.php index 2b5c12cb..06bdc002 100644 --- a/src/UMem/Models/URedisGroupSet.php +++ b/src/UMem/Models/URedisGroupSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * RewriteTime: 返回运维时间 0 //0点 1 //1点 以此类推 * @@ -57,11 +59,10 @@ public function getRewriteTime() * * @param int $rewriteTime */ - public function setRewriteTime($rewriteTime) + public function setRewriteTime(int $rewriteTime) { $this->set("RewriteTime", $rewriteTime); } - /** * Role: 实例类型 * @@ -77,11 +78,10 @@ public function getRole() * * @param string $role */ - public function setRole($role) + public function setRole(string $role) { $this->set("Role", $role); } - /** * VPCId: vpcid * @@ -97,11 +97,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: subnetid * @@ -117,11 +116,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * GroupId: 组ID * @@ -137,11 +135,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Name: 组名称 * @@ -157,11 +154,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Type: 空间类型:single(无热备),double(热备) * @@ -177,11 +173,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Protocol: 协议 * @@ -197,11 +192,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * MemorySize: 容量单位GB * @@ -217,11 +211,10 @@ public function getMemorySize() * * @param int $memorySize */ - public function setMemorySize($memorySize) + public function setMemorySize(int $memorySize) { $this->set("MemorySize", $memorySize); } - /** * GroupName: 组名称 * @@ -237,11 +230,10 @@ public function getGroupName() * * @param string $groupName */ - public function setGroupName($groupName) + public function setGroupName(string $groupName) { $this->set("GroupName", $groupName); } - /** * ConfigId: 节点的配置ID * @@ -257,11 +249,10 @@ public function getConfigId() * * @param string $configId */ - public function setConfigId($configId) + public function setConfigId(string $configId) { $this->set("ConfigId", $configId); } - /** * VirtualIP: 节点的虚拟IP地址 * @@ -277,11 +268,10 @@ public function getVirtualIP() * * @param string $virtualIP */ - public function setVirtualIP($virtualIP) + public function setVirtualIP(string $virtualIP) { $this->set("VirtualIP", $virtualIP); } - /** * Port: 节点分配的服务端口 * @@ -297,11 +287,10 @@ public function getPort() * * @param int $port */ - public function setPort($port) + public function setPort(int $port) { $this->set("Port", $port); } - /** * Size: 容量单位GB * @@ -317,11 +306,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * UsedSize: 使用量单位MB * @@ -337,11 +325,10 @@ public function getUsedSize() * * @param int $usedSize */ - public function setUsedSize($usedSize) + public function setUsedSize(int $usedSize) { $this->set("UsedSize", $usedSize); } - /** * AutoBackup: 是否需要自动备份,enable,disable * @@ -357,11 +344,10 @@ public function getAutoBackup() * * @param string $autoBackup */ - public function setAutoBackup($autoBackup) + public function setAutoBackup(string $autoBackup) { $this->set("AutoBackup", $autoBackup); } - /** * BackupTime: 组自动备份开始时间,单位小时计,范围[0-23] * @@ -377,11 +363,10 @@ public function getBackupTime() * * @param int $backupTime */ - public function setBackupTime($backupTime) + public function setBackupTime(int $backupTime) { $this->set("BackupTime", $backupTime); } - /** * HighAvailability: 是否开启高可用,enable,disable * @@ -397,11 +382,10 @@ public function getHighAvailability() * * @param string $highAvailability */ - public function setHighAvailability($highAvailability) + public function setHighAvailability(string $highAvailability) { $this->set("HighAvailability", $highAvailability); } - /** * Version: Redis版本信息 * @@ -417,11 +401,10 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } - /** * ExpireTime: 过期时间 (UNIX时间戳) * @@ -437,11 +420,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * ChargeType: 计费类型:Year,Month,Dynamic 默认Dynamic * @@ -457,11 +439,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * State: 状态标记 Creating // 初始化中 CreateFail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败 * @@ -477,11 +458,10 @@ public function getState() * * @param string $state */ - public function setState($state) + public function setState(string $state) { $this->set("State", $state); } - /** * CreateTime: 创建时间 (UNIX时间戳) * @@ -497,11 +477,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ModifyTime: 修改时间 (UNIX时间戳) * @@ -517,11 +496,10 @@ public function getModifyTime() * * @param int $modifyTime */ - public function setModifyTime($modifyTime) + public function setModifyTime(int $modifyTime) { $this->set("ModifyTime", $modifyTime); } - /** * Tag: 业务组名称 * @@ -537,11 +515,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * SlaveZone: 跨机房URedis,slave redis所在可用区,参见 [可用区列表](../summary/regionlist.html) * @@ -557,7 +534,7 @@ public function getSlaveZone() * * @param string $slaveZone */ - public function setSlaveZone($slaveZone) + public function setSlaveZone(string $slaveZone) { $this->set("SlaveZone", $slaveZone); } diff --git a/src/UMem/Models/URedisPriceSet.php b/src/UMem/Models/URedisPriceSet.php index 636f1f06..95c92fef 100644 --- a/src/UMem/Models/URedisPriceSet.php +++ b/src/UMem/Models/URedisPriceSet.php @@ -1,6 +1,7 @@ set("OriginalPrice", $originalPrice); } - /** * ChargeType: Year, Month, Dynamic,Trial * @@ -57,11 +59,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ListPrice: 产品列表价 * @@ -77,11 +78,10 @@ public function getListPrice() * * @param int $listPrice */ - public function setListPrice($listPrice) + public function setListPrice(int $listPrice) { $this->set("ListPrice", $listPrice); } - /** * Price: 总价格 * @@ -97,7 +97,7 @@ public function getPrice() * * @param int $price */ - public function setPrice($price) + public function setPrice(int $price) { $this->set("Price", $price); } diff --git a/src/UMem/Models/URedisSlowlogSet.php b/src/UMem/Models/URedisSlowlogSet.php index 8aba62f7..aaf1ab3e 100644 --- a/src/UMem/Models/URedisSlowlogSet.php +++ b/src/UMem/Models/URedisSlowlogSet.php @@ -1,6 +1,7 @@ set("StartTime", $startTime); } - /** * SpendTime: 查询消耗的时间 * @@ -57,11 +59,10 @@ public function getSpendTime() * * @param int $spendTime */ - public function setSpendTime($spendTime) + public function setSpendTime(int $spendTime) { $this->set("SpendTime", $spendTime); } - /** * Command: 查询命令 * @@ -77,7 +78,7 @@ public function getCommand() * * @param string $command */ - public function setCommand($command) + public function setCommand(string $command) { $this->set("Command", $command); } diff --git a/src/UMem/Models/URedisVersionSet.php b/src/UMem/Models/URedisVersionSet.php index 2f62413b..5638b5c9 100644 --- a/src/UMem/Models/URedisVersionSet.php +++ b/src/UMem/Models/URedisVersionSet.php @@ -1,6 +1,7 @@ set("Version", $version); } diff --git a/src/UMem/UMemClient.php b/src/UMem/UMemClient.php index 187b4d3d..70ea8acd 100644 --- a/src/UMem/UMemClient.php +++ b/src/UMem/UMemClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Size" => (integer) 创建实例的容量大小,,扩容时的分片目标容量大小 - * "Count" => (string) 创建实例的数量,[1-10] - * "GroupId" => (string) 资源ID,扩缩容时的必传参数 - * ] - * - * Outputs: - * - * $outputs = [ - * "Count" => (integer) 创建实例资源时,表示可创建的数量;扩容资源时,返回1表示可以扩容,0表示可用区资源不足不能扩容 - * ] - * - * @return CheckUDredisSpaceAllowanceResponse * @throws UCloudException */ public function checkUDredisSpaceAllowance(CheckUDredisSpaceAllowanceRequest $request = null) @@ -136,32 +251,13 @@ public function checkUDredisSpaceAllowance(CheckUDredisSpaceAllowanceRequest $re $resp = $this->invoke($request); return new CheckUDredisSpaceAllowanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CheckURedisAllowance - 检查主备Redis的资源是否足够创建新实例,以及主备Redis的扩容资源预检查 * - * See also: https://docs.ucloud.cn/api/umem-api/check_uredis_allowance - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 创建实例的容量大小, 单位:GB 目前仅支持1/2/4/8/16/32六种规格;扩缩容时,表示实例的目标资源大小 - * "Count" => (integer) 创建实例的数量,[1-10] - * "Protocol" => (string) - * "RegionFlag" => (boolean) 是否是跨机房URedis(默认false) - * "GroupId" => (string) 资源ID,扩容实例资源时的必传参数 - * ] - * - * Outputs: - * - * $outputs = [ - * "Count" => (integer) 创建实例资源时,表示可创建的数量;扩容资源时,返回1表示可以扩容,0表示可用区资源不足不能扩容 - * ] - * - * @return CheckURedisAllowanceResponse * @throws UCloudException */ public function checkURedisAllowance(CheckURedisAllowanceRequest $request = null) @@ -169,29 +265,13 @@ public function checkURedisAllowance(CheckURedisAllowanceRequest $request = null $resp = $this->invoke($request); return new CheckURedisAllowanceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUMemBackup - 创建分布式redis备份 * - * See also: https://docs.ucloud.cn/api/umem-api/create_umem_backup - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) 资源id - * "BackupName" => (string) 请求创建备份的名称 (范围[6-63],只能包含英文、数字以及符号-和_) - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupId" => (string) 备份Id - * ] - * - * @return CreateUMemBackupResponse * @throws UCloudException */ public function createUMemBackup(CreateUMemBackupRequest $request = null) @@ -199,34 +279,13 @@ public function createUMemBackup(CreateUMemBackupRequest $request = null) $resp = $this->invoke($request); return new CreateUMemBackupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUMemSpace - 创建UMem内存空间 * - * See also: https://docs.ucloud.cn/api/umem-api/create_umem_space - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Size" => (integer) 内存大小, 单位:GB, 范围[1~1024] - * "Name" => (string) 空间名称,长度(6<=size<=63) - * "Protocol" => (string) 协议:memcache, redis (默认redis).注意:redis无single类型 - * "Type" => (string) 空间类型:single(无热备),double(热备)(默认: double) - * "ChargeType" => (string) Year , Month, Dynamic, Trial 默认: Month - * "Quantity" => (integer) 购买时长 默认: 1 - * "CouponId" => (string) 使用的代金券id - * ] - * - * Outputs: - * - * $outputs = [ - * "SpaceId" => (string) 创建内存空间ID列表 - * ] - * - * @return CreateUMemSpaceResponse * @throws UCloudException */ public function createUMemSpace(CreateUMemSpaceRequest $request = null) @@ -234,36 +293,13 @@ public function createUMemSpace(CreateUMemSpaceRequest $request = null) $resp = $this->invoke($request); return new CreateUMemSpaceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUMemcacheGroup - 创建单机Memcache * - * See also: https://docs.ucloud.cn/api/umem-api/create_umem_cache_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) 请求创建组的名称 范围[6-60] - * "Size" => (integer) 每个节点的内存大小,单位GB,默认1GB 目前仅支持1/2/4/8/16/32这几档 - * "ConfigId" => (string) 配置ID,目前仅支持默认配置id 默认配置id:"9a891891-c245-4b66-bce8-67e59430d67c" - * "Version" => (string) Memcache版本信息,默认为1.4.31 - * "ChargeType" => (string) 计费模式,Year , Month, Dynamic 默认: Month - * "Quantity" => (integer) 购买时长,默认为1 - * "Tag" => (string) 业务组 默认:Default - * "Protocol" => (string) - * "CouponId" => (string) 代金券ID - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (string) 创建的组ID - * ] - * - * @return CreateUMemcacheGroupResponse * @throws UCloudException */ public function createUMemcacheGroup(CreateUMemcacheGroupRequest $request = null) @@ -271,30 +307,13 @@ public function createUMemcacheGroup(CreateUMemcacheGroupRequest $request = null $resp = $this->invoke($request); return new CreateUMemcacheGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateURedisBackup - 创建主备Redis备份 * - * See also: https://docs.ucloud.cn/api/umem-api/create_uredis_backup - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 资源id - * "BackupName" => (string) 请求创建组的名称 (范围[6-63],只能包含英文、数字以及符号-和_) - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupId" => (string) 备份id - * ] - * - * @return CreateURedisBackupResponse * @throws UCloudException */ public function createURedisBackup(CreateURedisBackupRequest $request = null) @@ -302,45 +321,13 @@ public function createURedisBackup(CreateURedisBackupRequest $request = null) $resp = $this->invoke($request); return new CreateURedisBackupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateURedisGroup - 创建主备redis * - * See also: https://docs.ucloud.cn/api/umem-api/create_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) 请求创建组的名称 (范围[6-63],只能包含英文、数字以及符号-和_) - * "HighAvailability" => (string) 是否开启高可用,enable或disable - * "Size" => (integer) 每个节点的内存大小,单位GB,默认1GB,目前仅支持1/2/4/8/16/32,六种 - * "AutoBackup" => (string) 是否自动备份,enable或disable,默认disable - * "BackupTime" => (integer) 自动备份开始时间,范围[0-23],默认3点 - * "ConfigId" => (string) 配置ID,目前支持 3.0版本配置ID:"03f58ca9-b64d-4bdd-abc7-c6b9a46fd801",3.2版本配置ID:"3e45ac48-f8a2-a9q2-261d-l342dab130gf", 4.0版本配置ID:"6c9298a3-9d7f-428c-b1d0-e87ab3b8a1ea",默认版本3.0,从备份创建为必传项 - * "Version" => (string) Redis版本信息(详见DescribeURedisVersion返回结果),默认版本3.0 - * "ChargeType" => (string) 计费模式,Year , Month, Dynamic 默认: Month - * "Quantity" => (integer) 购买时长,默认为1 - * "Tag" => (string) 业务组名称 - * "Password" => (string) 初始化密码,需要 base64 编码 - * "BackupId" => (string) 有此项代表从备份中创建,无代表正常创建 - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * "MasterGroupId" => (string) Master Redis Group的ID,创建只读Slave时,必须填写 - * "EnableIpV6" => (boolean) 是否创建使用ipv6 资源, 默认为false, 或者不填, 创建ipv6为true - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC的ID - * "CouponId" => (string) 代金券ID - * ] - * - * Outputs: - * - * $outputs = [ - * "GroupId" => (string) 创建的组ID - * ] - * - * @return CreateURedisGroupResponse * @throws UCloudException */ public function createURedisGroup(CreateURedisGroupRequest $request = null) @@ -348,27 +335,13 @@ public function createURedisGroup(CreateURedisGroupRequest $request = null) $resp = $this->invoke($request); return new CreateURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUMemSpace - 删除UMem内存空间 * - * See also: https://docs.ucloud.cn/api/umem-api/delete_umem_space - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) UMem内存空间ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUMemSpaceResponse * @throws UCloudException */ public function deleteUMemSpace(DeleteUMemSpaceRequest $request = null) @@ -376,27 +349,13 @@ public function deleteUMemSpace(DeleteUMemSpaceRequest $request = null) $resp = $this->invoke($request); return new DeleteUMemSpaceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUMemcacheGroup - 删除单机Memcache * - * See also: https://docs.ucloud.cn/api/umem-api/delete_umem_cache_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUMemcacheGroupResponse * @throws UCloudException */ public function deleteUMemcacheGroup(DeleteUMemcacheGroupRequest $request = null) @@ -404,26 +363,13 @@ public function deleteUMemcacheGroup(DeleteUMemcacheGroupRequest $request = null $resp = $this->invoke($request); return new DeleteUMemcacheGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteURedisGroup - 删除主备redis * - * See also: https://docs.ucloud.cn/api/umem-api/delete_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteURedisGroupResponse * @throws UCloudException */ public function deleteURedisGroup(DeleteURedisGroupRequest $request = null) @@ -431,37 +377,27 @@ public function deleteURedisGroup(DeleteURedisGroupRequest $request = null) $resp = $this->invoke($request); return new DeleteURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DescribeUDRedisSlowlog - 查询UDRedis慢日志 - * - * See also: https://docs.ucloud.cn/api/umem-api/describe_ud_redis_slowlog - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "InstanceId" => (string) 实例id - * "Limit" => (integer) 分页显示的条目数,默认为10 - * ] + * DescribeUDRedisProxyInfo - 拉取udredis所有的代理信息 * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 总条目数 - * "DataSet" => (array) 条目数据[ - * [ - * "StartTime" => (integer) 查询发生的时间 - * "SpendTime" => (integer) 查询消耗的时间 - * "Command" => (string) 查询命令 - * "BlockId" => (string) 分片id - * ] - * ] - * ] + * @throws UCloudException + */ + public function describeUDRedisProxyInfo(DescribeUDRedisProxyInfoRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeUDRedisProxyInfoResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeUDRedisSlowlog - 查询UDRedis慢日志 * - * @return DescribeUDRedisSlowlogResponse * @throws UCloudException */ public function describeUDRedisSlowlog(DescribeUDRedisSlowlogRequest $request = null) @@ -469,92 +405,13 @@ public function describeUDRedisSlowlog(DescribeUDRedisSlowlogRequest $request = $resp = $this->invoke($request); return new DescribeUDRedisSlowlogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMem - 获取UMem列表 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Protocol" => (string) 协议类型: memcache, redis - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为20 - * "ResourceId" => (string) 资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 根据过滤条件得到的总数 - * "DataSet" => (array) UMem实例列表, 详细参见UMemDataSet[ - * [ - * "Zone" => (string) 实例所在可用区,或者master redis所在可用区,参见 [可用区列表](../summary/regionlist.html) - * "OwnSlave" => (string) 是否拥有只读Slave“Yes” 包含“No” 不包含 - * "DataSet" => (array) UMEM实例列表 UMemSlaveDataSet 如果没有slave,则没有该字段[ - * [ - * "Zone" => (string) 实例所在可用区,或者master redis所在可用区,参见 [可用区列表](../summary/regionlist.html) - * "SubnetId" => (string) 子网 - * "VPCId" => (string) vpc - * "VirtualIP" => (string) - * "RewriteTime" => (integer) 主备Redis返回运维时间 0//0点 1 //1点 以此类推 - * "MasterGroupId" => (string) 主实例id - * "GroupId" => (string) 资源id - * "Port" => (integer) 端口 - * "MemorySize" => (integer) 实力大小 - * "GroupName" => (string) 资源名称 - * "Role" => (string) 表示实例是主库还是从库,master,slave - * "ModifyTime" => (integer) 修改时间 - * "Name" => (string) 资源名称 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 到期时间 - * "Size" => (integer) 容量单位GB - * "UsedSize" => (integer) 使用量单位MB - * "State" => (string) 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中SetPasswordFail //设置密码失败 - * "ChargeType" => (string) 计费模式,Year, Month, Dynamic, Trial - * "Tag" => (string) 业务组名称 - * "ResourceType" => (string) distributed: 分布式版Redis,或者分布式Memcache;single:主备版Redis,或者单机Memcache;performance:高性能版 - * "ConfigId" => (string) 节点的配置ID - * "Version" => (string) Redis版本信息 - * ] - * ] - * "Role" => (string) 表示实例是主库还是从库,master,slave仅主备redis返回该项参数 - * "RewriteTime" => (integer) 主备redis和分布式redis运维时间0 //0点1 //1点以此类推单机版memcache不返回该项 - * "VPCId" => (string) vpc - * "SubnetId" => (string) 子网 - * "ResourceId" => (string) 资源ID - * "Name" => (string) 资源名称 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 到期时间 - * "Type" => (string) 空间类型:single(无热备),double(热备) - * "Protocol" => (string) 协议类型: memcache, redis - * "Size" => (integer) 容量单位GB - * "UsedSize" => (integer) 使用量单位MB - * "State" => (string) 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中SetPasswordFail //设置密码失败 - * "ChargeType" => (string) 计费模式,Year, Month, Dynamic, Trial - * "Address" => (array) IP端口信息请,参见UMemSpaceAddressSet[ - * [ - * "IP" => (string) UMem实例访问IP - * "Port" => (integer) UMem实例访问Port - * ] - * ] - * "Tag" => (string) 业务组名称 - * "ResourceType" => (string) distributed: 分布式版Redis,或者分布式Memcache;single:主备版Redis,或者单机Memcache;performance:高性能版 - * "ConfigId" => (string) 节点的配置ID - * "AutoBackup" => (string) 是否需要自动备份,enable,disable - * "BackupTime" => (integer) 自动备份开始时间,单位小时计,范围[0-23] - * "HighAvailability" => (string) 是否开启高可用,enable,disable - * "Version" => (string) Redis版本信息 - * "SlaveZone" => (string) 跨机房URedis,slave redis所在可用区,参见 [可用区列表](../summary/regionlist.html) - * ] - * ] - * ] - * - * @return DescribeUMemResponse * @throws UCloudException */ public function describeUMem(DescribeUMemRequest $request = null) @@ -562,39 +419,13 @@ public function describeUMem(DescribeUMemRequest $request = null) $resp = $this->invoke($request); return new DescribeUMemResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemBackup - 查询分布式redis备份 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_backup - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) 资源id - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为10 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 分布式redis 备份,数组的每个元素为每个分片的备份[ - * [ - * "BackupName" => (string) 备份名称 - * "CreateTime" => (integer) 创建时间 - * "State" => (string) Starting:备份中 Done:完成 - * "BackupId" => (string) 空间的备份ID - * "BackupType" => (string) 备份类型: auto(自动) ,manual(手动) - * "BlockCount" => (integer) 本次备份,分片的数量 - * ] - * ] - * ] - * - * @return DescribeUMemBackupResponse * @throws UCloudException */ public function describeUMemBackup(DescribeUMemBackupRequest $request = null) @@ -602,30 +433,13 @@ public function describeUMemBackup(DescribeUMemBackupRequest $request = null) $resp = $this->invoke($request); return new DescribeUMemBackupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemBackupURL - 获取分布式redis 备份下载链接 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_backup_url - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) 资源id - * "BackupId" => (string) 备份Id - * "BlockId" => (string) 分片id - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupURL" => (array) 备份url,每个分片一个下载URL - * ] - * - * @return DescribeUMemBackupURLResponse * @throws UCloudException */ public function describeUMemBackupURL(DescribeUMemBackupURLRequest $request = null) @@ -633,41 +447,13 @@ public function describeUMemBackupURL(DescribeUMemBackupURLRequest $request = nu $resp = $this->invoke($request); return new DescribeUMemBackupURLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemBlockInfo - 拉取UDRedis分片信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_block_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) UMem内存资源ID - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为10 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 分布式redis 分片信息[ - * [ - * "BlockId" => (string) 分片id - * "BlockVip" => (string) 分片ip - * "BlockPort" => (integer) 分片端口 - * "BlockSize" => (integer) 容量单位GB - * "BlockUsedSize" => (integer) 使用量单位MB - * "BlockState" => (string) 实例状态 Starting // 创建中 Creating // 初始化中 CreateFail // 创建失败 Fail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中 SetPasswordFail //设置密码失败 - * "BlockSlotBegin" => (integer) 分片维护的键槽起始值 - * "BlockSlotEnd" => (integer) 分片维护的键槽结束值 - * ] - * ] - * ] - * - * @return DescribeUMemBlockInfoResponse * @throws UCloudException */ public function describeUMemBlockInfo(DescribeUMemBlockInfoRequest $request = null) @@ -675,37 +461,13 @@ public function describeUMemBlockInfo(DescribeUMemBlockInfoRequest $request = nu $resp = $this->invoke($request); return new DescribeUMemBlockInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemPrice - 获取UMem实例价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买umem大小,单位:GB,范围[1~1024] - * "Type" => (string) 空间类型:single(无热备),double(热备)(默认: double) - * "ChargeType" => (string) Year, Month, Dynamic 如果不指定,则一次性获取三种计费 - * "Quantity" => (integer) 购买UMem的时长,默认值为1 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 价格 参数见 UMemPriceSet[ - * [ - * "ChargeType" => (string) Year, Month, Dynamic,Trial - * "Price" => (integer) 现价 - * "OriginalPrice" => (integer) 原价 - * ] - * ] - * ] - * - * @return DescribeUMemPriceResponse * @throws UCloudException */ public function describeUMemPrice(DescribeUMemPriceRequest $request = null) @@ -713,56 +475,13 @@ public function describeUMemPrice(DescribeUMemPriceRequest $request = null) $resp = $this->invoke($request); return new DescribeUMemPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemSpace - 获取UMem内存空间列表 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_space - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 返回数据长度, 默认为20 - * "SpaceId" => (string) 内存空间ID (无ID,则获取所有) - * "Protocol" => (string) 协议类型: memcache, redis - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) JSON 格式的UMem内存空间实例列表, 详细参见 UMemSpaceSet[ - * [ - * "Zone" => (string) 可用区,参见[可用区列表](../summary/regionlist.html) - * "Tag" => (string) - * "RewriteTime" => (integer) 运维时间0 //0点1 //1点依次类推 - * "SpaceId" => (string) 内存空间ID - * "SubnetId" => (string) - * "VPCId" => (string) - * "Name" => (string) 内存空间名称 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 到期时间 - * "Type" => (string) 空间类型:single(无热备),double(热备) - * "Protocol" => (string) 协议类型: memcache, redis - * "Size" => (integer) 容量单位GB - * "UsedSize" => (integer) 使用量单位MB - * "State" => (string) Starting:创建中 Running:运行中 Fail:失败 - * "ChargeType" => (string) Year, Month, Dynamic, Trial - * "Address" => (array) IP端口信息请参见 UMemSpaceAddressSet[ - * [ - * "IP" => (string) UMem实例访问IP - * "Port" => (integer) UMem实例访问Port - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 根据过滤条件得到的总数 - * ] - * - * @return DescribeUMemSpaceResponse * @throws UCloudException */ public function describeUMemSpace(DescribeUMemSpaceRequest $request = null) @@ -770,31 +489,13 @@ public function describeUMemSpace(DescribeUMemSpaceRequest $request = null) $resp = $this->invoke($request); return new DescribeUMemSpaceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemUpgradePrice - 获取UMem升级价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Size" => (integer) 购买UMem大小,单位:GB - * "Type" => (string) 空间类型:single(无热备),double(热备)(默认: double) - * "SpaceId" => (string) 需要升级的空间的SpaceId - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (integer) 价格 - * "OriginalPrice" => (integer) 原价 - * ] - * - * @return DescribeUMemUpgradePriceResponse * @throws UCloudException */ public function describeUMemUpgradePrice(DescribeUMemUpgradePriceRequest $request = null) @@ -802,48 +503,13 @@ public function describeUMemUpgradePrice(DescribeUMemUpgradePriceRequest $reques $resp = $this->invoke($request); return new DescribeUMemUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemcacheGroup - 显示Memcache * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_cache_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID,如果指定则获取描述,否则为列表操 作,需指定Offset/Limit - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 组的总的节点个数 - * "DataSet" => (array) 组列表,参见 UMemcacheGroupSet[ - * [ - * "GroupId" => (string) 组ID - * "Name" => (string) 组名称 - * "ConfigId" => (string) 节点的配置ID - * "VirtualIP" => (string) 节点的虚拟IP地址 - * "Port" => (integer) 节点分配的服务端口 - * "Size" => (integer) 容量单位GB - * "UsedSize" => (integer) 使用量单位MB - * "Version" => (string) Memcache版本信息,默认为1.4.31 - * "State" => (string) 状态标记 Creating // 初始化中 CreateFail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败Restarting // 重启中 - * "CreateTime" => (integer) 创建时间 (UNIX时间戳) - * "ModifyTime" => (integer) 修改时间 (UNIX时间戳) - * "ExpireTime" => (integer) 过期时间 (UNIX时间戳) - * "ChargeType" => (string) 计费类型:Year,Month,Dynamic 默认Dynamic - * "Tag" => (string) 业务组名称 - * ] - * ] - * ] - * - * @return DescribeUMemcacheGroupResponse * @throws UCloudException */ public function describeUMemcacheGroup(DescribeUMemcacheGroupRequest $request = null) @@ -851,38 +517,13 @@ public function describeUMemcacheGroup(DescribeUMemcacheGroupRequest $request = $resp = $this->invoke($request); return new DescribeUMemcacheGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemcachePrice - 获取umemcache组价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_cache_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Size" => (integer) 容量大小,单位:GB 取值范围[1-32] - * "ChargeType" => (string) 计费模式,Year, Month, Dynamic,默认: Dynamic 默认: 获取所有计费模式的价格 - * "Quantity" => (integer) 购买umemcache的时长,默认值为1 - * "Type" => (string) 空间类型:single(无热备),double(热备)(默认: double) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 价格列表, 参见 UMemcachePriceSet[ - * [ - * "ChargeType" => (string) 计费模式,Year, Month, Dynamic - * "Price" => (integer) 总价格 - * "ListPrice" => (integer) 产品列表价 - * "OriginalPrice" => (integer) 原价 - * ] - * ] - * ] - * - * @return DescribeUMemcachePriceResponse * @throws UCloudException */ public function describeUMemcachePrice(DescribeUMemcachePriceRequest $request = null) @@ -890,26 +531,13 @@ public function describeUMemcachePrice(DescribeUMemcachePriceRequest $request = $resp = $this->invoke($request); return new DescribeUMemcachePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeUMemcacheUpgradePrice - 获取umemcache升级价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_umem_cache_upgrade_price - * - * Arguments: - * - * $args = [ - * "Size" => (integer) 购买umemcache大小,单位:GB - * "GroupId" => (string) 需要升级的空间的GroupId,请参考DescribeUMemcacheGroup接口 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 价格,单位:元 - * ] - * - * @return DescribeUMemcacheUpgradePriceResponse * @throws UCloudException */ public function describeUMemcacheUpgradePrice(DescribeUMemcacheUpgradePriceRequest $request = null) @@ -917,42 +545,13 @@ public function describeUMemcacheUpgradePrice(DescribeUMemcacheUpgradePriceReque $resp = $this->invoke($request); return new DescribeUMemcacheUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisBackup - 查询主备redis备份 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_backup - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为10 - * "GroupId" => (string) 组的ID - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 用户名下总的备份个数 - * "DataSet" => (array) 备份列表 参见 URedisBackupSet[ - * [ - * "BackupId" => (string) 备份ID - * "Zone" => (string) 可用区,参见[可用区列表](../summary/regionlist.html) - * "GroupId" => (string) 对应的实例ID - * "GroupName" => (string) 组名称 - * "BackupName" => (string) 备份的名称 - * "BackupTime" => (integer) 备份时间 (UNIX时间戳) - * "BackupSize" => (integer) 备份文件大小, 以字节为单位 - * "BackupType" => (string) 备份类型: Manual 手动 Auto 自动 - * "State" => (string) 备份的状态: Backuping 备份中 Success 备份成功 Error 备份失败 Expired 备份过期 - * ] - * ] - * ] - * - * @return DescribeURedisBackupResponse * @throws UCloudException */ public function describeURedisBackup(DescribeURedisBackupRequest $request = null) @@ -960,32 +559,13 @@ public function describeURedisBackup(DescribeURedisBackupRequest $request = null $resp = $this->invoke($request); return new DescribeURedisBackupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisBackupURL - 获取主备Redis备份下载链接 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_backup_url - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BackupId" => (string) 备份ID - * "RegionFlag" => (boolean) 是否是跨机房URedis(默认false) - * "GroupId" => (string) 实例名称 - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * ] - * - * Outputs: - * - * $outputs = [ - * "BackupURL" => (string) 备份文件公网的地址 - * "BackupPath" => (string) 备份文件公网的地址 - * ] - * - * @return DescribeURedisBackupURLResponse * @throws UCloudException */ public function describeURedisBackupURL(DescribeURedisBackupURLRequest $request = null) @@ -993,46 +573,13 @@ public function describeURedisBackupURL(DescribeURedisBackupURLRequest $request $resp = $this->invoke($request); return new DescribeURedisBackupURLResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisConfig - 查询主备Redis所有配置文件 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_config - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RegionFlag" => (boolean) 是否是跨机房URedis(默认false) - * "Version" => (string) Redis版本号 - * "ConfigId" => (string) 配置文件ID - * "Offset" => (integer) 页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 页显示的条目数, 默认值为10 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 根据过滤条件得到的总数 - * "DataSet" => (array) 配置文件列表 参见 URedisConfigSet[ - * [ - * "Zone" => (string) Zone - * "ConfigId" => (string) 配置ID - * "Name" => (string) 配置名称 - * "Description" => (string) 配置描述 - * "Version" => (string) 配置对应的Redis版本 - * "IsModify" => (string) 置是否可以修改 - * "State" => (string) 配置所处的状态 - * "CreateTime" => (integer) 创建时间 (UNIX时间戳) - * "ModifyTime" => (integer) 修改时间 (UNIX时间戳) - * "RegionFlag" => (boolean) 是否是跨机房URedis(默认false) - * ] - * ] - * ] - * - * @return DescribeURedisConfigResponse * @throws UCloudException */ public function describeURedisConfig(DescribeURedisConfigRequest $request = null) @@ -1040,61 +587,13 @@ public function describeURedisConfig(DescribeURedisConfigRequest $request = null $resp = $this->invoke($request); return new DescribeURedisConfigResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisGroup - 查询主备Redis * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "GroupId" => (string) 组的ID,如果指定则获取描述,否则为列表操 作,需指定Offset/Limit - * "Offset" => (integer) 分页显示的起始偏移, 默认值为0 - * "Limit" => (integer) 分页显示的条目数, 默认值为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 组的总的节点个数 - * "DataSet" => (array) 组列表 参见 URedisGroupSet[ - * [ - * "Zone" => (string) 实例所在可用区,或者master redis所在可用区,参见 [可用区列表](../summary/regionlist.html) - * "RewriteTime" => (integer) 返回运维时间 0 //0点 1 //1点 以此类推 - * "Role" => (string) 实例类型 - * "VPCId" => (string) vpcid - * "SubnetId" => (string) subnetid - * "GroupId" => (string) 组ID - * "Name" => (string) 组名称 - * "Type" => (string) 空间类型:single(无热备),double(热备) - * "Protocol" => (string) 协议 - * "MemorySize" => (integer) 容量单位GB - * "GroupName" => (string) 组名称 - * "ConfigId" => (string) 节点的配置ID - * "VirtualIP" => (string) 节点的虚拟IP地址 - * "Port" => (integer) 节点分配的服务端口 - * "Size" => (integer) 容量单位GB - * "UsedSize" => (integer) 使用量单位MB - * "AutoBackup" => (string) 是否需要自动备份,enable,disable - * "BackupTime" => (integer) 组自动备份开始时间,单位小时计,范围[0-23] - * "HighAvailability" => (string) 是否开启高可用,enable,disable - * "Version" => (string) Redis版本信息 - * "ExpireTime" => (integer) 过期时间 (UNIX时间戳) - * "ChargeType" => (string) 计费类型:Year,Month,Dynamic 默认Dynamic - * "State" => (string) 状态标记 Creating // 初始化中 CreateFail // 创建失败 Deleting // 删除中 DeleteFail // 删除失败 Running // 运行 Resizing // 容量调整中 ResizeFail // 容量调整失败 Configing // 配置中 ConfigFail // 配置失败 - * "CreateTime" => (integer) 创建时间 (UNIX时间戳) - * "ModifyTime" => (integer) 修改时间 (UNIX时间戳) - * "Tag" => (string) 业务组名称 - * "SlaveZone" => (string) 跨机房URedis,slave redis所在可用区,参见 [可用区列表](../summary/regionlist.html) - * ] - * ] - * ] - * - * @return DescribeURedisGroupResponse * @throws UCloudException */ public function describeURedisGroup(DescribeURedisGroupRequest $request = null) @@ -1102,39 +601,13 @@ public function describeURedisGroup(DescribeURedisGroupRequest $request = null) $resp = $this->invoke($request); return new DescribeURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisPrice - 取uredis价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Size" => (integer) 量大小,单位:GB 取值范围[1-32] - * "ChargeType" => (string) 计费模式,Year, Month, Dynamic;如果不指定,则一次性获取三种计费 - * "Quantity" => (integer) 计费模式为Dynamic时,购买的时长, 默认为1 - * "RegionFlag" => (boolean) 是否是跨机房URedis(默认false) - * "ProductType" => (string) 产品类型:MS_Redis(标准主备版),S_Redis(从库),默认为MS_Redis - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 价格 参数见 UMemPriceSet[ - * [ - * "OriginalPrice" => (integer) 原价 - * "ChargeType" => (string) Year, Month, Dynamic,Trial - * "ListPrice" => (integer) 产品列表价 - * "Price" => (integer) 总价格 - * ] - * ] - * ] - * - * @return DescribeURedisPriceResponse * @throws UCloudException */ public function describeURedisPrice(DescribeURedisPriceRequest $request = null) @@ -1142,36 +615,13 @@ public function describeURedisPrice(DescribeURedisPriceRequest $request = null) $resp = $this->invoke($request); return new DescribeURedisPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisSlowlog - 查询URedis慢日志 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_slowlog - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 资源ID - * "Limit" => (integer) 分页显示的条目数,默认为10 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 总条目数 - * "DataSet" => (array) 条目数据[ - * [ - * "StartTime" => (integer) 查询发生的时间 - * "SpendTime" => (integer) 查询消耗的时间 - * "Command" => (string) 查询命令 - * ] - * ] - * ] - * - * @return DescribeURedisSlowlogResponse * @throws UCloudException */ public function describeURedisSlowlog(DescribeURedisSlowlogRequest $request = null) @@ -1179,28 +629,13 @@ public function describeURedisSlowlog(DescribeURedisSlowlogRequest $request = nu $resp = $this->invoke($request); return new DescribeURedisSlowlogResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisUpgradePrice - 获取uredis升级价格信息 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "Size" => (integer) 购买uredis大小,单位:GB,范围是[1-32] - * "GroupId" => (string) 要升级的空间的GroupId,请参考DescribeURedisGroup接口 - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 扩容差价,单位: 元,保留小数点后两位有效数字 - * ] - * - * @return DescribeURedisUpgradePriceResponse * @throws UCloudException */ public function describeURedisUpgradePrice(DescribeURedisUpgradePriceRequest $request = null) @@ -1208,32 +643,13 @@ public function describeURedisUpgradePrice(DescribeURedisUpgradePriceRequest $re $resp = $this->invoke($request); return new DescribeURedisUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeURedisVersion - 获取主Redis可用版本 * - * See also: https://docs.ucloud.cn/api/umem-api/describe_uredis_version - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 组列表 参见 URedisVersionSet[ - * [ - * "Version" => (string) Redis版本 - * ] - * ] - * "TotalCount" => (integer) 总版本个数 - * ] - * - * @return DescribeURedisVersionResponse * @throws UCloudException */ public function describeURedisVersion(DescribeURedisVersionRequest $request = null) @@ -1241,32 +657,13 @@ public function describeURedisVersion(DescribeURedisVersionRequest $request = nu $resp = $this->invoke($request); return new DescribeURedisVersionResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * FlushallURedisGroup - 清除主备redis数据 * - * See also: https://docs.ucloud.cn/api/umem-api/flushall_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID - * "FlushType" => (string) FlushDb或FlushAll - * "DbNum" => (integer) 清空的db,FlushType为FlushDb,此项为必传项 - * "TopOrganizationId" => (integer) company_id - * "OrganizationId" => (integer) OrganizationId - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return FlushallURedisGroupResponse * @throws UCloudException */ public function flushallURedisGroup(FlushallURedisGroupRequest $request = null) @@ -1274,28 +671,13 @@ public function flushallURedisGroup(FlushallURedisGroupRequest $request = null) $resp = $this->invoke($request); return new FlushallURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUMemSpaceState - 获取UMem内存空间列表 * - * See also: https://docs.ucloud.cn/api/umem-api/get_umem_space_state - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) 内存空间ID - * ] - * - * Outputs: - * - * $outputs = [ - * "State" => (string) Starting:创建中 Running:运行中 Fail:失败 - * ] - * - * @return GetUMemSpaceStateResponse * @throws UCloudException */ public function getUMemSpaceState(GetUMemSpaceStateRequest $request = null) @@ -1303,29 +685,13 @@ public function getUMemSpaceState(GetUMemSpaceStateRequest $request = null) $resp = $this->invoke($request); return new GetUMemSpaceStateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ISolationURedisGroup - 打开/关闭URedis * - * See also: https://docs.ucloud.cn/api/umem-api/i_solation_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "GroupId" => (string) 组的ID - * "TransformType" => (string) UNBind(关闭)或Bind(打开) - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ISolationURedisGroupResponse * @throws UCloudException */ public function iSolationURedisGroup(ISolationURedisGroupRequest $request = null) @@ -1333,28 +699,13 @@ public function iSolationURedisGroup(ISolationURedisGroupRequest $request = null $resp = $this->invoke($request); return new ISolationURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyUMemSpaceName - 修改UMem内存空间名称 * - * See also: https://docs.ucloud.cn/api/umem-api/modify_umem_space_name - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) UMem内存空间ID - * "Name" => (string) 新的名称,长度(6<=size<=63) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyUMemSpaceNameResponse * @throws UCloudException */ public function modifyUMemSpaceName(ModifyUMemSpaceNameRequest $request = null) @@ -1362,27 +713,13 @@ public function modifyUMemSpaceName(ModifyUMemSpaceNameRequest $request = null) $resp = $this->invoke($request); return new ModifyUMemSpaceNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyURedisGroupName - 修改主备redis名称 * - * See also: https://docs.ucloud.cn/api/umem-api/modify_uredis_group_name - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID - * "Name" => (string) Redis组名称 (范围[6-63],只能包含英文、数字以及符号-和_) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyURedisGroupNameResponse * @throws UCloudException */ public function modifyURedisGroupName(ModifyURedisGroupNameRequest $request = null) @@ -1390,28 +727,13 @@ public function modifyURedisGroupName(ModifyURedisGroupNameRequest $request = nu $resp = $this->invoke($request); return new ModifyURedisGroupNameResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyURedisGroupPassword - 修改主备密码/重置密码 * - * See also: https://docs.ucloud.cn/api/umem-api/modify_uredis_group_password - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID - * "Password" => (string) 新密码字符串,要求长度为6~36个字符,且只能包含英文、数字以及-和下划线;并且需要base64加密;如要取消密码,此值为空字符串, - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyURedisGroupPasswordResponse * @throws UCloudException */ public function modifyURedisGroupPassword(ModifyURedisGroupPasswordRequest $request = null) @@ -1419,27 +741,13 @@ public function modifyURedisGroupPassword(ModifyURedisGroupPasswordRequest $requ $resp = $this->invoke($request); return new ModifyURedisGroupPasswordResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RemoveUDRedisData - 清除udredis实例数据 * - * See also: https://docs.ucloud.cn/api/umem-api/remove_ud_redis_data - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) 实例id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RemoveUDRedisDataResponse * @throws UCloudException */ public function removeUDRedisData(RemoveUDRedisDataRequest $request = null) @@ -1447,29 +755,13 @@ public function removeUDRedisData(RemoveUDRedisDataRequest $request = null) $resp = $this->invoke($request); return new RemoveUDRedisDataResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeUMemSpace - 调整内存空间容量 * - * See also: https://docs.ucloud.cn/api/umem-api/resize_umem_space - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SpaceId" => (string) UMem 内存空间Id - * "Size" => (integer) 内存大小, 单位:GB (需要大于原size,<= 1024) - * "CouponId" => (string) 使用的代金券Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ResizeUMemSpaceResponse * @throws UCloudException */ public function resizeUMemSpace(ResizeUMemSpaceRequest $request = null) @@ -1477,31 +769,13 @@ public function resizeUMemSpace(ResizeUMemSpaceRequest $request = null) $resp = $this->invoke($request); return new ResizeUMemSpaceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeURedisGroup - 通过调用CheckURedisAllowance接口,检查资源情况,根据不同情形来调整主备redis容量,其中主要包括可用区资源不足无法扩容,主备所在宿主机资源不足需要迁移完成扩容(需要主从切换,会闪断及负载升高),以及直接扩容(业务无感知) * - * See also: https://docs.ucloud.cn/api/umem-api/resize_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组ID - * "Size" => (integer) 内存大小, 单位:GB (需要大于原size,且小于等于32) 目前仅支持1/2/4/8/16/32 G 六种容量规格 - * "ChargeType" => (string) - * "Type" => (string) 空间类型:single(无热备),double(热备)(默认: double) - * "CouponId" => (integer) 代金券ID 请参考DescribeCoupon接口 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ResizeURedisGroupResponse * @throws UCloudException */ public function resizeURedisGroup(ResizeURedisGroupRequest $request = null) @@ -1509,27 +783,13 @@ public function resizeURedisGroup(ResizeURedisGroupRequest $request = null) $resp = $this->invoke($request); return new ResizeURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartUMemcacheGroup - 重启单机Memcache * - * See also: https://docs.ucloud.cn/api/umem-api/restart_umem_cache_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartUMemcacheGroupResponse * @throws UCloudException */ public function restartUMemcacheGroup(RestartUMemcacheGroupRequest $request = null) @@ -1537,27 +797,13 @@ public function restartUMemcacheGroup(RestartUMemcacheGroupRequest $request = nu $resp = $this->invoke($request); return new RestartUMemcacheGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RestartURedisGroup - 重启主备实例 * - * See also: https://docs.ucloud.cn/api/umem-api/restart_uredis_group - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return RestartURedisGroupResponse * @throws UCloudException */ public function restartURedisGroup(RestartURedisGroupRequest $request = null) @@ -1565,30 +811,13 @@ public function restartURedisGroup(RestartURedisGroupRequest $request = null) $resp = $this->invoke($request); return new RestartURedisGroupResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateURedisBackupStrategy - URedisBackupStrategy * - * See also: https://docs.ucloud.cn/api/umem-api/update_uredis_backup_strategy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "GroupId" => (string) 组的ID - * "BackupTime" => (string) 备份时间,默认为0 - * "AutoBackup" => (string) 是否打开默认备份功能。enable(打开),disable(关闭),默认enable - * "SlaveZone" => (string) 跨机房URedis,slave所在可用区(必须和Zone在同一Region,且不可相同) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateURedisBackupStrategyResponse * @throws UCloudException */ public function updateURedisBackupStrategy(UpdateURedisBackupStrategyRequest $request = null) diff --git a/src/UNet/Apis/AllocateEIPRequest.php b/src/UNet/Apis/AllocateEIPRequest.php index 1971a196..5d324779 100644 --- a/src/UNet/Apis/AllocateEIPRequest.php +++ b/src/UNet/Apis/AllocateEIPRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 * @@ -65,13 +65,12 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * OperatorName: 弹性IP线路,枚举值:国际线路, International;BGP线路:Bgp。使用BGP线路的地域:北京二、上海金融云、上海二、广州等,其他地域均使用国际线路。 + * OperatorName: 弹性IP线路,枚举值:国际线路, International;BGP线路:Bgp;精品BGP:BGPPro。使用BGP线路的地域:北京二、上海金融云、上海二、广州等,其他地域均使用国际线路。使用BGPPro线路的地域:香港 * * @return string|null */ @@ -81,15 +80,14 @@ public function getOperatorName() } /** - * OperatorName: 弹性IP线路,枚举值:国际线路, International;BGP线路:Bgp。使用BGP线路的地域:北京二、上海金融云、上海二、广州等,其他地域均使用国际线路。 + * OperatorName: 弹性IP线路,枚举值:国际线路, International;BGP线路:Bgp;精品BGP:BGPPro。使用BGP线路的地域:北京二、上海金融云、上海二、广州等,其他地域均使用国际线路。使用BGPPro线路的地域:香港 * * @param string $operatorName */ - public function setOperatorName($operatorName) + public function setOperatorName(string $operatorName) { $this->set("OperatorName", $operatorName); } - /** * Bandwidth: 弹性IP的外网带宽, 单位为Mbps. 共享带宽模式必须指定0M带宽, 非共享带宽模式必须指定非0Mbps带宽. 各地域非共享带宽的带宽范围如下: 流量计费[1-300],带宽计费[1-10000] * @@ -105,11 +103,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * Tag: 业务组名称, 默认为 "Default" * @@ -125,11 +122,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费,默认为按月付费。 * @@ -145,11 +141,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买的时长, 默认: 1 * @@ -165,11 +160,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * PayMode: 弹性IP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; "ShareBandwidth",共享带宽模式. 默认为 "Bandwidth".“PostAccurateBandwidth”:带宽后付费模式 * @@ -185,11 +179,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * ShareBandwidthId: 绑定的共享带宽Id,仅当PayMode为ShareBandwidth时有效 * @@ -205,11 +198,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - /** * Name: 弹性IP的名称, 默认为 "EIP" * @@ -225,11 +217,29 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } + /** + * Count: 购买EIP数量,默认值为1 + * + * @return integer|null + */ + public function getCount() + { + return $this->get("Count"); + } + /** + * Count: 购买EIP数量,默认值为1 + * + * @param int $count + */ + public function setCount(int $count) + { + $this->set("Count", $count); + } /** * Remark: 弹性IP的备注, 默认为空 * @@ -245,11 +255,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * CouponId: 代金券ID, 默认不使用 * @@ -265,7 +274,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UNet/Apis/AllocateEIPResponse.php b/src/UNet/Apis/AllocateEIPResponse.php index f557d96d..e8566873 100644 --- a/src/UNet/Apis/AllocateEIPResponse.php +++ b/src/UNet/Apis/AllocateEIPResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UnetAllocateEIPSet($item)); + array_push($result, new UnetAllocateEIPSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getEIPSet() /** * EIPSet: 申请到的EIP资源详情 参见 UnetAllocateEIPSet * - * @param UnetAllocateEIPSet[] $eipSet + * @param UnetAllocateEIPSetModel[] $eipSet */ public function setEIPSet(array $eipSet) { diff --git a/src/UNet/Apis/AllocateShareBandwidthRequest.php b/src/UNet/Apis/AllocateShareBandwidthRequest.php index 8bb6b200..57a1cb95 100644 --- a/src/UNet/Apis/AllocateShareBandwidthRequest.php +++ b/src/UNet/Apis/AllocateShareBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("ShareBandwidth"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -42,15 +43,14 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: 共享带宽名字 * @@ -86,11 +85,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * ChargeType: 付费方式:Year 按年,Month 按月,Dynamic 按时; * @@ -106,11 +104,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * ShareBandwidth: 共享带宽值 * @@ -126,11 +123,10 @@ public function getShareBandwidth() * * @param int $shareBandwidth */ - public function setShareBandwidth($shareBandwidth) + public function setShareBandwidth(int $shareBandwidth) { $this->set("ShareBandwidth", $shareBandwidth); } - /** * Quantity: 购买时长 * @@ -146,11 +142,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * IPVersion: 共享带宽类型,IPv4或者IPv6,不传默认IPv4 * @@ -166,7 +161,7 @@ public function getIPVersion() * * @param string $ipVersion */ - public function setIPVersion($ipVersion) + public function setIPVersion(string $ipVersion) { $this->set("IPVersion", $ipVersion); } diff --git a/src/UNet/Apis/AllocateShareBandwidthResponse.php b/src/UNet/Apis/AllocateShareBandwidthResponse.php index 50451f9b..4da1e4db 100644 --- a/src/UNet/Apis/AllocateShareBandwidthResponse.php +++ b/src/UNet/Apis/AllocateShareBandwidthResponse.php @@ -1,6 +1,7 @@ set("ShareBandwidthId", $shareBandwidthId); } diff --git a/src/UNet/Apis/AssociateEIPWithShareBandwidthRequest.php b/src/UNet/Apis/AssociateEIPWithShareBandwidthRequest.php index 8fb772fe..1782c0ac 100644 --- a/src/UNet/Apis/AssociateEIPWithShareBandwidthRequest.php +++ b/src/UNet/Apis/AssociateEIPWithShareBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("ShareBandwidthId"); } - /** * Region: 地域。 @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPIds: 要加入共享带宽的EIP的资源Id * @@ -89,7 +88,6 @@ public function setEIPIds(array $eipIds) { $this->set("EIPIds", $eipIds); } - /** * ShareBandwidthId: 共享带宽ID * @@ -105,11 +103,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - /** * IPVersion: 共享带宽类型,IPv4或者IPv6,不传默认IPv4 * @@ -125,7 +122,7 @@ public function getIPVersion() * * @param string $ipVersion */ - public function setIPVersion($ipVersion) + public function setIPVersion(string $ipVersion) { $this->set("IPVersion", $ipVersion); } diff --git a/src/UNet/Apis/AssociateEIPWithShareBandwidthResponse.php b/src/UNet/Apis/AssociateEIPWithShareBandwidthResponse.php index 97040007..c15eb957 100644 --- a/src/UNet/Apis/AssociateEIPWithShareBandwidthResponse.php +++ b/src/UNet/Apis/AssociateEIPWithShareBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * Region: 地域 @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写 * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源Id * @@ -86,11 +85,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * ResourceType: 弹性IP请求绑定的资源类型, 枚举值为: uhost: 云主机; ulb, 负载均衡器 upm: 物理机; hadoophost: 大数据集群;fortresshost:堡垒机;udockhost:容器;udhost:私有专区主机;natgw:natgw;udb:udb;vpngw:ipsec vpn;ucdr:云灾备;dbaudit:数据库审计;uni:虚拟网卡;cube,Cube容器。如果EIP为普通带宽计费,且带宽值高于2G,则只允许绑定在快杰型云主机和ULB * @@ -106,11 +104,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 弹性IP请求绑定的资源ID * @@ -126,7 +123,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UNet/Apis/BindEIPResponse.php b/src/UNet/Apis/BindEIPResponse.php index 7e42cd42..bda78891 100644 --- a/src/UNet/Apis/BindEIPResponse.php +++ b/src/UNet/Apis/BindEIPResponse.php @@ -1,6 +1,7 @@ markRequired("TimeRange"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Bandwidth: 带宽大小(单位Mbps), 取值范围[2,800] (最大值受地域限制) * @@ -66,11 +66,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * EIPId: 所绑定弹性IP的资源ID * @@ -86,11 +85,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * TimeRange: 带宽包有效时长, 取值范围为大于0的整数, 即该带宽包在EnableTime到 EnableTime+TimeRange时间段内生效 * @@ -106,11 +104,10 @@ public function getTimeRange() * * @param int $timeRange */ - public function setTimeRange($timeRange) + public function setTimeRange(int $timeRange) { $this->set("TimeRange", $timeRange); } - /** * EnableTime: 生效时间, 格式为 Unix timestamp, 默认为立即开通 * @@ -126,11 +123,10 @@ public function getEnableTime() * * @param int $enableTime */ - public function setEnableTime($enableTime) + public function setEnableTime(int $enableTime) { $this->set("EnableTime", $enableTime); } - /** * CouponId: 代金券ID * @@ -146,7 +142,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UNet/Apis/CreateBandwidthPackageResponse.php b/src/UNet/Apis/CreateBandwidthPackageResponse.php index 9b5a3123..25a19434 100644 --- a/src/UNet/Apis/CreateBandwidthPackageResponse.php +++ b/src/UNet/Apis/CreateBandwidthPackageResponse.php @@ -1,6 +1,7 @@ set("BandwidthPackageId", $bandwidthPackageId); } diff --git a/src/UNet/Apis/CreateFirewallRequest.php b/src/UNet/Apis/CreateFirewallRequest.php index bfbf4505..0fba4218 100644 --- a/src/UNet/Apis/CreateFirewallRequest.php +++ b/src/UNet/Apis/CreateFirewallRequest.php @@ -1,6 +1,7 @@ markRequired("Name"); } - /** * Region: 地域 @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写 * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Rule: 防火墙规则,例如:TCP|22|192.168.1.1/22|DROP|LOW|禁用22端口,第一个参数代表协议:第二个参数代表端口号,第三个参数为ip,第四个参数为ACCEPT(接受)和DROP(拒绝),第五个参数优先级:HIGH(高),MEDIUM(中),LOW(低),第六个参数为该条规则的自定义备注,bj1不支持添加备注 * @@ -89,7 +88,6 @@ public function setRule(array $rule) { $this->set("Rule", $rule); } - /** * Name: 防火墙名称 * @@ -105,11 +103,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 防火墙业务组,默认为Default * @@ -125,11 +122,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 防火墙描述,默认为空 * @@ -145,7 +141,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UNet/Apis/CreateFirewallResponse.php b/src/UNet/Apis/CreateFirewallResponse.php index d4efad02..8575f7f5 100644 --- a/src/UNet/Apis/CreateFirewallResponse.php +++ b/src/UNet/Apis/CreateFirewallResponse.php @@ -1,6 +1,7 @@ set("FWId", $fwId); } diff --git a/src/UNet/Apis/DeleteBandwidthPackageRequest.php b/src/UNet/Apis/DeleteBandwidthPackageRequest.php index 27691cfd..5ab485ab 100644 --- a/src/UNet/Apis/DeleteBandwidthPackageRequest.php +++ b/src/UNet/Apis/DeleteBandwidthPackageRequest.php @@ -1,6 +1,7 @@ markRequired("BandwidthPackageId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * BandwidthPackageId: 带宽包资源ID * @@ -84,7 +83,7 @@ public function getBandwidthPackageId() * * @param string $bandwidthPackageId */ - public function setBandwidthPackageId($bandwidthPackageId) + public function setBandwidthPackageId(string $bandwidthPackageId) { $this->set("BandwidthPackageId", $bandwidthPackageId); } diff --git a/src/UNet/Apis/DeleteBandwidthPackageResponse.php b/src/UNet/Apis/DeleteBandwidthPackageResponse.php index 5f98729c..9ca3ccc9 100644 --- a/src/UNet/Apis/DeleteBandwidthPackageResponse.php +++ b/src/UNet/Apis/DeleteBandwidthPackageResponse.php @@ -1,6 +1,7 @@ markRequired("FWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙资源ID * @@ -84,7 +83,7 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } diff --git a/src/UNet/Apis/DeleteFirewallResponse.php b/src/UNet/Apis/DeleteFirewallResponse.php index 839c890e..dd37ffcc 100644 --- a/src/UNet/Apis/DeleteFirewallResponse.php +++ b/src/UNet/Apis/DeleteFirewallResponse.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Limit: 返回数据分页值, 取值范围为 [0,10000000] 之间的整数, 默认为20 * @@ -83,11 +82,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 返回数据偏移量, 默认为0 * @@ -103,7 +101,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UNet/Apis/DescribeBandwidthPackageResponse.php b/src/UNet/Apis/DescribeBandwidthPackageResponse.php index 9a089219..ba1e71a8 100644 --- a/src/UNet/Apis/DescribeBandwidthPackageResponse.php +++ b/src/UNet/Apis/DescribeBandwidthPackageResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSets: 带宽包详细信息, 参见 UnetBandwidthPackageSet * - * @return UnetBandwidthPackageSet[]|null + * @return UnetBandwidthPackageSetModel[]|null */ public function getDataSets() { @@ -57,7 +58,7 @@ public function getDataSets() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UnetBandwidthPackageSet($item)); + array_push($result, new UnetBandwidthPackageSetModel($item)); } return $result; } @@ -65,7 +66,7 @@ public function getDataSets() /** * DataSets: 带宽包详细信息, 参见 UnetBandwidthPackageSet * - * @param UnetBandwidthPackageSet[] $dataSets + * @param UnetBandwidthPackageSetModel[] $dataSets */ public function setDataSets(array $dataSets) { diff --git a/src/UNet/Apis/DescribeBandwidthUsageRequest.php b/src/UNet/Apis/DescribeBandwidthUsageRequest.php index 4ef37527..7cba9ba3 100644 --- a/src/UNet/Apis/DescribeBandwidthUsageRequest.php +++ b/src/UNet/Apis/DescribeBandwidthUsageRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Limit: 返回数据分页值, 取值范围为 [0,10000000] 之间的整数, 默认为20 * @@ -83,11 +82,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * OffSet: 返回数据偏移量, 默认为0 * @@ -103,11 +101,10 @@ public function getOffSet() * * @param int $offSet */ - public function setOffSet($offSet) + public function setOffSet(int $offSet) { $this->set("OffSet", $offSet); } - /** * EIPIds: 弹性IP的资源Id. 如果为空, 则返回当前 Region中符合条件的所有EIP的带宽用量, n为自然数 * diff --git a/src/UNet/Apis/DescribeBandwidthUsageResponse.php b/src/UNet/Apis/DescribeBandwidthUsageResponse.php index baac6780..479abc37 100644 --- a/src/UNet/Apis/DescribeBandwidthUsageResponse.php +++ b/src/UNet/Apis/DescribeBandwidthUsageResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * EIPSet: 单个弹性IP的带宽用量详细信息, 详见 UnetBandwidthUsageEIPSet, 如没有弹性IP资源则没有该返回值。 * - * @return UnetBandwidthUsageEIPSet[]|null + * @return UnetBandwidthUsageEIPSetModel[]|null */ public function getEIPSet() { @@ -56,7 +57,7 @@ public function getEIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UnetBandwidthUsageEIPSet($item)); + array_push($result, new UnetBandwidthUsageEIPSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getEIPSet() /** * EIPSet: 单个弹性IP的带宽用量详细信息, 详见 UnetBandwidthUsageEIPSet, 如没有弹性IP资源则没有该返回值。 * - * @param UnetBandwidthUsageEIPSet[] $eipSet + * @param UnetBandwidthUsageEIPSetModel[] $eipSet */ public function setEIPSet(array $eipSet) { diff --git a/src/UNet/Apis/DescribeEIPRequest.php b/src/UNet/Apis/DescribeEIPRequest.php index 087f11a8..0a1840be 100644 --- a/src/UNet/Apis/DescribeEIPRequest.php +++ b/src/UNet/Apis/DescribeEIPRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域 @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写 * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPIds: 弹性IP的资源ID如果为空, 则返回当前 Region中符合条件的的所有EIP * @@ -87,7 +86,6 @@ public function setEIPIds(array $eipIds) { $this->set("EIPIds", $eipIds); } - /** * Offset: 数据偏移量, 默认为0 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -123,11 +120,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * IPs: IP地址,支持通过ip查询,如果ip与EIP都传,会取并集查询 * diff --git a/src/UNet/Apis/DescribeEIPResponse.php b/src/UNet/Apis/DescribeEIPResponse.php index 921c473a..e0dac792 100644 --- a/src/UNet/Apis/DescribeEIPResponse.php +++ b/src/UNet/Apis/DescribeEIPResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * UnbindCount: 未绑定的弹性IP总数 * @@ -61,11 +62,10 @@ public function getUnbindCount() * * @param int $unbindCount */ - public function setUnbindCount($unbindCount) + public function setUnbindCount(int $unbindCount) { $this->set("UnbindCount", $unbindCount); } - /** * TotalBandwidth: 满足条件的弹性IP带宽总和, 单位Mbps * @@ -81,15 +81,14 @@ public function getTotalBandwidth() * * @param int $totalBandwidth */ - public function setTotalBandwidth($totalBandwidth) + public function setTotalBandwidth(int $totalBandwidth) { $this->set("TotalBandwidth", $totalBandwidth); } - /** * EIPSet: 弹性IP列表, 每项参数详见 UnetEIPSet * - * @return UnetEIPSet[]|null + * @return UnetEIPSetModel[]|null */ public function getEIPSet() { @@ -99,7 +98,7 @@ public function getEIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UnetEIPSet($item)); + array_push($result, new UnetEIPSetModel($item)); } return $result; } @@ -107,7 +106,7 @@ public function getEIPSet() /** * EIPSet: 弹性IP列表, 每项参数详见 UnetEIPSet * - * @param UnetEIPSet[] $eipSet + * @param UnetEIPSetModel[] $eipSet */ public function setEIPSet(array $eipSet) { diff --git a/src/UNet/Apis/DescribeFirewallRequest.php b/src/UNet/Apis/DescribeFirewallRequest.php index 9adb5d53..b845614d 100644 --- a/src/UNet/Apis/DescribeFirewallRequest.php +++ b/src/UNet/Apis/DescribeFirewallRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域 @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写 * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙ID,默认为返回所有防火墙 * @@ -83,11 +82,10 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** * ResourceType: 绑定防火墙组的资源类型,默认为全部资源类型。枚举值为:"unatgw",NAT网关; "uhost",云主机;“uni”,虚拟网卡; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计. * @@ -103,11 +101,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 绑定防火墙组的资源ID * @@ -123,11 +120,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * Limit: 返回数据长度,默认为20,最大10000000 * @@ -143,11 +139,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -163,7 +158,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UNet/Apis/DescribeFirewallResourceRequest.php b/src/UNet/Apis/DescribeFirewallResourceRequest.php index d59256a9..25748413 100644 --- a/src/UNet/Apis/DescribeFirewallResourceRequest.php +++ b/src/UNet/Apis/DescribeFirewallResourceRequest.php @@ -1,6 +1,7 @@ markRequired("FWId"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -40,17 +41,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -60,15 +60,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙ID * @@ -84,13 +83,12 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** - * Limit: 返回数据长度,默认为20,最大10000000 + * Limit: 返回数据长度,默认为20,最大1000 * * @return integer|null */ @@ -100,15 +98,14 @@ public function getLimit() } /** - * Limit: 返回数据长度,默认为20,最大10000000 + * Limit: 返回数据长度,默认为20,最大1000 * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -124,7 +121,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/UNet/Apis/DescribeFirewallResourceResponse.php b/src/UNet/Apis/DescribeFirewallResourceResponse.php index 0ca9665e..688491b6 100644 --- a/src/UNet/Apis/DescribeFirewallResourceResponse.php +++ b/src/UNet/Apis/DescribeFirewallResourceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ResourceSet($item)); + array_push($result, new ResourceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getResourceSet() /** * ResourceSet: 资源列表,见 ResourceSet * - * @param ResourceSet[] $resourceSet + * @param ResourceSetModel[] $resourceSet */ public function setResourceSet(array $resourceSet) { @@ -54,7 +56,6 @@ public function setResourceSet(array $resourceSet) } return $result; } - /** * TotalCount: 绑定资源总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UNet/Apis/DescribeFirewallResponse.php b/src/UNet/Apis/DescribeFirewallResponse.php index 2eac5d48..eae18e73 100644 --- a/src/UNet/Apis/DescribeFirewallResponse.php +++ b/src/UNet/Apis/DescribeFirewallResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new FirewallDataSet($item)); + array_push($result, new FirewallDataSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: 获取的防火墙组详细信息 参见 FirewallDataSet * - * @param FirewallDataSet[] $dataSet + * @param FirewallDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -55,7 +57,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 防火墙资源数量 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UNet/Apis/DescribeShareBandwidthPriceRequest.php b/src/UNet/Apis/DescribeShareBandwidthPriceRequest.php new file mode 100644 index 00000000..b6eb72a3 --- /dev/null +++ b/src/UNet/Apis/DescribeShareBandwidthPriceRequest.php @@ -0,0 +1,148 @@ + "DescribeShareBandwidthPrice"]); + $this->markRequired("Region"); + $this->markRequired("ChargeType"); + $this->markRequired("ShareBandwidth"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * ChargeType: 付费方式, 预付费:Year 按年,Month 按月,Dynamic 按需; + * + * @return string|null + */ + public function getChargeType() + { + return $this->get("ChargeType"); + } + + /** + * ChargeType: 付费方式, 预付费:Year 按年,Month 按月,Dynamic 按需; + * + * @param string $chargeType + */ + public function setChargeType(string $chargeType) + { + $this->set("ChargeType", $chargeType); + } + /** + * ShareBandwidth: 共享带宽值 + * + * @return integer|null + */ + public function getShareBandwidth() + { + return $this->get("ShareBandwidth"); + } + + /** + * ShareBandwidth: 共享带宽值 + * + * @param int $shareBandwidth + */ + public function setShareBandwidth(int $shareBandwidth) + { + $this->set("ShareBandwidth", $shareBandwidth); + } + /** + * Quantity: 购买数量 + * + * @return integer|null + */ + public function getQuantity() + { + return $this->get("Quantity"); + } + + /** + * Quantity: 购买数量 + * + * @param int $quantity + */ + public function setQuantity(int $quantity) + { + $this->set("Quantity", $quantity); + } + /** + * OperatorName: 香港地域支持:BGPPro和International。其他地域无需填写该字段 + * + * @return string|null + */ + public function getOperatorName() + { + return $this->get("OperatorName"); + } + + /** + * OperatorName: 香港地域支持:BGPPro和International。其他地域无需填写该字段 + * + * @param string $operatorName + */ + public function setOperatorName(string $operatorName) + { + $this->set("OperatorName", $operatorName); + } +} diff --git a/src/UNet/Apis/DescribeShareBandwidthPriceResponse.php b/src/UNet/Apis/DescribeShareBandwidthPriceResponse.php new file mode 100644 index 00000000..12650f12 --- /dev/null +++ b/src/UNet/Apis/DescribeShareBandwidthPriceResponse.php @@ -0,0 +1,45 @@ +get("TotalPrice"); + } + + /** + * TotalPrice: 共享带宽总价格 + * + * @param int $totalPrice + */ + public function setTotalPrice(int $totalPrice) + { + $this->set("TotalPrice", $totalPrice); + } +} diff --git a/src/UNet/Apis/DescribeShareBandwidthRequest.php b/src/UNet/Apis/DescribeShareBandwidthRequest.php index 45087cd6..3858ce6f 100644 --- a/src/UNet/Apis/DescribeShareBandwidthRequest.php +++ b/src/UNet/Apis/DescribeShareBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ShareBandwidthIds: 需要返回的共享带宽Id * diff --git a/src/UNet/Apis/DescribeShareBandwidthResponse.php b/src/UNet/Apis/DescribeShareBandwidthResponse.php index cdd1aa37..ce1fa1e1 100644 --- a/src/UNet/Apis/DescribeShareBandwidthResponse.php +++ b/src/UNet/Apis/DescribeShareBandwidthResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new UnetShareBandwidthSet($item)); + array_push($result, new UnetShareBandwidthSetModel($item)); } return $result; } @@ -46,7 +48,7 @@ public function getDataSet() /** * DataSet: 共享带宽信息组 参见 UnetShareBandwidthSet * - * @param UnetShareBandwidthSet[] $dataSet + * @param UnetShareBandwidthSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -56,7 +58,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 符合条件的共享带宽总数,大于等于返回DataSet长度 * @@ -72,7 +73,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UNet/Apis/DescribeShareBandwidthUpdatePriceRequest.php b/src/UNet/Apis/DescribeShareBandwidthUpdatePriceRequest.php new file mode 100644 index 00000000..bb82cce2 --- /dev/null +++ b/src/UNet/Apis/DescribeShareBandwidthUpdatePriceRequest.php @@ -0,0 +1,91 @@ + "DescribeShareBandwidthUpdatePrice"]); + $this->markRequired("Region"); + $this->markRequired("ShareBandwidthId"); + $this->markRequired("ShareBandwidth"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ShareBandwidthId: 共享带宽Id + * + * @return string|null + */ + public function getShareBandwidthId() + { + return $this->get("ShareBandwidthId"); + } + + /** + * ShareBandwidthId: 共享带宽Id + * + * @param string $shareBandwidthId + */ + public function setShareBandwidthId(string $shareBandwidthId) + { + $this->set("ShareBandwidthId", $shareBandwidthId); + } + /** + * ShareBandwidth: 共享带宽值 + * + * @return integer|null + */ + public function getShareBandwidth() + { + return $this->get("ShareBandwidth"); + } + + /** + * ShareBandwidth: 共享带宽值 + * + * @param int $shareBandwidth + */ + public function setShareBandwidth(int $shareBandwidth) + { + $this->set("ShareBandwidth", $shareBandwidth); + } +} diff --git a/src/UNet/Apis/DescribeShareBandwidthUpdatePriceResponse.php b/src/UNet/Apis/DescribeShareBandwidthUpdatePriceResponse.php new file mode 100644 index 00000000..5cb0330f --- /dev/null +++ b/src/UNet/Apis/DescribeShareBandwidthUpdatePriceResponse.php @@ -0,0 +1,45 @@ +get("Price"); + } + + /** + * Price: 共享带宽升降级价格 + * + * @param float $price + */ + public function setPrice(float $price) + { + $this->set("Price", $price); + } +} diff --git a/src/UNet/Apis/DisassociateEIPWithShareBandwidthRequest.php b/src/UNet/Apis/DisassociateEIPWithShareBandwidthRequest.php index 29a9aa08..f1f3a558 100644 --- a/src/UNet/Apis/DisassociateEIPWithShareBandwidthRequest.php +++ b/src/UNet/Apis/DisassociateEIPWithShareBandwidthRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ShareBandwidthId: 共享带宽ID * @@ -85,11 +84,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - /** * Bandwidth: 移出共享带宽后,EIP的外网带宽, 单位为Mbps. 各地域带宽范围如下: 流量计费[1-200],带宽计费[1-800] * @@ -105,11 +103,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * EIPIds: EIP的资源Id;默认移出该共享带宽下所有的EIP * @@ -129,7 +126,6 @@ public function setEIPIds(array $eipIds) { $this->set("EIPIds", $eipIds); } - /** * PayMode: 移出共享带宽后,EIP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; 默认为 "Bandwidth". * @@ -145,11 +141,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * IPVersion: 共享带宽类型,IPv4或者IPv6,不传默认IPv4 * @@ -165,7 +160,7 @@ public function getIPVersion() * * @param string $ipVersion */ - public function setIPVersion($ipVersion) + public function setIPVersion(string $ipVersion) { $this->set("IPVersion", $ipVersion); } diff --git a/src/UNet/Apis/DisassociateEIPWithShareBandwidthResponse.php b/src/UNet/Apis/DisassociateEIPWithShareBandwidthResponse.php index 2769854d..4550f6c5 100644 --- a/src/UNet/Apis/DisassociateEIPWithShareBandwidthResponse.php +++ b/src/UNet/Apis/DisassociateEIPWithShareBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceType"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙ID * @@ -86,11 +85,10 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** * ResourceId: 需要解绑的资源ID * @@ -106,11 +104,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceType: 资源类型:ULB 表示负载均衡 * @@ -126,7 +123,7 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } diff --git a/src/UNet/Apis/DisassociateFirewallResponse.php b/src/UNet/Apis/DisassociateFirewallResponse.php index 9b9db2eb..3b97e345 100644 --- a/src/UNet/Apis/DisassociateFirewallResponse.php +++ b/src/UNet/Apis/DisassociateFirewallResponse.php @@ -1,6 +1,7 @@ markRequired("EIPId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源Id * diff --git a/src/UNet/Apis/GetEIPPayModeResponse.php b/src/UNet/Apis/GetEIPPayModeResponse.php index 6ceaccc7..d790a6b5 100644 --- a/src/UNet/Apis/GetEIPPayModeResponse.php +++ b/src/UNet/Apis/GetEIPPayModeResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new EIPPayModeSet($item)); + array_push($result, new EIPPayModeSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getEIPPayMode() /** * EIPPayMode: EIP的计费模式, 参见 EIPPayModeSet * - * @param EIPPayModeSet[] $eipPayMode + * @param EIPPayModeSetModel[] $eipPayMode */ public function setEIPPayMode(array $eipPayMode) { diff --git a/src/UNet/Apis/GetEIPPriceRequest.php b/src/UNet/Apis/GetEIPPriceRequest.php index 768b374b..e177e199 100644 --- a/src/UNet/Apis/GetEIPPriceRequest.php +++ b/src/UNet/Apis/GetEIPPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * OperatorName: 弹性IP的线路如下: 国际: International BGP: Bgp 各地域允许的线路参数如下: cn-sh1: Bgp cn-sh2: Bgp cn-gd: Bgp cn-bj1: Bgp cn-bj2: Bgp hk: International us-ca: International th-bkk: International kr-seoul:International us-ws:International ge-fra:International sg:International tw-kh:International.其他海外线路均为 International,泉州为移动单线cn-qz:ChinaMobile * @@ -85,11 +84,10 @@ public function getOperatorName() * * @param string $operatorName */ - public function setOperatorName($operatorName) + public function setOperatorName(string $operatorName) { $this->set("OperatorName", $operatorName); } - /** * Bandwidth: 弹性IP的外网带宽, 单位为Mbps, 范围 [0-800] * @@ -105,11 +103,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费; 默认为获取三种价格 * @@ -125,11 +122,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * PayMode: 弹性IP计费方式r. 枚举值为: Traffic, 流量计费; Bandwidth, 带宽计费; "ShareBandwidth",共享带宽模式. 默认为Bandwidth * @@ -145,11 +141,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * Quantity: 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末 * @@ -165,7 +160,7 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } diff --git a/src/UNet/Apis/GetEIPPriceResponse.php b/src/UNet/Apis/GetEIPPriceResponse.php index d49164b3..3fb10b67 100644 --- a/src/UNet/Apis/GetEIPPriceResponse.php +++ b/src/UNet/Apis/GetEIPPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new EIPPriceDetailSet($item)); + array_push($result, new EIPPriceDetailSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getPriceSet() /** * PriceSet: 弹性IP价格详情 详情见 EIPPriceDetailSet * - * @param EIPPriceDetailSet[] $priceSet + * @param EIPPriceDetailSetModel[] $priceSet */ public function setPriceSet(array $priceSet) { diff --git a/src/UNet/Apis/GetEIPUpgradePriceRequest.php b/src/UNet/Apis/GetEIPUpgradePriceRequest.php index 0a4c1bd8..bdaf3fcb 100644 --- a/src/UNet/Apis/GetEIPUpgradePriceRequest.php +++ b/src/UNet/Apis/GetEIPUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源ID * @@ -85,11 +84,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * Bandwidth: 弹性IP的外网带宽, 单位为Mbps, 范围 [1-800] * @@ -105,7 +103,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UNet/Apis/GetEIPUpgradePriceResponse.php b/src/UNet/Apis/GetEIPUpgradePriceResponse.php index bdf756d7..03022e68 100644 --- a/src/UNet/Apis/GetEIPUpgradePriceResponse.php +++ b/src/UNet/Apis/GetEIPUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } diff --git a/src/UNet/Apis/GetThroughputDailyBillingInfoRequest.php b/src/UNet/Apis/GetThroughputDailyBillingInfoRequest.php index 40066d3c..0e162e19 100644 --- a/src/UNet/Apis/GetThroughputDailyBillingInfoRequest.php +++ b/src/UNet/Apis/GetThroughputDailyBillingInfoRequest.php @@ -1,6 +1,7 @@ markRequired("EndTime"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: EIP的资源ID * @@ -86,11 +85,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * StartTime: 查询开始时间时间戳 * @@ -106,11 +104,10 @@ public function getStartTime() * * @param int $startTime */ - public function setStartTime($startTime) + public function setStartTime(int $startTime) { $this->set("StartTime", $startTime); } - /** * EndTime: 查询结束时间时间戳 * @@ -126,7 +123,7 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } diff --git a/src/UNet/Apis/GetThroughputDailyBillingInfoResponse.php b/src/UNet/Apis/GetThroughputDailyBillingInfoResponse.php index 505a96a1..8cee5782 100644 --- a/src/UNet/Apis/GetThroughputDailyBillingInfoResponse.php +++ b/src/UNet/Apis/GetThroughputDailyBillingInfoResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ThroughputDailyBillingInfo($item)); + array_push($result, new ThroughputDailyBillingInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getStats() /** * Stats: EIP流量计费信息,详见模型ThroughputDailyBillingInfo * - * @param ThroughputDailyBillingInfo[] $stats + * @param ThroughputDailyBillingInfoModel[] $stats */ public function setStats(array $stats) { @@ -54,7 +56,6 @@ public function setStats(array $stats) } return $result; } - /** * TotalOut: 计费总流量 * @@ -70,11 +71,10 @@ public function getTotalOut() * * @param int $totalOut */ - public function setTotalOut($totalOut) + public function setTotalOut(int $totalOut) { $this->set("TotalOut", $totalOut); } - /** * EIPId: 资源ID * @@ -90,7 +90,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/UNet/Apis/GrantFirewallRequest.php b/src/UNet/Apis/GrantFirewallRequest.php index 918d281d..6051e4b5 100644 --- a/src/UNet/Apis/GrantFirewallRequest.php +++ b/src/UNet/Apis/GrantFirewallRequest.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙资源ID * @@ -86,11 +85,10 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** * ResourceType: 绑定防火墙组的资源类型,默认为全部资源类型。枚举值为:"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计,”uni“,虚拟网卡,“cube”,Cube容器实例。 * @@ -106,11 +104,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 所应用资源ID * @@ -126,7 +123,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UNet/Apis/GrantFirewallResponse.php b/src/UNet/Apis/GrantFirewallResponse.php index 49014a5c..2c5bc844 100644 --- a/src/UNet/Apis/GrantFirewallResponse.php +++ b/src/UNet/Apis/GrantFirewallResponse.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源ID * @@ -85,11 +84,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * Bandwidth: 弹性IP的外网带宽, 单位为Mbps. 各地域的带宽值范围如下:流量计费[1-200],带宽计费[1-800] * @@ -105,7 +103,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UNet/Apis/ModifyEIPBandwidthResponse.php b/src/UNet/Apis/ModifyEIPBandwidthResponse.php index 3971c2de..b944fc88 100644 --- a/src/UNet/Apis/ModifyEIPBandwidthResponse.php +++ b/src/UNet/Apis/ModifyEIPBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("Weight"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源ID * @@ -85,11 +84,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * Weight: 外网出口权重, 范围[0-100] 取值为0时, 该弹性IP不会被使用. 取值为100时, 同主机下只会使用这个弹性IP,其他弹性IP不会被使用 请勿将多个绑定在同一资源的弹性IP设置为相同权重 * @@ -105,7 +103,7 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } diff --git a/src/UNet/Apis/ModifyEIPWeightResponse.php b/src/UNet/Apis/ModifyEIPWeightResponse.php index f9896c88..5a17130a 100644 --- a/src/UNet/Apis/ModifyEIPWeightResponse.php +++ b/src/UNet/Apis/ModifyEIPWeightResponse.php @@ -1,6 +1,7 @@ markRequired("EIPId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源ID * @@ -84,7 +83,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/UNet/Apis/ReleaseEIPResponse.php b/src/UNet/Apis/ReleaseEIPResponse.php index c10c6fcf..6008dd85 100644 --- a/src/UNet/Apis/ReleaseEIPResponse.php +++ b/src/UNet/Apis/ReleaseEIPResponse.php @@ -1,6 +1,7 @@ markRequired("EIPBandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ShareBandwidthId: 共享带宽ID * @@ -85,11 +84,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - /** * EIPBandwidth: 关闭共享带宽后,各EIP恢复为的带宽值 * @@ -105,11 +103,10 @@ public function getEIPBandwidth() * * @param int $eipBandwidth */ - public function setEIPBandwidth($eipBandwidth) + public function setEIPBandwidth(int $eipBandwidth) { $this->set("EIPBandwidth", $eipBandwidth); } - /** * PayMode: 默认为 Bandwidth 带宽计费 * @@ -125,7 +122,7 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } diff --git a/src/UNet/Apis/ReleaseShareBandwidthResponse.php b/src/UNet/Apis/ReleaseShareBandwidthResponse.php index c7e2b1b0..15da8c0a 100644 --- a/src/UNet/Apis/ReleaseShareBandwidthResponse.php +++ b/src/UNet/Apis/ReleaseShareBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("ShareBandwidthId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ShareBandwidth: 带宽值,单位为Mb,范围 [20-5000] (最大值受地域限制) * @@ -85,11 +84,10 @@ public function getShareBandwidth() * * @param int $shareBandwidth */ - public function setShareBandwidth($shareBandwidth) + public function setShareBandwidth(int $shareBandwidth) { $this->set("ShareBandwidth", $shareBandwidth); } - /** * ShareBandwidthId: 共享带宽的Id * @@ -105,7 +103,7 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } diff --git a/src/UNet/Apis/ResizeShareBandwidthResponse.php b/src/UNet/Apis/ResizeShareBandwidthResponse.php index 2b34b1ca..7af29577 100644 --- a/src/UNet/Apis/ResizeShareBandwidthResponse.php +++ b/src/UNet/Apis/ResizeShareBandwidthResponse.php @@ -1,6 +1,7 @@ markRequired("Bandwidth"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源Id * @@ -86,11 +85,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * PayMode: 计费模式. 枚举值:"Traffic", 流量计费模式; "Bandwidth", 带宽计费模式 * @@ -106,11 +104,10 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * Bandwidth: 调整的目标带宽值, 单位Mbps. 各地域的带宽值范围如下: 流量计费[1-200],其余情况[1-800] * @@ -126,7 +123,7 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } diff --git a/src/UNet/Apis/SetEIPPayModeResponse.php b/src/UNet/Apis/SetEIPPayModeResponse.php index bfdd651c..9cbe0831 100644 --- a/src/UNet/Apis/SetEIPPayModeResponse.php +++ b/src/UNet/Apis/SetEIPPayModeResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: 弹性IP的资源Id * @@ -86,11 +85,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * ResourceType: 弹性IP请求解绑的资源类型, 枚举值为: uhost: 云主机; ulb, 负载均衡器 upm: 物理机; hadoophost: 大数据集群;fortresshost:堡垒机;udockhost:容器;udhost:私有专区主机;natgw:NAT网关;udb:udb;vpngw:ipsec vpn;ucdr:云灾备;dbaudit:数据库审计; * @@ -106,11 +104,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * ResourceId: 弹性IP请求解绑的资源ID * @@ -126,7 +123,7 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } diff --git a/src/UNet/Apis/UnBindEIPResponse.php b/src/UNet/Apis/UnBindEIPResponse.php index 82fb4507..10927f23 100644 --- a/src/UNet/Apis/UnBindEIPResponse.php +++ b/src/UNet/Apis/UnBindEIPResponse.php @@ -1,6 +1,7 @@ markRequired("EIPId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * EIPId: EIP资源ID * @@ -84,11 +83,10 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * Name: 名字(Name Tag Remark都为空则报错) * @@ -104,11 +102,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务 * @@ -124,11 +121,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -144,7 +140,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UNet/Apis/UpdateEIPAttributeResponse.php b/src/UNet/Apis/UpdateEIPAttributeResponse.php index 669a4988..c11a5eba 100644 --- a/src/UNet/Apis/UpdateEIPAttributeResponse.php +++ b/src/UNet/Apis/UpdateEIPAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("FWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙资源ID * @@ -84,11 +83,10 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** * Name: 防火墙名称,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 * @@ -104,11 +102,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 防火墙业务组,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 * @@ -124,11 +121,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 防火墙备注,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 * @@ -144,7 +140,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UNet/Apis/UpdateFirewallAttributeResponse.php b/src/UNet/Apis/UpdateFirewallAttributeResponse.php index f9db38c5..aa9fdc89 100644 --- a/src/UNet/Apis/UpdateFirewallAttributeResponse.php +++ b/src/UNet/Apis/UpdateFirewallAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("Rule"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * FWId: 防火墙资源ID * @@ -85,11 +84,10 @@ public function getFWId() * * @param string $fwId */ - public function setFWId($fwId) + public function setFWId(string $fwId) { $this->set("FWId", $fwId); } - /** * Rule: 防火墙规则,例如:TCP|22|192.168.1.1/22|DROP|LOW|禁用22端口,第一个参数代表协议:第二个参数代表端口号,第三个参数为ip,第四个参数为ACCEPT(接受)和DROP(拒绝),第五个参数优先级:HIGH(高),MEDIUM(中),LOW(低),第六个参数为该条规则的自定义备注 * diff --git a/src/UNet/Apis/UpdateFirewallResponse.php b/src/UNet/Apis/UpdateFirewallResponse.php index 71a77a18..06be3b00 100644 --- a/src/UNet/Apis/UpdateFirewallResponse.php +++ b/src/UNet/Apis/UpdateFirewallResponse.php @@ -1,6 +1,7 @@ set("FWId", $fwId); } diff --git a/src/UNet/Models/EIPAddrSet.php b/src/UNet/Models/EIPAddrSet.php index 0f9b6508..16eee715 100644 --- a/src/UNet/Models/EIPAddrSet.php +++ b/src/UNet/Models/EIPAddrSet.php @@ -1,6 +1,7 @@ set("OperatorName", $operatorName); } - /** * IP: 弹性IP地址 * @@ -57,7 +65,7 @@ public function getIP() * * @param string $ip */ - public function setIP($ip) + public function setIP(string $ip) { $this->set("IP", $ip); } diff --git a/src/UNet/Models/EIPPayModeSet.php b/src/UNet/Models/EIPPayModeSet.php index 2de8a886..59334740 100644 --- a/src/UNet/Models/EIPPayModeSet.php +++ b/src/UNet/Models/EIPPayModeSet.php @@ -1,6 +1,7 @@ set("EIPId", $eipId); } - /** * EIPPayMode: EIP的计费模式. 枚举值为:Bandwidth, 带宽计费;Traffic, 流量计费; "ShareBandwidth",共享带宽模式 * @@ -57,7 +59,7 @@ public function getEIPPayMode() * * @param string $eipPayMode */ - public function setEIPPayMode($eipPayMode) + public function setEIPPayMode(string $eipPayMode) { $this->set("EIPPayMode", $eipPayMode); } diff --git a/src/UNet/Models/EIPPriceDetailSet.php b/src/UNet/Models/EIPPriceDetailSet.php index 975d5d5e..ac8001aa 100644 --- a/src/UNet/Models/EIPPriceDetailSet.php +++ b/src/UNet/Models/EIPPriceDetailSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 购买弹性IP的实际价格, 单位"元" * @@ -57,11 +59,10 @@ public function getPrice() * * @param float $price */ - public function setPrice($price) + public function setPrice(float $price) { $this->set("Price", $price); } - /** * OriginalPrice: 弹性IP的原价,单位“元” * @@ -77,11 +78,10 @@ public function getOriginalPrice() * * @param float $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(float $originalPrice) { $this->set("OriginalPrice", $originalPrice); } - /** * PurchaseValue: 资源有效期, 以Unix Timestamp表示 * @@ -97,7 +97,7 @@ public function getPurchaseValue() * * @param int $purchaseValue */ - public function setPurchaseValue($purchaseValue) + public function setPurchaseValue(int $purchaseValue) { $this->set("PurchaseValue", $purchaseValue); } diff --git a/src/UNet/Models/EIPSetData.php b/src/UNet/Models/EIPSetData.php index 6ec0a5d5..3bc0e425 100644 --- a/src/UNet/Models/EIPSetData.php +++ b/src/UNet/Models/EIPSetData.php @@ -1,6 +1,7 @@ set("Bandwidth", $bandwidth); } - /** * EIPAddr: EIP的IP信息,详情见EIPAddrSet * - * @return EIPAddrSet[]|null + * @return EIPAddrSetModel[]|null */ public function getEIPAddr() { @@ -55,7 +59,7 @@ public function getEIPAddr() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EIPAddrSet($item)); + array_push($result, new EIPAddrSetModel($item)); } return $result; } @@ -63,7 +67,7 @@ public function getEIPAddr() /** * EIPAddr: EIP的IP信息,详情见EIPAddrSet * - * @param EIPAddrSet[] $eipAddr + * @param EIPAddrSetModel[] $eipAddr */ public function setEIPAddr(array $eipAddr) { @@ -73,7 +77,6 @@ public function setEIPAddr(array $eipAddr) } return $result; } - /** * EIPId: EIP资源Id * @@ -89,7 +92,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/UNet/Models/FirewallDataSet.php b/src/UNet/Models/FirewallDataSet.php index 16812066..5dc71899 100644 --- a/src/UNet/Models/FirewallDataSet.php +++ b/src/UNet/Models/FirewallDataSet.php @@ -1,6 +1,7 @@ set("FWId", $fwId); } - /** * GroupId: 安全组ID(即将废弃) * @@ -57,11 +60,10 @@ public function getGroupId() * * @param string $groupId */ - public function setGroupId($groupId) + public function setGroupId(string $groupId) { $this->set("GroupId", $groupId); } - /** * Name: 防火墙名称 * @@ -77,11 +79,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 防火墙业务组 * @@ -97,11 +98,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 防火墙备注 * @@ -117,11 +117,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * ResourceCount: 防火墙绑定资源数量 * @@ -137,11 +136,10 @@ public function getResourceCount() * * @param int $resourceCount */ - public function setResourceCount($resourceCount) + public function setResourceCount(int $resourceCount) { $this->set("ResourceCount", $resourceCount); } - /** * CreateTime: 防火墙组创建时间,格式为Unix Timestamp * @@ -157,11 +155,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Type: 防火墙组类型,枚举值为: "user defined", 用户自定义防火墙; "recommend web", 默认Web防火墙; "recommend non web", 默认非Web防火墙 * @@ -177,15 +174,14 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Rule: 防火墙组中的规则列表,参见 FirewallRuleSet * - * @return FirewallRuleSet[]|null + * @return FirewallRuleSetModel[]|null */ public function getRule() { @@ -195,7 +191,7 @@ public function getRule() } $result = []; foreach ($items as $i => $item) { - array_push($result, new FirewallRuleSet($item)); + array_push($result, new FirewallRuleSetModel($item)); } return $result; } @@ -203,7 +199,7 @@ public function getRule() /** * Rule: 防火墙组中的规则列表,参见 FirewallRuleSet * - * @param FirewallRuleSet[] $rule + * @param FirewallRuleSetModel[] $rule */ public function setRule(array $rule) { diff --git a/src/UNet/Models/FirewallRuleSet.php b/src/UNet/Models/FirewallRuleSet.php index 9c4a2097..bd53930e 100644 --- a/src/UNet/Models/FirewallRuleSet.php +++ b/src/UNet/Models/FirewallRuleSet.php @@ -1,6 +1,7 @@ set("SrcIP", $srcIP); } - /** * Priority: 优先级 * @@ -57,11 +60,10 @@ public function getPriority() * * @param string $priority */ - public function setPriority($priority) + public function setPriority(string $priority) { $this->set("Priority", $priority); } - /** * ProtocolType: 协议类型 * @@ -77,11 +79,10 @@ public function getProtocolType() * * @param string $protocolType */ - public function setProtocolType($protocolType) + public function setProtocolType(string $protocolType) { $this->set("ProtocolType", $protocolType); } - /** * DstPort: 目标端口 * @@ -97,11 +98,10 @@ public function getDstPort() * * @param string $dstPort */ - public function setDstPort($dstPort) + public function setDstPort(string $dstPort) { $this->set("DstPort", $dstPort); } - /** * RuleAction: 防火墙动作 * @@ -117,11 +117,10 @@ public function getRuleAction() * * @param string $ruleAction */ - public function setRuleAction($ruleAction) + public function setRuleAction(string $ruleAction) { $this->set("RuleAction", $ruleAction); } - /** * Remark: 防火墙规则备注 * @@ -137,7 +136,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/UNet/Models/ResourceSet.php b/src/UNet/Models/ResourceSet.php index 7cc06446..666cdd6d 100644 --- a/src/UNet/Models/ResourceSet.php +++ b/src/UNet/Models/ResourceSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } + /** + * SubResourceName: 资源绑定的虚拟网卡的名称 + * + * @return string|null + */ + public function getSubResourceName() + { + return $this->get("SubResourceName"); + } + + /** + * SubResourceName: 资源绑定的虚拟网卡的名称 + * + * @param string $subResourceName + */ + public function setSubResourceName(string $subResourceName) + { + $this->set("SubResourceName", $subResourceName); + } + /** + * SubResourceId: 资源绑定的虚拟网卡的ID + * + * @return string|null + */ + public function getSubResourceId() + { + return $this->get("SubResourceId"); + } + + /** + * SubResourceId: 资源绑定的虚拟网卡的ID + * + * @param string $subResourceId + */ + public function setSubResourceId(string $subResourceId) + { + $this->set("SubResourceId", $subResourceId); + } + /** + * SubResourceType: 资源绑定的虚拟网卡的类型,“uni”,虚拟网卡。 + * + * @return string|null + */ + public function getSubResourceType() + { + return $this->get("SubResourceType"); + } + /** + * SubResourceType: 资源绑定的虚拟网卡的类型,“uni”,虚拟网卡。 + * + * @param string $subResourceType + */ + public function setSubResourceType(string $subResourceType) + { + $this->set("SubResourceType", $subResourceType); + } /** * Name: 名称 * @@ -57,11 +116,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * PrivateIP: 内网IP * @@ -77,11 +135,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * Remark: 备注 * @@ -97,11 +154,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * ResourceID: 绑定该防火墙的资源id * @@ -117,13 +173,12 @@ public function getResourceID() * * @param string $resourceID */ - public function setResourceID($resourceID) + public function setResourceID(string $resourceID) { $this->set("ResourceID", $resourceID); } - /** - * ResourceType: 绑定防火墙组的资源类型。"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计. + * ResourceType: 绑定防火墙组的资源类型。"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计,“uni”,虚拟网卡。 * * @return string|null */ @@ -133,15 +188,14 @@ public function getResourceType() } /** - * ResourceType: 绑定防火墙组的资源类型。"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计. + * ResourceType: 绑定防火墙组的资源类型。"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计,“uni”,虚拟网卡。 * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * Status: 状态 * @@ -157,11 +211,10 @@ public function getStatus() * * @param int $status */ - public function setStatus($status) + public function setStatus(int $status) { $this->set("Status", $status); } - /** * Tag: 业务组 * @@ -177,7 +230,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/UNet/Models/ShareBandwidthSet.php b/src/UNet/Models/ShareBandwidthSet.php index 590d3758..16d70773 100644 --- a/src/UNet/Models/ShareBandwidthSet.php +++ b/src/UNet/Models/ShareBandwidthSet.php @@ -1,6 +1,7 @@ set("ShareBandwidth", $shareBandwidth); } - /** * ShareBandwidthName: 共享带宽的资源名称 * @@ -57,11 +60,10 @@ public function getShareBandwidthName() * * @param string $shareBandwidthName */ - public function setShareBandwidthName($shareBandwidthName) + public function setShareBandwidthName(string $shareBandwidthName) { $this->set("ShareBandwidthName", $shareBandwidthName); } - /** * ShareBandwidthId: 共享带宽ID * @@ -77,7 +79,7 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } diff --git a/src/UNet/Models/ThroughputDailyBillingInfo.php b/src/UNet/Models/ThroughputDailyBillingInfo.php index 782e5271..a0a66d62 100644 --- a/src/UNet/Models/ThroughputDailyBillingInfo.php +++ b/src/UNet/Models/ThroughputDailyBillingInfo.php @@ -1,6 +1,7 @@ set("StartTime", $startTime); } - /** * EndTime: 计费结束时间 * @@ -57,11 +59,10 @@ public function getEndTime() * * @param int $endTime */ - public function setEndTime($endTime) + public function setEndTime(int $endTime) { $this->set("EndTime", $endTime); } - /** * QuantityOut: 计费流量,单位“GB” * @@ -77,11 +78,10 @@ public function getQuantityOut() * * @param int $quantityOut */ - public function setQuantityOut($quantityOut) + public function setQuantityOut(int $quantityOut) { $this->set("QuantityOut", $quantityOut); } - /** * BillingState: 是否已计费,“Yes”或者“No” * @@ -97,7 +97,7 @@ public function getBillingState() * * @param string $billingState */ - public function setBillingState($billingState) + public function setBillingState(string $billingState) { $this->set("BillingState", $billingState); } diff --git a/src/UNet/Models/UnetAllocateEIPSet.php b/src/UNet/Models/UnetAllocateEIPSet.php index 491886ec..c2161067 100644 --- a/src/UNet/Models/UnetAllocateEIPSet.php +++ b/src/UNet/Models/UnetAllocateEIPSet.php @@ -1,6 +1,7 @@ set("EIPId", $eipId); } - /** * EIPAddr: 申请到的IPv4地址. * - * @return UnetEIPAddrSet[]|null + * @return UnetEIPAddrSetModel[]|null */ public function getEIPAddr() { @@ -55,7 +59,7 @@ public function getEIPAddr() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UnetEIPAddrSet($item)); + array_push($result, new UnetEIPAddrSetModel($item)); } return $result; } @@ -63,7 +67,7 @@ public function getEIPAddr() /** * EIPAddr: 申请到的IPv4地址. * - * @param UnetEIPAddrSet[] $eipAddr + * @param UnetEIPAddrSetModel[] $eipAddr */ public function setEIPAddr(array $eipAddr) { diff --git a/src/UNet/Models/UnetBandwidthPackageSet.php b/src/UNet/Models/UnetBandwidthPackageSet.php index b9ceed4f..6bf4db77 100644 --- a/src/UNet/Models/UnetBandwidthPackageSet.php +++ b/src/UNet/Models/UnetBandwidthPackageSet.php @@ -1,6 +1,7 @@ set("BandwidthPackageId", $bandwidthPackageId); } - /** * EnableTime: 生效时间, 格式为 Unix Timestamp * @@ -57,11 +60,10 @@ public function getEnableTime() * * @param int $enableTime */ - public function setEnableTime($enableTime) + public function setEnableTime(int $enableTime) { $this->set("EnableTime", $enableTime); } - /** * DisableTime: 失效时间, 格式为 Unix Timestamp * @@ -77,11 +79,10 @@ public function getDisableTime() * * @param int $disableTime */ - public function setDisableTime($disableTime) + public function setDisableTime(int $disableTime) { $this->set("DisableTime", $disableTime); } - /** * CreateTime: 创建时间, 格式为 Unix Timestamp * @@ -97,11 +98,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * Bandwidth: 带宽包的临时带宽值, 单位Mbps * @@ -117,11 +117,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * EIPId: 带宽包所绑定弹性IP的资源ID * @@ -137,15 +136,14 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } - /** * EIPAddr: 带宽包所绑定弹性IP的详细信息,只有当EIPId对应双线IP时, EIPAddr的长度为2, 其他情况, EIPAddr长度均为1.参见 EIPAddrSet * - * @return EIPAddrSet[]|null + * @return EIPAddrSetModel[]|null */ public function getEIPAddr() { @@ -155,7 +153,7 @@ public function getEIPAddr() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EIPAddrSet($item)); + array_push($result, new EIPAddrSetModel($item)); } return $result; } @@ -163,7 +161,7 @@ public function getEIPAddr() /** * EIPAddr: 带宽包所绑定弹性IP的详细信息,只有当EIPId对应双线IP时, EIPAddr的长度为2, 其他情况, EIPAddr长度均为1.参见 EIPAddrSet * - * @param EIPAddrSet[] $eipAddr + * @param EIPAddrSetModel[] $eipAddr */ public function setEIPAddr(array $eipAddr) { diff --git a/src/UNet/Models/UnetBandwidthUsageEIPSet.php b/src/UNet/Models/UnetBandwidthUsageEIPSet.php index f201b918..a03b09a8 100644 --- a/src/UNet/Models/UnetBandwidthUsageEIPSet.php +++ b/src/UNet/Models/UnetBandwidthUsageEIPSet.php @@ -1,6 +1,7 @@ set("CurBandwidth", $curBandwidth); } - /** * EIPId: 弹性IP资源ID * @@ -57,7 +59,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/UNet/Models/UnetEIPAddrSet.php b/src/UNet/Models/UnetEIPAddrSet.php index 9ab1bc06..4e8fe334 100644 --- a/src/UNet/Models/UnetEIPAddrSet.php +++ b/src/UNet/Models/UnetEIPAddrSet.php @@ -1,6 +1,7 @@ set("OperatorName", $operatorName); } - /** * IP: IP地址 * @@ -57,7 +63,7 @@ public function getIP() * * @param string $ip */ - public function setIP($ip) + public function setIP(string $ip) { $this->set("IP", $ip); } diff --git a/src/UNet/Models/UnetEIPResourceSet.php b/src/UNet/Models/UnetEIPResourceSet.php index cc6132b0..e9660c91 100644 --- a/src/UNet/Models/UnetEIPResourceSet.php +++ b/src/UNet/Models/UnetEIPResourceSet.php @@ -1,6 +1,7 @@ set("ResourceType", $resourceType); } - /** * ResourceName: 已绑定的资源名称 * @@ -57,11 +60,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * ResourceID: 已绑定资源的资源ID * @@ -77,11 +79,10 @@ public function getResourceID() * * @param string $resourceID */ - public function setResourceID($resourceID) + public function setResourceID(string $resourceID) { $this->set("ResourceID", $resourceID); } - /** * SubResourceType: 资源绑定的虚拟网卡的类型。uni,虚拟网卡。 * @@ -97,11 +98,10 @@ public function getSubResourceType() * * @param string $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(string $subResourceType) { $this->set("SubResourceType", $subResourceType); } - /** * SubResourceName: 资源绑定的虚拟网卡的名称 * @@ -117,11 +117,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * SubResourceId: 资源绑定的虚拟网卡的ID * @@ -137,11 +136,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * EIPId: 弹性IP的资源ID * @@ -157,7 +155,7 @@ public function getEIPId() * * @param string $eipId */ - public function setEIPId($eipId) + public function setEIPId(string $eipId) { $this->set("EIPId", $eipId); } diff --git a/src/UNet/Models/UnetEIPSet.php b/src/UNet/Models/UnetEIPSet.php index 4f42acab..45a8d27b 100644 --- a/src/UNet/Models/UnetEIPSet.php +++ b/src/UNet/Models/UnetEIPSet.php @@ -1,6 +1,7 @@ set("EIPId", $eipId); } - /** * Weight: 外网出口权重, 默认为50, 范围[0-100] * @@ -57,11 +62,10 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } - /** * BandwidthType: 带宽模式, 枚举值为: 0: 非共享带宽模式, 1: 共享带宽模式 * @@ -77,11 +81,10 @@ public function getBandwidthType() * * @param int $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(int $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * Bandwidth: 弹性IP的带宽, 单位为Mbps, 当BandwidthType=1时, 该处显示为共享带宽值. 当BandwidthType=0时, 该处显示这个弹性IP的带宽. * @@ -97,11 +100,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * Status: 弹性IP的资源绑定状态, 枚举值为: used: 已绑定, free: 未绑定, freeze: 已冻结 * @@ -117,11 +119,10 @@ public function getStatus() * * @param string $status */ - public function setStatus($status) + public function setStatus(string $status) { $this->set("Status", $status); } - /** * ChargeType: 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按小时付费; Trial, 试用. 按小时付费和试用这两种付费模式需要开通权限. * @@ -137,11 +138,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CreateTime: 弹性IP的创建时间, 格式为Unix Timestamp * @@ -157,11 +157,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 弹性IP的到期时间, 格式为Unix Timestamp * @@ -177,35 +176,33 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * Resource: 弹性IP的详细信息列表, 具体结构见下方 UnetEIPResourceSet * - * @return UnetEIPResourceSet|null + * @return UnetEIPResourceSetModel|null */ public function getResource() { - return new UnetEIPResourceSet($this->get("Resource")); + return new UnetEIPResourceSetModel($this->get("Resource")); } /** * Resource: 弹性IP的详细信息列表, 具体结构见下方 UnetEIPResourceSet * - * @param UnetEIPResourceSet $resource + * @param UnetEIPResourceSetModel $resource */ - public function setResource(array $resource) + public function setResource(UnetEIPResourceSetModel $resource) { $this->set("Resource", $resource->getAll()); } - /** * EIPAddr: 弹性IP的详细信息列表, 具体结构见下方 UnetEIPAddrSet * - * @return UnetEIPAddrSet[]|null + * @return UnetEIPAddrSetModel[]|null */ public function getEIPAddr() { @@ -215,7 +212,7 @@ public function getEIPAddr() } $result = []; foreach ($items as $i => $item) { - array_push($result, new UnetEIPAddrSet($item)); + array_push($result, new UnetEIPAddrSetModel($item)); } return $result; } @@ -223,7 +220,7 @@ public function getEIPAddr() /** * EIPAddr: 弹性IP的详细信息列表, 具体结构见下方 UnetEIPAddrSet * - * @param UnetEIPAddrSet[] $eipAddr + * @param UnetEIPAddrSetModel[] $eipAddr */ public function setEIPAddr(array $eipAddr) { @@ -233,7 +230,6 @@ public function setEIPAddr(array $eipAddr) } return $result; } - /** * Name: 弹性IP的名称,缺省值为 "EIP" * @@ -249,11 +245,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 弹性IP的业务组标识, 缺省值为 "Default" * @@ -269,11 +264,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 弹性IP的备注, 缺省值为 "" * @@ -289,11 +283,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * PayMode: 弹性IP的计费模式, 枚举值为: "Bandwidth", 带宽计费; "Traffic", 流量计费; "ShareBandwidth",共享带宽模式. 默认为 "Bandwidth". * @@ -309,31 +302,29 @@ public function getPayMode() * * @param string $payMode */ - public function setPayMode($payMode) + public function setPayMode(string $payMode) { $this->set("PayMode", $payMode); } - /** * ShareBandwidthSet: 共享带宽信息 参见 ShareBandwidthSet * - * @return ShareBandwidthSet|null + * @return ShareBandwidthSetModel|null */ public function getShareBandwidthSet() { - return new ShareBandwidthSet($this->get("ShareBandwidthSet")); + return new ShareBandwidthSetModel($this->get("ShareBandwidthSet")); } /** * ShareBandwidthSet: 共享带宽信息 参见 ShareBandwidthSet * - * @param ShareBandwidthSet $shareBandwidthSet + * @param ShareBandwidthSetModel $shareBandwidthSet */ - public function setShareBandwidthSet(array $shareBandwidthSet) + public function setShareBandwidthSet(ShareBandwidthSetModel $shareBandwidthSet) { $this->set("ShareBandwidthSet", $shareBandwidthSet->getAll()); } - /** * Expire: 弹性IP是否到期 * @@ -349,7 +340,7 @@ public function getExpire() * * @param boolean $expire */ - public function setExpire($expire) + public function setExpire(bool $expire) { $this->set("Expire", $expire); } diff --git a/src/UNet/Models/UnetShareBandwidthSet.php b/src/UNet/Models/UnetShareBandwidthSet.php index c4c127e4..9f7b93da 100644 --- a/src/UNet/Models/UnetShareBandwidthSet.php +++ b/src/UNet/Models/UnetShareBandwidthSet.php @@ -1,6 +1,7 @@ set("IPVersion", $ipVersion); } - /** * ShareBandwidth: 共享带宽值(预付费)/共享带宽峰值(后付费), 单位Mbps * @@ -57,11 +61,10 @@ public function getShareBandwidth() * * @param int $shareBandwidth */ - public function setShareBandwidth($shareBandwidth) + public function setShareBandwidth(int $shareBandwidth) { $this->set("ShareBandwidth", $shareBandwidth); } - /** * ShareBandwidthId: 共享带宽的资源ID * @@ -77,11 +80,10 @@ public function getShareBandwidthId() * * @param string $shareBandwidthId */ - public function setShareBandwidthId($shareBandwidthId) + public function setShareBandwidthId(string $shareBandwidthId) { $this->set("ShareBandwidthId", $shareBandwidthId); } - /** * ChargeType: 付费方式, 预付费:Year 按年,Month 按月,Dynamic 按需;后付费:PostPay(按月) * @@ -97,11 +99,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * CreateTime: 创建时间, 格式为Unix Timestamp * @@ -117,11 +118,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 过期时间, 格式为Unix Timestamp * @@ -137,15 +137,14 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * EIPSet: EIP信息,详情见 EIPSetData * - * @return EIPSetData[]|null + * @return EIPSetDataModel[]|null */ public function getEIPSet() { @@ -155,7 +154,7 @@ public function getEIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new EIPSetData($item)); + array_push($result, new EIPSetDataModel($item)); } return $result; } @@ -163,7 +162,7 @@ public function getEIPSet() /** * EIPSet: EIP信息,详情见 EIPSetData * - * @param EIPSetData[] $eipSet + * @param EIPSetDataModel[] $eipSet */ public function setEIPSet(array $eipSet) { @@ -173,7 +172,6 @@ public function setEIPSet(array $eipSet) } return $result; } - /** * Name: 共享带宽名称 * @@ -189,7 +187,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/UNet/UNetClient.php b/src/UNet/UNetClient.php index 62ca141b..75189fa7 100644 --- a/src/UNet/UNetClient.php +++ b/src/UNet/UNetClient.php @@ -1,6 +1,7 @@ (string) 地域。 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 - * "OperatorName" => (string) 弹性IP线路,枚举值:国际线路, International;BGP线路:Bgp。使用BGP线路的地域:北京二、上海金融云、上海二、广州等,其他地域均使用国际线路。 - * "Bandwidth" => (integer) 弹性IP的外网带宽, 单位为Mbps. 共享带宽模式必须指定0M带宽, 非共享带宽模式必须指定非0Mbps带宽. 各地域非共享带宽的带宽范围如下: 流量计费[1-300],带宽计费[1-10000] - * "Tag" => (string) 业务组名称, 默认为 "Default" - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费,默认为按月付费。 - * "Quantity" => (integer) 购买的时长, 默认: 1 - * "PayMode" => (string) 弹性IP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; "ShareBandwidth",共享带宽模式. 默认为 "Bandwidth".“PostAccurateBandwidth”:带宽后付费模式 - * "ShareBandwidthId" => (string) 绑定的共享带宽Id,仅当PayMode为ShareBandwidth时有效 - * "Name" => (string) 弹性IP的名称, 默认为 "EIP" - * "Remark" => (string) 弹性IP的备注, 默认为空 - * "CouponId" => (string) 代金券ID, 默认不使用 - * ] - * - * Outputs: - * - * $outputs = [ - * "EIPSet" => (array) 申请到的EIP资源详情 参见 UnetAllocateEIPSet[ - * [ - * "EIPId" => (string) 申请到的EIP资源ID - * "EIPAddr" => (array) 申请到的IPv4地址. [ - * [ - * "OperatorName" => (string) 运营商信息如: 国际: International, BGP: BGP - * "IP" => (string) IP地址 - * ] - * ] - * ] - * ] - * ] - * - * @return AllocateEIPResponse * @throws UCloudException */ public function allocateEIP(AllocateEIPRequest $request = null) @@ -133,31 +206,13 @@ public function allocateEIP(AllocateEIPRequest $request = null) $resp = $this->invoke($request); return new AllocateEIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * AllocateShareBandwidth - 开通共享带宽 * - * See also: https://docs.ucloud.cn/api/unet-api/allocate_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 - * "Name" => (string) 共享带宽名字 - * "ChargeType" => (string) 付费方式:Year 按年,Month 按月,Dynamic 按时; - * "ShareBandwidth" => (integer) 共享带宽值 - * "Quantity" => (integer) 购买时长 - * "IPVersion" => (string) 共享带宽类型,IPv4或者IPv6,不传默认IPv4 - * ] - * - * Outputs: - * - * $outputs = [ - * "ShareBandwidthId" => (string) 共享带宽资源Id - * ] - * - * @return AllocateShareBandwidthResponse * @throws UCloudException */ public function allocateShareBandwidth(AllocateShareBandwidthRequest $request = null) @@ -165,28 +220,13 @@ public function allocateShareBandwidth(AllocateShareBandwidthRequest $request = $resp = $this->invoke($request); return new AllocateShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * AssociateEIPWithShareBandwidth - 将EIP加入共享带宽 * - * See also: https://docs.ucloud.cn/api/unet-api/associate_eip_with_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 - * "EIPIds" => (array) 要加入共享带宽的EIP的资源Id - * "ShareBandwidthId" => (string) 共享带宽ID - * "IPVersion" => (string) 共享带宽类型,IPv4或者IPv6,不传默认IPv4 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AssociateEIPWithShareBandwidthResponse * @throws UCloudException */ public function associateEIPWithShareBandwidth(AssociateEIPWithShareBandwidthRequest $request = null) @@ -194,28 +234,13 @@ public function associateEIPWithShareBandwidth(AssociateEIPWithShareBandwidthReq $resp = $this->invoke($request); return new AssociateEIPWithShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * BindEIP - 将尚未使用的弹性IP绑定到指定的资源 * - * See also: https://docs.ucloud.cn/api/unet-api/bind_eip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写 - * "EIPId" => (string) 弹性IP的资源Id - * "ResourceType" => (string) 弹性IP请求绑定的资源类型, 枚举值为: uhost: 云主机; ulb, 负载均衡器 upm: 物理机; hadoophost: 大数据集群;fortresshost:堡垒机;udockhost:容器;udhost:私有专区主机;natgw:natgw;udb:udb;vpngw:ipsec vpn;ucdr:云灾备;dbaudit:数据库审计;uni:虚拟网卡;cube,Cube容器。如果EIP为普通带宽计费,且带宽值高于2G,则只允许绑定在快杰型云主机和ULB - * "ResourceId" => (string) 弹性IP请求绑定的资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return BindEIPResponse * @throws UCloudException */ public function bindEIP(BindEIPRequest $request = null) @@ -223,30 +248,13 @@ public function bindEIP(BindEIPRequest $request = null) $resp = $this->invoke($request); return new BindEIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateBandwidthPackage - 为非共享带宽模式下, 已绑定资源实例的带宽计费弹性IP附加临时带宽包 * - * See also: https://docs.ucloud.cn/api/unet-api/create_bandwidth_package - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Bandwidth" => (integer) 带宽大小(单位Mbps), 取值范围[2,800] (最大值受地域限制) - * "EIPId" => (string) 所绑定弹性IP的资源ID - * "TimeRange" => (integer) 带宽包有效时长, 取值范围为大于0的整数, 即该带宽包在EnableTime到 EnableTime+TimeRange时间段内生效 - * "EnableTime" => (integer) 生效时间, 格式为 Unix timestamp, 默认为立即开通 - * "CouponId" => (string) 代金券ID - * ] - * - * Outputs: - * - * $outputs = [ - * "BandwidthPackageId" => (string) 所创建带宽包的资源ID - * ] - * - * @return CreateBandwidthPackageResponse * @throws UCloudException */ public function createBandwidthPackage(CreateBandwidthPackageRequest $request = null) @@ -254,30 +262,13 @@ public function createBandwidthPackage(CreateBandwidthPackageRequest $request = $resp = $this->invoke($request); return new CreateBandwidthPackageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateFirewall - 创建防火墙 * - * See also: https://docs.ucloud.cn/api/unet-api/create_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写 - * "Rule" => (array) 防火墙规则,例如:TCP|22|192.168.1.1/22|DROP|LOW|禁用22端口,第一个参数代表协议:第二个参数代表端口号,第三个参数为ip,第四个参数为ACCEPT(接受)和DROP(拒绝),第五个参数优先级:HIGH(高),MEDIUM(中),LOW(低),第六个参数为该条规则的自定义备注,bj1不支持添加备注 - * "Name" => (string) 防火墙名称 - * "Tag" => (string) 防火墙业务组,默认为Default - * "Remark" => (string) 防火墙描述,默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * "FWId" => (string) 防火墙ID - * ] - * - * @return CreateFirewallResponse * @throws UCloudException */ public function createFirewall(CreateFirewallRequest $request = null) @@ -285,26 +276,13 @@ public function createFirewall(CreateFirewallRequest $request = null) $resp = $this->invoke($request); return new CreateFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteBandwidthPackage - 删除弹性IP上已附加带宽包 * - * See also: https://docs.ucloud.cn/api/unet-api/delete_bandwidth_package - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "BandwidthPackageId" => (string) 带宽包资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteBandwidthPackageResponse * @throws UCloudException */ public function deleteBandwidthPackage(DeleteBandwidthPackageRequest $request = null) @@ -312,26 +290,13 @@ public function deleteBandwidthPackage(DeleteBandwidthPackageRequest $request = $resp = $this->invoke($request); return new DeleteBandwidthPackageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteFirewall - 删除防火墙 * - * See also: https://docs.ucloud.cn/api/unet-api/delete_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "FWId" => (string) 防火墙资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteFirewallResponse * @throws UCloudException */ public function deleteFirewall(DeleteFirewallRequest $request = null) @@ -339,44 +304,13 @@ public function deleteFirewall(DeleteFirewallRequest $request = null) $resp = $this->invoke($request); return new DeleteFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeBandwidthPackage - 获取某地域下的带宽包信息 * - * See also: https://docs.ucloud.cn/api/unet-api/describe_bandwidth_package - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Limit" => (integer) 返回数据分页值, 取值范围为 [0,10000000] 之间的整数, 默认为20 - * "Offset" => (integer) 返回数据偏移量, 默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的带宽包总数 - * "DataSets" => (array) 带宽包详细信息, 参见 UnetBandwidthPackageSet[ - * [ - * "BandwidthPackageId" => (string) 带宽包的资源ID - * "EnableTime" => (integer) 生效时间, 格式为 Unix Timestamp - * "DisableTime" => (integer) 失效时间, 格式为 Unix Timestamp - * "CreateTime" => (integer) 创建时间, 格式为 Unix Timestamp - * "Bandwidth" => (integer) 带宽包的临时带宽值, 单位Mbps - * "EIPId" => (string) 带宽包所绑定弹性IP的资源ID - * "EIPAddr" => (array) 带宽包所绑定弹性IP的详细信息,只有当EIPId对应双线IP时, EIPAddr的长度为2, 其他情况, EIPAddr长度均为1.参见 EIPAddrSet[ - * [ - * "OperatorName" => (string) 运营商信息, 枚举值为: BGP: BGP; International: 国际. - * "IP" => (string) 弹性IP地址 - * ] - * ] - * ] - * ] - * ] - * - * @return DescribeBandwidthPackageResponse * @throws UCloudException */ public function describeBandwidthPackage(DescribeBandwidthPackageRequest $request = null) @@ -384,35 +318,13 @@ public function describeBandwidthPackage(DescribeBandwidthPackageRequest $reques $resp = $this->invoke($request); return new DescribeBandwidthPackageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeBandwidthUsage - 获取带宽用量信息 * - * See also: https://docs.ucloud.cn/api/unet-api/describe_bandwidth_usage - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Limit" => (integer) 返回数据分页值, 取值范围为 [0,10000000] 之间的整数, 默认为20 - * "OffSet" => (integer) 返回数据偏移量, 默认为0 - * "EIPIds" => (array) 弹性IP的资源Id. 如果为空, 则返回当前 Region中符合条件的所有EIP的带宽用量, n为自然数 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) EIPSet中的元素个数 - * "EIPSet" => (array) 单个弹性IP的带宽用量详细信息, 详见 UnetBandwidthUsageEIPSet, 如没有弹性IP资源则没有该返回值。[ - * [ - * "CurBandwidth" => (number) 最近5分钟带宽用量, 单位Mbps - * "EIPId" => (string) 弹性IP资源ID - * ] - * ] - * ] - * - * @return DescribeBandwidthUsageResponse * @throws UCloudException */ public function describeBandwidthUsage(DescribeBandwidthUsageRequest $request = null) @@ -420,69 +332,13 @@ public function describeBandwidthUsage(DescribeBandwidthUsageRequest $request = $resp = $this->invoke($request); return new DescribeBandwidthUsageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeEIP - 获取弹性IP信息 * - * See also: https://docs.ucloud.cn/api/unet-api/describe_eip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写 - * "EIPIds" => (array) 弹性IP的资源ID如果为空, 则返回当前 Region中符合条件的的所有EIP - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * "IPs" => (array) IP地址,支持通过ip查询,如果ip与EIP都传,会取并集查询 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的弹性IP总数 - * "UnbindCount" => (integer) 未绑定的弹性IP总数 - * "TotalBandwidth" => (integer) 满足条件的弹性IP带宽总和, 单位Mbps - * "EIPSet" => (array) 弹性IP列表, 每项参数详见 UnetEIPSet[ - * [ - * "EIPId" => (string) 弹性IP的资源ID - * "Weight" => (integer) 外网出口权重, 默认为50, 范围[0-100] - * "BandwidthType" => (integer) 带宽模式, 枚举值为: 0: 非共享带宽模式, 1: 共享带宽模式 - * "Bandwidth" => (integer) 弹性IP的带宽, 单位为Mbps, 当BandwidthType=1时, 该处显示为共享带宽值. 当BandwidthType=0时, 该处显示这个弹性IP的带宽. - * "Status" => (string) 弹性IP的资源绑定状态, 枚举值为: used: 已绑定, free: 未绑定, freeze: 已冻结 - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按小时付费; Trial, 试用. 按小时付费和试用这两种付费模式需要开通权限. - * "CreateTime" => (integer) 弹性IP的创建时间, 格式为Unix Timestamp - * "ExpireTime" => (integer) 弹性IP的到期时间, 格式为Unix Timestamp - * "Resource" => (object) 弹性IP的详细信息列表, 具体结构见下方 UnetEIPResourceSet[ - * "ResourceType" => (string) 已绑定的资源类型, 枚举值为: uhost, 云主机;natgw:NAT网关;ulb:负载均衡器;upm: 物理机; hadoophost: 大数据集群;fortresshost:堡垒机;udockhost:容器;udhost:私有专区主机;vpngw:IPSec VPN;ucdr:云灾备;dbaudit:数据库审计,uni:虚拟网卡。 - * "ResourceName" => (string) 已绑定的资源名称 - * "ResourceID" => (string) 已绑定资源的资源ID - * "SubResourceType" => (string) 资源绑定的虚拟网卡的类型。uni,虚拟网卡。 - * "SubResourceName" => (string) 资源绑定的虚拟网卡的名称 - * "SubResourceId" => (string) 资源绑定的虚拟网卡的ID - * "EIPId" => (string) 弹性IP的资源ID - * ] - * "EIPAddr" => (array) 弹性IP的详细信息列表, 具体结构见下方 UnetEIPAddrSet[ - * [ - * "OperatorName" => (string) 运营商信息如: 国际: International, BGP: BGP - * "IP" => (string) IP地址 - * ] - * ] - * "Name" => (string) 弹性IP的名称,缺省值为 "EIP" - * "Tag" => (string) 弹性IP的业务组标识, 缺省值为 "Default" - * "Remark" => (string) 弹性IP的备注, 缺省值为 "" - * "PayMode" => (string) 弹性IP的计费模式, 枚举值为: "Bandwidth", 带宽计费; "Traffic", 流量计费; "ShareBandwidth",共享带宽模式. 默认为 "Bandwidth". - * "ShareBandwidthSet" => (object) 共享带宽信息 参见 ShareBandwidthSet[ - * "ShareBandwidth" => (integer) 共享带宽带宽值 - * "ShareBandwidthName" => (string) 共享带宽的资源名称 - * "ShareBandwidthId" => (string) 共享带宽ID - * ] - * "Expire" => (boolean) 弹性IP是否到期 - * ] - * ] - * ] - * - * @return DescribeEIPResponse * @throws UCloudException */ public function describeEIP(DescribeEIPRequest $request = null) @@ -490,53 +346,13 @@ public function describeEIP(DescribeEIPRequest $request = null) $resp = $this->invoke($request); return new DescribeEIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeFirewall - 获取防火墙组信息 * - * See also: https://docs.ucloud.cn/api/unet-api/describe_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写 - * "FWId" => (string) 防火墙ID,默认为返回所有防火墙 - * "ResourceType" => (string) 绑定防火墙组的资源类型,默认为全部资源类型。枚举值为:"unatgw",NAT网关; "uhost",云主机;“uni”,虚拟网卡; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计. - * "ResourceId" => (string) 绑定防火墙组的资源ID - * "Limit" => (integer) 返回数据长度,默认为20,最大10000000 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 获取的防火墙组详细信息 参见 FirewallDataSet[ - * [ - * "FWId" => (string) 防火墙ID - * "GroupId" => (string) 安全组ID(即将废弃) - * "Name" => (string) 防火墙名称 - * "Tag" => (string) 防火墙业务组 - * "Remark" => (string) 防火墙备注 - * "ResourceCount" => (integer) 防火墙绑定资源数量 - * "CreateTime" => (integer) 防火墙组创建时间,格式为Unix Timestamp - * "Type" => (string) 防火墙组类型,枚举值为: "user defined", 用户自定义防火墙; "recommend web", 默认Web防火墙; "recommend non web", 默认非Web防火墙 - * "Rule" => (array) 防火墙组中的规则列表,参见 FirewallRuleSet[ - * [ - * "SrcIP" => (string) 源地址 - * "Priority" => (string) 优先级 - * "ProtocolType" => (string) 协议类型 - * "DstPort" => (string) 目标端口 - * "RuleAction" => (string) 防火墙动作 - * "Remark" => (string) 防火墙规则备注 - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 防火墙资源数量 - * ] - * - * @return DescribeFirewallResponse * @throws UCloudException */ public function describeFirewall(DescribeFirewallRequest $request = null) @@ -544,41 +360,13 @@ public function describeFirewall(DescribeFirewallRequest $request = null) $resp = $this->invoke($request); return new DescribeFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeFirewallResource - 获取防火墙组所绑定资源的外网IP * - * See also: https://docs.ucloud.cn/api/unet-api/describe_firewall_resource - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "FWId" => (string) 防火墙ID - * "Limit" => (integer) 返回数据长度,默认为20,最大10000000 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "ResourceSet" => (array) 资源列表,见 ResourceSet[ - * [ - * "Zone" => (integer) 可用区 - * "Name" => (string) 名称 - * "PrivateIP" => (string) 内网IP - * "Remark" => (string) 备注 - * "ResourceID" => (string) 绑定该防火墙的资源id - * "ResourceType" => (string) 绑定防火墙组的资源类型。"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计. - * "Status" => (integer) 状态 - * "Tag" => (string) 业务组 - * ] - * ] - * "TotalCount" => (integer) 绑定资源总数 - * ] - * - * @return DescribeFirewallResourceResponse * @throws UCloudException */ public function describeFirewallResource(DescribeFirewallResourceRequest $request = null) @@ -586,50 +374,13 @@ public function describeFirewallResource(DescribeFirewallResourceRequest $reques $resp = $this->invoke($request); return new DescribeFirewallResourceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribeShareBandwidth - 获取共享带宽信息 * - * See also: https://docs.ucloud.cn/api/unet-api/describe_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ShareBandwidthIds" => (array) 需要返回的共享带宽Id - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 共享带宽信息组 参见 UnetShareBandwidthSet[ - * [ - * "IPVersion" => (string) 共享带宽类型 - * "ShareBandwidth" => (integer) 共享带宽值(预付费)/共享带宽峰值(后付费), 单位Mbps - * "ShareBandwidthId" => (string) 共享带宽的资源ID - * "ChargeType" => (string) 付费方式, 预付费:Year 按年,Month 按月,Dynamic 按需;后付费:PostPay(按月) - * "CreateTime" => (integer) 创建时间, 格式为Unix Timestamp - * "ExpireTime" => (integer) 过期时间, 格式为Unix Timestamp - * "EIPSet" => (array) EIP信息,详情见 EIPSetData[ - * [ - * "Bandwidth" => (integer) EIP带宽值 - * "EIPAddr" => (array) EIP的IP信息,详情见EIPAddrSet[ - * [ - * "OperatorName" => (string) 运营商信息, 枚举值为: BGP: BGP; International: 国际. - * "IP" => (string) 弹性IP地址 - * ] - * ] - * "EIPId" => (string) EIP资源Id - * ] - * ] - * "Name" => (string) 共享带宽名称 - * ] - * ] - * "TotalCount" => (integer) 符合条件的共享带宽总数,大于等于返回DataSet长度 - * ] - * - * @return DescribeShareBandwidthResponse * @throws UCloudException */ public function describeShareBandwidth(DescribeShareBandwidthRequest $request = null) @@ -637,30 +388,41 @@ public function describeShareBandwidth(DescribeShareBandwidthRequest $request = $resp = $this->invoke($request); return new DescribeShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DisassociateEIPWithShareBandwidth - 将EIP移出共享带宽 + * DescribeShareBandwidthPrice - 获取共享带宽价格 * - * See also: https://docs.ucloud.cn/api/unet-api/disassociate_eip_with_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ShareBandwidthId" => (string) 共享带宽ID - * "Bandwidth" => (integer) 移出共享带宽后,EIP的外网带宽, 单位为Mbps. 各地域带宽范围如下: 流量计费[1-200],带宽计费[1-800] - * "EIPIds" => (array) EIP的资源Id;默认移出该共享带宽下所有的EIP - * "PayMode" => (string) 移出共享带宽后,EIP的计费模式. 枚举值: "Traffic", 流量计费; "Bandwidth", 带宽计费; 默认为 "Bandwidth". - * "IPVersion" => (string) 共享带宽类型,IPv4或者IPv6,不传默认IPv4 - * ] - * - * Outputs: + * @throws UCloudException + */ + public function describeShareBandwidthPrice(DescribeShareBandwidthPriceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeShareBandwidthPriceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeShareBandwidthUpdatePrice - 获取共享带宽升级价格 * - * $outputs = [ - * ] + * @throws UCloudException + */ + public function describeShareBandwidthUpdatePrice(DescribeShareBandwidthUpdatePriceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeShareBandwidthUpdatePriceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DisassociateEIPWithShareBandwidth - 将EIP移出共享带宽 * - * @return DisassociateEIPWithShareBandwidthResponse * @throws UCloudException */ public function disassociateEIPWithShareBandwidth(DisassociateEIPWithShareBandwidthRequest $request = null) @@ -668,28 +430,13 @@ public function disassociateEIPWithShareBandwidth(DisassociateEIPWithShareBandwi $resp = $this->invoke($request); return new DisassociateEIPWithShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DisassociateFirewall - 解绑资源上的防火墙 * - * See also: https://docs.ucloud.cn/api/unet-api/disassociate_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FWId" => (string) 防火墙ID - * "ResourceId" => (string) 需要解绑的资源ID - * "ResourceType" => (string) 资源类型:ULB 表示负载均衡 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DisassociateFirewallResponse * @throws UCloudException */ public function disassociateFirewall(DisassociateFirewallRequest $request = null) @@ -697,32 +444,13 @@ public function disassociateFirewall(DisassociateFirewallRequest $request = null $resp = $this->invoke($request); return new DisassociateFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetEIPPayMode - 获取弹性IP计费模式 * - * See also: https://docs.ucloud.cn/api/unet-api/get_eip_pay_mode - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (array) 弹性IP的资源Id - * ] - * - * Outputs: - * - * $outputs = [ - * "EIPPayMode" => (array) EIP的计费模式, 参见 EIPPayModeSet[ - * [ - * "EIPId" => (string) EIP的资源ID - * "EIPPayMode" => (string) EIP的计费模式. 枚举值为:Bandwidth, 带宽计费;Traffic, 流量计费; "ShareBandwidth",共享带宽模式 - * ] - * ] - * ] - * - * @return GetEIPPayModeResponse * @throws UCloudException */ public function getEIPPayMode(GetEIPPayModeRequest $request = null) @@ -730,38 +458,13 @@ public function getEIPPayMode(GetEIPPayModeRequest $request = null) $resp = $this->invoke($request); return new GetEIPPayModeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetEIPPrice - 获取弹性IP价格 * - * See also: https://docs.ucloud.cn/api/unet-api/get_eip_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "OperatorName" => (string) 弹性IP的线路如下: 国际: International BGP: Bgp 各地域允许的线路参数如下: cn-sh1: Bgp cn-sh2: Bgp cn-gd: Bgp cn-bj1: Bgp cn-bj2: Bgp hk: International us-ca: International th-bkk: International kr-seoul:International us-ws:International ge-fra:International sg:International tw-kh:International.其他海外线路均为 International,泉州为移动单线cn-qz:ChinaMobile - * "Bandwidth" => (integer) 弹性IP的外网带宽, 单位为Mbps, 范围 [0-800] - * "ChargeType" => (string) 付费方式, 枚举值为: Year, 按年付费; Month, 按月付费; Dynamic, 按时付费; 默认为获取三种价格 - * "PayMode" => (string) 弹性IP计费方式r. 枚举值为: Traffic, 流量计费; Bandwidth, 带宽计费; "ShareBandwidth",共享带宽模式. 默认为Bandwidth - * "Quantity" => (integer) 购买时长。默认: 1。按小时购买(Dynamic)时无需此参数。 月付时,此参数传0,代表了购买至月末 - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceSet" => (array) 弹性IP价格详情 详情见 EIPPriceDetailSet[ - * [ - * "ChargeType" => (string) 弹性IP付费方式 - * "Price" => (number) 购买弹性IP的实际价格, 单位"元" - * "OriginalPrice" => (number) 弹性IP的原价,单位“元” - * "PurchaseValue" => (integer) 资源有效期, 以Unix Timestamp表示 - * ] - * ] - * ] - * - * @return GetEIPPriceResponse * @throws UCloudException */ public function getEIPPrice(GetEIPPriceRequest $request = null) @@ -769,28 +472,13 @@ public function getEIPPrice(GetEIPPriceRequest $request = null) $resp = $this->invoke($request); return new GetEIPPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetEIPUpgradePrice - 获取弹性IP带宽改动价格 * - * See also: https://docs.ucloud.cn/api/unet-api/get_eip_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源ID - * "Bandwidth" => (integer) 弹性IP的外网带宽, 单位为Mbps, 范围 [1-800] - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 调整带宽后的EIP价格, 单位为"元", 如需退费此处为负值 - * ] - * - * @return GetEIPUpgradePriceResponse * @throws UCloudException */ public function getEIPUpgradePrice(GetEIPUpgradePriceRequest $request = null) @@ -798,38 +486,13 @@ public function getEIPUpgradePrice(GetEIPUpgradePriceRequest $request = null) $resp = $this->invoke($request); return new GetEIPUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetThroughputDailyBillingInfo - 获取流量计费EIP每日流量计费信息 * - * See also: https://docs.ucloud.cn/api/unet-api/get_throughput_daily_billing_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "EIPId" => (string) EIP的资源ID - * "StartTime" => (integer) 查询开始时间时间戳 - * "EndTime" => (integer) 查询结束时间时间戳 - * ] - * - * Outputs: - * - * $outputs = [ - * "Stats" => (array) EIP流量计费信息,详见模型ThroughputDailyBillingInfo[ - * [ - * "StartTime" => (integer) 计费开始时间 - * "EndTime" => (integer) 计费结束时间 - * "QuantityOut" => (integer) 计费流量,单位“GB” - * "BillingState" => (string) 是否已计费,“Yes”或者“No” - * ] - * ] - * "TotalOut" => (integer) 计费总流量 - * "EIPId" => (string) 资源ID - * ] - * - * @return GetThroughputDailyBillingInfoResponse * @throws UCloudException */ public function getThroughputDailyBillingInfo(GetThroughputDailyBillingInfoRequest $request = null) @@ -837,28 +500,13 @@ public function getThroughputDailyBillingInfo(GetThroughputDailyBillingInfoReque $resp = $this->invoke($request); return new GetThroughputDailyBillingInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GrantFirewall - 将防火墙应用到资源上 * - * See also: https://docs.ucloud.cn/api/unet-api/grant_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "FWId" => (string) 防火墙资源ID - * "ResourceType" => (string) 绑定防火墙组的资源类型,默认为全部资源类型。枚举值为:"unatgw",NAT网关; "uhost",云主机; "upm",物理云主机; "hadoophost",hadoop节点; "fortresshost",堡垒机; "udhost",私有专区主机;"udockhost",容器;"dbaudit",数据库审计,”uni“,虚拟网卡,“cube”,Cube容器实例。 - * "ResourceId" => (string) 所应用资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return GrantFirewallResponse * @throws UCloudException */ public function grantFirewall(GrantFirewallRequest $request = null) @@ -866,27 +514,13 @@ public function grantFirewall(GrantFirewallRequest $request = null) $resp = $this->invoke($request); return new GrantFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyEIPBandwidth - 调整弹性IP的外网带宽 * - * See also: https://docs.ucloud.cn/api/unet-api/modify_eip_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源ID - * "Bandwidth" => (integer) 弹性IP的外网带宽, 单位为Mbps. 各地域的带宽值范围如下:流量计费[1-200],带宽计费[1-800] - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyEIPBandwidthResponse * @throws UCloudException */ public function modifyEIPBandwidth(ModifyEIPBandwidthRequest $request = null) @@ -894,27 +528,13 @@ public function modifyEIPBandwidth(ModifyEIPBandwidthRequest $request = null) $resp = $this->invoke($request); return new ModifyEIPBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ModifyEIPWeight - 修改弹性IP的外网出口权重 * - * See also: https://docs.ucloud.cn/api/unet-api/modify_eip_weight - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源ID - * "Weight" => (integer) 外网出口权重, 范围[0-100] 取值为0时, 该弹性IP不会被使用. 取值为100时, 同主机下只会使用这个弹性IP,其他弹性IP不会被使用 请勿将多个绑定在同一资源的弹性IP设置为相同权重 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyEIPWeightResponse * @throws UCloudException */ public function modifyEIPWeight(ModifyEIPWeightRequest $request = null) @@ -922,26 +542,13 @@ public function modifyEIPWeight(ModifyEIPWeightRequest $request = null) $resp = $this->invoke($request); return new ModifyEIPWeightResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReleaseEIP - 释放弹性IP资源, 所释放弹性IP必须为非绑定状态. * - * See also: https://docs.ucloud.cn/api/unet-api/release_eip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReleaseEIPResponse * @throws UCloudException */ public function releaseEIP(ReleaseEIPRequest $request = null) @@ -949,28 +556,13 @@ public function releaseEIP(ReleaseEIPRequest $request = null) $resp = $this->invoke($request); return new ReleaseEIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReleaseShareBandwidth - 关闭共享带宽 * - * See also: https://docs.ucloud.cn/api/unet-api/release_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ShareBandwidthId" => (string) 共享带宽ID - * "EIPBandwidth" => (integer) 关闭共享带宽后,各EIP恢复为的带宽值 - * "PayMode" => (string) 默认为 Bandwidth 带宽计费 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReleaseShareBandwidthResponse * @throws UCloudException */ public function releaseShareBandwidth(ReleaseShareBandwidthRequest $request = null) @@ -978,27 +570,13 @@ public function releaseShareBandwidth(ReleaseShareBandwidthRequest $request = nu $resp = $this->invoke($request); return new ReleaseShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizeShareBandwidth - 调整共享带宽的带宽值 * - * See also: https://docs.ucloud.cn/api/unet-api/resize_share_bandwidth - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ShareBandwidth" => (integer) 带宽值,单位为Mb,范围 [20-5000] (最大值受地域限制) - * "ShareBandwidthId" => (string) 共享带宽的Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ResizeShareBandwidthResponse * @throws UCloudException */ public function resizeShareBandwidth(ResizeShareBandwidthRequest $request = null) @@ -1006,28 +584,13 @@ public function resizeShareBandwidth(ResizeShareBandwidthRequest $request = null $resp = $this->invoke($request); return new ResizeShareBandwidthResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SetEIPPayMode - 设置弹性IP计费模式, 切换时会涉及付费/退费. * - * See also: https://docs.ucloud.cn/api/unet-api/set_eip_pay_mode - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源Id - * "PayMode" => (string) 计费模式. 枚举值:"Traffic", 流量计费模式; "Bandwidth", 带宽计费模式 - * "Bandwidth" => (integer) 调整的目标带宽值, 单位Mbps. 各地域的带宽值范围如下: 流量计费[1-200],其余情况[1-800] - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetEIPPayModeResponse * @throws UCloudException */ public function setEIPPayMode(SetEIPPayModeRequest $request = null) @@ -1035,28 +598,13 @@ public function setEIPPayMode(SetEIPPayModeRequest $request = null) $resp = $this->invoke($request); return new SetEIPPayModeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UnBindEIP - 将弹性IP从资源上解绑 * - * See also: https://docs.ucloud.cn/api/unet-api/un_bind_eip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "EIPId" => (string) 弹性IP的资源Id - * "ResourceType" => (string) 弹性IP请求解绑的资源类型, 枚举值为: uhost: 云主机; ulb, 负载均衡器 upm: 物理机; hadoophost: 大数据集群;fortresshost:堡垒机;udockhost:容器;udhost:私有专区主机;natgw:NAT网关;udb:udb;vpngw:ipsec vpn;ucdr:云灾备;dbaudit:数据库审计; - * "ResourceId" => (string) 弹性IP请求解绑的资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UnBindEIPResponse * @throws UCloudException */ public function unBindEIP(UnBindEIPRequest $request = null) @@ -1064,29 +612,13 @@ public function unBindEIP(UnBindEIPRequest $request = null) $resp = $this->invoke($request); return new UnBindEIPResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateEIPAttribute - 更新弹性IP名称,业务组,备注等属性字段 * - * See also: https://docs.ucloud.cn/api/unet-api/update_eip_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "EIPId" => (string) EIP资源ID - * "Name" => (string) 名字(Name Tag Remark都为空则报错) - * "Tag" => (string) 业务 - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateEIPAttributeResponse * @throws UCloudException */ public function updateEIPAttribute(UpdateEIPAttributeRequest $request = null) @@ -1094,28 +626,13 @@ public function updateEIPAttribute(UpdateEIPAttributeRequest $request = null) $resp = $this->invoke($request); return new UpdateEIPAttributeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateFirewall - 更新防火墙规则 * - * See also: https://docs.ucloud.cn/api/unet-api/update_firewall - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "FWId" => (string) 防火墙资源ID - * "Rule" => (array) 防火墙规则,例如:TCP|22|192.168.1.1/22|DROP|LOW|禁用22端口,第一个参数代表协议:第二个参数代表端口号,第三个参数为ip,第四个参数为ACCEPT(接受)和DROP(拒绝),第五个参数优先级:HIGH(高),MEDIUM(中),LOW(低),第六个参数为该条规则的自定义备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "FWId" => (string) 防火墙id - * ] - * - * @return UpdateFirewallResponse * @throws UCloudException */ public function updateFirewall(UpdateFirewallRequest $request = null) @@ -1123,29 +640,13 @@ public function updateFirewall(UpdateFirewallRequest $request = null) $resp = $this->invoke($request); return new UpdateFirewallResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateFirewallAttribute - 更新防火墙规则 * - * See also: https://docs.ucloud.cn/api/unet-api/update_firewall_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "FWId" => (string) 防火墙资源ID - * "Name" => (string) 防火墙名称,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 - * "Tag" => (string) 防火墙业务组,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 - * "Remark" => (string) 防火墙备注,默认为空,为空则不做修改。Name,Tag,Remark必须填写1个及以上 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateFirewallAttributeResponse * @throws UCloudException */ public function updateFirewallAttribute(UpdateFirewallAttributeRequest $request = null) diff --git a/src/UPHost/Apis/CreatePHostImageRequest.php b/src/UPHost/Apis/CreatePHostImageRequest.php new file mode 100644 index 00000000..4dae535e --- /dev/null +++ b/src/UPHost/Apis/CreatePHostImageRequest.php @@ -0,0 +1,149 @@ + "CreatePHostImage"]); + $this->markRequired("Region"); + $this->markRequired("Zone"); + $this->markRequired("PHostId"); + $this->markRequired("ImageName"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * PHostId: UPHost实例ID + * + * @return string|null + */ + public function getPHostId() + { + return $this->get("PHostId"); + } + + /** + * PHostId: UPHost实例ID + * + * @param string $pHostId + */ + public function setPHostId(string $pHostId) + { + $this->set("PHostId", $pHostId); + } + /** + * ImageName: 镜像名称 + * + * @return string|null + */ + public function getImageName() + { + return $this->get("ImageName"); + } + + /** + * ImageName: 镜像名称 + * + * @param string $imageName + */ + public function setImageName(string $imageName) + { + $this->set("ImageName", $imageName); + } + /** + * ImageDescription: 镜像描述 + * + * @return string|null + */ + public function getImageDescription() + { + return $this->get("ImageDescription"); + } + + /** + * ImageDescription: 镜像描述 + * + * @param string $imageDescription + */ + public function setImageDescription(string $imageDescription) + { + $this->set("ImageDescription", $imageDescription); + } +} diff --git a/src/UPHost/Apis/CreatePHostImageResponse.php b/src/UPHost/Apis/CreatePHostImageResponse.php new file mode 100644 index 00000000..20da398e --- /dev/null +++ b/src/UPHost/Apis/CreatePHostImageResponse.php @@ -0,0 +1,45 @@ +get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } +} diff --git a/src/UPHost/Apis/CreatePHostRequest.php b/src/UPHost/Apis/CreatePHostRequest.php index 05bf314b..f64b752c 100644 --- a/src/UPHost/Apis/CreatePHostRequest.php +++ b/src/UPHost/Apis/CreatePHostRequest.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * ImageId: ImageId,可以通过接口 [DescribePHostImage](api/uphost-api/describe_phost_image.html)获取 * @@ -107,11 +106,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * Password: 密码(密码需使用base64进行编码) * @@ -127,11 +125,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * Type: 物理机类型,默认为:db-2(基础型-SAS-V3) * @@ -147,11 +144,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Name: 物理机名称,默认为phost * @@ -167,11 +163,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 物理机备注,默认为空 * @@ -187,11 +182,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组,默认为default * @@ -207,11 +201,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ChargeType: 计费模式,枚举值为:year, 按年付费; month,按月付费;默认为按月付费 * @@ -227,11 +220,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,1-10个月或1-10年;默认值为1。月付时,此参数传0,代表购买至月末,1代表整月。 * @@ -247,11 +239,10 @@ public function getQuantity() * * @param string $quantity */ - public function setQuantity($quantity) + public function setQuantity(string $quantity) { $this->set("Quantity", $quantity); } - /** * SecurityGroupId: 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。 * @@ -267,11 +258,10 @@ public function getSecurityGroupId() * * @param string $securityGroupId */ - public function setSecurityGroupId($securityGroupId) + public function setSecurityGroupId(string $securityGroupId) { $this->set("SecurityGroupId", $securityGroupId); } - /** * Raid: Raid配置,默认Raid10 支持:Raid0、Raid1、Raid5、Raid10,NoRaid * @@ -287,11 +277,10 @@ public function getRaid() * * @param string $raid */ - public function setRaid($raid) + public function setRaid(string $raid) { $this->set("Raid", $raid); } - /** * VPCId: VPC ID,不填为默认,VPC2.0下需要填写此字段。 * @@ -307,11 +296,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网ID,不填为默认,VPC2.0下需要填写此字段。 * @@ -327,11 +315,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Cluster: 网络环境,可选千兆:1G ,万兆:10G, 默认1G。智能网卡可以选择25G。 * @@ -347,15 +334,14 @@ public function getCluster() * * @param string $cluster */ - public function setCluster($cluster) + public function setCluster(string $cluster) { $this->set("Cluster", $cluster); } - /** * Disks: * - * @return CreatePHostParamDisks[]|null + * @return CreatePHostRequestDisksModel[]|null */ public function getDisks() { @@ -365,7 +351,7 @@ public function getDisks() } $result = []; foreach ($items as $i => $item) { - array_push($result, new CreatePHostParamDisks($item)); + array_push($result, new CreatePHostRequestDisksModel($item)); } return $result; } @@ -373,7 +359,7 @@ public function getDisks() /** * Disks: * - * @param CreatePHostParamDisks[] $disks + * @param CreatePHostRequestDisksModel[] $disks */ public function setDisks(array $disks) { @@ -383,7 +369,6 @@ public function setDisks(array $disks) } return $result; } - /** * VpcIp: 指定内网ip创建 * @@ -399,11 +384,10 @@ public function getVpcIp() * * @param string $vpcIp */ - public function setVpcIp($vpcIp) + public function setVpcIp(string $vpcIp) { $this->set("VpcIp", $vpcIp); } - /** * CouponId: 代金券 * @@ -419,7 +403,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UPHost/Apis/CreatePHostResponse.php b/src/UPHost/Apis/CreatePHostResponse.php index 51ffed5d..a646874a 100644 --- a/src/UPHost/Apis/CreatePHostResponse.php +++ b/src/UPHost/Apis/CreatePHostResponse.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 具体机型。若不填写,则返回全部机型 * @@ -104,7 +102,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/UPHost/Apis/DescribeBaremetalMachineTypeResponse.php b/src/UPHost/Apis/DescribeBaremetalMachineTypeResponse.php index 35ed01ca..776fb00b 100644 --- a/src/UPHost/Apis/DescribeBaremetalMachineTypeResponse.php +++ b/src/UPHost/Apis/DescribeBaremetalMachineTypeResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new PHostCloudMachineTypeSet($item)); + array_push($result, new PHostCloudMachineTypeSetModel($item)); } return $result; } @@ -47,7 +49,7 @@ public function getMachineTypes() /** * MachineTypes: 机型列表,模型:PHostCloudMachineTypeSet * - * @param PHostCloudMachineTypeSet[] $machineTypes + * @param PHostCloudMachineTypeSetModel[] $machineTypes */ public function setMachineTypes(array $machineTypes) { diff --git a/src/UPHost/Apis/DescribePHostImageRequest.php b/src/UPHost/Apis/DescribePHostImageRequest.php index 0bfa8f98..0d908bff 100644 --- a/src/UPHost/Apis/DescribePHostImageRequest.php +++ b/src/UPHost/Apis/DescribePHostImageRequest.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -40,17 +41,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -60,17 +60,16 @@ public function getZone() } /** - * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -80,17 +79,16 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** - * ImageType: 镜像类别,枚举值,Base是基础镜像; + * ImageType: 镜像类别,枚举值,Base是基础镜像;Custom是自制镜像。 * * @return string|null */ @@ -100,15 +98,14 @@ public function getImageType() } /** - * ImageType: 镜像类别,枚举值,Base是基础镜像; + * ImageType: 镜像类别,枚举值,Base是基础镜像;Custom是自制镜像。 * * @param string $imageType */ - public function setImageType($imageType) + public function setImageType(string $imageType) { $this->set("ImageType", $imageType); } - /** * ImageId: 镜像ID * @@ -128,7 +125,6 @@ public function setImageId(array $imageId) { $this->set("ImageId", $imageId); } - /** * Offset: 数据偏移量,默认为0 * @@ -144,11 +140,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20 * @@ -164,11 +159,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * MachineType: 机器型号,只支持当前zone的展示机型 * @@ -184,7 +178,7 @@ public function getMachineType() * * @param string $machineType */ - public function setMachineType($machineType) + public function setMachineType(string $machineType) { $this->set("MachineType", $machineType); } diff --git a/src/UPHost/Apis/DescribePHostImageResponse.php b/src/UPHost/Apis/DescribePHostImageResponse.php index 9d58d7c1..6a8e6065 100644 --- a/src/UPHost/Apis/DescribePHostImageResponse.php +++ b/src/UPHost/Apis/DescribePHostImageResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * ImageSet: 镜像列表 PHostImageSet * - * @return PHostImageSet[]|null + * @return PHostImageSetModel[]|null */ public function getImageSet() { @@ -56,7 +57,7 @@ public function getImageSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostImageSet($item)); + array_push($result, new PHostImageSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getImageSet() /** * ImageSet: 镜像列表 PHostImageSet * - * @param PHostImageSet[] $imageSet + * @param PHostImageSetModel[] $imageSet */ public function setImageSet(array $imageSet) { diff --git a/src/UPHost/Apis/DescribePHostMachineTypeRequest.php b/src/UPHost/Apis/DescribePHostMachineTypeRequest.php index 47993996..230273cb 100644 --- a/src/UPHost/Apis/DescribePHostMachineTypeRequest.php +++ b/src/UPHost/Apis/DescribePHostMachineTypeRequest.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Type: 具体机型。若不填写,则返回全部机型 * @@ -104,7 +102,7 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } diff --git a/src/UPHost/Apis/DescribePHostMachineTypeResponse.php b/src/UPHost/Apis/DescribePHostMachineTypeResponse.php index 6d48dc14..1682789d 100644 --- a/src/UPHost/Apis/DescribePHostMachineTypeResponse.php +++ b/src/UPHost/Apis/DescribePHostMachineTypeResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new PHostMachineTypeSet($item)); + array_push($result, new PHostMachineTypeSetModel($item)); } return $result; } @@ -48,7 +50,7 @@ public function getMachineTypes() /** * MachineTypes: 机型列表,模型:PHostMachineTypeSet * - * @param PHostMachineTypeSet[] $machineTypes + * @param PHostMachineTypeSetModel[] $machineTypes */ public function setMachineTypes(array $machineTypes) { diff --git a/src/UPHost/Apis/DescribePHostRequest.php b/src/UPHost/Apis/DescribePHostRequest.php index 3ff4f654..a53d16f3 100644 --- a/src/UPHost/Apis/DescribePHostRequest.php +++ b/src/UPHost/Apis/DescribePHostRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID,若为空,则返回当前Region所有PHost。 * @@ -107,7 +105,6 @@ public function setPHostId(array $pHostId) { $this->set("PHostId", $pHostId); } - /** * Offset: 数据偏移量,默认为0 * @@ -123,11 +120,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 返回数据长度,默认为20 * @@ -143,11 +139,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * UDiskIdForAttachment: 要挂载的云盘id,过滤返回能被UDiskId挂载的云主机。目前主要针对rssd云盘使用 * @@ -163,11 +158,10 @@ public function getUDiskIdForAttachment() * * @param string $uDiskIdForAttachment */ - public function setUDiskIdForAttachment($uDiskIdForAttachment) + public function setUDiskIdForAttachment(string $uDiskIdForAttachment) { $this->set("UDiskIdForAttachment", $uDiskIdForAttachment); } - /** * VPCId: ULB使用参数,获取同VPC下机器信息。 * @@ -183,7 +177,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/UPHost/Apis/DescribePHostResponse.php b/src/UPHost/Apis/DescribePHostResponse.php index 123076eb..2155d361 100644 --- a/src/UPHost/Apis/DescribePHostResponse.php +++ b/src/UPHost/Apis/DescribePHostResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * PHostSet: PHost资源列表,参见 PHostSet * - * @return PHostSet[]|null + * @return PHostSetModel[]|null */ public function getPHostSet() { @@ -59,7 +60,7 @@ public function getPHostSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostSet($item)); + array_push($result, new PHostSetModel($item)); } return $result; } @@ -67,7 +68,7 @@ public function getPHostSet() /** * PHostSet: PHost资源列表,参见 PHostSet * - * @param PHostSet[] $pHostSet + * @param PHostSetModel[] $pHostSet */ public function setPHostSet(array $pHostSet) { diff --git a/src/UPHost/Apis/DescribePHostTagsRequest.php b/src/UPHost/Apis/DescribePHostTagsRequest.php index c07b9b3f..edc1c250 100644 --- a/src/UPHost/Apis/DescribePHostTagsRequest.php +++ b/src/UPHost/Apis/DescribePHostTagsRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -83,7 +82,7 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } diff --git a/src/UPHost/Apis/DescribePHostTagsResponse.php b/src/UPHost/Apis/DescribePHostTagsResponse.php index aa899855..8d4a2c57 100644 --- a/src/UPHost/Apis/DescribePHostTagsResponse.php +++ b/src/UPHost/Apis/DescribePHostTagsResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * TagSet: 具体参见 PHostTagSet * - * @return PHostTagSet[]|null + * @return PHostTagSetModel[]|null */ public function getTagSet() { @@ -56,7 +57,7 @@ public function getTagSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostTagSet($item)); + array_push($result, new PHostTagSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getTagSet() /** * TagSet: 具体参见 PHostTagSet * - * @param PHostTagSet[] $tagSet + * @param PHostTagSetModel[] $tagSet */ public function setTagSet(array $tagSet) { diff --git a/src/UPHost/Apis/GetPHostDiskUpgradePriceRequest.php b/src/UPHost/Apis/GetPHostDiskUpgradePriceRequest.php index 029b569e..66fe3fad 100644 --- a/src/UPHost/Apis/GetPHostDiskUpgradePriceRequest.php +++ b/src/UPHost/Apis/GetPHostDiskUpgradePriceRequest.php @@ -1,6 +1,7 @@ markRequired("DiskSpace"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: UPHost实例ID。 * @@ -106,11 +104,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * DiskSpace: 磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 * @@ -126,11 +123,10 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } - /** * UDiskId: 磁盘 ID。获取扩容价格必填(只能扩不能减);重装时候不需要填(根据所选盘大小决定) * @@ -146,11 +142,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * ReinstallTag: 是否重装价格获取。复用此接口。扩容只能增加云盘大小。重装不限制。枚举值:true/false * @@ -166,7 +161,7 @@ public function getReinstallTag() * * @param boolean $reinstallTag */ - public function setReinstallTag($reinstallTag) + public function setReinstallTag(bool $reinstallTag) { $this->set("ReinstallTag", $reinstallTag); } diff --git a/src/UPHost/Apis/GetPHostDiskUpgradePriceResponse.php b/src/UPHost/Apis/GetPHostDiskUpgradePriceResponse.php index 506df73c..92557ded 100644 --- a/src/UPHost/Apis/GetPHostDiskUpgradePriceResponse.php +++ b/src/UPHost/Apis/GetPHostDiskUpgradePriceResponse.php @@ -1,6 +1,7 @@ set("Price", $price); } - /** * OriginalPrice: 升价差价原价。精度为小数点后2位。 * @@ -57,7 +57,7 @@ public function getOriginalPrice() * * @param float $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(float $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UPHost/Apis/GetPHostPriceRequest.php b/src/UPHost/Apis/GetPHostPriceRequest.php index 82a57967..7e300686 100644 --- a/src/UPHost/Apis/GetPHostPriceRequest.php +++ b/src/UPHost/Apis/GetPHostPriceRequest.php @@ -1,6 +1,7 @@ markRequired("Quantity"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -67,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -87,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Count: 购买数量,范围[1-5] * @@ -107,11 +106,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * ChargeType: 计费模式,枚举值为: Year/Month * @@ -127,11 +125,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * Quantity: 购买时长,1-10个月或1-10年;默认值为1。月付时,此参数传0,代表购买至月末,1代表整月。 * @@ -147,11 +144,10 @@ public function getQuantity() * * @param int $quantity */ - public function setQuantity($quantity) + public function setQuantity(int $quantity) { $this->set("Quantity", $quantity); } - /** * Cluster: 网络环境,可选千兆:1G ;万兆:10G;25G网络:25G。 * @@ -167,11 +163,10 @@ public function getCluster() * * @param string $cluster */ - public function setCluster($cluster) + public function setCluster(string $cluster) { $this->set("Cluster", $cluster); } - /** * Type: 默认为:DB(数据库型),可以通过接口 [DescribePHostMachineType](api/uphost-api/describe_phost_machine_type.html)获取 * @@ -187,15 +182,14 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Disks: * - * @return GetPHostPriceParamDisks[]|null + * @return GetPHostPriceRequestDisksModel[]|null */ public function getDisks() { @@ -205,7 +199,7 @@ public function getDisks() } $result = []; foreach ($items as $i => $item) { - array_push($result, new GetPHostPriceParamDisks($item)); + array_push($result, new GetPHostPriceRequestDisksModel($item)); } return $result; } @@ -213,7 +207,7 @@ public function getDisks() /** * Disks: * - * @param GetPHostPriceParamDisks[] $disks + * @param GetPHostPriceRequestDisksModel[] $disks */ public function setDisks(array $disks) { diff --git a/src/UPHost/Apis/GetPHostPriceResponse.php b/src/UPHost/Apis/GetPHostPriceResponse.php index 57a4e1ef..66eac4c9 100644 --- a/src/UPHost/Apis/GetPHostPriceResponse.php +++ b/src/UPHost/Apis/GetPHostPriceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new PHostPriceSet($item)); + array_push($result, new PHostPriceSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getPriceSet() /** * PriceSet: 价格列表 见 PHostPriceSet * - * @param PHostPriceSet[] $priceSet + * @param PHostPriceSetModel[] $priceSet */ public function setPriceSet(array $priceSet) { diff --git a/src/UPHost/Apis/ModifyPHostImageInfoRequest.php b/src/UPHost/Apis/ModifyPHostImageInfoRequest.php new file mode 100644 index 00000000..f750adab --- /dev/null +++ b/src/UPHost/Apis/ModifyPHostImageInfoRequest.php @@ -0,0 +1,148 @@ + "ModifyPHostImageInfo"]); + $this->markRequired("Region"); + $this->markRequired("Zone"); + $this->markRequired("ImageId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * ImageId: 镜像ID + * + * @return string|null + */ + public function getImageId() + { + return $this->get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } + /** + * Name: 镜像名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 镜像名称 + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } +} diff --git a/src/UPHost/Apis/ModifyPHostImageInfoResponse.php b/src/UPHost/Apis/ModifyPHostImageInfoResponse.php new file mode 100644 index 00000000..6dd8192a --- /dev/null +++ b/src/UPHost/Apis/ModifyPHostImageInfoResponse.php @@ -0,0 +1,45 @@ +get("ImageId"); + } + + /** + * ImageId: 镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } +} diff --git a/src/UPHost/Apis/ModifyPHostInfoRequest.php b/src/UPHost/Apis/ModifyPHostInfoRequest.php index c328f126..f157d715 100644 --- a/src/UPHost/Apis/ModifyPHostInfoRequest.php +++ b/src/UPHost/Apis/ModifyPHostInfoRequest.php @@ -1,6 +1,7 @@ markRequired("PHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: 物理机资源ID * @@ -104,11 +102,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * Name: 物理机名称,默认不更改 * @@ -124,11 +121,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 物理机备注,默认不更改 * @@ -144,11 +140,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组,默认不更改 * @@ -164,7 +159,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/UPHost/Apis/ModifyPHostInfoResponse.php b/src/UPHost/Apis/ModifyPHostInfoResponse.php index b03d81d5..1218c183 100644 --- a/src/UPHost/Apis/ModifyPHostInfoResponse.php +++ b/src/UPHost/Apis/ModifyPHostInfoResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/PoweroffPHostRequest.php b/src/UPHost/Apis/PoweroffPHostRequest.php index dbff5b4d..06d96ddc 100644 --- a/src/UPHost/Apis/PoweroffPHostRequest.php +++ b/src/UPHost/Apis/PoweroffPHostRequest.php @@ -1,6 +1,7 @@ markRequired("PHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID * @@ -105,7 +103,7 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/PoweroffPHostResponse.php b/src/UPHost/Apis/PoweroffPHostResponse.php index 4bccab8e..04809733 100644 --- a/src/UPHost/Apis/PoweroffPHostResponse.php +++ b/src/UPHost/Apis/PoweroffPHostResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/RebootPHostRequest.php b/src/UPHost/Apis/RebootPHostRequest.php index fb5aa891..3f6fdaf6 100644 --- a/src/UPHost/Apis/RebootPHostRequest.php +++ b/src/UPHost/Apis/RebootPHostRequest.php @@ -1,6 +1,7 @@ markRequired("PHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID * @@ -105,7 +103,7 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/RebootPHostResponse.php b/src/UPHost/Apis/RebootPHostResponse.php index e4dd041c..e4d60b13 100644 --- a/src/UPHost/Apis/RebootPHostResponse.php +++ b/src/UPHost/Apis/RebootPHostResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/ReinstallPHostRequest.php b/src/UPHost/Apis/ReinstallPHostRequest.php index 8cf5d6e3..e886bea1 100644 --- a/src/UPHost/Apis/ReinstallPHostRequest.php +++ b/src/UPHost/Apis/ReinstallPHostRequest.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID * @@ -106,11 +104,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * Password: 密码 * @@ -126,11 +123,10 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } - /** * ImageId: 镜像Id,参考镜像列表,默认使用原镜像 * @@ -146,11 +142,10 @@ public function getImageId() * * @param string $imageId */ - public function setImageId($imageId) + public function setImageId(string $imageId) { $this->set("ImageId", $imageId); } - /** * Name: 物理机名称,默认不更改 * @@ -166,11 +161,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 物理机备注,默认为不更改。 * @@ -186,11 +180,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组,默认不更改。 * @@ -206,11 +199,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ReserveDisk: 是否保留数据盘,保留:Yes,不报留:No, 默认:Yes * @@ -226,11 +218,10 @@ public function getReserveDisk() * * @param string $reserveDisk */ - public function setReserveDisk($reserveDisk) + public function setReserveDisk(string $reserveDisk) { $this->set("ReserveDisk", $reserveDisk); } - /** * Raid: 不保留数据盘重装,可选Raid * @@ -246,11 +237,10 @@ public function getRaid() * * @param string $raid */ - public function setRaid($raid) + public function setRaid(string $raid) { $this->set("Raid", $raid); } - /** * BootDiskSpace: 裸金属机型参数->系统盘大小。 单位:GB, 范围[20,500], 步长:10 * @@ -266,7 +256,7 @@ public function getBootDiskSpace() * * @param int $bootDiskSpace */ - public function setBootDiskSpace($bootDiskSpace) + public function setBootDiskSpace(int $bootDiskSpace) { $this->set("BootDiskSpace", $bootDiskSpace); } diff --git a/src/UPHost/Apis/ReinstallPHostResponse.php b/src/UPHost/Apis/ReinstallPHostResponse.php index ff976a9b..72fec3ca 100644 --- a/src/UPHost/Apis/ReinstallPHostResponse.php +++ b/src/UPHost/Apis/ReinstallPHostResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/ResetPHostPasswordRequest.php b/src/UPHost/Apis/ResetPHostPasswordRequest.php index 1691bbf3..6e9ce5d9 100644 --- a/src/UPHost/Apis/ResetPHostPasswordRequest.php +++ b/src/UPHost/Apis/ResetPHostPasswordRequest.php @@ -1,6 +1,7 @@ markRequired("Password"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -66,11 +66,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -86,11 +85,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: 裸金属实例ID * @@ -106,11 +104,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * Password: PHost新密码(密码格式使用BASE64编码) * @@ -126,7 +123,7 @@ public function getPassword() * * @param string $password */ - public function setPassword($password) + public function setPassword(string $password) { $this->set("Password", $password); } diff --git a/src/UPHost/Apis/ResetPHostPasswordResponse.php b/src/UPHost/Apis/ResetPHostPasswordResponse.php index 226cf30d..b51c8f29 100644 --- a/src/UPHost/Apis/ResetPHostPasswordResponse.php +++ b/src/UPHost/Apis/ResetPHostPasswordResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/ResizePHostAttachedDiskRequest.php b/src/UPHost/Apis/ResizePHostAttachedDiskRequest.php index 13f1933c..079ddffd 100644 --- a/src/UPHost/Apis/ResizePHostAttachedDiskRequest.php +++ b/src/UPHost/Apis/ResizePHostAttachedDiskRequest.php @@ -1,6 +1,7 @@ markRequired("Zone"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: UPHost实例ID。 * @@ -104,11 +102,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * UDiskId: 磁盘ID。 * @@ -124,11 +121,10 @@ public function getUDiskId() * * @param string $uDiskId */ - public function setUDiskId($uDiskId) + public function setUDiskId(string $uDiskId) { $this->set("UDiskId", $uDiskId); } - /** * DiskSpace: 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 * @@ -144,7 +140,7 @@ public function getDiskSpace() * * @param int $diskSpace */ - public function setDiskSpace($diskSpace) + public function setDiskSpace(int $diskSpace) { $this->set("DiskSpace", $diskSpace); } diff --git a/src/UPHost/Apis/ResizePHostAttachedDiskResponse.php b/src/UPHost/Apis/ResizePHostAttachedDiskResponse.php index 6e831a2d..75223cd3 100644 --- a/src/UPHost/Apis/ResizePHostAttachedDiskResponse.php +++ b/src/UPHost/Apis/ResizePHostAttachedDiskResponse.php @@ -1,6 +1,7 @@ set("UDiskId", $uDiskId); } diff --git a/src/UPHost/Apis/StartPHostRequest.php b/src/UPHost/Apis/StartPHostRequest.php index 3fb3b95d..ac3f7775 100644 --- a/src/UPHost/Apis/StartPHostRequest.php +++ b/src/UPHost/Apis/StartPHostRequest.php @@ -1,6 +1,7 @@ markRequired("PHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID * @@ -105,7 +103,7 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/StartPHostResponse.php b/src/UPHost/Apis/StartPHostResponse.php index b8bd6b91..98fa6b20 100644 --- a/src/UPHost/Apis/StartPHostResponse.php +++ b/src/UPHost/Apis/StartPHostResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Apis/StopPHostRequest.php b/src/UPHost/Apis/StopPHostRequest.php new file mode 100644 index 00000000..fc1c030d --- /dev/null +++ b/src/UPHost/Apis/StopPHostRequest.php @@ -0,0 +1,110 @@ + "StopPHost"]); + $this->markRequired("Region"); + $this->markRequired("ProjectId"); + $this->markRequired("PHostId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * PHostId: PHost资源ID + * + * @return string|null + */ + public function getPHostId() + { + return $this->get("PHostId"); + } + + /** + * PHostId: PHost资源ID + * + * @param string $pHostId + */ + public function setPHostId(string $pHostId) + { + $this->set("PHostId", $pHostId); + } +} diff --git a/src/UPHost/Apis/StopPHostResponse.php b/src/UPHost/Apis/StopPHostResponse.php new file mode 100644 index 00000000..746afd24 --- /dev/null +++ b/src/UPHost/Apis/StopPHostResponse.php @@ -0,0 +1,45 @@ +get("PHostId"); + } + + /** + * PHostId: PHost 的资源ID + * + * @param string $pHostId + */ + public function setPHostId(string $pHostId) + { + $this->set("PHostId", $pHostId); + } +} diff --git a/src/UPHost/Apis/TerminatePHostImageRequest.php b/src/UPHost/Apis/TerminatePHostImageRequest.php new file mode 100644 index 00000000..ad007819 --- /dev/null +++ b/src/UPHost/Apis/TerminatePHostImageRequest.php @@ -0,0 +1,110 @@ + "TerminatePHostImage"]); + $this->markRequired("Region"); + $this->markRequired("Zone"); + $this->markRequired("ImageId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getZone() + { + return $this->get("Zone"); + } + + /** + * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $zone + */ + public function setZone(string $zone) + { + $this->set("Zone", $zone); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * ImageId: 自制镜像ID + * + * @return string|null + */ + public function getImageId() + { + return $this->get("ImageId"); + } + + /** + * ImageId: 自制镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } +} diff --git a/src/UPHost/Apis/TerminatePHostImageResponse.php b/src/UPHost/Apis/TerminatePHostImageResponse.php new file mode 100644 index 00000000..56e96ca4 --- /dev/null +++ b/src/UPHost/Apis/TerminatePHostImageResponse.php @@ -0,0 +1,45 @@ +get("ImageId"); + } + + /** + * ImageId: 自制镜像ID + * + * @param string $imageId + */ + public function setImageId(string $imageId) + { + $this->set("ImageId", $imageId); + } +} diff --git a/src/UPHost/Apis/TerminatePHostRequest.php b/src/UPHost/Apis/TerminatePHostRequest.php index c56c01b1..0a394ebc 100644 --- a/src/UPHost/Apis/TerminatePHostRequest.php +++ b/src/UPHost/Apis/TerminatePHostRequest.php @@ -1,6 +1,7 @@ markRequired("PHostId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PHostId: PHost资源ID * @@ -105,11 +103,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * ReleaseEIP: 是否释放绑定的EIP。true: 解绑EIP后,并释放;其他值或不填:解绑EIP。 * @@ -125,11 +122,10 @@ public function getReleaseEIP() * * @param boolean $releaseEIP */ - public function setReleaseEIP($releaseEIP) + public function setReleaseEIP(bool $releaseEIP) { $this->set("ReleaseEIP", $releaseEIP); } - /** * ReleaseUDisk: 裸金属机型参数->删除主机时是否同时删除挂载的数据盘。默认为false。 * @@ -145,7 +141,7 @@ public function getReleaseUDisk() * * @param boolean $releaseUDisk */ - public function setReleaseUDisk($releaseUDisk) + public function setReleaseUDisk(bool $releaseUDisk) { $this->set("ReleaseUDisk", $releaseUDisk); } diff --git a/src/UPHost/Apis/TerminatePHostResponse.php b/src/UPHost/Apis/TerminatePHostResponse.php index 07efbe30..75d261e2 100644 --- a/src/UPHost/Apis/TerminatePHostResponse.php +++ b/src/UPHost/Apis/TerminatePHostResponse.php @@ -1,6 +1,7 @@ set("PHostId", $pHostId); } diff --git a/src/UPHost/Params/CreatePHostParamDisks.php b/src/UPHost/Models/CreatePHostRequestDisks.php similarity index 87% rename from src/UPHost/Params/CreatePHostParamDisks.php rename to src/UPHost/Models/CreatePHostRequestDisks.php index 61ea0a05..cb12b659 100644 --- a/src/UPHost/Params/CreatePHostParamDisks.php +++ b/src/UPHost/Models/CreatePHostRequestDisks.php @@ -1,6 +1,7 @@ 是否是系统盘。枚举值: True,是系统盘。 False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 @@ -37,11 +40,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * Type: 裸金属机型参数->磁盘类型:枚举值:CLOUD_RSSD * @@ -57,11 +59,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Size: 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 * @@ -77,11 +78,10 @@ public function getSize() * * @param int $size */ - public function setSize($size) + public function setSize(int $size) { $this->set("Size", $size); } - /** * CouponId: 裸金属机型参数->云盘代金券id。不适用于系统盘。请通过DescribeCoupon接口查询,或登录用户中心查看 * @@ -97,7 +97,7 @@ public function getCouponId() * * @param string $couponId */ - public function setCouponId($couponId) + public function setCouponId(string $couponId) { $this->set("CouponId", $couponId); } diff --git a/src/UPHost/Params/GetPHostPriceParamDisks.php b/src/UPHost/Models/GetPHostPriceRequestDisks.php similarity index 85% rename from src/UPHost/Params/GetPHostPriceParamDisks.php rename to src/UPHost/Models/GetPHostPriceRequestDisks.php index b9df1487..dc38c179 100644 --- a/src/UPHost/Params/GetPHostPriceParamDisks.php +++ b/src/UPHost/Models/GetPHostPriceRequestDisks.php @@ -1,6 +1,7 @@ 枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 @@ -37,11 +40,10 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } - /** * Type: 裸金属机型参数->磁盘类型:枚举值:CLOUD_RSSD * @@ -57,11 +59,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Size: 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB。数据盘是20-32000G。 * @@ -77,7 +78,7 @@ public function getSize() * * @param string $size */ - public function setSize($size) + public function setSize(string $size) { $this->set("Size", $size); } diff --git a/src/UPHost/Models/PHostCPUSet.php b/src/UPHost/Models/PHostCPUSet.php index ca09cb18..752a58e7 100644 --- a/src/UPHost/Models/PHostCPUSet.php +++ b/src/UPHost/Models/PHostCPUSet.php @@ -1,6 +1,7 @@ set("Model", $model); } - /** * Frequence: CPU主频 * @@ -57,11 +64,10 @@ public function getFrequence() * * @param float $frequence */ - public function setFrequence($frequence) + public function setFrequence(float $frequence) { $this->set("Frequence", $frequence); } - /** * Count: CPU个数 * @@ -77,11 +83,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * CoreCount: CPU核数 * @@ -97,7 +102,7 @@ public function getCoreCount() * * @param int $coreCount */ - public function setCoreCount($coreCount) + public function setCoreCount(int $coreCount) { $this->set("CoreCount", $coreCount); } diff --git a/src/UPHost/Models/PHostCloudMachineTypeSet.php b/src/UPHost/Models/PHostCloudMachineTypeSet.php index a0912b1b..7d56596b 100644 --- a/src/UPHost/Models/PHostCloudMachineTypeSet.php +++ b/src/UPHost/Models/PHostCloudMachineTypeSet.php @@ -1,6 +1,7 @@ set("Type", $type); } - /** * CPU: CPU信息 * - * @return PHostCPUSet|null + * @return PHostCPUSetModel|null */ public function getCPU() { - return new PHostCPUSet($this->get("CPU")); + return new PHostCPUSetModel($this->get("CPU")); } /** * CPU: CPU信息 * - * @param PHostCPUSet $cpu + * @param PHostCPUSetModel $cpu */ - public function setCPU(array $cpu) + public function setCPU(PHostCPUSetModel $cpu) { $this->set("CPU", $cpu->getAll()); } - /** * Memory: 内存大小,单位MB * @@ -77,35 +81,33 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * Components: 其他组件信息 * - * @return PHostComponentSet|null + * @return PHostComponentSetModel|null */ public function getComponents() { - return new PHostComponentSet($this->get("Components")); + return new PHostComponentSetModel($this->get("Components")); } /** * Components: 其他组件信息 * - * @param PHostComponentSet $components + * @param PHostComponentSetModel $components */ - public function setComponents(array $components) + public function setComponents(PHostComponentSetModel $components) { $this->set("Components", $components->getAll()); } - /** * Clusters: 集群库存信息 * - * @return PHostClusterSet[]|null + * @return PHostClusterSetModel[]|null */ public function getClusters() { @@ -115,7 +117,7 @@ public function getClusters() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostClusterSet($item)); + array_push($result, new PHostClusterSetModel($item)); } return $result; } @@ -123,7 +125,7 @@ public function getClusters() /** * Clusters: 集群库存信息 * - * @param PHostClusterSet[] $clusters + * @param PHostClusterSetModel[] $clusters */ public function setClusters(array $clusters) { diff --git a/src/UPHost/Models/PHostClusterSet.php b/src/UPHost/Models/PHostClusterSet.php index e08746c7..9fd55295 100644 --- a/src/UPHost/Models/PHostClusterSet.php +++ b/src/UPHost/Models/PHostClusterSet.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * StockStatus: 库存状态。枚举值:有库存:Available;无库存:SoldOut * @@ -57,7 +62,7 @@ public function getStockStatus() * * @param string $stockStatus */ - public function setStockStatus($stockStatus) + public function setStockStatus(string $stockStatus) { $this->set("StockStatus", $stockStatus); } diff --git a/src/UPHost/Models/PHostComponentSet.php b/src/UPHost/Models/PHostComponentSet.php index 4f073371..6e9deb5e 100644 --- a/src/UPHost/Models/PHostComponentSet.php +++ b/src/UPHost/Models/PHostComponentSet.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * Count: 组件数量 * @@ -57,7 +62,7 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } diff --git a/src/UPHost/Models/PHostDescDiskSet.php b/src/UPHost/Models/PHostDescDiskSet.php index 8bdf9846..f87f9555 100644 --- a/src/UPHost/Models/PHostDescDiskSet.php +++ b/src/UPHost/Models/PHostDescDiskSet.php @@ -1,6 +1,7 @@ set("Space", $space); } - /** * Count: 磁盘数量 * @@ -57,11 +60,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Type: 磁盘属性 * @@ -77,11 +79,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Name: 磁盘名称,sys/data * @@ -97,11 +98,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * IOCap: 磁盘IO性能,单位MB/s(待废弃) * @@ -117,11 +117,10 @@ public function getIOCap() * * @param int $ioCap */ - public function setIOCap($ioCap) + public function setIOCap(int $ioCap) { $this->set("IOCap", $ioCap); } - /** * Drive: 裸金属机型参数:磁盘盘符 * @@ -137,11 +136,10 @@ public function getDrive() * * @param string $drive */ - public function setDrive($drive) + public function setDrive(string $drive) { $this->set("Drive", $drive); } - /** * DiskId: 裸金属机型参数:磁盘ID * @@ -157,11 +155,10 @@ public function getDiskId() * * @param string $diskId */ - public function setDiskId($diskId) + public function setDiskId(string $diskId) { $this->set("DiskId", $diskId); } - /** * IsBoot: 裸金属机型参数:是否是启动盘。True/False * @@ -177,7 +174,7 @@ public function getIsBoot() * * @param string $isBoot */ - public function setIsBoot($isBoot) + public function setIsBoot(string $isBoot) { $this->set("IsBoot", $isBoot); } diff --git a/src/UPHost/Models/PHostDiskSet.php b/src/UPHost/Models/PHostDiskSet.php index 5786758b..8f250446 100644 --- a/src/UPHost/Models/PHostDiskSet.php +++ b/src/UPHost/Models/PHostDiskSet.php @@ -1,6 +1,7 @@ set("Space", $space); } - /** * Count: 磁盘数量 * @@ -57,11 +60,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Type: 磁盘属性 * @@ -77,11 +79,10 @@ public function getType() * * @param string $type */ - public function setType($type) + public function setType(string $type) { $this->set("Type", $type); } - /** * Name: 磁盘名称,sys/data * @@ -97,11 +98,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * IOCap: 磁盘IO性能,单位MB/s(待废弃) * @@ -117,7 +117,7 @@ public function getIOCap() * * @param int $ioCap */ - public function setIOCap($ioCap) + public function setIOCap(int $ioCap) { $this->set("IOCap", $ioCap); } diff --git a/src/UPHost/Models/PHostIPSet.php b/src/UPHost/Models/PHostIPSet.php index f82550f8..f686ffa3 100644 --- a/src/UPHost/Models/PHostIPSet.php +++ b/src/UPHost/Models/PHostIPSet.php @@ -1,6 +1,7 @@ set("OperatorName", $operatorName); } - /** * IPId: IP资源ID(内网IP无资源ID)(待废弃) * @@ -57,11 +60,10 @@ public function getIPId() * * @param string $ipId */ - public function setIPId($ipId) + public function setIPId(string $ipId) { $this->set("IPId", $ipId); } - /** * IPAddr: IP地址, * @@ -77,11 +79,10 @@ public function getIPAddr() * * @param string $ipAddr */ - public function setIPAddr($ipAddr) + public function setIPAddr(string $ipAddr) { $this->set("IPAddr", $ipAddr); } - /** * MACAddr: MAC地址 * @@ -97,11 +98,10 @@ public function getMACAddr() * * @param string $macAddr */ - public function setMACAddr($macAddr) + public function setMACAddr(string $macAddr) { $this->set("MACAddr", $macAddr); } - /** * Bandwidth: IP对应带宽,单位Mb,内网IP不显示带宽信息 * @@ -117,11 +117,10 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * SubnetId: 子网ID * @@ -137,11 +136,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC ID * @@ -157,7 +155,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/UPHost/Models/PHostImageSet.php b/src/UPHost/Models/PHostImageSet.php index 1a8be54e..d1ee1886 100644 --- a/src/UPHost/Models/PHostImageSet.php +++ b/src/UPHost/Models/PHostImageSet.php @@ -1,6 +1,7 @@ set("ImageId", $imageId); } - /** * ImageName: 镜像名称 * @@ -57,11 +59,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * OsName: 操作系统名称 * @@ -77,11 +78,10 @@ public function getOsName() * * @param string $osName */ - public function setOsName($osName) + public function setOsName(string $osName) { $this->set("OsName", $osName); } - /** * OsType: 操作系统类型 * @@ -97,11 +97,10 @@ public function getOsType() * * @param string $osType */ - public function setOsType($osType) + public function setOsType(string $osType) { $this->set("OsType", $osType); } - /** * Support: 支持的机型 * @@ -121,7 +120,6 @@ public function setSupport(array $support) { $this->set("Support", $support); } - /** * Version: 当前版本 * @@ -137,8 +135,103 @@ public function getVersion() * * @param string $version */ - public function setVersion($version) + public function setVersion(string $version) { $this->set("Version", $version); } + /** + * ImageType: 枚举值:Base=>基础镜像,Custom=>自制镜像。 + * + * @return string|null + */ + public function getImageType() + { + return $this->get("ImageType"); + } + + /** + * ImageType: 枚举值:Base=>基础镜像,Custom=>自制镜像。 + * + * @param string $imageType + */ + public function setImageType(string $imageType) + { + $this->set("ImageType", $imageType); + } + /** + * CreateTime: 裸金属2.0参数。镜像创建时间。 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 裸金属2.0参数。镜像创建时间。 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * State: 裸金属2.0参数。镜像当前状态。 + * + * @return string|null + */ + public function getState() + { + return $this->get("State"); + } + + /** + * State: 裸金属2.0参数。镜像当前状态。 + * + * @param string $state + */ + public function setState(string $state) + { + $this->set("State", $state); + } + /** + * ImageSize: 裸金属2.0参数。镜像大小。 + * + * @return integer|null + */ + public function getImageSize() + { + return $this->get("ImageSize"); + } + + /** + * ImageSize: 裸金属2.0参数。镜像大小。 + * + * @param int $imageSize + */ + public function setImageSize(int $imageSize) + { + $this->set("ImageSize", $imageSize); + } + /** + * ImageDescription: 镜像描述 + * + * @return string|null + */ + public function getImageDescription() + { + return $this->get("ImageDescription"); + } + + /** + * ImageDescription: 镜像描述 + * + * @param string $imageDescription + */ + public function setImageDescription(string $imageDescription) + { + $this->set("ImageDescription", $imageDescription); + } } diff --git a/src/UPHost/Models/PHostMachineTypeSet.php b/src/UPHost/Models/PHostMachineTypeSet.php index a377046f..0596a474 100644 --- a/src/UPHost/Models/PHostMachineTypeSet.php +++ b/src/UPHost/Models/PHostMachineTypeSet.php @@ -1,6 +1,7 @@ set("Type", $type); } - /** * CPU: CPU信息 * - * @return PHostCPUSet|null + * @return PHostCPUSetModel|null */ public function getCPU() { - return new PHostCPUSet($this->get("CPU")); + return new PHostCPUSetModel($this->get("CPU")); } /** * CPU: CPU信息 * - * @param PHostCPUSet $cpu + * @param PHostCPUSetModel $cpu */ - public function setCPU(array $cpu) + public function setCPU(PHostCPUSetModel $cpu) { $this->set("CPU", $cpu->getAll()); } - /** * Memory: 内存大小,单位MB * @@ -77,15 +82,14 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * Disks: 磁盘信息 * - * @return PHostDiskSet[]|null + * @return PHostDiskSetModel[]|null */ public function getDisks() { @@ -95,7 +99,7 @@ public function getDisks() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostDiskSet($item)); + array_push($result, new PHostDiskSetModel($item)); } return $result; } @@ -103,7 +107,7 @@ public function getDisks() /** * Disks: 磁盘信息 * - * @param PHostDiskSet[] $disks + * @param PHostDiskSetModel[] $disks */ public function setDisks(array $disks) { @@ -113,31 +117,29 @@ public function setDisks(array $disks) } return $result; } - /** * Components: 其他组件信息 * - * @return PHostComponentSet|null + * @return PHostComponentSetModel|null */ public function getComponents() { - return new PHostComponentSet($this->get("Components")); + return new PHostComponentSetModel($this->get("Components")); } /** * Components: 其他组件信息 * - * @param PHostComponentSet $components + * @param PHostComponentSetModel $components */ - public function setComponents(array $components) + public function setComponents(PHostComponentSetModel $components) { $this->set("Components", $components->getAll()); } - /** * Clusters: 集群库存信息 * - * @return PHostClusterSet[]|null + * @return PHostClusterSetModel[]|null */ public function getClusters() { @@ -147,7 +149,7 @@ public function getClusters() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostClusterSet($item)); + array_push($result, new PHostClusterSetModel($item)); } return $result; } @@ -155,7 +157,7 @@ public function getClusters() /** * Clusters: 集群库存信息 * - * @param PHostClusterSet[] $clusters + * @param PHostClusterSetModel[] $clusters */ public function setClusters(array $clusters) { @@ -165,7 +167,6 @@ public function setClusters(array $clusters) } return $result; } - /** * RaidSupported: 是否支持Raid。枚举值:支持:YES;不支持:NO * @@ -181,7 +182,7 @@ public function getRaidSupported() * * @param string $raidSupported */ - public function setRaidSupported($raidSupported) + public function setRaidSupported(string $raidSupported) { $this->set("RaidSupported", $raidSupported); } diff --git a/src/UPHost/Models/PHostPriceSet.php b/src/UPHost/Models/PHostPriceSet.php index 31b62101..24dc3d63 100644 --- a/src/UPHost/Models/PHostPriceSet.php +++ b/src/UPHost/Models/PHostPriceSet.php @@ -1,6 +1,7 @@ set("ChargeType", $chargeType); } - /** * Price: 价格, 单位:元, 保留小数点后两位有效数字 * @@ -57,11 +59,10 @@ public function getPrice() * * @param float $price */ - public function setPrice($price) + public function setPrice(float $price) { $this->set("Price", $price); } - /** * Product: 枚举值:phost=>为主机价格,如果是云盘包括了系统盘价格。cloudDisk=>所有数据盘价格,只是裸金属机型才返回此参数。 * @@ -77,11 +78,10 @@ public function getProduct() * * @param string $product */ - public function setProduct($product) + public function setProduct(string $product) { $this->set("Product", $product); } - /** * OriginalPrice: 原价格, 单位:元, 保留小数点后两位有效数字 * @@ -97,7 +97,7 @@ public function getOriginalPrice() * * @param float $originalPrice */ - public function setOriginalPrice($originalPrice) + public function setOriginalPrice(float $originalPrice) { $this->set("OriginalPrice", $originalPrice); } diff --git a/src/UPHost/Models/PHostSet.php b/src/UPHost/Models/PHostSet.php index e8690968..0f1e1d2e 100644 --- a/src/UPHost/Models/PHostSet.php +++ b/src/UPHost/Models/PHostSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * PHostId: PHost资源ID * @@ -57,11 +62,10 @@ public function getPHostId() * * @param string $pHostId */ - public function setPHostId($pHostId) + public function setPHostId(string $pHostId) { $this->set("PHostId", $pHostId); } - /** * SN: 物理机序列号 * @@ -77,11 +81,10 @@ public function getSN() * * @param string $sn */ - public function setSN($sn) + public function setSN(string $sn) { $this->set("SN", $sn); } - /** * PMStatus: 物理云主机状态。枚举值:\\ > 初始化:Initializing; \\ > 启动中:Starting; \\ > 运行中:Running;\\ > 关机中:Stopping; \\ > 安装失败:InstallFailed; \\ > 重启中:Rebooting;\\ > 关机:Stopped; \\ > 迁移中(裸金属云盘):Migrating * @@ -97,11 +100,10 @@ public function getPMStatus() * * @param string $pmStatus */ - public function setPMStatus($pmStatus) + public function setPMStatus(string $pmStatus) { $this->set("PMStatus", $pmStatus); } - /** * Name: 物理机名称 * @@ -117,11 +119,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 物理机备注 * @@ -137,11 +138,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组 * @@ -157,11 +157,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * ImageName: 镜像名称 * @@ -177,11 +176,10 @@ public function getImageName() * * @param string $imageName */ - public function setImageName($imageName) + public function setImageName(string $imageName) { $this->set("ImageName", $imageName); } - /** * OSname: 操作系统名称 * @@ -197,11 +195,10 @@ public function getOSname() * * @param string $oSname */ - public function setOSname($oSname) + public function setOSname(string $oSname) { $this->set("OSname", $oSname); } - /** * CreateTime: 创建时间 * @@ -217,11 +214,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * ExpireTime: 到期时间 * @@ -237,11 +233,10 @@ public function getExpireTime() * * @param int $expireTime */ - public function setExpireTime($expireTime) + public function setExpireTime(int $expireTime) { $this->set("ExpireTime", $expireTime); } - /** * ChargeType: 计费模式,枚举值为: Year,按年付费; Month,按月付费;默认为月付 * @@ -257,11 +252,10 @@ public function getChargeType() * * @param string $chargeType */ - public function setChargeType($chargeType) + public function setChargeType(string $chargeType) { $this->set("ChargeType", $chargeType); } - /** * PowerState: 电源状态,on 或 off * @@ -277,11 +271,10 @@ public function getPowerState() * * @param string $powerState */ - public function setPowerState($powerState) + public function setPowerState(string $powerState) { $this->set("PowerState", $powerState); } - /** * PHostType: 物理机类型,参见DescribePHostMachineType返回值 * @@ -297,11 +290,10 @@ public function getPHostType() * * @param string $pHostType */ - public function setPHostType($pHostType) + public function setPHostType(string $pHostType) { $this->set("PHostType", $pHostType); } - /** * Memory: 内存大小,单位:MB * @@ -317,35 +309,33 @@ public function getMemory() * * @param int $memory */ - public function setMemory($memory) + public function setMemory(int $memory) { $this->set("Memory", $memory); } - /** * CPUSet: CPU信息,见 PHostCPUSet * - * @return PHostCPUSet|null + * @return PHostCPUSetModel|null */ public function getCPUSet() { - return new PHostCPUSet($this->get("CPUSet")); + return new PHostCPUSetModel($this->get("CPUSet")); } /** * CPUSet: CPU信息,见 PHostCPUSet * - * @param PHostCPUSet $cpuSet + * @param PHostCPUSetModel $cpuSet */ - public function setCPUSet(array $cpuSet) + public function setCPUSet(PHostCPUSetModel $cpuSet) { $this->set("CPUSet", $cpuSet->getAll()); } - /** * DiskSet: 磁盘信息,见 PHostDescDiskSet * - * @return PHostDescDiskSet[]|null + * @return PHostDescDiskSetModel[]|null */ public function getDiskSet() { @@ -355,7 +345,7 @@ public function getDiskSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostDescDiskSet($item)); + array_push($result, new PHostDescDiskSetModel($item)); } return $result; } @@ -363,7 +353,7 @@ public function getDiskSet() /** * DiskSet: 磁盘信息,见 PHostDescDiskSet * - * @param PHostDescDiskSet[] $diskSet + * @param PHostDescDiskSetModel[] $diskSet */ public function setDiskSet(array $diskSet) { @@ -373,11 +363,10 @@ public function setDiskSet(array $diskSet) } return $result; } - /** * IPSet: IP信息,见 PHostIPSet * - * @return PHostIPSet[]|null + * @return PHostIPSetModel[]|null */ public function getIPSet() { @@ -387,7 +376,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new PHostIPSet($item)); + array_push($result, new PHostIPSetModel($item)); } return $result; } @@ -395,7 +384,7 @@ public function getIPSet() /** * IPSet: IP信息,见 PHostIPSet * - * @param PHostIPSet[] $ipSet + * @param PHostIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -405,7 +394,6 @@ public function setIPSet(array $ipSet) } return $result; } - /** * Cluster: 网络环境。枚举值:千兆:1G ,万兆:10G * @@ -421,11 +409,10 @@ public function getCluster() * * @param string $cluster */ - public function setCluster($cluster) + public function setCluster(string $cluster) { $this->set("Cluster", $cluster); } - /** * AutoRenew: 自动续费 * @@ -441,11 +428,10 @@ public function getAutoRenew() * * @param string $autoRenew */ - public function setAutoRenew($autoRenew) + public function setAutoRenew(string $autoRenew) { $this->set("AutoRenew", $autoRenew); } - /** * IsSupportKVM: 是否支持紧急登录 * @@ -461,11 +447,10 @@ public function getIsSupportKVM() * * @param string $isSupportKVM */ - public function setIsSupportKVM($isSupportKVM) + public function setIsSupportKVM(string $isSupportKVM) { $this->set("IsSupportKVM", $isSupportKVM); } - /** * OSType: 操作系统类型 * @@ -481,11 +466,10 @@ public function getOSType() * * @param string $osType */ - public function setOSType($osType) + public function setOSType(string $osType) { $this->set("OSType", $osType); } - /** * Components: 组件信息(暂不支持) * @@ -501,11 +485,10 @@ public function getComponents() * * @param string $components */ - public function setComponents($components) + public function setComponents(string $components) { $this->set("Components", $components); } - /** * RaidSupported: 是否支持Raid。枚举值:Yes:支持;No:不支持。 * @@ -521,11 +504,10 @@ public function getRaidSupported() * * @param string $raidSupported */ - public function setRaidSupported($raidSupported) + public function setRaidSupported(string $raidSupported) { $this->set("RaidSupported", $raidSupported); } - /** * PhostClass: 物理云产品类型,枚举值:LocalDisk=>代表传统本地盘机型, CloudDisk=>云盘裸金属机型 * @@ -541,7 +523,7 @@ public function getPhostClass() * * @param string $phostClass */ - public function setPhostClass($phostClass) + public function setPhostClass(string $phostClass) { $this->set("PhostClass", $phostClass); } diff --git a/src/UPHost/Models/PHostTagSet.php b/src/UPHost/Models/PHostTagSet.php index 796f3d85..6ef06744 100644 --- a/src/UPHost/Models/PHostTagSet.php +++ b/src/UPHost/Models/PHostTagSet.php @@ -1,6 +1,7 @@ set("Tag", $tag); } - /** * TotalCount: 该业务组中包含的主机个数 * @@ -57,7 +59,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/UPHost/UPHostClient.php b/src/UPHost/UPHostClient.php index 4301e6bf..7ccf1b46 100644 --- a/src/UPHost/UPHostClient.php +++ b/src/UPHost/UPHostClient.php @@ -1,6 +1,7 @@ (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "ImageId" => (string) ImageId,可以通过接口 [DescribePHostImage](api/uphost-api/describe_phost_image.html)获取 - * "Password" => (string) 密码(密码需使用base64进行编码) - * "Type" => (string) 物理机类型,默认为:db-2(基础型-SAS-V3) - * "Name" => (string) 物理机名称,默认为phost - * "Remark" => (string) 物理机备注,默认为空 - * "Tag" => (string) 业务组,默认为default - * "ChargeType" => (string) 计费模式,枚举值为:year, 按年付费; month,按月付费;默认为按月付费 - * "Quantity" => (string) 购买时长,1-10个月或1-10年;默认值为1。月付时,此参数传0,代表购买至月末,1代表整月。 - * "SecurityGroupId" => (string) 防火墙ID,默认:Web推荐防火墙。如何查询SecurityGroupId请参见 [DescribeFirewall](api/unet-api/describe_firewall.html)。 - * "Raid" => (string) Raid配置,默认Raid10 支持:Raid0、Raid1、Raid5、Raid10,NoRaid - * "VPCId" => (string) VPC ID,不填为默认,VPC2.0下需要填写此字段。 - * "SubnetId" => (string) 子网ID,不填为默认,VPC2.0下需要填写此字段。 - * "Cluster" => (string) 网络环境,可选千兆:1G ,万兆:10G, 默认1G。智能网卡可以选择25G。 - * "Disks" => (array) [ - * [ - * "IsBoot" => (string) 裸金属机型参数->是否是系统盘。枚举值: True,是系统盘。 False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 - * "Type" => (string) 裸金属机型参数->磁盘类型:枚举值:CLOUD_RSSD - * "Size" => (integer) 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 - * "CouponId" => (string) 裸金属机型参数->云盘代金券id。不适用于系统盘。请通过DescribeCoupon接口查询,或登录用户中心查看 - * ] - * ] - * "VpcIp" => (string) 指定内网ip创建 - * "CouponId" => (string) 代金券 - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (array) PHost的资源ID数组 - * ] - * - * @return CreatePHostResponse * @throws UCloudException */ public function createPHost(CreatePHostRequest $request = null) @@ -107,49 +141,27 @@ public function createPHost(CreatePHostRequest $request = null) $resp = $this->invoke($request); return new CreatePHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * DescribeBaremetalMachineType - 获取裸金属机型的详细描述信息 - * - * See also: https://docs.ucloud.cn/api/uphost-api/describe_baremetal_machine_type + * CreatePHostImage - 创建裸金属2.0用户自定义镜像 * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (string) 具体机型。若不填写,则返回全部机型 - * ] - * - * Outputs: - * - * $outputs = [ - * "MachineTypes" => (array) 机型列表,模型:PHostCloudMachineTypeSet[ - * [ - * "Type" => (string) 物理云主机机型别名,全网唯一。 - * "CPU" => (object) CPU信息[ - * "Model" => (string) CPU型号 - * "Frequence" => (number) CPU主频 - * "Count" => (integer) CPU个数 - * "CoreCount" => (integer) CPU核数 - * ] - * "Memory" => (integer) 内存大小,单位MB - * "Components" => (object) 其他组件信息[ - * "Name" => (string) 组件名称 - * "Count" => (integer) 组件数量 - * ] - * "Clusters" => (array) 集群库存信息[ - * [ - * "Name" => (string) 集群名。枚举值:千兆网络集群:1G;万兆网络集群:10G;智能网卡网络:25G; - * "StockStatus" => (string) 库存状态。枚举值:有库存:Available;无库存:SoldOut - * ] - * ] - * ] - * ] - * ] + * @throws UCloudException + */ + public function createPHostImage(CreatePHostImageRequest $request = null) + { + $resp = $this->invoke($request); + return new CreatePHostImageResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeBaremetalMachineType - 获取裸金属机型的详细描述信息 * - * @return DescribeBaremetalMachineTypeResponse * @throws UCloudException */ public function describeBaremetalMachineType(DescribeBaremetalMachineTypeRequest $request = null) @@ -157,87 +169,13 @@ public function describeBaremetalMachineType(DescribeBaremetalMachineTypeRequest $resp = $this->invoke($request); return new DescribeBaremetalMachineTypeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePHost - 获取物理机详细信息 * - * See also: https://docs.ucloud.cn/api/uphost-api/describe_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PHostId" => (array) PHost资源ID,若为空,则返回当前Region所有PHost。 - * "Offset" => (integer) 数据偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20 - * "UDiskIdForAttachment" => (string) 要挂载的云盘id,过滤返回能被UDiskId挂载的云主机。目前主要针对rssd云盘使用 - * "VPCId" => (string) ULB使用参数,获取同VPC下机器信息。 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的PHost总数 - * "PHostSet" => (array) PHost资源列表,参见 PHostSet[ - * [ - * "Zone" => (string) 可用区,参见 [可用区列表](../summary/regionlist.html) - * "PHostId" => (string) PHost资源ID - * "SN" => (string) 物理机序列号 - * "PMStatus" => (string) 物理云主机状态。枚举值:\\ > 初始化:Initializing; \\ > 启动中:Starting; \\ > 运行中:Running;\\ > 关机中:Stopping; \\ > 安装失败:InstallFailed; \\ > 重启中:Rebooting;\\ > 关机:Stopped; \\ > 迁移中(裸金属云盘):Migrating - * "Name" => (string) 物理机名称 - * "Remark" => (string) 物理机备注 - * "Tag" => (string) 业务组 - * "ImageName" => (string) 镜像名称 - * "OSname" => (string) 操作系统名称 - * "CreateTime" => (integer) 创建时间 - * "ExpireTime" => (integer) 到期时间 - * "ChargeType" => (string) 计费模式,枚举值为: Year,按年付费; Month,按月付费;默认为月付 - * "PowerState" => (string) 电源状态,on 或 off - * "PHostType" => (string) 物理机类型,参见DescribePHostMachineType返回值 - * "Memory" => (integer) 内存大小,单位:MB - * "CPUSet" => (object) CPU信息,见 PHostCPUSet[ - * "Model" => (string) CPU型号 - * "Frequence" => (number) CPU主频 - * "Count" => (integer) CPU个数 - * "CoreCount" => (integer) CPU核数 - * ] - * "DiskSet" => (array) 磁盘信息,见 PHostDescDiskSet[ - * [ - * "Space" => (integer) 单盘大小,单位GB - * "Count" => (integer) 磁盘数量 - * "Type" => (string) 磁盘属性 - * "Name" => (string) 磁盘名称,sys/data - * "IOCap" => (integer) 磁盘IO性能,单位MB/s(待废弃) - * "Drive" => (string) 裸金属机型参数:磁盘盘符 - * "DiskId" => (string) 裸金属机型参数:磁盘ID - * "IsBoot" => (string) 裸金属机型参数:是否是启动盘。True/False - * ] - * ] - * "IPSet" => (array) IP信息,见 PHostIPSet[ - * [ - * "OperatorName" => (string) 国际: Internation, BGP: BGP, 内网: Private - * "IPId" => (string) IP资源ID(内网IP无资源ID)(待废弃) - * "IPAddr" => (string) IP地址, - * "MACAddr" => (string) MAC地址 - * "Bandwidth" => (integer) IP对应带宽,单位Mb,内网IP不显示带宽信息 - * "SubnetId" => (string) 子网ID - * "VPCId" => (string) VPC ID - * ] - * ] - * "Cluster" => (string) 网络环境。枚举值:千兆:1G ,万兆:10G - * "AutoRenew" => (string) 自动续费 - * "IsSupportKVM" => (string) 是否支持紧急登录 - * "OSType" => (string) 操作系统类型 - * "Components" => (string) 组件信息(暂不支持) - * "RaidSupported" => (string) 是否支持Raid。枚举值:Yes:支持;No:不支持。 - * "PhostClass" => (string) 物理云产品类型,枚举值:LocalDisk=>代表传统本地盘机型, CloudDisk=>云盘裸金属机型 - * ] - * ] - * ] - * - * @return DescribePHostResponse * @throws UCloudException */ public function describePHost(DescribePHostRequest $request = null) @@ -245,42 +183,13 @@ public function describePHost(DescribePHostRequest $request = null) $resp = $this->invoke($request); return new DescribePHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePHostImage - 获取物理云主机镜像列表 * - * See also: https://docs.ucloud.cn/api/uphost-api/describe_phost_image - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "ImageType" => (string) 镜像类别,枚举值,Base是基础镜像; - * "ImageId" => (array) 镜像ID - * "Offset" => (integer) 数据偏移量,默认为0 - * "Limit" => (integer) 返回数据长度,默认为20 - * "MachineType" => (string) 机器型号,只支持当前zone的展示机型 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的镜像总数 - * "ImageSet" => (array) 镜像列表 PHostImageSet[ - * [ - * "ImageId" => (string) 镜像ID - * "ImageName" => (string) 镜像名称 - * "OsName" => (string) 操作系统名称 - * "OsType" => (string) 操作系统类型 - * "Support" => (array) 支持的机型 - * "Version" => (string) 当前版本 - * ] - * ] - * ] - * - * @return DescribePHostImageResponse * @throws UCloudException */ public function describePHostImage(DescribePHostImageRequest $request = null) @@ -288,59 +197,13 @@ public function describePHostImage(DescribePHostImageRequest $request = null) $resp = $this->invoke($request); return new DescribePHostImageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePHostMachineType - 获取物理云机型的详细描述信息 * - * See also: https://docs.ucloud.cn/api/uphost-api/describe_phost_machine_type - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Type" => (string) 具体机型。若不填写,则返回全部机型 - * ] - * - * Outputs: - * - * $outputs = [ - * "MachineTypes" => (array) 机型列表,模型:PHostMachineTypeSet[ - * [ - * "Type" => (string) 物理云主机机型别名,全网唯一。 - * "CPU" => (object) CPU信息[ - * "Model" => (string) CPU型号 - * "Frequence" => (number) CPU主频 - * "Count" => (integer) CPU个数 - * "CoreCount" => (integer) CPU核数 - * ] - * "Memory" => (integer) 内存大小,单位MB - * "Disks" => (array) 磁盘信息[ - * [ - * "Space" => (integer) 单盘大小,单位GB - * "Count" => (integer) 磁盘数量 - * "Type" => (string) 磁盘属性 - * "Name" => (string) 磁盘名称,sys/data - * "IOCap" => (integer) 磁盘IO性能,单位MB/s(待废弃) - * ] - * ] - * "Components" => (object) 其他组件信息[ - * "Name" => (string) 组件名称 - * "Count" => (integer) 组件数量 - * ] - * "Clusters" => (array) 集群库存信息[ - * [ - * "Name" => (string) 集群名。枚举值:千兆网络集群:1G;万兆网络集群:10G;智能网卡网络:25G; - * "StockStatus" => (string) 库存状态。枚举值:有库存:Available;无库存:SoldOut - * ] - * ] - * "RaidSupported" => (string) 是否支持Raid。枚举值:支持:YES;不支持:NO - * ] - * ] - * ] - * - * @return DescribePHostMachineTypeResponse * @throws UCloudException */ public function describePHostMachineType(DescribePHostMachineTypeRequest $request = null) @@ -348,33 +211,13 @@ public function describePHostMachineType(DescribePHostMachineTypeRequest $reques $resp = $this->invoke($request); return new DescribePHostMachineTypeResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DescribePHostTags - 获取物理机tag列表(业务组) * - * See also: https://docs.ucloud.cn/api/uphost-api/describe_phost_tags - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) Tag的个数 - * "TagSet" => (array) 具体参见 PHostTagSet[ - * [ - * "Tag" => (string) 业务组名称 - * "TotalCount" => (integer) 该业务组中包含的主机个数 - * ] - * ] - * ] - * - * @return DescribePHostTagsResponse * @throws UCloudException */ public function describePHostTags(DescribePHostTagsRequest $request = null) @@ -382,32 +225,13 @@ public function describePHostTags(DescribePHostTagsRequest $request = null) $resp = $this->invoke($request); return new DescribePHostTagsResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetPHostDiskUpgradePrice - 获取物理云裸金属挂载磁盘的升级价格 * - * See also: https://docs.ucloud.cn/api/uphost-api/get_phost_disk_upgrade_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) UPHost实例ID。 - * "DiskSpace" => (integer) 磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 - * "UDiskId" => (string) 磁盘 ID。获取扩容价格必填(只能扩不能减);重装时候不需要填(根据所选盘大小决定) - * "ReinstallTag" => (boolean) 是否重装价格获取。复用此接口。扩容只能增加云盘大小。重装不限制。枚举值:true/false - * ] - * - * Outputs: - * - * $outputs = [ - * "Price" => (number) 升级差价。精度为小数点后2位。 - * "OriginalPrice" => (number) 升价差价原价。精度为小数点后2位。 - * ] - * - * @return GetPHostDiskUpgradePriceResponse * @throws UCloudException */ public function getPHostDiskUpgradePrice(GetPHostDiskUpgradePriceRequest $request = null) @@ -415,46 +239,13 @@ public function getPHostDiskUpgradePrice(GetPHostDiskUpgradePriceRequest $reques $resp = $this->invoke($request); return new GetPHostDiskUpgradePriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetPHostPrice - 获取物理机价格列表 * - * See also: https://docs.ucloud.cn/api/uphost-api/get_phost_price - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Count" => (integer) 购买数量,范围[1-5] - * "ChargeType" => (string) 计费模式,枚举值为: Year/Month - * "Quantity" => (integer) 购买时长,1-10个月或1-10年;默认值为1。月付时,此参数传0,代表购买至月末,1代表整月。 - * "Cluster" => (string) 网络环境,可选千兆:1G ;万兆:10G;25G网络:25G。 - * "Type" => (string) 默认为:DB(数据库型),可以通过接口 [DescribePHostMachineType](api/uphost-api/describe_phost_machine_type.html)获取 - * "Disks" => (array) [ - * [ - * "IsBoot" => (string) 裸金属机型参数->枚举值:\\ > True,是系统盘 \\ > False,是数据盘(默认)。Disks数组中有且只能有一块盘是系统盘。 - * "Type" => (string) 裸金属机型参数->磁盘类型:枚举值:CLOUD_RSSD - * "Size" => (string) 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB。数据盘是20-32000G。 - * ] - * ] - * ] - * - * Outputs: - * - * $outputs = [ - * "PriceSet" => (array) 价格列表 见 PHostPriceSet[ - * [ - * "ChargeType" => (string) Year/Month - * "Price" => (number) 价格, 单位:元, 保留小数点后两位有效数字 - * "Product" => (string) 枚举值:phost=>为主机价格,如果是云盘包括了系统盘价格。cloudDisk=>所有数据盘价格,只是裸金属机型才返回此参数。 - * "OriginalPrice" => (number) 原价格, 单位:元, 保留小数点后两位有效数字 - * ] - * ] - * ] - * - * @return GetPHostPriceResponse * @throws UCloudException */ public function getPHostPrice(GetPHostPriceRequest $request = null) @@ -462,31 +253,27 @@ public function getPHostPrice(GetPHostPriceRequest $request = null) $resp = $this->invoke($request); return new GetPHostPriceResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * ModifyPHostInfo - 更改物理机信息 - * - * See also: https://docs.ucloud.cn/api/uphost-api/modify_phost_info - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) 物理机资源ID - * "Name" => (string) 物理机名称,默认不更改 - * "Remark" => (string) 物理机备注,默认不更改 - * "Tag" => (string) 业务组,默认不更改 - * ] - * - * Outputs: + * ModifyPHostImageInfo - 修改自定义镜像名称和备注 * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] + * @throws UCloudException + */ + public function modifyPHostImageInfo(ModifyPHostImageInfoRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyPHostImageInfoResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyPHostInfo - 更改物理机信息 * - * @return ModifyPHostInfoResponse * @throws UCloudException */ public function modifyPHostInfo(ModifyPHostInfoRequest $request = null) @@ -494,28 +281,13 @@ public function modifyPHostInfo(ModifyPHostInfoRequest $request = null) $resp = $this->invoke($request); return new ModifyPHostInfoResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * PoweroffPHost - 断电物理云主机 * - * See also: https://docs.ucloud.cn/api/uphost-api/poweroff_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) PHost资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] - * - * @return PoweroffPHostResponse * @throws UCloudException */ public function poweroffPHost(PoweroffPHostRequest $request = null) @@ -523,28 +295,13 @@ public function poweroffPHost(PoweroffPHostRequest $request = null) $resp = $this->invoke($request); return new PoweroffPHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * RebootPHost - 重启物理机 * - * See also: https://docs.ucloud.cn/api/uphost-api/reboot_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) PHost资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] - * - * @return RebootPHostResponse * @throws UCloudException */ public function rebootPHost(RebootPHostRequest $request = null) @@ -552,36 +309,13 @@ public function rebootPHost(RebootPHostRequest $request = null) $resp = $this->invoke($request); return new RebootPHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ReinstallPHost - 重装物理机操作系统 * - * See also: https://docs.ucloud.cn/api/uphost-api/reinstall_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) PHost资源ID - * "Password" => (string) 密码 - * "ImageId" => (string) 镜像Id,参考镜像列表,默认使用原镜像 - * "Name" => (string) 物理机名称,默认不更改 - * "Remark" => (string) 物理机备注,默认为不更改。 - * "Tag" => (string) 业务组,默认不更改。 - * "ReserveDisk" => (string) 是否保留数据盘,保留:Yes,不报留:No, 默认:Yes - * "Raid" => (string) 不保留数据盘重装,可选Raid - * "BootDiskSpace" => (integer) 裸金属机型参数->系统盘大小。 单位:GB, 范围[20,500], 步长:10 - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] - * - * @return ReinstallPHostResponse * @throws UCloudException */ public function reinstallPHost(ReinstallPHostRequest $request = null) @@ -589,29 +323,13 @@ public function reinstallPHost(ReinstallPHostRequest $request = null) $resp = $this->invoke($request); return new ReinstallPHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResetPHostPassword - 重置裸金属实例的管理员密码 * - * See also: https://docs.ucloud.cn/api/uphost-api/reset_phost_password - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) 裸金属实例ID - * "Password" => (string) PHost新密码(密码格式使用BASE64编码) - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) 裸金属实例ID - * ] - * - * @return ResetPHostPasswordResponse * @throws UCloudException */ public function resetPHostPassword(ResetPHostPasswordRequest $request = null) @@ -619,30 +337,13 @@ public function resetPHostPassword(ResetPHostPasswordRequest $request = null) $resp = $this->invoke($request); return new ResetPHostPasswordResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * ResizePHostAttachedDisk - 修改裸金属物理云已经挂载的云盘容量大小 * - * See also: https://docs.ucloud.cn/api/uphost-api/resize_phost_attached_disk - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PHostId" => (string) UPHost实例ID。 - * "UDiskId" => (string) 磁盘ID。 - * "DiskSpace" => (integer) 裸金属机型参数->磁盘大小,单位GB,必须是10GB的整数倍。系统盘20-500GB,数据盘单块盘20-32000GB。 - * ] - * - * Outputs: - * - * $outputs = [ - * "UDiskId" => (string) 改配成功的磁盘id - * ] - * - * @return ResizePHostAttachedDiskResponse * @throws UCloudException */ public function resizePHostAttachedDisk(ResizePHostAttachedDiskRequest $request = null) @@ -650,28 +351,13 @@ public function resizePHostAttachedDisk(ResizePHostAttachedDiskRequest $request $resp = $this->invoke($request); return new ResizePHostAttachedDiskResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * StartPHost - 启动物理机 * - * See also: https://docs.ucloud.cn/api/uphost-api/start_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) PHost资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] - * - * @return StartPHostResponse * @throws UCloudException */ public function startPHost(StartPHostRequest $request = null) @@ -679,30 +365,27 @@ public function startPHost(StartPHostRequest $request = null) $resp = $this->invoke($request); return new StartPHostResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** - * TerminatePHost - 删除物理云主机 - * - * See also: https://docs.ucloud.cn/api/uphost-api/terminate_phost - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "PHostId" => (string) PHost资源ID - * "ReleaseEIP" => (boolean) 是否释放绑定的EIP。true: 解绑EIP后,并释放;其他值或不填:解绑EIP。 - * "ReleaseUDisk" => (boolean) 裸金属机型参数->删除主机时是否同时删除挂载的数据盘。默认为false。 - * ] + * StopPHost - 关闭物理机 * - * Outputs: - * - * $outputs = [ - * "PHostId" => (string) PHost 的资源ID - * ] + * @throws UCloudException + */ + public function stopPHost(StopPHostRequest $request = null) + { + $resp = $this->invoke($request); + return new StopPHostResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * TerminatePHost - 删除物理云主机 * - * @return TerminatePHostResponse * @throws UCloudException */ public function terminatePHost(TerminatePHostRequest $request = null) @@ -710,4 +393,18 @@ public function terminatePHost(TerminatePHostRequest $request = null) $resp = $this->invoke($request); return new TerminatePHostResponse($resp->toArray(), $resp->getRequestId()); } + + + + + /** + * TerminatePHostImage - 删除裸金属2.0用户自定义镜像 + * + * @throws UCloudException + */ + public function terminatePHostImage(TerminatePHostImageRequest $request = null) + { + $resp = $this->invoke($request); + return new TerminatePHostImageResponse($resp->toArray(), $resp->getRequestId()); + } } diff --git a/src/USMS/Apis/CreateUSMSSignatureRequest.php b/src/USMS/Apis/CreateUSMSSignatureRequest.php index 67926b09..e0ffeb86 100644 --- a/src/USMS/Apis/CreateUSMSSignatureRequest.php +++ b/src/USMS/Apis/CreateUSMSSignatureRequest.php @@ -1,6 +1,7 @@ markRequired("File"); } - /** * ProjectId: 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -49,11 +50,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SigContent: 签名内容 * @@ -69,11 +69,10 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } - /** * SigType: 签名类型,说明如下:0-公司或企业的全称或简称;1-App应用的全称或简称;2-工信部备案网站的全称或简称;3-公众号或小程序的全称或简称;4-商标名的全称或简称;5-政府/机关事业单位/其他单位的全称或简称; * @@ -89,11 +88,10 @@ public function getSigType() * * @param int $sigType */ - public function setSigType($sigType) + public function setSigType(int $sigType) { $this->set("SigType", $sigType); } - /** * SigPurpose: 签名用途,0-自用,1-他用; * @@ -109,11 +107,10 @@ public function getSigPurpose() * * @param int $sigPurpose */ - public function setSigPurpose($sigPurpose) + public function setSigPurpose(int $sigPurpose) { $this->set("SigPurpose", $sigPurpose); } - /** * CertificateType: 签名的资质证明文件类型,需与签名类型保持一致,说明如下:0-三证合一/企业营业执照/组织机构代码证书/社会信用代码证书;1-应用商店后台开发者管理截图;2-备案服务商的备案成功截图(含域名,网站名称,备案号);3-公众号或小程序的管理界面截图;4-商标注册证书;5-组织机构代码证书、社会信用代码证书; * @@ -129,11 +126,10 @@ public function getCertificateType() * * @param int $certificateType */ - public function setCertificateType($certificateType) + public function setCertificateType(int $certificateType) { $this->set("CertificateType", $certificateType); } - /** * Description: 短信签名申请原因 * @@ -149,11 +145,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * File: 短信签名的资质证明文件,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB * @@ -169,11 +164,10 @@ public function getFile() * * @param string $file */ - public function setFile($file) + public function setFile(string $file) { $this->set("File", $file); } - /** * International: 国内/国际短信。true:国际短信,false:国内短信,若不传值则默认该值为false * @@ -189,11 +183,10 @@ public function getInternational() * * @param boolean $international */ - public function setInternational($international) + public function setInternational(bool $international) { $this->set("International", $international); } - /** * ProxyFile: 短信签名授权委托文件,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB;当您是代理并使用第三方的签名时(也即SigPurpose为1-他用),该项为必填项; * @@ -209,7 +202,7 @@ public function getProxyFile() * * @param string $proxyFile */ - public function setProxyFile($proxyFile) + public function setProxyFile(string $proxyFile) { $this->set("ProxyFile", $proxyFile); } diff --git a/src/USMS/Apis/CreateUSMSSignatureResponse.php b/src/USMS/Apis/CreateUSMSSignatureResponse.php index e6aed7c1..4be55bc5 100644 --- a/src/USMS/Apis/CreateUSMSSignatureResponse.php +++ b/src/USMS/Apis/CreateUSMSSignatureResponse.php @@ -1,6 +1,7 @@ set("SigId", $sigId); } diff --git a/src/USMS/Apis/CreateUSMSTemplateRequest.php b/src/USMS/Apis/CreateUSMSTemplateRequest.php index c04db2a1..90dfbbc5 100644 --- a/src/USMS/Apis/CreateUSMSTemplateRequest.php +++ b/src/USMS/Apis/CreateUSMSTemplateRequest.php @@ -1,6 +1,7 @@ markRequired("Template"); } - /** * ProjectId: 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -46,11 +47,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Purpose: 短信模板用途类型:1-验证码类短信模板;2-系统通知类短信模板;3-会员推广类短信模板; * @@ -66,11 +66,10 @@ public function getPurpose() * * @param int $purpose */ - public function setPurpose($purpose) + public function setPurpose(int $purpose) { $this->set("Purpose", $purpose); } - /** * TemplateName: 短信模板名称,不超过32个字符,每个中文、符号、英文、数字等都计为1个字。 * @@ -86,11 +85,10 @@ public function getTemplateName() * * @param string $templateName */ - public function setTemplateName($templateName) + public function setTemplateName(string $templateName) { $this->set("TemplateName", $templateName); } - /** * Template: 短信模板内容,说明如下:字数不超过500,每个中文、符号、英文、数组等都计为一个字;模板中的变量填写格式:{N},其中N为大于1的整数,有多个参数时,建议N从1开始顺次,例如:{1}、{2}等;短信模板禁止仅包括变量的情况; * @@ -106,11 +104,10 @@ public function getTemplate() * * @param string $template */ - public function setTemplate($template) + public function setTemplate(string $template) { $this->set("Template", $template); } - /** * International: 标记是否为国际短信。true:国际短信,false:国内短信,若不传值则默认该值为false * @@ -126,11 +123,10 @@ public function getInternational() * * @param boolean $international */ - public function setInternational($international) + public function setInternational(bool $international) { $this->set("International", $international); } - /** * Remark: 短信模板申请原因说明,字数不超过128,每个中文、符号、英文、数字等都计为1个字。 * @@ -146,11 +142,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * UnsubscribeInfo: 当Purpose为3时,也即会员推广类短信模板,该项必填。枚举值:TD退订、回T退订、回N退订、回TD退订、退订回T、退订回D、退订回TD、退订回复T、退订回复D、退订回复N、退订回复TD、拒收回T * @@ -166,8 +161,27 @@ public function getUnsubscribeInfo() * * @param string $unsubscribeInfo */ - public function setUnsubscribeInfo($unsubscribeInfo) + public function setUnsubscribeInfo(string $unsubscribeInfo) { $this->set("UnsubscribeInfo", $unsubscribeInfo); } + /** + * Instruction: 模板变量属性说明 + * + * @return string|null + */ + public function getInstruction() + { + return $this->get("Instruction"); + } + + /** + * Instruction: 模板变量属性说明 + * + * @param string $instruction + */ + public function setInstruction(string $instruction) + { + $this->set("Instruction", $instruction); + } } diff --git a/src/USMS/Apis/CreateUSMSTemplateResponse.php b/src/USMS/Apis/CreateUSMSTemplateResponse.php index 6be1e505..35dff245 100644 --- a/src/USMS/Apis/CreateUSMSTemplateResponse.php +++ b/src/USMS/Apis/CreateUSMSTemplateResponse.php @@ -1,6 +1,7 @@ set("TemplateId", $templateId); } diff --git a/src/USMS/Apis/DeleteUSMSSignatureRequest.php b/src/USMS/Apis/DeleteUSMSSignatureRequest.php index 714ad3a3..e243f361 100644 --- a/src/USMS/Apis/DeleteUSMSSignatureRequest.php +++ b/src/USMS/Apis/DeleteUSMSSignatureRequest.php @@ -1,6 +1,7 @@ markRequired("SigIds"); } - /** * ProjectId: 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SigIds: 签名ID(也即短信签名申请时的工单ID),支持以数组的方式,举例,以SigIds.0、SigIds.1...SigIds.N方式传入 * diff --git a/src/USMS/Apis/DeleteUSMSSignatureResponse.php b/src/USMS/Apis/DeleteUSMSSignatureResponse.php index 537a8cea..280b4d2c 100644 --- a/src/USMS/Apis/DeleteUSMSSignatureResponse.php +++ b/src/USMS/Apis/DeleteUSMSSignatureResponse.php @@ -1,6 +1,7 @@ markRequired("TemplateIds"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TemplateIds: 模板ID(也即短信模板申请时的工单ID),支持以数组的方式,举例,以TemplateIds.0、TemplateIds.1...TemplateIds.N方式传入 * diff --git a/src/USMS/Apis/DeleteUSMSTemplateResponse.php b/src/USMS/Apis/DeleteUSMSTemplateResponse.php index d27eb7a0..5e55fd16 100644 --- a/src/USMS/Apis/DeleteUSMSTemplateResponse.php +++ b/src/USMS/Apis/DeleteUSMSTemplateResponse.php @@ -1,6 +1,7 @@ markRequired("SessionNoSet"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -63,11 +63,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -83,11 +82,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SessionNoSet: 发送短信时返回的SessionNo集合,SessionNoSet.0,SessionNoSet.1....格式,单次调用集合数需控制在100个以内 * diff --git a/src/USMS/Apis/GetUSMSSendReceiptResponse.php b/src/USMS/Apis/GetUSMSSendReceiptResponse.php index fa6942d9..571de0f2 100644 --- a/src/USMS/Apis/GetUSMSSendReceiptResponse.php +++ b/src/USMS/Apis/GetUSMSSendReceiptResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new ReceiptPerSession($item)); + array_push($result, new ReceiptPerSessionModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getData() /** * Data: 回执信息集合 * - * @param ReceiptPerSession[] $data + * @param ReceiptPerSessionModel[] $data */ public function setData(array $data) { diff --git a/src/USMS/Apis/QueryUSMSSignatureRequest.php b/src/USMS/Apis/QueryUSMSSignatureRequest.php index 515cedd4..92e0fb25 100644 --- a/src/USMS/Apis/QueryUSMSSignatureRequest.php +++ b/src/USMS/Apis/QueryUSMSSignatureRequest.php @@ -1,6 +1,7 @@ "QueryUSMSSignature"]); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) @@ -42,11 +43,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SigId: 已申请的短信签名ID(短信签名申请时的工单ID);签名ID和签名至少需填写1项; * @@ -62,11 +62,10 @@ public function getSigId() * * @param string $sigId */ - public function setSigId($sigId) + public function setSigId(string $sigId) { $this->set("SigId", $sigId); } - /** * SigContent: 签名内容;签名ID和签名至少需填写1项; * @@ -82,7 +81,7 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } diff --git a/src/USMS/Apis/QueryUSMSSignatureResponse.php b/src/USMS/Apis/QueryUSMSSignatureResponse.php index 30d535fd..c5c1cf2d 100644 --- a/src/USMS/Apis/QueryUSMSSignatureResponse.php +++ b/src/USMS/Apis/QueryUSMSSignatureResponse.php @@ -1,6 +1,7 @@ get("Data")); + return new OutSignatureModel($this->get("Data")); } /** * Data: 签名信息 * - * @param OutSignature $data + * @param OutSignatureModel $data */ - public function setData(array $data) + public function setData(OutSignatureModel $data) { $this->set("Data", $data->getAll()); } diff --git a/src/USMS/Apis/QueryUSMSTemplateRequest.php b/src/USMS/Apis/QueryUSMSTemplateRequest.php index ab007c00..ecc17c66 100644 --- a/src/USMS/Apis/QueryUSMSTemplateRequest.php +++ b/src/USMS/Apis/QueryUSMSTemplateRequest.php @@ -1,6 +1,7 @@ markRequired("TemplateId"); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -40,15 +41,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TemplateId: 模板ID * @@ -64,7 +64,7 @@ public function getTemplateId() * * @param string $templateId */ - public function setTemplateId($templateId) + public function setTemplateId(string $templateId) { $this->set("TemplateId", $templateId); } diff --git a/src/USMS/Apis/QueryUSMSTemplateResponse.php b/src/USMS/Apis/QueryUSMSTemplateResponse.php index 60043aae..74e32c66 100644 --- a/src/USMS/Apis/QueryUSMSTemplateResponse.php +++ b/src/USMS/Apis/QueryUSMSTemplateResponse.php @@ -1,6 +1,7 @@ get("Data")); + return new OutTemplateModel($this->get("Data")); } /** * Data: 短信模板明细信息,各字段说明详见OutTemplate * - * @param OutTemplate $data + * @param OutTemplateModel $data */ - public function setData(array $data) + public function setData(OutTemplateModel $data) { $this->set("Data", $data->getAll()); } diff --git a/src/USMS/Apis/SendBatchUSMSMessageRequest.php b/src/USMS/Apis/SendBatchUSMSMessageRequest.php index e3d257ae..2b0a6517 100644 --- a/src/USMS/Apis/SendBatchUSMSMessageRequest.php +++ b/src/USMS/Apis/SendBatchUSMSMessageRequest.php @@ -1,6 +1,7 @@ markRequired("TaskContent"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -44,11 +45,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TaskContent: 批量发送内容,该参数是json数组的base64编码结果。发送内容json数组中,每个“模板+签名”组合作为一个子项,每个子项内支持多个号码,示例:发送内容json数组(base64编码前):[{"TemplateId": "UTA20212831C85C", "SigContent": "UCloud", "Target": [{"TemplateParams": ["123456"], "Phone": "18500000123", "ExtendCode": "123", "UserId": "456"} ] } ] 。json数组中各参数的定义:"TemplateId":模板ID,"SigContent"短信签名内容,"Target"具体到号码粒度的发送内容。"Target"中的具体字段有:"TemplateParams"实际发送的模板参数(若使用的是无参数模板,该参数不能传值),"Phone"手机号码, "ExtendCode"短信扩展码, "UserId"自定义业务标识ID。其中必传参数为"TemplateId", "SigContent", "Target"("Target"中必传参数为"Phone")。实际调用本接口时TaskContent传值(发送内容base64编码后)为:W3siVGVtcGxhdGVJZCI6ICJVVEEyMDIxMjgzMUM4NUMiLCAiU2lnQ29udGVudCI6ICJVQ2xvdWQiLCAiVGFyZ2V0IjogW3siVGVtcGxhdGVQYXJhbXMiOiBbIjEyMzQ1NiJdLCAiUGhvbmUiOiAiMTg1MDAwMDAxMjMiLCAiRXh0ZW5kQ29kZSI6ICIxMjMiLCAiVXNlcklkIjogIjQ1NiJ9IF0gfSBdIA== * @@ -64,7 +64,7 @@ public function getTaskContent() * * @param string $taskContent */ - public function setTaskContent($taskContent) + public function setTaskContent(string $taskContent) { $this->set("TaskContent", $taskContent); } diff --git a/src/USMS/Apis/SendBatchUSMSMessageResponse.php b/src/USMS/Apis/SendBatchUSMSMessageResponse.php index 744dd7e6..ae490797 100644 --- a/src/USMS/Apis/SendBatchUSMSMessageResponse.php +++ b/src/USMS/Apis/SendBatchUSMSMessageResponse.php @@ -1,6 +1,7 @@ set("SessionNo", $sessionNo); } - /** * ReqUuid: 本次请求Uuid * @@ -59,11 +60,10 @@ public function getReqUuid() * * @param string $reqUuid */ - public function setReqUuid($reqUuid) + public function setReqUuid(string $reqUuid) { $this->set("ReqUuid", $reqUuid); } - /** * SuccessCount: 成功提交短信(未拆分)条数 * @@ -79,15 +79,14 @@ public function getSuccessCount() * * @param int $successCount */ - public function setSuccessCount($successCount) + public function setSuccessCount(int $successCount) { $this->set("SuccessCount", $successCount); } - /** * FailContent: 未发送成功的详情,返回码非0时该字段有效,可根据该字段数据重发 * - * @return BatchInfo[]|null + * @return BatchInfoModel[]|null */ public function getFailContent() { @@ -97,7 +96,7 @@ public function getFailContent() } $result = []; foreach ($items as $i => $item) { - array_push($result, new BatchInfo($item)); + array_push($result, new BatchInfoModel($item)); } return $result; } @@ -105,7 +104,7 @@ public function getFailContent() /** * FailContent: 未发送成功的详情,返回码非0时该字段有效,可根据该字段数据重发 * - * @param BatchInfo[] $failContent + * @param BatchInfoModel[] $failContent */ public function setFailContent(array $failContent) { diff --git a/src/USMS/Apis/SendUSMSMessageRequest.php b/src/USMS/Apis/SendUSMSMessageRequest.php index c374464f..b9a7dcec 100644 --- a/src/USMS/Apis/SendUSMSMessageRequest.php +++ b/src/USMS/Apis/SendUSMSMessageRequest.php @@ -1,6 +1,7 @@ markRequired("TemplateId"); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -46,11 +47,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * PhoneNumbers: 电话号码数组,电话号码格式为(60)1xxxxxxxx,()中为国际长途区号(如中国为86或0086,两种格式都支持),后面为电话号码.若不传入国际区号,如1851623xxxx,则默认为国内手机号 * @@ -70,7 +70,6 @@ public function setPhoneNumbers(array $phoneNumbers) { $this->set("PhoneNumbers", $phoneNumbers); } - /** * SigContent: 短信签名内容,请到[USMS控制台](https://console.ucloud.cn/usms)的签名管理页面查看;使用的短信签名必须是已申请并且通过审核; * @@ -86,11 +85,10 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } - /** * TemplateId: 模板ID(也即短信模板申请时的工单ID),请到[USMS控制台](https://console.ucloud.cn/usms)的模板管理页面查看;使用的短信模板必须是已申请并通过审核; * @@ -106,11 +104,10 @@ public function getTemplateId() * * @param string $templateId */ - public function setTemplateId($templateId) + public function setTemplateId(string $templateId) { $this->set("TemplateId", $templateId); } - /** * TemplateParams: 模板可变参数,以数组的方式填写,举例,TemplateParams.0,TemplateParams.1,... 若模板中无可变参数,则该项可不填写;若模板中有可变参数,则该项为必填项,参数个数需与变量个数保持一致,否则无法发送; * @@ -130,7 +127,6 @@ public function setTemplateParams(array $templateParams) { $this->set("TemplateParams", $templateParams); } - /** * ExtendCode: 短信扩展码,格式为阿拉伯数字串,默认不开通,如需开通请联系 UCloud技术支持 * @@ -146,11 +142,10 @@ public function getExtendCode() * * @param string $extendCode */ - public function setExtendCode($extendCode) + public function setExtendCode(string $extendCode) { $this->set("ExtendCode", $extendCode); } - /** * UserId: 自定义的业务标识ID,字符串( 长度不能超过32 位),不支持 单引号、表情包符号等特殊字符 * @@ -166,7 +161,7 @@ public function getUserId() * * @param string $userId */ - public function setUserId($userId) + public function setUserId(string $userId) { $this->set("UserId", $userId); } diff --git a/src/USMS/Apis/SendUSMSMessageResponse.php b/src/USMS/Apis/SendUSMSMessageResponse.php index 9d262d76..119bc95a 100644 --- a/src/USMS/Apis/SendUSMSMessageResponse.php +++ b/src/USMS/Apis/SendUSMSMessageResponse.php @@ -1,6 +1,7 @@ set("SessionNo", $sessionNo); } - /** * UserId: 本次提交的自定义业务标识ID,仅当发送时传入有效的UserId,才返回该字段。 * @@ -57,7 +57,7 @@ public function getUserId() * * @param string $userId */ - public function setUserId($userId) + public function setUserId(string $userId) { $this->set("UserId", $userId); } diff --git a/src/USMS/Apis/UpdateUSMSSignatureRequest.php b/src/USMS/Apis/UpdateUSMSSignatureRequest.php index 1e4346ac..85504734 100644 --- a/src/USMS/Apis/UpdateUSMSSignatureRequest.php +++ b/src/USMS/Apis/UpdateUSMSSignatureRequest.php @@ -1,6 +1,7 @@ markRequired("SigPurpose"); } - /** * ProjectId: 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) @@ -47,11 +48,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SigId: 签名ID(也即短信签名申请时的工单ID),支持以数组的方式,举例,以SigIds.0、SigIds.1...SigIds.N方式传入 * @@ -67,11 +67,10 @@ public function getSigId() * * @param string $sigId */ - public function setSigId($sigId) + public function setSigId(string $sigId) { $this->set("SigId", $sigId); } - /** * SigContent: 新的短信签名内容;长度为2-12个字符, 可包含中文、数字和符号;无需填写【】或[],系统会自动添加 * @@ -87,11 +86,10 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } - /** * SigType: 签名类型,说明如下:0-公司或企业的全称或简称;1-App应用的全称或简称;2-工信部备案网站的全称或简称;3-公众号或小程序的全称或简称;4-商标名的全称或简称;5-政府/机关事业单位/其他单位的全称或简称; * @@ -107,11 +105,10 @@ public function getSigType() * * @param int $sigType */ - public function setSigType($sigType) + public function setSigType(int $sigType) { $this->set("SigType", $sigType); } - /** * SigPurpose: 签名用途,0-自用,1-他用; * @@ -127,11 +124,10 @@ public function getSigPurpose() * * @param int $sigPurpose */ - public function setSigPurpose($sigPurpose) + public function setSigPurpose(int $sigPurpose) { $this->set("SigPurpose", $sigPurpose); } - /** * File: 短信签名的资质证明文件内容,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB。内容格式如下: [file type];[code type],[base64] 如:image/jpeg;base64,5YaF5a65 * @@ -147,11 +143,10 @@ public function getFile() * * @param string $file */ - public function setFile($file) + public function setFile(string $file) { $this->set("File", $file); } - /** * CertificateType: 签名的资质证明文件类型,需与签名类型保持一致,说明如下:0-三证合一/企业营业执照/组织机构代码证书/社会信用代码证书;1-应用商店后台开发者管理截图;2-备案服务商的备案成功截图(含域名,网站名称,备案号);3-公众号或小程序的管理界面截图;4-商标注册证书;5-组织机构代码证书、社会信用代码证书; * @@ -167,11 +162,10 @@ public function getCertificateType() * * @param int $certificateType */ - public function setCertificateType($certificateType) + public function setCertificateType(int $certificateType) { $this->set("CertificateType", $certificateType); } - /** * ProxyFile: 短信签名授权委托文件内容,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB;当您是代理并使用第三方的签名时(也即SigPurpose为1-他用),该项为必填项;格式和File类似。 * @@ -187,11 +181,10 @@ public function getProxyFile() * * @param string $proxyFile */ - public function setProxyFile($proxyFile) + public function setProxyFile(string $proxyFile) { $this->set("ProxyFile", $proxyFile); } - /** * Document: 短信签名的资质证明文件URL,若未更改审核材料,则该处使用已上传审核材料的URL链接,否则使用File参数 * @@ -207,11 +200,10 @@ public function getDocument() * * @param string $document */ - public function setDocument($document) + public function setDocument(string $document) { $this->set("Document", $document); } - /** * ProxyDoc: 短信签名授权委托文件URL,若未更改授权委托文件,则该处填写已上传的授权委托文件的URL链接,否则使用ProxyFile参数 * @@ -227,7 +219,7 @@ public function getProxyDoc() * * @param string $proxyDoc */ - public function setProxyDoc($proxyDoc) + public function setProxyDoc(string $proxyDoc) { $this->set("ProxyDoc", $proxyDoc); } diff --git a/src/USMS/Apis/UpdateUSMSSignatureResponse.php b/src/USMS/Apis/UpdateUSMSSignatureResponse.php index 966bd077..1a5a1c9a 100644 --- a/src/USMS/Apis/UpdateUSMSSignatureResponse.php +++ b/src/USMS/Apis/UpdateUSMSSignatureResponse.php @@ -1,6 +1,7 @@ markRequired("Template"); } - /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -41,15 +42,14 @@ public function getProjectId() } /** - * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * TemplateId: 短信模板ID * @@ -65,11 +65,10 @@ public function getTemplateId() * * @param string $templateId */ - public function setTemplateId($templateId) + public function setTemplateId(string $templateId) { $this->set("TemplateId", $templateId); } - /** * Template: 新的模板内容。模板名称和模板内容必须提供一个,否则会报错。小于等于600个字 * @@ -85,11 +84,10 @@ public function getTemplate() * * @param string $template */ - public function setTemplate($template) + public function setTemplate(string $template) { $this->set("Template", $template); } - /** * TemplateName: 新的模板名称。小于等于32个字,每个中文、英文、数组、符合都计为一个字 * @@ -105,11 +103,10 @@ public function getTemplateName() * * @param string $templateName */ - public function setTemplateName($templateName) + public function setTemplateName(string $templateName) { $this->set("TemplateName", $templateName); } - /** * Remark: 短信模板申请原因说明,字数不超过128,每个中文、符号、英文、数字等都计为1个字。 * @@ -125,8 +122,27 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } + /** + * Instruction: 模板变量属性说明 + * + * @return string|null + */ + public function getInstruction() + { + return $this->get("Instruction"); + } + + /** + * Instruction: 模板变量属性说明 + * + * @param string $instruction + */ + public function setInstruction(string $instruction) + { + $this->set("Instruction", $instruction); + } } diff --git a/src/USMS/Apis/UpdateUSMSTemplateResponse.php b/src/USMS/Apis/UpdateUSMSTemplateResponse.php index 6485cf6a..41133f67 100644 --- a/src/USMS/Apis/UpdateUSMSTemplateResponse.php +++ b/src/USMS/Apis/UpdateUSMSTemplateResponse.php @@ -1,6 +1,7 @@ set("TemplateId", $templateId); } - /** * SigContent: 签名 * @@ -57,15 +60,14 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } - /** * Target: 具体号码信息 * - * @return FailPhoneDetail[]|null + * @return FailPhoneDetailModel[]|null */ public function getTarget() { @@ -75,7 +77,7 @@ public function getTarget() } $result = []; foreach ($items as $i => $item) { - array_push($result, new FailPhoneDetail($item)); + array_push($result, new FailPhoneDetailModel($item)); } return $result; } @@ -83,7 +85,7 @@ public function getTarget() /** * Target: 具体号码信息 * - * @param FailPhoneDetail[] $target + * @param FailPhoneDetailModel[] $target */ public function setTarget(array $target) { @@ -93,7 +95,6 @@ public function setTarget(array $target) } return $result; } - /** * FailureDetails: 未能成功发送的详情。注:模板/签名检验失败时,该字段有效 * @@ -109,7 +110,7 @@ public function getFailureDetails() * * @param string $failureDetails */ - public function setFailureDetails($failureDetails) + public function setFailureDetails(string $failureDetails) { $this->set("FailureDetails", $failureDetails); } diff --git a/src/USMS/Models/FailPhoneDetail.php b/src/USMS/Models/FailPhoneDetail.php index 18bd3660..bf0e90a3 100644 --- a/src/USMS/Models/FailPhoneDetail.php +++ b/src/USMS/Models/FailPhoneDetail.php @@ -1,6 +1,7 @@ set("TemplateParams", $templateParams); } - /** * Phone: 手机号 * @@ -57,11 +60,10 @@ public function getPhone() * * @param string $phone */ - public function setPhone($phone) + public function setPhone(string $phone) { $this->set("Phone", $phone); } - /** * ExtendCode: 扩展号码 * @@ -77,11 +79,10 @@ public function getExtendCode() * * @param string $extendCode */ - public function setExtendCode($extendCode) + public function setExtendCode(string $extendCode) { $this->set("ExtendCode", $extendCode); } - /** * UserId: 用户自定义ID * @@ -97,11 +98,10 @@ public function getUserId() * * @param string $userId */ - public function setUserId($userId) + public function setUserId(string $userId) { $this->set("UserId", $userId); } - /** * FailureDetails: 发送失败原因。注:若模板/签名校验失败,该字段为空 * @@ -117,7 +117,7 @@ public function getFailureDetails() * * @param string $failureDetails */ - public function setFailureDetails($failureDetails) + public function setFailureDetails(string $failureDetails) { $this->set("FailureDetails", $failureDetails); } diff --git a/src/USMS/Models/OutSignature.php b/src/USMS/Models/OutSignature.php index ff7339e8..f2d6b719 100644 --- a/src/USMS/Models/OutSignature.php +++ b/src/USMS/Models/OutSignature.php @@ -1,6 +1,7 @@ set("SigId", $sigId); } - /** * SigContent: 短信签名内容 * @@ -57,11 +60,10 @@ public function getSigContent() * * @param string $sigContent */ - public function setSigContent($sigContent) + public function setSigContent(string $sigContent) { $this->set("SigContent", $sigContent); } - /** * Status: 签名状态,0-待审核 1-审核中 2-审核通过 3-审核未通过 4-被禁用 * @@ -77,11 +79,10 @@ public function getStatus() * * @param int $status */ - public function setStatus($status) + public function setStatus(int $status) { $this->set("Status", $status); } - /** * ErrDesc: 短信签名未通过审核原因 * @@ -97,7 +98,7 @@ public function getErrDesc() * * @param string $errDesc */ - public function setErrDesc($errDesc) + public function setErrDesc(string $errDesc) { $this->set("ErrDesc", $errDesc); } diff --git a/src/USMS/Models/OutTemplate.php b/src/USMS/Models/OutTemplate.php index d9491aee..f14e4851 100644 --- a/src/USMS/Models/OutTemplate.php +++ b/src/USMS/Models/OutTemplate.php @@ -1,6 +1,7 @@ set("TemplateId", $templateId); } - /** * Purpose: 模板类型,选项:1-验证码类 2-通知类 3-会员推广类 * @@ -57,11 +59,10 @@ public function getPurpose() * * @param int $purpose */ - public function setPurpose($purpose) + public function setPurpose(int $purpose) { $this->set("Purpose", $purpose); } - /** * TemplateName: 短信模板名称 * @@ -77,11 +78,10 @@ public function getTemplateName() * * @param string $templateName */ - public function setTemplateName($templateName) + public function setTemplateName(string $templateName) { $this->set("TemplateName", $templateName); } - /** * Template: 短信模板内容 * @@ -97,11 +97,10 @@ public function getTemplate() * * @param string $template */ - public function setTemplate($template) + public function setTemplate(string $template) { $this->set("Template", $template); } - /** * UnsubscribeInfo: 退订信息;一般填写方式“回T退订”,当purpose为3(也即会员推广类)时,为必填项 * @@ -117,11 +116,10 @@ public function getUnsubscribeInfo() * * @param string $unsubscribeInfo */ - public function setUnsubscribeInfo($unsubscribeInfo) + public function setUnsubscribeInfo(string $unsubscribeInfo) { $this->set("UnsubscribeInfo", $unsubscribeInfo); } - /** * Status: 短信模板状态;状态说明:0-待审核,1-审核中,2-审核通过,3-审核未通过,4-被禁用 * @@ -137,11 +135,10 @@ public function getStatus() * * @param int $status */ - public function setStatus($status) + public function setStatus(int $status) { $this->set("Status", $status); } - /** * Remark: 模板说明 * @@ -157,11 +154,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * ErrDesc: 审核失败原因 * @@ -177,11 +173,10 @@ public function getErrDesc() * * @param string $errDesc */ - public function setErrDesc($errDesc) + public function setErrDesc(string $errDesc) { $this->set("ErrDesc", $errDesc); } - /** * CreateTime: 创建时间 * @@ -197,8 +192,27 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } + /** + * Instruction: 模板变量属性说明 + * + * @return string|null + */ + public function getInstruction() + { + return $this->get("Instruction"); + } + + /** + * Instruction: 模板变量属性说明 + * + * @param string $instruction + */ + public function setInstruction(string $instruction) + { + $this->set("Instruction", $instruction); + } } diff --git a/src/USMS/Models/ReceiptPerPhone.php b/src/USMS/Models/ReceiptPerPhone.php index 8021745a..1927d98f 100644 --- a/src/USMS/Models/ReceiptPerPhone.php +++ b/src/USMS/Models/ReceiptPerPhone.php @@ -1,6 +1,7 @@ set("Phone", $phone); } - /** * CostCount: 消耗短信条数 * @@ -57,11 +60,10 @@ public function getCostCount() * * @param int $costCount */ - public function setCostCount($costCount) + public function setCostCount(int $costCount) { $this->set("CostCount", $costCount); } - /** * ReceiptResult: 回执结果,枚举值:\\ > 发送成功: 代表成功 \\ > Success: 代表成功 \\ > 发送失败: 代表失败 \\ > Fail: 代表失败 \\ > 状态未知: 代表未知 \\ > Unknow: 代表未知 * @@ -77,11 +79,10 @@ public function getReceiptResult() * * @param string $receiptResult */ - public function setReceiptResult($receiptResult) + public function setReceiptResult(string $receiptResult) { $this->set("ReceiptResult", $receiptResult); } - /** * ReceiptCode: 状态报告编码 * @@ -97,11 +98,10 @@ public function getReceiptCode() * * @param string $receiptCode */ - public function setReceiptCode($receiptCode) + public function setReceiptCode(string $receiptCode) { $this->set("ReceiptCode", $receiptCode); } - /** * ReceiptDesc: 回执结果描述 * @@ -117,11 +117,10 @@ public function getReceiptDesc() * * @param string $receiptDesc */ - public function setReceiptDesc($receiptDesc) + public function setReceiptDesc(string $receiptDesc) { $this->set("ReceiptDesc", $receiptDesc); } - /** * ReceiptTime: 回执返回时间 * @@ -137,11 +136,10 @@ public function getReceiptTime() * * @param int $receiptTime */ - public function setReceiptTime($receiptTime) + public function setReceiptTime(int $receiptTime) { $this->set("ReceiptTime", $receiptTime); } - /** * UserId: 自定义的业务标识ID,字符串 * @@ -157,7 +155,7 @@ public function getUserId() * * @param string $userId */ - public function setUserId($userId) + public function setUserId(string $userId) { $this->set("UserId", $userId); } diff --git a/src/USMS/Models/ReceiptPerSession.php b/src/USMS/Models/ReceiptPerSession.php index 3dfee416..88d8525e 100644 --- a/src/USMS/Models/ReceiptPerSession.php +++ b/src/USMS/Models/ReceiptPerSession.php @@ -1,6 +1,7 @@ set("SessionNo", $sessionNo); } - /** * ReceiptSet: 每个手机号的短信回执信息集合 * - * @return ReceiptPerPhone[]|null + * @return ReceiptPerPhoneModel[]|null */ public function getReceiptSet() { @@ -55,7 +58,7 @@ public function getReceiptSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new ReceiptPerPhone($item)); + array_push($result, new ReceiptPerPhoneModel($item)); } return $result; } @@ -63,7 +66,7 @@ public function getReceiptSet() /** * ReceiptSet: 每个手机号的短信回执信息集合 * - * @param ReceiptPerPhone[] $receiptSet + * @param ReceiptPerPhoneModel[] $receiptSet */ public function setReceiptSet(array $receiptSet) { diff --git a/src/USMS/USMSClient.php b/src/USMS/USMSClient.php index 805d79f1..fd2df62b 100644 --- a/src/USMS/USMSClient.php +++ b/src/USMS/USMSClient.php @@ -1,6 +1,7 @@ (string) 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SigContent" => (string) 签名内容 - * "SigType" => (integer) 签名类型,说明如下:0-公司或企业的全称或简称;1-App应用的全称或简称;2-工信部备案网站的全称或简称;3-公众号或小程序的全称或简称;4-商标名的全称或简称;5-政府/机关事业单位/其他单位的全称或简称; - * "SigPurpose" => (integer) 签名用途,0-自用,1-他用; - * "CertificateType" => (integer) 签名的资质证明文件类型,需与签名类型保持一致,说明如下:0-三证合一/企业营业执照/组织机构代码证书/社会信用代码证书;1-应用商店后台开发者管理截图;2-备案服务商的备案成功截图(含域名,网站名称,备案号);3-公众号或小程序的管理界面截图;4-商标注册证书;5-组织机构代码证书、社会信用代码证书; - * "Description" => (string) 短信签名申请原因 - * "File" => (string) 短信签名的资质证明文件,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB - * "International" => (boolean) 国内/国际短信。true:国际短信,false:国内短信,若不传值则默认该值为false - * "ProxyFile" => (string) 短信签名授权委托文件,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB;当您是代理并使用第三方的签名时(也即SigPurpose为1-他用),该项为必填项; - * ] - * - * Outputs: - * - * $outputs = [ - * "SigId" => (string) 短信签名ID(短信签名申请时的工单ID) - * ] - * - * @return CreateUSMSSignatureResponse * @throws UCloudException */ public function createUSMSSignature(CreateUSMSSignatureRequest $request = null) @@ -80,31 +96,13 @@ public function createUSMSSignature(CreateUSMSSignatureRequest $request = null) $resp = $this->invoke($request); return new CreateUSMSSignatureResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * CreateUSMSTemplate - 调用接口CreateUSMSTemplate申请短信模板 * - * See also: https://docs.ucloud.cn/api/usms-api/create_usms_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Purpose" => (integer) 短信模板用途类型:1-验证码类短信模板;2-系统通知类短信模板;3-会员推广类短信模板; - * "TemplateName" => (string) 短信模板名称,不超过32个字符,每个中文、符号、英文、数字等都计为1个字。 - * "Template" => (string) 短信模板内容,说明如下:字数不超过500,每个中文、符号、英文、数组等都计为一个字;模板中的变量填写格式:{N},其中N为大于1的整数,有多个参数时,建议N从1开始顺次,例如:{1}、{2}等;短信模板禁止仅包括变量的情况; - * "International" => (boolean) 标记是否为国际短信。true:国际短信,false:国内短信,若不传值则默认该值为false - * "Remark" => (string) 短信模板申请原因说明,字数不超过128,每个中文、符号、英文、数字等都计为1个字。 - * "UnsubscribeInfo" => (string) 当Purpose为3时,也即会员推广类短信模板,该项必填。枚举值:TD退订、回T退订、回N退订、回TD退订、退订回T、退订回D、退订回TD、退订回复T、退订回复D、退订回复N、退订回复TD、拒收回T - * ] - * - * Outputs: - * - * $outputs = [ - * "TemplateId" => (string) 短信模板ID(短信模板申请时的工单ID) - * ] - * - * @return CreateUSMSTemplateResponse * @throws UCloudException */ public function createUSMSTemplate(CreateUSMSTemplateRequest $request = null) @@ -112,25 +110,13 @@ public function createUSMSTemplate(CreateUSMSTemplateRequest $request = null) $resp = $this->invoke($request); return new CreateUSMSTemplateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUSMSSignature - 调用接口DeleteUSMSSignature删除短信签名 * - * See also: https://docs.ucloud.cn/api/usms-api/delete_usms_signature - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SigIds" => (array) 签名ID(也即短信签名申请时的工单ID),支持以数组的方式,举例,以SigIds.0、SigIds.1...SigIds.N方式传入 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUSMSSignatureResponse * @throws UCloudException */ public function deleteUSMSSignature(DeleteUSMSSignatureRequest $request = null) @@ -138,25 +124,13 @@ public function deleteUSMSSignature(DeleteUSMSSignatureRequest $request = null) $resp = $this->invoke($request); return new DeleteUSMSSignatureResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * DeleteUSMSTemplate - 调用接口DeleteUSMSTemplate删除短信模板 * - * See also: https://docs.ucloud.cn/api/usms-api/delete_usms_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TemplateIds" => (array) 模板ID(也即短信模板申请时的工单ID),支持以数组的方式,举例,以TemplateIds.0、TemplateIds.1...TemplateIds.N方式传入 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteUSMSTemplateResponse * @throws UCloudException */ public function deleteUSMSTemplate(DeleteUSMSTemplateRequest $request = null) @@ -164,43 +138,13 @@ public function deleteUSMSTemplate(DeleteUSMSTemplateRequest $request = null) $resp = $this->invoke($request); return new DeleteUSMSTemplateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * GetUSMSSendReceipt - 调用接口GetUSMSSendReceipt短信发送状态信息 * - * See also: https://docs.ucloud.cn/api/usms-api/get_usms_send_receipt - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "Zone" => (string) 可用区。参见 [可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SessionNoSet" => (array) 发送短信时返回的SessionNo集合,SessionNoSet.0,SessionNoSet.1....格式,单次调用集合数需控制在100个以内 - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (array) 回执信息集合[ - * [ - * "SessionNo" => (string) 发送短信时返回的SessionNo - * "ReceiptSet" => (array) 每个手机号的短信回执信息集合[ - * [ - * "Phone" => (string) 手机号码 - * "CostCount" => (integer) 消耗短信条数 - * "ReceiptResult" => (string) 回执结果,枚举值:\\ > 发送成功: 代表成功 \\ > Success: 代表成功 \\ > 发送失败: 代表失败 \\ > Fail: 代表失败 \\ > 状态未知: 代表未知 \\ > Unknow: 代表未知 - * "ReceiptCode" => (string) 状态报告编码 - * "ReceiptDesc" => (string) 回执结果描述 - * "ReceiptTime" => (integer) 回执返回时间 - * "UserId" => (string) 自定义的业务标识ID,字符串 - * ] - * ] - * ] - * ] - * ] - * - * @return GetUSMSSendReceiptResponse * @throws UCloudException */ public function getUSMSSendReceipt(GetUSMSSendReceiptRequest $request = null) @@ -208,32 +152,13 @@ public function getUSMSSendReceipt(GetUSMSSendReceiptRequest $request = null) $resp = $this->invoke($request); return new GetUSMSSendReceiptResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * QueryUSMSSignature - 调用接口QueryUSMSSignature查询短信签名申请状态 * - * See also: https://docs.ucloud.cn/api/usms-api/query_usms_signature - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SigId" => (string) 已申请的短信签名ID(短信签名申请时的工单ID);签名ID和签名至少需填写1项; - * "SigContent" => (string) 签名内容;签名ID和签名至少需填写1项; - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (object) 签名信息[ - * "SigId" => (string) 短信签名ID - * "SigContent" => (string) 短信签名内容 - * "Status" => (integer) 签名状态,0-待审核 1-审核中 2-审核通过 3-审核未通过 4-被禁用 - * "ErrDesc" => (string) 短信签名未通过审核原因 - * ] - * ] - * - * @return QueryUSMSSignatureResponse * @throws UCloudException */ public function queryUSMSSignature(QueryUSMSSignatureRequest $request = null) @@ -241,36 +166,13 @@ public function queryUSMSSignature(QueryUSMSSignatureRequest $request = null) $resp = $this->invoke($request); return new QueryUSMSSignatureResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * QueryUSMSTemplate - 调用接口QueryUSMSTemplate查询短信模板申请状态 * - * See also: https://docs.ucloud.cn/api/usms-api/query_usms_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TemplateId" => (string) 模板ID - * ] - * - * Outputs: - * - * $outputs = [ - * "Data" => (object) 短信模板明细信息,各字段说明详见OutTemplate[ - * "TemplateId" => (string) 短信模板ID - * "Purpose" => (integer) 模板类型,选项:1-验证码类 2-通知类 3-会员推广类 - * "TemplateName" => (string) 短信模板名称 - * "Template" => (string) 短信模板内容 - * "UnsubscribeInfo" => (string) 退订信息;一般填写方式“回T退订”,当purpose为3(也即会员推广类)时,为必填项 - * "Status" => (integer) 短信模板状态;状态说明:0-待审核,1-审核中,2-审核通过,3-审核未通过,4-被禁用 - * "Remark" => (string) 模板说明 - * "ErrDesc" => (string) 审核失败原因 - * "CreateTime" => (integer) 创建时间 - * ] - * ] - * - * @return QueryUSMSTemplateResponse * @throws UCloudException */ public function queryUSMSTemplate(QueryUSMSTemplateRequest $request = null) @@ -278,44 +180,13 @@ public function queryUSMSTemplate(QueryUSMSTemplateRequest $request = null) $resp = $this->invoke($request); return new QueryUSMSTemplateResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SendBatchUSMSMessage - 调用SendBatchUSMSMessage接口批量发送短信 * - * See also: https://docs.ucloud.cn/api/usms-api/send_batch_usms_message - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "TaskContent" => (string) 批量发送内容,该参数是json数组的base64编码结果。发送内容json数组中,每个“模板+签名”组合作为一个子项,每个子项内支持多个号码,示例:发送内容json数组(base64编码前):[{"TemplateId": "UTA20212831C85C", "SigContent": "UCloud", "Target": [{"TemplateParams": ["123456"], "Phone": "18500000123", "ExtendCode": "123", "UserId": "456"} ] } ] 。json数组中各参数的定义:"TemplateId":模板ID,"SigContent"短信签名内容,"Target"具体到号码粒度的发送内容。"Target"中的具体字段有:"TemplateParams"实际发送的模板参数(若使用的是无参数模板,该参数不能传值),"Phone"手机号码, "ExtendCode"短信扩展码, "UserId"自定义业务标识ID。其中必传参数为"TemplateId", "SigContent", "Target"("Target"中必传参数为"Phone")。实际调用本接口时TaskContent传值(发送内容base64编码后)为:W3siVGVtcGxhdGVJZCI6ICJVVEEyMDIxMjgzMUM4NUMiLCAiU2lnQ29udGVudCI6ICJVQ2xvdWQiLCAiVGFyZ2V0IjogW3siVGVtcGxhdGVQYXJhbXMiOiBbIjEyMzQ1NiJdLCAiUGhvbmUiOiAiMTg1MDAwMDAxMjMiLCAiRXh0ZW5kQ29kZSI6ICIxMjMiLCAiVXNlcklkIjogIjQ1NiJ9IF0gfSBdIA== - * ] - * - * Outputs: - * - * $outputs = [ - * "SessionNo" => (string) 本次提交发送任务的唯一ID,可根据该值查询本次发送的短信列表。注:成功提交短信数大于0时,才返回该字段 - * "ReqUuid" => (string) 本次请求Uuid - * "SuccessCount" => (integer) 成功提交短信(未拆分)条数 - * "FailContent" => (array) 未发送成功的详情,返回码非0时该字段有效,可根据该字段数据重发[ - * [ - * "TemplateId" => (string) 模板ID - * "SigContent" => (string) 签名 - * "Target" => (array) 具体号码信息[ - * [ - * "TemplateParams" => (array) 模板参数 - * "Phone" => (string) 手机号 - * "ExtendCode" => (string) 扩展号码 - * "UserId" => (string) 用户自定义ID - * "FailureDetails" => (string) 发送失败原因。注:若模板/签名校验失败,该字段为空 - * ] - * ] - * "FailureDetails" => (string) 未能成功发送的详情。注:模板/签名检验失败时,该字段有效 - * ] - * ] - * ] - * - * @return SendBatchUSMSMessageResponse * @throws UCloudException */ public function sendBatchUSMSMessage(SendBatchUSMSMessageRequest $request = null) @@ -323,32 +194,13 @@ public function sendBatchUSMSMessage(SendBatchUSMSMessageRequest $request = null $resp = $this->invoke($request); return new SendBatchUSMSMessageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * SendUSMSMessage - 调用接口SendUSMSMessage发送短信 * - * See also: https://docs.ucloud.cn/api/usms-api/send_usms_message - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "PhoneNumbers" => (array) 电话号码数组,电话号码格式为(60)1xxxxxxxx,()中为国际长途区号(如中国为86或0086,两种格式都支持),后面为电话号码.若不传入国际区号,如1851623xxxx,则默认为国内手机号 - * "SigContent" => (string) 短信签名内容,请到[USMS控制台](https://console.ucloud.cn/usms)的签名管理页面查看;使用的短信签名必须是已申请并且通过审核; - * "TemplateId" => (string) 模板ID(也即短信模板申请时的工单ID),请到[USMS控制台](https://console.ucloud.cn/usms)的模板管理页面查看;使用的短信模板必须是已申请并通过审核; - * "TemplateParams" => (array) 模板可变参数,以数组的方式填写,举例,TemplateParams.0,TemplateParams.1,... 若模板中无可变参数,则该项可不填写;若模板中有可变参数,则该项为必填项,参数个数需与变量个数保持一致,否则无法发送; - * "ExtendCode" => (string) 短信扩展码,格式为阿拉伯数字串,默认不开通,如需开通请联系 UCloud技术支持 - * "UserId" => (string) 自定义的业务标识ID,字符串( 长度不能超过32 位),不支持 单引号、表情包符号等特殊字符 - * ] - * - * Outputs: - * - * $outputs = [ - * "SessionNo" => (string) 本次提交发送的短信的唯一ID,可根据该值查询本次发送的短信列表 - * "UserId" => (string) 本次提交的自定义业务标识ID,仅当发送时传入有效的UserId,才返回该字段。 - * ] - * - * @return SendUSMSMessageResponse * @throws UCloudException */ public function sendUSMSMessage(SendUSMSMessageRequest $request = null) @@ -356,33 +208,13 @@ public function sendUSMSMessage(SendUSMSMessageRequest $request = null) $resp = $this->invoke($request); return new SendUSMSMessageResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUSMSSignature - 调用接口UpdateUSMSSignature修改未通过审核的短信签名,并重新提交审核 * - * See also: https://docs.ucloud.cn/api/usms-api/update_usms_signature - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID,不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SigId" => (string) 签名ID(也即短信签名申请时的工单ID),支持以数组的方式,举例,以SigIds.0、SigIds.1...SigIds.N方式传入 - * "SigContent" => (string) 新的短信签名内容;长度为2-12个字符, 可包含中文、数字和符号;无需填写【】或[],系统会自动添加 - * "SigType" => (integer) 签名类型,说明如下:0-公司或企业的全称或简称;1-App应用的全称或简称;2-工信部备案网站的全称或简称;3-公众号或小程序的全称或简称;4-商标名的全称或简称;5-政府/机关事业单位/其他单位的全称或简称; - * "SigPurpose" => (integer) 签名用途,0-自用,1-他用; - * "File" => (string) 短信签名的资质证明文件内容,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB。内容格式如下: [file type];[code type],[base64] 如:image/jpeg;base64,5YaF5a65 - * "CertificateType" => (integer) 签名的资质证明文件类型,需与签名类型保持一致,说明如下:0-三证合一/企业营业执照/组织机构代码证书/社会信用代码证书;1-应用商店后台开发者管理截图;2-备案服务商的备案成功截图(含域名,网站名称,备案号);3-公众号或小程序的管理界面截图;4-商标注册证书;5-组织机构代码证书、社会信用代码证书; - * "ProxyFile" => (string) 短信签名授权委托文件内容,需先进行base64编码格式转换,此处填写转换后的字符串。文件大小不超过4 MB;当您是代理并使用第三方的签名时(也即SigPurpose为1-他用),该项为必填项;格式和File类似。 - * "Document" => (string) 短信签名的资质证明文件URL,若未更改审核材料,则该处使用已上传审核材料的URL链接,否则使用File参数 - * "ProxyDoc" => (string) 短信签名授权委托文件URL,若未更改授权委托文件,则该处填写已上传的授权委托文件的URL链接,否则使用ProxyFile参数 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUSMSSignatureResponse * @throws UCloudException */ public function updateUSMSSignature(UpdateUSMSSignatureRequest $request = null) @@ -390,28 +222,13 @@ public function updateUSMSSignature(UpdateUSMSSignatureRequest $request = null) $resp = $this->invoke($request); return new UpdateUSMSSignatureResponse($resp->toArray(), $resp->getRequestId()); } - + + + + /** * UpdateUSMSTemplate - 调用接口UpdateUSMSTemplate修改未通过审核的短信模板,并重新提交审核 * - * See also: https://docs.ucloud.cn/api/usms-api/update_usms_template - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "TemplateId" => (string) 短信模板ID - * "Template" => (string) 新的模板内容。模板名称和模板内容必须提供一个,否则会报错。小于等于600个字 - * "TemplateName" => (string) 新的模板名称。小于等于32个字,每个中文、英文、数组、符合都计为一个字 - * "Remark" => (string) 短信模板申请原因说明,字数不超过128,每个中文、符号、英文、数字等都计为1个字。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateUSMSTemplateResponse * @throws UCloudException */ public function updateUSMSTemplate(UpdateUSMSTemplateRequest $request = null) diff --git a/src/VPC/VPCClient.php b/src/VPC/VPCClient.php deleted file mode 100644 index 4bafa4da..00000000 --- a/src/VPC/VPCClient.php +++ /dev/null @@ -1,2350 +0,0 @@ - (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关的ID - * "SourceIp" => (string) 需要出外网的私网IP地址,例如10.9.7.xx - * "SnatIp" => (string) EIP的ip地址,例如106.75.xx.xx - * "Name" => (string) snat规则名称,默认为“出口规则” - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddSnatRuleResponse - * @throws UCloudException - */ - public function addSnatRule(AddSnatRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new AddSnatRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * AddVPCNetwork - 添加VPC网段 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/add_vpc_network - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 源VPC短ID - * "Network" => (array) 增加网段 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddVPCNetworkResponse - * @throws UCloudException - */ - public function addVPCNetwork(AddVPCNetworkRequest $request = null) - { - $resp = $this->invoke($request); - return new AddVPCNetworkResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * AddWhiteListResource - 添加NAT网关白名单 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/add_white_list_resource - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "ResourceIds" => (array) 可添加白名单的资源Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AddWhiteListResourceResponse - * @throws UCloudException - */ - public function addWhiteListResource(AddWhiteListResourceRequest $request = null) - { - $resp = $this->invoke($request); - return new AddWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * AllocateSecondaryIp - 分配ip(用于uk8s使用) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/allocate_secondary_ip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Mac" => (string) 节点mac - * "ObjectId" => (string) 资源Id - * "SubnetId" => (string) 子网Id(若未指定,则根据zone获取默认子网进行创建) - * "VPCId" => (string) vpcId - * "Ip" => (string) 指定Ip分配 - * ] - * - * Outputs: - * - * $outputs = [ - * "IpInfo" => (object) [ - * "Ip" => (string) - * "Mask" => (string) - * "Gateway" => (string) - * "Mac" => (string) - * "SubnetId" => (string) - * "VPCId" => (string) - * ] - * ] - * - * @return AllocateSecondaryIpResponse - * @throws UCloudException - */ - public function allocateSecondaryIp(AllocateSecondaryIpRequest $request = null) - { - $resp = $this->invoke($request); - return new AllocateSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * AllocateVIP - 根据提供信息,申请内网VIP(Virtual IP),多用于高可用程序作为漂移IP。 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/allocate_vip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "Zone" => (string) 可用区 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 指定vip所属的VPC - * "SubnetId" => (string) 子网id - * "Ip" => (string) 指定ip - * "Count" => (integer) 申请数量,默认: 1 - * "Name" => (string) vip名,默认:VIP - * "Tag" => (string) 业务组名称,默认为Default - * "Remark" => (string) 备注 - * "BusinessId" => (string) 业务组 - * ] - * - * Outputs: - * - * $outputs = [ - * "VIPSet" => (array) 申请到的VIP资源相关信息[ - * [ - * "VIP" => (string) 虚拟ip - * "VIPId" => (string) 虚拟ip id - * "VPCId" => (string) VPC id - * ] - * ] - * "DataSet" => (array) 申请到的VIP地址 - * ] - * - * @return AllocateVIPResponse - * @throws UCloudException - */ - public function allocateVIP(AllocateVIPRequest $request = null) - { - $resp = $this->invoke($request); - return new AllocateVIPResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * AssociateRouteTable - 绑定子网的路由表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/associate_route_table - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetId" => (string) 子网ID - * "RouteTableId" => (string) 路由表资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return AssociateRouteTableResponse - * @throws UCloudException - */ - public function associateRouteTable(AssociateRouteTableRequest $request = null) - { - $resp = $this->invoke($request); - return new AssociateRouteTableResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CloneRouteTable - 将现有的路由表复制为一张新的路由表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/clone_route_table - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RouteTableId" => (string) 被克隆的路由表ID - * ] - * - * Outputs: - * - * $outputs = [ - * "RouteTableId" => (string) 复制后新的路由表资源ID - * ] - * - * @return CloneRouteTableResponse - * @throws UCloudException - */ - public function cloneRouteTable(CloneRouteTableRequest $request = null) - { - $resp = $this->invoke($request); - return new CloneRouteTableResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateNATGW - 创建NAT网关 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_natgw - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWName" => (string) NAT网关名称 - * "EIPIds" => (array) NAT网关绑定的EIPId - * "FirewallId" => (string) NAT网关绑定的防火墙Id - * "SubnetworkIds" => (array) NAT网关绑定的子网Id,默认为空。 - * "VPCId" => (string) NAT网关所属的VPC Id。默认为Default VPC Id - * "IfOpen" => (integer) 白名单开关标记。0表示关闭,1表示开启。默认为0 - * "Tag" => (string) 业务组。默认为空 - * "Remark" => (string) 备注。默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * "NATGWId" => (string) 申请到的NATGateWay Id - * ] - * - * @return CreateNATGWResponse - * @throws UCloudException - */ - public function createNATGW(CreateNATGWRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateNATGWResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateNATGWPolicy - 添加NAT网关端口转发规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_natgw_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "Protocol" => (string) 协议类型。枚举值为:TCP、UDP - * "SrcEIPId" => (string) 源IP。填写对应的EIP Id - * "SrcPort" => (string) 源端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 - * "DstIP" => (string) 目标IP。填写对应的目标IP地址 - * "DstPort" => (string) 目标端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 - * "PolicyName" => (string) 转发策略名称。默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * "PolicyId" => (string) 创建时分配的策略Id - * ] - * - * @return CreateNATGWPolicyResponse - * @throws UCloudException - */ - public function createNATGWPolicy(CreateNATGWPolicyRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateNetworkAcl - 创建网络ACL - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_network_acl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VpcId" => (string) 将要创建的ACL所属VPC的ID - * "AclName" => (string) ACL的名称 - * "Description" => (string) ACL的描述 - * ] - * - * Outputs: - * - * $outputs = [ - * "AclId" => (string) 创建的ACL的ID - * ] - * - * @return CreateNetworkAclResponse - * @throws UCloudException - */ - public function createNetworkAcl(CreateNetworkAclRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateNetworkAclResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateNetworkAclAssociation - 创建ACL的绑定关系 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_network_acl_association - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "AclId" => (string) ACL的ID - * "SubnetworkId" => (string) 需要绑定的子网ID - * ] - * - * Outputs: - * - * $outputs = [ - * "AssociationId" => (string) 创建的绑定关系的ID - * "PrevAssociation" => (object) 该子网之前的绑定关系信息[ - * "AssociationId" => (string) 绑定ID - * "AclId" => (string) ACL的ID - * "SubnetworkId" => (string) 绑定的子网ID - * "CreateTime" => (integer) 创建的Unix时间戳 - * ] - * ] - * - * @return CreateNetworkAclAssociationResponse - * @throws UCloudException - */ - public function createNetworkAclAssociation(CreateNetworkAclAssociationRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateNetworkAclEntry - 创建ACL的规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_network_acl_entry - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) ACL的ID - * "Priority" => (integer) Entry的优先级,对于同样的Direction来说,不能重复 - * "Direction" => (string) 出向或者入向(“Ingress”, "Egress") - * "IpProtocol" => (string) 协议规则描述 - * "CidrBlock" => (string) IPv4段的CIDR表示 - * "PortRange" => (string) 针对的端口范围 - * "EntryAction" => (string) 规则的行为("Accept", "Reject") - * "Description" => (string) 描述。长度限制为不超过32字节。 - * "TargetType" => (integer) 应用目标类型。0代表“子网内全部资源”,1代表“子网内指定资源”,默认为0 - * "TargetResourceIds" => (array) 应用目标资源列表。默认为全部资源生效。TargetType为0时不用填写该值。 - * ] - * - * Outputs: - * - * $outputs = [ - * "EntryId" => (string) 创建的Entry的ID - * ] - * - * @return CreateNetworkAclEntryResponse - * @throws UCloudException - */ - public function createNetworkAclEntry(CreateNetworkAclEntryRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateRouteTable - 创建路由表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_route_table - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 所属的VPC资源ID - * "Name" => (string) 路由表名称。默认为RouteTable - * "Tag" => (string) 路由表所属业务组 - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "RouteTableId" => (string) 路由表ID - * ] - * - * @return CreateRouteTableResponse - * @throws UCloudException - */ - public function createRouteTable(CreateRouteTableRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateRouteTableResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateSubnet - 创建子网 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_subnet - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) VPC资源ID - * "Subnet" => (string) 子网网络地址,例如192.168.0.0 - * "Netmask" => (integer) 子网网络号位数,默认为24 - * "SubnetName" => (string) 子网名称,默认为Subnet - * "Tag" => (string) 业务组名称,默认为Default - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "SubnetId" => (string) 子网ID - * ] - * - * @return CreateSubnetResponse - * @throws UCloudException - */ - public function createSubnet(CreateSubnetRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateSubnetResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateVPC - 创建VPC - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_vpc - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Name" => (string) VPC名称 - * "Network" => (array) VPC网段 - * "Tag" => (string) 业务组名称 - * "Remark" => (string) 备注 - * ] - * - * Outputs: - * - * $outputs = [ - * "VPCId" => (string) VPC资源Id - * ] - * - * @return CreateVPCResponse - * @throws UCloudException - */ - public function createVPC(CreateVPCRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateVPCResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * CreateVPCIntercom - 新建VPC互通关系 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/create_vpc_intercom - * - * Arguments: - * - * $args = [ - * "Region" => (string) 源VPC所在地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 源VPC短ID - * "DstVPCId" => (string) 目的VPC短ID - * "DstRegion" => (string) 目的VPC所在地域,默认与源VPC同地域。 - * "DstProjectId" => (string) 目的VPC项目ID。默认与源VPC同项目。 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return CreateVPCIntercomResponse - * @throws UCloudException - */ - public function createVPCIntercom(CreateVPCIntercomRequest $request = null) - { - $resp = $this->invoke($request); - return new CreateVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteNATGW - 删除NAT网关 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_natgw - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "ReleaseEip" => (boolean) 是否释放绑定的EIP。true:解绑并释放;false:只解绑不释放。默认为false - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteNATGWResponse - * @throws UCloudException - */ - public function deleteNATGW(DeleteNATGWRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteNATGWResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteNATGWPolicy - 删除NAT网关端口转发规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_natgw_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "PolicyId" => (string) 端口转发规则Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteNATGWPolicyResponse - * @throws UCloudException - */ - public function deleteNATGWPolicy(DeleteNATGWPolicyRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteNetworkAcl - 删除网络ACL - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_network_acl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) 需要删除的AclId - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteNetworkAclResponse - * @throws UCloudException - */ - public function deleteNetworkAcl(DeleteNetworkAclRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteNetworkAclResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteNetworkAclAssociation - 删除网络ACL绑定关系 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_network_acl_association - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) 需要删除的AclId - * "SubnetworkId" => (string) 绑定的子网ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteNetworkAclAssociationResponse - * @throws UCloudException - */ - public function deleteNetworkAclAssociation(DeleteNetworkAclAssociationRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteNetworkAclEntry - 删除ACL的规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_network_acl_entry - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) Acl的ID - * "EntryId" => (string) 需要删除的EntryId - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteNetworkAclEntryResponse - * @throws UCloudException - */ - public function deleteNetworkAclEntry(DeleteNetworkAclEntryRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteRouteTable - 删除自定义路由表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_route_table - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RouteTableId" => (string) 路由表资源ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteRouteTableResponse - * @throws UCloudException - */ - public function deleteRouteTable(DeleteRouteTableRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteRouteTableResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteSecondaryIp - 删除ip(用于uk8s使用) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_secondary_ip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "Ip" => (string) ip - * "Mac" => (string) mac - * "SubnetId" => (string) 子网Id - * "VPCId" => (string) VPCId - * "ObjectId" => (string) 资源Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteSecondaryIpResponse - * @throws UCloudException - */ - public function deleteSecondaryIp(DeleteSecondaryIpRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteSnatRule - 删除指定的出口规则(SNAT规则) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_snat_rule - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关的ID - * "SourceIp" => (string) 需要出外网的私网IP地址,例如10.9.7.xx - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteSnatRuleResponse - * @throws UCloudException - */ - public function deleteSnatRule(DeleteSnatRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteSnatRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteSubnet - 删除子网 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_subnet - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetId" => (string) 子网ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteSubnetResponse - * @throws UCloudException - */ - public function deleteSubnet(DeleteSubnetRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteSubnetResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteVPC - 删除VPC - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_vpc - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) VPC资源Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteVPCResponse - * @throws UCloudException - */ - public function deleteVPC(DeleteVPCRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteVPCResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteVPCIntercom - 删除VPC互通关系 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_vpc_intercom - * - * Arguments: - * - * $args = [ - * "Region" => (string) 源VPC所在地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 源VPC短ID - * "DstVPCId" => (string) 目的VPC短ID - * "DstRegion" => (string) 目的VPC所在地域,默认为源VPC所在地域 - * "DstProjectId" => (string) 目的VPC所在项目ID,默认为源VPC所在项目ID - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteVPCIntercomResponse - * @throws UCloudException - */ - public function deleteVPCIntercom(DeleteVPCIntercomRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DeleteWhiteListResource - 删除NAT网关白名单列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/delete_white_list_resource - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "ResourceIds" => (array) 删除白名单的资源Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return DeleteWhiteListResourceResponse - * @throws UCloudException - */ - public function deleteWhiteListResource(DeleteWhiteListResourceRequest $request = null) - { - $resp = $this->invoke($request); - return new DeleteWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNATGW - 获取NAT网关信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_natgw - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWIds" => (array) NAT网关Id。默认为该项目下所有NAT网关 - * "Offset" => (integer) 数据偏移量。默认为0 - * "Limit" => (integer) 数据分页值。默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的实例的总数 - * "DataSet" => (array) 查到的NATGW信息列表[ - * [ - * "NATGWId" => (string) natgw id - * "NATGWName" => (string) natgw名称 - * "CreateTime" => (integer) natgw创建时间 - * "Tag" => (string) 业务组 - * "Remark" => (string) 备注 - * "FirewallId" => (string) 绑定的防火墙Id - * "VPCId" => (string) 所属VPC Id - * "SubnetSet" => (array) 子网 Id[ - * [ - * "SubnetworkId" => (string) 子网id - * "Subnet" => (string) 子网网段 - * "SubnetName" => (string) 子网名字 - * ] - * ] - * "IPSet" => (array) 绑定的EIP 信息[ - * [ - * "EIPId" => (string) 外网IP的 EIPId - * "Weight" => (integer) 权重为100的为出口 - * "BandwidthType" => (string) EIP带宽类型 - * "Bandwidth" => (integer) 带宽 - * "IPResInfo" => (array) 外网IP信息[ - * [ - * "OperatorName" => (string) IP的运营商信息 - * "EIP" => (string) 外网IP - * ] - * ] - * ] - * ] - * "PolicyId" => (array) 转发策略Id - * ] - * ] - * ] - * - * @return DescribeNATGWResponse - * @throws UCloudException - */ - public function describeNATGW(DescribeNATGWRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNATGWResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNATGWPolicy - 展示NAT网关端口转发规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_natgw_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "Limit" => (integer) 返回数据长度,默认为10000 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 满足条件的转发策略总数 - * "DataSet" => (array) 查到的NATGW 转发策略的详细信息[ - * [ - * "NATGWId" => (string) NAT网关Id - * "PolicyId" => (string) 转发策略Id - * "Protocol" => (string) 协议类型 - * "SrcEIP" => (string) 端口转发前端EIP - * "SrcEIPId" => (string) 端口转发前端EIP Id - * "SrcPort" => (string) 源端口 - * "DstIP" => (string) 目的地址 - * "DstPort" => (string) 目的端口 - * "PolicyName" => (string) 转发策略名称 - * ] - * ] - * ] - * - * @return DescribeNATGWPolicyResponse - * @throws UCloudException - */ - public function describeNATGWPolicy(DescribeNATGWPolicyRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNetworkAcl - 获取网络ACL - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_network_acl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Offset" => (integer) 列表偏移量 - * "Limit" => (string) 列表获取的个数限制 - * "VpcId" => (string) 需要获取的ACL所属的VPC的ID - * ] - * - * Outputs: - * - * $outputs = [ - * "AclList" => (array) ACL的信息,具体结构见下方AclInfo[ - * [ - * "VpcId" => (string) ACL所属的VPC ID - * "AclId" => (string) ACL的ID - * "AclName" => (string) 名称 - * "Description" => (string) 描述 - * "Entries" => (array) 所有的规则[ - * [ - * "EntryId" => (string) Entry的ID - * "Priority" => (string) 优先级 - * "Direction" => (string) 出向或者入向 - * "IpProtocol" => (string) 针对的IP协议 - * "CidrBlock" => (string) IP段的CIDR信息 - * "PortRange" => (string) Port的段信息 - * "EntryAction" => (string) 匹配规则的动作 - * "TargetType" => (integer) 应用目标类型。 0代表“子网内全部资源” ,1代表“子网内指定资源” 。 - * "CreateTime" => (integer) 创建的Unix时间戳 - * "UpdateTime" => (integer) 更改的Unix时间戳 - * "TargetResourceList" => (array) 应用目标资源信息。TargetType为0时不返回该值。具体结构见下方TargetResourceInfo[ - * [ - * "SubnetworkId" => (string) 子网ID - * "ResourceName" => (string) 资源名称 - * "ResourceId" => (string) 资源ID - * "ResourceType" => (integer) 资源类型 - * "SubResourceName" => (string) 资源绑定的虚拟网卡的名称 - * "SubResourceId" => (string) 资源绑定的虚拟网卡的ID - * "SubResourceType" => (integer) 资源绑定虚拟网卡的类型 - * "PrivateIp" => (string) 资源内网IP - * ] - * ] - * "TargetResourceCount" => (integer) 应用目标资源数量。TargetType为0时不返回该值。 - * ] - * ] - * "Associations" => (array) 所有的绑定关系,具体结构见下方AssociationInfo[ - * [ - * "AssociationId" => (string) 绑定ID - * "AclId" => (string) ACL的ID - * "SubnetworkId" => (string) 绑定的子网ID - * "CreateTime" => (integer) 创建的Unix时间戳 - * ] - * ] - * "CreateTime" => (integer) 创建的Unix时间戳 - * "UpdateTime" => (integer) 更改的Unix时间戳 - * ] - * ] - * ] - * - * @return DescribeNetworkAclResponse - * @throws UCloudException - */ - public function describeNetworkAcl(DescribeNetworkAclRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNetworkAclResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNetworkAclAssociation - 获取网络ACL的绑定关系列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_network_acl_association - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) Acl的ID - * "Offset" => (integer) 列表偏移量 - * "Limit" => (string) 列表获取的个数限制 - * ] - * - * Outputs: - * - * $outputs = [ - * "AssociationList" => (array) 绑定信息列表[ - * [ - * "AssociationId" => (string) 绑定ID - * "AclId" => (string) ACL的ID - * "SubnetworkId" => (string) 绑定的子网ID - * "CreateTime" => (integer) 创建的Unix时间戳 - * ] - * ] - * ] - * - * @return DescribeNetworkAclAssociationResponse - * @throws UCloudException - */ - public function describeNetworkAclAssociation(DescribeNetworkAclAssociationRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNetworkAclAssociationBySubnet - 获取子网的ACL绑定信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_network_acl_association_by_subnet - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetworkId" => (string) 子网的ID - * ] - * - * Outputs: - * - * $outputs = [ - * "Association" => (object) 绑定信息[ - * "AssociationId" => (string) 绑定ID - * "AclId" => (string) ACL的ID - * "SubnetworkId" => (string) 绑定的子网ID - * "CreateTime" => (integer) 创建的Unix时间戳 - * ] - * ] - * - * @return DescribeNetworkAclAssociationBySubnetResponse - * @throws UCloudException - */ - public function describeNetworkAclAssociationBySubnet(DescribeNetworkAclAssociationBySubnetRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNetworkAclAssociationBySubnetResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeNetworkAclEntry - 获取ACL的规则信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_network_acl_entry - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "AclId" => (string) ACL的ID - * ] - * - * Outputs: - * - * $outputs = [ - * "EntryList" => (array) 所有的规则信息[ - * [ - * "EntryId" => (string) Entry的ID - * "Priority" => (string) 优先级 - * "Direction" => (string) 出向或者入向 - * "IpProtocol" => (string) 针对的IP协议 - * "CidrBlock" => (string) IP段的CIDR信息 - * "PortRange" => (string) Port的段信息 - * "EntryAction" => (string) 匹配规则的动作 - * "TargetType" => (integer) 应用目标类型。 0代表“子网内全部资源” ,1代表“子网内指定资源” 。 - * "CreateTime" => (integer) 创建的Unix时间戳 - * "UpdateTime" => (integer) 更改的Unix时间戳 - * "TargetResourceList" => (array) 应用目标资源信息。TargetType为0时不返回该值。具体结构见下方TargetResourceInfo[ - * [ - * "SubnetworkId" => (string) 子网ID - * "ResourceName" => (string) 资源名称 - * "ResourceId" => (string) 资源ID - * "ResourceType" => (integer) 资源类型 - * "SubResourceName" => (string) 资源绑定的虚拟网卡的名称 - * "SubResourceId" => (string) 资源绑定的虚拟网卡的ID - * "SubResourceType" => (integer) 资源绑定虚拟网卡的类型 - * "PrivateIp" => (string) 资源内网IP - * ] - * ] - * "TargetResourceCount" => (integer) 应用目标资源数量。TargetType为0时不返回该值。 - * ] - * ] - * ] - * - * @return DescribeNetworkAclEntryResponse - * @throws UCloudException - */ - public function describeNetworkAclEntry(DescribeNetworkAclEntryRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeRouteTable - 获取路由表详细信息(包括路由策略) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_route_table - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) 所属VPC的资源ID - * "RouteTableId" => (string) 路由表资源ID - * "OffSet" => (integer) 数据偏移量。默认为0 - * "Limit" => (integer) 数据分页值。默认为20 - * "BusinessId" => (string) 业务组ID - * ] - * - * Outputs: - * - * $outputs = [ - * "RouteTables" => (array) 路由表信息[ - * [ - * "RouteTableId" => (string) 路由表资源ID - * "RouteTableType" => (integer) 路由表类型。1为默认路由表,0为自定义路由表 - * "SubnetCount" => (integer) 绑定该路由表的子网数量 - * "VPCId" => (string) 路由表所属的VPC资源ID - * "VPCName" => (string) 路由表所属的VPC资源名称 - * "Tag" => (string) 路由表所属业务组 - * "Remark" => (string) 路由表备注 - * "CreateTime" => (integer) 创建时间戳 - * "RouteRules" => (array) 路由规则[ - * [ - * "AccountId" => (integer) 项目ID信息 - * "DstAddr" => (string) 目的地址 - * "DstPort" => (integer) 保留字段,暂未使用 - * "NexthopId" => (string) 路由下一跳资源ID - * "NexthopType" => (string) 路由表下一跳类型。LOCAL,本VPC内部通信路由;PUBLIC,公共服务路由;CNAT,外网路由;UDPN,跨域高速通道路由;HYBRIDGW,混合云路由;INSTANCE,实例路由;VNET,VPC联通路由;IPSEC VPN,指向VPN网关的路由。 - * "OriginAddr" => (string) 保留字段,暂未使用 - * "Priority" => (integer) 保留字段,暂未使用 - * "Remark" => (string) 路由规则备注 - * "RouteRuleId" => (string) 规则ID - * "RouteTableId" => (string) 路由表资源ID - * "RuleType" => (integer) 路由规则类型。0,系统路由规则;1,自定义路由规则 - * "SrcAddr" => (string) 保留字段,暂未使用 - * "SrcPort" => (integer) 保留字段,暂未使用 - * "VNetId" => (string) 所属的VPC - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) RouteTables字段的数量 - * ] - * - * @return DescribeRouteTableResponse - * @throws UCloudException - */ - public function describeRouteTable(DescribeRouteTableRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeRouteTableResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeSecondaryIp - 查询SecondaryIp(uk8s使用) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_secondary_ip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SubnetId" => (string) 子网Id - * "VPCId" => (string) VPCId - * "Ip" => (string) Ip - * "Mac" => (string) Mac - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) [ - * [ - * "Ip" => (string) - * "Mask" => (string) - * "Gateway" => (string) - * "Mac" => (string) - * "SubnetId" => (string) - * "VPCId" => (string) - * ] - * ] - * ] - * - * @return DescribeSecondaryIpResponse - * @throws UCloudException - */ - public function describeSecondaryIp(DescribeSecondaryIpRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeSnatRule - 获取Nat网关的出口规则(SNAT规则) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_snat_rule - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关的ID - * "SourceIp" => (string) 需要出外网的私网IP地址,例如10.9.7.xx - * "SnatIp" => (string) EIP的ip地址,例如106.75.xx.xx - * "Offset" => (string) 偏移,默认为0 - * "Limit" => (string) 分页,默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 某个NAT网关的所有Snat规则[ - * [ - * "SnatIp" => (string) EIP地址,如106.76.xx.xx - * "SourceIp" => (string) 资源的内网IP地址 - * "SubnetworkId" => (string) SourceIp所属的子网id - * "Name" => (string) snat规则名称 - * ] - * ] - * "TotalCount" => (integer) 规则数量 - * ] - * - * @return DescribeSnatRuleResponse - * @throws UCloudException - */ - public function describeSnatRule(DescribeSnatRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeSnatRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeSubnet - 获取子网信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_subnet - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetIds" => (array) 子网id数组,适用于一次查询多个子网信息 - * "SubnetId" => (string) 子网id,适用于一次查询一个子网信息 - * "RouteTableId" => (string) 路由表Id - * "VPCId" => (string) VPC资源id - * "Tag" => (string) 业务组名称,默认为Default - * "Offset" => (integer) 偏移量,默认为0 - * "Limit" => (integer) 列表长度,默认为20 - * "ShowAvailableIPs" => (boolean) 是否返回子网的可用IP数,true为是,false为否,默认不返回 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 子网总数量 - * "DataSet" => (array) 子网信息数组,具体资源见下方SubnetInfo[ - * [ - * "Zone" => (string) 可用区名称 - * "IPv6Network" => (string) 子网关联的IPv6网段 - * "VPCId" => (string) VPCId - * "VPCName" => (string) VPC名称 - * "SubnetId" => (string) 子网Id - * "SubnetName" => (string) 子网名称 - * "Remark" => (string) 备注 - * "Tag" => (string) 业务组 - * "SubnetType" => (integer) 子网类型 - * "Subnet" => (string) 子网网段 - * "Netmask" => (string) 子网掩码 - * "Gateway" => (string) 子网网关 - * "CreateTime" => (integer) 创建时间 - * "HasNATGW" => (boolean) 是否有natgw - * "RouteTableId" => (string) 路由表Id - * "AvailableIPs" => (integer) 可用IP数量 - * ] - * ] - * ] - * - * @return DescribeSubnetResponse - * @throws UCloudException - */ - public function describeSubnet(DescribeSubnetRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeSubnetResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeSubnetResource - 展示子网资源 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_subnet_resource - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetId" => (string) 子网id - * "ResourceType" => (string) 资源类型,默认为全部资源类型。枚举值为:UHOST,云主机;PHOST,物理云主机;ULB,负载均衡;UHADOOP_HOST,hadoop节点;UFORTRESS_HOST,堡垒机;UNATGW,NAT网关;UKAFKA,Kafka消息队列;UMEM,内存存储;DOCKER,容器集群;UDB,数据库;UDW,数据仓库;VIP,内网VIP. - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * "Limit" => (integer) 单页返回数据长度,默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "TotalCount" => (integer) 总数 - * "DataSet" => (array) 返回数据集,请见SubnetResource[ - * [ - * "Name" => (string) 名称 - * "ResourceId" => (string) 资源Id - * "ResourceType" => (string) 资源类型。对应的资源类型:UHOST,云主机;PHOST,物理云主机;ULB,负载均衡;UHADOOP_HOST,hadoop节点;UFORTRESS_HOST,堡垒机;UNATGW,NAT网关;UKAFKA,分布式消息系统;UMEM,内存存储;DOCKER,容器集群;UDB,数据库;UDW,数据仓库;VIP,内网VIP. - * "IP" => (string) 资源ip - * ] - * ] - * ] - * - * @return DescribeSubnetResourceResponse - * @throws UCloudException - */ - public function describeSubnetResource(DescribeSubnetResourceRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeSubnetResourceResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeVIP - 获取内网VIP详细信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_vip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "Zone" => (string) 可用区。参见 [可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) vpc的id,指定SubnetId时必填 - * "SubnetId" => (string) 子网id,不指定则获取VPCId下的所有vip - * "VIPId" => (string) VIP ID - * "Tag" => (string) 业务组名称, 默认为 Default - * "BusinessId" => (string) 业务组 - * ] - * - * Outputs: - * - * $outputs = [ - * "VIPSet" => (array) 内网VIP详情,请见VIPDetailSet[ - * [ - * "Zone" => (string) 地域 - * "VIPId" => (string) 虚拟ip id - * "CreateTime" => (integer) 创建时间 - * "RealIp" => (string) 真实主机ip - * "VIP" => (string) 虚拟ip - * "SubnetId" => (string) 子网id - * "VPCId" => (string) VPC id - * "Name" => (string) VIP名称 - * "Remark" => (string) VIP备注 - * "Tag" => (string) VIP所属业务组 - * ] - * ] - * "DataSet" => (array) 内网VIP地址列表 - * "TotalCount" => (integer) vip数量 - * ] - * - * @return DescribeVIPResponse - * @throws UCloudException - */ - public function describeVIP(DescribeVIPRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeVIPResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeVPC - 获取VPC信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_vpc - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCIds" => (array) VPCId - * "Tag" => (string) 业务组名称 - * "Offset" => (integer) - * "Limit" => (integer) - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) vpc信息,具体结构见下方VPCInfo[ - * [ - * "NetworkInfo" => (array) [ - * [ - * "Network" => (string) vpc地址空间 - * "SubnetCount" => (integer) 地址空间中子网数量 - * ] - * ] - * "SubnetCount" => (integer) - * "CreateTime" => (integer) - * "UpdateTime" => (integer) - * "Tag" => (string) - * "Name" => (string) - * "VPCId" => (string) VPCId - * "Network" => (array) - * "IPv6Network" => (string) VPC关联的IPv6网段 - * "OperatorName" => (string) VPC关联的IPv6网段所属运营商 - * ] - * ] - * ] - * - * @return DescribeVPCResponse - * @throws UCloudException - */ - public function describeVPC(DescribeVPCRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeVPCResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeVPCIntercom - 获取VPC互通信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_vpc_intercom - * - * Arguments: - * - * $args = [ - * "Region" => (string) 源VPC所在地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "VPCId" => (string) VPC短ID - * "DstRegion" => (string) 目的VPC所在地域,默认为全部地域 - * "DstProjectId" => (string) 目的项目ID,默认为全部项目 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 联通VPC信息数组[ - * [ - * "ProjectId" => (string) 项目Id - * "VPCType" => (integer) vpc类型(1表示托管VPC,0表示公有云VPC) - * "AccountId" => (integer) 项目Id(数字) - * "Network" => (array) VPC的地址空间 - * "DstRegion" => (string) 所属地域 - * "Name" => (string) VPC名字 - * "VPCId" => (string) VPCId - * "Tag" => (string) 业务组(未分组显示为 Default) - * ] - * ] - * ] - * - * @return DescribeVPCIntercomResponse - * @throws UCloudException - */ - public function describeVPCIntercom(DescribeVPCIntercomRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * DescribeWhiteListResource - 展示NAT网关白名单资源列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/describe_white_list_resource - * - * Arguments: - * - * $args = [ - * "ProjectId" => (string) 项目id - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "NATGWIds" => (array) NAT网关的Id - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 白名单资源的详细信息,详见DescribeResourceWhiteListDataSet[ - * [ - * "NATGWId" => (string) NATGateWay Id - * "IfOpen" => (integer) 白名单开关标记 - * "ObjectIPInfo" => (array) 白名单详情[ - * [ - * "GwType" => (string) natgw字符串 - * "PrivateIP" => (string) 白名单资源的内网IP - * "ResourceId" => (string) 白名单资源Id信息 - * "ResourceName" => (string) 白名单资源名称 - * "ResourceType" => (string) 白名单资源类型 - * "SubResourceId" => (string) 资源绑定的虚拟网卡的实例ID - * "SubResourceName" => (string) 资源绑定的虚拟网卡的实例名称 - * "SubResourceType" => (string) 资源绑定的虚拟网卡的类型 - * "VPCId" => (string) 白名单资源所属VPCId - * ] - * ] - * ] - * ] - * "TotalCount" => (integer) 上述DataSet总数量 - * ] - * - * @return DescribeWhiteListResourceResponse - * @throws UCloudException - */ - public function describeWhiteListResource(DescribeWhiteListResourceRequest $request = null) - { - $resp = $this->invoke($request); - return new DescribeWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * EnableWhiteList - 修改NAT网关白名单开关 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/enable_white_list - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "IfOpen" => (integer) 白名单开关标记。0:关闭;1:开启。默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return EnableWhiteListResponse - * @throws UCloudException - */ - public function enableWhiteList(EnableWhiteListRequest $request = null) - { - $resp = $this->invoke($request); - return new EnableWhiteListResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * GetAvailableResourceForPolicy - 获取NAT网关可配置端口转发规则的资源信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/get_available_resource_for_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关Id - * "Limit" => (integer) 返回数据长度,默认为20 - * "Offset" => (integer) 列表起始位置偏移量,默认为0 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 支持资源类型的信息[ - * [ - * "ResourceId" => (string) 资源的Id - * "PrivateIP" => (string) 资源对应的内网Ip - * "ResourceType" => (string) 资源类型。"uhost":云主机; "upm",物理云主机; "hadoophost":hadoop节点; "fortresshost":堡垒机: "udockhost",容器 - * ] - * ] - * ] - * - * @return GetAvailableResourceForPolicyResponse - * @throws UCloudException - */ - public function getAvailableResourceForPolicy(GetAvailableResourceForPolicyRequest $request = null) - { - $resp = $this->invoke($request); - return new GetAvailableResourceForPolicyResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * GetAvailableResourceForSnatRule - 获取可用于添加snat规则(出口规则)的资源列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/get_available_resource_for_snat_rule - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关Id - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 返回的资源详细信息[ - * [ - * "ResourceId" => (string) 资源ID - * "ResourceName" => (string) 资源名称 - * "PrivateIP" => (string) 资源内网IP - * "ResourceType" => (string) 资源类型 - * "SubnetworkId" => (string) 资源所属VPC的ID - * "VPCId" => (string) 资源所属子网的ID - * ] - * ] - * "TotalCount" => (integer) 总数 - * ] - * - * @return GetAvailableResourceForSnatRuleResponse - * @throws UCloudException - */ - public function getAvailableResourceForSnatRule(GetAvailableResourceForSnatRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new GetAvailableResourceForSnatRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * GetAvailableResourceForWhiteList - 获取NAT网关可添加白名单的资源 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/get_available_resource_for_white_list - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关Id - * "Offset" => (integer) 数据偏移量, 默认为0 - * "Limit" => (integer) 数据分页值, 默认为20 - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 返回白名单列表的详细信息[ - * [ - * "ResourceId" => (string) 资源类型Id - * "ResourceName" => (string) 资源名称 - * "PrivateIP" => (string) 资源的内网Ip - * "ResourceType" => (string) 资源类型。"uhost":云主机; "upm",物理云主机; "hadoophost":hadoop节点; "fortresshost":堡垒机: "udockhost",容器 - * "SubResourceName" => (string) 资源绑定的虚拟网卡的实例名称 - * "VPCId" => (string) 资源所属VPCId - * "SubnetworkId" => (string) 资源所属子网Id - * "SubResourceId" => (string) 资源绑定的虚拟网卡的实例ID - * "SubResourceType" => (string) 资源绑定的虚拟网卡的实例类型 - * ] - * ] - * "TotalCount" => (integer) 白名单资源列表的总的个数 - * ] - * - * @return GetAvailableResourceForWhiteListResponse - * @throws UCloudException - */ - public function getAvailableResourceForWhiteList(GetAvailableResourceForWhiteListRequest $request = null) - { - $resp = $this->invoke($request); - return new GetAvailableResourceForWhiteListResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * GetNetworkAclTargetResource - 获取ACL规则应用目标列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/get_network_acl_target_resource - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "SubnetworkId" => (array) 子网ID。 - * ] - * - * Outputs: - * - * $outputs = [ - * "TargetResourceList" => (array) ACL规则应用目标资源列表,具体结构见下方TargetResourceInfo[ - * [ - * "SubnetworkId" => (string) 子网ID - * "ResourceName" => (string) 资源名称 - * "ResourceId" => (string) 资源ID - * "ResourceType" => (integer) 资源类型 - * "SubResourceName" => (string) 资源绑定的虚拟网卡的名称 - * "SubResourceId" => (string) 资源绑定的虚拟网卡的ID - * "SubResourceType" => (integer) 资源绑定虚拟网卡的类型 - * "PrivateIp" => (string) 资源内网IP - * ] - * ] - * "TotalCount" => (integer) ACL规则应用目标资源总数 - * ] - * - * @return GetNetworkAclTargetResourceResponse - * @throws UCloudException - */ - public function getNetworkAclTargetResource(GetNetworkAclTargetResourceRequest $request = null) - { - $resp = $this->invoke($request); - return new GetNetworkAclTargetResourceResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * ListSubnetForNATGW - 展示NAT网关可绑定的子网列表 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/list_subnet_for_natgw - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) NAT网关所属VPC Id。默认值为Default VPC Id - * ] - * - * Outputs: - * - * $outputs = [ - * "DataSet" => (array) 具体参数请见NatgwSubnetDataSet[ - * [ - * "SubnetId" => (string) 子网id - * "Subnet" => (string) 子网网段 - * "Netmask" => (string) 掩码 - * "SubnetName" => (string) 子网名字 - * "HasNATGW" => (boolean) 是否绑定NATGW - * ] - * ] - * ] - * - * @return ListSubnetForNATGWResponse - * @throws UCloudException - */ - public function listSubnetForNATGW(ListSubnetForNATGWRequest $request = null) - { - $resp = $this->invoke($request); - return new ListSubnetForNATGWResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * ModifyRouteRule - 路由策略增、删、改 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/modify_route_rule - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RouteTableId" => (string) 通过DescribeRouteTable拿到 - * "RouteRule" => (array) 格式: RouteRuleId | 目的网段 | 下一跳类型(支持INSTANCE、VIP) | 下一跳 |优先级(保留字段,填写0即可)| 备注 | 增、删、改标志(add/delete/update) 。"添加"示例: test_id | 10.8.0.0/16 | instance | uhost-xd8ja | 0 | Default Route Rule| add (添加的RouteRuleId填任意非空字符串) 。"删除"示例: routerule-xk3jxa | 10.8.0.0/16 | instance | uhost-xd8ja | 0 | Default Route Rule| delete (RouteRuleId来自DescribeRouteTable中) 。“修改”示例: routerule-xk3jxa | 10.8.0.0/16 | instance | uhost-cjksa2 | 0 | Default Route Rule| update (RouteRuleId来自DescribeRouteTable中) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ModifyRouteRuleResponse - * @throws UCloudException - */ - public function modifyRouteRule(ModifyRouteRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new ModifyRouteRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * MoveSecondaryIPMac - 把 Secondary IP 从旧 MAC 迁移到新 MAC - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/move_secondary_ip_mac - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "Ip" => (string) Secondary IP - * "OldMac" => (string) 旧 Mac。Secondary IP 当前所绑定的 Mac - * "NewMac" => (string) 新 Mac。Secondary IP 迁移的目的 Mac - * "SubnetId" => (string) 子网 ID。IP/OldMac/NewMac 三者必须在同一子网 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return MoveSecondaryIPMacResponse - * @throws UCloudException - */ - public function moveSecondaryIPMac(MoveSecondaryIPMacRequest $request = null) - { - $resp = $this->invoke($request); - return new MoveSecondaryIPMacResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * ReleaseVIP - 释放VIP资源 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/release_vip - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域 - * "Zone" => (string) 可用区 - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写 - * "VIPId" => (string) 内网VIP的id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return ReleaseVIPResponse - * @throws UCloudException - */ - public function releaseVIP(ReleaseVIPRequest $request = null) - { - $resp = $this->invoke($request); - return new ReleaseVIPResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * SetGwDefaultExport - 设置NAT网关的默认出口 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/set_gw_default_export - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "ExportIp" => (string) NAT网关绑定的EIP。ExportIp和ExportEipId必填一个 - * "ExportEipId" => (string) NAT网关绑定的EIP Id。ExportIp和ExportEipId必填一个 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return SetGwDefaultExportResponse - * @throws UCloudException - */ - public function setGwDefaultExport(SetGwDefaultExportRequest $request = null) - { - $resp = $this->invoke($request); - return new SetGwDefaultExportResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateNATGWPolicy - 更新NAT网关端口转发规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_natgw_policy - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关Id - * "PolicyId" => (string) 转发策略Id - * "Protocol" => (string) 协议类型。枚举值为:TCP 、 UDP - * "SrcEIPId" => (string) 源IP。填写对应的EIP Id - * "SrcPort" => (string) 源端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-6553 - * "DstIP" => (string) 目标IP。填写对应的目标IP地址 - * "DstPort" => (string) 目标端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 - * "PolicyName" => (string) 转发策略名称。默认为空 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateNATGWPolicyResponse - * @throws UCloudException - */ - public function updateNATGWPolicy(UpdateNATGWPolicyRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateNATGWSubnet - 更新NAT网关绑定的子网 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_natgw_subnet - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "NATGWId" => (string) NAT网关Id - * "SubnetworkIds" => (array) NAT网关绑定的子网Id - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateNATGWSubnetResponse - * @throws UCloudException - */ - public function updateNATGWSubnet(UpdateNATGWSubnetRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateNATGWSubnetResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateNetworkAcl - 更改ACL - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_network_acl - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclName" => (string) Acl的名称 - * "AclId" => (string) 需要更改的ACL ID - * "Description" => (string) 描述 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateNetworkAclResponse - * @throws UCloudException - */ - public function updateNetworkAcl(UpdateNetworkAclRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateNetworkAclResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateNetworkAclEntry - 更新ACL的规则 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_network_acl_entry - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "AclId" => (string) ACL的ID - * "EntryId" => (string) 需要更新的Entry Id - * "Priority" => (integer) Entry的优先级,对于同样的Direction来说,不能重复 - * "Direction" => (string) 出向或者入向(“Ingress”, "Egress") - * "IpProtocol" => (string) 针对的协议规则 - * "CidrBlock" => (string) IPv4段的CIDR表示 - * "PortRange" => (string) 针对的端口范围 - * "EntryAction" => (string) 规则的行为("Accept", "Reject") - * "Description" => (string) 描述 - * "TargetType" => (integer) 应用目标类型。0代表“子网内全部资源”, 1代表“子网内指定资源”。默认为0 - * "TargetResourceIds" => (array) 应用目标资源列表。默认为全部资源生效。TargetType为0时不用填写该值 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateNetworkAclEntryResponse - * @throws UCloudException - */ - public function updateNetworkAclEntry(UpdateNetworkAclEntryRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateRouteTableAttribute - 更新路由表基本信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_route_table_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "RouteTableId" => (string) 路由表ID - * "Name" => (string) 名称 - * "Remark" => (string) 备注 - * "Tag" => (string) 业务组名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateRouteTableAttributeResponse - * @throws UCloudException - */ - public function updateRouteTableAttribute(UpdateRouteTableAttributeRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateRouteTableAttributeResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateSnatRule - 更新指定的出口规则(SNAT规则) - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_snat_rule - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) - * "NATGWId" => (string) NAT网关的ID, - * "SourceIp" => (string) 需要出外网的私网IP地址,例如10.9.7.xx - * "SnatIp" => (string) EIP的ip地址,例如106.75.xx.xx - * "Name" => (string) snat名称,即出口规则名称 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateSnatRuleResponse - * @throws UCloudException - */ - public function updateSnatRule(UpdateSnatRuleRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateSnatRuleResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateSubnetAttribute - 更新子网信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_subnet_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "SubnetId" => (string) 子网ID - * "Name" => (string) 子网名称(如果Name不填写,Tag必须填写) - * "Tag" => (string) 业务组名称(如果Tag不填写,Name必须填写) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateSubnetAttributeResponse - * @throws UCloudException - */ - public function updateSubnetAttribute(UpdateSubnetAttributeRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateSubnetAttributeResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateVIPAttribute - 更新VIP信息 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_vip_attribute - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VIPId" => (string) 内网VIP的资源Id - * "Remark" => (string) 内网VIP的备注 - * "Name" => (string) 内网VIP的名称 - * "Tag" => (string) 内网VIP所属的业务组 - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateVIPAttributeResponse - * @throws UCloudException - */ - public function updateVIPAttribute(UpdateVIPAttributeRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateVIPAttributeResponse($resp->toArray(), $resp->getRequestId()); - } - - /** - * UpdateVPCNetwork - 更新VPC网段 - * - * See also: https://docs.ucloud.cn/api/vpc2.0-api/update_vpc_network - * - * Arguments: - * - * $args = [ - * "Region" => (string) 地域。 参见 [地域和可用区列表](../summary/regionlist.html) - * "ProjectId" => (string) 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) - * "VPCId" => (string) VPC的ID - * "Network" => (array) 需要保留的VPC网段。当前仅支持删除VPC网段,添加网段请参考[AddVPCNetwork](https://docs.ucloud.cn/api/vpc2.0-api/add_vpc_network) - * ] - * - * Outputs: - * - * $outputs = [ - * ] - * - * @return UpdateVPCNetworkResponse - * @throws UCloudException - */ - public function updateVPCNetwork(UpdateVPCNetworkRequest $request = null) - { - $resp = $this->invoke($request); - return new UpdateVPCNetworkResponse($resp->toArray(), $resp->getRequestId()); - } -} diff --git a/src/VPC/Apis/AddSnatRuleRequest.php b/src/VPC2.0/Apis/AddSnatRuleRequest.php similarity index 90% rename from src/VPC/Apis/AddSnatRuleRequest.php rename to src/VPC2.0/Apis/AddSnatRuleRequest.php index 531f0792..f833c079 100644 --- a/src/VPC/Apis/AddSnatRuleRequest.php +++ b/src/VPC2.0/Apis/AddSnatRuleRequest.php @@ -1,6 +1,7 @@ markRequired("SnatIp"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关的ID * @@ -86,11 +85,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * SourceIp: 需要出外网的私网IP地址,例如10.9.7.xx * @@ -106,11 +104,10 @@ public function getSourceIp() * * @param string $sourceIp */ - public function setSourceIp($sourceIp) + public function setSourceIp(string $sourceIp) { $this->set("SourceIp", $sourceIp); } - /** * SnatIp: EIP的ip地址,例如106.75.xx.xx * @@ -126,11 +123,10 @@ public function getSnatIp() * * @param string $snatIp */ - public function setSnatIp($snatIp) + public function setSnatIp(string $snatIp) { $this->set("SnatIp", $snatIp); } - /** * Name: snat规则名称,默认为“出口规则” * @@ -146,7 +142,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/VPC/Apis/AddSnatRuleResponse.php b/src/VPC2.0/Apis/AddSnatRuleResponse.php similarity index 93% rename from src/VPC/Apis/AddSnatRuleResponse.php rename to src/VPC2.0/Apis/AddSnatRuleResponse.php index c3a47dbb..33e6f000 100644 --- a/src/VPC/Apis/AddSnatRuleResponse.php +++ b/src/VPC2.0/Apis/AddSnatRuleResponse.php @@ -1,6 +1,7 @@ markRequired("Network"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 源VPC短ID * @@ -85,11 +84,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Network: 增加网段 * diff --git a/src/VPC/Apis/AddVPCNetworkResponse.php b/src/VPC2.0/Apis/AddVPCNetworkResponse.php similarity index 93% rename from src/VPC/Apis/AddVPCNetworkResponse.php rename to src/VPC2.0/Apis/AddVPCNetworkResponse.php index 76553628..61ae41d9 100644 --- a/src/VPC/Apis/AddVPCNetworkResponse.php +++ b/src/VPC2.0/Apis/AddVPCNetworkResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * ResourceIds: 可添加白名单的资源Id * diff --git a/src/VPC/Apis/AddWhiteListResourceResponse.php b/src/VPC2.0/Apis/AddWhiteListResourceResponse.php similarity index 93% rename from src/VPC/Apis/AddWhiteListResourceResponse.php rename to src/VPC2.0/Apis/AddWhiteListResourceResponse.php index 6e6f731d..0febf1da 100644 --- a/src/VPC/Apis/AddWhiteListResourceResponse.php +++ b/src/VPC2.0/Apis/AddWhiteListResourceResponse.php @@ -1,6 +1,7 @@ markRequired("ObjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -67,11 +67,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -87,11 +86,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Mac: 节点mac * @@ -107,11 +105,10 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } - /** * ObjectId: 资源Id * @@ -127,11 +124,10 @@ public function getObjectId() * * @param string $objectId */ - public function setObjectId($objectId) + public function setObjectId(string $objectId) { $this->set("ObjectId", $objectId); } - /** * SubnetId: 子网Id(若未指定,则根据zone获取默认子网进行创建) * @@ -147,11 +143,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: vpcId * @@ -167,11 +162,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Ip: 指定Ip分配 * @@ -187,7 +181,7 @@ public function getIp() * * @param string $ip */ - public function setIp($ip) + public function setIp(string $ip) { $this->set("Ip", $ip); } diff --git a/src/VPC/Apis/AllocateSecondaryIpResponse.php b/src/VPC2.0/Apis/AllocateSecondaryIpResponse.php similarity index 80% rename from src/VPC/Apis/AllocateSecondaryIpResponse.php rename to src/VPC2.0/Apis/AllocateSecondaryIpResponse.php index e1fc0e67..9c8a48e3 100644 --- a/src/VPC/Apis/AllocateSecondaryIpResponse.php +++ b/src/VPC2.0/Apis/AllocateSecondaryIpResponse.php @@ -1,6 +1,7 @@ get("IpInfo")); + return new IpInfoModel($this->get("IpInfo")); } /** * IpInfo: * - * @param IpInfo $ipInfo + * @param IpInfoModel $ipInfo */ - public function setIpInfo(array $ipInfo) + public function setIpInfo(IpInfoModel $ipInfo) { $this->set("IpInfo", $ipInfo->getAll()); } diff --git a/src/VPC/Apis/AllocateVIPRequest.php b/src/VPC2.0/Apis/AllocateVIPRequest.php similarity index 88% rename from src/VPC/Apis/AllocateVIPRequest.php rename to src/VPC2.0/Apis/AllocateVIPRequest.php index 173075ff..03afc5ed 100644 --- a/src/VPC/Apis/AllocateVIPRequest.php +++ b/src/VPC2.0/Apis/AllocateVIPRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域 @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区 * @@ -65,11 +65,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -85,11 +84,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 指定vip所属的VPC * @@ -105,11 +103,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网id * @@ -125,11 +122,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Ip: 指定ip * @@ -145,11 +141,10 @@ public function getIp() * * @param string $ip */ - public function setIp($ip) + public function setIp(string $ip) { $this->set("Ip", $ip); } - /** * Count: 申请数量,默认: 1 * @@ -165,11 +160,10 @@ public function getCount() * * @param int $count */ - public function setCount($count) + public function setCount(int $count) { $this->set("Count", $count); } - /** * Name: vip名,默认:VIP * @@ -185,11 +179,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务组名称,默认为Default * @@ -205,11 +198,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -225,11 +217,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * BusinessId: 业务组 * @@ -245,7 +236,7 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } diff --git a/src/VPC/Apis/AllocateVIPResponse.php b/src/VPC2.0/Apis/AllocateVIPResponse.php similarity index 90% rename from src/VPC/Apis/AllocateVIPResponse.php rename to src/VPC2.0/Apis/AllocateVIPResponse.php index 3757c03e..870907ba 100644 --- a/src/VPC/Apis/AllocateVIPResponse.php +++ b/src/VPC2.0/Apis/AllocateVIPResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VIPSet($item)); + array_push($result, new VIPSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getVIPSet() /** * VIPSet: 申请到的VIP资源相关信息 * - * @param VIPSet[] $vipSet + * @param VIPSetModel[] $vipSet */ public function setVIPSet(array $vipSet) { @@ -54,7 +56,6 @@ public function setVIPSet(array $vipSet) } return $result; } - /** * DataSet: 申请到的VIP地址 * diff --git a/src/VPC/Apis/AssociateRouteTableRequest.php b/src/VPC2.0/Apis/AssociateRouteTableRequest.php similarity index 91% rename from src/VPC/Apis/AssociateRouteTableRequest.php rename to src/VPC2.0/Apis/AssociateRouteTableRequest.php index 848663ce..8f59eba2 100644 --- a/src/VPC/Apis/AssociateRouteTableRequest.php +++ b/src/VPC2.0/Apis/AssociateRouteTableRequest.php @@ -1,6 +1,7 @@ markRequired("RouteTableId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网ID * @@ -86,11 +85,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * RouteTableId: 路由表资源ID * @@ -106,7 +104,7 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } diff --git a/src/VPC/Apis/AssociateRouteTableResponse.php b/src/VPC2.0/Apis/AssociateRouteTableResponse.php similarity index 93% rename from src/VPC/Apis/AssociateRouteTableResponse.php rename to src/VPC2.0/Apis/AssociateRouteTableResponse.php index bfffc17d..f5c3f1c2 100644 --- a/src/VPC/Apis/AssociateRouteTableResponse.php +++ b/src/VPC2.0/Apis/AssociateRouteTableResponse.php @@ -1,6 +1,7 @@ markRequired("RouteTableId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RouteTableId: 被克隆的路由表ID * @@ -85,7 +84,7 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } diff --git a/src/VPC/Apis/CloneRouteTableResponse.php b/src/VPC2.0/Apis/CloneRouteTableResponse.php similarity index 90% rename from src/VPC/Apis/CloneRouteTableResponse.php rename to src/VPC2.0/Apis/CloneRouteTableResponse.php index 9e2dd1c8..5edbbde8 100644 --- a/src/VPC/Apis/CloneRouteTableResponse.php +++ b/src/VPC2.0/Apis/CloneRouteTableResponse.php @@ -1,6 +1,7 @@ set("RouteTableId", $routeTableId); } diff --git a/src/VPC/Apis/CreateNATGWPolicyRequest.php b/src/VPC2.0/Apis/CreateNATGWPolicyRequest.php similarity index 90% rename from src/VPC/Apis/CreateNATGWPolicyRequest.php rename to src/VPC2.0/Apis/CreateNATGWPolicyRequest.php index 1956886a..f4455f69 100644 --- a/src/VPC/Apis/CreateNATGWPolicyRequest.php +++ b/src/VPC2.0/Apis/CreateNATGWPolicyRequest.php @@ -1,6 +1,7 @@ markRequired("DstPort"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -49,11 +50,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -69,11 +69,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -89,11 +88,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * Protocol: 协议类型。枚举值为:TCP、UDP * @@ -109,11 +107,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * SrcEIPId: 源IP。填写对应的EIP Id * @@ -129,11 +126,10 @@ public function getSrcEIPId() * * @param string $srcEIPId */ - public function setSrcEIPId($srcEIPId) + public function setSrcEIPId(string $srcEIPId) { $this->set("SrcEIPId", $srcEIPId); } - /** * SrcPort: 源端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 * @@ -149,11 +145,10 @@ public function getSrcPort() * * @param string $srcPort */ - public function setSrcPort($srcPort) + public function setSrcPort(string $srcPort) { $this->set("SrcPort", $srcPort); } - /** * DstIP: 目标IP。填写对应的目标IP地址 * @@ -169,11 +164,10 @@ public function getDstIP() * * @param string $dstIP */ - public function setDstIP($dstIP) + public function setDstIP(string $dstIP) { $this->set("DstIP", $dstIP); } - /** * DstPort: 目标端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 * @@ -189,11 +183,10 @@ public function getDstPort() * * @param string $dstPort */ - public function setDstPort($dstPort) + public function setDstPort(string $dstPort) { $this->set("DstPort", $dstPort); } - /** * PolicyName: 转发策略名称。默认为空 * @@ -209,7 +202,7 @@ public function getPolicyName() * * @param string $policyName */ - public function setPolicyName($policyName) + public function setPolicyName(string $policyName) { $this->set("PolicyName", $policyName); } diff --git a/src/VPC/Apis/CreateNATGWPolicyResponse.php b/src/VPC2.0/Apis/CreateNATGWPolicyResponse.php similarity index 91% rename from src/VPC/Apis/CreateNATGWPolicyResponse.php rename to src/VPC2.0/Apis/CreateNATGWPolicyResponse.php index 345ce4b8..c6850eb4 100644 --- a/src/VPC/Apis/CreateNATGWPolicyResponse.php +++ b/src/VPC2.0/Apis/CreateNATGWPolicyResponse.php @@ -1,6 +1,7 @@ set("PolicyId", $policyId); } diff --git a/src/VPC/Apis/CreateNATGWRequest.php b/src/VPC2.0/Apis/CreateNATGWRequest.php similarity index 91% rename from src/VPC/Apis/CreateNATGWRequest.php rename to src/VPC2.0/Apis/CreateNATGWRequest.php index 935a79c0..c937bdb0 100644 --- a/src/VPC/Apis/CreateNATGWRequest.php +++ b/src/VPC2.0/Apis/CreateNATGWRequest.php @@ -1,6 +1,7 @@ markRequired("FirewallId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWName: NAT网关名称 * @@ -86,11 +85,10 @@ public function getNATGWName() * * @param string $natgwName */ - public function setNATGWName($natgwName) + public function setNATGWName(string $natgwName) { $this->set("NATGWName", $natgwName); } - /** * EIPIds: NAT网关绑定的EIPId * @@ -110,7 +108,6 @@ public function setEIPIds(array $eipIds) { $this->set("EIPIds", $eipIds); } - /** * FirewallId: NAT网关绑定的防火墙Id * @@ -126,11 +123,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * SubnetworkIds: NAT网关绑定的子网Id,默认为空。 * @@ -150,7 +146,6 @@ public function setSubnetworkIds(array $subnetworkIds) { $this->set("SubnetworkIds", $subnetworkIds); } - /** * VPCId: NAT网关所属的VPC Id。默认为Default VPC Id * @@ -166,11 +161,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * IfOpen: 白名单开关标记。0表示关闭,1表示开启。默认为0 * @@ -186,11 +180,10 @@ public function getIfOpen() * * @param int $ifOpen */ - public function setIfOpen($ifOpen) + public function setIfOpen(int $ifOpen) { $this->set("IfOpen", $ifOpen); } - /** * Tag: 业务组。默认为空 * @@ -206,11 +199,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注。默认为空 * @@ -226,7 +218,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/VPC/Apis/CreateNATGWResponse.php b/src/VPC2.0/Apis/CreateNATGWResponse.php similarity index 91% rename from src/VPC/Apis/CreateNATGWResponse.php rename to src/VPC2.0/Apis/CreateNATGWResponse.php index 1d5552e1..381b9f5c 100644 --- a/src/VPC/Apis/CreateNATGWResponse.php +++ b/src/VPC2.0/Apis/CreateNATGWResponse.php @@ -1,6 +1,7 @@ set("NATGWId", $natgwId); } diff --git a/src/VPC/Apis/CreateNetworkAclAssociationRequest.php b/src/VPC2.0/Apis/CreateNetworkAclAssociationRequest.php similarity index 91% rename from src/VPC/Apis/CreateNetworkAclAssociationRequest.php rename to src/VPC2.0/Apis/CreateNetworkAclAssociationRequest.php index 7d5ac61b..8f223a1c 100644 --- a/src/VPC/Apis/CreateNetworkAclAssociationRequest.php +++ b/src/VPC2.0/Apis/CreateNetworkAclAssociationRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetworkId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: ACL的ID * @@ -85,11 +84,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * SubnetworkId: 需要绑定的子网ID * @@ -105,7 +103,7 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } diff --git a/src/VPC/Apis/CreateNetworkAclAssociationResponse.php b/src/VPC2.0/Apis/CreateNetworkAclAssociationResponse.php similarity index 80% rename from src/VPC/Apis/CreateNetworkAclAssociationResponse.php rename to src/VPC2.0/Apis/CreateNetworkAclAssociationResponse.php index 2c45eb8c..9c0fadf1 100644 --- a/src/VPC/Apis/CreateNetworkAclAssociationResponse.php +++ b/src/VPC2.0/Apis/CreateNetworkAclAssociationResponse.php @@ -1,6 +1,7 @@ set("AssociationId", $associationId); } - /** * PrevAssociation: 该子网之前的绑定关系信息 * - * @return AssociationInfo|null + * @return AssociationInfoModel|null */ public function getPrevAssociation() { - return new AssociationInfo($this->get("PrevAssociation")); + return new AssociationInfoModel($this->get("PrevAssociation")); } /** * PrevAssociation: 该子网之前的绑定关系信息 * - * @param AssociationInfo $prevAssociation + * @param AssociationInfoModel $prevAssociation */ - public function setPrevAssociation(array $prevAssociation) + public function setPrevAssociation(AssociationInfoModel $prevAssociation) { $this->set("PrevAssociation", $prevAssociation->getAll()); } diff --git a/src/VPC/Apis/CreateNetworkAclEntryRequest.php b/src/VPC2.0/Apis/CreateNetworkAclEntryRequest.php similarity index 90% rename from src/VPC/Apis/CreateNetworkAclEntryRequest.php rename to src/VPC2.0/Apis/CreateNetworkAclEntryRequest.php index 30674d0d..db9420fc 100644 --- a/src/VPC/Apis/CreateNetworkAclEntryRequest.php +++ b/src/VPC2.0/Apis/CreateNetworkAclEntryRequest.php @@ -1,6 +1,7 @@ markRequired("EntryAction"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -50,11 +51,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -70,11 +70,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: ACL的ID * @@ -90,11 +89,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * Priority: Entry的优先级,对于同样的Direction来说,不能重复 * @@ -110,11 +108,10 @@ public function getPriority() * * @param int $priority */ - public function setPriority($priority) + public function setPriority(int $priority) { $this->set("Priority", $priority); } - /** * Direction: 出向或者入向(“Ingress”, "Egress") * @@ -130,11 +127,10 @@ public function getDirection() * * @param string $direction */ - public function setDirection($direction) + public function setDirection(string $direction) { $this->set("Direction", $direction); } - /** * IpProtocol: 协议规则描述 * @@ -150,11 +146,10 @@ public function getIpProtocol() * * @param string $ipProtocol */ - public function setIpProtocol($ipProtocol) + public function setIpProtocol(string $ipProtocol) { $this->set("IpProtocol", $ipProtocol); } - /** * CidrBlock: IPv4段的CIDR表示 * @@ -170,11 +165,10 @@ public function getCidrBlock() * * @param string $cidrBlock */ - public function setCidrBlock($cidrBlock) + public function setCidrBlock(string $cidrBlock) { $this->set("CidrBlock", $cidrBlock); } - /** * PortRange: 针对的端口范围 * @@ -190,11 +184,10 @@ public function getPortRange() * * @param string $portRange */ - public function setPortRange($portRange) + public function setPortRange(string $portRange) { $this->set("PortRange", $portRange); } - /** * EntryAction: 规则的行为("Accept", "Reject") * @@ -210,11 +203,10 @@ public function getEntryAction() * * @param string $entryAction */ - public function setEntryAction($entryAction) + public function setEntryAction(string $entryAction) { $this->set("EntryAction", $entryAction); } - /** * Description: 描述。长度限制为不超过32字节。 * @@ -230,11 +222,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * TargetType: 应用目标类型。0代表“子网内全部资源”,1代表“子网内指定资源”,默认为0 * @@ -250,11 +241,10 @@ public function getTargetType() * * @param int $targetType */ - public function setTargetType($targetType) + public function setTargetType(int $targetType) { $this->set("TargetType", $targetType); } - /** * TargetResourceIds: 应用目标资源列表。默认为全部资源生效。TargetType为0时不用填写该值。 * diff --git a/src/VPC/Apis/CreateNetworkAclEntryResponse.php b/src/VPC2.0/Apis/CreateNetworkAclEntryResponse.php similarity index 91% rename from src/VPC/Apis/CreateNetworkAclEntryResponse.php rename to src/VPC2.0/Apis/CreateNetworkAclEntryResponse.php index 65f05e94..37b24c2d 100644 --- a/src/VPC/Apis/CreateNetworkAclEntryResponse.php +++ b/src/VPC2.0/Apis/CreateNetworkAclEntryResponse.php @@ -1,6 +1,7 @@ set("EntryId", $entryId); } diff --git a/src/VPC/Apis/CreateNetworkAclRequest.php b/src/VPC2.0/Apis/CreateNetworkAclRequest.php similarity index 90% rename from src/VPC/Apis/CreateNetworkAclRequest.php rename to src/VPC2.0/Apis/CreateNetworkAclRequest.php index 8f8ca7e0..1dbcc7f3 100644 --- a/src/VPC/Apis/CreateNetworkAclRequest.php +++ b/src/VPC2.0/Apis/CreateNetworkAclRequest.php @@ -1,6 +1,7 @@ markRequired("AclName"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VpcId: 将要创建的ACL所属VPC的ID * @@ -85,11 +84,10 @@ public function getVpcId() * * @param string $vpcId */ - public function setVpcId($vpcId) + public function setVpcId(string $vpcId) { $this->set("VpcId", $vpcId); } - /** * AclName: ACL的名称 * @@ -105,11 +103,10 @@ public function getAclName() * * @param string $aclName */ - public function setAclName($aclName) + public function setAclName(string $aclName) { $this->set("AclName", $aclName); } - /** * Description: ACL的描述 * @@ -125,7 +122,7 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } diff --git a/src/VPC/Apis/CreateNetworkAclResponse.php b/src/VPC2.0/Apis/CreateNetworkAclResponse.php similarity index 91% rename from src/VPC/Apis/CreateNetworkAclResponse.php rename to src/VPC2.0/Apis/CreateNetworkAclResponse.php index 870c73de..75da9e0a 100644 --- a/src/VPC/Apis/CreateNetworkAclResponse.php +++ b/src/VPC2.0/Apis/CreateNetworkAclResponse.php @@ -1,6 +1,7 @@ set("AclId", $aclId); } diff --git a/src/VPC/Apis/CreateRouteTableRequest.php b/src/VPC2.0/Apis/CreateRouteTableRequest.php similarity index 90% rename from src/VPC/Apis/CreateRouteTableRequest.php rename to src/VPC2.0/Apis/CreateRouteTableRequest.php index c8ad7c24..a38d834e 100644 --- a/src/VPC/Apis/CreateRouteTableRequest.php +++ b/src/VPC2.0/Apis/CreateRouteTableRequest.php @@ -1,6 +1,7 @@ markRequired("VPCId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 所属的VPC资源ID * @@ -85,11 +84,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Name: 路由表名称。默认为RouteTable * @@ -105,11 +103,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 路由表所属业务组 * @@ -125,11 +122,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -145,7 +141,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/VPC/Apis/CreateRouteTableResponse.php b/src/VPC2.0/Apis/CreateRouteTableResponse.php similarity index 90% rename from src/VPC/Apis/CreateRouteTableResponse.php rename to src/VPC2.0/Apis/CreateRouteTableResponse.php index d75afc30..cf91cce9 100644 --- a/src/VPC/Apis/CreateRouteTableResponse.php +++ b/src/VPC2.0/Apis/CreateRouteTableResponse.php @@ -1,6 +1,7 @@ set("RouteTableId", $routeTableId); } diff --git a/src/VPC2.0/Apis/CreateSnatDnatRuleRequest.php b/src/VPC2.0/Apis/CreateSnatDnatRuleRequest.php new file mode 100644 index 00000000..a58dfd15 --- /dev/null +++ b/src/VPC2.0/Apis/CreateSnatDnatRuleRequest.php @@ -0,0 +1,130 @@ + "CreateSnatDnatRule"]); + $this->markRequired("Region"); + $this->markRequired("PrivateIp"); + $this->markRequired("EIP"); + $this->markRequired("NATGWId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * PrivateIp: 内网P地址 + * + * @return string[]|null + */ + public function getPrivateIp() + { + return $this->get("PrivateIp"); + } + + /** + * PrivateIp: 内网P地址 + * + * @param string[] $privateIp + */ + public function setPrivateIp(array $privateIp) + { + $this->set("PrivateIp", $privateIp); + } + /** + * EIP: EIP的IP地址。按入参顺序,PrivateIp与EIP一一对应建立映射关系。 + * + * @return string[]|null + */ + public function getEIP() + { + return $this->get("EIP"); + } + + /** + * EIP: EIP的IP地址。按入参顺序,PrivateIp与EIP一一对应建立映射关系。 + * + * @param string[] $eip + */ + public function setEIP(array $eip) + { + $this->set("EIP", $eip); + } + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @return string|null + */ + public function getNATGWId() + { + return $this->get("NATGWId"); + } + + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @param string $natgwId + */ + public function setNATGWId(string $natgwId) + { + $this->set("NATGWId", $natgwId); + } +} diff --git a/src/VPC2.0/Apis/CreateSnatDnatRuleResponse.php b/src/VPC2.0/Apis/CreateSnatDnatRuleResponse.php new file mode 100644 index 00000000..b3c08a67 --- /dev/null +++ b/src/VPC2.0/Apis/CreateSnatDnatRuleResponse.php @@ -0,0 +1,26 @@ +markRequired("Subnet"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPC资源ID * @@ -85,11 +84,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Subnet: 子网网络地址,例如192.168.0.0 * @@ -105,11 +103,10 @@ public function getSubnet() * * @param string $subnet */ - public function setSubnet($subnet) + public function setSubnet(string $subnet) { $this->set("Subnet", $subnet); } - /** * Netmask: 子网网络号位数,默认为24 * @@ -125,11 +122,10 @@ public function getNetmask() * * @param int $netmask */ - public function setNetmask($netmask) + public function setNetmask(int $netmask) { $this->set("Netmask", $netmask); } - /** * SubnetName: 子网名称,默认为Subnet * @@ -145,11 +141,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * Tag: 业务组名称,默认为Default * @@ -165,11 +160,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -185,7 +179,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/VPC/Apis/CreateSubnetResponse.php b/src/VPC2.0/Apis/CreateSubnetResponse.php similarity index 90% rename from src/VPC/Apis/CreateSubnetResponse.php rename to src/VPC2.0/Apis/CreateSubnetResponse.php index 4e77f638..fa939833 100644 --- a/src/VPC/Apis/CreateSubnetResponse.php +++ b/src/VPC2.0/Apis/CreateSubnetResponse.php @@ -1,6 +1,7 @@ set("SubnetId", $subnetId); } diff --git a/src/VPC/Apis/CreateVPCIntercomRequest.php b/src/VPC2.0/Apis/CreateVPCIntercomRequest.php similarity index 90% rename from src/VPC/Apis/CreateVPCIntercomRequest.php rename to src/VPC2.0/Apis/CreateVPCIntercomRequest.php index 2162c994..9af70408 100644 --- a/src/VPC/Apis/CreateVPCIntercomRequest.php +++ b/src/VPC2.0/Apis/CreateVPCIntercomRequest.php @@ -1,6 +1,7 @@ markRequired("DstVPCId"); } - /** * Region: 源VPC所在地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 源VPC短ID * @@ -85,11 +84,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * DstVPCId: 目的VPC短ID * @@ -105,11 +103,10 @@ public function getDstVPCId() * * @param string $dstVPCId */ - public function setDstVPCId($dstVPCId) + public function setDstVPCId(string $dstVPCId) { $this->set("DstVPCId", $dstVPCId); } - /** * DstRegion: 目的VPC所在地域,默认与源VPC同地域。 * @@ -125,11 +122,10 @@ public function getDstRegion() * * @param string $dstRegion */ - public function setDstRegion($dstRegion) + public function setDstRegion(string $dstRegion) { $this->set("DstRegion", $dstRegion); } - /** * DstProjectId: 目的VPC项目ID。默认与源VPC同项目。 * @@ -145,7 +141,7 @@ public function getDstProjectId() * * @param string $dstProjectId */ - public function setDstProjectId($dstProjectId) + public function setDstProjectId(string $dstProjectId) { $this->set("DstProjectId", $dstProjectId); } diff --git a/src/VPC/Apis/CreateVPCIntercomResponse.php b/src/VPC2.0/Apis/CreateVPCIntercomResponse.php similarity index 93% rename from src/VPC/Apis/CreateVPCIntercomResponse.php rename to src/VPC2.0/Apis/CreateVPCIntercomResponse.php index 23c1d425..8695863f 100644 --- a/src/VPC/Apis/CreateVPCIntercomResponse.php +++ b/src/VPC2.0/Apis/CreateVPCIntercomResponse.php @@ -1,6 +1,7 @@ markRequired("Network"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Name: VPC名称 * @@ -85,11 +84,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Network: VPC网段 * @@ -109,7 +107,6 @@ public function setNetwork(array $network) { $this->set("Network", $network); } - /** * Tag: 业务组名称 * @@ -125,11 +122,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -145,7 +141,7 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } diff --git a/src/VPC/Apis/CreateVPCResponse.php b/src/VPC2.0/Apis/CreateVPCResponse.php similarity index 91% rename from src/VPC/Apis/CreateVPCResponse.php rename to src/VPC2.0/Apis/CreateVPCResponse.php index e1034602..80ad17c2 100644 --- a/src/VPC/Apis/CreateVPCResponse.php +++ b/src/VPC2.0/Apis/CreateVPCResponse.php @@ -1,6 +1,7 @@ set("VPCId", $vpcId); } diff --git a/src/VPC/Apis/DeleteNATGWPolicyRequest.php b/src/VPC2.0/Apis/DeleteNATGWPolicyRequest.php similarity index 91% rename from src/VPC/Apis/DeleteNATGWPolicyRequest.php rename to src/VPC2.0/Apis/DeleteNATGWPolicyRequest.php index 61414d19..0f8c8f39 100644 --- a/src/VPC/Apis/DeleteNATGWPolicyRequest.php +++ b/src/VPC2.0/Apis/DeleteNATGWPolicyRequest.php @@ -1,6 +1,7 @@ markRequired("PolicyId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * PolicyId: 端口转发规则Id * @@ -105,7 +103,7 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } diff --git a/src/VPC/Apis/DeleteNATGWPolicyResponse.php b/src/VPC2.0/Apis/DeleteNATGWPolicyResponse.php similarity index 93% rename from src/VPC/Apis/DeleteNATGWPolicyResponse.php rename to src/VPC2.0/Apis/DeleteNATGWPolicyResponse.php index a1606397..92dc52e9 100644 --- a/src/VPC/Apis/DeleteNATGWPolicyResponse.php +++ b/src/VPC2.0/Apis/DeleteNATGWPolicyResponse.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -40,17 +41,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -60,15 +60,14 @@ public function getProjectId() } /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * ReleaseEip: 是否释放绑定的EIP。true:解绑并释放;false:只解绑不释放。默认为false * @@ -104,7 +102,7 @@ public function getReleaseEip() * * @param boolean $releaseEip */ - public function setReleaseEip($releaseEip) + public function setReleaseEip(bool $releaseEip) { $this->set("ReleaseEip", $releaseEip); } diff --git a/src/VPC/Apis/DeleteNATGWResponse.php b/src/VPC2.0/Apis/DeleteNATGWResponse.php similarity index 93% rename from src/VPC/Apis/DeleteNATGWResponse.php rename to src/VPC2.0/Apis/DeleteNATGWResponse.php index 0b1a7779..9fc779f7 100644 --- a/src/VPC/Apis/DeleteNATGWResponse.php +++ b/src/VPC2.0/Apis/DeleteNATGWResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetworkId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: 需要删除的AclId * @@ -85,11 +84,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * SubnetworkId: 绑定的子网ID * @@ -105,7 +103,7 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } diff --git a/src/VPC/Apis/DeleteNetworkAclAssociationResponse.php b/src/VPC2.0/Apis/DeleteNetworkAclAssociationResponse.php similarity index 93% rename from src/VPC/Apis/DeleteNetworkAclAssociationResponse.php rename to src/VPC2.0/Apis/DeleteNetworkAclAssociationResponse.php index 3759f138..c0410e36 100644 --- a/src/VPC/Apis/DeleteNetworkAclAssociationResponse.php +++ b/src/VPC2.0/Apis/DeleteNetworkAclAssociationResponse.php @@ -1,6 +1,7 @@ markRequired("EntryId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: Acl的ID * @@ -85,11 +84,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * EntryId: 需要删除的EntryId * @@ -105,7 +103,7 @@ public function getEntryId() * * @param string $entryId */ - public function setEntryId($entryId) + public function setEntryId(string $entryId) { $this->set("EntryId", $entryId); } diff --git a/src/VPC/Apis/DeleteNetworkAclEntryResponse.php b/src/VPC2.0/Apis/DeleteNetworkAclEntryResponse.php similarity index 93% rename from src/VPC/Apis/DeleteNetworkAclEntryResponse.php rename to src/VPC2.0/Apis/DeleteNetworkAclEntryResponse.php index 4849d29b..5af3e239 100644 --- a/src/VPC/Apis/DeleteNetworkAclEntryResponse.php +++ b/src/VPC2.0/Apis/DeleteNetworkAclEntryResponse.php @@ -1,6 +1,7 @@ markRequired("AclId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: 需要删除的AclId * @@ -84,7 +83,7 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } diff --git a/src/VPC/Apis/DeleteNetworkAclResponse.php b/src/VPC2.0/Apis/DeleteNetworkAclResponse.php similarity index 93% rename from src/VPC/Apis/DeleteNetworkAclResponse.php rename to src/VPC2.0/Apis/DeleteNetworkAclResponse.php index 6169a2cb..de5fb1ae 100644 --- a/src/VPC/Apis/DeleteNetworkAclResponse.php +++ b/src/VPC2.0/Apis/DeleteNetworkAclResponse.php @@ -1,6 +1,7 @@ markRequired("RouteTableId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RouteTableId: 路由表资源ID * @@ -85,7 +84,7 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } diff --git a/src/VPC/Apis/DeleteRouteTableResponse.php b/src/VPC2.0/Apis/DeleteRouteTableResponse.php similarity index 93% rename from src/VPC/Apis/DeleteRouteTableResponse.php rename to src/VPC2.0/Apis/DeleteRouteTableResponse.php index 455a2995..251528cd 100644 --- a/src/VPC/Apis/DeleteRouteTableResponse.php +++ b/src/VPC2.0/Apis/DeleteRouteTableResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -48,11 +49,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -68,11 +68,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -88,11 +87,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Ip: ip * @@ -108,11 +106,10 @@ public function getIp() * * @param string $ip */ - public function setIp($ip) + public function setIp(string $ip) { $this->set("Ip", $ip); } - /** * Mac: mac * @@ -128,11 +125,10 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } - /** * SubnetId: 子网Id * @@ -148,11 +144,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPCId * @@ -168,11 +163,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * ObjectId: 资源Id * @@ -188,7 +182,7 @@ public function getObjectId() * * @param string $objectId */ - public function setObjectId($objectId) + public function setObjectId(string $objectId) { $this->set("ObjectId", $objectId); } diff --git a/src/VPC/Apis/DeleteSecondaryIpResponse.php b/src/VPC2.0/Apis/DeleteSecondaryIpResponse.php similarity index 93% rename from src/VPC/Apis/DeleteSecondaryIpResponse.php rename to src/VPC2.0/Apis/DeleteSecondaryIpResponse.php index d4184765..c2b3fb57 100644 --- a/src/VPC/Apis/DeleteSecondaryIpResponse.php +++ b/src/VPC2.0/Apis/DeleteSecondaryIpResponse.php @@ -1,6 +1,7 @@ "DeleteSnatDnatRule"]); + $this->markRequired("Region"); + $this->markRequired("EIP"); + $this->markRequired("PrivateIp"); + $this->markRequired("NATGWId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * EIP: EIP的IP地址,PrivateIp与EIP需一一对应 + * + * @return string[]|null + */ + public function getEIP() + { + return $this->get("EIP"); + } + + /** + * EIP: EIP的IP地址,PrivateIp与EIP需一一对应 + * + * @param string[] $eip + */ + public function setEIP(array $eip) + { + $this->set("EIP", $eip); + } + /** + * PrivateIp: 内网P地址 + * + * @return string[]|null + */ + public function getPrivateIp() + { + return $this->get("PrivateIp"); + } + + /** + * PrivateIp: 内网P地址 + * + * @param string[] $privateIp + */ + public function setPrivateIp(array $privateIp) + { + $this->set("PrivateIp", $privateIp); + } + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @return string|null + */ + public function getNATGWId() + { + return $this->get("NATGWId"); + } + + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @param string $natgwId + */ + public function setNATGWId(string $natgwId) + { + $this->set("NATGWId", $natgwId); + } +} diff --git a/src/VPC2.0/Apis/DeleteSnatDnatRuleResponse.php b/src/VPC2.0/Apis/DeleteSnatDnatRuleResponse.php new file mode 100644 index 00000000..5521ba8f --- /dev/null +++ b/src/VPC2.0/Apis/DeleteSnatDnatRuleResponse.php @@ -0,0 +1,26 @@ +markRequired("SourceIp"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关的ID * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * SourceIp: 需要出外网的私网IP地址,例如10.9.7.xx * @@ -105,7 +103,7 @@ public function getSourceIp() * * @param string $sourceIp */ - public function setSourceIp($sourceIp) + public function setSourceIp(string $sourceIp) { $this->set("SourceIp", $sourceIp); } diff --git a/src/VPC/Apis/DeleteSnatRuleResponse.php b/src/VPC2.0/Apis/DeleteSnatRuleResponse.php similarity index 93% rename from src/VPC/Apis/DeleteSnatRuleResponse.php rename to src/VPC2.0/Apis/DeleteSnatRuleResponse.php index 82cb9705..59240fc6 100644 --- a/src/VPC/Apis/DeleteSnatRuleResponse.php +++ b/src/VPC2.0/Apis/DeleteSnatRuleResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网ID * @@ -84,7 +83,7 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } diff --git a/src/VPC/Apis/DeleteSubnetResponse.php b/src/VPC2.0/Apis/DeleteSubnetResponse.php similarity index 93% rename from src/VPC/Apis/DeleteSubnetResponse.php rename to src/VPC2.0/Apis/DeleteSubnetResponse.php index 525f8177..faf6c31f 100644 --- a/src/VPC/Apis/DeleteSubnetResponse.php +++ b/src/VPC2.0/Apis/DeleteSubnetResponse.php @@ -1,6 +1,7 @@ markRequired("DstVPCId"); } - /** * Region: 源VPC所在地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 源VPC短ID * @@ -85,11 +84,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * DstVPCId: 目的VPC短ID * @@ -105,11 +103,10 @@ public function getDstVPCId() * * @param string $dstVPCId */ - public function setDstVPCId($dstVPCId) + public function setDstVPCId(string $dstVPCId) { $this->set("DstVPCId", $dstVPCId); } - /** * DstRegion: 目的VPC所在地域,默认为源VPC所在地域 * @@ -125,11 +122,10 @@ public function getDstRegion() * * @param string $dstRegion */ - public function setDstRegion($dstRegion) + public function setDstRegion(string $dstRegion) { $this->set("DstRegion", $dstRegion); } - /** * DstProjectId: 目的VPC所在项目ID,默认为源VPC所在项目ID * @@ -145,7 +141,7 @@ public function getDstProjectId() * * @param string $dstProjectId */ - public function setDstProjectId($dstProjectId) + public function setDstProjectId(string $dstProjectId) { $this->set("DstProjectId", $dstProjectId); } diff --git a/src/VPC/Apis/DeleteVPCIntercomResponse.php b/src/VPC2.0/Apis/DeleteVPCIntercomResponse.php similarity index 93% rename from src/VPC/Apis/DeleteVPCIntercomResponse.php rename to src/VPC2.0/Apis/DeleteVPCIntercomResponse.php index 9c5d3900..cfea2e27 100644 --- a/src/VPC/Apis/DeleteVPCIntercomResponse.php +++ b/src/VPC2.0/Apis/DeleteVPCIntercomResponse.php @@ -1,6 +1,7 @@ markRequired("VPCId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPC资源Id * @@ -84,7 +83,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Apis/DeleteVPCResponse.php b/src/VPC2.0/Apis/DeleteVPCResponse.php similarity index 93% rename from src/VPC/Apis/DeleteVPCResponse.php rename to src/VPC2.0/Apis/DeleteVPCResponse.php index 4f1f1d18..449c5587 100644 --- a/src/VPC/Apis/DeleteVPCResponse.php +++ b/src/VPC2.0/Apis/DeleteVPCResponse.php @@ -1,6 +1,7 @@ markRequired("ResourceIds"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * ResourceIds: 删除白名单的资源Id * diff --git a/src/VPC/Apis/DeleteWhiteListResourceResponse.php b/src/VPC2.0/Apis/DeleteWhiteListResourceResponse.php similarity index 93% rename from src/VPC/Apis/DeleteWhiteListResourceResponse.php rename to src/VPC2.0/Apis/DeleteWhiteListResourceResponse.php index 0127de61..ffa2e45c 100644 --- a/src/VPC/Apis/DeleteWhiteListResourceResponse.php +++ b/src/VPC2.0/Apis/DeleteWhiteListResourceResponse.php @@ -1,6 +1,7 @@ "DescribeInstanceNetworkInterface"]); + $this->markRequired("Region"); + $this->markRequired("ProjectId"); + $this->markRequired("InstanceId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * InstanceId: 云主机ID + * + * @return string|null + */ + public function getInstanceId() + { + return $this->get("InstanceId"); + } + + /** + * InstanceId: 云主机ID + * + * @param string $instanceId + */ + public function setInstanceId(string $instanceId) + { + $this->set("InstanceId", $instanceId); + } + /** + * Offset: 默认为0 + * + * @return integer|null + */ + public function getOffset() + { + return $this->get("Offset"); + } + + /** + * Offset: 默认为0 + * + * @param int $offset + */ + public function setOffset(int $offset) + { + $this->set("Offset", $offset); + } + /** + * Limit: 默认为20 + * + * @return integer|null + */ + public function getLimit() + { + return $this->get("Limit"); + } + + /** + * Limit: 默认为20 + * + * @param int $limit + */ + public function setLimit(int $limit) + { + $this->set("Limit", $limit); + } +} diff --git a/src/VPC2.0/Apis/DescribeInstanceNetworkInterfaceResponse.php b/src/VPC2.0/Apis/DescribeInstanceNetworkInterfaceResponse.php new file mode 100644 index 00000000..4ca5268b --- /dev/null +++ b/src/VPC2.0/Apis/DescribeInstanceNetworkInterfaceResponse.php @@ -0,0 +1,59 @@ +get("NetworkInterfaceSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new NetworkInterfaceModel($item)); + } + return $result; + } + + /** + * NetworkInterfaceSet: 虚拟网卡信息 + * + * @param NetworkInterfaceModel[] $networkInterfaceSet + */ + public function setNetworkInterfaceSet(array $networkInterfaceSet) + { + $result = []; + foreach ($networkInterfaceSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/VPC/Apis/DescribeNATGWPolicyRequest.php b/src/VPC2.0/Apis/DescribeNATGWPolicyRequest.php similarity index 91% rename from src/VPC/Apis/DescribeNATGWPolicyRequest.php rename to src/VPC2.0/Apis/DescribeNATGWPolicyRequest.php index 10e23620..1a44b250 100644 --- a/src/VPC/Apis/DescribeNATGWPolicyRequest.php +++ b/src/VPC2.0/Apis/DescribeNATGWPolicyRequest.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * Limit: 返回数据长度,默认为10000 * @@ -104,11 +102,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -124,7 +121,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/VPC/Apis/DescribeNATGWPolicyResponse.php b/src/VPC2.0/Apis/DescribeNATGWPolicyResponse.php similarity index 86% rename from src/VPC/Apis/DescribeNATGWPolicyResponse.php rename to src/VPC2.0/Apis/DescribeNATGWPolicyResponse.php index 5248c508..0f9ba901 100644 --- a/src/VPC/Apis/DescribeNATGWPolicyResponse.php +++ b/src/VPC2.0/Apis/DescribeNATGWPolicyResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 查到的NATGW 转发策略的详细信息 * - * @return NATGWPolicyDataSet[]|null + * @return NATGWPolicyDataSetModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NATGWPolicyDataSet($item)); + array_push($result, new NATGWPolicyDataSetModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 查到的NATGW 转发策略的详细信息 * - * @param NATGWPolicyDataSet[] $dataSet + * @param NATGWPolicyDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeNATGWRequest.php b/src/VPC2.0/Apis/DescribeNATGWRequest.php similarity index 79% rename from src/VPC/Apis/DescribeNATGWRequest.php rename to src/VPC2.0/Apis/DescribeNATGWRequest.php index a24a446f..087f6582 100644 --- a/src/VPC/Apis/DescribeNATGWRequest.php +++ b/src/VPC2.0/Apis/DescribeNATGWRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -39,17 +40,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -59,15 +59,14 @@ public function getProjectId() } /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWIds: NAT网关Id。默认为该项目下所有NAT网关 * @@ -87,7 +86,6 @@ public function setNATGWIds(array $natgwIds) { $this->set("NATGWIds", $natgwIds); } - /** * Offset: 数据偏移量。默认为0 * @@ -103,11 +101,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值。默认为20 * @@ -123,7 +120,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeNATGWResponse.php b/src/VPC2.0/Apis/DescribeNATGWResponse.php similarity index 87% rename from src/VPC/Apis/DescribeNATGWResponse.php rename to src/VPC2.0/Apis/DescribeNATGWResponse.php index ba5c9625..f334e363 100644 --- a/src/VPC/Apis/DescribeNATGWResponse.php +++ b/src/VPC2.0/Apis/DescribeNATGWResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 查到的NATGW信息列表 * - * @return NatGatewayDataSet[]|null + * @return NatGatewayDataSetModel[]|null */ public function getDataSet() { @@ -59,7 +60,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NatGatewayDataSet($item)); + array_push($result, new NatGatewayDataSetModel($item)); } return $result; } @@ -67,7 +68,7 @@ public function getDataSet() /** * DataSet: 查到的NATGW信息列表 * - * @param NatGatewayDataSet[] $dataSet + * @param NatGatewayDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeNetworkAclAssociationBySubnetRequest.php b/src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetRequest.php similarity index 91% rename from src/VPC/Apis/DescribeNetworkAclAssociationBySubnetRequest.php rename to src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetRequest.php index b0a6dacb..2cdf6608 100644 --- a/src/VPC/Apis/DescribeNetworkAclAssociationBySubnetRequest.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetworkId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetworkId: 子网的ID * @@ -84,7 +83,7 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } diff --git a/src/VPC/Apis/DescribeNetworkAclAssociationBySubnetResponse.php b/src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetResponse.php similarity index 78% rename from src/VPC/Apis/DescribeNetworkAclAssociationBySubnetResponse.php rename to src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetResponse.php index 02440560..9792b810 100644 --- a/src/VPC/Apis/DescribeNetworkAclAssociationBySubnetResponse.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclAssociationBySubnetResponse.php @@ -1,6 +1,7 @@ get("Association")); + return new AssociationInfoModel($this->get("Association")); } /** * Association: 绑定信息 * - * @param AssociationInfo $association + * @param AssociationInfoModel $association */ - public function setAssociation(array $association) + public function setAssociation(AssociationInfoModel $association) { $this->set("Association", $association->getAll()); } diff --git a/src/VPC/Apis/DescribeNetworkAclAssociationRequest.php b/src/VPC2.0/Apis/DescribeNetworkAclAssociationRequest.php similarity index 90% rename from src/VPC/Apis/DescribeNetworkAclAssociationRequest.php rename to src/VPC2.0/Apis/DescribeNetworkAclAssociationRequest.php index fa97ca31..6ca3e72c 100644 --- a/src/VPC/Apis/DescribeNetworkAclAssociationRequest.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclAssociationRequest.php @@ -1,6 +1,7 @@ markRequired("AclId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: Acl的ID * @@ -84,11 +83,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * Offset: 列表偏移量 * @@ -104,11 +102,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 列表获取的个数限制 * @@ -124,7 +121,7 @@ public function getLimit() * * @param string $limit */ - public function setLimit($limit) + public function setLimit(string $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeNetworkAclAssociationResponse.php b/src/VPC2.0/Apis/DescribeNetworkAclAssociationResponse.php similarity index 86% rename from src/VPC/Apis/DescribeNetworkAclAssociationResponse.php rename to src/VPC2.0/Apis/DescribeNetworkAclAssociationResponse.php index ac57c5b8..e55705ba 100644 --- a/src/VPC/Apis/DescribeNetworkAclAssociationResponse.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclAssociationResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new AssociationInfo($item)); + array_push($result, new AssociationInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getAssociationList() /** * AssociationList: 绑定信息列表 * - * @param AssociationInfo[] $associationList + * @param AssociationInfoModel[] $associationList */ public function setAssociationList(array $associationList) { diff --git a/src/VPC/Apis/DescribeNetworkAclEntryRequest.php b/src/VPC2.0/Apis/DescribeNetworkAclEntryRequest.php similarity index 92% rename from src/VPC/Apis/DescribeNetworkAclEntryRequest.php rename to src/VPC2.0/Apis/DescribeNetworkAclEntryRequest.php index 64a922d1..a924a70e 100644 --- a/src/VPC/Apis/DescribeNetworkAclEntryRequest.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclEntryRequest.php @@ -1,6 +1,7 @@ markRequired("AclId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: ACL的ID * @@ -84,7 +83,7 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } diff --git a/src/VPC/Apis/DescribeNetworkAclEntryResponse.php b/src/VPC2.0/Apis/DescribeNetworkAclEntryResponse.php similarity index 87% rename from src/VPC/Apis/DescribeNetworkAclEntryResponse.php rename to src/VPC2.0/Apis/DescribeNetworkAclEntryResponse.php index 21c1b7de..4baafe9c 100644 --- a/src/VPC/Apis/DescribeNetworkAclEntryResponse.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclEntryResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new AclEntryInfo($item)); + array_push($result, new AclEntryInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getEntryList() /** * EntryList: 所有的规则信息 * - * @param AclEntryInfo[] $entryList + * @param AclEntryInfoModel[] $entryList */ public function setEntryList(array $entryList) { diff --git a/src/VPC/Apis/DescribeNetworkAclRequest.php b/src/VPC2.0/Apis/DescribeNetworkAclRequest.php similarity index 91% rename from src/VPC/Apis/DescribeNetworkAclRequest.php rename to src/VPC2.0/Apis/DescribeNetworkAclRequest.php index c59b2ab1..0f904f6a 100644 --- a/src/VPC/Apis/DescribeNetworkAclRequest.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Offset: 列表偏移量 * @@ -83,11 +82,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 列表获取的个数限制 * @@ -103,11 +101,10 @@ public function getLimit() * * @param string $limit */ - public function setLimit($limit) + public function setLimit(string $limit) { $this->set("Limit", $limit); } - /** * VpcId: 需要获取的ACL所属的VPC的ID * @@ -123,7 +120,7 @@ public function getVpcId() * * @param string $vpcId */ - public function setVpcId($vpcId) + public function setVpcId(string $vpcId) { $this->set("VpcId", $vpcId); } diff --git a/src/VPC/Apis/DescribeNetworkAclResponse.php b/src/VPC2.0/Apis/DescribeNetworkAclResponse.php similarity index 89% rename from src/VPC/Apis/DescribeNetworkAclResponse.php rename to src/VPC2.0/Apis/DescribeNetworkAclResponse.php index 1704d476..bc8b1780 100644 --- a/src/VPC/Apis/DescribeNetworkAclResponse.php +++ b/src/VPC2.0/Apis/DescribeNetworkAclResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new AclInfo($item)); + array_push($result, new AclInfoModel($item)); } return $result; } @@ -47,7 +49,7 @@ public function getAclList() /** * AclList: ACL的信息,具体结构见下方AclInfo * - * @param AclInfo[] $aclList + * @param AclInfoModel[] $aclList */ public function setAclList(array $aclList) { diff --git a/src/VPC2.0/Apis/DescribeNetworkInterfaceRequest.php b/src/VPC2.0/Apis/DescribeNetworkInterfaceRequest.php new file mode 100644 index 00000000..618687f3 --- /dev/null +++ b/src/VPC2.0/Apis/DescribeNetworkInterfaceRequest.php @@ -0,0 +1,223 @@ + "DescribeNetworkInterface"]); + $this->markRequired("Region"); + $this->markRequired("ProjectId"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * VPCId: 所属VPC + * + * @return string|null + */ + public function getVPCId() + { + return $this->get("VPCId"); + } + + /** + * VPCId: 所属VPC + * + * @param string $vpcId + */ + public function setVPCId(string $vpcId) + { + $this->set("VPCId", $vpcId); + } + /** + * SubnetId: 所属子网 + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: 所属子网 + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } + /** + * InterfaceId: 虚拟网卡ID,可指定 0~n + * + * @return string[]|null + */ + public function getInterfaceId() + { + return $this->get("InterfaceId"); + } + + /** + * InterfaceId: 虚拟网卡ID,可指定 0~n + * + * @param string[] $interfaceId + */ + public function setInterfaceId(array $interfaceId) + { + $this->set("InterfaceId", $interfaceId); + } + /** + * OnlyDefault: 若为true 只返回默认网卡默认为false + * + * @return boolean|null + */ + public function getOnlyDefault() + { + return $this->get("OnlyDefault"); + } + + /** + * OnlyDefault: 若为true 只返回默认网卡默认为false + * + * @param boolean $onlyDefault + */ + public function setOnlyDefault(bool $onlyDefault) + { + $this->set("OnlyDefault", $onlyDefault); + } + /** + * NoRecycled: 若为true 过滤绑定在回收站主机中的网卡。默认为false。 + * + * @return boolean|null + */ + public function getNoRecycled() + { + return $this->get("NoRecycled"); + } + + /** + * NoRecycled: 若为true 过滤绑定在回收站主机中的网卡。默认为false。 + * + * @param boolean $noRecycled + */ + public function setNoRecycled(bool $noRecycled) + { + $this->set("NoRecycled", $noRecycled); + } + /** + * Tag: 业务组 + * + * @return string|null + */ + public function getTag() + { + return $this->get("Tag"); + } + + /** + * Tag: 业务组 + * + * @param string $tag + */ + public function setTag(string $tag) + { + $this->set("Tag", $tag); + } + /** + * Limit: 默认为20 + * + * @return integer|null + */ + public function getLimit() + { + return $this->get("Limit"); + } + + /** + * Limit: 默认为20 + * + * @param int $limit + */ + public function setLimit(int $limit) + { + $this->set("Limit", $limit); + } + /** + * Offset: 默认为0 + * + * @return integer|null + */ + public function getOffset() + { + return $this->get("Offset"); + } + + /** + * Offset: 默认为0 + * + * @param int $offset + */ + public function setOffset(int $offset) + { + $this->set("Offset", $offset); + } +} diff --git a/src/VPC2.0/Apis/DescribeNetworkInterfaceResponse.php b/src/VPC2.0/Apis/DescribeNetworkInterfaceResponse.php new file mode 100644 index 00000000..b6ea9be2 --- /dev/null +++ b/src/VPC2.0/Apis/DescribeNetworkInterfaceResponse.php @@ -0,0 +1,78 @@ +get("NetworkInterfaceSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new NetworkInterfaceModel($item)); + } + return $result; + } + + /** + * NetworkInterfaceSet: 虚拟网卡信息 + * + * @param NetworkInterfaceModel[] $networkInterfaceSet + */ + public function setNetworkInterfaceSet(array $networkInterfaceSet) + { + $result = []; + foreach ($networkInterfaceSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } + /** + * TotalCount: 虚拟网卡总数 + * + * @return integer|null + */ + public function getTotalCount() + { + return $this->get("TotalCount"); + } + + /** + * TotalCount: 虚拟网卡总数 + * + * @param int $totalCount + */ + public function setTotalCount(int $totalCount) + { + $this->set("TotalCount", $totalCount); + } +} diff --git a/src/VPC/Apis/DescribeRouteTableRequest.php b/src/VPC2.0/Apis/DescribeRouteTableRequest.php similarity index 89% rename from src/VPC/Apis/DescribeRouteTableRequest.php rename to src/VPC2.0/Apis/DescribeRouteTableRequest.php index 4fa575ef..408f1103 100644 --- a/src/VPC/Apis/DescribeRouteTableRequest.php +++ b/src/VPC2.0/Apis/DescribeRouteTableRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: 所属VPC的资源ID * @@ -83,11 +82,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * RouteTableId: 路由表资源ID * @@ -103,11 +101,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * OffSet: 数据偏移量。默认为0 * @@ -123,11 +120,10 @@ public function getOffSet() * * @param int $offSet */ - public function setOffSet($offSet) + public function setOffSet(int $offSet) { $this->set("OffSet", $offSet); } - /** * Limit: 数据分页值。默认为20 * @@ -143,11 +139,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * BusinessId: 业务组ID * @@ -163,7 +158,7 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } diff --git a/src/VPC/Apis/DescribeRouteTableResponse.php b/src/VPC2.0/Apis/DescribeRouteTableResponse.php similarity index 86% rename from src/VPC/Apis/DescribeRouteTableResponse.php rename to src/VPC2.0/Apis/DescribeRouteTableResponse.php index bde86317..3b0ec509 100644 --- a/src/VPC/Apis/DescribeRouteTableResponse.php +++ b/src/VPC2.0/Apis/DescribeRouteTableResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new RouteTableInfo($item)); + array_push($result, new RouteTableInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getRouteTables() /** * RouteTables: 路由表信息 * - * @param RouteTableInfo[] $routeTables + * @param RouteTableInfoModel[] $routeTables */ public function setRouteTables(array $routeTables) { @@ -55,7 +57,6 @@ public function setRouteTables(array $routeTables) } return $result; } - /** * TotalCount: RouteTables字段的数量 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/DescribeSecondaryIpRequest.php b/src/VPC2.0/Apis/DescribeSecondaryIpRequest.php similarity index 90% rename from src/VPC/Apis/DescribeSecondaryIpRequest.php rename to src/VPC2.0/Apis/DescribeSecondaryIpRequest.php index 241c54d9..406d34cb 100644 --- a/src/VPC/Apis/DescribeSecondaryIpRequest.php +++ b/src/VPC2.0/Apis/DescribeSecondaryIpRequest.php @@ -1,6 +1,7 @@ markRequired("VPCId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网Id * @@ -85,11 +84,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPCId * @@ -105,11 +103,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Ip: Ip * @@ -125,11 +122,10 @@ public function getIp() * * @param string $ip */ - public function setIp($ip) + public function setIp(string $ip) { $this->set("Ip", $ip); } - /** * Mac: Mac * @@ -145,7 +141,7 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } diff --git a/src/VPC/Apis/DescribeSecondaryIpResponse.php b/src/VPC2.0/Apis/DescribeSecondaryIpResponse.php similarity index 87% rename from src/VPC/Apis/DescribeSecondaryIpResponse.php rename to src/VPC2.0/Apis/DescribeSecondaryIpResponse.php index ec4b43d3..7eb396fb 100644 --- a/src/VPC/Apis/DescribeSecondaryIpResponse.php +++ b/src/VPC2.0/Apis/DescribeSecondaryIpResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new IpInfo($item)); + array_push($result, new IpInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: * - * @param IpInfo[] $dataSet + * @param IpInfoModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC2.0/Apis/DescribeSnatDnatRuleRequest.php b/src/VPC2.0/Apis/DescribeSnatDnatRuleRequest.php new file mode 100644 index 00000000..e64a074e --- /dev/null +++ b/src/VPC2.0/Apis/DescribeSnatDnatRuleRequest.php @@ -0,0 +1,108 @@ + "DescribeSnatDnatRule"]); + $this->markRequired("Region"); + } + + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @return string|null + */ + public function getRegion() + { + return $this->get("Region"); + } + + /** + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) + * + * @param string $region + */ + public function setRegion(string $region) + { + $this->set("Region", $region); + } + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @return string|null + */ + public function getProjectId() + { + return $this->get("ProjectId"); + } + + /** + * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) + * + * @param string $projectId + */ + public function setProjectId(string $projectId) + { + $this->set("ProjectId", $projectId); + } + /** + * NATGWId: 获取NAT上添加的所有SnatDnatRule信息 + * + * @return string[]|null + */ + public function getNATGWId() + { + return $this->get("NATGWId"); + } + + /** + * NATGWId: 获取NAT上添加的所有SnatDnatRule信息 + * + * @param string[] $natgwId + */ + public function setNATGWId(array $natgwId) + { + $this->set("NATGWId", $natgwId); + } + /** + * EIP: 获取EIP对应的SnatDnatRule信息 + * + * @return string[]|null + */ + public function getEIP() + { + return $this->get("EIP"); + } + + /** + * EIP: 获取EIP对应的SnatDnatRule信息 + * + * @param string[] $eip + */ + public function setEIP(array $eip) + { + $this->set("EIP", $eip); + } +} diff --git a/src/VPC2.0/Apis/DescribeSnatDnatRuleResponse.php b/src/VPC2.0/Apis/DescribeSnatDnatRuleResponse.php new file mode 100644 index 00000000..f4cd1307 --- /dev/null +++ b/src/VPC2.0/Apis/DescribeSnatDnatRuleResponse.php @@ -0,0 +1,59 @@ +get("DataSet"); + if ($items == null) { + return []; + } + $result = []; + foreach ($items as $i => $item) { + array_push($result, new SnatDnatRuleInfoModel($item)); + } + return $result; + } + + /** + * DataSet: 规则信息 + * + * @param SnatDnatRuleInfoModel[] $dataSet + */ + public function setDataSet(array $dataSet) + { + $result = []; + foreach ($dataSet as $i => $item) { + array_push($result, $item->getAll()); + } + return $result; + } +} diff --git a/src/VPC/Apis/DescribeSnatRuleRequest.php b/src/VPC2.0/Apis/DescribeSnatRuleRequest.php similarity index 90% rename from src/VPC/Apis/DescribeSnatRuleRequest.php rename to src/VPC2.0/Apis/DescribeSnatRuleRequest.php index 3b971d23..ffd67dae 100644 --- a/src/VPC/Apis/DescribeSnatRuleRequest.php +++ b/src/VPC2.0/Apis/DescribeSnatRuleRequest.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关的ID * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * SourceIp: 需要出外网的私网IP地址,例如10.9.7.xx * @@ -104,11 +102,10 @@ public function getSourceIp() * * @param string $sourceIp */ - public function setSourceIp($sourceIp) + public function setSourceIp(string $sourceIp) { $this->set("SourceIp", $sourceIp); } - /** * SnatIp: EIP的ip地址,例如106.75.xx.xx * @@ -124,11 +121,10 @@ public function getSnatIp() * * @param string $snatIp */ - public function setSnatIp($snatIp) + public function setSnatIp(string $snatIp) { $this->set("SnatIp", $snatIp); } - /** * Offset: 偏移,默认为0 * @@ -144,11 +140,10 @@ public function getOffset() * * @param string $offset */ - public function setOffset($offset) + public function setOffset(string $offset) { $this->set("Offset", $offset); } - /** * Limit: 分页,默认为20 * @@ -164,7 +159,7 @@ public function getLimit() * * @param string $limit */ - public function setLimit($limit) + public function setLimit(string $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeSnatRuleResponse.php b/src/VPC2.0/Apis/DescribeSnatRuleResponse.php similarity index 86% rename from src/VPC/Apis/DescribeSnatRuleResponse.php rename to src/VPC2.0/Apis/DescribeSnatRuleResponse.php index f9ff140d..119a4313 100644 --- a/src/VPC/Apis/DescribeSnatRuleResponse.php +++ b/src/VPC2.0/Apis/DescribeSnatRuleResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NATGWSnatRule($item)); + array_push($result, new NATGWSnatRuleModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 某个NAT网关的所有Snat规则 * - * @param NATGWSnatRule[] $dataSet + * @param NATGWSnatRuleModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 规则数量 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/DescribeSubnetRequest.php b/src/VPC2.0/Apis/DescribeSubnetRequest.php similarity index 90% rename from src/VPC/Apis/DescribeSubnetRequest.php rename to src/VPC2.0/Apis/DescribeSubnetRequest.php index f1534856..b5ae5e5d 100644 --- a/src/VPC/Apis/DescribeSubnetRequest.php +++ b/src/VPC2.0/Apis/DescribeSubnetRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetIds: 子网id数组,适用于一次查询多个子网信息 * @@ -87,7 +86,6 @@ public function setSubnetIds(array $subnetIds) { $this->set("SubnetIds", $subnetIds); } - /** * SubnetId: 子网id,适用于一次查询一个子网信息 * @@ -103,11 +101,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * RouteTableId: 路由表Id * @@ -123,11 +120,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * VPCId: VPC资源id * @@ -143,11 +139,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Tag: 业务组名称,默认为Default * @@ -163,11 +158,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Offset: 偏移量,默认为0 * @@ -183,11 +177,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 列表长度,默认为20 * @@ -203,11 +196,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * ShowAvailableIPs: 是否返回子网的可用IP数,true为是,false为否,默认不返回 * @@ -223,7 +215,7 @@ public function getShowAvailableIPs() * * @param boolean $showAvailableIPs */ - public function setShowAvailableIPs($showAvailableIPs) + public function setShowAvailableIPs(bool $showAvailableIPs) { $this->set("ShowAvailableIPs", $showAvailableIPs); } diff --git a/src/VPC/Apis/DescribeSubnetResourceRequest.php b/src/VPC2.0/Apis/DescribeSubnetResourceRequest.php similarity index 91% rename from src/VPC/Apis/DescribeSubnetResourceRequest.php rename to src/VPC2.0/Apis/DescribeSubnetResourceRequest.php index ddae73ea..dd90b351 100644 --- a/src/VPC/Apis/DescribeSubnetResourceRequest.php +++ b/src/VPC2.0/Apis/DescribeSubnetResourceRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网id * @@ -84,11 +83,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * ResourceType: 资源类型,默认为全部资源类型。枚举值为:UHOST,云主机;PHOST,物理云主机;ULB,负载均衡;UHADOOP_HOST,hadoop节点;UFORTRESS_HOST,堡垒机;UNATGW,NAT网关;UKAFKA,Kafka消息队列;UMEM,内存存储;DOCKER,容器集群;UDB,数据库;UDW,数据仓库;VIP,内网VIP. * @@ -104,11 +102,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -124,11 +121,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 单页返回数据长度,默认为20 * @@ -144,7 +140,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeSubnetResourceResponse.php b/src/VPC2.0/Apis/DescribeSubnetResourceResponse.php similarity index 86% rename from src/VPC/Apis/DescribeSubnetResourceResponse.php rename to src/VPC2.0/Apis/DescribeSubnetResourceResponse.php index 50bb806d..164664da 100644 --- a/src/VPC/Apis/DescribeSubnetResourceResponse.php +++ b/src/VPC2.0/Apis/DescribeSubnetResourceResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 返回数据集,请见SubnetResource * - * @return SubnetResource[]|null + * @return SubnetResourceModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SubnetResource($item)); + array_push($result, new SubnetResourceModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 返回数据集,请见SubnetResource * - * @param SubnetResource[] $dataSet + * @param SubnetResourceModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeSubnetResponse.php b/src/VPC2.0/Apis/DescribeSubnetResponse.php similarity index 87% rename from src/VPC/Apis/DescribeSubnetResponse.php rename to src/VPC2.0/Apis/DescribeSubnetResponse.php index f2948c70..401f8a97 100644 --- a/src/VPC/Apis/DescribeSubnetResponse.php +++ b/src/VPC2.0/Apis/DescribeSubnetResponse.php @@ -1,6 +1,7 @@ set("TotalCount", $totalCount); } - /** * DataSet: 子网信息数组,具体资源见下方SubnetInfo * - * @return SubnetInfo[]|null + * @return SubnetInfoModel[]|null */ public function getDataSet() { @@ -56,7 +57,7 @@ public function getDataSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new SubnetInfo($item)); + array_push($result, new SubnetInfoModel($item)); } return $result; } @@ -64,7 +65,7 @@ public function getDataSet() /** * DataSet: 子网信息数组,具体资源见下方SubnetInfo * - * @param SubnetInfo[] $dataSet + * @param SubnetInfoModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeVIPRequest.php b/src/VPC2.0/Apis/DescribeVIPRequest.php similarity index 90% rename from src/VPC/Apis/DescribeVIPRequest.php rename to src/VPC2.0/Apis/DescribeVIPRequest.php index b2b0b27e..fad17e86 100644 --- a/src/VPC/Apis/DescribeVIPRequest.php +++ b/src/VPC2.0/Apis/DescribeVIPRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区。参见 [可用区列表](../summary/regionlist.html) * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: vpc的id,指定SubnetId时必填 * @@ -104,11 +102,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetId: 子网id,不指定则获取VPCId下的所有vip * @@ -124,11 +121,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VIPId: VIP ID * @@ -144,11 +140,10 @@ public function getVIPId() * * @param string $vipId */ - public function setVIPId($vipId) + public function setVIPId(string $vipId) { $this->set("VIPId", $vipId); } - /** * Tag: 业务组名称, 默认为 Default * @@ -164,11 +159,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * BusinessId: 业务组 * @@ -184,7 +178,7 @@ public function getBusinessId() * * @param string $businessId */ - public function setBusinessId($businessId) + public function setBusinessId(string $businessId) { $this->set("BusinessId", $businessId); } diff --git a/src/VPC/Apis/DescribeVIPResponse.php b/src/VPC2.0/Apis/DescribeVIPResponse.php similarity index 89% rename from src/VPC/Apis/DescribeVIPResponse.php rename to src/VPC2.0/Apis/DescribeVIPResponse.php index 0ed3efbe..fbd07564 100644 --- a/src/VPC/Apis/DescribeVIPResponse.php +++ b/src/VPC2.0/Apis/DescribeVIPResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VIPDetailSet($item)); + array_push($result, new VIPDetailSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getVIPSet() /** * VIPSet: 内网VIP详情,请见VIPDetailSet * - * @param VIPDetailSet[] $vipSet + * @param VIPDetailSetModel[] $vipSet */ public function setVIPSet(array $vipSet) { @@ -54,7 +56,6 @@ public function setVIPSet(array $vipSet) } return $result; } - /** * DataSet: 内网VIP地址列表 * @@ -74,7 +75,6 @@ public function setDataSet(array $dataSet) { $this->set("DataSet", $dataSet); } - /** * TotalCount: vip数量 * @@ -90,7 +90,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/DescribeVPCIntercomRequest.php b/src/VPC2.0/Apis/DescribeVPCIntercomRequest.php similarity index 90% rename from src/VPC/Apis/DescribeVPCIntercomRequest.php rename to src/VPC2.0/Apis/DescribeVPCIntercomRequest.php index f979fe72..b807c43b 100644 --- a/src/VPC/Apis/DescribeVPCIntercomRequest.php +++ b/src/VPC2.0/Apis/DescribeVPCIntercomRequest.php @@ -1,6 +1,7 @@ markRequired("VPCId"); } - /** * Region: 源VPC所在地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 源VPC所在项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPC短ID * @@ -84,11 +83,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * DstRegion: 目的VPC所在地域,默认为全部地域 * @@ -104,11 +102,10 @@ public function getDstRegion() * * @param string $dstRegion */ - public function setDstRegion($dstRegion) + public function setDstRegion(string $dstRegion) { $this->set("DstRegion", $dstRegion); } - /** * DstProjectId: 目的项目ID,默认为全部项目 * @@ -124,7 +121,7 @@ public function getDstProjectId() * * @param string $dstProjectId */ - public function setDstProjectId($dstProjectId) + public function setDstProjectId(string $dstProjectId) { $this->set("DstProjectId", $dstProjectId); } diff --git a/src/VPC/Apis/DescribeVPCIntercomResponse.php b/src/VPC2.0/Apis/DescribeVPCIntercomResponse.php similarity index 86% rename from src/VPC/Apis/DescribeVPCIntercomResponse.php rename to src/VPC2.0/Apis/DescribeVPCIntercomResponse.php index ce4d3d99..474afa5b 100644 --- a/src/VPC/Apis/DescribeVPCIntercomResponse.php +++ b/src/VPC2.0/Apis/DescribeVPCIntercomResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VPCIntercomInfo($item)); + array_push($result, new VPCIntercomInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 联通VPC信息数组 * - * @param VPCIntercomInfo[] $dataSet + * @param VPCIntercomInfoModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeVPCRequest.php b/src/VPC2.0/Apis/DescribeVPCRequest.php similarity index 91% rename from src/VPC/Apis/DescribeVPCRequest.php rename to src/VPC2.0/Apis/DescribeVPCRequest.php index 71dc4316..b8c869bc 100644 --- a/src/VPC/Apis/DescribeVPCRequest.php +++ b/src/VPC2.0/Apis/DescribeVPCRequest.php @@ -1,6 +1,7 @@ markRequired("ProjectId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCIds: VPCId * @@ -88,7 +87,6 @@ public function setVPCIds(array $vpcIds) { $this->set("VPCIds", $vpcIds); } - /** * Tag: 业务组名称 * @@ -104,11 +102,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Offset: * @@ -124,11 +121,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: * @@ -144,7 +140,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeVPCResponse.php b/src/VPC2.0/Apis/DescribeVPCResponse.php similarity index 88% rename from src/VPC/Apis/DescribeVPCResponse.php rename to src/VPC2.0/Apis/DescribeVPCResponse.php index d2de103d..f6d4e112 100644 --- a/src/VPC/Apis/DescribeVPCResponse.php +++ b/src/VPC2.0/Apis/DescribeVPCResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VPCInfo($item)); + array_push($result, new VPCInfoModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: vpc信息,具体结构见下方VPCInfo * - * @param VPCInfo[] $dataSet + * @param VPCInfoModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/DescribeWhiteListResourceRequest.php b/src/VPC2.0/Apis/DescribeWhiteListResourceRequest.php similarity index 92% rename from src/VPC/Apis/DescribeWhiteListResourceRequest.php rename to src/VPC2.0/Apis/DescribeWhiteListResourceRequest.php index ea6a2e41..ef61f887 100644 --- a/src/VPC/Apis/DescribeWhiteListResourceRequest.php +++ b/src/VPC2.0/Apis/DescribeWhiteListResourceRequest.php @@ -1,6 +1,7 @@ markRequired("NATGWIds"); } - /** * ProjectId: 项目id @@ -45,11 +46,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * @@ -65,11 +65,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * NATGWIds: NAT网关的Id * @@ -89,7 +88,6 @@ public function setNATGWIds(array $natgwIds) { $this->set("NATGWIds", $natgwIds); } - /** * Offset: 数据偏移量, 默认为0 * @@ -105,11 +103,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -125,7 +122,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/DescribeWhiteListResourceResponse.php b/src/VPC2.0/Apis/DescribeWhiteListResourceResponse.php similarity index 86% rename from src/VPC/Apis/DescribeWhiteListResourceResponse.php rename to src/VPC2.0/Apis/DescribeWhiteListResourceResponse.php index 09e89b31..bead3018 100644 --- a/src/VPC/Apis/DescribeWhiteListResourceResponse.php +++ b/src/VPC2.0/Apis/DescribeWhiteListResourceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NatGWWhitelistDataSet($item)); + array_push($result, new NatGWWhitelistDataSetModel($item)); } return $result; } @@ -45,7 +47,7 @@ public function getDataSet() /** * DataSet: 白名单资源的详细信息,详见DescribeResourceWhiteListDataSet * - * @param NatGWWhitelistDataSet[] $dataSet + * @param NatGWWhitelistDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -55,7 +57,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 上述DataSet总数量 * @@ -71,7 +72,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/EnableWhiteListRequest.php b/src/VPC2.0/Apis/EnableWhiteListRequest.php similarity index 91% rename from src/VPC/Apis/EnableWhiteListRequest.php rename to src/VPC2.0/Apis/EnableWhiteListRequest.php index cb2bcd04..7a24b92d 100644 --- a/src/VPC/Apis/EnableWhiteListRequest.php +++ b/src/VPC2.0/Apis/EnableWhiteListRequest.php @@ -1,6 +1,7 @@ markRequired("IfOpen"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * IfOpen: 白名单开关标记。0:关闭;1:开启。默认为0 * @@ -105,7 +103,7 @@ public function getIfOpen() * * @param int $ifOpen */ - public function setIfOpen($ifOpen) + public function setIfOpen(int $ifOpen) { $this->set("IfOpen", $ifOpen); } diff --git a/src/VPC/Apis/EnableWhiteListResponse.php b/src/VPC2.0/Apis/EnableWhiteListResponse.php similarity index 93% rename from src/VPC/Apis/EnableWhiteListResponse.php rename to src/VPC2.0/Apis/EnableWhiteListResponse.php index c1f378eb..cc27e28a 100644 --- a/src/VPC/Apis/EnableWhiteListResponse.php +++ b/src/VPC2.0/Apis/EnableWhiteListResponse.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * Limit: 返回数据长度,默认为20 * @@ -104,11 +102,10 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } - /** * Offset: 列表起始位置偏移量,默认为0 * @@ -124,7 +121,7 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } diff --git a/src/VPC/Apis/GetAvailableResourceForPolicyResponse.php b/src/VPC2.0/Apis/GetAvailableResourceForPolicyResponse.php similarity index 87% rename from src/VPC/Apis/GetAvailableResourceForPolicyResponse.php rename to src/VPC2.0/Apis/GetAvailableResourceForPolicyResponse.php index 783b92af..535b25a4 100644 --- a/src/VPC/Apis/GetAvailableResourceForPolicyResponse.php +++ b/src/VPC2.0/Apis/GetAvailableResourceForPolicyResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new GetAvailableResourceForPolicyDataSet($item)); + array_push($result, new GetAvailableResourceForPolicyDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 支持资源类型的信息 * - * @param GetAvailableResourceForPolicyDataSet[] $dataSet + * @param GetAvailableResourceForPolicyDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/GetAvailableResourceForSnatRuleRequest.php b/src/VPC2.0/Apis/GetAvailableResourceForSnatRuleRequest.php similarity index 91% rename from src/VPC/Apis/GetAvailableResourceForSnatRuleRequest.php rename to src/VPC2.0/Apis/GetAvailableResourceForSnatRuleRequest.php index 714d4bad..76c78a95 100644 --- a/src/VPC/Apis/GetAvailableResourceForSnatRuleRequest.php +++ b/src/VPC2.0/Apis/GetAvailableResourceForSnatRuleRequest.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +84,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * Offset: 数据偏移量, 默认为0 * @@ -105,11 +103,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -125,7 +122,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/GetAvailableResourceForSnatRuleResponse.php b/src/VPC2.0/Apis/GetAvailableResourceForSnatRuleResponse.php similarity index 86% rename from src/VPC/Apis/GetAvailableResourceForSnatRuleResponse.php rename to src/VPC2.0/Apis/GetAvailableResourceForSnatRuleResponse.php index f5d7d01b..f27ab19b 100644 --- a/src/VPC/Apis/GetAvailableResourceForSnatRuleResponse.php +++ b/src/VPC2.0/Apis/GetAvailableResourceForSnatRuleResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new GetAvailableResourceForSnatRuleDataSet($item)); + array_push($result, new GetAvailableResourceForSnatRuleDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 返回的资源详细信息 * - * @param GetAvailableResourceForSnatRuleDataSet[] $dataSet + * @param GetAvailableResourceForSnatRuleDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/GetAvailableResourceForWhiteListRequest.php b/src/VPC2.0/Apis/GetAvailableResourceForWhiteListRequest.php similarity index 91% rename from src/VPC/Apis/GetAvailableResourceForWhiteListRequest.php rename to src/VPC2.0/Apis/GetAvailableResourceForWhiteListRequest.php index 9ac44dda..969bc9dc 100644 --- a/src/VPC/Apis/GetAvailableResourceForWhiteListRequest.php +++ b/src/VPC2.0/Apis/GetAvailableResourceForWhiteListRequest.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * Offset: 数据偏移量, 默认为0 * @@ -104,11 +102,10 @@ public function getOffset() * * @param int $offset */ - public function setOffset($offset) + public function setOffset(int $offset) { $this->set("Offset", $offset); } - /** * Limit: 数据分页值, 默认为20 * @@ -124,7 +121,7 @@ public function getLimit() * * @param int $limit */ - public function setLimit($limit) + public function setLimit(int $limit) { $this->set("Limit", $limit); } diff --git a/src/VPC/Apis/GetAvailableResourceForWhiteListResponse.php b/src/VPC2.0/Apis/GetAvailableResourceForWhiteListResponse.php similarity index 87% rename from src/VPC/Apis/GetAvailableResourceForWhiteListResponse.php rename to src/VPC2.0/Apis/GetAvailableResourceForWhiteListResponse.php index c75c6d79..97669b50 100644 --- a/src/VPC/Apis/GetAvailableResourceForWhiteListResponse.php +++ b/src/VPC2.0/Apis/GetAvailableResourceForWhiteListResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new GetAvailableResourceForWhiteListDataSet($item)); + array_push($result, new GetAvailableResourceForWhiteListDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 返回白名单列表的详细信息 * - * @param GetAvailableResourceForWhiteListDataSet[] $dataSet + * @param GetAvailableResourceForWhiteListDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { @@ -54,7 +56,6 @@ public function setDataSet(array $dataSet) } return $result; } - /** * TotalCount: 白名单资源列表的总的个数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/GetNetworkAclTargetResourceRequest.php b/src/VPC2.0/Apis/GetNetworkAclTargetResourceRequest.php similarity index 94% rename from src/VPC/Apis/GetNetworkAclTargetResourceRequest.php rename to src/VPC2.0/Apis/GetNetworkAclTargetResourceRequest.php index 85f280bc..e7163f10 100644 --- a/src/VPC/Apis/GetNetworkAclTargetResourceRequest.php +++ b/src/VPC2.0/Apis/GetNetworkAclTargetResourceRequest.php @@ -1,6 +1,7 @@ markRequired("SubnetworkId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetworkId: 子网ID。 * diff --git a/src/VPC/Apis/GetNetworkAclTargetResourceResponse.php b/src/VPC2.0/Apis/GetNetworkAclTargetResourceResponse.php similarity index 87% rename from src/VPC/Apis/GetNetworkAclTargetResourceResponse.php rename to src/VPC2.0/Apis/GetNetworkAclTargetResourceResponse.php index 78b1b141..0e9f26b1 100644 --- a/src/VPC/Apis/GetNetworkAclTargetResourceResponse.php +++ b/src/VPC2.0/Apis/GetNetworkAclTargetResourceResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new TargetResourceInfo($item)); + array_push($result, new TargetResourceInfoModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getTargetResourceList() /** * TargetResourceList: ACL规则应用目标资源列表,具体结构见下方TargetResourceInfo * - * @param TargetResourceInfo[] $targetResourceList + * @param TargetResourceInfoModel[] $targetResourceList */ public function setTargetResourceList(array $targetResourceList) { @@ -54,7 +56,6 @@ public function setTargetResourceList(array $targetResourceList) } return $result; } - /** * TotalCount: ACL规则应用目标资源总数 * @@ -70,7 +71,7 @@ public function getTotalCount() * * @param int $totalCount */ - public function setTotalCount($totalCount) + public function setTotalCount(int $totalCount) { $this->set("TotalCount", $totalCount); } diff --git a/src/VPC/Apis/ListSubnetForNATGWRequest.php b/src/VPC2.0/Apis/ListSubnetForNATGWRequest.php similarity index 91% rename from src/VPC/Apis/ListSubnetForNATGWRequest.php rename to src/VPC2.0/Apis/ListSubnetForNATGWRequest.php index 953cb603..8f21fbe2 100644 --- a/src/VPC/Apis/ListSubnetForNATGWRequest.php +++ b/src/VPC2.0/Apis/ListSubnetForNATGWRequest.php @@ -1,6 +1,7 @@ markRequired("Region"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -43,11 +44,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -63,11 +63,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: NAT网关所属VPC Id。默认值为Default VPC Id * @@ -83,7 +82,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Apis/ListSubnetForNATGWResponse.php b/src/VPC2.0/Apis/ListSubnetForNATGWResponse.php similarity index 86% rename from src/VPC/Apis/ListSubnetForNATGWResponse.php rename to src/VPC2.0/Apis/ListSubnetForNATGWResponse.php index b4505bc5..cdde9da8 100644 --- a/src/VPC/Apis/ListSubnetForNATGWResponse.php +++ b/src/VPC2.0/Apis/ListSubnetForNATGWResponse.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new NatgwSubnetDataSet($item)); + array_push($result, new NatgwSubnetDataSetModel($item)); } return $result; } @@ -44,7 +46,7 @@ public function getDataSet() /** * DataSet: 具体参数请见NatgwSubnetDataSet * - * @param NatgwSubnetDataSet[] $dataSet + * @param NatgwSubnetDataSetModel[] $dataSet */ public function setDataSet(array $dataSet) { diff --git a/src/VPC/Apis/ModifyRouteRuleRequest.php b/src/VPC2.0/Apis/ModifyRouteRuleRequest.php similarity index 95% rename from src/VPC/Apis/ModifyRouteRuleRequest.php rename to src/VPC2.0/Apis/ModifyRouteRuleRequest.php index 11c7cdf0..40e986b2 100644 --- a/src/VPC/Apis/ModifyRouteRuleRequest.php +++ b/src/VPC2.0/Apis/ModifyRouteRuleRequest.php @@ -1,6 +1,7 @@ markRequired("RouteRule"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RouteTableId: 通过DescribeRouteTable拿到 * @@ -86,11 +85,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * RouteRule: 格式: RouteRuleId | 目的网段 | 下一跳类型(支持INSTANCE、VIP) | 下一跳 |优先级(保留字段,填写0即可)| 备注 | 增、删、改标志(add/delete/update) 。"添加"示例: test_id | 10.8.0.0/16 | instance | uhost-xd8ja | 0 | Default Route Rule| add (添加的RouteRuleId填任意非空字符串) 。"删除"示例: routerule-xk3jxa | 10.8.0.0/16 | instance | uhost-xd8ja | 0 | Default Route Rule| delete (RouteRuleId来自DescribeRouteTable中) 。“修改”示例: routerule-xk3jxa | 10.8.0.0/16 | instance | uhost-cjksa2 | 0 | Default Route Rule| update (RouteRuleId来自DescribeRouteTable中) * diff --git a/src/VPC/Apis/ModifyRouteRuleResponse.php b/src/VPC2.0/Apis/ModifyRouteRuleResponse.php similarity index 93% rename from src/VPC/Apis/ModifyRouteRuleResponse.php rename to src/VPC2.0/Apis/ModifyRouteRuleResponse.php index 14f333b0..3ce5f07a 100644 --- a/src/VPC/Apis/ModifyRouteRuleResponse.php +++ b/src/VPC2.0/Apis/ModifyRouteRuleResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -47,11 +48,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -67,11 +67,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * Ip: Secondary IP * @@ -87,11 +86,10 @@ public function getIp() * * @param string $ip */ - public function setIp($ip) + public function setIp(string $ip) { $this->set("Ip", $ip); } - /** * OldMac: 旧 Mac。Secondary IP 当前所绑定的 Mac * @@ -107,11 +105,10 @@ public function getOldMac() * * @param string $oldMac */ - public function setOldMac($oldMac) + public function setOldMac(string $oldMac) { $this->set("OldMac", $oldMac); } - /** * NewMac: 新 Mac。Secondary IP 迁移的目的 Mac * @@ -127,11 +124,10 @@ public function getNewMac() * * @param string $newMac */ - public function setNewMac($newMac) + public function setNewMac(string $newMac) { $this->set("NewMac", $newMac); } - /** * SubnetId: 子网 ID。IP/OldMac/NewMac 三者必须在同一子网 * @@ -147,7 +143,7 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } diff --git a/src/VPC/Apis/MoveSecondaryIPMacResponse.php b/src/VPC2.0/Apis/MoveSecondaryIPMacResponse.php similarity index 93% rename from src/VPC/Apis/MoveSecondaryIPMacResponse.php rename to src/VPC2.0/Apis/MoveSecondaryIPMacResponse.php index 2c29dc2f..791d984d 100644 --- a/src/VPC/Apis/MoveSecondaryIPMacResponse.php +++ b/src/VPC2.0/Apis/MoveSecondaryIPMacResponse.php @@ -1,6 +1,7 @@ markRequired("VIPId"); } - /** * Region: 地域 @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * Zone: 可用区 * @@ -64,11 +64,10 @@ public function getZone() * * @param string $zone */ - public function setZone($zone) + public function setZone(string $zone) { $this->set("Zone", $zone); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写 * @@ -84,11 +83,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VIPId: 内网VIP的id * @@ -104,7 +102,7 @@ public function getVIPId() * * @param string $vipId */ - public function setVIPId($vipId) + public function setVIPId(string $vipId) { $this->set("VIPId", $vipId); } diff --git a/src/VPC/Apis/ReleaseVIPResponse.php b/src/VPC2.0/Apis/ReleaseVIPResponse.php similarity index 93% rename from src/VPC/Apis/ReleaseVIPResponse.php rename to src/VPC2.0/Apis/ReleaseVIPResponse.php index b5aed27c..1bbac2e6 100644 --- a/src/VPC/Apis/ReleaseVIPResponse.php +++ b/src/VPC2.0/Apis/ReleaseVIPResponse.php @@ -1,6 +1,7 @@ markRequired("NATGWId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -84,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * ExportIp: NAT网关绑定的EIP。ExportIp和ExportEipId必填一个 * @@ -104,11 +102,10 @@ public function getExportIp() * * @param string $exportIp */ - public function setExportIp($exportIp) + public function setExportIp(string $exportIp) { $this->set("ExportIp", $exportIp); } - /** * ExportEipId: NAT网关绑定的EIP Id。ExportIp和ExportEipId必填一个 * @@ -124,7 +121,7 @@ public function getExportEipId() * * @param string $exportEipId */ - public function setExportEipId($exportEipId) + public function setExportEipId(string $exportEipId) { $this->set("ExportEipId", $exportEipId); } diff --git a/src/VPC/Apis/SetGwDefaultExportResponse.php b/src/VPC2.0/Apis/SetGwDefaultExportResponse.php similarity index 93% rename from src/VPC/Apis/SetGwDefaultExportResponse.php rename to src/VPC2.0/Apis/SetGwDefaultExportResponse.php index 4be92ea8..60cd4456 100644 --- a/src/VPC/Apis/SetGwDefaultExportResponse.php +++ b/src/VPC2.0/Apis/SetGwDefaultExportResponse.php @@ -1,6 +1,7 @@ markRequired("DstPort"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -50,11 +51,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -70,11 +70,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -90,11 +89,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * PolicyId: 转发策略Id * @@ -110,11 +108,10 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } - /** * Protocol: 协议类型。枚举值为:TCP 、 UDP * @@ -130,11 +127,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * SrcEIPId: 源IP。填写对应的EIP Id * @@ -150,11 +146,10 @@ public function getSrcEIPId() * * @param string $srcEIPId */ - public function setSrcEIPId($srcEIPId) + public function setSrcEIPId(string $srcEIPId) { $this->set("SrcEIPId", $srcEIPId); } - /** * SrcPort: 源端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-6553 * @@ -170,11 +165,10 @@ public function getSrcPort() * * @param string $srcPort */ - public function setSrcPort($srcPort) + public function setSrcPort(string $srcPort) { $this->set("SrcPort", $srcPort); } - /** * DstIP: 目标IP。填写对应的目标IP地址 * @@ -190,11 +184,10 @@ public function getDstIP() * * @param string $dstIP */ - public function setDstIP($dstIP) + public function setDstIP(string $dstIP) { $this->set("DstIP", $dstIP); } - /** * DstPort: 目标端口。可填写固定端口,也可填写端口范围。支持的端口范围为1-65535 * @@ -210,11 +203,10 @@ public function getDstPort() * * @param string $dstPort */ - public function setDstPort($dstPort) + public function setDstPort(string $dstPort) { $this->set("DstPort", $dstPort); } - /** * PolicyName: 转发策略名称。默认为空 * @@ -230,7 +222,7 @@ public function getPolicyName() * * @param string $policyName */ - public function setPolicyName($policyName) + public function setPolicyName(string $policyName) { $this->set("PolicyName", $policyName); } diff --git a/src/VPC/Apis/UpdateNATGWPolicyResponse.php b/src/VPC2.0/Apis/UpdateNATGWPolicyResponse.php similarity index 93% rename from src/VPC/Apis/UpdateNATGWPolicyResponse.php rename to src/VPC2.0/Apis/UpdateNATGWPolicyResponse.php index d53a5831..84129f69 100644 --- a/src/VPC/Apis/UpdateNATGWPolicyResponse.php +++ b/src/VPC2.0/Apis/UpdateNATGWPolicyResponse.php @@ -1,6 +1,7 @@ "UpdateNATGWSubnet"]); $this->markRequired("Region"); $this->markRequired("NATGWId"); - $this->markRequired("SubnetworkIds"); } - /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @return string|null */ @@ -41,17 +41,16 @@ public function getRegion() } /** - * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) + * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @return string|null */ @@ -61,15 +60,14 @@ public function getProjectId() } /** - * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) + * ProjectId: 项目Id。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关Id * @@ -85,11 +83,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * SubnetworkIds: NAT网关绑定的子网Id * diff --git a/src/VPC/Apis/UpdateNATGWSubnetResponse.php b/src/VPC2.0/Apis/UpdateNATGWSubnetResponse.php similarity index 93% rename from src/VPC/Apis/UpdateNATGWSubnetResponse.php rename to src/VPC2.0/Apis/UpdateNATGWSubnetResponse.php index 1a44a2c6..d8264e58 100644 --- a/src/VPC/Apis/UpdateNATGWSubnetResponse.php +++ b/src/VPC2.0/Apis/UpdateNATGWSubnetResponse.php @@ -1,6 +1,7 @@ markRequired("EntryAction"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -51,11 +52,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -71,11 +71,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclId: ACL的ID * @@ -91,11 +90,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * EntryId: 需要更新的Entry Id * @@ -111,11 +109,10 @@ public function getEntryId() * * @param string $entryId */ - public function setEntryId($entryId) + public function setEntryId(string $entryId) { $this->set("EntryId", $entryId); } - /** * Priority: Entry的优先级,对于同样的Direction来说,不能重复 * @@ -131,11 +128,10 @@ public function getPriority() * * @param int $priority */ - public function setPriority($priority) + public function setPriority(int $priority) { $this->set("Priority", $priority); } - /** * Direction: 出向或者入向(“Ingress”, "Egress") * @@ -151,11 +147,10 @@ public function getDirection() * * @param string $direction */ - public function setDirection($direction) + public function setDirection(string $direction) { $this->set("Direction", $direction); } - /** * IpProtocol: 针对的协议规则 * @@ -171,11 +166,10 @@ public function getIpProtocol() * * @param string $ipProtocol */ - public function setIpProtocol($ipProtocol) + public function setIpProtocol(string $ipProtocol) { $this->set("IpProtocol", $ipProtocol); } - /** * CidrBlock: IPv4段的CIDR表示 * @@ -191,11 +185,10 @@ public function getCidrBlock() * * @param string $cidrBlock */ - public function setCidrBlock($cidrBlock) + public function setCidrBlock(string $cidrBlock) { $this->set("CidrBlock", $cidrBlock); } - /** * PortRange: 针对的端口范围 * @@ -211,11 +204,10 @@ public function getPortRange() * * @param string $portRange */ - public function setPortRange($portRange) + public function setPortRange(string $portRange) { $this->set("PortRange", $portRange); } - /** * EntryAction: 规则的行为("Accept", "Reject") * @@ -231,11 +223,10 @@ public function getEntryAction() * * @param string $entryAction */ - public function setEntryAction($entryAction) + public function setEntryAction(string $entryAction) { $this->set("EntryAction", $entryAction); } - /** * Description: 描述 * @@ -251,11 +242,10 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * TargetType: 应用目标类型。0代表“子网内全部资源”, 1代表“子网内指定资源”。默认为0 * @@ -271,11 +261,10 @@ public function getTargetType() * * @param int $targetType */ - public function setTargetType($targetType) + public function setTargetType(int $targetType) { $this->set("TargetType", $targetType); } - /** * TargetResourceIds: 应用目标资源列表。默认为全部资源生效。TargetType为0时不用填写该值 * diff --git a/src/VPC/Apis/UpdateNetworkAclEntryResponse.php b/src/VPC2.0/Apis/UpdateNetworkAclEntryResponse.php similarity index 93% rename from src/VPC/Apis/UpdateNetworkAclEntryResponse.php rename to src/VPC2.0/Apis/UpdateNetworkAclEntryResponse.php index 1f61f211..289654c2 100644 --- a/src/VPC/Apis/UpdateNetworkAclEntryResponse.php +++ b/src/VPC2.0/Apis/UpdateNetworkAclEntryResponse.php @@ -1,6 +1,7 @@ markRequired("Description"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * AclName: Acl的名称 * @@ -86,11 +85,10 @@ public function getAclName() * * @param string $aclName */ - public function setAclName($aclName) + public function setAclName(string $aclName) { $this->set("AclName", $aclName); } - /** * AclId: 需要更改的ACL ID * @@ -106,11 +104,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * Description: 描述 * @@ -126,7 +123,7 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } diff --git a/src/VPC/Apis/UpdateNetworkAclResponse.php b/src/VPC2.0/Apis/UpdateNetworkAclResponse.php similarity index 93% rename from src/VPC/Apis/UpdateNetworkAclResponse.php rename to src/VPC2.0/Apis/UpdateNetworkAclResponse.php index bb18deef..35457c99 100644 --- a/src/VPC/Apis/UpdateNetworkAclResponse.php +++ b/src/VPC2.0/Apis/UpdateNetworkAclResponse.php @@ -1,6 +1,7 @@ markRequired("RouteTableId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * RouteTableId: 路由表ID * @@ -85,11 +84,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * Name: 名称 * @@ -105,11 +103,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: 备注 * @@ -125,11 +122,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组名称 * @@ -145,7 +141,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/VPC/Apis/UpdateRouteTableAttributeResponse.php b/src/VPC2.0/Apis/UpdateRouteTableAttributeResponse.php similarity index 93% rename from src/VPC/Apis/UpdateRouteTableAttributeResponse.php rename to src/VPC2.0/Apis/UpdateRouteTableAttributeResponse.php index f355d2ff..9d35d0f8 100644 --- a/src/VPC/Apis/UpdateRouteTableAttributeResponse.php +++ b/src/VPC2.0/Apis/UpdateRouteTableAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("SnatIp"); } - /** * Region: 地域。 参见 [地域和可用区列表](https://docs.ucloud.cn/api/summary/regionlist) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](https://docs.ucloud.cn/api/summary/get_project_list) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * NATGWId: NAT网关的ID, * @@ -86,11 +85,10 @@ public function getNATGWId() * * @param string $natgwId */ - public function setNATGWId($natgwId) + public function setNATGWId(string $natgwId) { $this->set("NATGWId", $natgwId); } - /** * SourceIp: 需要出外网的私网IP地址,例如10.9.7.xx * @@ -106,11 +104,10 @@ public function getSourceIp() * * @param string $sourceIp */ - public function setSourceIp($sourceIp) + public function setSourceIp(string $sourceIp) { $this->set("SourceIp", $sourceIp); } - /** * SnatIp: EIP的ip地址,例如106.75.xx.xx * @@ -126,11 +123,10 @@ public function getSnatIp() * * @param string $snatIp */ - public function setSnatIp($snatIp) + public function setSnatIp(string $snatIp) { $this->set("SnatIp", $snatIp); } - /** * Name: snat名称,即出口规则名称 * @@ -146,7 +142,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/VPC/Apis/UpdateSnatRuleResponse.php b/src/VPC2.0/Apis/UpdateSnatRuleResponse.php similarity index 93% rename from src/VPC/Apis/UpdateSnatRuleResponse.php rename to src/VPC2.0/Apis/UpdateSnatRuleResponse.php index 5fc80b72..3be1d56b 100644 --- a/src/VPC/Apis/UpdateSnatRuleResponse.php +++ b/src/VPC2.0/Apis/UpdateSnatRuleResponse.php @@ -1,6 +1,7 @@ markRequired("SubnetId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -44,11 +45,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -64,11 +64,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * SubnetId: 子网ID * @@ -84,11 +83,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * Name: 子网名称(如果Name不填写,Tag必须填写) * @@ -104,11 +102,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 业务组名称(如果Tag不填写,Name必须填写) * @@ -124,7 +121,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/VPC/Apis/UpdateSubnetAttributeResponse.php b/src/VPC2.0/Apis/UpdateSubnetAttributeResponse.php similarity index 93% rename from src/VPC/Apis/UpdateSubnetAttributeResponse.php rename to src/VPC2.0/Apis/UpdateSubnetAttributeResponse.php index 935fbb6f..dbbd3651 100644 --- a/src/VPC/Apis/UpdateSubnetAttributeResponse.php +++ b/src/VPC2.0/Apis/UpdateSubnetAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("VIPId"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -45,11 +46,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -65,11 +65,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VIPId: 内网VIP的资源Id * @@ -85,11 +84,10 @@ public function getVIPId() * * @param string $vipId */ - public function setVIPId($vipId) + public function setVIPId(string $vipId) { $this->set("VIPId", $vipId); } - /** * Remark: 内网VIP的备注 * @@ -105,11 +103,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Name: 内网VIP的名称 * @@ -125,11 +122,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Tag: 内网VIP所属的业务组 * @@ -145,7 +141,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/VPC/Apis/UpdateVIPAttributeResponse.php b/src/VPC2.0/Apis/UpdateVIPAttributeResponse.php similarity index 93% rename from src/VPC/Apis/UpdateVIPAttributeResponse.php rename to src/VPC2.0/Apis/UpdateVIPAttributeResponse.php index 09025b89..27a74e33 100644 --- a/src/VPC/Apis/UpdateVIPAttributeResponse.php +++ b/src/VPC2.0/Apis/UpdateVIPAttributeResponse.php @@ -1,6 +1,7 @@ markRequired("Network"); } - /** * Region: 地域。 参见 [地域和可用区列表](../summary/regionlist.html) @@ -46,11 +47,10 @@ public function getRegion() * * @param string $region */ - public function setRegion($region) + public function setRegion(string $region) { $this->set("Region", $region); } - /** * ProjectId: 项目ID。不填写为默认项目,子帐号必须填写。 请参考[GetProjectList接口](../summary/get_project_list.html) * @@ -66,11 +66,10 @@ public function getProjectId() * * @param string $projectId */ - public function setProjectId($projectId) + public function setProjectId(string $projectId) { $this->set("ProjectId", $projectId); } - /** * VPCId: VPC的ID * @@ -86,11 +85,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Network: 需要保留的VPC网段。当前仅支持删除VPC网段,添加网段请参考[AddVPCNetwork](https://docs.ucloud.cn/api/vpc2.0-api/add_vpc_network) * diff --git a/src/VPC/Apis/UpdateVPCNetworkResponse.php b/src/VPC2.0/Apis/UpdateVPCNetworkResponse.php similarity index 93% rename from src/VPC/Apis/UpdateVPCNetworkResponse.php rename to src/VPC2.0/Apis/UpdateVPCNetworkResponse.php index 9be36898..fb630957 100644 --- a/src/VPC/Apis/UpdateVPCNetworkResponse.php +++ b/src/VPC2.0/Apis/UpdateVPCNetworkResponse.php @@ -1,6 +1,7 @@ set("EntryId", $entryId); } - /** * Priority: 优先级 * @@ -57,11 +62,10 @@ public function getPriority() * * @param string $priority */ - public function setPriority($priority) + public function setPriority(string $priority) { $this->set("Priority", $priority); } - /** * Direction: 出向或者入向 * @@ -77,11 +81,10 @@ public function getDirection() * * @param string $direction */ - public function setDirection($direction) + public function setDirection(string $direction) { $this->set("Direction", $direction); } - /** * IpProtocol: 针对的IP协议 * @@ -97,11 +100,10 @@ public function getIpProtocol() * * @param string $ipProtocol */ - public function setIpProtocol($ipProtocol) + public function setIpProtocol(string $ipProtocol) { $this->set("IpProtocol", $ipProtocol); } - /** * CidrBlock: IP段的CIDR信息 * @@ -117,11 +119,10 @@ public function getCidrBlock() * * @param string $cidrBlock */ - public function setCidrBlock($cidrBlock) + public function setCidrBlock(string $cidrBlock) { $this->set("CidrBlock", $cidrBlock); } - /** * PortRange: Port的段信息 * @@ -137,11 +138,10 @@ public function getPortRange() * * @param string $portRange */ - public function setPortRange($portRange) + public function setPortRange(string $portRange) { $this->set("PortRange", $portRange); } - /** * EntryAction: 匹配规则的动作 * @@ -157,11 +157,10 @@ public function getEntryAction() * * @param string $entryAction */ - public function setEntryAction($entryAction) + public function setEntryAction(string $entryAction) { $this->set("EntryAction", $entryAction); } - /** * TargetType: 应用目标类型。 0代表“子网内全部资源” ,1代表“子网内指定资源” 。 * @@ -177,11 +176,10 @@ public function getTargetType() * * @param int $targetType */ - public function setTargetType($targetType) + public function setTargetType(int $targetType) { $this->set("TargetType", $targetType); } - /** * CreateTime: 创建的Unix时间戳 * @@ -197,11 +195,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * UpdateTime: 更改的Unix时间戳 * @@ -217,15 +214,14 @@ public function getUpdateTime() * * @param int $updateTime */ - public function setUpdateTime($updateTime) + public function setUpdateTime(int $updateTime) { $this->set("UpdateTime", $updateTime); } - /** * TargetResourceList: 应用目标资源信息。TargetType为0时不返回该值。具体结构见下方TargetResourceInfo * - * @return TargetResourceInfo[]|null + * @return TargetResourceInfoModel[]|null */ public function getTargetResourceList() { @@ -235,7 +231,7 @@ public function getTargetResourceList() } $result = []; foreach ($items as $i => $item) { - array_push($result, new TargetResourceInfo($item)); + array_push($result, new TargetResourceInfoModel($item)); } return $result; } @@ -243,7 +239,7 @@ public function getTargetResourceList() /** * TargetResourceList: 应用目标资源信息。TargetType为0时不返回该值。具体结构见下方TargetResourceInfo * - * @param TargetResourceInfo[] $targetResourceList + * @param TargetResourceInfoModel[] $targetResourceList */ public function setTargetResourceList(array $targetResourceList) { @@ -253,7 +249,6 @@ public function setTargetResourceList(array $targetResourceList) } return $result; } - /** * TargetResourceCount: 应用目标资源数量。TargetType为0时不返回该值。 * @@ -269,7 +264,7 @@ public function getTargetResourceCount() * * @param int $targetResourceCount */ - public function setTargetResourceCount($targetResourceCount) + public function setTargetResourceCount(int $targetResourceCount) { $this->set("TargetResourceCount", $targetResourceCount); } diff --git a/src/VPC/Models/AclInfo.php b/src/VPC2.0/Models/AclInfo.php similarity index 82% rename from src/VPC/Models/AclInfo.php rename to src/VPC2.0/Models/AclInfo.php index 6841a925..09c7d42b 100644 --- a/src/VPC/Models/AclInfo.php +++ b/src/VPC2.0/Models/AclInfo.php @@ -1,6 +1,7 @@ set("VpcId", $vpcId); } - /** * AclId: ACL的ID * @@ -57,11 +62,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * AclName: 名称 * @@ -77,11 +81,10 @@ public function getAclName() * * @param string $aclName */ - public function setAclName($aclName) + public function setAclName(string $aclName) { $this->set("AclName", $aclName); } - /** * Description: 描述 * @@ -97,15 +100,14 @@ public function getDescription() * * @param string $description */ - public function setDescription($description) + public function setDescription(string $description) { $this->set("Description", $description); } - /** * Entries: 所有的规则 * - * @return AclEntryInfo[]|null + * @return AclEntryInfoModel[]|null */ public function getEntries() { @@ -115,7 +117,7 @@ public function getEntries() } $result = []; foreach ($items as $i => $item) { - array_push($result, new AclEntryInfo($item)); + array_push($result, new AclEntryInfoModel($item)); } return $result; } @@ -123,7 +125,7 @@ public function getEntries() /** * Entries: 所有的规则 * - * @param AclEntryInfo[] $entries + * @param AclEntryInfoModel[] $entries */ public function setEntries(array $entries) { @@ -133,11 +135,10 @@ public function setEntries(array $entries) } return $result; } - /** * Associations: 所有的绑定关系,具体结构见下方AssociationInfo * - * @return AssociationInfo[]|null + * @return AssociationInfoModel[]|null */ public function getAssociations() { @@ -147,7 +148,7 @@ public function getAssociations() } $result = []; foreach ($items as $i => $item) { - array_push($result, new AssociationInfo($item)); + array_push($result, new AssociationInfoModel($item)); } return $result; } @@ -155,7 +156,7 @@ public function getAssociations() /** * Associations: 所有的绑定关系,具体结构见下方AssociationInfo * - * @param AssociationInfo[] $associations + * @param AssociationInfoModel[] $associations */ public function setAssociations(array $associations) { @@ -165,7 +166,6 @@ public function setAssociations(array $associations) } return $result; } - /** * CreateTime: 创建的Unix时间戳 * @@ -181,11 +181,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * UpdateTime: 更改的Unix时间戳 * @@ -201,7 +200,7 @@ public function getUpdateTime() * * @param int $updateTime */ - public function setUpdateTime($updateTime) + public function setUpdateTime(int $updateTime) { $this->set("UpdateTime", $updateTime); } diff --git a/src/VPC/Models/AssociationInfo.php b/src/VPC2.0/Models/AssociationInfo.php similarity index 78% rename from src/VPC/Models/AssociationInfo.php rename to src/VPC2.0/Models/AssociationInfo.php index 926e8131..244811b7 100644 --- a/src/VPC/Models/AssociationInfo.php +++ b/src/VPC2.0/Models/AssociationInfo.php @@ -1,6 +1,7 @@ set("AssociationId", $associationId); } - /** * AclId: ACL的ID * @@ -57,11 +63,10 @@ public function getAclId() * * @param string $aclId */ - public function setAclId($aclId) + public function setAclId(string $aclId) { $this->set("AclId", $aclId); } - /** * SubnetworkId: 绑定的子网ID * @@ -77,11 +82,10 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } - /** * CreateTime: 创建的Unix时间戳 * @@ -97,7 +101,7 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } diff --git a/src/VPC/Models/DescribeWhiteListResourceObjectIPInfo.php b/src/VPC2.0/Models/DescribeWhiteListResourceObjectIPInfo.php similarity index 83% rename from src/VPC/Models/DescribeWhiteListResourceObjectIPInfo.php rename to src/VPC2.0/Models/DescribeWhiteListResourceObjectIPInfo.php index 63f4dba1..1690d90e 100644 --- a/src/VPC/Models/DescribeWhiteListResourceObjectIPInfo.php +++ b/src/VPC2.0/Models/DescribeWhiteListResourceObjectIPInfo.php @@ -1,6 +1,7 @@ set("GwType", $gwType); } - /** * PrivateIP: 白名单资源的内网IP * @@ -57,11 +62,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * ResourceId: 白名单资源Id信息 * @@ -77,11 +81,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceName: 白名单资源名称 * @@ -97,11 +100,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * ResourceType: 白名单资源类型 * @@ -117,11 +119,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * SubResourceId: 资源绑定的虚拟网卡的实例ID * @@ -137,11 +138,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * SubResourceName: 资源绑定的虚拟网卡的实例名称 * @@ -157,11 +157,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * SubResourceType: 资源绑定的虚拟网卡的类型 * @@ -177,11 +176,10 @@ public function getSubResourceType() * * @param string $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(string $subResourceType) { $this->set("SubResourceType", $subResourceType); } - /** * VPCId: 白名单资源所属VPCId * @@ -197,7 +195,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Models/GetAvailableResourceForPolicyDataSet.php b/src/VPC2.0/Models/GetAvailableResourceForPolicyDataSet.php similarity index 87% rename from src/VPC/Models/GetAvailableResourceForPolicyDataSet.php rename to src/VPC2.0/Models/GetAvailableResourceForPolicyDataSet.php index af3ce80f..43dbd176 100644 --- a/src/VPC/Models/GetAvailableResourceForPolicyDataSet.php +++ b/src/VPC2.0/Models/GetAvailableResourceForPolicyDataSet.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * PrivateIP: 资源对应的内网Ip * @@ -57,11 +59,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * ResourceType: 资源类型。"uhost":云主机; "upm",物理云主机; "hadoophost":hadoop节点; "fortresshost":堡垒机: "udockhost",容器 * @@ -77,7 +78,7 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } diff --git a/src/VPC/Models/GetAvailableResourceForSnatRuleDataSet.php b/src/VPC2.0/Models/GetAvailableResourceForSnatRuleDataSet.php similarity index 85% rename from src/VPC/Models/GetAvailableResourceForSnatRuleDataSet.php rename to src/VPC2.0/Models/GetAvailableResourceForSnatRuleDataSet.php index 8d8c1872..a9fe85f0 100644 --- a/src/VPC/Models/GetAvailableResourceForSnatRuleDataSet.php +++ b/src/VPC2.0/Models/GetAvailableResourceForSnatRuleDataSet.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * ResourceName: 资源名称 * @@ -57,11 +59,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * PrivateIP: 资源内网IP * @@ -77,11 +78,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * ResourceType: 资源类型 * @@ -97,11 +97,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * SubnetworkId: 资源所属VPC的ID * @@ -117,11 +116,10 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } - /** * VPCId: 资源所属子网的ID * @@ -137,7 +135,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Models/GetAvailableResourceForWhiteListDataSet.php b/src/VPC2.0/Models/GetAvailableResourceForWhiteListDataSet.php similarity index 85% rename from src/VPC/Models/GetAvailableResourceForWhiteListDataSet.php rename to src/VPC2.0/Models/GetAvailableResourceForWhiteListDataSet.php index 86b1e713..38a35c24 100644 --- a/src/VPC/Models/GetAvailableResourceForWhiteListDataSet.php +++ b/src/VPC2.0/Models/GetAvailableResourceForWhiteListDataSet.php @@ -1,6 +1,7 @@ set("ResourceId", $resourceId); } - /** * ResourceName: 资源名称 * @@ -57,11 +60,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * PrivateIP: 资源的内网Ip * @@ -77,11 +79,10 @@ public function getPrivateIP() * * @param string $privateIP */ - public function setPrivateIP($privateIP) + public function setPrivateIP(string $privateIP) { $this->set("PrivateIP", $privateIP); } - /** * ResourceType: 资源类型。"uhost":云主机; "upm",物理云主机; "hadoophost":hadoop节点; "fortresshost":堡垒机: "udockhost",容器 * @@ -97,11 +98,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * SubResourceName: 资源绑定的虚拟网卡的实例名称 * @@ -117,11 +117,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * VPCId: 资源所属VPCId * @@ -137,11 +136,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetworkId: 资源所属子网Id * @@ -157,11 +155,10 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } - /** * SubResourceId: 资源绑定的虚拟网卡的实例ID * @@ -177,11 +174,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * SubResourceType: 资源绑定的虚拟网卡的实例类型 * @@ -197,7 +193,7 @@ public function getSubResourceType() * * @param string $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(string $subResourceType) { $this->set("SubResourceType", $subResourceType); } diff --git a/src/VPC/Models/IpInfo.php b/src/VPC2.0/Models/IpInfo.php similarity index 84% rename from src/VPC/Models/IpInfo.php rename to src/VPC2.0/Models/IpInfo.php index f8380674..e71da8a1 100644 --- a/src/VPC/Models/IpInfo.php +++ b/src/VPC2.0/Models/IpInfo.php @@ -1,6 +1,7 @@ set("Ip", $ip); } - /** * Mask: * @@ -57,11 +60,10 @@ public function getMask() * * @param string $mask */ - public function setMask($mask) + public function setMask(string $mask) { $this->set("Mask", $mask); } - /** * Gateway: * @@ -77,11 +79,10 @@ public function getGateway() * * @param string $gateway */ - public function setGateway($gateway) + public function setGateway(string $gateway) { $this->set("Gateway", $gateway); } - /** * Mac: * @@ -97,11 +98,10 @@ public function getMac() * * @param string $mac */ - public function setMac($mac) + public function setMac(string $mac) { $this->set("Mac", $mac); } - /** * SubnetId: * @@ -117,11 +117,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: * @@ -137,7 +136,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Models/NATGWPolicyDataSet.php b/src/VPC2.0/Models/NATGWPolicyDataSet.php similarity index 86% rename from src/VPC/Models/NATGWPolicyDataSet.php rename to src/VPC2.0/Models/NATGWPolicyDataSet.php index 29b71aed..a9215f76 100644 --- a/src/VPC/Models/NATGWPolicyDataSet.php +++ b/src/VPC2.0/Models/NATGWPolicyDataSet.php @@ -1,6 +1,7 @@ set("NATGWId", $natgwId); } - /** * PolicyId: 转发策略Id * @@ -57,11 +59,10 @@ public function getPolicyId() * * @param string $policyId */ - public function setPolicyId($policyId) + public function setPolicyId(string $policyId) { $this->set("PolicyId", $policyId); } - /** * Protocol: 协议类型 * @@ -77,11 +78,10 @@ public function getProtocol() * * @param string $protocol */ - public function setProtocol($protocol) + public function setProtocol(string $protocol) { $this->set("Protocol", $protocol); } - /** * SrcEIP: 端口转发前端EIP * @@ -97,11 +97,10 @@ public function getSrcEIP() * * @param string $srcEIP */ - public function setSrcEIP($srcEIP) + public function setSrcEIP(string $srcEIP) { $this->set("SrcEIP", $srcEIP); } - /** * SrcEIPId: 端口转发前端EIP Id * @@ -117,11 +116,10 @@ public function getSrcEIPId() * * @param string $srcEIPId */ - public function setSrcEIPId($srcEIPId) + public function setSrcEIPId(string $srcEIPId) { $this->set("SrcEIPId", $srcEIPId); } - /** * SrcPort: 源端口 * @@ -137,11 +135,10 @@ public function getSrcPort() * * @param string $srcPort */ - public function setSrcPort($srcPort) + public function setSrcPort(string $srcPort) { $this->set("SrcPort", $srcPort); } - /** * DstIP: 目的地址 * @@ -157,11 +154,10 @@ public function getDstIP() * * @param string $dstIP */ - public function setDstIP($dstIP) + public function setDstIP(string $dstIP) { $this->set("DstIP", $dstIP); } - /** * DstPort: 目的端口 * @@ -177,11 +173,10 @@ public function getDstPort() * * @param string $dstPort */ - public function setDstPort($dstPort) + public function setDstPort(string $dstPort) { $this->set("DstPort", $dstPort); } - /** * PolicyName: 转发策略名称 * @@ -197,7 +192,7 @@ public function getPolicyName() * * @param string $policyName */ - public function setPolicyName($policyName) + public function setPolicyName(string $policyName) { $this->set("PolicyName", $policyName); } diff --git a/src/VPC/Models/NATGWSnatRule.php b/src/VPC2.0/Models/NATGWSnatRule.php similarity index 87% rename from src/VPC/Models/NATGWSnatRule.php rename to src/VPC2.0/Models/NATGWSnatRule.php index 97bfaed7..d376a64b 100644 --- a/src/VPC/Models/NATGWSnatRule.php +++ b/src/VPC2.0/Models/NATGWSnatRule.php @@ -1,6 +1,7 @@ set("SnatIp", $snatIp); } - /** * SourceIp: 资源的内网IP地址 * @@ -57,11 +59,10 @@ public function getSourceIp() * * @param string $sourceIp */ - public function setSourceIp($sourceIp) + public function setSourceIp(string $sourceIp) { $this->set("SourceIp", $sourceIp); } - /** * SubnetworkId: SourceIp所属的子网id * @@ -77,11 +78,10 @@ public function getSubnetworkId() * * @param string $subnetworkId */ - public function setSubnetworkId($subnetworkId) + public function setSubnetworkId(string $subnetworkId) { $this->set("SubnetworkId", $subnetworkId); } - /** * Name: snat规则名称 * @@ -97,7 +97,7 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } diff --git a/src/VPC/Models/NatGWIPResInfo.php b/src/VPC2.0/Models/NatGWIPResInfo.php similarity index 82% rename from src/VPC/Models/NatGWIPResInfo.php rename to src/VPC2.0/Models/NatGWIPResInfo.php index ea030383..ec6304c7 100644 --- a/src/VPC/Models/NatGWIPResInfo.php +++ b/src/VPC2.0/Models/NatGWIPResInfo.php @@ -1,6 +1,7 @@ set("OperatorName", $operatorName); } - /** * EIP: 外网IP * @@ -57,7 +61,7 @@ public function getEIP() * * @param string $eip */ - public function setEIP($eip) + public function setEIP(string $eip) { $this->set("EIP", $eip); } diff --git a/src/VPC/Models/NatGWWhitelistDataSet.php b/src/VPC2.0/Models/NatGWWhitelistDataSet.php similarity index 78% rename from src/VPC/Models/NatGWWhitelistDataSet.php rename to src/VPC2.0/Models/NatGWWhitelistDataSet.php index a71d10a1..d21ba857 100644 --- a/src/VPC/Models/NatGWWhitelistDataSet.php +++ b/src/VPC2.0/Models/NatGWWhitelistDataSet.php @@ -1,6 +1,7 @@ set("NATGWId", $natgwId); } - /** * IfOpen: 白名单开关标记 * @@ -57,15 +62,14 @@ public function getIfOpen() * * @param int $ifOpen */ - public function setIfOpen($ifOpen) + public function setIfOpen(int $ifOpen) { $this->set("IfOpen", $ifOpen); } - /** * ObjectIPInfo: 白名单详情 * - * @return DescribeWhiteListResourceObjectIPInfo[]|null + * @return DescribeWhiteListResourceObjectIPInfoModel[]|null */ public function getObjectIPInfo() { @@ -75,7 +79,7 @@ public function getObjectIPInfo() } $result = []; foreach ($items as $i => $item) { - array_push($result, new DescribeWhiteListResourceObjectIPInfo($item)); + array_push($result, new DescribeWhiteListResourceObjectIPInfoModel($item)); } return $result; } @@ -83,7 +87,7 @@ public function getObjectIPInfo() /** * ObjectIPInfo: 白名单详情 * - * @param DescribeWhiteListResourceObjectIPInfo[] $objectIPInfo + * @param DescribeWhiteListResourceObjectIPInfoModel[] $objectIPInfo */ public function setObjectIPInfo(array $objectIPInfo) { diff --git a/src/VPC/Models/NatGatewayDataSet.php b/src/VPC2.0/Models/NatGatewayDataSet.php similarity index 69% rename from src/VPC/Models/NatGatewayDataSet.php rename to src/VPC2.0/Models/NatGatewayDataSet.php index b0d5a51c..b76a9a75 100644 --- a/src/VPC/Models/NatGatewayDataSet.php +++ b/src/VPC2.0/Models/NatGatewayDataSet.php @@ -1,6 +1,7 @@ set("NATGWId", $natgwId); } - /** * NATGWName: natgw名称 * @@ -57,31 +62,10 @@ public function getNATGWName() * * @param string $natgwName */ - public function setNATGWName($natgwName) + public function setNATGWName(string $natgwName) { $this->set("NATGWName", $natgwName); } - - /** - * CreateTime: natgw创建时间 - * - * @return integer|null - */ - public function getCreateTime() - { - return $this->get("CreateTime"); - } - - /** - * CreateTime: natgw创建时间 - * - * @param int $createTime - */ - public function setCreateTime($createTime) - { - $this->set("CreateTime", $createTime); - } - /** * Tag: 业务组 * @@ -97,11 +81,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 备注 * @@ -117,11 +100,29 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } + /** + * CreateTime: natgw创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + /** + * CreateTime: natgw创建时间 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } /** * FirewallId: 绑定的防火墙Id * @@ -137,11 +138,10 @@ public function getFirewallId() * * @param string $firewallId */ - public function setFirewallId($firewallId) + public function setFirewallId(string $firewallId) { $this->set("FirewallId", $firewallId); } - /** * VPCId: 所属VPC Id * @@ -157,15 +157,14 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * SubnetSet: 子网 Id * - * @return NatGatewaySubnetSet[]|null + * @return NatGatewaySubnetSetModel[]|null */ public function getSubnetSet() { @@ -175,7 +174,7 @@ public function getSubnetSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NatGatewaySubnetSet($item)); + array_push($result, new NatGatewaySubnetSetModel($item)); } return $result; } @@ -183,7 +182,7 @@ public function getSubnetSet() /** * SubnetSet: 子网 Id * - * @param NatGatewaySubnetSet[] $subnetSet + * @param NatGatewaySubnetSetModel[] $subnetSet */ public function setSubnetSet(array $subnetSet) { @@ -193,11 +192,10 @@ public function setSubnetSet(array $subnetSet) } return $result; } - /** * IPSet: 绑定的EIP 信息 * - * @return NatGatewayIPSet[]|null + * @return NatGatewayIPSetModel[]|null */ public function getIPSet() { @@ -207,7 +205,7 @@ public function getIPSet() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NatGatewayIPSet($item)); + array_push($result, new NatGatewayIPSetModel($item)); } return $result; } @@ -215,7 +213,7 @@ public function getIPSet() /** * IPSet: 绑定的EIP 信息 * - * @param NatGatewayIPSet[] $ipSet + * @param NatGatewayIPSetModel[] $ipSet */ public function setIPSet(array $ipSet) { @@ -225,7 +223,44 @@ public function setIPSet(array $ipSet) } return $result; } + /** + * VPCName: VPC名称 + * + * @return string|null + */ + public function getVPCName() + { + return $this->get("VPCName"); + } + /** + * VPCName: VPC名称 + * + * @param string $vpcName + */ + public function setVPCName(string $vpcName) + { + $this->set("VPCName", $vpcName); + } + /** + * IsSnatpoolEnabled: 枚举值,“enable”,默认出口规则使用了负载均衡;“disable”,默认出口规则未使用负载均衡。 + * + * @return string|null + */ + public function getIsSnatpoolEnabled() + { + return $this->get("IsSnatpoolEnabled"); + } + + /** + * IsSnatpoolEnabled: 枚举值,“enable”,默认出口规则使用了负载均衡;“disable”,默认出口规则未使用负载均衡。 + * + * @param string $isSnatpoolEnabled + */ + public function setIsSnatpoolEnabled(string $isSnatpoolEnabled) + { + $this->set("IsSnatpoolEnabled", $isSnatpoolEnabled); + } /** * PolicyId: 转发策略Id * diff --git a/src/VPC/Models/NatGatewayIPSet.php b/src/VPC2.0/Models/NatGatewayIPSet.php similarity index 82% rename from src/VPC/Models/NatGatewayIPSet.php rename to src/VPC2.0/Models/NatGatewayIPSet.php index 57ce4c2c..036126d3 100644 --- a/src/VPC/Models/NatGatewayIPSet.php +++ b/src/VPC2.0/Models/NatGatewayIPSet.php @@ -1,6 +1,7 @@ set("EIPId", $eipId); } - /** * Weight: 权重为100的为出口 * @@ -57,11 +61,10 @@ public function getWeight() * * @param int $weight */ - public function setWeight($weight) + public function setWeight(int $weight) { $this->set("Weight", $weight); } - /** * BandwidthType: EIP带宽类型 * @@ -77,11 +80,10 @@ public function getBandwidthType() * * @param string $bandwidthType */ - public function setBandwidthType($bandwidthType) + public function setBandwidthType(string $bandwidthType) { $this->set("BandwidthType", $bandwidthType); } - /** * Bandwidth: 带宽 * @@ -97,15 +99,14 @@ public function getBandwidth() * * @param int $bandwidth */ - public function setBandwidth($bandwidth) + public function setBandwidth(int $bandwidth) { $this->set("Bandwidth", $bandwidth); } - /** * IPResInfo: 外网IP信息 * - * @return NatGWIPResInfo[]|null + * @return NatGWIPResInfoModel[]|null */ public function getIPResInfo() { @@ -115,7 +116,7 @@ public function getIPResInfo() } $result = []; foreach ($items as $i => $item) { - array_push($result, new NatGWIPResInfo($item)); + array_push($result, new NatGWIPResInfoModel($item)); } return $result; } @@ -123,7 +124,7 @@ public function getIPResInfo() /** * IPResInfo: 外网IP信息 * - * @param NatGWIPResInfo[] $ipResInfo + * @param NatGWIPResInfoModel[] $ipResInfo */ public function setIPResInfo(array $ipResInfo) { diff --git a/src/VPC/Models/NatGatewaySubnetSet.php b/src/VPC2.0/Models/NatGatewaySubnetSet.php similarity index 84% rename from src/VPC/Models/NatGatewaySubnetSet.php rename to src/VPC2.0/Models/NatGatewaySubnetSet.php index e198f853..727eca23 100644 --- a/src/VPC/Models/NatGatewaySubnetSet.php +++ b/src/VPC2.0/Models/NatGatewaySubnetSet.php @@ -1,6 +1,7 @@ set("SubnetworkId", $subnetworkId); } - /** * Subnet: 子网网段 * @@ -57,11 +60,10 @@ public function getSubnet() * * @param string $subnet */ - public function setSubnet($subnet) + public function setSubnet(string $subnet) { $this->set("Subnet", $subnet); } - /** * SubnetName: 子网名字 * @@ -77,7 +79,7 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } diff --git a/src/VPC/Models/NatgwSubnetDataSet.php b/src/VPC2.0/Models/NatgwSubnetDataSet.php similarity index 86% rename from src/VPC/Models/NatgwSubnetDataSet.php rename to src/VPC2.0/Models/NatgwSubnetDataSet.php index e797c826..29197d6e 100644 --- a/src/VPC/Models/NatgwSubnetDataSet.php +++ b/src/VPC2.0/Models/NatgwSubnetDataSet.php @@ -1,6 +1,7 @@ set("SubnetId", $subnetId); } - /** * Subnet: 子网网段 * @@ -57,11 +59,10 @@ public function getSubnet() * * @param string $subnet */ - public function setSubnet($subnet) + public function setSubnet(string $subnet) { $this->set("Subnet", $subnet); } - /** * Netmask: 掩码 * @@ -77,11 +78,10 @@ public function getNetmask() * * @param string $netmask */ - public function setNetmask($netmask) + public function setNetmask(string $netmask) { $this->set("Netmask", $netmask); } - /** * SubnetName: 子网名字 * @@ -97,11 +97,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * HasNATGW: 是否绑定NATGW * @@ -117,7 +116,7 @@ public function getHasNATGW() * * @param boolean $hasNATGW */ - public function setHasNATGW($hasNATGW) + public function setHasNATGW(bool $hasNATGW) { $this->set("HasNATGW", $hasNATGW); } diff --git a/src/VPC2.0/Models/NetworkInterface.php b/src/VPC2.0/Models/NetworkInterface.php new file mode 100644 index 00000000..31fba24b --- /dev/null +++ b/src/VPC2.0/Models/NetworkInterface.php @@ -0,0 +1,372 @@ +get("InterfaceId"); + } + + /** + * InterfaceId: 虚拟网卡资源ID + * + * @param string $interfaceId + */ + public function setInterfaceId(string $interfaceId) + { + $this->set("InterfaceId", $interfaceId); + } + /** + * VPCId: 所属VPC + * + * @return string|null + */ + public function getVPCId() + { + return $this->get("VPCId"); + } + + /** + * VPCId: 所属VPC + * + * @param string $vpcId + */ + public function setVPCId(string $vpcId) + { + $this->set("VPCId", $vpcId); + } + /** + * SubnetId: 所属子网 + * + * @return string|null + */ + public function getSubnetId() + { + return $this->get("SubnetId"); + } + + /** + * SubnetId: 所属子网 + * + * @param string $subnetId + */ + public function setSubnetId(string $subnetId) + { + $this->set("SubnetId", $subnetId); + } + /** + * PrivateIpSet: 关联内网IP。当前一个网卡仅支持绑定一个内网IP + * + * @return string[]|null + */ + public function getPrivateIpSet() + { + return $this->get("PrivateIpSet"); + } + + /** + * PrivateIpSet: 关联内网IP。当前一个网卡仅支持绑定一个内网IP + * + * @param string[] $privateIpSet + */ + public function setPrivateIpSet(array $privateIpSet) + { + $this->set("PrivateIpSet", $privateIpSet); + } + /** + * MacAddress: 关联Mac + * + * @return string|null + */ + public function getMacAddress() + { + return $this->get("MacAddress"); + } + + /** + * MacAddress: 关联Mac + * + * @param string $macAddress + */ + public function setMacAddress(string $macAddress) + { + $this->set("MacAddress", $macAddress); + } + /** + * Status: 绑定状态 + * + * @return integer|null + */ + public function getStatus() + { + return $this->get("Status"); + } + + /** + * Status: 绑定状态 + * + * @param int $status + */ + public function setStatus(int $status) + { + $this->set("Status", $status); + } + /** + * PrivateIp: 网卡的内网IP信息 + * + * @return string[]|null + */ + public function getPrivateIp() + { + return $this->get("PrivateIp"); + } + + /** + * PrivateIp: 网卡的内网IP信息 + * + * @param string[] $privateIp + */ + public function setPrivateIp(array $privateIp) + { + $this->set("PrivateIp", $privateIp); + } + /** + * Name: 虚拟网卡名称 + * + * @return string|null + */ + public function getName() + { + return $this->get("Name"); + } + + /** + * Name: 虚拟网卡名称 + * + * @param string $name + */ + public function setName(string $name) + { + $this->set("Name", $name); + } + /** + * Netmask: 内网IP掩码 + * + * @return string|null + */ + public function getNetmask() + { + return $this->get("Netmask"); + } + + /** + * Netmask: 内网IP掩码 + * + * @param string $netmask + */ + public function setNetmask(string $netmask) + { + $this->set("Netmask", $netmask); + } + /** + * Gateway: 默认网关 + * + * @return string|null + */ + public function getGateway() + { + return $this->get("Gateway"); + } + + /** + * Gateway: 默认网关 + * + * @param string $gateway + */ + public function setGateway(string $gateway) + { + $this->set("Gateway", $gateway); + } + /** + * AttachInstanceId: 绑定实例资源ID + * + * @return string|null + */ + public function getAttachInstanceId() + { + return $this->get("AttachInstanceId"); + } + + /** + * AttachInstanceId: 绑定实例资源ID + * + * @param string $attachInstanceId + */ + public function setAttachInstanceId(string $attachInstanceId) + { + $this->set("AttachInstanceId", $attachInstanceId); + } + /** + * Default: 是否是绑定实例的默认网卡 false:不是 true:是 + * + * @return boolean|null + */ + public function getDefault() + { + return $this->get("Default"); + } + + /** + * Default: 是否是绑定实例的默认网卡 false:不是 true:是 + * + * @param boolean $default + */ + public function setDefault(bool $default) + { + $this->set("Default", $default); + } + /** + * CreateTime: 创建时间 + * + * @return integer|null + */ + public function getCreateTime() + { + return $this->get("CreateTime"); + } + + /** + * CreateTime: 创建时间 + * + * @param int $createTime + */ + public function setCreateTime(int $createTime) + { + $this->set("CreateTime", $createTime); + } + /** + * Remark: 备注 + * + * @return string|null + */ + public function getRemark() + { + return $this->get("Remark"); + } + + /** + * Remark: 备注 + * + * @param string $remark + */ + public function setRemark(string $remark) + { + $this->set("Remark", $remark); + } + /** + * Tag: 业务组 + * + * @return string|null + */ + public function getTag() + { + return $this->get("Tag"); + } + + /** + * Tag: 业务组 + * + * @param string $tag + */ + public function setTag(string $tag) + { + $this->set("Tag", $tag); + } + /** + * EIPIdSet: 虚拟网卡绑定的EIP ID信息 + * + * @return string[]|null + */ + public function getEIPIdSet() + { + return $this->get("EIPIdSet"); + } + + /** + * EIPIdSet: 虚拟网卡绑定的EIP ID信息 + * + * @param string[] $eipIdSet + */ + public function setEIPIdSet(array $eipIdSet) + { + $this->set("EIPIdSet", $eipIdSet); + } + /** + * FirewallIdSet: 虚拟网卡绑定的防火墙ID信息 + * + * @return string[]|null + */ + public function getFirewallIdSet() + { + return $this->get("FirewallIdSet"); + } + + /** + * FirewallIdSet: 虚拟网卡绑定的防火墙ID信息 + * + * @param string[] $firewallIdSet + */ + public function setFirewallIdSet(array $firewallIdSet) + { + $this->set("FirewallIdSet", $firewallIdSet); + } + /** + * PrivateIplimit: 网卡的内网IP配额信息 + * + * @return string[]|null + */ + public function getPrivateIplimit() + { + return $this->get("PrivateIplimit"); + } + + /** + * PrivateIplimit: 网卡的内网IP配额信息 + * + * @param string[] $privateIplimit + */ + public function setPrivateIplimit(array $privateIplimit) + { + $this->set("PrivateIplimit", $privateIplimit); + } +} diff --git a/src/VPC/Models/RouteRuleInfo.php b/src/VPC2.0/Models/RouteRuleInfo.php similarity index 87% rename from src/VPC/Models/RouteRuleInfo.php rename to src/VPC2.0/Models/RouteRuleInfo.php index 523b61fa..b17a4568 100644 --- a/src/VPC/Models/RouteRuleInfo.php +++ b/src/VPC2.0/Models/RouteRuleInfo.php @@ -1,6 +1,7 @@ set("AccountId", $accountId); } - /** * DstAddr: 目的地址 * @@ -57,11 +60,10 @@ public function getDstAddr() * * @param string $dstAddr */ - public function setDstAddr($dstAddr) + public function setDstAddr(string $dstAddr) { $this->set("DstAddr", $dstAddr); } - /** * DstPort: 保留字段,暂未使用 * @@ -77,11 +79,10 @@ public function getDstPort() * * @param int $dstPort */ - public function setDstPort($dstPort) + public function setDstPort(int $dstPort) { $this->set("DstPort", $dstPort); } - /** * NexthopId: 路由下一跳资源ID * @@ -97,11 +98,10 @@ public function getNexthopId() * * @param string $nexthopId */ - public function setNexthopId($nexthopId) + public function setNexthopId(string $nexthopId) { $this->set("NexthopId", $nexthopId); } - /** * NexthopType: 路由表下一跳类型。LOCAL,本VPC内部通信路由;PUBLIC,公共服务路由;CNAT,外网路由;UDPN,跨域高速通道路由;HYBRIDGW,混合云路由;INSTANCE,实例路由;VNET,VPC联通路由;IPSEC VPN,指向VPN网关的路由。 * @@ -117,11 +117,10 @@ public function getNexthopType() * * @param string $nexthopType */ - public function setNexthopType($nexthopType) + public function setNexthopType(string $nexthopType) { $this->set("NexthopType", $nexthopType); } - /** * OriginAddr: 保留字段,暂未使用 * @@ -137,11 +136,10 @@ public function getOriginAddr() * * @param string $originAddr */ - public function setOriginAddr($originAddr) + public function setOriginAddr(string $originAddr) { $this->set("OriginAddr", $originAddr); } - /** * Priority: 保留字段,暂未使用 * @@ -157,11 +155,10 @@ public function getPriority() * * @param int $priority */ - public function setPriority($priority) + public function setPriority(int $priority) { $this->set("Priority", $priority); } - /** * Remark: 路由规则备注 * @@ -177,11 +174,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * RouteRuleId: 规则ID * @@ -197,11 +193,10 @@ public function getRouteRuleId() * * @param string $routeRuleId */ - public function setRouteRuleId($routeRuleId) + public function setRouteRuleId(string $routeRuleId) { $this->set("RouteRuleId", $routeRuleId); } - /** * RouteTableId: 路由表资源ID * @@ -217,11 +212,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * RuleType: 路由规则类型。0,系统路由规则;1,自定义路由规则 * @@ -237,11 +231,10 @@ public function getRuleType() * * @param int $ruleType */ - public function setRuleType($ruleType) + public function setRuleType(int $ruleType) { $this->set("RuleType", $ruleType); } - /** * SrcAddr: 保留字段,暂未使用 * @@ -257,11 +250,10 @@ public function getSrcAddr() * * @param string $srcAddr */ - public function setSrcAddr($srcAddr) + public function setSrcAddr(string $srcAddr) { $this->set("SrcAddr", $srcAddr); } - /** * SrcPort: 保留字段,暂未使用 * @@ -277,11 +269,10 @@ public function getSrcPort() * * @param int $srcPort */ - public function setSrcPort($srcPort) + public function setSrcPort(int $srcPort) { $this->set("SrcPort", $srcPort); } - /** * VNetId: 所属的VPC * @@ -297,7 +288,7 @@ public function getVNetId() * * @param string $vNetId */ - public function setVNetId($vNetId) + public function setVNetId(string $vNetId) { $this->set("VNetId", $vNetId); } diff --git a/src/VPC/Models/RouteTableInfo.php b/src/VPC2.0/Models/RouteTableInfo.php similarity index 85% rename from src/VPC/Models/RouteTableInfo.php rename to src/VPC2.0/Models/RouteTableInfo.php index 954e8d77..386c8c69 100644 --- a/src/VPC/Models/RouteTableInfo.php +++ b/src/VPC2.0/Models/RouteTableInfo.php @@ -1,6 +1,7 @@ set("RouteTableId", $routeTableId); } - /** * RouteTableType: 路由表类型。1为默认路由表,0为自定义路由表 * @@ -57,11 +60,10 @@ public function getRouteTableType() * * @param int $routeTableType */ - public function setRouteTableType($routeTableType) + public function setRouteTableType(int $routeTableType) { $this->set("RouteTableType", $routeTableType); } - /** * SubnetCount: 绑定该路由表的子网数量 * @@ -77,11 +79,10 @@ public function getSubnetCount() * * @param int $subnetCount */ - public function setSubnetCount($subnetCount) + public function setSubnetCount(int $subnetCount) { $this->set("SubnetCount", $subnetCount); } - /** * VPCId: 路由表所属的VPC资源ID * @@ -97,11 +98,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * VPCName: 路由表所属的VPC资源名称 * @@ -117,11 +117,10 @@ public function getVPCName() * * @param string $vpcName */ - public function setVPCName($vpcName) + public function setVPCName(string $vpcName) { $this->set("VPCName", $vpcName); } - /** * Tag: 路由表所属业务组 * @@ -137,11 +136,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Remark: 路由表备注 * @@ -157,11 +155,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * CreateTime: 创建时间戳 * @@ -177,15 +174,14 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * RouteRules: 路由规则 * - * @return RouteRuleInfo[]|null + * @return RouteRuleInfoModel[]|null */ public function getRouteRules() { @@ -195,7 +191,7 @@ public function getRouteRules() } $result = []; foreach ($items as $i => $item) { - array_push($result, new RouteRuleInfo($item)); + array_push($result, new RouteRuleInfoModel($item)); } return $result; } @@ -203,7 +199,7 @@ public function getRouteRules() /** * RouteRules: 路由规则 * - * @param RouteRuleInfo[] $routeRules + * @param RouteRuleInfoModel[] $routeRules */ public function setRouteRules(array $routeRules) { diff --git a/src/VPC2.0/Models/SnatDnatRuleInfo.php b/src/VPC2.0/Models/SnatDnatRuleInfo.php new file mode 100644 index 00000000..5c55377b --- /dev/null +++ b/src/VPC2.0/Models/SnatDnatRuleInfo.php @@ -0,0 +1,85 @@ +get("PrivateIp"); + } + + /** + * PrivateIp: 内网IP地址 + * + * @param string $privateIp + */ + public function setPrivateIp(string $privateIp) + { + $this->set("PrivateIp", $privateIp); + } + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @return string|null + */ + public function getNATGWId() + { + return $this->get("NATGWId"); + } + + /** + * NATGWId: 映射所使用的NAT网关资源ID + * + * @param string $natgwId + */ + public function setNATGWId(string $natgwId) + { + $this->set("NATGWId", $natgwId); + } + /** + * EIP: EIP的IP地址 + * + * @return string|null + */ + public function getEIP() + { + return $this->get("EIP"); + } + + /** + * EIP: EIP的IP地址 + * + * @param string $eip + */ + public function setEIP(string $eip) + { + $this->set("EIP", $eip); + } +} diff --git a/src/VPC/Models/SubnetInfo.php b/src/VPC2.0/Models/SubnetInfo.php similarity index 86% rename from src/VPC/Models/SubnetInfo.php rename to src/VPC2.0/Models/SubnetInfo.php index 4b83b086..82976bb4 100644 --- a/src/VPC/Models/SubnetInfo.php +++ b/src/VPC2.0/Models/SubnetInfo.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * IPv6Network: 子网关联的IPv6网段 * @@ -57,11 +59,10 @@ public function getIPv6Network() * * @param string $iPv6Network */ - public function setIPv6Network($iPv6Network) + public function setIPv6Network(string $iPv6Network) { $this->set("IPv6Network", $iPv6Network); } - /** * VPCId: VPCId * @@ -77,11 +78,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * VPCName: VPC名称 * @@ -97,11 +97,10 @@ public function getVPCName() * * @param string $vpcName */ - public function setVPCName($vpcName) + public function setVPCName(string $vpcName) { $this->set("VPCName", $vpcName); } - /** * SubnetId: 子网Id * @@ -117,11 +116,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * SubnetName: 子网名称 * @@ -137,11 +135,10 @@ public function getSubnetName() * * @param string $subnetName */ - public function setSubnetName($subnetName) + public function setSubnetName(string $subnetName) { $this->set("SubnetName", $subnetName); } - /** * Remark: 备注 * @@ -157,11 +154,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: 业务组 * @@ -177,11 +173,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * SubnetType: 子网类型 * @@ -197,11 +192,10 @@ public function getSubnetType() * * @param int $subnetType */ - public function setSubnetType($subnetType) + public function setSubnetType(int $subnetType) { $this->set("SubnetType", $subnetType); } - /** * Subnet: 子网网段 * @@ -217,11 +211,10 @@ public function getSubnet() * * @param string $subnet */ - public function setSubnet($subnet) + public function setSubnet(string $subnet) { $this->set("Subnet", $subnet); } - /** * Netmask: 子网掩码 * @@ -237,11 +230,10 @@ public function getNetmask() * * @param string $netmask */ - public function setNetmask($netmask) + public function setNetmask(string $netmask) { $this->set("Netmask", $netmask); } - /** * Gateway: 子网网关 * @@ -257,11 +249,10 @@ public function getGateway() * * @param string $gateway */ - public function setGateway($gateway) + public function setGateway(string $gateway) { $this->set("Gateway", $gateway); } - /** * CreateTime: 创建时间 * @@ -277,11 +268,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * HasNATGW: 是否有natgw * @@ -297,11 +287,10 @@ public function getHasNATGW() * * @param boolean $hasNATGW */ - public function setHasNATGW($hasNATGW) + public function setHasNATGW(bool $hasNATGW) { $this->set("HasNATGW", $hasNATGW); } - /** * RouteTableId: 路由表Id * @@ -317,11 +306,10 @@ public function getRouteTableId() * * @param string $routeTableId */ - public function setRouteTableId($routeTableId) + public function setRouteTableId(string $routeTableId) { $this->set("RouteTableId", $routeTableId); } - /** * AvailableIPs: 可用IP数量 * @@ -337,7 +325,7 @@ public function getAvailableIPs() * * @param int $availableIPs */ - public function setAvailableIPs($availableIPs) + public function setAvailableIPs(int $availableIPs) { $this->set("AvailableIPs", $availableIPs); } diff --git a/src/VPC/Models/SubnetResource.php b/src/VPC2.0/Models/SubnetResource.php similarity index 89% rename from src/VPC/Models/SubnetResource.php rename to src/VPC2.0/Models/SubnetResource.php index d20f902a..23ca7b06 100644 --- a/src/VPC/Models/SubnetResource.php +++ b/src/VPC2.0/Models/SubnetResource.php @@ -1,6 +1,7 @@ set("Name", $name); } - /** * ResourceId: 资源Id * @@ -57,11 +59,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceType: 资源类型。对应的资源类型:UHOST,云主机;PHOST,物理云主机;ULB,负载均衡;UHADOOP_HOST,hadoop节点;UFORTRESS_HOST,堡垒机;UNATGW,NAT网关;UKAFKA,分布式消息系统;UMEM,内存存储;DOCKER,容器集群;UDB,数据库;UDW,数据仓库;VIP,内网VIP. * @@ -77,11 +78,10 @@ public function getResourceType() * * @param string $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(string $resourceType) { $this->set("ResourceType", $resourceType); } - /** * IP: 资源ip * @@ -97,7 +97,7 @@ public function getIP() * * @param string $ip */ - public function setIP($ip) + public function setIP(string $ip) { $this->set("IP", $ip); } diff --git a/src/VPC/Models/TargetResourceInfo.php b/src/VPC2.0/Models/TargetResourceInfo.php similarity index 82% rename from src/VPC/Models/TargetResourceInfo.php rename to src/VPC2.0/Models/TargetResourceInfo.php index dab4a57d..158916f7 100644 --- a/src/VPC/Models/TargetResourceInfo.php +++ b/src/VPC2.0/Models/TargetResourceInfo.php @@ -1,6 +1,7 @@ set("SubnetworkId", $subnetworkId); } - /** * ResourceName: 资源名称 * @@ -57,11 +63,10 @@ public function getResourceName() * * @param string $resourceName */ - public function setResourceName($resourceName) + public function setResourceName(string $resourceName) { $this->set("ResourceName", $resourceName); } - /** * ResourceId: 资源ID * @@ -77,11 +82,10 @@ public function getResourceId() * * @param string $resourceId */ - public function setResourceId($resourceId) + public function setResourceId(string $resourceId) { $this->set("ResourceId", $resourceId); } - /** * ResourceType: 资源类型 * @@ -97,11 +101,10 @@ public function getResourceType() * * @param int $resourceType */ - public function setResourceType($resourceType) + public function setResourceType(int $resourceType) { $this->set("ResourceType", $resourceType); } - /** * SubResourceName: 资源绑定的虚拟网卡的名称 * @@ -117,11 +120,10 @@ public function getSubResourceName() * * @param string $subResourceName */ - public function setSubResourceName($subResourceName) + public function setSubResourceName(string $subResourceName) { $this->set("SubResourceName", $subResourceName); } - /** * SubResourceId: 资源绑定的虚拟网卡的ID * @@ -137,11 +139,10 @@ public function getSubResourceId() * * @param string $subResourceId */ - public function setSubResourceId($subResourceId) + public function setSubResourceId(string $subResourceId) { $this->set("SubResourceId", $subResourceId); } - /** * SubResourceType: 资源绑定虚拟网卡的类型 * @@ -157,11 +158,10 @@ public function getSubResourceType() * * @param int $subResourceType */ - public function setSubResourceType($subResourceType) + public function setSubResourceType(int $subResourceType) { $this->set("SubResourceType", $subResourceType); } - /** * PrivateIp: 资源内网IP * @@ -177,7 +177,7 @@ public function getPrivateIp() * * @param string $privateIp */ - public function setPrivateIp($privateIp) + public function setPrivateIp(string $privateIp) { $this->set("PrivateIp", $privateIp); } diff --git a/src/VPC/Models/VIPDetailSet.php b/src/VPC2.0/Models/VIPDetailSet.php similarity index 86% rename from src/VPC/Models/VIPDetailSet.php rename to src/VPC2.0/Models/VIPDetailSet.php index f103fdf8..de391fde 100644 --- a/src/VPC/Models/VIPDetailSet.php +++ b/src/VPC2.0/Models/VIPDetailSet.php @@ -1,6 +1,7 @@ set("Zone", $zone); } - /** * VIPId: 虚拟ip id * @@ -57,11 +59,10 @@ public function getVIPId() * * @param string $vipId */ - public function setVIPId($vipId) + public function setVIPId(string $vipId) { $this->set("VIPId", $vipId); } - /** * CreateTime: 创建时间 * @@ -77,11 +78,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * RealIp: 真实主机ip * @@ -97,11 +97,10 @@ public function getRealIp() * * @param string $realIp */ - public function setRealIp($realIp) + public function setRealIp(string $realIp) { $this->set("RealIp", $realIp); } - /** * VIP: 虚拟ip * @@ -117,11 +116,10 @@ public function getVIP() * * @param string $vip */ - public function setVIP($vip) + public function setVIP(string $vip) { $this->set("VIP", $vip); } - /** * SubnetId: 子网id * @@ -137,11 +135,10 @@ public function getSubnetId() * * @param string $subnetId */ - public function setSubnetId($subnetId) + public function setSubnetId(string $subnetId) { $this->set("SubnetId", $subnetId); } - /** * VPCId: VPC id * @@ -157,11 +154,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Name: VIP名称 * @@ -177,11 +173,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * Remark: VIP备注 * @@ -197,11 +192,10 @@ public function getRemark() * * @param string $remark */ - public function setRemark($remark) + public function setRemark(string $remark) { $this->set("Remark", $remark); } - /** * Tag: VIP所属业务组 * @@ -217,7 +211,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/VPC/Models/VIPSet.php b/src/VPC2.0/Models/VIPSet.php similarity index 87% rename from src/VPC/Models/VIPSet.php rename to src/VPC2.0/Models/VIPSet.php index 1a64157d..9fe2785f 100644 --- a/src/VPC/Models/VIPSet.php +++ b/src/VPC2.0/Models/VIPSet.php @@ -1,6 +1,7 @@ set("VIP", $vip); } - /** * VIPId: 虚拟ip id * @@ -57,11 +59,10 @@ public function getVIPId() * * @param string $vipId */ - public function setVIPId($vipId) + public function setVIPId(string $vipId) { $this->set("VIPId", $vipId); } - /** * VPCId: VPC id * @@ -77,7 +78,7 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } diff --git a/src/VPC/Models/VPCInfo.php b/src/VPC2.0/Models/VPCInfo.php similarity index 85% rename from src/VPC/Models/VPCInfo.php rename to src/VPC2.0/Models/VPCInfo.php index af68de7f..2e765650 100644 --- a/src/VPC/Models/VPCInfo.php +++ b/src/VPC2.0/Models/VPCInfo.php @@ -1,6 +1,7 @@ $item) { - array_push($result, new VPCNetworkInfo($item)); + array_push($result, new VPCNetworkInfoModel($item)); } return $result; } @@ -43,7 +47,7 @@ public function getNetworkInfo() /** * NetworkInfo: * - * @param VPCNetworkInfo[] $networkInfo + * @param VPCNetworkInfoModel[] $networkInfo */ public function setNetworkInfo(array $networkInfo) { @@ -53,7 +57,6 @@ public function setNetworkInfo(array $networkInfo) } return $result; } - /** * SubnetCount: * @@ -69,11 +72,10 @@ public function getSubnetCount() * * @param int $subnetCount */ - public function setSubnetCount($subnetCount) + public function setSubnetCount(int $subnetCount) { $this->set("SubnetCount", $subnetCount); } - /** * CreateTime: * @@ -89,11 +91,10 @@ public function getCreateTime() * * @param int $createTime */ - public function setCreateTime($createTime) + public function setCreateTime(int $createTime) { $this->set("CreateTime", $createTime); } - /** * UpdateTime: * @@ -109,11 +110,10 @@ public function getUpdateTime() * * @param int $updateTime */ - public function setUpdateTime($updateTime) + public function setUpdateTime(int $updateTime) { $this->set("UpdateTime", $updateTime); } - /** * Tag: * @@ -129,11 +129,10 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } - /** * Name: * @@ -149,11 +148,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * VPCId: VPCId * @@ -169,11 +167,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Network: * @@ -193,7 +190,6 @@ public function setNetwork(array $network) { $this->set("Network", $network); } - /** * IPv6Network: VPC关联的IPv6网段 * @@ -209,11 +205,10 @@ public function getIPv6Network() * * @param string $iPv6Network */ - public function setIPv6Network($iPv6Network) + public function setIPv6Network(string $iPv6Network) { $this->set("IPv6Network", $iPv6Network); } - /** * OperatorName: VPC关联的IPv6网段所属运营商 * @@ -229,7 +224,7 @@ public function getOperatorName() * * @param string $operatorName */ - public function setOperatorName($operatorName) + public function setOperatorName(string $operatorName) { $this->set("OperatorName", $operatorName); } diff --git a/src/VPC/Models/VPCIntercomInfo.php b/src/VPC2.0/Models/VPCIntercomInfo.php similarity index 88% rename from src/VPC/Models/VPCIntercomInfo.php rename to src/VPC2.0/Models/VPCIntercomInfo.php index d2a09928..1e27f49f 100644 --- a/src/VPC/Models/VPCIntercomInfo.php +++ b/src/VPC2.0/Models/VPCIntercomInfo.php @@ -1,6 +1,7 @@ set("ProjectId", $projectId); } - /** * VPCType: vpc类型(1表示托管VPC,0表示公有云VPC) * @@ -57,11 +59,10 @@ public function getVPCType() * * @param int $vpcType */ - public function setVPCType($vpcType) + public function setVPCType(int $vpcType) { $this->set("VPCType", $vpcType); } - /** * AccountId: 项目Id(数字) * @@ -77,11 +78,10 @@ public function getAccountId() * * @param int $accountId */ - public function setAccountId($accountId) + public function setAccountId(int $accountId) { $this->set("AccountId", $accountId); } - /** * Network: VPC的地址空间 * @@ -101,7 +101,6 @@ public function setNetwork(array $network) { $this->set("Network", $network); } - /** * DstRegion: 所属地域 * @@ -117,11 +116,10 @@ public function getDstRegion() * * @param string $dstRegion */ - public function setDstRegion($dstRegion) + public function setDstRegion(string $dstRegion) { $this->set("DstRegion", $dstRegion); } - /** * Name: VPC名字 * @@ -137,11 +135,10 @@ public function getName() * * @param string $name */ - public function setName($name) + public function setName(string $name) { $this->set("Name", $name); } - /** * VPCId: VPCId * @@ -157,11 +154,10 @@ public function getVPCId() * * @param string $vpcId */ - public function setVPCId($vpcId) + public function setVPCId(string $vpcId) { $this->set("VPCId", $vpcId); } - /** * Tag: 业务组(未分组显示为 Default) * @@ -177,7 +173,7 @@ public function getTag() * * @param string $tag */ - public function setTag($tag) + public function setTag(string $tag) { $this->set("Tag", $tag); } diff --git a/src/VPC/Models/VPCNetworkInfo.php b/src/VPC2.0/Models/VPCNetworkInfo.php similarity index 85% rename from src/VPC/Models/VPCNetworkInfo.php rename to src/VPC2.0/Models/VPCNetworkInfo.php index 26955b90..fdff2202 100644 --- a/src/VPC/Models/VPCNetworkInfo.php +++ b/src/VPC2.0/Models/VPCNetworkInfo.php @@ -1,6 +1,7 @@ set("Network", $network); } - /** * SubnetCount: 地址空间中子网数量 * @@ -57,7 +60,7 @@ public function getSubnetCount() * * @param int $subnetCount */ - public function setSubnetCount($subnetCount) + public function setSubnetCount(int $subnetCount) { $this->set("SubnetCount", $subnetCount); } diff --git a/src/VPC2.0/VPC2.0Client.php b/src/VPC2.0/VPC2.0Client.php new file mode 100644 index 00000000..972efae5 --- /dev/null +++ b/src/VPC2.0/VPC2.0Client.php @@ -0,0 +1,1303 @@ +invoke($request); + return new AddSnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AddVPCNetwork - 添加VPC网段 + * + * @throws UCloudException + */ + public function addVPCNetwork(AddVPCNetworkRequest $request = null) + { + $resp = $this->invoke($request); + return new AddVPCNetworkResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AddWhiteListResource - 添加NAT网关白名单 + * + * @throws UCloudException + */ + public function addWhiteListResource(AddWhiteListResourceRequest $request = null) + { + $resp = $this->invoke($request); + return new AddWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AllocateSecondaryIp - 分配ip(用于uk8s使用) + * + * @throws UCloudException + */ + public function allocateSecondaryIp(AllocateSecondaryIpRequest $request = null) + { + $resp = $this->invoke($request); + return new AllocateSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AllocateVIP - 根据提供信息,申请内网VIP(Virtual IP),多用于高可用程序作为漂移IP。 + * + * @throws UCloudException + */ + public function allocateVIP(AllocateVIPRequest $request = null) + { + $resp = $this->invoke($request); + return new AllocateVIPResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * AssociateRouteTable - 绑定子网的路由表 + * + * @throws UCloudException + */ + public function associateRouteTable(AssociateRouteTableRequest $request = null) + { + $resp = $this->invoke($request); + return new AssociateRouteTableResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CloneRouteTable - 将现有的路由表复制为一张新的路由表 + * + * @throws UCloudException + */ + public function cloneRouteTable(CloneRouteTableRequest $request = null) + { + $resp = $this->invoke($request); + return new CloneRouteTableResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateNATGW - 创建NAT网关 + * + * @throws UCloudException + */ + public function createNATGW(CreateNATGWRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateNATGWResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateNATGWPolicy - 添加NAT网关端口转发规则 + * + * @throws UCloudException + */ + public function createNATGWPolicy(CreateNATGWPolicyRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateNetworkAcl - 创建网络ACL + * + * @throws UCloudException + */ + public function createNetworkAcl(CreateNetworkAclRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateNetworkAclResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateNetworkAclAssociation - 创建ACL的绑定关系 + * + * @throws UCloudException + */ + public function createNetworkAclAssociation(CreateNetworkAclAssociationRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateNetworkAclEntry - 创建ACL的规则 + * + * @throws UCloudException + */ + public function createNetworkAclEntry(CreateNetworkAclEntryRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateRouteTable - 创建路由表 + * + * @throws UCloudException + */ + public function createRouteTable(CreateRouteTableRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateRouteTableResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateSnatDnatRule - 调用接口后会自动创建内外网IP之间的SNAT和DNAT规则,支持TCP、UDP协议全端口 + * + * @throws UCloudException + */ + public function createSnatDnatRule(CreateSnatDnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateSnatDnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateSubnet - 创建子网 + * + * @throws UCloudException + */ + public function createSubnet(CreateSubnetRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateSubnetResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateVPC - 创建VPC + * + * @throws UCloudException + */ + public function createVPC(CreateVPCRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateVPCResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * CreateVPCIntercom - 新建VPC互通关系 + * + * @throws UCloudException + */ + public function createVPCIntercom(CreateVPCIntercomRequest $request = null) + { + $resp = $this->invoke($request); + return new CreateVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteNATGW - 删除NAT网关 + * + * @throws UCloudException + */ + public function deleteNATGW(DeleteNATGWRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteNATGWResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteNATGWPolicy - 删除NAT网关端口转发规则 + * + * @throws UCloudException + */ + public function deleteNATGWPolicy(DeleteNATGWPolicyRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteNetworkAcl - 删除网络ACL + * + * @throws UCloudException + */ + public function deleteNetworkAcl(DeleteNetworkAclRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteNetworkAclResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteNetworkAclAssociation - 删除网络ACL绑定关系 + * + * @throws UCloudException + */ + public function deleteNetworkAclAssociation(DeleteNetworkAclAssociationRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteNetworkAclEntry - 删除ACL的规则 + * + * @throws UCloudException + */ + public function deleteNetworkAclEntry(DeleteNetworkAclEntryRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteRouteTable - 删除自定义路由表 + * + * @throws UCloudException + */ + public function deleteRouteTable(DeleteRouteTableRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteRouteTableResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteSecondaryIp - 删除ip(用于uk8s使用) + * + * @throws UCloudException + */ + public function deleteSecondaryIp(DeleteSecondaryIpRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteSnatDnatRule - 删除NAT创建内外网IP映射规则 + * + * @throws UCloudException + */ + public function deleteSnatDnatRule(DeleteSnatDnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteSnatDnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteSnatRule - 删除指定的出口规则(SNAT规则) + * + * @throws UCloudException + */ + public function deleteSnatRule(DeleteSnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteSnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteSubnet - 删除子网 + * + * @throws UCloudException + */ + public function deleteSubnet(DeleteSubnetRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteSubnetResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteVPC - 删除VPC + * + * @throws UCloudException + */ + public function deleteVPC(DeleteVPCRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteVPCResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteVPCIntercom - 删除VPC互通关系 + * + * @throws UCloudException + */ + public function deleteVPCIntercom(DeleteVPCIntercomRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DeleteWhiteListResource - 删除NAT网关白名单列表 + * + * @throws UCloudException + */ + public function deleteWhiteListResource(DeleteWhiteListResourceRequest $request = null) + { + $resp = $this->invoke($request); + return new DeleteWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeInstanceNetworkInterface - 展示云主机绑定的网卡信息 + * + * @throws UCloudException + */ + public function describeInstanceNetworkInterface(DescribeInstanceNetworkInterfaceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeInstanceNetworkInterfaceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNATGW - 获取NAT网关信息 + * + * @throws UCloudException + */ + public function describeNATGW(DescribeNATGWRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNATGWResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNATGWPolicy - 展示NAT网关端口转发规则 + * + * @throws UCloudException + */ + public function describeNATGWPolicy(DescribeNATGWPolicyRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNetworkAcl - 获取网络ACL + * + * @throws UCloudException + */ + public function describeNetworkAcl(DescribeNetworkAclRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNetworkAclResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNetworkAclAssociation - 获取网络ACL的绑定关系列表 + * + * @throws UCloudException + */ + public function describeNetworkAclAssociation(DescribeNetworkAclAssociationRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNetworkAclAssociationResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNetworkAclAssociationBySubnet - 获取子网的ACL绑定信息 + * + * @throws UCloudException + */ + public function describeNetworkAclAssociationBySubnet(DescribeNetworkAclAssociationBySubnetRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNetworkAclAssociationBySubnetResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNetworkAclEntry - 获取ACL的规则信息 + * + * @throws UCloudException + */ + public function describeNetworkAclEntry(DescribeNetworkAclEntryRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeNetworkInterface - 展示虚拟网卡信息 + * + * @throws UCloudException + */ + public function describeNetworkInterface(DescribeNetworkInterfaceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeNetworkInterfaceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeRouteTable - 获取路由表详细信息(包括路由策略) + * + * @throws UCloudException + */ + public function describeRouteTable(DescribeRouteTableRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeRouteTableResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeSecondaryIp - 查询SecondaryIp(uk8s使用) + * + * @throws UCloudException + */ + public function describeSecondaryIp(DescribeSecondaryIpRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeSecondaryIpResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeSnatDnatRule - 获取基于NAT创建的内外网IP映射规则信息 + * + * @throws UCloudException + */ + public function describeSnatDnatRule(DescribeSnatDnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeSnatDnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeSnatRule - 获取Nat网关的出口规则(SNAT规则) + * + * @throws UCloudException + */ + public function describeSnatRule(DescribeSnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeSnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeSubnet - 获取子网信息 + * + * @throws UCloudException + */ + public function describeSubnet(DescribeSubnetRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeSubnetResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeSubnetResource - 展示子网资源 + * + * @throws UCloudException + */ + public function describeSubnetResource(DescribeSubnetResourceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeSubnetResourceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeVIP - 获取内网VIP详细信息 + * + * @throws UCloudException + */ + public function describeVIP(DescribeVIPRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeVIPResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeVPC - 获取VPC信息 + * + * @throws UCloudException + */ + public function describeVPC(DescribeVPCRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeVPCResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeVPCIntercom - 获取VPC互通信息 + * + * @throws UCloudException + */ + public function describeVPCIntercom(DescribeVPCIntercomRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeVPCIntercomResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * DescribeWhiteListResource - 展示NAT网关白名单资源列表 + * + * @throws UCloudException + */ + public function describeWhiteListResource(DescribeWhiteListResourceRequest $request = null) + { + $resp = $this->invoke($request); + return new DescribeWhiteListResourceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * EnableWhiteList - 修改NAT网关白名单开关 + * + * @throws UCloudException + */ + public function enableWhiteList(EnableWhiteListRequest $request = null) + { + $resp = $this->invoke($request); + return new EnableWhiteListResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetAvailableResourceForPolicy - 获取NAT网关可配置端口转发规则的资源信息 + * + * @throws UCloudException + */ + public function getAvailableResourceForPolicy(GetAvailableResourceForPolicyRequest $request = null) + { + $resp = $this->invoke($request); + return new GetAvailableResourceForPolicyResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetAvailableResourceForSnatRule - 获取可用于添加snat规则(出口规则)的资源列表 + * + * @throws UCloudException + */ + public function getAvailableResourceForSnatRule(GetAvailableResourceForSnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new GetAvailableResourceForSnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetAvailableResourceForWhiteList - 获取NAT网关可添加白名单的资源 + * + * @throws UCloudException + */ + public function getAvailableResourceForWhiteList(GetAvailableResourceForWhiteListRequest $request = null) + { + $resp = $this->invoke($request); + return new GetAvailableResourceForWhiteListResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * GetNetworkAclTargetResource - 获取ACL规则应用目标列表 + * + * @throws UCloudException + */ + public function getNetworkAclTargetResource(GetNetworkAclTargetResourceRequest $request = null) + { + $resp = $this->invoke($request); + return new GetNetworkAclTargetResourceResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ListSubnetForNATGW - 展示NAT网关可绑定的子网列表 + * + * @throws UCloudException + */ + public function listSubnetForNATGW(ListSubnetForNATGWRequest $request = null) + { + $resp = $this->invoke($request); + return new ListSubnetForNATGWResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ModifyRouteRule - 路由策略增、删、改 + * + * @throws UCloudException + */ + public function modifyRouteRule(ModifyRouteRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new ModifyRouteRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * MoveSecondaryIPMac - 把 Secondary IP 从旧 MAC 迁移到新 MAC + * + * @throws UCloudException + */ + public function moveSecondaryIPMac(MoveSecondaryIPMacRequest $request = null) + { + $resp = $this->invoke($request); + return new MoveSecondaryIPMacResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * ReleaseVIP - 释放VIP资源 + * + * @throws UCloudException + */ + public function releaseVIP(ReleaseVIPRequest $request = null) + { + $resp = $this->invoke($request); + return new ReleaseVIPResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * SetGwDefaultExport - 设置NAT网关的默认出口 + * + * @throws UCloudException + */ + public function setGwDefaultExport(SetGwDefaultExportRequest $request = null) + { + $resp = $this->invoke($request); + return new SetGwDefaultExportResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateNATGWPolicy - 更新NAT网关端口转发规则 + * + * @throws UCloudException + */ + public function updateNATGWPolicy(UpdateNATGWPolicyRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateNATGWPolicyResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateNATGWSubnet - 更新NAT网关绑定的子网 + * + * @throws UCloudException + */ + public function updateNATGWSubnet(UpdateNATGWSubnetRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateNATGWSubnetResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateNetworkAcl - 更改ACL + * + * @throws UCloudException + */ + public function updateNetworkAcl(UpdateNetworkAclRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateNetworkAclResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateNetworkAclEntry - 更新ACL的规则 + * + * @throws UCloudException + */ + public function updateNetworkAclEntry(UpdateNetworkAclEntryRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateNetworkAclEntryResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateRouteTableAttribute - 更新路由表基本信息 + * + * @throws UCloudException + */ + public function updateRouteTableAttribute(UpdateRouteTableAttributeRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateRouteTableAttributeResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateSnatRule - 更新指定的出口规则(SNAT规则) + * + * @throws UCloudException + */ + public function updateSnatRule(UpdateSnatRuleRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateSnatRuleResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateSubnetAttribute - 更新子网信息 + * + * @throws UCloudException + */ + public function updateSubnetAttribute(UpdateSubnetAttributeRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateSubnetAttributeResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateVIPAttribute - 更新VIP信息 + * + * @throws UCloudException + */ + public function updateVIPAttribute(UpdateVIPAttributeRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateVIPAttributeResponse($resp->toArray(), $resp->getRequestId()); + } + + + + + /** + * UpdateVPCNetwork - 更新VPC网段 + * + * @throws UCloudException + */ + public function updateVPCNetwork(UpdateVPCNetworkRequest $request = null) + { + $resp = $this->invoke($request); + return new UpdateVPCNetworkResponse($resp->toArray(), $resp->getRequestId()); + } +}