public interface ProductSelectionCreateCommand extends DraftBasedCreateCommandDsl<ProductSelection,ProductSelectionDraft,ProductSelectionCreateCommand>, MetaModelReferenceExpansionDsl<ProductSelection,ProductSelectionCreateCommand,ProductSelectionExpansionModel<ProductSelection>>
ProductSelection
.
final LocalizedString name = en("Summer");
final ProductSelectionDraft productSelectionDraft = ProductSelectionDraft.ofName(name);
final ProductSelection productSelection = client().executeBlocking(ProductSelectionCreateCommand.of(productSelectionDraft));
assertThat(productSelection.getMode()).isEqualTo(ProductSelectionMode.INDIVIDUAL);
assertThat(productSelection.getName()).isEqualTo(name);
See the test code.
ProductSelectionDraft
,
ProductSelection
Modifier and Type | Method and Description |
---|---|
static ProductSelectionCreateCommand |
of(ProductSelectionDraft draft)
Creates a command object to create a
ProductSelection . |
getDraft, withDraft
canDeserialize, deserialize, httpRequestIntent
plusExpansionPaths, withExpansionPaths
plusExpansionPaths, plusExpansionPaths, plusExpansionPaths, plusExpansionPaths, withExpansionPaths, withExpansionPaths, withExpansionPaths, withExpansionPaths
expansionPaths
static ProductSelectionCreateCommand of(ProductSelectionDraft draft)
ProductSelection
.draft
- template to create the new object