Skip to content

Commit

Permalink
Merge pull request #18 from aliyun/v1.0.x
Browse files Browse the repository at this point in the history
feat: getGameArchive
  • Loading branch information
xfslove authored Aug 10, 2023
2 parents 3c3ba36 + caf67c7 commit 883e7a9
Show file tree
Hide file tree
Showing 5 changed files with 49 additions and 169 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ PHP 5.5 and later

To install the bindings via Composer:
```
composer require alibabacloud/alibabacloud-yjopenapi-php-client 1.0.20230809
composer require alibabacloud/alibabacloud-yjopenapi-php-client 1.0.20230810
```

Then run `composer install`
Expand Down
8 changes: 4 additions & 4 deletions lib/Api/UsercontrollerApi.php
Original file line number Diff line number Diff line change
Expand Up @@ -694,10 +694,10 @@ function ($exception) {
*/
protected function getUserGameArchiveRequest($varForms)
{
// verify the required parameter 'user_id' is set
if ($varForms['user_id'] === null || (is_array($varForms['user_id']) && count($varForms['user_id']) === 0)) {
// verify the required parameter 'account_id' is set
if ($varForms['account_id'] === null || (is_array($varForms['account_id']) && count($varForms['account_id']) === 0)) {
throw new \InvalidArgumentException(
'Missing the required parameter $varForms[\'user_id\'] when calling getUserGameArchive'
'Missing the required parameter $varForms[\'account_id\'] when calling getUserGameArchive'
);
}
// verify the required parameter 'game_id' is set
Expand All @@ -720,7 +720,7 @@ protected function getUserGameArchiveRequest($varForms)
$httpBody = '';

// form params
$formParams['userId'] = ObjectSerializer::toFormValue($varForms['user_id']);
$formParams['accountId'] = ObjectSerializer::toFormValue($varForms['account_id']);
$formParams['gameId'] = ObjectSerializer::toFormValue($varForms['game_id']);
$formParams['projectId'] = ObjectSerializer::toFormValue($varForms['project_id']);

Expand Down
58 changes: 14 additions & 44 deletions lib/Model/UsercontollerGetUserGameArchiveResultModel.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,7 @@ class UsercontollerGetUserGameArchiveResultModel implements ModelInterface, Arra
protected static $serialTypes = [
'download_url' => 'string',
'object_md5' => 'string',
'archive_id' => 'int',
'model' => '\Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelModel' ];
'user_game_archive_dto' => '\Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO' ];

/**
* Array of property to format mappings. Used for (de)serialization
Expand All @@ -58,8 +57,7 @@ class UsercontollerGetUserGameArchiveResultModel implements ModelInterface, Arra
protected static $serialFormats = [
'download_url' => null,
'object_md5' => null,
'archive_id' => 'int64',
'model' => null ];
'user_game_archive_dto' => null ];

/**
* Array of property to type mappings. Used for (de)serialization
Expand Down Expand Up @@ -90,8 +88,7 @@ public static function serialFormats()
protected static $attributeMap = [
'download_url' => 'downloadUrl',
'object_md5' => 'objectMD5',
'archive_id' => 'archiveId',
'model' => 'model' ];
'user_game_archive_dto' => 'userGameArchiveDTO' ];

/**
* Array of attributes to setter functions (for deserialization of responses)
Expand All @@ -101,8 +98,7 @@ public static function serialFormats()
protected static $setters = [
'download_url' => 'setDownloadUrl',
'object_md5' => 'setObjectMd5',
'archive_id' => 'setArchiveId',
'model' => 'setModel' ];
'user_game_archive_dto' => 'setUserGameArchiveDto' ];

/**
* Array of attributes to getter functions (for serialization of requests)
Expand All @@ -112,8 +108,7 @@ public static function serialFormats()
protected static $getters = [
'download_url' => 'getDownloadUrl',
'object_md5' => 'getObjectMd5',
'archive_id' => 'getArchiveId',
'model' => 'getModel' ];
'user_game_archive_dto' => 'getUserGameArchiveDto' ];

/**
* Array of attributes where the key is the local name,
Expand Down Expand Up @@ -175,8 +170,7 @@ public function __construct(array $data = null)
{
$this->container['download_url'] = isset($data['download_url']) ? $data['download_url'] : null;
$this->container['object_md5'] = isset($data['object_md5']) ? $data['object_md5'] : null;
$this->container['archive_id'] = isset($data['archive_id']) ? $data['archive_id'] : null;
$this->container['model'] = isset($data['model']) ? $data['model'] : null;
$this->container['user_game_archive_dto'] = isset($data['user_game_archive_dto']) ? $data['user_game_archive_dto'] : null;
}


Expand Down Expand Up @@ -229,49 +223,25 @@ public function setObjectMd5($object_md5)
}

/**
* Gets archive_id
* Gets user_game_archive_dto
*
* @return int
* @return \Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO
*/
public function getArchiveId()
public function getUserGameArchiveDto()
{
return $this->container['archive_id'];
return $this->container['user_game_archive_dto'];
}

/**
* Sets archive_id
* Sets user_game_archive_dto
*
* @param int $archive_id 存档ID
* @param \Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO $user_game_archive_dto user_game_archive_dto
*
* @return $this
*/
public function setArchiveId($archive_id)
public function setUserGameArchiveDto($user_game_archive_dto)
{
$this->container['archive_id'] = $archive_id;

return $this;
}

/**
* Gets model
*
* @return \Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelModel
*/
public function getModel()
{
return $this->container['model'];
}

/**
* Sets model
*
* @param \Yjopenapi\Client\Model\UsercontollerGetUserGameArchiveResultModelModel $model model
*
* @return $this
*/
public function setModel($model)
{
$this->container['model'] = $model;
$this->container['user_game_archive_dto'] = $user_game_archive_dto;

return $this;
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?php
/**
* UsercontollerGetUserGameArchiveResultModelModel
* UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO
*
* PHP version 5
*
Expand All @@ -23,12 +23,12 @@
use \Yjopenapi\Client\Api\ObjectSerializer;

/**
* UsercontollerGetUserGameArchiveResultModelModel Class Doc Comment
* UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO Class Doc Comment
*
* @category Class
* @package Yjopenapi\Client
*/
class UsercontollerGetUserGameArchiveResultModelModel implements ModelInterface, ArrayAccess
class UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO implements ModelInterface, ArrayAccess
{
const DISCRIMINATOR = null;

Expand All @@ -37,18 +37,15 @@ class UsercontollerGetUserGameArchiveResultModelModel implements ModelInterface,
*
* @var string
*/
protected static $serialModelName = 'UsercontollerGetUserGameArchiveResultModelModel';
protected static $serialModelName = 'UsercontollerGetUserGameArchiveResultModelUserGameArchiveDTO';

/**
* Array of property to type mappings. Used for (de)serialization
*
* @var string[]
*/
protected static $serialTypes = [
'game_id' => 'int',
'game_session_id' => 'string',
'tenant_id' => 'int',
'project_id' => 'int',
'game_session_id' => 'string',
'gmt_create' => 'int' ];

/**
Expand All @@ -57,10 +54,7 @@ class UsercontollerGetUserGameArchiveResultModelModel implements ModelInterface,
* @var string[]
*/
protected static $serialFormats = [
'game_id' => 'int64',
'game_session_id' => null,
'tenant_id' => 'int64',
'project_id' => 'int64',
'game_session_id' => null,
'gmt_create' => 'int64' ];

/**
Expand Down Expand Up @@ -90,10 +84,7 @@ public static function serialFormats()
* @var string[]
*/
protected static $attributeMap = [
'game_id' => 'gameId',
'game_session_id' => 'gameSessionId',
'tenant_id' => 'tenantId',
'project_id' => 'projectId',
'game_session_id' => 'gameSessionId',
'gmt_create' => 'gmtCreate' ];

/**
Expand All @@ -102,10 +93,7 @@ public static function serialFormats()
* @var string[]
*/
protected static $setters = [
'game_id' => 'setGameId',
'game_session_id' => 'setGameSessionId',
'tenant_id' => 'setTenantId',
'project_id' => 'setProjectId',
'game_session_id' => 'setGameSessionId',
'gmt_create' => 'setGmtCreate' ];

/**
Expand All @@ -114,10 +102,7 @@ public static function serialFormats()
* @var string[]
*/
protected static $getters = [
'game_id' => 'getGameId',
'game_session_id' => 'getGameSessionId',
'tenant_id' => 'getTenantId',
'project_id' => 'getProjectId',
'game_session_id' => 'getGameSessionId',
'gmt_create' => 'getGmtCreate' ];

/**
Expand Down Expand Up @@ -178,38 +163,11 @@ public function getModelName()
*/
public function __construct(array $data = null)
{
$this->container['game_id'] = isset($data['game_id']) ? $data['game_id'] : null;
$this->container['game_session_id'] = isset($data['game_session_id']) ? $data['game_session_id'] : null;
$this->container['tenant_id'] = isset($data['tenant_id']) ? $data['tenant_id'] : null;
$this->container['project_id'] = isset($data['project_id']) ? $data['project_id'] : null;
$this->container['gmt_create'] = isset($data['gmt_create']) ? $data['gmt_create'] : null;
}


/**
* Gets game_id
*
* @return int
*/
public function getGameId()
{
return $this->container['game_id'];
}

/**
* Sets game_id
*
* @param int $game_id 游戏ID
*
* @return $this
*/
public function setGameId($game_id)
{
$this->container['game_id'] = $game_id;

return $this;
}

/**
* Gets game_session_id
*
Expand All @@ -234,54 +192,6 @@ public function setGameSessionId($game_session_id)
return $this;
}

/**
* Gets tenant_id
*
* @return int
*/
public function getTenantId()
{
return $this->container['tenant_id'];
}

/**
* Sets tenant_id
*
* @param int $tenant_id 租户ID
*
* @return $this
*/
public function setTenantId($tenant_id)
{
$this->container['tenant_id'] = $tenant_id;

return $this;
}

/**
* Gets project_id
*
* @return int
*/
public function getProjectId()
{
return $this->container['project_id'];
}

/**
* Sets project_id
*
* @param int $project_id 项目ID
*
* @return $this
*/
public function setProjectId($project_id)
{
$this->container['project_id'] = $project_id;

return $this;
}

/**
* Gets gmt_create
*
Expand Down
Loading

0 comments on commit 883e7a9

Please sign in to comment.