Class InventoryEntryQueryBuilder


  • public final class InventoryEntryQueryBuilder
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.util.List<com.commercetools.api.client.ByProjectKeyInventoryGet> buildQueries​(com.commercetools.api.client.ProjectApiRoot ctpClient, java.util.Set<InventoryEntryIdentifier> identifiers)
      Builds List of ByProjectKeyInventoryGet requests to be used to query existing InventoryEntry's against set of sku and supply channels.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • buildQueries

        public static java.util.List<com.commercetools.api.client.ByProjectKeyInventoryGet> buildQueries​(@Nonnull
                                                                                                         com.commercetools.api.client.ProjectApiRoot ctpClient,
                                                                                                         @Nonnull
                                                                                                         java.util.Set<InventoryEntryIdentifier> identifiers)
        Builds List of ByProjectKeyInventoryGet requests to be used to query existing InventoryEntry's against set of sku and supply channels.

        For instance, a query for one inventory entry will be like (sku="sku_9" and supplyChannel(id="c28c5609-9766-4176-b8d3-a72edee753e8")) or when supply channel not defined the query will be like (sku="sku_9" and supplyChannel is not defined)

        Parameters:
        identifiers - Set of unique inventory identifiers, used in search predicate
        Returns:
        List of inventory entry queries or empty list when there was no identifiers.