com.ibm.commerce.fulfillment.commands

Class FulfillmentRegistry

  • java.lang.Object
    • com.ibm.commerce.fulfillment.commands.FulfillmentRegistry
  • All Implemented Interfaces:
    Registry


    public class FulfillmentRegistry
    extends java.lang.Object
    implements Registry
    This registry caches fulfillment-related entities, such as ShippingArrangements.
    • Field Detail

      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        The IBM copyright string.
        See Also:
        Constant Field Values
      • REGISTRY_NAME

        public static final java.lang.String REGISTRY_NAME
        The name of this registry.
        See Also:
        Constant Field Values
    • Method Detail

      • getInstance

        public static FulfillmentRegistry getInstance()
        Returns the FulfillmentRegistry instance.
        Returns:
        the FulfillmentRegistry instance
      • initialize

        public void initialize()
                        throws java.lang.Exception
        Initialize this registry instance.
        Specified by:
        initialize in interface Registry
        Throws:
        java.lang.Exception
        See Also:
        Registry.initialize()
      • refresh

        public void refresh()
                     throws java.lang.Exception
        Refreshes this registry instance.
        Specified by:
        refresh in interface Registry
        Throws:
        java.lang.Exception
        See Also:
        Registry.refresh()
      • isFulfillmentCenterEffective

        public boolean isFulfillmentCenterEffective(java.lang.Integer anFulfillmentCenterId,
                                                    java.lang.Integer anStoreId,
                                                    java.lang.Integer anShippingModeId,
                                                    java.sql.Timestamp aTimestamp)
                                             throws ECException
        Returns whether the specified FulfillmentCenter is effective for the specified combination of Store and ShippingMode at the specified time.
        Parameters:
        anFulfillmentCenterId - the fulfillmentCenterId
        anStoreId - the storeId
        anShippingModeId - the shippingModeId
        aTimestamp - the time
        Returns:
        true if the specified FulfillmentCenter is effective
        Throws:
        ECException -
      • getEffectiveFulfillmentCenterIds

        public java.lang.Integer[] getEffectiveFulfillmentCenterIds(java.lang.Integer anStoreId,
                                                                    java.lang.Integer anShippingModeId,
                                                                    java.sql.Timestamp aTimestamp)
                                                             throws ECException
        Returns the list of effective fulfillmentCenterIds for the specified combination of Store and ShippingMode at the specified time.
        Parameters:
        anStoreId - the storeId
        anShippingModeId - the shippingModeId
        aTimestamp - the time
        Returns:
        the list of fulfillmentCenterIds
        Throws:
        ECException -
      • isFulfillmentCenterEffective

        public boolean isFulfillmentCenterEffective(java.lang.Integer anFulfillmentCenterId,
                                                    java.lang.Integer anStoreId,
                                                    java.lang.Integer anShippingModeId,
                                                    java.sql.Timestamp aTimestamp,
                                                    java.lang.Long anAddressId,
                                                    CommandContext aCommandContext)
                                             throws ECException
        Returns true if the specified fulfillment center is effective for the specified store, shipping mode, time, and shipping address.
        Parameters:
        anFulfillmentCenterId - the fulfillment center identifier.
        anStoreId - the store identifier.
        anShippingModeId - the shipping mode identifier.
        aTimestamp - the time.
        anAddressId - if not null, the results are limited to those that can ship to this shipping address.
        aCommandContext - the command context. Can be null if anAddressId is null.
        Returns:
        true if the specified fulfillment center is effective as specified by the other input parameter values.
        Throws:
        ECException
      • getEffectiveFulfillmentCenterIds

        public java.lang.Integer[] getEffectiveFulfillmentCenterIds(java.lang.Integer anStoreId,
                                                                    java.lang.Integer anShippingModeId,
                                                                    java.sql.Timestamp aTimestamp,
                                                                    java.lang.Long anAddressId,
                                                                    CommandContext aCommandContext)
                                                             throws ECException
        Returns an array of fulfillment center identifiers that are effective for the specified store, shipping mode, time, and shipping address.
        Parameters:
        anStoreId - the store identifier.
        anShippingModeId - the shipping mode identifier.
        aTimestamp - the time.
        anAddressId - if not null, the results are limited to those that can ship to this shipping address.
        aCommandContext - the command context. Can be null if anAddressId is null.
        Returns:
        A non-null array of identifiers of effective fulfillment centers.
        Throws:
        ECException
      • isShippingArrangementRestricted

        public boolean isShippingArrangementRestricted(java.lang.Integer anStoreId,
                                                       java.lang.Integer anShippingModeId,
                                                       java.sql.Timestamp aTimestamp)
                                                throws ECException
        Returns true if any shipping arrangements (that are effective for the specified store, shipping mode, and time) are restricted to certain shipping jurisdiction groups.
        Parameters:
        anStoreId - the identifier of the store.
        anShippingModeId - the shipping mode identifier.
        aTimestamp - the time.
        Returns:
        true if any of the specified shipping arrangements are restricted to certain shipping jurisdiction groups.
        Throws:
        ECException
      • isFulfillmentCenterRestricted

        public boolean isFulfillmentCenterRestricted(java.lang.Integer anFulfillmentCenterId,
                                                     java.lang.Integer anStoreId,
                                                     java.lang.Integer anShippingModeId,
                                                     java.sql.Timestamp aTimestamp)
                                              throws ECException
        Returns true if any shipping arrangements are restricted to certain shipping jurisdiction groups. The shipping arrangements should be effective for the specified fulfillment center, store, shipping mode, and time.
        Parameters:
        anFulfillmentCenterId - the fulfillment center.
        anStoreId - the identifier of the store.
        anShippingModeId - the shipping mode identifier.
        aTimestamp - the time.
        Returns:
        true if any of the specified shipping arrangements are restricted to certain shipping jurisdiction groups.
        Throws:
        ECException
      • getShippingArrangement

        public ShippingArrangementCache getShippingArrangement()
        Returns singleton shippingArrangementCache, the caller should always use this singleton cache instead to create new cache.
        Returns:
        ShippingArrangementCache