com.ibm.commerce.tools.campaigns

Class CampaignInitiativeCache

  • java.lang.Object
    • com.ibm.commerce.tools.campaigns.CampaignInitiativeCache
  • All Implemented Interfaces:
    CampaignConstants


    public final class CampaignInitiativeCache
    extends java.lang.Object
    implements CampaignConstants
    This class contains static methods that allow you to get a cached instance of a campaign initiative.
    • Field Detail

      • cacheEMarketingSpotNameIdMapping

        public static boolean cacheEMarketingSpotNameIdMapping
        Disable the caching of the e-Marketing Spot Name to ID relationship if this information is not required because full page caching is used.
      • clearLocalCacheAndCreateBroadcastJob

        public static boolean clearLocalCacheAndCreateBroadcastJob
        Disable clearing the campaign initiative cache when business users make changes in Accelerator, and do not create a broadcast job to clear the cache on all servers.
      • COPYRIGHT

        public static final java.lang.String COPYRIGHT
        IBM copyright notice field.
        See Also:
        Constant Field Values
    • Constructor Detail

      • CampaignInitiativeCache

        public CampaignInitiativeCache()
    • Method Detail

      • getCachedInitiative

        public static CampaignInitiativeCache.CachedInitiative getCachedInitiative(java.lang.Integer initiativeId)
        This function takes the initiative ID, and returns the cached initiative object.
        Parameters:
        initiativeId - The ID of the initiative.
        Returns:
        The cached initiative object.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.Integer eMarketingSpotId)
        This function takes the e-Marketing Spot ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotId - The ID of the e-Marketing Spot.
        Returns:
        A vector of cached initiatives.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.Integer eMarketingSpotId,
                                                            java.sql.Timestamp currentTime)
        This function takes the e-Marketing Spot ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotId - The ID of the e-Marketing Spot.
        currentTime - Time for the evaluation.
        Returns:
        A vector of cached initiatives.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.String eMarketingSpotName,
                                                            java.lang.Integer storeId)
        This function takes an e-Marketing Spot name and store ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        storeId - The ID of the store.
        Returns:
        A vector of cached initiatives.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.String eMarketingSpotName,
                                                            java.lang.Integer emsStoreId,
                                                            java.lang.Integer currentStoreId)
        This function takes an e-Marketing Spot name and store ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        emsStoreId - The ID of the store that owns the given e-Marketing Spot.
        currentStoreId - The ID of the current store.
        Returns:
        A vector of cached initiatives.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.String eMarketingSpotName,
                                                            java.lang.Integer emsStoreId,
                                                            java.lang.Integer currentStoreId,
                                                            java.sql.Timestamp currentTime)
        This function takes an e-Marketing Spot name and store ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        emsStoreId - The ID of the store that owns the given e-Marketing Spot.
        currentStoreId - The ID of the current store.
        currentTime - Time for the evaluation.
        Returns:
        A vector of cached initiatives.
      • getCachedInitiatives

        public static java.util.Vector getCachedInitiatives(java.lang.String eMarketingSpotName,
                                                            java.lang.Integer storeId,
                                                            java.sql.Timestamp currentTime)
        This function takes an e-Marketing Spot name and store ID, and according to the initiative schedule, populates the content of the initiatives that will be shown to this e-Marketing Spot to the cached initiative inner class.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        storeId - The ID of the store.
        currentTime - Time for the evaluation.
        Returns:
        A vector of cached initiatives.
      • getEMarketingSpot

        public static CampaignInitiativeCache.CachedEMarketingSpot getEMarketingSpot(java.lang.String eMarketingSpotName,
                                                                                     java.lang.Integer storeId)
        This function takes an e-Marketing Spot name and store ID, and returns the cached e-Marketing Spot object.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        storeId - The ID of the store.
        Returns:
        The cached e-Marketing Spot object.
      • getEMarketingSpotId

        public static java.lang.Integer getEMarketingSpotId(java.lang.String eMarketingSpotName,
                                                            java.lang.Integer storeId)
        This function takes an e-Marketing Spot name and store ID, and returns an e-Marketing Spot ID.
        Parameters:
        eMarketingSpotName - The name of the e-Marketing Spot.
        storeId - The ID of the store.
        Returns:
        The e-Marketing Spot ID.
      • localRefresh

        public static boolean localRefresh()
        Performs a refresh of the local cache.
        Returns:
        True if a local refresh is performed; false otherwise.
      • refresh

        public static void refresh(com.ibm.commerce.command.CommandContext commandContext)
                            throws com.ibm.commerce.exception.ECException
        Performs a refresh of the initiative cache.
        Parameters:
        commandContext - The command context.
        Throws:
        com.ibm.commerce.exception.ECException - Thrown when an error occurs while accessing the runtime command context.