java.lang.Object
org.ccdtovcd.Play_item
- All Implemented Interfaces:
- java.lang.Comparable, java.io.Serializable
- Direct Known Subclasses:
- Segment_item, Sequence_item
- public abstract class Play_item
- extends java.lang.Object
- implements java.lang.Comparable, java.io.Serializable
src
private java.lang.String src
id
private java.lang.String id
auto_pause
private java.util.Set auto_pause
Play_item
public Play_item(java.lang.String src,
java.lang.String id)
getSrc
public java.lang.String getSrc()
setSrc
public void setSrc(java.lang.String src)
getId
public java.lang.String getId()
setId
public void setId(java.lang.String id)
getAuto_pause
public java.util.Set getAuto_pause()
setAuto_pause
public void setAuto_pause(java.util.Set auto_pause)
addOneAuto_pause
public void addOneAuto_pause(float one_auto_pause)
compareTo
public int compareTo(java.lang.Object element1)
- Description copied from interface:
java.lang.Comparable
- Compares this object with another, and returns a numerical result based
on the comparison. If the result is negative, this object sorts less
than the other; if 0, the two are equal, and if positive, this object
sorts greater than the other. To translate this into boolean, simply
perform
o1.compareTo(o2) <op> 0, where op
is one of <, <=, =, !=, >, or >=.
You must make sure that the comparison is mutual, ie.
sgn(x.compareTo(y)) == -sgn(y.compareTo(x)) (where sgn() is
defined as -1, 0, or 1 based on the sign). This includes throwing an
exception in either direction if the two are not comparable; hence,
compareTo(null) should always throw an Exception.
You should also ensure transitivity, in two forms:
x.compareTo(y) > 0 && y.compareTo(z) > 0 implies
x.compareTo(z) > 0; and x.compareTo(y) == 0
implies x.compareTo(z) == y.compareTo(z).
- Specified by:
compareTo in interface java.lang.Comparable
toString
public java.lang.String toString()
- Description copied from class:
java.lang.Object
- Convert this Object to a human-readable String.
There are no limits placed on how long this String
should be or what it should contain. We suggest you
make it as intuitive as possible to be able to place
it into System.out.println() 55
and such.
It is typical, but not required, to ensure that this method
never completes abruptly with a java.lang.RuntimeException.
This method will be called when performing string
concatenation with this object. If the result is
null, string concatenation will instead
use "null".
The default implementation returns
getClass().getName() + "@" +
Integer.toHexString(hashCode()).