Class ExternalProductAssetProvider<T extends ProductAsset>
java.lang.Object
com.broadleafcommerce.dataexchange.service.provider.external.AbstractRestApiExternalProvider
com.broadleafcommerce.dataexchange.service.provider.external.ExternalProductAssetProvider<T>
- All Implemented Interfaces:
NodeBuilder
,ProductAssetProvider<T>
public class ExternalProductAssetProvider<T extends ProductAsset>
extends AbstractRestApiExternalProvider
implements ProductAssetProvider<T>
-
Constructor Summary
ConstructorsConstructorDescriptionExternalProductAssetProvider
(ExternalCatalogProviderProperties properties, com.fasterxml.jackson.databind.ObjectMapper mapper, org.springframework.web.reactive.function.client.WebClient webClient, com.broadleafcommerce.common.extension.TypeFactory typeFactory) -
Method Summary
Modifier and TypeMethodDescriptioncreateProductAsset
(String productId, T asset, BatchContext<?> batchContext) void
deleteProductAsset
(String productId, String assetId, BatchContext<?> batchContext) protected String
readProductAssets
(String productId, BatchContext<?> batchContext) Fetch any assets associated with the supplied product id.saveTranslations
(String productId, String assetId, Locale locale, List<Translation> translations, BatchContext<?> batchContext) updateProductAsset
(String productId, T asset, BatchContext<?> batchContext) Methods inherited from class com.broadleafcommerce.dataexchange.service.provider.external.AbstractRestApiExternalProvider
addNarrowedPageableParams, deleteRequest, deleteRequest, getFilterParams, getFilterParams, getHeaders, getMapper, getMostDerivedType, getRequest, getRequest, getTypeFactory, getWebClient, narrowedPageParams, patchRequest, patchRequest, postRequest, postRequest, putRequest, putRequest, setCorrelationIds
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.broadleafcommerce.dataexchange.service.NodeBuilder
buildAndNode, buildAndNode, buildEqualsNode, buildInNode, buildInNode, buildOrNode, buildOrNode, emptyNode, escapeSpecialCharacters, filterEmptyNodes, filterEmptyNodes, isEmptyNodeOrNull
-
Constructor Details
-
ExternalProductAssetProvider
public ExternalProductAssetProvider(ExternalCatalogProviderProperties properties, com.fasterxml.jackson.databind.ObjectMapper mapper, org.springframework.web.reactive.function.client.WebClient webClient, com.broadleafcommerce.common.extension.TypeFactory typeFactory)
-
-
Method Details
-
readProductAssets
Description copied from interface:ProductAssetProvider
Fetch any assets associated with the supplied product id.- Specified by:
readProductAssets
in interfaceProductAssetProvider<T extends ProductAsset>
- Parameters:
productId
- The product id.- Returns:
- The assets associated with the product.
-
createProductAsset
- Specified by:
createProductAsset
in interfaceProductAssetProvider<T extends ProductAsset>
-
updateProductAsset
- Specified by:
updateProductAsset
in interfaceProductAssetProvider<T extends ProductAsset>
-
deleteProductAsset
- Specified by:
deleteProductAsset
in interfaceProductAssetProvider<T extends ProductAsset>
-
saveTranslations
public List<Translation> saveTranslations(String productId, String assetId, Locale locale, List<Translation> translations, BatchContext<?> batchContext) - Specified by:
saveTranslations
in interfaceProductAssetProvider<T extends ProductAsset>
-
getServiceClient
- Specified by:
getServiceClient
in classAbstractRestApiExternalProvider
- Returns:
- Returns the service client name to be used for the request.
-
getProperties
-