Interface Asset
public interface Asset
Asset
Example to create an instance using the builder pattern
Example to create an instance using the builder pattern
Asset asset = Asset.builder()
.key("{key}")
.plusSources(sourcesBuilder -> sourcesBuilder)
.name(nameBuilder -> nameBuilder)
.build()
-
Method Summary
Modifier and TypeMethodDescriptionstatic AssetBuilderbuilder()builder factory method for Assetstatic AssetBuildercreate builder for Asset instancecopyDeep()static Assetfactory method to create a deep copy of Asset@Valid CustomCustom Fields defined for the Asset.@Valid LocalizedStringDescription of the Asset.@NotNull StringgetKey()User-defined identifier for the asset.@NotNull @Valid LocalizedStringgetName()Name of the Asset.@NotNull @Valid List<AssetSource>getTags()Keywords for categorizing and organizing Assets.static Assetof()factory methodstatic Assetfactory method to create a shallow copy AssetvoidCustom Fields defined for the Asset.voidsetDescription(LocalizedString description) Description of the Asset.voidUser-defined identifier for the asset.voidsetName(LocalizedString name) Name of the Asset.voidsetSources(AssetSource... sources) set sourcesvoidsetSources(List<AssetSource> sources) set sourcesvoidKeywords for categorizing and organizing Assets.voidKeywords for categorizing and organizing Assets.static com.fasterxml.jackson.core.type.TypeReference<Asset>gives a TypeReference for usage with Jackson DataBinddefault <T> Taccessor map function
-
Method Details
-
getKey
User-defined identifier for the asset. Asset keys are unique inside their container (a product variant or a category).
- Returns:
- key
-
getSources
- Returns:
- sources
-
getName
Name of the Asset.
- Returns:
- name
-
getDescription
Description of the Asset.
- Returns:
- description
-
getTags
Keywords for categorizing and organizing Assets.
- Returns:
- tags
-
getCustom
Custom Fields defined for the Asset.
- Returns:
- custom
-
setKey
User-defined identifier for the asset. Asset keys are unique inside their container (a product variant or a category).
- Parameters:
key- value to be set
-
setSources
set sources- Parameters:
sources- values to be set
-
setSources
set sources- Parameters:
sources- values to be set
-
setName
Name of the Asset.
- Parameters:
name- value to be set
-
setDescription
Description of the Asset.
- Parameters:
description- value to be set
-
setTags
Keywords for categorizing and organizing Assets.
- Parameters:
tags- values to be set
-
setTags
Keywords for categorizing and organizing Assets.
- Parameters:
tags- values to be set
-
setCustom
Custom Fields defined for the Asset.
- Parameters:
custom- value to be set
-
of
factory method- Returns:
- instance of Asset
-
of
factory method to create a shallow copy Asset- Parameters:
template- instance to be copied- Returns:
- copy instance
-
copyDeep
Asset copyDeep() -
deepCopy
factory method to create a deep copy of Asset- Parameters:
template- instance to be copied- Returns:
- copy instance
-
builder
builder factory method for Asset- Returns:
- builder
-
builder
create builder for Asset instance- Parameters:
template- instance with prefilled values for the builder- Returns:
- builder
-
withAsset
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
-