|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectnet.sf.xtvdclient.xtvd.datatypes.StarRating
public class StarRating
A ordinal-based typesafe enum
class that represents
the pre-defined values for tms:starRating
as defined
in the XTVD schema.
Copyright 2004, Tribune Media Services
$Id: StarRating.java,v 1.4 2004/03/26 15:56:16 rakesh Exp $Field Summary | |
---|---|
static StarRating |
FOUR_STAR
The typesafe representation of the **** starRating. |
static StarRating |
ONE_AND_HALF_STAR
The typesafe representation of the *+ starRating. |
static StarRating |
ONE_STAR
The typesafe representation of the * starRating. |
static StarRating |
THREE_AND_HALF_STAR
The typesafe representation of the ***+ starRating. |
static StarRating |
THREE_STAR
The typesafe representation of the *** starRating. |
static StarRating |
TWO_AND_HALF_STAR
The typesafe representation of the **+ starRating. |
static StarRating |
TWO_STAR
The typesafe representation of the ** starRating. |
Method Summary | |
---|---|
int |
compareTo(java.lang.Object object)
Implementation of the Comparable interface. |
boolean |
equals(java.lang.Object object)
Indicates whether some other object is "equal to" this one. |
static StarRating |
getStarRating(java.lang.String rating)
Return the appropriate StarRating based upon the
string specified. |
int |
hashCode()
Returns a hash code value for this class. |
java.lang.String |
toString()
Over-ridden to return the value of rating . |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final StarRating ONE_STAR
*
starRating.
public static final StarRating ONE_AND_HALF_STAR
*+
starRating.
public static final StarRating TWO_STAR
**
starRating.
public static final StarRating TWO_AND_HALF_STAR
**+
starRating.
public static final StarRating THREE_STAR
***
starRating.
public static final StarRating THREE_AND_HALF_STAR
***+
starRating.
public static final StarRating FOUR_STAR
****
starRating.
Method Detail |
---|
public static StarRating getStarRating(java.lang.String rating)
StarRating
based upon the
string specified. If the appropriate tv rating does not exist
return null
.
rating
- The rating value that is to be used to fetch
the corresponding StarRating.
null
otherwise.public java.lang.String toString()
rating
.
toString
in class java.lang.Object
public int compareTo(java.lang.Object object)
Comparable
interface.
Compares this object with the specified object for order. Returns
a negative integer, zero, or a positive integer as this object is
less than, equal to, or greater than the specified object.
compareTo
in interface java.lang.Comparable
object
- The object with which this class is to
be compared. No class type checking is done.
public boolean equals(java.lang.Object object)
ordinal
value.
equals
in class java.lang.Object
object
- The reference object with which to compare.
true
if the match succeeds.public int hashCode()
ordinal
.
hashCode
in class java.lang.Object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |