public class MarketingHelper
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CAMPAIGN_ELEMENT_FORMAT_DATA
Constant representing the format 'Data' of a campaign element.
|
static java.lang.String |
CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONFILTER
Constant representing the type of campaign element used as a search filter.
|
static java.lang.String |
CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONINCLUSION
Constant representing the type of campaign element used as a search rule inclusion.
|
static java.lang.String |
CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONORDERBY
Constant representing the type of campaign element used as a search ordering field.
|
static java.lang.String |
CATEGORY_RULE_SPOT_PREFIX
The prefix used for the generated marketing spot name for a rule for a category.
|
static java.lang.String |
COPYRIGHT
The IBM copyright field.
|
static java.lang.String |
DYNAMIC_SALES_CATEGORY_ACTIVITY_NAME_PREFIX
Prefix for the activity name generated for a dynamic sales category.
|
static java.lang.String |
MKTING_ACTION_NAME_DYN_MERCH
Constant representing the marketing action name used in dynamic merchandising, 'displayProductStandardSearchCombined'.
|
static java.lang.String |
PRODUCT_SEARCH_ACTION_ELEMENT_NAME
Constant representing the campaign element name for the 'displayProductStandardSearchCombined' action.
|
static java.lang.String |
UNDERSCORE
Constant representing underscore.
|
static java.lang.String |
WEB_ACTIVITY_FORMAT_WEB
Constant representing the activity format 'Web'.
|
static java.lang.String |
WEB_ACTIVITY_INACTIVE
Constant representing the activity state 'Inactive'.
|
Constructor and Description |
---|
MarketingHelper() |
Modifier and Type | Method and Description |
---|---|
static void |
activateActivity(java.lang.String activityId)
This method activates a Marketing Activity.
|
static void |
createActivity(java.util.List<ActivityType> activityList)
This method creates a given list of Activities.
|
static ActivityType |
createCampaignElement(java.lang.String activityId,
CampaignElementType campaignElement)
This method creates a campaign element given an activity ID.
|
static java.lang.String |
createMarketingSpot(java.lang.String name,
java.lang.Integer storeId,
boolean displayable)
This method creates a new e-Marketing spot.
|
static void |
createRuleForCategory(java.lang.Long catgroupId,
CatalogGroupType catalogGroupType,
com.ibm.commerce.catalog.facade.datatypes.RuleType ruleType,
CatalogGroup aPhysicalEntity,
com.ibm.commerce.catalog.facade.server.entity.datatypes.Catgrprule catgroupRule)
This method will generate a rule for a category.
|
static void |
deactivateActivity(java.lang.String activityId)
This method deactivates a Marketing Activity.
|
static void |
deleteActivity(java.util.List<java.lang.String> activityIdList)
This method deletes a list of existing marketing activities.
|
static java.lang.String |
generateActivityNameForDynamicSalesCategory(java.lang.String catgroupId)
This method will generate an activity name for a dynamic sales category web activity.
|
static ActivityType |
getActivityByID(java.lang.String activityId)
This method gets the activity given the activity ID.
|
static java.util.List<ActivityType> |
getActivityForEMarketingSpot(java.lang.String spotId)
This methods gets the activities for a given e-marketing spot.
|
static void |
removeElementFromActivity(java.lang.String activityId,
java.lang.String elementUniqueId)
This method will remove a campaign element from a web activity.
|
static void |
updateElement(java.lang.String activityId,
CampaignElementType campaignElement)
This method will update a campaign element for a web activity.
|
public static final java.lang.String COPYRIGHT
public static final java.lang.String CATEGORY_RULE_SPOT_PREFIX
public static final java.lang.String DYNAMIC_SALES_CATEGORY_ACTIVITY_NAME_PREFIX
public static final java.lang.String UNDERSCORE
public static final java.lang.String WEB_ACTIVITY_INACTIVE
public static final java.lang.String WEB_ACTIVITY_FORMAT_WEB
public static final java.lang.String MKTING_ACTION_NAME_DYN_MERCH
public static final java.lang.String CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONFILTER
public static final java.lang.String CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONORDERBY
public static final java.lang.String CAMPAIGN_ELEMENT_TEMPLATE_IDENTIFIER_NAME_SEARCHACTIONINCLUSION
public static final java.lang.String CAMPAIGN_ELEMENT_FORMAT_DATA
public static final java.lang.String PRODUCT_SEARCH_ACTION_ELEMENT_NAME
public static java.lang.String createMarketingSpot(java.lang.String name, java.lang.Integer storeId, boolean displayable) throws MarketingSpotException
name
- The name of the e-Marketing Spot to create.storeId
- The ID of the store in which to create the e-Marketing Spot.displayable
- True if this eMarketing Spot should be displayed in the Marketing tool. False otherwise.MarketingSpotException
public static void createActivity(java.util.List<ActivityType> activityList) throws ActivityException
activityList
- the given list of Activities.ActivityException
- if any exception occurs while creating the Activities.public static ActivityType createCampaignElement(java.lang.String activityId, CampaignElementType campaignElement) throws ActivityException
activityId
- The activity ID.campaignElement
- The campaign element being created.ActivityException
- if any exception occurs while creating the campaign element.public static void activateActivity(java.lang.String activityId) throws ActivityException
activityId
- The activity Id.ActivityException
public static void deactivateActivity(java.lang.String activityId) throws ActivityException
activityId
- The activity Id.ActivityException
public static void deleteActivity(java.util.List<java.lang.String> activityIdList) throws ActivityException
activityIdList
- The list of unique id of the marketing activities to delete.ActivityException
public static java.util.List<ActivityType> getActivityForEMarketingSpot(java.lang.String spotId) throws ActivityException
This methods gets the activities for a given e-marketing spot.
If there is more than one, only the first activity ID will be returned.
spotId
- The e-Marketing Spot ID.ActivityException
public static void removeElementFromActivity(java.lang.String activityId, java.lang.String elementUniqueId) throws ActivityException
This method will remove a campaign element from a web activity.
activityId
- The activity identifier.elementUniqueId
- The unique id of the element.ActivityException
- An exception will be thrown if there was a problem removing the element.public static java.lang.String generateActivityNameForDynamicSalesCategory(java.lang.String catgroupId)
This method will generate an activity name for a dynamic sales category web activity.
catgroupId
- The category ID.public static ActivityType getActivityByID(java.lang.String activityId) throws ActivityException
This method gets the activity given the activity ID.
activityId
- The activity ID.ActivityException
public static void updateElement(java.lang.String activityId, CampaignElementType campaignElement) throws ActivityException
This method will update a campaign element for a web activity.
activityId
- The activity identifier.campaignElement
- The campaign element.ActivityException
- An exception will be thrown if there was a problem updating the element.public static void createRuleForCategory(java.lang.Long catgroupId, CatalogGroupType catalogGroupType, com.ibm.commerce.catalog.facade.datatypes.RuleType ruleType, CatalogGroup aPhysicalEntity, com.ibm.commerce.catalog.facade.server.entity.datatypes.Catgrprule catgroupRule) throws CatalogApplicationException
This method will generate a rule for a category.
catgroupId
- The catalog group internal identifier.catalogGroupType
- The catalog group logical object from the request.ruleType
- The rule logical object noun part from the request.aPhysicalEntity
- The catalog group physical entity.catgroupRule
- The catalog group rule physical entity.CatalogApplicationException
- An error will be thrown if there was a problem creating the rule for the category.