idx
int64
0
60.3k
question
stringlengths
92
4.62k
target
stringlengths
7
635
50,500
public function resetFeedStatuses ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#FeedProcessingStatusList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes feed status options .
50,501
public function countFeeds ( ) { $ this -> prepareCount ( ) ; $ url = $ this -> urlbase . $ this -> urlbranch ; $ query = $ this -> genQuery ( ) ; $ path = $ this -> options [ 'Action' ] . 'Result' ; if ( $ this -> mockMode ) { $ xml = $ this -> fetchMockFile ( ) -> $ path ; } else { $ response = $ this -> sendRequest ...
Fetches a count of Feed Submissions from Amazon .
50,502
public function cancelFeeds ( ) { $ this -> prepareCancel ( ) ; $ url = $ this -> urlbase . $ this -> urlbranch ; $ query = $ this -> genQuery ( ) ; $ path = $ this -> options [ 'Action' ] . 'Result' ; if ( $ this -> mockMode ) { $ xml = $ this -> fetchMockFile ( ) -> $ path ; } else { $ response = $ this -> sendReques...
Cancels the feed submissions that match the given parameters . Careful!
50,503
public function getFeedId ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) ) { return $ this -> feedList [ $ i ] [ 'FeedSubmissionId' ] ; } else { return false ; } }
Returns the feed submission ID for the specified entry .
50,504
public function getFeedType ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) ) { return $ this -> feedList [ $ i ] [ 'FeedType' ] ; } else { return false ; } }
Returns the feed type for the specified entry .
50,505
public function getDateSubmitted ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) ) { return $ this -> feedList [ $ i ] [ 'SubmittedDate' ] ; } else { return false ; } }
Returns the date submitted for the specified entry .
50,506
public function getFeedStatus ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) ) { return $ this -> feedList [ $ i ] [ 'FeedProcessingStatus' ] ; } else { return false ; } }
Returns the feed processing status for the specified entry .
50,507
public function getDateStarted ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) && isset ( $ this -> feedList [ $ i ] [ 'StartedProcessingDate' ] ) ) { return $ this -> feedList [ $ i ] [ 'StartedProcessingDate' ] ; } else { return false ; } }
Returns the date that the specified entry started being processed .
50,508
public function getDateCompleted ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) && isset ( $ this -> feedList [ $ i ] [ 'CompletedProcessingDate' ] ) ) { return $ this -> feedList [ $ i ] [ 'CompletedProcessingDate' ] ; } else { return false ; } }
Returns the date that the specified entry finished being processed .
50,509
public function getFeedInfo ( $ i = 0 ) { if ( is_numeric ( $ i ) && isset ( $ this -> feedList ) && is_array ( $ this -> feedList ) ) { return $ this -> feedList [ $ i ] ; } else { return false ; } }
Returns the full info for the specified entry .
50,510
public function getGroupId ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'FinancialEventGroupId' ] ) ) { return $ this -> list [ $ i ] [ 'FinancialEventGroupId' ] ; } else { return false ; } }
Returns the ID for the specified entry .
50,511
public function getProcessingStatus ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'ProcessingStatus' ] ) ) { return $ this -> list [ $ i ] [ 'ProcessingStatus' ] ; } else { return false ; } }
Returns the processing status for the specified entry .
50,512
public function getTransferStatus ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'FundTransferStatus' ] ) ) { return $ this -> list [ $ i ] [ 'FundTransferStatus' ] ; } else { return false ; } }
Returns the transfer status for the specified entry .
50,513
public function getOriginalTotal ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> list [ $ i ] [ 'OriginalTotal' ] ) ) { if ( $ only ) { return $ this -> list [ $ i ] [ 'OriginalTotal' ] [ 'Amount' ] ; } else { return $ this -> list [ $ i ] [ 'OriginalTotal' ] ; } } else { return false ; } }
Returns the original total for the specified entry .
50,514
public function getConvertedTotal ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> list [ $ i ] [ 'ConvertedTotal' ] ) ) { if ( $ only ) { return $ this -> list [ $ i ] [ 'ConvertedTotal' ] [ 'Amount' ] ; } else { return $ this -> list [ $ i ] [ 'ConvertedTotal' ] ; } } else { return false ; } }
Returns the converted total for the specified entry .
50,515
public function getTransferDate ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'FundTransferDate' ] ) ) { return $ this -> list [ $ i ] [ 'FundTransferDate' ] ; } else { return false ; } }
Returns the transfer date for the specified entry .
50,516
public function getTraceId ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'TraceId' ] ) ) { return $ this -> list [ $ i ] [ 'TraceId' ] ; } else { return false ; } }
Returns the trace ID for the specified entry .
50,517
public function getAccountTail ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'AccountTail' ] ) ) { return $ this -> list [ $ i ] [ 'AccountTail' ] ; } else { return false ; } }
Returns the account tail for the specified entry .
50,518
public function getBeginningBalance ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> list [ $ i ] [ 'BeginningBalance' ] ) ) { if ( $ only ) { return $ this -> list [ $ i ] [ 'BeginningBalance' ] [ 'Amount' ] ; } else { return $ this -> list [ $ i ] [ 'BeginningBalance' ] ; } } else { return false ; } }
Returns the balance at the beginning of the settlement period for the specified entry .
50,519
public function getStartDate ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'FinancialEventGroupStart' ] ) ) { return $ this -> list [ $ i ] [ 'FinancialEventGroupStart' ] ; } else { return false ; } }
Returns the start date for the specified entry .
50,520
public function getEndDate ( $ i = 0 ) { if ( isset ( $ this -> list [ $ i ] [ 'FinancialEventGroupEnd' ] ) ) { return $ this -> list [ $ i ] [ 'FinancialEventGroupEnd' ] ; } else { return false ; } }
Returns the end date for the specified entry .
50,521
public function resetEmails ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#NotificationEmailList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes email options .
50,522
public function resetCodSettings ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#CODSettings#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes COD settings options .
50,523
public function createOrder ( ) { if ( ! array_key_exists ( 'SellerFulfillmentOrderId' , $ this -> options ) ) { $ this -> log ( "Seller Fulfillment Order ID must be set in order to create an order" , 'Warning' ) ; return false ; } if ( ! array_key_exists ( 'DisplayableOrderId' , $ this -> options ) ) { $ this -> log (...
Creates a Fulfillment Order with Amazon .
50,524
public function updateOrder ( ) { if ( ! array_key_exists ( 'SellerFulfillmentOrderId' , $ this -> options ) ) { $ this -> log ( "Seller Fulfillment Order ID must be set in order to update an order" , 'Warning' ) ; return false ; } $ this -> prepareUpdate ( ) ; $ url = $ this -> urlbase . $ this -> urlbranch ; $ query ...
Updates a Fulfillment Order with Amazon .
50,525
public function getReportId ( $ i = 0 ) { if ( ! isset ( $ this -> reportList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> reportList [ $ i ] [ 'ReportId' ] ; } else { return false ; } }
Returns the report ID for the specified entry .
50,526
public function getAvailableDate ( $ i = 0 ) { if ( ! isset ( $ this -> reportList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> reportList [ $ i ] [ 'AvailableDate' ] ; } else { return false ; } }
Returns the date the specified report was first available .
50,527
public function getIsAcknowledged ( $ i = 0 ) { if ( ! isset ( $ this -> reportList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> reportList [ $ i ] [ 'Acknowledged' ] ; } else { return false ; } }
Returns whether or not the specified report is scheduled .
50,528
public function getAcknowledgedDate ( $ i = 0 ) { if ( ! isset ( $ this -> reportList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> reportList [ $ i ] [ 'AcknowledgedDate' ] ; } else { return false ; } }
Returns the date the specified report was acknowledged .
50,529
public function getProduct ( $ num = null ) { if ( ! isset ( $ this -> productList ) ) { return false ; } if ( is_numeric ( $ num ) ) { return $ this -> productList [ $ num ] ; } else { return $ this -> productList ; } }
Returns product specified or array of products .
50,530
public function resetMarketplaces ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#MarketplaceIdList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes marketplace ID options .
50,531
public function setDetailsByCreator ( AmazonMerchantShipmentCreator $ obj ) { $ this -> resetDetails ( ) ; $ options = $ obj -> getOptions ( ) ; foreach ( $ options as $ op => $ val ) { if ( preg_match ( "#ShipmentRequestDetails#" , $ op ) ) { $ this -> options [ $ op ] = $ val ; } } }
Sets all of the same Shipment details used by the given Amazon Merchant Shipment Creator object .
50,532
protected function resetDetails ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#ShipmentRequestDetails#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the shipment detail options .
50,533
public function fetchServices ( ) { if ( ! array_key_exists ( 'ShipmentRequestDetails.AmazonOrderId' , $ this -> options ) ) { $ this -> log ( "Amazon Order ID must be set in order to fetch a service list" , 'Warning' ) ; return false ; } if ( ! array_key_exists ( 'ShipmentRequestDetails.ItemList.Item.1.OrderItemId' , ...
Fetches a list of eligible shipping Services from Amazon .
50,534
public function resetShippingSpeeds ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#ShippingSpeedCategories#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes shipping speed options .
50,535
public function getPreview ( $ i = null ) { if ( ! isset ( $ this -> previewList ) ) { return false ; } if ( is_numeric ( $ i ) ) { return $ this -> previewList [ $ i ] ; } else { return $ this -> previewList ; } }
Returns the specified fulfillment preview or all of them .
50,536
public function getEstimatedWeight ( $ i = 0 , $ mode = 0 ) { if ( ! isset ( $ this -> previewList ) ) { return false ; } if ( is_int ( $ i ) && $ i >= 0 ) { if ( $ mode == 1 ) { return $ this -> previewList [ $ i ] [ 'EstimatedShippingWeight' ] [ 'Unit' ] ; } else if ( $ mode == 2 ) { return $ this -> previewList [ $ ...
Returns the estimated shipping weight for the specified entry .
50,537
public function fetchItems ( $ r = true ) { $ this -> prepareToken ( ) ; $ url = $ this -> urlbase . $ this -> urlbranch ; $ query = $ this -> genQuery ( ) ; $ path = $ this -> options [ 'Action' ] . 'Result' ; if ( $ this -> mockMode ) { $ xml = $ this -> fetchMockFile ( ) -> $ path ; } else { $ response = $ this -> s...
Retrieves the items from Amazon .
50,538
public function getItems ( $ i = null ) { if ( isset ( $ this -> itemList ) ) { if ( is_numeric ( $ i ) ) { return $ this -> itemList [ $ i ] ; } else { return $ this -> itemList ; } } else { return false ; } }
Returns the specified order item or all of them .
50,539
public function getOrderItemId ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'OrderItemId' ] ) ) { return $ this -> itemList [ $ i ] [ 'OrderItemId' ] ; } else { return false ; } }
Returns the order item ID for the specified entry .
50,540
public function getTitle ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'Title' ] ) ) { return $ this -> itemList [ $ i ] [ 'Title' ] ; } else { return false ; } }
Returns the name for the specified entry .
50,541
public function getQuantityOrdered ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'QuantityOrdered' ] ) ) { return $ this -> itemList [ $ i ] [ 'QuantityOrdered' ] ; } else { return false ; } }
Returns the quantity ordered for the specified entry .
50,542
public function getQuantityShipped ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'QuantityShipped' ] ) ) { return $ this -> itemList [ $ i ] [ 'QuantityShipped' ] ; } else { return false ; } }
Returns the quantity shipped for the specified entry .
50,543
public function getCustomizedInfo ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'BuyerCustomizedInfo' ] ) ) { return $ this -> itemList [ $ i ] [ 'BuyerCustomizedInfo' ] ; } else { return false ; } }
Returns the URL for the ZIP file containing the customized options for the specified entry .
50,544
public function getPointsGranted ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'PointsGranted' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'PointsGranted' ] [ 'PointsNumber' ] ; } else { return $ this -> itemList [ $ i ] [ 'PointsGranted' ] ; } } else { return false ; } }
Returns the number of Amazon Points granted for the specified entry .
50,545
public function getPriceDesignation ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'PriceDesignation' ] ) ) { return $ this -> itemList [ $ i ] [ 'PriceDesignation' ] ; } else { return false ; } }
Returns the price designation for the specified entry .
50,546
public function getGiftMessageText ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'GiftMessageText' ] ) ) { return $ this -> itemList [ $ i ] [ 'GiftMessageText' ] ; } else { return false ; } }
Returns the gift message text for the specified entry .
50,547
public function getGiftWrapLevel ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'GiftWrapLevel' ] ) ) { return $ this -> itemList [ $ i ] [ 'GiftWrapLevel' ] ; } else { return false ; } }
Returns the gift wrap level for the specified entry .
50,548
public function getItemPrice ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ItemPrice' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'ItemPrice' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'ItemPrice' ] ; } } else { return false ; } }
Returns the item price for the specified entry .
50,549
public function getShippingPrice ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ShippingPrice' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'ShippingPrice' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'ShippingPrice' ] ; } } else { return false ; } }
Returns the shipping price for the specified entry .
50,550
public function getGiftWrapPrice ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'GiftWrapPrice' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'GiftWrapPrice' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'GiftWrapPrice' ] ; } } else { return false ; } }
Returns the gift wrap price for the specified entry .
50,551
public function getItemTax ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ItemTax' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'ItemTax' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'ItemTax' ] ; } } else { return false ; } }
Returns the item tax for the specified entry .
50,552
public function getShippingTax ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ShippingTax' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'ShippingTax' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'ShippingTax' ] ; } } else { return false ; } }
Returns the shipping tax for the specified entry .
50,553
public function getGiftWrapTax ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'GiftWrapTax' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'GiftWrapTax' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'GiftWrapTax' ] ; } } else { return false ; } }
Returns the gift wrap tax for the specified entry .
50,554
public function getShippingDiscount ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ShippingDiscount' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'ShippingDiscount' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'ShippingDiscount' ] ; } } else { return false ; } ...
Returns the shipping discount for the specified entry .
50,555
public function getPromotionDiscount ( $ i = 0 , $ only = false ) { if ( isset ( $ this -> itemList [ $ i ] [ 'PromotionDiscount' ] ) ) { if ( $ only ) { return $ this -> itemList [ $ i ] [ 'PromotionDiscount' ] [ 'Amount' ] ; } else { return $ this -> itemList [ $ i ] [ 'PromotionDiscount' ] ; } } else { return false ...
Returns the promotional discount for the specified entry .
50,556
public function getPromotionIds ( $ i = 0 , $ j = null ) { if ( isset ( $ this -> itemList [ $ i ] [ 'PromotionIds' ] ) ) { if ( isset ( $ this -> itemList [ $ i ] [ 'PromotionIds' ] [ $ j ] ) ) { return $ this -> itemList [ $ i ] [ 'PromotionIds' ] [ $ j ] ; } else { return $ this -> itemList [ $ i ] [ 'PromotionIds' ...
Returns specified promotion ID for the specified item .
50,557
public function getInvoiceData ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'InvoiceData' ] ) ) { return $ this -> itemList [ $ i ] [ 'InvoiceData' ] ; } else { return false ; } }
Returns invoice data for the specified item .
50,558
public function getConditionId ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ConditionId' ] ) ) { return $ this -> itemList [ $ i ] [ 'ConditionId' ] ; } else { return false ; } }
Returns the condition for the specified item .
50,559
public function getConditionSubtypeId ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ConditionSubtypeId' ] ) ) { return $ this -> itemList [ $ i ] [ 'ConditionSubtypeId' ] ; } else { return false ; } }
Returns the subcondition for the specified item .
50,560
public function getConditionNote ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ConditionNote' ] ) ) { return $ this -> itemList [ $ i ] [ 'ConditionNote' ] ; } else { return false ; } }
Returns the condition description for the specified item .
50,561
public function getScheduledDeliveryStartDate ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ScheduledDeliveryStartDate' ] ) ) { return $ this -> itemList [ $ i ] [ 'ScheduledDeliveryStartDate' ] ; } else { return false ; } }
Returns the earliest date in the scheduled delivery window for the specified item .
50,562
public function getScheduledDeliveryEndDate ( $ i = 0 ) { if ( isset ( $ this -> itemList [ $ i ] [ 'ScheduledDeliveryEndDate' ] ) ) { return $ this -> itemList [ $ i ] [ 'ScheduledDeliveryEndDate' ] ; } else { return false ; } }
Returns the latest date in the scheduled delivery window for the specified item .
50,563
public function getTotalSupplyQuantity ( $ i = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> supplyList [ $ i ] [ 'TotalSupplyQuantity' ] ; } else { return false ; } }
Returns the total supply quantity for the specified entry .
50,564
public function getFNSKU ( $ i = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> supplyList [ $ i ] [ 'FNSKU' ] ; } else { return false ; } }
Returns the fulfillment network SKU for the specified entry .
50,565
public function getCondition ( $ i = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> supplyList [ $ i ] [ 'Condition' ] ; } else { return false ; } }
Returns the item condition for the specified entry .
50,566
public function getInStockSupplyQuantity ( $ i = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) ) { return $ this -> supplyList [ $ i ] [ 'InStockSupplyQuantity' ] ; } else { return false ; } }
Returns the in - stock supply quantity for the specified entry .
50,567
public function getEarliestAvailability ( $ i = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) && array_key_exists ( 'EarliestAvailability' , $ this -> supplyList [ $ i ] ) ) { return $ this -> supplyList [ $ i ] [ 'EarliestAvailability' ] ; } else { return false ; } }
Returns the earliest availability for the specified entry .
50,568
public function getEarliestAvailableToPick ( $ i = 0 , $ j = 0 ) { if ( ! isset ( $ this -> supplyList ) ) { return false ; } if ( is_int ( $ i ) && is_numeric ( $ j ) && array_key_exists ( 'SupplyDetail' , $ this -> supplyList [ $ i ] ) ) { return $ this -> supplyList [ $ i ] [ 'SupplyDetail' ] [ $ j ] [ 'EarliestAvai...
Returns the earliest pick timeframe for the specified entry .
50,569
protected function resetRequests ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#FeesEstimateRequestList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Removes request options .
50,570
protected function parseMoney ( $ xml ) { $ r = array ( ) ; $ r [ 'Amount' ] = ( string ) $ xml -> Amount ; $ r [ 'CurrencyCode' ] = ( string ) $ xml -> CurrencyCode ; return $ r ; }
Parses XML for a single money element into an array . This structure is used many times throughout fee estimates .
50,571
protected function parseFeeDetail ( $ xml ) { $ r = array ( ) ; $ r [ 'FeeType' ] = ( string ) $ xml -> FeeType ; $ r [ 'FeeAmount' ] = $ this -> parseMoney ( $ xml -> FeeAmount ) ; if ( isset ( $ xml -> FeePromotion ) ) { $ r [ 'FeePromotion' ] = $ this -> parseMoney ( $ xml -> FeePromotion ) ; } if ( isset ( $ xml ->...
Parses XML for a single fee detail into an array . This structure is used recursively in fee estimates .
50,572
protected function loadCategories ( $ xml ) { if ( ! $ xml -> Self ) { return false ; } $ cnum = 0 ; foreach ( $ xml -> children ( ) as $ x ) { $ this -> data [ 'Categories' ] [ $ cnum ] = $ this -> genHierarchy ( $ x ) ; $ cnum ++ ; } }
Takes in XML data for Categories and parses it for the object to use
50,573
protected function genHierarchy ( $ xml ) { if ( ! $ xml ) { return false ; } $ a = array ( ) ; $ a [ 'ProductCategoryId' ] = ( string ) $ xml -> ProductCategoryId ; $ a [ 'ProductCategoryName' ] = ( string ) $ xml -> ProductCategoryName ; if ( $ xml -> Parent ) { $ a [ 'Parent' ] = $ this -> genHierarchy ( $ xml -> Pa...
Recursively builds the hierarchy array .
50,574
public function fetchItems ( $ token = false ) { if ( ! isset ( $ this -> data [ 'AmazonOrderId' ] ) ) { return false ; } if ( ! is_bool ( $ token ) ) { $ token = false ; } $ items = new AmazonOrderItemList ( $ this -> storeName , $ this -> data [ 'AmazonOrderId' ] , $ this -> mockMode , $ this -> mockFiles , $ this ->...
Fetches items for the order from Amazon .
50,575
public function getOrderTotalAmount ( ) { if ( isset ( $ this -> data [ 'OrderTotal' ] ) && isset ( $ this -> data [ 'OrderTotal' ] [ 'Amount' ] ) ) { return $ this -> data [ 'OrderTotal' ] [ 'Amount' ] ; } else { return false ; } }
Returns just the total cost of the Order .
50,576
public function getPercentShipped ( ) { if ( isset ( $ this -> data [ 'NumberOfItemsShipped' ] ) && isset ( $ this -> data [ 'NumberOfItemsUnshipped' ] ) ) { $ total = $ this -> data [ 'NumberOfItemsShipped' ] + $ this -> data [ 'NumberOfItemsUnshipped' ] ; if ( $ total == 0 ) { return 0 ; } $ ratio = $ this -> data [ ...
Returns the ratio of shipped items to unshipped items .
50,577
public function fetchFeedResult ( ) { if ( ! array_key_exists ( 'FeedSubmissionId' , $ this -> options ) ) { $ this -> log ( "Feed Submission ID must be set in order to fetch it!" , 'Warning' ) ; return false ; } $ url = $ this -> urlbase . $ this -> urlbranch ; $ query = $ this -> genQuery ( ) ; if ( $ this -> mockMod...
Sends a request to Amazon for a feed .
50,578
public function saveFeed ( $ path ) { if ( ! isset ( $ this -> rawFeed ) ) { return false ; } try { file_put_contents ( $ path , $ this -> rawFeed ) ; $ this -> log ( "Successfully saved feed #" . $ this -> options [ 'FeedSubmissionId' ] . " at $path" ) ; } catch ( Exception $ e ) { $ this -> log ( "Unable to save feed...
Saves the raw report data to a path you specify .
50,579
protected function parseXML ( $ xml ) { if ( ! $ xml ) { return false ; } $ xmlP = $ xml -> ListParticipations ; $ xmlM = $ xml -> ListMarketplaces ; foreach ( $ xmlP -> children ( ) as $ x ) { $ this -> participationList [ $ this -> indexP ] [ 'MarketplaceId' ] = ( string ) $ x -> MarketplaceId ; $ this -> participati...
Parses XML response into two arrays .
50,580
public function getMarketplaceId ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'MarketplaceId' ] ; } else { return false ; } }
Returns the marketplace ID for the specified entry .
50,581
public function getName ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'Name' ] ; } else { return false ; } }
Returns the marketplace name for the specified entry .
50,582
public function getCountry ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'Country' ] ; } else { return false ; } }
Returns the country code for the specified entry .
50,583
public function getCurreny ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'Currency' ] ; } else { return false ; } }
Returns the default currency code for the specified entry .
50,584
public function getLanguage ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'Language' ] ; } else { return false ; } }
Returns the default language code for the specified entry .
50,585
public function getDomain ( $ i = 0 ) { if ( ! isset ( $ this -> marketplaceList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> marketplaceList ) ) { return $ this -> marketplaceList [ $ i ] [ 'Domain' ] ; } else { return false ; } }
Returns the domain name for the specified entry .
50,586
public function getSellerId ( $ i = 0 ) { if ( ! isset ( $ this -> participationList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> participationList ) ) { return $ this -> participationList [ $ i ] [ 'SellerId' ] ; } else { return false ; } }
Returns the seller ID for the specified entry .
50,587
public function getSuspensionStatus ( $ i = 0 ) { if ( ! isset ( $ this -> participationList ) ) { return false ; } if ( is_numeric ( $ i ) && array_key_exists ( $ i , $ this -> participationList ) ) { return $ this -> participationList [ $ i ] [ 'Suspended' ] ; } else { return false ; } }
Returns the suspension status for the specified entry .
50,588
protected function resetAttributes ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#Destination.AttributeList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the destination attribute options .
50,589
protected function resetDestinationParams ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#^Destination.#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the destination - specific parameters .
50,590
protected function resetSubscriptionParams ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#Subscription.#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the subscription - specific parameters .
50,591
protected function determineDetailOption ( ) { if ( ! isset ( $ this -> options [ 'IsPartnered' ] ) || ! isset ( $ this -> options [ 'ShipmentType' ] ) ) { $ this -> log ( 'Cannot set transport details without shipment type and partner parameters!' , 'Warning' ) ; return false ; } $ op = 'TransportDetails.' ; if ( $ th...
Determines which of the four possible transport detail parameter prefixes should be used . The parameter to use depends on the partnered and shipment type parameters .
50,592
protected function resetPackages ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#PackageList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the package list parameters .
50,593
public function resetPallets ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#PalletList#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the pallet list parameters .
50,594
protected function resetTransportDetails ( ) { foreach ( $ this -> options as $ op => $ junk ) { if ( preg_match ( "#TransportDetails#" , $ op ) ) { unset ( $ this -> options [ $ op ] ) ; } } }
Resets the transport detail parameters .
50,595
public function sendTransportContents ( ) { if ( ! $ this -> verifySendParams ( ) ) { return false ; } $ this -> prepareSend ( ) ; $ url = $ this -> urlbase . $ this -> urlbranch ; $ query = $ this -> genQuery ( ) ; $ path = $ this -> options [ 'Action' ] . 'Result' ; if ( $ this -> mockMode ) { $ xml = $ this -> fetch...
Sends transport content information for a shipment with Amazon .
50,596
public function getFreightClass ( ) { if ( isset ( $ this -> contents [ 'Details' ] [ 'PreviewFreightClass' ] ) ) { return $ this -> contents [ 'Details' ] [ 'PreviewFreightClass' ] ; } else if ( isset ( $ this -> contents [ 'Details' ] [ 'SellerFreightClass' ] ) ) { return $ this -> contents [ 'Details' ] [ 'SellerFre...
Returns the freight class for the transport request .
50,597
public function getTotalWeight ( $ only = false ) { if ( isset ( $ this -> contents [ 'Details' ] [ 'TotalWeight' ] ) ) { if ( $ only ) { return $ this -> contents [ 'Details' ] [ 'TotalWeight' ] [ 'Value' ] ; } else { return $ this -> contents [ 'Details' ] [ 'TotalWeight' ] ; } } else { return false ; } }
Returns the total weight for the transport request .
50,598
public function getDeclaredValue ( $ only = false ) { if ( isset ( $ this -> contents [ 'Details' ] [ 'SellerDeclaredValue' ] ) ) { if ( $ only ) { return $ this -> contents [ 'Details' ] [ 'SellerDeclaredValue' ] [ 'Value' ] ; } else { return $ this -> contents [ 'Details' ] [ 'SellerDeclaredValue' ] ; } } else { retu...
Returns the seller s declared value for the transport request .
50,599
public function getCalculatedValue ( $ only = false ) { if ( isset ( $ this -> contents [ 'Details' ] [ 'AmazonCalculatedValue' ] ) ) { if ( $ only ) { return $ this -> contents [ 'Details' ] [ 'AmazonCalculatedValue' ] [ 'Value' ] ; } else { return $ this -> contents [ 'Details' ] [ 'AmazonCalculatedValue' ] ; } } els...
Returns Amazon s calculated value for the transport request .