Packageorg.osmf.captioning.model
Classpublic class Caption
InheritanceCaption Inheritance org.osmf.metadata.TimelineMarker

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Represents a caption, including text and style formatting information, as well as when to show the caption and when to hide it.



Public Properties
 PropertyDefined By
  clearText : String
[read-only] Returns the caption text without embedded HTML tags.
Caption
  id : uint
[read-only]
Caption
  numCaptionFormats : int
[read-only] Returns the number of CaptionFormat objects in this class' internal collection.
Caption
  text : String
[read-only] Returns the caption text which will include embedded HTML tags.
Caption
Public Methods
 MethodDefined By
  
Caption(id:uint, start:Number, end:Number, captionText:String)
Constructor.
Caption
  
Adds a CaptionFormat to this class' internal collection.
Caption
  
Returns the CaptionFormat object at the index specified.
Caption
Property Detail
clearTextproperty
clearText:String  [read-only]

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Returns the caption text without embedded HTML tags.


Implementation
    public function get clearText():String
idproperty 
id:uint  [read-only]


Implementation
    public function get id():uint
numCaptionFormatsproperty 
numCaptionFormats:int  [read-only]

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Returns the number of CaptionFormat objects in this class' internal collection.


Implementation
    public function get numCaptionFormats():int
textproperty 
text:String  [read-only]

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Returns the caption text which will include embedded HTML tags. To get the caption text without embedded HTML tags, use the clearText property.


Implementation
    public function get text():String
Constructor Detail
Caption()Constructor
public function Caption(id:uint, start:Number, end:Number, captionText:String)

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Constructor.

Parameters
id:uint — The caption id if supplied (optional).
 
start:Number — The time in seconds the media when the caption should appear.
 
end:Number — The time in seconds the media when the caption should no longer appear.
 
captionText:String — The caption text to display.
Method Detail
addCaptionFormat()method
public function addCaptionFormat(value:CaptionFormat):void

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Adds a CaptionFormat to this class' internal collection.

Parameters

value:CaptionFormat

getCaptionFormatAt()method 
public function getCaptionFormatAt(index:int):CaptionFormat

Language Version : ActionScript 3.0
Product Version : OSMF 1.0
Runtime Versions : Flash Player 10, AIR 1.0

Returns the CaptionFormat object at the index specified.

Parameters

index:int

Returns
CaptionFormat

Throws
IllegalOperationError — If index argument is out of range.