Interface ImportResource
- All Known Subinterfaces:
CategoryImport
,CustomerImport
,DiscountCodeImport
,InventoryImport
,PriceImport
,ProductDraftImport
,ProductImport
,ProductTypeImport
,ProductVariantImport
,StandalonePriceImport
,TypeImport
public interface ImportResource
A representation of the resource to import. Import resources are similar to draft types, but they only support key references. In general, import resources are more granular then regular resources. They are optimized for incremental updates and therefore have a slightly different structure.
Example to create an instance using the builder pattern
ImportResource importResource = ImportResource.builder()
.key("{key}")
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic ImportResourceBuilder
builder()
builder factory method for ImportResourcestatic ImportResourceBuilder
builder
(ImportResource template) create builder for ImportResource instancestatic ImportResource
deepCopy
(ImportResource template) factory method to create a deep copy of ImportResource@NotNull String
getKey()
User-defined unique identifier.static ImportResource
of()
factory methodstatic ImportResource
of
(ImportResource template) factory method to create a shallow copy ImportResourcevoid
User-defined unique identifier.static com.fasterxml.jackson.core.type.TypeReference<ImportResource>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withImportResource
(Function<ImportResource, T> helper) accessor map function
-
Method Details
-
getKey
User-defined unique identifier.
- Returns:
- key
-
setKey
User-defined unique identifier.
- Parameters:
key
- value to be set
-
of
factory method- Returns:
- instance of ImportResource
-
of
factory method to create a shallow copy ImportResource- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of ImportResource- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for ImportResource- Returns:
- builder
-
builder
create builder for ImportResource instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withImportResource
accessor map function- Type Parameters:
T
- mapped type- Parameters:
helper
- function to map the object- Returns:
- mapped value
-
typeReference
gives a TypeReference for usage with Jackson DataBind- Returns:
- TypeReference
-