public class GiftRegistryRules extends java.lang.Object implements ECGiftRegistryRuleConstants
Searches for a business rule value for a specific store and business rule only, then provides input parameters of storeId (Integer) and businessRuleName (Integer).
All business rules available are defined as constants in the ECGiftRegistryRuleContstant class.
When looking up a registry rule value, providing input parameters by storeId, eventTypeName, and businessRuleName, the IBM Gift Center rule cache will first check for a perfect match given the values provided. If there is no result found, then it will then check for the default value of the site with storeId of -1 and with the provided eventTypeName and businessRuleName.
Looks up a registry rule value, providing input parameters by only the storeId and businessRuleName, the IBM Gift Center rule cache will first check for a perfect match given the values provided. If there is no result found, then it will then check for the default value of the site with storeId of -1 and default eventTypeName of Default with the provided business rule name.
Modifier and Type | Field and Description |
---|---|
static java.lang.String | CLASS_NAME
The name of this class
|
static java.lang.String | COPYRIGHT
IBM copyright notice field.
|
Constructor and Description |
---|
GiftRegistryRules() |
Modifier and Type | Method and Description |
---|---|
static GiftRegistryRuleRegistry.GiftRegistryRuleEntry | getRuleEntryByStoreIdByEventTypeNameByName(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Private method that returns the grRuleValue value associated with a business rule given storeId, eventTypeName, and the businessRuleName.
|
static GiftRegistryRuleRegistry.GiftRegistryRuleEntry | getRuleEntryByStoreIdByName(java.lang.Integer storeId, java.lang.Integer ruleName)
Private method that returns the grRuleValue value associated with a business rule given storeId and the business rule name
|
static boolean | getRuleValueAsBoolean(java.lang.Integer storeId, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a boolean given storeId, and the business rule name returns true if registry value = "1", else returns false.
|
static boolean | getRuleValueAsBoolean(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a boolean given storeId, eventTypeName, and the business rule name returns true if registry value = "1", else returns false.
|
static java.sql.Date | getRuleValueAsDate(java.lang.Integer storeId, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a Date given storeId, and the business rule name
|
static java.sql.Date | getRuleValueAsDate(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a Date given storeId, eventTypeName, and the business rule name
|
static java.lang.Integer | getRuleValueAsInteger(java.lang.Integer storeId, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a String given storeId and the business rule name
|
static java.lang.Integer | getRuleValueAsInteger(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as an Integer given storeId, eventTypeName, and the business rule name
|
static java.lang.Long | getRuleValueAsLong(java.lang.Integer storeId, java.lang.Integer ruleName)
public method that returns the grRuleValue value associated with a business rule as a Long given storeId and the business rule name
|
static java.lang.Long | getRuleValueAsLong(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a Long given storeId, eventTypeName, and the business rule name
|
static java.lang.String | getRuleValueAsString(java.lang.Integer storeId, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a String given storeId and the business rule name
|
static java.lang.String | getRuleValueAsString(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
Public method that returns the grRuleValue value associated with a business rule as a String given storeId, eventTypeName, and the business rule name
|
public static java.lang.String CLASS_NAME
public static final java.lang.String COPYRIGHT
public static GiftRegistryRuleRegistry.GiftRegistryRuleEntry getRuleEntryByStoreIdByEventTypeNameByName(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static GiftRegistryRuleRegistry.GiftRegistryRuleEntry getRuleEntryByStoreIdByName(java.lang.Integer storeId, java.lang.Integer ruleName)
public static java.lang.String getRuleValueAsString(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static java.lang.String getRuleValueAsString(java.lang.Integer storeId, java.lang.Integer ruleName)
public static java.lang.Integer getRuleValueAsInteger(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static java.lang.Integer getRuleValueAsInteger(java.lang.Integer storeId, java.lang.Integer ruleName)
public static java.lang.Long getRuleValueAsLong(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static java.lang.Long getRuleValueAsLong(java.lang.Integer storeId, java.lang.Integer ruleName)
public static java.sql.Date getRuleValueAsDate(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static java.sql.Date getRuleValueAsDate(java.lang.Integer storeId, java.lang.Integer ruleName)
public static boolean getRuleValueAsBoolean(java.lang.Integer storeId, java.lang.String eventTypeName, java.lang.Integer ruleName)
public static boolean getRuleValueAsBoolean(java.lang.Integer storeId, java.lang.Integer ruleName)