Interface StoreDraft
- All Superinterfaces:
CustomizableDraft<StoreDraft>
,Draft<StoreDraft>
,WithKey
Example to create an instance using the builder pattern
StoreDraft storeDraft = StoreDraft.builder()
.key("{key}")
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic StoreDraftBuilder
builder()
builder factory method for StoreDraftstatic StoreDraftBuilder
builder
(StoreDraft template) create builder for StoreDraft instancestatic StoreDraft
deepCopy
(StoreDraft template) factory method to create a deep copy of StoreDraft@Valid List<StoreCountry>
Countries defined for the Store.@Valid CustomFieldsDraft
Custom fields for the Store.@Valid List<ChannelResourceIdentifier>
ResourceIdentifier of a Channel withProductDistribution
ChannelRoleEnum.@NotNull String
getKey()
User-defined unique and immutable identifier for the Store.Languages defined in Project.@Valid LocalizedString
getName()
Name of the Store.@Valid List<ProductSelectionSettingDraft>
Controls availability of Products for this Store via active/inactive Product Selections:@Valid List<ChannelResourceIdentifier>
ResourceIdentifier of a Channel withInventorySupply
ChannelRoleEnum.static StoreDraft
of()
factory methodstatic StoreDraft
of
(StoreDraft template) factory method to create a shallow copy StoreDraftvoid
setCountries
(StoreCountry... countries) Countries defined for the Store.void
setCountries
(List<StoreCountry> countries) Countries defined for the Store.void
setCustom
(CustomFieldsDraft custom) Custom fields for the Store.void
setDistributionChannels
(ChannelResourceIdentifier... distributionChannels) ResourceIdentifier of a Channel withProductDistribution
ChannelRoleEnum.void
setDistributionChannels
(List<ChannelResourceIdentifier> distributionChannels) ResourceIdentifier of a Channel withProductDistribution
ChannelRoleEnum.void
User-defined unique and immutable identifier for the Store.void
setLanguages
(String... languages) Languages defined in Project.void
setLanguages
(List<String> languages) Languages defined in Project.void
setName
(LocalizedString name) Name of the Store.void
setProductSelections
(ProductSelectionSettingDraft... productSelections) Controls availability of Products for this Store via active/inactive Product Selections:void
setProductSelections
(List<ProductSelectionSettingDraft> productSelections) Controls availability of Products for this Store via active/inactive Product Selections:void
setSupplyChannels
(ChannelResourceIdentifier... supplyChannels) ResourceIdentifier of a Channel withInventorySupply
ChannelRoleEnum.void
setSupplyChannels
(List<ChannelResourceIdentifier> supplyChannels) ResourceIdentifier of a Channel withInventorySupply
ChannelRoleEnum.static com.fasterxml.jackson.core.type.TypeReference<StoreDraft>
gives a TypeReference for usage with Jackson DataBinddefault <T> T
withStoreDraft
(Function<StoreDraft, T> helper) accessor map functionMethods inherited from interface com.commercetools.api.models.CustomizableDraft
unwrapCustomizableDraft
-
Method Details
-
getKey
User-defined unique and immutable identifier for the Store. Keys can only contain alphanumeric characters, underscores, and hyphens.
-
getName
Name of the Store.
- Returns:
- name
-
getLanguages
Languages defined in Project. Only languages defined in the Project can be used.
- Returns:
- languages
-
getCountries
Countries defined for the Store.
- Returns:
- countries
-
getDistributionChannels
ResourceIdentifier of a Channel with
ProductDistribution
ChannelRoleEnum.- Returns:
- distributionChannels
-
getSupplyChannels
ResourceIdentifier of a Channel with
InventorySupply
ChannelRoleEnum.- Returns:
- supplyChannels
-
getProductSelections
Controls availability of Products for this Store via active/inactive Product Selections:
- Leave empty if all Products in the Project should be available in this Store.
- If only
inactive
Product Selections withIndividualExclusion
ProductSelectionMode are provided, all the Products are available in this Store. - If all the Product Selections provided are
inactive
and there's at least a Product Selection of modeIndividual
, no Product is available in this Store. - If at least an
active
Product Selection is provided, onlyactive
Product Selections are considered to compute the availability in this Store.
- Returns:
- productSelections
-
getCustom
Custom fields for the Store.
- Specified by:
getCustom
in interfaceCustomizableDraft<StoreDraft>
- Returns:
- custom
-
setKey
User-defined unique and immutable identifier for the Store. Keys can only contain alphanumeric characters, underscores, and hyphens.
- Parameters:
key
- value to be set
-
setName
Name of the Store.
- Parameters:
name
- value to be set
-
setLanguages
Languages defined in Project. Only languages defined in the Project can be used.
- Parameters:
languages
- values to be set
-
setLanguages
Languages defined in Project. Only languages defined in the Project can be used.
- Parameters:
languages
- values to be set
-
setCountries
Countries defined for the Store.
- Parameters:
countries
- values to be set
-
setCountries
Countries defined for the Store.
- Parameters:
countries
- values to be set
-
setDistributionChannels
ResourceIdentifier of a Channel with
ProductDistribution
ChannelRoleEnum.- Parameters:
distributionChannels
- values to be set
-
setDistributionChannels
ResourceIdentifier of a Channel with
ProductDistribution
ChannelRoleEnum.- Parameters:
distributionChannels
- values to be set
-
setSupplyChannels
ResourceIdentifier of a Channel with
InventorySupply
ChannelRoleEnum.- Parameters:
supplyChannels
- values to be set
-
setSupplyChannels
ResourceIdentifier of a Channel with
InventorySupply
ChannelRoleEnum.- Parameters:
supplyChannels
- values to be set
-
setProductSelections
Controls availability of Products for this Store via active/inactive Product Selections:
- Leave empty if all Products in the Project should be available in this Store.
- If only
inactive
Product Selections withIndividualExclusion
ProductSelectionMode are provided, all the Products are available in this Store. - If all the Product Selections provided are
inactive
and there's at least a Product Selection of modeIndividual
, no Product is available in this Store. - If at least an
active
Product Selection is provided, onlyactive
Product Selections are considered to compute the availability in this Store.
- Parameters:
productSelections
- values to be set
-
setProductSelections
Controls availability of Products for this Store via active/inactive Product Selections:
- Leave empty if all Products in the Project should be available in this Store.
- If only
inactive
Product Selections withIndividualExclusion
ProductSelectionMode are provided, all the Products are available in this Store. - If all the Product Selections provided are
inactive
and there's at least a Product Selection of modeIndividual
, no Product is available in this Store. - If at least an
active
Product Selection is provided, onlyactive
Product Selections are considered to compute the availability in this Store.
- Parameters:
productSelections
- values to be set
-
setCustom
Custom fields for the Store.
- Specified by:
setCustom
in interfaceCustomizableDraft<StoreDraft>
- Parameters:
custom
- value to be set
-
of
factory method- Returns:
- instance of StoreDraft
-
of
factory method to create a shallow copy StoreDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
deepCopy
factory method to create a deep copy of StoreDraft- Parameters:
template
- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for StoreDraft- Returns:
- builder
-
builder
create builder for StoreDraft instance- Parameters:
template
- instance with prefilled values for the builder- Returns:
- builder
-
withStoreDraft
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
-