it.dtt.ca.history
Class ProductHistoryItem

java.lang.Object
  extended by it.dtt.ca.history.HistoryItem
      extended by it.dtt.ca.history.ProductHistoryItem
All Implemented Interfaces:
java.io.Serializable

public class ProductHistoryItem
extends HistoryItem

This object describes one item of the history regarding purchased services.

See Also:
Serialized Form

Field Summary
static int EVENT_LOST
          Tells the event ha been purchased and not viewd, so it's been lost and the credit was deducted.
static int EVENT_REFUNDED
          Tells the event has been refunded by broadcaster.
static int EVENT_SEEN
          Tells the event has already been seem
static int EVENT_UPCOMING
          Tells the event has been purchased and it's upcoming
 
Fields inherited from class it.dtt.ca.history.HistoryItem
DISPOSED, READ, UNREAD
 
Constructor Summary
protected ProductHistoryItem(Product product, int itemStatus, java.util.Date orderingDate, int status, java.util.Date date)
          Create a ProductHistoryItem.
 
Method Summary
 Product getItemData()
          Retrieves all the data associated to the service.
 int getItemStatus()
          Tells if the event has already been viewed, if it's upcoming, or if it's been lost.
 java.util.Date getOrderingDate()
          Indicate when the order has been accepted.
 
Methods inherited from class it.dtt.ca.history.HistoryItem
getDate, getStatus, markDisposed, markRead, markUnread
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EVENT_SEEN

public static final int EVENT_SEEN
Tells the event has already been seem

See Also:
Constant Field Values

EVENT_UPCOMING

public static final int EVENT_UPCOMING
Tells the event has been purchased and it's upcoming

See Also:
Constant Field Values

EVENT_LOST

public static final int EVENT_LOST
Tells the event ha been purchased and not viewd, so it's been lost and the credit was deducted.

See Also:
Constant Field Values

EVENT_REFUNDED

public static final int EVENT_REFUNDED
Tells the event has been refunded by broadcaster.

See Also:
Constant Field Values
Constructor Detail

ProductHistoryItem

protected ProductHistoryItem(Product product,
                             int itemStatus,
                             java.util.Date orderingDate,
                             int status,
                             java.util.Date date)
Create a ProductHistoryItem.

Parameters:
product - the Product which was purchased by the user.
itemStatus - indicates whether the item was seen, lost, refunded, etc.
orderingDate - the date an time when the Product was purchased.
status - the status of this item in the history log, either READ, UNREAD, or DISPOSED.
date - the time and date of storage of the item in the history log.
Method Detail

getItemStatus

public int getItemStatus()
Tells if the event has already been viewed, if it's upcoming, or if it's been lost.

Returns:
the status.

getItemData

public Product getItemData()
Retrieves all the data associated to the service.

Returns:
item data.

getOrderingDate

public java.util.Date getOrderingDate()
Indicate when the order has been accepted. In case of subscription or PPT events, a null value is returned.

Returns:
date of pay per view event order.