/** * List Carts * Returns a list of customer records based on the criteria in the * request. In the case there are more cart results than can be returned * in a single response, a next token is provided which can be used * to obtain more results via ListCartsByNextToken. * * @param mixed $request array of parameters for Cart_Model_ListCarts request or Cart_Model_ListCarts object itself * @see Cart_Model_ListCarts * @return Cart_Model_ListCartsResponse * * @throws Cart_Exception */ public function listCarts($request) { // //require_once (dirname(__FILE__) . '/Model/ListCartsResponse.php'); return Model\Cart_Model_ListCartsResponse::fromXML($this->_invoke('ListCarts')); }
/** * List Carts * Returns a list of customer records based on the criteria in the * request. In the case there are more cart results than can be returned * in a single response, a next token is provided which can be used * to obtain more results via ListCartsByNextToken. * * @param mixed $request array of parameters for Cart_Model_ListCarts request or Cart_Model_ListCarts object itself * @see Cart_Model_ListCartsRequest * @return Cart_Model_ListCartsResponse * * @throws Cart_Exception */ public function listCarts($request) { if (!$request instanceof Model\Cart_Model_ListCartsRequest) { // //require_once (dirname(__FILE__) . '/Model/ListCartsRequest.php'); $request = new Cart_Model_ListCartsRequest($request); } $parameters = $request->toQueryParameterArray(); $parameters['Action'] = 'ListCarts'; $httpResponse = $this->_invoke($parameters); // //require_once (dirname(__FILE__) . '/Model/ListCartsResponse.php'); $response = Model\Cart_Model_ListCartsResponse::fromXML($httpResponse['ResponseBody']); $response->setResponseHeaderMetadata($httpResponse['ResponseHeaderMetadata']); return $response; }