public final class ProductTypeReferenceResolver extends BaseReferenceResolver<io.sphere.sdk.producttypes.ProductTypeDraft,ProductTypeSyncOptions>
BLANK_ID_VALUE_ON_REFERENCE, BLANK_KEY_VALUE_ON_RESOURCE_IDENTIFIER, options| Constructor and Description |
|---|
ProductTypeReferenceResolver(ProductTypeSyncOptions productTypeSyncOptions,
ProductTypeService productTypeService)
Takes a
ProductTypeSyncOptions instance and a ProductTypeService to instantiate
a AttributeDefinitionReferenceResolver instance that could be used to resolve the AttributeDefinition
references on the productType draft supplied to the resolveReferences(ProductTypeDraft) method. |
| Modifier and Type | Method and Description |
|---|---|
java.util.concurrent.CompletionStage<io.sphere.sdk.producttypes.ProductTypeDraft> |
resolveReferences(io.sphere.sdk.producttypes.ProductTypeDraft productTypeDraft)
Given a
ProductTypeDraft this method attempts to resolve the attribute definition references to return
a CompletionStage which contains a new instance of the draft with the resolved references. |
getIdFromReference, getKeyFromResourceIdentifierpublic ProductTypeReferenceResolver(@Nonnull
ProductTypeSyncOptions productTypeSyncOptions,
@Nonnull
ProductTypeService productTypeService)
ProductTypeSyncOptions instance and a ProductTypeService to instantiate
a AttributeDefinitionReferenceResolver instance that could be used to resolve the AttributeDefinition
references on the productType draft supplied to the resolveReferences(ProductTypeDraft) method.productTypeSyncOptions - the container of all the options of the sync process including the CTP project
client and/or configuration and other sync-specific options.productTypeService - the service to fetch the product type for reference resolution.@Nonnull
public java.util.concurrent.CompletionStage<io.sphere.sdk.producttypes.ProductTypeDraft> resolveReferences(@Nonnull
io.sphere.sdk.producttypes.ProductTypeDraft productTypeDraft)
ProductTypeDraft this method attempts to resolve the attribute definition references to return
a CompletionStage which contains a new instance of the draft with the resolved references.resolveReferences in class BaseReferenceResolver<io.sphere.sdk.producttypes.ProductTypeDraft,ProductTypeSyncOptions>productTypeDraft - the productTypeDraft to resolve its references.CompletionStage that contains as a result a new productTypeDraft instance with resolved
references or, in case an error occurs during reference resolution,
a ReferenceResolutionException.