diff --git a/CHANGELOG.md b/CHANGELOG.md index 0119685f6..e31174354 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # CHANGELOG +## 17.0.0 - 2018-06-12 + +### Features + +* Support Catalog API version v1_beta.2.0. + ## 16.0.0 - 2018-05-12 ### Features diff --git a/Makefile b/Makefile index 3bc8125fa..98b1e445f 100644 --- a/Makefile +++ b/Makefile @@ -99,6 +99,10 @@ sync_bus: rsync -rtvu --delete --exclude *BaseService.php ../ebay-api-sdk-php/dist/BusinessPoliciesManagement/src/BusinessPoliciesManagement/ src/BusinessPoliciesManagement/ rsync -rtvu --delete --exclude /Mocks/ --exclude /Services/ ../ebay-api-sdk-php/dist/BusinessPoliciesManagement/test/BusinessPoliciesManagement/ test/BusinessPoliciesManagement/ +sync_catalog: + rsync -rtvu --delete --exclude *BaseService.php ../ebay-api-sdk-php/dist/Catalog/src/Catalog/ src/Catalog/ + rsync -rtvu --delete --exclude /Mocks/ --exclude /Services/ ../ebay-api-sdk-php/dist/Catalog/test/Catalog/ test/Catalog/ + sync_feed: rsync -rtvu --delete --exclude *BaseService.php ../ebay-api-sdk-php/dist/Feed/src/Feed/ src/Feed/ rsync -rtvu --delete --exclude /Mocks/ --exclude /Services/ ../ebay-api-sdk-php/dist/Feed/test/Feed/ test/Feed/ @@ -190,6 +194,7 @@ sync_all: sync_account \ sync_browse \ sync_bulk \ sync_bus \ + sync_catalog \ sync_feedback \ sync_file \ sync_finding \ diff --git a/docs/guide/configuration.rst b/docs/guide/configuration.rst index c3ffab517..1a0f3ed21 100644 --- a/docs/guide/configuration.rst +++ b/docs/guide/configuration.rst @@ -93,7 +93,7 @@ authorization ~~~~~~~~~~~~~ :Type: ``string`` -:Services: ``Account``, ``Analytics``, ``Browse``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Trading``, ``Taxonomy`` +:Services: ``Account``, ``Analytics``, ``Browse``, ``Catalog``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Trading``, ``Taxonomy`` :Required: true, except for the Trading service. All eBay RESTful services use OAuth 2.0 access tokens for application authentication and user authorization. The token passed via ``authorization`` can be either an User or Application token. You must ensure that the token has the require scope for the operation that you are calling. @@ -441,7 +441,7 @@ marketplaceId ~~~~~~~~~~~~~ :Type: ``string`` -:Services: ``Account``, ``Analytics``, ``Browse``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` +:Services: ``Account``, ``Analytics``, ``Browse``, ``Catalog``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` The string identifier for the eBay site your API requests are to be sent to. For example, you would pass the value ``EBAY-UK`` to specify the eBay UK site. @@ -467,7 +467,7 @@ requestLanguage ~~~~~~~~~~~~~~~ :Type: ``string`` -:Services: ``Account``, ``Analytics``, ``Browse``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` +:Services: ``Account``, ``Analytics``, ``Browse``, ``Catalog``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` This configuration option will set the ``Content-Language`` HTTP header for the request. @@ -475,7 +475,7 @@ responseLanguage ~~~~~~~~~~~~~~~~ :Type: ``string`` -:Services: ``Account``, ``Analytics``, ``Browse``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` +:Services: ``Account``, ``Analytics``, ``Browse``, ``Catalog``, ``Feed``, ``Fulfillment``, ``Inventory``, ``Marketing``, ``Metadata``, ``Order``, ``Taxonomy`` This configuration option will set the ``Accept-Language`` HTTP header for the request. diff --git a/src/Catalog/Enums/AspectDataTypeEnum.php b/src/Catalog/Enums/AspectDataTypeEnum.php new file mode 100644 index 000000000..84eb99743 --- /dev/null +++ b/src/Catalog/Enums/AspectDataTypeEnum.php @@ -0,0 +1,19 @@ + 'https://api.sandbox.ebay.com/commerce/catalog', + 'production' => 'https://api.ebay.com/commerce/catalog' + ]; + + /** + * HTTP header constant. The Authentication Token that is used to validate the caller has permission to access the eBay servers. + */ + const HDR_AUTHORIZATION = 'Authorization'; + + /** + * HTTP header constant. The global ID of the eBay site on which the transaction took place. + */ + const HDR_MARKETPLACE_ID = 'X-EBAY-C-MARKETPLACE-ID'; + + /** + * @param array $config Configuration option values. + */ + public function __construct(array $config) + { + parent::__construct($config); + } + + /** + * Returns definitions for each configuration option that is supported. + * + * @return array An associative array of configuration definitions. + */ + public static function getConfigDefinitions() + { + $definitions = parent::getConfigDefinitions(); + + return $definitions + [ + 'apiVersion' => [ + 'valid' => ['string'], + 'default' => \DTS\eBaySDK\Catalog\Services\CatalogService::API_VERSION, + 'required' => true + ], + 'authorization' => [ + 'valid' => ['string'], + 'required' => true + ], + 'marketplaceId' => [ + 'valid' => ['string'] + ] + ]; + } + + /** + * Builds the needed eBay HTTP headers. + * + * @return array An associative array of eBay HTTP headers. + */ + protected function getEbayHeaders() + { + $headers = []; + + // Add required headers first. + $headers[self::HDR_AUTHORIZATION] = 'Bearer '.$this->getConfig('authorization'); + + // Add optional headers. + if ($this->getConfig('marketplaceId')) { + $headers[self::HDR_MARKETPLACE_ID] = $this->getConfig('marketplaceId'); + } + + return $headers; + } +} diff --git a/src/Catalog/Services/CatalogService.php b/src/Catalog/Services/CatalogService.php new file mode 100644 index 000000000..ac8118987 --- /dev/null +++ b/src/Catalog/Services/CatalogService.php @@ -0,0 +1,263 @@ + [ + 'method' => 'GET', + 'resource' => 'product/{epid}', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\GetProductRestResponse', + 'params' => [ + 'epid' => [ + 'valid' => ['string'], + 'required' => true + ] + ] + ], + 'Search' => [ + 'method' => 'GET', + 'resource' => 'product_summary/search', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\SearchRestResponse', + 'params' => [ + 'offset' => [ + 'valid' => ['string'] + ], + 'limit' => [ + 'valid' => ['string'] + ], + 'fieldgroups' => [ + 'valid' => ['string'] + ], + 'aspect_filter' => [ + 'valid' => ['string'] + ], + 'category_ids' => [ + 'valid' => ['string'] + ], + 'mpn' => [ + 'valid' => ['string'] + ], + 'gtin' => [ + 'valid' => ['string'] + ], + 'q' => [ + 'valid' => ['string'] + ] + ] + ], + 'GetProductMetadata' => [ + 'method' => 'GET', + 'resource' => 'get_product_metadata', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\GetProductMetadataRestResponse', + 'params' => [ + 'other_applicable_category_ids' => [ + 'valid' => ['string'] + ], + 'primary_category_id' => [ + 'valid' => ['string'] + ], + 'epid' => [ + 'valid' => ['string'], + 'required' => true + ] + ] + ], + 'GetProductMetadataForCategories' => [ + 'method' => 'GET', + 'resource' => 'get_product_metadata_for_categories', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestResponse', + 'params' => [ + 'other_applicable_category_ids' => [ + 'valid' => ['string'] + ], + 'primary_category_id' => [ + 'valid' => ['string'], + 'required' => true + ] + ] + ], + 'GetChangeRequest' => [ + 'method' => 'GET', + 'resource' => 'change_request/{change_request_id}', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\GetChangeRequestRestResponse', + 'params' => [ + 'change_request_id' => [ + 'valid' => ['string'], + 'required' => true + ] + ] + ], + 'GetChangeRequests' => [ + 'method' => 'GET', + 'resource' => 'change_request', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestResponse', + 'params' => [ + 'offset' => [ + 'valid' => ['string'] + ], + 'limit' => [ + 'valid' => ['string'] + ], + 'filter' => [ + 'valid' => ['string'] + ] + ] + ], + 'CreateChangeRequest' => [ + 'method' => 'PUT', + 'resource' => 'change_request', + 'responseClass' => '\DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestResponse', + 'params' => [ + ] + ] + ]; + + /** + * @param array $config Configuration option values. + */ + public function __construct(array $config = []) + { + parent::__construct($config); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\GetProductRestResponse + */ + public function getProduct(\DTS\eBaySDK\Catalog\Types\GetProductRestRequest $request) + { + return $this->getProductAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function getProductAsync(\DTS\eBaySDK\Catalog\Types\GetProductRestRequest $request) + { + return $this->callOperationAsync('GetProduct', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\SearchRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\SearchRestResponse + */ + public function search(\DTS\eBaySDK\Catalog\Types\SearchRestRequest $request) + { + return $this->searchAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\SearchRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function searchAsync(\DTS\eBaySDK\Catalog\Types\SearchRestRequest $request) + { + return $this->callOperationAsync('Search', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductMetadataRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\GetProductMetadataRestResponse + */ + public function getProductMetadata(\DTS\eBaySDK\Catalog\Types\GetProductMetadataRestRequest $request) + { + return $this->getProductMetadataAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductMetadataRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function getProductMetadataAsync(\DTS\eBaySDK\Catalog\Types\GetProductMetadataRestRequest $request) + { + return $this->callOperationAsync('GetProductMetadata', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestResponse + */ + public function getProductMetadataForCategories(\DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestRequest $request) + { + return $this->getProductMetadataForCategoriesAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function getProductMetadataForCategoriesAsync(\DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestRequest $request) + { + return $this->callOperationAsync('GetProductMetadataForCategories', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetChangeRequestRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\GetChangeRequestRestResponse + */ + public function getChangeRequest(\DTS\eBaySDK\Catalog\Types\GetChangeRequestRestRequest $request) + { + return $this->getChangeRequestAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetChangeRequestRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function getChangeRequestAsync(\DTS\eBaySDK\Catalog\Types\GetChangeRequestRestRequest $request) + { + return $this->callOperationAsync('GetChangeRequest', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestResponse + */ + public function getChangeRequests(\DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestRequest $request) + { + return $this->getChangeRequestsAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function getChangeRequestsAsync(\DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestRequest $request) + { + return $this->callOperationAsync('GetChangeRequests', $request); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestRequest $request + * @return \DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestResponse + */ + public function createChangeRequest(\DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestRequest $request) + { + return $this->createChangeRequestAsync($request)->wait(); + } + + /** + * @param \DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestRequest $request + * @return \GuzzleHttp\Promise\PromiseInterface + */ + public function createChangeRequestAsync(\DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestRequest $request) + { + return $this->callOperationAsync('CreateChangeRequest', $request); + } +} diff --git a/src/Catalog/Types/Aspect.php b/src/Catalog/Types/Aspect.php new file mode 100644 index 000000000..1e5b59bfe --- /dev/null +++ b/src/Catalog/Types/Aspect.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'localizedName' + ], + 'localizedValues' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'localizedValues' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/AspectDistribution.php b/src/Catalog/Types/AspectDistribution.php new file mode 100644 index 000000000..b85e5f74c --- /dev/null +++ b/src/Catalog/Types/AspectDistribution.php @@ -0,0 +1,53 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\AspectValueDistribution', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspectValueDistributions' + ], + 'localizedAspectName' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'localizedAspectName' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/AspectFilter.php b/src/Catalog/Types/AspectFilter.php new file mode 100644 index 000000000..30730d0f0 --- /dev/null +++ b/src/Catalog/Types/AspectFilter.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'categoryId' + ], + 'filters' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\FilterField', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'filters' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/AspectValueDistribution.php b/src/Catalog/Types/AspectValueDistribution.php new file mode 100644 index 000000000..284473c0c --- /dev/null +++ b/src/Catalog/Types/AspectValueDistribution.php @@ -0,0 +1,60 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'localizedAspectValue' + ], + 'matchCount' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'matchCount' + ], + 'refinementHref' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'refinementHref' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CategoryAspect.php b/src/Catalog/Types/CategoryAspect.php new file mode 100644 index 000000000..7d2b50bf0 --- /dev/null +++ b/src/Catalog/Types/CategoryAspect.php @@ -0,0 +1,67 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectHelpText' + ], + 'constraint' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductAspectConstraint', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'constraint' + ], + 'name' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'name' + ], + 'values' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\CategoryAspectValue', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CategoryAspectValue.php b/src/Catalog/Types/CategoryAspectValue.php new file mode 100644 index 000000000..0642e933c --- /dev/null +++ b/src/Catalog/Types/CategoryAspectValue.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ], + 'valueConstraints' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ValueConstraint', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'valueConstraints' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ChangeRequest.php b/src/Catalog/Types/ChangeRequest.php new file mode 100644 index 000000000..c1f23ba6b --- /dev/null +++ b/src/Catalog/Types/ChangeRequest.php @@ -0,0 +1,123 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'changeRequestId' + ], + 'changeRequestStatus' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'changeRequestStatus' + ], + 'changeRequestType' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'changeRequestType' + ], + 'creationDate' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'creationDate' + ], + 'expectedCompletionDate' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'expectedCompletionDate' + ], + 'processResolution' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProcessResolution', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'processResolution' + ], + 'processStatusMessage' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'processStatusMessage' + ], + 'reasonForChangeRequest' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'reasonForChangeRequest' + ], + 'referenceId' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'referenceId' + ], + 'referenceType' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'referenceType' + ], + 'resolutionDate' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'resolutionDate' + ], + 'suggestedProduct' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\SuggestedProduct', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'suggestedProduct' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ConflictingProduct.php b/src/Catalog/Types/ConflictingProduct.php new file mode 100644 index 000000000..a9824249d --- /dev/null +++ b/src/Catalog/Types/ConflictingProduct.php @@ -0,0 +1,67 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'conflictCode' + ], + 'differentiatingAspects' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductAspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'differentiatingAspects' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ], + 'reason' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'reason' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/Correction.php b/src/Catalog/Types/Correction.php new file mode 100644 index 000000000..1aaca6436 --- /dev/null +++ b/src/Catalog/Types/Correction.php @@ -0,0 +1,67 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\CorrectionAspectValues', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectValues' + ], + 'correctionCode' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'correctionCode' + ], + 'productAttribute' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\CorrectionProductAttribute', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productAttribute' + ], + 'reason' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'reason' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CorrectionAspectValue.php b/src/Catalog/Types/CorrectionAspectValue.php new file mode 100644 index 000000000..ff498d6ed --- /dev/null +++ b/src/Catalog/Types/CorrectionAspectValue.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'newValue' + ], + 'value' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CorrectionAspectValues.php b/src/Catalog/Types/CorrectionAspectValues.php new file mode 100644 index 000000000..45c9a5c78 --- /dev/null +++ b/src/Catalog/Types/CorrectionAspectValues.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectName' + ], + 'values' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\CorrectionAspectValue', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CorrectionProductAttribute.php b/src/Catalog/Types/CorrectionProductAttribute.php new file mode 100644 index 000000000..7228a192d --- /dev/null +++ b/src/Catalog/Types/CorrectionProductAttribute.php @@ -0,0 +1,60 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'attributeName' + ], + 'newValue' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'newValue' + ], + 'value' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CreateChangeRequestPayload.php b/src/Catalog/Types/CreateChangeRequestPayload.php new file mode 100644 index 000000000..221737a3b --- /dev/null +++ b/src/Catalog/Types/CreateChangeRequestPayload.php @@ -0,0 +1,74 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'changeRequestType' + ], + 'reasonForChangeRequest' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'reasonForChangeRequest' + ], + 'referenceId' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'referenceId' + ], + 'referenceType' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'referenceType' + ], + 'suggestedProduct' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\SuggestedProduct', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'suggestedProduct' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CreateChangeRequestRestRequest.php b/src/Catalog/Types/CreateChangeRequestRestRequest.php new file mode 100644 index 000000000..fa4c296b6 --- /dev/null +++ b/src/Catalog/Types/CreateChangeRequestRestRequest.php @@ -0,0 +1,39 @@ +setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/CreateChangeRequestRestResponse.php b/src/Catalog/Types/CreateChangeRequestRestResponse.php new file mode 100644 index 000000000..41277e7cb --- /dev/null +++ b/src/Catalog/Types/CreateChangeRequestRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/ErrorDetailV3.php b/src/Catalog/Types/ErrorDetailV3.php new file mode 100644 index 000000000..3791d87ac --- /dev/null +++ b/src/Catalog/Types/ErrorDetailV3.php @@ -0,0 +1,102 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'category' + ], + 'domain' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'domain' + ], + 'errorId' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'errorId' + ], + 'inputRefIds' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'inputRefIds' + ], + 'longMessage' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'longMessage' + ], + 'message' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'message' + ], + 'outputRefIds' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'outputRefIds' + ], + 'parameters' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorParameterV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'parameters' + ], + 'subdomain' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'subdomain' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ErrorParameterV3.php b/src/Catalog/Types/ErrorParameterV3.php new file mode 100644 index 000000000..5ed1131f1 --- /dev/null +++ b/src/Catalog/Types/ErrorParameterV3.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'name' + ], + 'value' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/FilterField.php b/src/Catalog/Types/FilterField.php new file mode 100644 index 000000000..6c581a90b --- /dev/null +++ b/src/Catalog/Types/FilterField.php @@ -0,0 +1,74 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'field' + ], + 'negated' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'negated' + ], + 'range' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\RangeValue', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'range' + ], + 'set' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'set' + ], + 'value' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetChangeRequestRestRequest.php b/src/Catalog/Types/GetChangeRequestRestRequest.php new file mode 100644 index 000000000..5d702a60b --- /dev/null +++ b/src/Catalog/Types/GetChangeRequestRestRequest.php @@ -0,0 +1,46 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'change_request_id' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetChangeRequestRestResponse.php b/src/Catalog/Types/GetChangeRequestRestResponse.php new file mode 100644 index 000000000..d36937748 --- /dev/null +++ b/src/Catalog/Types/GetChangeRequestRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/GetChangeRequestsResponse.php b/src/Catalog/Types/GetChangeRequestsResponse.php new file mode 100644 index 000000000..cf6d2ac82 --- /dev/null +++ b/src/Catalog/Types/GetChangeRequestsResponse.php @@ -0,0 +1,88 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ChangeRequest', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'changeRequests' + ], + 'href' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'href' + ], + 'limit' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'limit' + ], + 'next' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'next' + ], + 'offset' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'offset' + ], + 'prev' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'prev' + ], + 'total' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'total' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetChangeRequestsRestRequest.php b/src/Catalog/Types/GetChangeRequestsRestRequest.php new file mode 100644 index 000000000..b5d589847 --- /dev/null +++ b/src/Catalog/Types/GetChangeRequestsRestRequest.php @@ -0,0 +1,60 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'offset' + ], + 'limit' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'limit' + ], + 'filter' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'filter' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetChangeRequestsRestResponse.php b/src/Catalog/Types/GetChangeRequestsRestResponse.php new file mode 100644 index 000000000..93ed3aa0c --- /dev/null +++ b/src/Catalog/Types/GetChangeRequestsRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/GetProductMetadataForCategoriesRestRequest.php b/src/Catalog/Types/GetProductMetadataForCategoriesRestRequest.php new file mode 100644 index 000000000..9b81e5f39 --- /dev/null +++ b/src/Catalog/Types/GetProductMetadataForCategoriesRestRequest.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'other_applicable_category_ids' + ], + 'primary_category_id' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'primary_category_id' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetProductMetadataForCategoriesRestResponse.php b/src/Catalog/Types/GetProductMetadataForCategoriesRestResponse.php new file mode 100644 index 000000000..f59910d37 --- /dev/null +++ b/src/Catalog/Types/GetProductMetadataForCategoriesRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/GetProductMetadataRestRequest.php b/src/Catalog/Types/GetProductMetadataRestRequest.php new file mode 100644 index 000000000..171b225f1 --- /dev/null +++ b/src/Catalog/Types/GetProductMetadataRestRequest.php @@ -0,0 +1,60 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'other_applicable_category_ids' + ], + 'primary_category_id' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'primary_category_id' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetProductMetadataRestResponse.php b/src/Catalog/Types/GetProductMetadataRestResponse.php new file mode 100644 index 000000000..cd45d8cd2 --- /dev/null +++ b/src/Catalog/Types/GetProductMetadataRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/GetProductRestRequest.php b/src/Catalog/Types/GetProductRestRequest.php new file mode 100644 index 000000000..f06f147bd --- /dev/null +++ b/src/Catalog/Types/GetProductRestRequest.php @@ -0,0 +1,46 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/GetProductRestResponse.php b/src/Catalog/Types/GetProductRestResponse.php new file mode 100644 index 000000000..1ec184e8f --- /dev/null +++ b/src/Catalog/Types/GetProductRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/Image.php b/src/Catalog/Types/Image.php new file mode 100644 index 000000000..7d9eccdf4 --- /dev/null +++ b/src/Catalog/Types/Image.php @@ -0,0 +1,60 @@ + [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'height' + ], + 'imageUrl' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'imageUrl' + ], + 'width' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'width' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProcessResolution.php b/src/Catalog/Types/ProcessResolution.php new file mode 100644 index 000000000..d3f9864f1 --- /dev/null +++ b/src/Catalog/Types/ProcessResolution.php @@ -0,0 +1,74 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ConflictingProduct', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'conflictingProducts' + ], + 'corrections' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Correction', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'corrections' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ], + 'productHref' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productHref' + ], + 'violations' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Violation', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'violations' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/Product.php b/src/Catalog/Types/Product.php new file mode 100644 index 000000000..28ba67fd6 --- /dev/null +++ b/src/Catalog/Types/Product.php @@ -0,0 +1,151 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Image', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'additionalImages' + ], + 'aspects' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Aspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspects' + ], + 'brand' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'brand' + ], + 'description' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'description' + ], + 'ean' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'ean' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ], + 'gtin' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'gtin' + ], + 'image' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Image', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'image' + ], + 'isbn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'isbn' + ], + 'mpn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'mpn' + ], + 'otherApplicableCategoryIds' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'otherApplicableCategoryIds' + ], + 'primaryCategoryId' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'primaryCategoryId' + ], + 'productWebUrl' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productWebUrl' + ], + 'title' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'title' + ], + 'upc' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'upc' + ], + 'version' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'version' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductAspect.php b/src/Catalog/Types/ProductAspect.php new file mode 100644 index 000000000..17debf936 --- /dev/null +++ b/src/Catalog/Types/ProductAspect.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'name' + ], + 'values' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductAspectConstraint.php b/src/Catalog/Types/ProductAspectConstraint.php new file mode 100644 index 000000000..767c71a2d --- /dev/null +++ b/src/Catalog/Types/ProductAspectConstraint.php @@ -0,0 +1,74 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectDataType' + ], + 'aspectFormat' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectFormat' + ], + 'aspectMode' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectMode' + ], + 'aspectRequired' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectRequired' + ], + 'productToAspectCardinality' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productToAspectCardinality' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductAspectValue.php b/src/Catalog/Types/ProductAspectValue.php new file mode 100644 index 000000000..e014bda51 --- /dev/null +++ b/src/Catalog/Types/ProductAspectValue.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'value' + ], + 'valueConstraints' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ValueConstraint', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'valueConstraints' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductIdentifier.php b/src/Catalog/Types/ProductIdentifier.php new file mode 100644 index 000000000..a6f9eb366 --- /dev/null +++ b/src/Catalog/Types/ProductIdentifier.php @@ -0,0 +1,53 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifierConstraint', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'constraint' + ], + 'values' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductIdentifierConstraint.php b/src/Catalog/Types/ProductIdentifierConstraint.php new file mode 100644 index 000000000..7c10f39f6 --- /dev/null +++ b/src/Catalog/Types/ProductIdentifierConstraint.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'mode' + ], + 'required' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'required' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductIdentifierForProductMetadata.php b/src/Catalog/Types/ProductIdentifierForProductMetadata.php new file mode 100644 index 000000000..fd8495a8e --- /dev/null +++ b/src/Catalog/Types/ProductIdentifierForProductMetadata.php @@ -0,0 +1,60 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifierConstraint', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'constraint' + ], + 'valueAssociatedWithProduct' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'valueAssociatedWithProduct' + ], + 'values' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductMetadata.php b/src/Catalog/Types/ProductMetadata.php new file mode 100644 index 000000000..284699d82 --- /dev/null +++ b/src/Catalog/Types/ProductMetadata.php @@ -0,0 +1,60 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductMetadataAspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspects' + ], + 'brand' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifierForProductMetadata', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'brand' + ], + 'mpn' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifierForProductMetadata', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'mpn' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductMetadataAspect.php b/src/Catalog/Types/ProductMetadataAspect.php new file mode 100644 index 000000000..aeaf48696 --- /dev/null +++ b/src/Catalog/Types/ProductMetadataAspect.php @@ -0,0 +1,81 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectHelpText' + ], + 'constraint' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductAspectConstraint', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'constraint' + ], + 'droppable' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'droppable' + ], + 'name' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'name' + ], + 'values' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductAspectValue', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ], + 'valuesAssociatedWithProduct' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'valuesAssociatedWithProduct' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductMetadataForCategories.php b/src/Catalog/Types/ProductMetadataForCategories.php new file mode 100644 index 000000000..bf05c3eeb --- /dev/null +++ b/src/Catalog/Types/ProductMetadataForCategories.php @@ -0,0 +1,60 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\CategoryAspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspects' + ], + 'brand' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifier', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'brand' + ], + 'mpn' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductIdentifier', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'mpn' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductSearchResponse.php b/src/Catalog/Types/ProductSearchResponse.php new file mode 100644 index 000000000..52a9a9c37 --- /dev/null +++ b/src/Catalog/Types/ProductSearchResponse.php @@ -0,0 +1,95 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'href' + ], + 'limit' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'limit' + ], + 'next' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'next' + ], + 'offset' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'offset' + ], + 'prev' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'prev' + ], + 'productSummaries' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ProductSummary', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'productSummaries' + ], + 'refinement' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Refinement', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'refinement' + ], + 'total' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'total' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ProductSummary.php b/src/Catalog/Types/ProductSummary.php new file mode 100644 index 000000000..3e2a5e80f --- /dev/null +++ b/src/Catalog/Types/ProductSummary.php @@ -0,0 +1,137 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Image', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'additionalImages' + ], + 'aspects' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Aspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspects' + ], + 'brand' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'brand' + ], + 'description' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'description' + ], + 'ean' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'ean' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ], + 'gtin' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'gtin' + ], + 'image' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Image', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'image' + ], + 'isbn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'isbn' + ], + 'mpn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'mpn' + ], + 'productHref' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productHref' + ], + 'productWebUrl' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productWebUrl' + ], + 'title' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'title' + ], + 'upc' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'upc' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/RangeValue.php b/src/Catalog/Types/RangeValue.php new file mode 100644 index 000000000..96e26bdd1 --- /dev/null +++ b/src/Catalog/Types/RangeValue.php @@ -0,0 +1,74 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'end' + ], + 'exclusiveEnd' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'exclusiveEnd' + ], + 'exclusiveStart' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'exclusiveStart' + ], + 'range' => [ + 'type' => 'boolean', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'range' + ], + 'start' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'start' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/Refinement.php b/src/Catalog/Types/Refinement.php new file mode 100644 index 000000000..4ac9d01f0 --- /dev/null +++ b/src/Catalog/Types/Refinement.php @@ -0,0 +1,53 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\AspectDistribution', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspectDistributions' + ], + 'dominantCategoryId' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'dominantCategoryId' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/SearchRestRequest.php b/src/Catalog/Types/SearchRestRequest.php new file mode 100644 index 000000000..18eccef1b --- /dev/null +++ b/src/Catalog/Types/SearchRestRequest.php @@ -0,0 +1,95 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'offset' + ], + 'limit' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'limit' + ], + 'fieldgroups' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'fieldgroups' + ], + 'aspect_filter' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspect_filter' + ], + 'category_ids' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'category_ids' + ], + 'mpn' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'mpn' + ], + 'gtin' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'gtin' + ], + 'q' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'q' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/SearchRestResponse.php b/src/Catalog/Types/SearchRestResponse.php new file mode 100644 index 000000000..2e0f410aa --- /dev/null +++ b/src/Catalog/Types/SearchRestResponse.php @@ -0,0 +1,65 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'errors' + ], + 'warnings' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ErrorDetailV3', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'warnings' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + * @param int $statusCode Status code + * @param array $headers HTTP Response headers. + */ + public function __construct(array $values = [], $statusCode = 200, array $headers = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + + $this->statusCode = (int)$statusCode; + + $this->setHeaders($headers); + } +} diff --git a/src/Catalog/Types/SuggestedProduct.php b/src/Catalog/Types/SuggestedProduct.php new file mode 100644 index 000000000..ac90f5746 --- /dev/null +++ b/src/Catalog/Types/SuggestedProduct.php @@ -0,0 +1,137 @@ + [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'additionalImageUrls' + ], + 'aspects' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\Aspect', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspects' + ], + 'brand' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'brand' + ], + 'description' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'description' + ], + 'ean' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'ean' + ], + 'epid' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'epid' + ], + 'imageUrl' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'imageUrl' + ], + 'isbn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'isbn' + ], + 'mpn' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'mpn' + ], + 'otherApplicableCategoryIds' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'otherApplicableCategoryIds' + ], + 'primaryCategoryId' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'primaryCategoryId' + ], + 'title' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'title' + ], + 'upc' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'upc' + ], + 'version' => [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'version' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ValueConstraint.php b/src/Catalog/Types/ValueConstraint.php new file mode 100644 index 000000000..d59c03ec4 --- /dev/null +++ b/src/Catalog/Types/ValueConstraint.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'applicableForAspectName' + ], + 'applicableForAspectValues' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'applicableForAspectValues' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/Violation.php b/src/Catalog/Types/Violation.php new file mode 100644 index 000000000..692a06b57 --- /dev/null +++ b/src/Catalog/Types/Violation.php @@ -0,0 +1,67 @@ + [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ViolationAspectValues', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'aspectsValues' + ], + 'productAttribute' => [ + 'type' => 'DTS\eBaySDK\Catalog\Types\ViolationProductAttribute', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'productAttribute' + ], + 'reason' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'reason' + ], + 'violationCode' => [ + 'type' => 'integer', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'violationCode' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ViolationAspectValues.php b/src/Catalog/Types/ViolationAspectValues.php new file mode 100644 index 000000000..963e978ed --- /dev/null +++ b/src/Catalog/Types/ViolationAspectValues.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'aspectName' + ], + 'values' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Catalog/Types/ViolationProductAttribute.php b/src/Catalog/Types/ViolationProductAttribute.php new file mode 100644 index 000000000..4ed9be37d --- /dev/null +++ b/src/Catalog/Types/ViolationProductAttribute.php @@ -0,0 +1,53 @@ + [ + 'type' => 'string', + 'repeatable' => false, + 'attribute' => false, + 'elementName' => 'name' + ], + 'values' => [ + 'type' => 'string', + 'repeatable' => true, + 'attribute' => false, + 'elementName' => 'values' + ] + ]; + + /** + * @param array $values Optional properties and values to assign to the object. + */ + public function __construct(array $values = []) + { + list($parentValues, $childValues) = self::getParentValues(self::$propertyTypes, $values); + + parent::__construct($parentValues); + + if (!array_key_exists(__CLASS__, self::$properties)) { + self::$properties[__CLASS__] = array_merge(self::$properties[get_parent_class()], self::$propertyTypes); + } + + $this->setValues(__CLASS__, $childValues); + } +} diff --git a/src/Sdk.php b/src/Sdk.php index 005de9745..a38499aa4 100644 --- a/src/Sdk.php +++ b/src/Sdk.php @@ -30,7 +30,7 @@ */ class Sdk { - const VERSION = '16.0.0'; + const VERSION = '17.0.0'; /** * @var bool Controls if the SDK should enforce strict types diff --git a/test/Catalog/Enums/AspectDataTypeEnumTest.php b/test/Catalog/Enums/AspectDataTypeEnumTest.php new file mode 100644 index 000000000..8eb23084c --- /dev/null +++ b/test/Catalog/Enums/AspectDataTypeEnumTest.php @@ -0,0 +1,28 @@ +obj = new AspectDataTypeEnum(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\AspectDataTypeEnum', $this->obj); + } +} diff --git a/test/Catalog/Enums/AspectModeEnumTest.php b/test/Catalog/Enums/AspectModeEnumTest.php new file mode 100644 index 000000000..ccef94fa4 --- /dev/null +++ b/test/Catalog/Enums/AspectModeEnumTest.php @@ -0,0 +1,28 @@ +obj = new AspectModeEnum(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\AspectModeEnum', $this->obj); + } +} diff --git a/test/Catalog/Enums/ChangeRequestStatusTest.php b/test/Catalog/Enums/ChangeRequestStatusTest.php new file mode 100644 index 000000000..c8eaa4444 --- /dev/null +++ b/test/Catalog/Enums/ChangeRequestStatusTest.php @@ -0,0 +1,28 @@ +obj = new ChangeRequestStatus(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\ChangeRequestStatus', $this->obj); + } +} diff --git a/test/Catalog/Enums/ChangeRequestTypeTest.php b/test/Catalog/Enums/ChangeRequestTypeTest.php new file mode 100644 index 000000000..69e0803d3 --- /dev/null +++ b/test/Catalog/Enums/ChangeRequestTypeTest.php @@ -0,0 +1,28 @@ +obj = new ChangeRequestType(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\ChangeRequestType', $this->obj); + } +} diff --git a/test/Catalog/Enums/ItemToAspectCardinalityEnumTest.php b/test/Catalog/Enums/ItemToAspectCardinalityEnumTest.php new file mode 100644 index 000000000..f3f0b5ae4 --- /dev/null +++ b/test/Catalog/Enums/ItemToAspectCardinalityEnumTest.php @@ -0,0 +1,28 @@ +obj = new ItemToAspectCardinalityEnum(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\ItemToAspectCardinalityEnum', $this->obj); + } +} diff --git a/test/Catalog/Enums/ProductAttributeNameTest.php b/test/Catalog/Enums/ProductAttributeNameTest.php new file mode 100644 index 000000000..1db9cc812 --- /dev/null +++ b/test/Catalog/Enums/ProductAttributeNameTest.php @@ -0,0 +1,28 @@ +obj = new ProductAttributeName(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\ProductAttributeName', $this->obj); + } +} diff --git a/test/Catalog/Enums/ReferenceTypeTest.php b/test/Catalog/Enums/ReferenceTypeTest.php new file mode 100644 index 000000000..bd5c8f82c --- /dev/null +++ b/test/Catalog/Enums/ReferenceTypeTest.php @@ -0,0 +1,28 @@ +obj = new ReferenceType(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Enums\ReferenceType', $this->obj); + } +} diff --git a/test/Catalog/Mocks/Service.php b/test/Catalog/Mocks/Service.php new file mode 100644 index 000000000..a35de2f6a --- /dev/null +++ b/test/Catalog/Mocks/Service.php @@ -0,0 +1,27 @@ + [ + 'method' => 'GET', + 'resource' => 'item/{item_id}', + 'responseClass' => '\DTS\eBaySDK\Test\Mocks\ComplexClass', + 'params' => [ + ] + ] + ]; + + public function __construct(array $config) + { + parent::__construct($config); + } + + public function testOperation() + { + return $this->callOperationAsync('testOperation', new ComplexClass())->wait(); + } +} diff --git a/test/Catalog/Services/ServiceTest.php b/test/Catalog/Services/ServiceTest.php new file mode 100644 index 000000000..471cced22 --- /dev/null +++ b/test/Catalog/Services/ServiceTest.php @@ -0,0 +1,68 @@ +assertArrayHasKey('apiVersion', $d); + $this->assertEquals([ + 'valid' => ['string'], + 'default' => CatalogService::API_VERSION, + 'required' => true + ], $d['apiVersion']); + + $this->assertArrayHasKey('authorization', $d); + $this->assertEquals([ + 'valid' => ['string'], + 'required' => true + ], $d['authorization']); + + $this->assertArrayHasKey('marketplaceId', $d); + $this->assertEquals([ + 'valid' => ['string'] + ], $d['marketplaceId']); + } + + public function testRequiredEbayHeaders() + { + $h = new HttpRestHandler(); + + $s = new Service([ + 'authorization' => '321', + 'httpHandler' => $h + ]); + + $s->testOperation(); + + // Test required headers first. + $this->assertArrayHasKey(CatalogBaseService::HDR_AUTHORIZATION, $h->headers); + $this->assertEquals('Bearer 321', $h->headers[CatalogBaseService::HDR_AUTHORIZATION]); + + // Test that optional headers have not been set until they have been configured. + $this->assertArrayNotHasKey(CatalogBaseService::HDR_MARKETPLACE_ID, $h->headers); + } + + public function testOptionalEbayHeaders() + { + $h = new HttpRestHandler(); + + $s = new Service([ + 'authorization' => '321', + 'marketplaceId' => '123', + 'httpHandler' => $h + ]); + + $s->testOperation(); + + $this->assertArrayHasKey(CatalogBaseService::HDR_MARKETPLACE_ID, $h->headers); + $this->assertEquals('123', $h->headers[CatalogBaseService::HDR_MARKETPLACE_ID]); + } +} diff --git a/test/Catalog/Types/AspectDistributionTest.php b/test/Catalog/Types/AspectDistributionTest.php new file mode 100644 index 000000000..2e48f1891 --- /dev/null +++ b/test/Catalog/Types/AspectDistributionTest.php @@ -0,0 +1,33 @@ +obj = new AspectDistribution(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\AspectDistribution', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/AspectFilterTest.php b/test/Catalog/Types/AspectFilterTest.php new file mode 100644 index 000000000..b31599c83 --- /dev/null +++ b/test/Catalog/Types/AspectFilterTest.php @@ -0,0 +1,33 @@ +obj = new AspectFilter(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\AspectFilter', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/AspectTest.php b/test/Catalog/Types/AspectTest.php new file mode 100644 index 000000000..d71b37011 --- /dev/null +++ b/test/Catalog/Types/AspectTest.php @@ -0,0 +1,33 @@ +obj = new Aspect(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Aspect', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/AspectValueDistributionTest.php b/test/Catalog/Types/AspectValueDistributionTest.php new file mode 100644 index 000000000..7f9c55240 --- /dev/null +++ b/test/Catalog/Types/AspectValueDistributionTest.php @@ -0,0 +1,33 @@ +obj = new AspectValueDistribution(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\AspectValueDistribution', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CategoryAspectTest.php b/test/Catalog/Types/CategoryAspectTest.php new file mode 100644 index 000000000..a36cf0ac4 --- /dev/null +++ b/test/Catalog/Types/CategoryAspectTest.php @@ -0,0 +1,33 @@ +obj = new CategoryAspect(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CategoryAspect', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CategoryAspectValueTest.php b/test/Catalog/Types/CategoryAspectValueTest.php new file mode 100644 index 000000000..837b08a81 --- /dev/null +++ b/test/Catalog/Types/CategoryAspectValueTest.php @@ -0,0 +1,33 @@ +obj = new CategoryAspectValue(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CategoryAspectValue', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ChangeRequestTest.php b/test/Catalog/Types/ChangeRequestTest.php new file mode 100644 index 000000000..66cf67e81 --- /dev/null +++ b/test/Catalog/Types/ChangeRequestTest.php @@ -0,0 +1,33 @@ +obj = new ChangeRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ChangeRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ConflictingProductTest.php b/test/Catalog/Types/ConflictingProductTest.php new file mode 100644 index 000000000..81c4f559d --- /dev/null +++ b/test/Catalog/Types/ConflictingProductTest.php @@ -0,0 +1,33 @@ +obj = new ConflictingProduct(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ConflictingProduct', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CorrectionAspectValueTest.php b/test/Catalog/Types/CorrectionAspectValueTest.php new file mode 100644 index 000000000..b1bdf78d7 --- /dev/null +++ b/test/Catalog/Types/CorrectionAspectValueTest.php @@ -0,0 +1,33 @@ +obj = new CorrectionAspectValue(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CorrectionAspectValue', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CorrectionAspectValuesTest.php b/test/Catalog/Types/CorrectionAspectValuesTest.php new file mode 100644 index 000000000..746361777 --- /dev/null +++ b/test/Catalog/Types/CorrectionAspectValuesTest.php @@ -0,0 +1,33 @@ +obj = new CorrectionAspectValues(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CorrectionAspectValues', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CorrectionProductAttributeTest.php b/test/Catalog/Types/CorrectionProductAttributeTest.php new file mode 100644 index 000000000..9fb508e5a --- /dev/null +++ b/test/Catalog/Types/CorrectionProductAttributeTest.php @@ -0,0 +1,33 @@ +obj = new CorrectionProductAttribute(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CorrectionProductAttribute', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CorrectionTest.php b/test/Catalog/Types/CorrectionTest.php new file mode 100644 index 000000000..cfa1572ad --- /dev/null +++ b/test/Catalog/Types/CorrectionTest.php @@ -0,0 +1,33 @@ +obj = new Correction(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Correction', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CreateChangeRequestPayloadTest.php b/test/Catalog/Types/CreateChangeRequestPayloadTest.php new file mode 100644 index 000000000..32f612476 --- /dev/null +++ b/test/Catalog/Types/CreateChangeRequestPayloadTest.php @@ -0,0 +1,33 @@ +obj = new CreateChangeRequestPayload(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CreateChangeRequestPayload', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/CreateChangeRequestRestRequestTest.php b/test/Catalog/Types/CreateChangeRequestRestRequestTest.php new file mode 100644 index 000000000..cf8b37243 --- /dev/null +++ b/test/Catalog/Types/CreateChangeRequestRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new CreateChangeRequestRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestRequest', $this->obj); + } + + public function testExtendsCreateChangeRequestPayload() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CreateChangeRequestPayload', $this->obj); + } +} diff --git a/test/Catalog/Types/CreateChangeRequestRestResponseTest.php b/test/Catalog/Types/CreateChangeRequestRestResponseTest.php new file mode 100644 index 000000000..95576258f --- /dev/null +++ b/test/Catalog/Types/CreateChangeRequestRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new CreateChangeRequestRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\CreateChangeRequestRestResponse', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ErrorDetailV3Test.php b/test/Catalog/Types/ErrorDetailV3Test.php new file mode 100644 index 000000000..353892a5d --- /dev/null +++ b/test/Catalog/Types/ErrorDetailV3Test.php @@ -0,0 +1,33 @@ +obj = new ErrorDetailV3(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ErrorDetailV3', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ErrorParameterV3Test.php b/test/Catalog/Types/ErrorParameterV3Test.php new file mode 100644 index 000000000..7d772746a --- /dev/null +++ b/test/Catalog/Types/ErrorParameterV3Test.php @@ -0,0 +1,33 @@ +obj = new ErrorParameterV3(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ErrorParameterV3', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/FilterFieldTest.php b/test/Catalog/Types/FilterFieldTest.php new file mode 100644 index 000000000..489d39041 --- /dev/null +++ b/test/Catalog/Types/FilterFieldTest.php @@ -0,0 +1,33 @@ +obj = new FilterField(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\FilterField', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetChangeRequestRestRequestTest.php b/test/Catalog/Types/GetChangeRequestRestRequestTest.php new file mode 100644 index 000000000..3613bd568 --- /dev/null +++ b/test/Catalog/Types/GetChangeRequestRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new GetChangeRequestRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetChangeRequestRestResponseTest.php b/test/Catalog/Types/GetChangeRequestRestResponseTest.php new file mode 100644 index 000000000..f6bc04b87 --- /dev/null +++ b/test/Catalog/Types/GetChangeRequestRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetChangeRequestRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestRestResponse', $this->obj); + } + + public function testExtendsChangeRequest() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ChangeRequest', $this->obj); + } +} diff --git a/test/Catalog/Types/GetChangeRequestsResponseTest.php b/test/Catalog/Types/GetChangeRequestsResponseTest.php new file mode 100644 index 000000000..5c4d95fb0 --- /dev/null +++ b/test/Catalog/Types/GetChangeRequestsResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetChangeRequestsResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestsResponse', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetChangeRequestsRestRequestTest.php b/test/Catalog/Types/GetChangeRequestsRestRequestTest.php new file mode 100644 index 000000000..3cb90249c --- /dev/null +++ b/test/Catalog/Types/GetChangeRequestsRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new GetChangeRequestsRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetChangeRequestsRestResponseTest.php b/test/Catalog/Types/GetChangeRequestsRestResponseTest.php new file mode 100644 index 000000000..827a4e460 --- /dev/null +++ b/test/Catalog/Types/GetChangeRequestsRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetChangeRequestsRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestsRestResponse', $this->obj); + } + + public function testExtendsGetChangeRequestsResponse() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetChangeRequestsResponse', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductMetadataForCategoriesRestRequestTest.php b/test/Catalog/Types/GetProductMetadataForCategoriesRestRequestTest.php new file mode 100644 index 000000000..069cab3d8 --- /dev/null +++ b/test/Catalog/Types/GetProductMetadataForCategoriesRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new GetProductMetadataForCategoriesRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductMetadataForCategoriesRestResponseTest.php b/test/Catalog/Types/GetProductMetadataForCategoriesRestResponseTest.php new file mode 100644 index 000000000..07256d44a --- /dev/null +++ b/test/Catalog/Types/GetProductMetadataForCategoriesRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetProductMetadataForCategoriesRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductMetadataForCategoriesRestResponse', $this->obj); + } + + public function testExtendsProductMetadataForCategories() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductMetadataForCategories', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductMetadataRestRequestTest.php b/test/Catalog/Types/GetProductMetadataRestRequestTest.php new file mode 100644 index 000000000..e23dd97a1 --- /dev/null +++ b/test/Catalog/Types/GetProductMetadataRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new GetProductMetadataRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductMetadataRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductMetadataRestResponseTest.php b/test/Catalog/Types/GetProductMetadataRestResponseTest.php new file mode 100644 index 000000000..87689afd7 --- /dev/null +++ b/test/Catalog/Types/GetProductMetadataRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetProductMetadataRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductMetadataRestResponse', $this->obj); + } + + public function testExtendsProductMetadata() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductMetadata', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductRestRequestTest.php b/test/Catalog/Types/GetProductRestRequestTest.php new file mode 100644 index 000000000..dadfcc997 --- /dev/null +++ b/test/Catalog/Types/GetProductRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new GetProductRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/GetProductRestResponseTest.php b/test/Catalog/Types/GetProductRestResponseTest.php new file mode 100644 index 000000000..137e672ae --- /dev/null +++ b/test/Catalog/Types/GetProductRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new GetProductRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\GetProductRestResponse', $this->obj); + } + + public function testExtendsProduct() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Product', $this->obj); + } +} diff --git a/test/Catalog/Types/ImageTest.php b/test/Catalog/Types/ImageTest.php new file mode 100644 index 000000000..3f58b6fa3 --- /dev/null +++ b/test/Catalog/Types/ImageTest.php @@ -0,0 +1,33 @@ +obj = new Image(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Image', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProcessResolutionTest.php b/test/Catalog/Types/ProcessResolutionTest.php new file mode 100644 index 000000000..d1bf65ed8 --- /dev/null +++ b/test/Catalog/Types/ProcessResolutionTest.php @@ -0,0 +1,33 @@ +obj = new ProcessResolution(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProcessResolution', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductAspectConstraintTest.php b/test/Catalog/Types/ProductAspectConstraintTest.php new file mode 100644 index 000000000..57b967b76 --- /dev/null +++ b/test/Catalog/Types/ProductAspectConstraintTest.php @@ -0,0 +1,33 @@ +obj = new ProductAspectConstraint(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductAspectConstraint', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductAspectTest.php b/test/Catalog/Types/ProductAspectTest.php new file mode 100644 index 000000000..6ce58530d --- /dev/null +++ b/test/Catalog/Types/ProductAspectTest.php @@ -0,0 +1,33 @@ +obj = new ProductAspect(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductAspect', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductAspectValueTest.php b/test/Catalog/Types/ProductAspectValueTest.php new file mode 100644 index 000000000..20b79f684 --- /dev/null +++ b/test/Catalog/Types/ProductAspectValueTest.php @@ -0,0 +1,33 @@ +obj = new ProductAspectValue(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductAspectValue', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductIdentifierConstraintTest.php b/test/Catalog/Types/ProductIdentifierConstraintTest.php new file mode 100644 index 000000000..43e777955 --- /dev/null +++ b/test/Catalog/Types/ProductIdentifierConstraintTest.php @@ -0,0 +1,33 @@ +obj = new ProductIdentifierConstraint(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductIdentifierConstraint', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductIdentifierForProductMetadataTest.php b/test/Catalog/Types/ProductIdentifierForProductMetadataTest.php new file mode 100644 index 000000000..ad966a613 --- /dev/null +++ b/test/Catalog/Types/ProductIdentifierForProductMetadataTest.php @@ -0,0 +1,33 @@ +obj = new ProductIdentifierForProductMetadata(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductIdentifierForProductMetadata', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductIdentifierTest.php b/test/Catalog/Types/ProductIdentifierTest.php new file mode 100644 index 000000000..24ca2c7a5 --- /dev/null +++ b/test/Catalog/Types/ProductIdentifierTest.php @@ -0,0 +1,33 @@ +obj = new ProductIdentifier(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductIdentifier', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductMetadataAspectTest.php b/test/Catalog/Types/ProductMetadataAspectTest.php new file mode 100644 index 000000000..5db74fc52 --- /dev/null +++ b/test/Catalog/Types/ProductMetadataAspectTest.php @@ -0,0 +1,33 @@ +obj = new ProductMetadataAspect(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductMetadataAspect', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductMetadataForCategoriesTest.php b/test/Catalog/Types/ProductMetadataForCategoriesTest.php new file mode 100644 index 000000000..27bcf116e --- /dev/null +++ b/test/Catalog/Types/ProductMetadataForCategoriesTest.php @@ -0,0 +1,33 @@ +obj = new ProductMetadataForCategories(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductMetadataForCategories', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductMetadataTest.php b/test/Catalog/Types/ProductMetadataTest.php new file mode 100644 index 000000000..cec0f96a3 --- /dev/null +++ b/test/Catalog/Types/ProductMetadataTest.php @@ -0,0 +1,33 @@ +obj = new ProductMetadata(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductMetadata', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductSearchResponseTest.php b/test/Catalog/Types/ProductSearchResponseTest.php new file mode 100644 index 000000000..fa62d4be9 --- /dev/null +++ b/test/Catalog/Types/ProductSearchResponseTest.php @@ -0,0 +1,33 @@ +obj = new ProductSearchResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductSearchResponse', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductSummaryTest.php b/test/Catalog/Types/ProductSummaryTest.php new file mode 100644 index 000000000..556aad397 --- /dev/null +++ b/test/Catalog/Types/ProductSummaryTest.php @@ -0,0 +1,33 @@ +obj = new ProductSummary(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductSummary', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ProductTest.php b/test/Catalog/Types/ProductTest.php new file mode 100644 index 000000000..5f833ce7f --- /dev/null +++ b/test/Catalog/Types/ProductTest.php @@ -0,0 +1,33 @@ +obj = new Product(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Product', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/RangeValueTest.php b/test/Catalog/Types/RangeValueTest.php new file mode 100644 index 000000000..2aa9d52e6 --- /dev/null +++ b/test/Catalog/Types/RangeValueTest.php @@ -0,0 +1,33 @@ +obj = new RangeValue(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\RangeValue', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/RefinementTest.php b/test/Catalog/Types/RefinementTest.php new file mode 100644 index 000000000..06165b7ac --- /dev/null +++ b/test/Catalog/Types/RefinementTest.php @@ -0,0 +1,33 @@ +obj = new Refinement(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Refinement', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/SearchRestRequestTest.php b/test/Catalog/Types/SearchRestRequestTest.php new file mode 100644 index 000000000..07cf62818 --- /dev/null +++ b/test/Catalog/Types/SearchRestRequestTest.php @@ -0,0 +1,33 @@ +obj = new SearchRestRequest(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\SearchRestRequest', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/SearchRestResponseTest.php b/test/Catalog/Types/SearchRestResponseTest.php new file mode 100644 index 000000000..3f4c7f23a --- /dev/null +++ b/test/Catalog/Types/SearchRestResponseTest.php @@ -0,0 +1,33 @@ +obj = new SearchRestResponse(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\SearchRestResponse', $this->obj); + } + + public function testExtendsProductSearchResponse() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ProductSearchResponse', $this->obj); + } +} diff --git a/test/Catalog/Types/SuggestedProductTest.php b/test/Catalog/Types/SuggestedProductTest.php new file mode 100644 index 000000000..bcd5c8ff5 --- /dev/null +++ b/test/Catalog/Types/SuggestedProductTest.php @@ -0,0 +1,33 @@ +obj = new SuggestedProduct(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\SuggestedProduct', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ValueConstraintTest.php b/test/Catalog/Types/ValueConstraintTest.php new file mode 100644 index 000000000..015514717 --- /dev/null +++ b/test/Catalog/Types/ValueConstraintTest.php @@ -0,0 +1,33 @@ +obj = new ValueConstraint(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ValueConstraint', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ViolationAspectValuesTest.php b/test/Catalog/Types/ViolationAspectValuesTest.php new file mode 100644 index 000000000..edc77bd8e --- /dev/null +++ b/test/Catalog/Types/ViolationAspectValuesTest.php @@ -0,0 +1,33 @@ +obj = new ViolationAspectValues(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ViolationAspectValues', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ViolationProductAttributeTest.php b/test/Catalog/Types/ViolationProductAttributeTest.php new file mode 100644 index 000000000..a7e193b12 --- /dev/null +++ b/test/Catalog/Types/ViolationProductAttributeTest.php @@ -0,0 +1,33 @@ +obj = new ViolationProductAttribute(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\ViolationProductAttribute', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +} diff --git a/test/Catalog/Types/ViolationTest.php b/test/Catalog/Types/ViolationTest.php new file mode 100644 index 000000000..4d70132d1 --- /dev/null +++ b/test/Catalog/Types/ViolationTest.php @@ -0,0 +1,33 @@ +obj = new Violation(); + } + + public function testCanBeCreated() + { + $this->assertInstanceOf('\DTS\eBaySDK\Catalog\Types\Violation', $this->obj); + } + + public function testExtendsBaseType() + { + $this->assertInstanceOf('\DTS\eBaySDK\Types\BaseType', $this->obj); + } +}