com.ibm.commerce.marketingcenter.events.dbobjects
Class PCStats

java.lang.Object
  |
  +--com.ibm.commerce.marketingcenter.events.dbobjects.PCStats
All Implemented Interfaces:
MktgClickEventHandler, MktgEventHandler, MktgLogEventHandler

public class PCStats
extends java.lang.Object
implements MktgClickEventHandler, MktgLogEventHandler

This is the object that will persist (create / update) the event into the PCSTATS table.


Field Summary
 java.lang.Long catgroup_id
          Category ID, maps to the table column with the same name.
static java.lang.String COPYRIGHT
          IBM copyright notice field.
 java.lang.Integer pcclicks
          # products clicked on by shopper, maps to the table column with the same name.
 java.lang.Integer pcviews
          # products shown to shopper (impressions), maps to the table column with the same name.
 java.lang.Integer storeent_id
          Store entity ID, maps to the table column with the same name.
 
Constructor Summary
PCStats()
          Constructor for PCStats.
 
Method Summary
 void addClick(java.util.Hashtable h)
          This method will update a record in the PCSTATS table.
 void addClick(java.lang.Long catGroupId, java.lang.Integer storeId)
          This method will update a record in the PCSTATS table.
 void addClick( TypedProperty tp)
          This method will update a record in the PCSTATS table.
 void addClick( TypedProperty tp, java.lang.Integer storeIdentifier)
          This method will update a record in the PCSTATS table.
 void addEvent()
          This method will persist/update a record in the PCSTATS table.
 void addEvent(java.util.Hashtable h)
          This method will persist/update a record in the PCSTATS table.
 void addEvent(java.lang.Long catGroupId, java.lang.Integer storeId)
          This method will persist/update a record in the PCSTATS table.
 void addEvent( TypedProperty tp)
          This method will persist/update a record in the PCSTATS table.
 void addEvent( TypedProperty tp, java.lang.Integer storeIdentifier)
          This method will persist/update a record in the PCSTATS table.
 java.lang.Long getCatgroup_id()
          Gets the category ID recorded in the current event.
 int getEventType()
          Gets the event type recorded in the current event.
 java.lang.Integer getPcclicks()
          Gets the number of product comparison clicks recorded in the current event.
 java.lang.Integer getPcviews()
          Gets the number of product comparison views recorded in the current event.
 java.lang.Integer getStoreent_id()
          Gets the store entity ID recorded in the current event.
 void persistClickEvent()
          Persists the current click event by inserting the event details into the database.
 void persistInvocationEvent()
          Persists the invocation event by inserting the event details into the database.
 void processEvent()
          Processes the current click event by persisting the event details into the database.
 void setCatgroup_id(java.lang.Long newCatgroup_id)
          Sets the category ID recorded in the current event.
 void setEventType(int newEventType)
          Sets the event type recorded in the current event.
 void setPcclicks(java.lang.Integer newPcclicks)
          Sets the number of product comparison clicks recorded in the current event.
 void setPcviews(java.lang.Integer newPcviews)
          Sets the number of product comparison views recorded in the current event.
 void setStoreent_id(java.lang.Integer newStoreent_id)
          Sets the store entity ID recorded in the current event.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

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

catgroup_id

public java.lang.Long catgroup_id
Category ID, maps to the table column with the same name.

storeent_id

public java.lang.Integer storeent_id
Store entity ID, maps to the table column with the same name.

pcviews

public java.lang.Integer pcviews
# products shown to shopper (impressions), maps to the table column with the same name.

pcclicks

public java.lang.Integer pcclicks
# products clicked on by shopper, maps to the table column with the same name.
Constructor Detail

PCStats

public PCStats()
Constructor for PCStats.
Method Detail

addClick

public void addClick(TypedProperty tp)
This method will update a record in the PCSTATS table. If a a record is not found, no work will be done. If a record exists, the click count is incremented.
Specified by:
addClick in interface MktgClickEventHandler
Parameters:
tp - The TypedProperty that contains all the column=value pairs that are components of the primary key. The TypedProperty key names should be the same names as in the database table. The type should also be the same (e.g. Integer).

addClick

public void addClick(TypedProperty tp,
                     java.lang.Integer storeIdentifier)
This method will update a record in the PCSTATS table. If a a record is not found, no work will be done. If a record exists, the click count is incremented.
Specified by:
addClick in interface MktgClickEventHandler
Parameters:
tp - The TypedProperty that contains all the column=value pairs that are components of the primary key. The TypedProperty key names should be the same names as in the database table. The type should also be the same (e.g. Integer).
storeIdentifier - Not used since this is not a component of the primary key.

addClick

public void addClick(java.lang.Long catGroupId,
                     java.lang.Integer storeId)
This method will update a record in the PCSTATS table. If a a record is not found, no work will be done. If a record exists, the click count is incremented.
Parameters:
catGroupId - the category ID to be persisted
storeId - the store ID to be persisted

addClick

public void addClick(java.util.Hashtable h)
This method will update a record in the PCSTATS table. If a a record is not found, no work will be done. If a record exists, the click count is incremented.
Specified by:
addClick in interface MktgClickEventHandler
Parameters:
h - The Hashtable that contains all the column=value pairs that are components of the primary key. The Hashtable key names should be the same names as in the database table. The type should also be the same (e.g. Integer).

addEvent

public void addEvent()
This method will persist/update a record in the PCSTATS table. If a a record is not found, one will be created with the counters set to 0. If a record exists, the view count is incremented. The caller must do all the setXXX prior to calling this.

addEvent

public void addEvent(TypedProperty tp)
This method will persist/update a record in the PCSTATS table. If a a record is not found, one will be created with the counters set to 0. If a record exists, the view count is incremented.
Specified by:
addEvent in interface MktgLogEventHandler
Parameters:
tp - The TypedProperty that contains all the column=value pairs. The key name should be the same name as in the database table. The type should also be the same (e.g. Integer).

addEvent

public void addEvent(TypedProperty tp,
                     java.lang.Integer storeIdentifier)
This method will persist/update a record in the PCSTATS table. If a a record is not found, one will be created with the counters set to 0. If a record exists, the view count is incremented.
Specified by:
addEvent in interface MktgLogEventHandler
Parameters:
tp - The TypedProperty that contains all the column=value pairs. The key name should be the same name as in the database table. The type should also be the same (e.g. Integer).
storeIdentifier - The WCS store Id

addEvent

public void addEvent(java.lang.Long catGroupId,
                     java.lang.Integer storeId)
This method will persist/update a record in the PCSTATS table. If a a record is not found, one will be created with the counters set to 0. If a record exists, the view count is incremented.
Parameters:
catGroupId - the category ID to be persisted
storeId - the store ID to be persisted

addEvent

public void addEvent(java.util.Hashtable h)
This method will persist/update a record in the PCSTATS table. If a a record is not found, one will be created with the counters set to 0. If a record exists, the view count is incremented.
Specified by:
addEvent in interface MktgLogEventHandler
Parameters:
h - The Hashtable that contains all the column=value pairs. The key name should be the same name as in the database table. The type should also be the same (e.g. Integer).

getCatgroup_id

public java.lang.Long getCatgroup_id()
Gets the category ID recorded in the current event.
Returns:
category ID

getEventType

public int getEventType()
Gets the event type recorded in the current event.
Returns:
event type

getPcclicks

public java.lang.Integer getPcclicks()
Gets the number of product comparison clicks recorded in the current event.
Returns:
product comparison clicks

getPcviews

public java.lang.Integer getPcviews()
Gets the number of product comparison views recorded in the current event.
Returns:
product comparison views

getStoreent_id

public java.lang.Integer getStoreent_id()
Gets the store entity ID recorded in the current event.
Returns:
store entity ID

persistClickEvent

public void persistClickEvent()
Persists the current click event by inserting the event details into the database.

persistInvocationEvent

public void persistInvocationEvent()
Persists the invocation event by inserting the event details into the database.

processEvent

public void processEvent()
Processes the current click event by persisting the event details into the database.

setCatgroup_id

public void setCatgroup_id(java.lang.Long newCatgroup_id)
Sets the category ID recorded in the current event.
Parameters:
newCatgroup_id - category ID

setEventType

public void setEventType(int newEventType)
Sets the event type recorded in the current event.
Parameters:
newEventType - event type

setPcclicks

public void setPcclicks(java.lang.Integer newPcclicks)
Sets the number of product comparison clicks recorded in the current event.
Parameters:
newPcclicks - product comparison click count

setPcviews

public void setPcviews(java.lang.Integer newPcviews)
Sets the number of product comparison views recorded in the current event.
Parameters:
newPcviews - product comparison view count

setStoreent_id

public void setStoreent_id(java.lang.Integer newStoreent_id)
Sets the store entity ID recorded in the current event.
Parameters:
newStoreent_id - store entity ID