/** Creates a command object to delete a {@link Order} by ID. @param versioned the object to delete (so directly a {@link Order}) or just the version/ID information of it @param eraseData If set to {@literal true}, the commercetools platform guarantees that all personal data related to the particular object, including invisible data, is erased, in compliance with the GDPR. @return delete command */ static OrderDeleteCommand of(final Versioned<Order> versioned,final boolean eraseData) { return new OrderDeleteCommandImpl(versioned,eraseData); }
/** Creates a command to update a Order selected by its ID using several update actions. @param versioned the object to update (so directly a {@link Order}) or just the version/ID information of it @param updateActions the updates @return the update command for Order */ static OrderUpdateCommand of(final Versioned<Order> versioned, final List<? extends UpdateAction<Order>> updateActions) { return new OrderUpdateCommandImpl(versioned, updateActions); }
public static OrderImportCommand of(final OrderImportDraft orderImportDraft) { return new OrderImportCommand(orderImportDraft); } }
static OrderFromCartCreateCommand of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }
private static void withImportedOrder(final BlockingSphereClient client, final OrderImportDraft draft, final Function<Order, Order> operator) { final Order order = client.executeBlocking(OrderImportCommand.of(draft)); final Order updatedOrder = operator.apply(order); client.executeBlocking(OrderDeleteCommand.of(updatedOrder)); }
public static OrderUpdateCommand of(final Versioned<Order> order, final List<? extends UpdateAction<Order>> updateActions) { return new OrderUpdateCommand(order, updateActions); }
public static OrderFromCartCreateCommand of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommand(draft); }
private Condition<? super LineItemLike> itemStates(final Set<ItemState> itemStates) { return new Condition<LineItemLike>(){ @Override public boolean matches(final LineItemLike actual) { return actual.getState().stream().anyMatch(state -> itemStates.contains(state)); } }.describedAs("states " + itemStates); }
public static OrderImportCommand of(final OrderImportDraft orderImportDraft) { return new OrderImportCommand(orderImportDraft); } }
public static OrderFromCartCreateCommandImpl of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }
/** Creates a command object to delete a {@link Order} by ID. @param versioned the object to delete (so directly a {@link Order}) or just the version/ID information of it @return delete command */ static OrderDeleteCommand of(final Versioned<Order> versioned) { return new OrderDeleteCommandImpl(versioned,false); }
static OrderUpdateCommand of(final Versioned<Order> order, final List<? extends UpdateAction<Order>> updateActions) { return new OrderUpdateCommandImpl(order, updateActions); }
public static OrderImportCommand of(final OrderImportDraft orderImportDraft) { return new OrderImportCommand(orderImportDraft); } }
public static OrderFromCartCreateCommandImpl of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }
static OrderDeleteCommand of(final Versioned<Order> versioned) { return new OrderDeleteCommandImpl(versioned); } }
/** Creates a command to update a Order selected by its ID using one update action. @param versioned the object to update (so directly a {@link Order}) or just the version/ID information of it @param updateAction the update to perform @return the update command for Order */ static OrderUpdateCommand of(final Versioned<Order> versioned, final UpdateAction<Order> updateAction) { return new OrderUpdateCommandImpl(versioned, Collections.singletonList(updateAction)); }
public static OrderImportCommand of(final OrderImportDraft orderImportDraft) { return new OrderImportCommand(orderImportDraft); } }
static OrderFromCartCreateCommand of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }
static OrderFromCartCreateCommand of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }
public static OrderFromCartCreateCommandImpl of(final OrderFromCartDraft draft) { return new OrderFromCartCreateCommandImpl(draft); }