Example #1
0
 /**
  * Get Subscription
  * Retrieve subscription information.
  *
  * @param mixed $request array of parameters for MWSSubscriptionsService_Model_GetSubscription request or MWSSubscriptionsService_Model_GetSubscription object itself
  * @see MWSSubscriptionsService_Model_GetSubscriptionInput
  * @return MWSSubscriptionsService_Model_GetSubscriptionResponse
  *
  * @throws MWSSubscriptionsService_Exception
  */
 public function getSubscription($request)
 {
     if (!$request instanceof MWSSubscriptionsService_Model_GetSubscriptionInput) {
         require_once dirname(__FILE__) . '/Model/GetSubscriptionInput.php';
         $request = new MWSSubscriptionsService_Model_GetSubscriptionInput($request);
     }
     $parameters = $request->toQueryParameterArray();
     $parameters['Action'] = 'GetSubscription';
     $httpResponse = $this->_invoke($parameters);
     require_once dirname(__FILE__) . '/Model/GetSubscriptionResponse.php';
     $response = MWSSubscriptionsService_Model_GetSubscriptionResponse::fromXML($httpResponse['ResponseBody']);
     $response->setResponseHeaderMetadata($httpResponse['ResponseHeaderMetadata']);
     return $response;
 }
Example #2
0
 /**
  * Get Subscription
  * Retrieve subscription information.
  *
  * @param mixed $request array of parameters for MWSSubscriptionsService_Model_GetSubscription request or MWSSubscriptionsService_Model_GetSubscription object itself
  * @see MWSSubscriptionsService_Model_GetSubscription
  * @return MWSSubscriptionsService_Model_GetSubscriptionResponse
  *
  * @throws MWSSubscriptionsService_Exception
  */
 public function getSubscription($request)
 {
     require_once dirname(__FILE__) . '/Model/GetSubscriptionResponse.php';
     return MWSSubscriptionsService_Model_GetSubscriptionResponse::fromXML($this->_invoke('GetSubscription'));
 }