|
DJDoc v.1.0.0b-1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Hittable
The Hittable
interface is associated with objects that may be
hit, i.e. that have clickable hyperlinks on some HTML page. Moreover,
Hittable
objects keep track of the total number of times they
have been hit as well as at what time they have been hit for the last time.
Field Summary | |
---|---|
static java.util.Comparator<Hittable> |
FAVORITE
A Comparator for sorting Hittable objects by
the total number they have been hit so far (in descending order). |
static java.util.Comparator<Hittable> |
NATURAL
A Comparator for sorting Hittable objects by
their respective natural order. |
static java.util.Comparator<Hittable> |
RECENT
A Comparator for sorting Hittable objects by
the time they have been hit for the last time (in descending order). |
Method Summary | |
---|---|
int |
getHitCount()
Getter method for this Hittable object's hit count. |
java.util.Date |
getHitDate()
Getter method for this Hittable object's hit date. |
void |
hit()
This method marks this Hittable object as hit. |
void |
setHitCount(int hitCount)
Setter method for this Hittable object's hit count. |
void |
setHitDate(java.util.Date hitDate)
Setter method for this Hittable object's hit date. |
Methods inherited from interface java.lang.Comparable |
---|
compareTo |
Field Detail |
---|
static final java.util.Comparator<Hittable> NATURAL
Comparator
for sorting Hittable
objects by
their respective natural order.
static final java.util.Comparator<Hittable> FAVORITE
Comparator
for sorting Hittable
objects by
the total number they have been hit so far (in descending order).
static final java.util.Comparator<Hittable> RECENT
Comparator
for sorting Hittable
objects by
the time they have been hit for the last time (in descending order).
Method Detail |
---|
int getHitCount()
Hittable
object's hit count.
void setHitCount(int hitCount)
Hittable
object's hit count.
hitCount
- The total number of times this object has been hitjava.util.Date getHitDate()
Hittable
object's hit date.
void setHitDate(java.util.Date hitDate)
Hittable
object's hit date.
hitDate
- The date at which this object has been hit lastvoid hit()
Hittable
object as hit. It adjusts
its hit count and hit date accordingly.
|
DJDoc v.1.0.0b-1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |