forked from loafle/openapi-generator-original
minor php code improvement
This commit is contained in:
@@ -102,7 +102,7 @@ class PetApi
|
||||
*/
|
||||
public function addPet($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->addPetWithHttpInfo ($body);
|
||||
list($response) = $this->addPetWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -126,11 +126,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array('application/json','application/xml'));
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array('application/json','application/xml'));
|
||||
|
||||
|
||||
|
||||
@@ -186,7 +186,7 @@ class PetApi
|
||||
*/
|
||||
public function addPetUsingByteArray($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->addPetUsingByteArrayWithHttpInfo ($body);
|
||||
list($response) = $this->addPetUsingByteArrayWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -210,11 +210,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array('application/json','application/xml'));
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array('application/json','application/xml'));
|
||||
|
||||
|
||||
|
||||
@@ -271,7 +271,7 @@ class PetApi
|
||||
*/
|
||||
public function deletePet($pet_id, $api_key = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->deletePetWithHttpInfo ($pet_id, $api_key);
|
||||
list($response) = $this->deletePetWithHttpInfo ($pet_id, $api_key);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -300,11 +300,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
// header params
|
||||
@@ -368,7 +368,7 @@ class PetApi
|
||||
*/
|
||||
public function findPetsByStatus($status = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->findPetsByStatusWithHttpInfo ($status);
|
||||
list($response) = $this->findPetsByStatusWithHttpInfo ($status);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -392,11 +392,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
// query params
|
||||
|
||||
@@ -439,12 +439,12 @@ class PetApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Pet[]', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Pet[]', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet[]', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet[]', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -464,7 +464,7 @@ class PetApi
|
||||
*/
|
||||
public function findPetsByTags($tags = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->findPetsByTagsWithHttpInfo ($tags);
|
||||
list($response) = $this->findPetsByTagsWithHttpInfo ($tags);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -488,11 +488,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
// query params
|
||||
|
||||
@@ -535,12 +535,12 @@ class PetApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Pet[]', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Pet[]', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet[]', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet[]', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -560,7 +560,7 @@ class PetApi
|
||||
*/
|
||||
public function getPetById($pet_id)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getPetByIdWithHttpInfo ($pet_id);
|
||||
list($response) = $this->getPetByIdWithHttpInfo ($pet_id);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -588,11 +588,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -642,12 +642,12 @@ class PetApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Pet', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Pet', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Pet', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -667,7 +667,7 @@ class PetApi
|
||||
*/
|
||||
public function getPetByIdInObject($pet_id)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getPetByIdInObjectWithHttpInfo ($pet_id);
|
||||
list($response) = $this->getPetByIdInObjectWithHttpInfo ($pet_id);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -695,11 +695,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -749,12 +749,12 @@ class PetApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\InlineResponse200', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\InlineResponse200', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\InlineResponse200', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\InlineResponse200', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -774,7 +774,7 @@ class PetApi
|
||||
*/
|
||||
public function petPetIdtestingByteArraytrueGet($pet_id)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->petPetIdtestingByteArraytrueGetWithHttpInfo ($pet_id);
|
||||
list($response) = $this->petPetIdtestingByteArraytrueGetWithHttpInfo ($pet_id);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -802,11 +802,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -856,12 +856,12 @@ class PetApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, 'string', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, 'string', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), 'string', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), 'string', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -881,7 +881,7 @@ class PetApi
|
||||
*/
|
||||
public function updatePet($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->updatePetWithHttpInfo ($body);
|
||||
list($response) = $this->updatePetWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -905,11 +905,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array('application/json','application/xml'));
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array('application/json','application/xml'));
|
||||
|
||||
|
||||
|
||||
@@ -967,7 +967,7 @@ class PetApi
|
||||
*/
|
||||
public function updatePetWithForm($pet_id, $name = null, $status = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->updatePetWithFormWithHttpInfo ($pet_id, $name, $status);
|
||||
list($response) = $this->updatePetWithFormWithHttpInfo ($pet_id, $name, $status);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -997,11 +997,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array('application/x-www-form-urlencoded'));
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array('application/x-www-form-urlencoded'));
|
||||
|
||||
|
||||
|
||||
@@ -1075,7 +1075,7 @@ class PetApi
|
||||
*/
|
||||
public function uploadFile($pet_id, $additional_metadata = null, $file = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->uploadFileWithHttpInfo ($pet_id, $additional_metadata, $file);
|
||||
list($response) = $this->uploadFileWithHttpInfo ($pet_id, $additional_metadata, $file);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -1105,11 +1105,11 @@ class PetApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array('multipart/form-data'));
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array('multipart/form-data'));
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -102,7 +102,7 @@ class StoreApi
|
||||
*/
|
||||
public function deleteOrder($order_id)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->deleteOrderWithHttpInfo ($order_id);
|
||||
list($response) = $this->deleteOrderWithHttpInfo ($order_id);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -130,11 +130,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -189,7 +189,7 @@ class StoreApi
|
||||
*/
|
||||
public function findOrdersByStatus($status = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->findOrdersByStatusWithHttpInfo ($status);
|
||||
list($response) = $this->findOrdersByStatusWithHttpInfo ($status);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -213,11 +213,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
// query params
|
||||
|
||||
@@ -265,12 +265,12 @@ class StoreApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Order[]', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Order[]', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order[]', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order[]', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -289,7 +289,7 @@ class StoreApi
|
||||
*/
|
||||
public function getInventory()
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getInventoryWithHttpInfo ();
|
||||
list($response) = $this->getInventoryWithHttpInfo ();
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -312,11 +312,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -353,12 +353,12 @@ class StoreApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, 'map[string,int]', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, 'map[string,int]', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), 'map[string,int]', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), 'map[string,int]', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -377,7 +377,7 @@ class StoreApi
|
||||
*/
|
||||
public function getInventoryInObject()
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getInventoryInObjectWithHttpInfo ();
|
||||
list($response) = $this->getInventoryInObjectWithHttpInfo ();
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -400,11 +400,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -441,12 +441,12 @@ class StoreApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, 'object', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, 'object', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), 'object', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), 'object', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -466,7 +466,7 @@ class StoreApi
|
||||
*/
|
||||
public function getOrderById($order_id)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getOrderByIdWithHttpInfo ($order_id);
|
||||
list($response) = $this->getOrderByIdWithHttpInfo ($order_id);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -494,11 +494,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -550,12 +550,12 @@ class StoreApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Order', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Order', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -575,7 +575,7 @@ class StoreApi
|
||||
*/
|
||||
public function placeOrder($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->placeOrderWithHttpInfo ($body);
|
||||
list($response) = $this->placeOrderWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -599,11 +599,11 @@ class StoreApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -651,12 +651,12 @@ class StoreApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\Order', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\Order', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\Order', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -102,7 +102,7 @@ class UserApi
|
||||
*/
|
||||
public function createUser($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->createUserWithHttpInfo ($body);
|
||||
list($response) = $this->createUserWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -126,11 +126,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -181,7 +181,7 @@ class UserApi
|
||||
*/
|
||||
public function createUsersWithArrayInput($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->createUsersWithArrayInputWithHttpInfo ($body);
|
||||
list($response) = $this->createUsersWithArrayInputWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -205,11 +205,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -260,7 +260,7 @@ class UserApi
|
||||
*/
|
||||
public function createUsersWithListInput($body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->createUsersWithListInputWithHttpInfo ($body);
|
||||
list($response) = $this->createUsersWithListInputWithHttpInfo ($body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -284,11 +284,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -339,7 +339,7 @@ class UserApi
|
||||
*/
|
||||
public function deleteUser($username)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->deleteUserWithHttpInfo ($username);
|
||||
list($response) = $this->deleteUserWithHttpInfo ($username);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -367,11 +367,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -431,7 +431,7 @@ class UserApi
|
||||
*/
|
||||
public function getUserByName($username)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->getUserByNameWithHttpInfo ($username);
|
||||
list($response) = $this->getUserByNameWithHttpInfo ($username);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -459,11 +459,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -501,12 +501,12 @@ class UserApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, '\Swagger\Client\Model\User', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, '\Swagger\Client\Model\User', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), '\Swagger\Client\Model\User', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), '\Swagger\Client\Model\User', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -527,7 +527,7 @@ class UserApi
|
||||
*/
|
||||
public function loginUser($username = null, $password = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->loginUserWithHttpInfo ($username, $password);
|
||||
list($response) = $this->loginUserWithHttpInfo ($username, $password);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -552,11 +552,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
// query params
|
||||
|
||||
@@ -594,12 +594,12 @@ class UserApi
|
||||
return array(null, $statusCode, $httpHeader);
|
||||
}
|
||||
|
||||
return array(\Swagger\Client\ObjectSerializer::deserialize($response, 'string', $httpHeader), $statusCode, $httpHeader);
|
||||
return array($this->apiClient->getSerializer()->deserialize($response, 'string', $httpHeader), $statusCode, $httpHeader);
|
||||
|
||||
} catch (ApiException $e) {
|
||||
switch ($e->getCode()) {
|
||||
case 200:
|
||||
$data = \Swagger\Client\ObjectSerializer::deserialize($e->getResponseBody(), 'string', $e->getResponseHeaders());
|
||||
$data = $this->apiClient->getSerializer()->deserialize($e->getResponseBody(), 'string', $e->getResponseHeaders());
|
||||
$e->setResponseObject($data);
|
||||
break;
|
||||
}
|
||||
@@ -618,7 +618,7 @@ class UserApi
|
||||
*/
|
||||
public function logoutUser()
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->logoutUserWithHttpInfo ();
|
||||
list($response) = $this->logoutUserWithHttpInfo ();
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -641,11 +641,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
@@ -693,7 +693,7 @@ class UserApi
|
||||
*/
|
||||
public function updateUser($username, $body = null)
|
||||
{
|
||||
list($response, $statusCode, $httpHeader) = $this->updateUserWithHttpInfo ($username, $body);
|
||||
list($response) = $this->updateUserWithHttpInfo ($username, $body);
|
||||
return $response;
|
||||
}
|
||||
|
||||
@@ -722,11 +722,11 @@ class UserApi
|
||||
$queryParams = array();
|
||||
$headerParams = array();
|
||||
$formParams = array();
|
||||
$_header_accept = ApiClient::selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
$_header_accept = $this->apiClient->selectHeaderAccept(array('application/json', 'application/xml'));
|
||||
if (!is_null($_header_accept)) {
|
||||
$headerParams['Accept'] = $_header_accept;
|
||||
}
|
||||
$headerParams['Content-Type'] = ApiClient::selectHeaderContentType(array());
|
||||
$headerParams['Content-Type'] = $this->apiClient->selectHeaderContentType(array());
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user