bbc.rd.tvanytime.programInformation
Class AspectRatio

java.lang.Object
  extended by bbc.rd.tvanytime.programInformation.AspectRatio
All Implemented Interfaces:
java.lang.Cloneable

public class AspectRatio
extends java.lang.Object
implements java.lang.Cloneable

AspectRatio: Represents aspect ratio of a program.

Version:
1.0
Author:
Tristan Ferne, BBC Research & Development, November 2002

Field Summary
static int ORIGINAL
           
static int PUBLICATION
           
 
Constructor Summary
AspectRatio()
          Create AspectRatio object.
AspectRatio(java.lang.String aspectRatio)
          Create AspectRatio object.
 
Method Summary
 java.lang.Object clone()
          Clones itself.
 java.lang.String getAspectRatio()
          Return aspect ratio of this program.
 int getType()
          Return the type of aspect ratio of this program.
 void setAspectRatio(java.lang.String aspectRatio)
          Set aspect ratio of this program.
 void setType(int type)
          Set the type of aspect ratio of this program.
 java.lang.String toString()
          Returns string representation of the aspect ratio.
 java.lang.String toString(int indent)
          Returns string representation of the aspect ratio.
 java.lang.String toXML()
          Returns XML representation of the aspect ratio.
 java.lang.String toXML(int indent)
          Returns XML representation of the aspect ratio.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

ORIGINAL

public static final int ORIGINAL
See Also:
Constant Field Values

PUBLICATION

public static final int PUBLICATION
See Also:
Constant Field Values
Constructor Detail

AspectRatio

public AspectRatio()
Create AspectRatio object.


AspectRatio

public AspectRatio(java.lang.String aspectRatio)
            throws TVAnytimeException
Create AspectRatio object.

Parameters:
aspectRatio - Aspect ratio of this program in the form "x:y".
Throws:
TVAnytimeException
Method Detail

getAspectRatio

public java.lang.String getAspectRatio()
Return aspect ratio of this program. Aspect ratio is in the form "x:x".

Returns:
The aspect ratio of this program.

setAspectRatio

public void setAspectRatio(java.lang.String aspectRatio)
                    throws TVAnytimeException
Set aspect ratio of this program. Aspect ratio is in the form "x:y".

Parameters:
aspectRatio - The aspect ratio of this program.
Throws:
TVAnytimeException - Thrown if passed invalid aspect ratio (must be "x:y").

getType

public int getType()
Return the type of aspect ratio of this program.

Returns:
The type of aspect ratio of this program.

setType

public void setType(int type)
             throws TVAnytimeException
Set the type of aspect ratio of this program.

Parameters:
type - The type of aspect ratio of this program.
Throws:
TVAnytimeException - Thrown if passed invalid aspect ratio (must be "x:y").

toXML

public java.lang.String toXML()
Returns XML representation of the aspect ratio.

Returns:
XML representation of the aspect ratio.

toXML

public java.lang.String toXML(int indent)
Returns XML representation of the aspect ratio.

Parameters:
indent - Number of tabs with which to indent the string.
Returns:
XML representation of the aspect ratio.

toString

public java.lang.String toString()
Returns string representation of the aspect ratio.

Overrides:
toString in class java.lang.Object
Returns:
string representation of the aspect ratio.

toString

public java.lang.String toString(int indent)
Returns string representation of the aspect ratio.

Parameters:
indent - Number of tabs with which to indent the string.
Returns:
string representation of the aspect ratio.

clone

public java.lang.Object clone()
Clones itself.

Overrides:
clone in class java.lang.Object
Returns:
A copy of itself.