sears.file
Class Subtitle

java.lang.Object
  extended by sears.file.Subtitle
All Implemented Interfaces:
java.lang.Cloneable, java.lang.Comparable<Subtitle>
Direct Known Subclasses:
SsaSubtitle

public class Subtitle
extends java.lang.Object
implements java.lang.Comparable<Subtitle>, java.lang.Cloneable

Class .
Summary:
Represent a Subtitle.


Constructor Summary
Subtitle()
          Constructor Subtitle.
Subtitle(int _number, int _startDate, int _endDate, java.lang.String _subtitle)
          Constructor Subtitle.
Subtitle(Subtitle _subtitle)
          Constructor Subtitle.
 
Method Summary
 void accentRemove()
          Method accentRemove.
 void anchor(int anchor)
          Method anchor.
 Subtitle cloneSubtitle()
           
 int compareTo(Subtitle subtitle)
           
 void delay(int delay)
          Method delay.
 boolean equals(java.lang.Object object)
           
 int getAnchor()
          Method getAnchor.
 int getEndDate()
          Method getEndDate.
 int getNumber()
          Method getNumber.
 int getStartDate()
          Method getStartDate.
 java.lang.String getSubtitle()
          Method getSubtitle.
 void htmlRemove()
          Method htmlRemove.
 boolean isAnchored()
          Method isAnchored.
 void setEndDate(int endDate)
          Method setEndDate.
 void setNumber(int number)
          Method setNumber.
 void setStartDate(int startDate)
          Method setStartDate.
 void setSubtitle(java.lang.String subtitle)
          Method setSubtitle.
 void unanchor()
          Method unanchor.
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Subtitle

public Subtitle(int _number,
                int _startDate,
                int _endDate,
                java.lang.String _subtitle)
Constructor Subtitle.
Summary:
Constructor of the class.

Parameters:
_number - The index of the subtitle.
_startDate - Its start date (in milliseconds)
_endDate - Its end date (in milliseconds)
_subtitle - The subtitle to display

Subtitle

public Subtitle(Subtitle _subtitle)
Constructor Subtitle.
Summary:
Constructor of the class. Copy another subtitle.

Parameters:
_subtitle - The Subtitle to copy.

Subtitle

public Subtitle()
Constructor Subtitle.
Summary:
Constructor of the class.

Method Detail

delay

public void delay(int delay)
Method delay.
Summary:
Apply a delay to the subtitle.

Parameters:
delay - The delay to apply.

getEndDate

public int getEndDate()
Method getEndDate.
Summary:
Return the endDate.

Returns:
the endDate

setEndDate

public void setEndDate(int endDate)
Method setEndDate.
Summary:
Set the endDate.

Parameters:
endDate - the endDate to set

getNumber

public int getNumber()
Method getNumber.
Summary:
Return the number.

Returns:
the number

setNumber

public void setNumber(int number)
Method setNumber.
Summary:
Set the number.

Parameters:
number - the number to set

getStartDate

public int getStartDate()
Method getStartDate.
Summary:
Return the startDate.

Returns:
the startDate

setStartDate

public void setStartDate(int startDate)
Method setStartDate.
Summary:
Set the startDate.

Parameters:
startDate - the startDate to set

getSubtitle

public java.lang.String getSubtitle()
Method getSubtitle.
Summary:
Return the subtitle.

Returns:
the subtitle

setSubtitle

public void setSubtitle(java.lang.String subtitle)
Method setSubtitle.
Summary:
Set the subtitle.

Parameters:
subtitle - the subtitle to set

equals

public boolean equals(java.lang.Object object)
Overrides:
equals in class java.lang.Object

accentRemove

public void accentRemove()
Method accentRemove.
Summary:
This method remove the accents and other bad characters from subtitle.


htmlRemove

public void htmlRemove()
Method htmlRemove.
Summary:
This method remove the Html tags from subtitle.


compareTo

public int compareTo(Subtitle subtitle)
Specified by:
compareTo in interface java.lang.Comparable<Subtitle>

isAnchored

public boolean isAnchored()
Method isAnchored.
Summary:
Return true, if the subtitle is anchored to a destination time.

Returns:
(boolean) true, if the subtitle is anchored to a destination time.

anchor

public void anchor(int anchor)
Method anchor.
Summary:
Permits to set the anchor of the subtitle.

Parameters:
anchor - The anchor to set (in seconds).

unanchor

public void unanchor()
Method unanchor.
Summary:
remove the anchor from a subtitle.


getAnchor

public int getAnchor()
Method getAnchor.
Summary:
Return the anchor in milliseconds.

Returns:
the anchor

cloneSubtitle

public Subtitle cloneSubtitle()