sbIMediacoreSequencer Interface Reference

import"sbIMediacoreSequencer.idl";

Inheritance diagram for sbIMediacoreSequencer:
[legend]
Collaboration diagram for sbIMediacoreSequencer:
[legend]

Public Member Functions

void playView (in sbIMediaListView aView, [optional] in long long aItemIndex, [optional] in boolean aNotFromUserAction)
 Play a media list view as a sequence. Optionally provide the index of the item in the view that should play first in the sequence. More...
 
void playURL (in nsIURI aURI)
 Play a single URL as a sequence. More...
 
void play ()
 Play the sequence. More...
 
void stop ([optional] in boolean aNotFromUserAction)
 Stop the sequence. More...
 
void next ([optional] in boolean aNotFromUserAction)
 Go to the next item in the sequence. More...
 
void previous ([optional] in boolean aNotFromUserAction)
 Go to the previous item in the sequence. More...
 
void requestHandleNextItem (in sbIMediacore aMediacore)
 Indicate that the current core will handle the next item in the sequence when the stream ends. More...
 
void abort ()
 Abort the current item playback attempt. More...
 

Public Attributes

const unsigned long MODE_FORWARD = 0
 The mode used to generate the sequence. Note that it is possible to disable shuffle mode using the playlist.shuffle.disabled DataRemote. In this case, setting the mode to MODE_SHUFFLE will result in NS_ERROR_FAILURE. More...
 
const unsigned long MODE_REVERSE = 1
 
const unsigned long MODE_SHUFFLE = 1 << 1
 
const unsigned long MODE_CUSTOM = 1 << 16
 
attribute unsigned long mode
 
const unsigned long MODE_REPEAT_NONE = 0
 The repeat mode to use. Note that it is possible to disable repeat mode using the playlist.repeat.disabled DataRemote. In this case, setting the mode to MODE_REPEAT_ONE or MODE_REPEAT_ALL will result in NS_ERROR_FAILURE. More...
 
const unsigned long MODE_REPEAT_ONE = 1
 
const unsigned long MODE_REPEAT_ALL = 1 << 1
 
attribute unsigned long repeatMode
 
attribute sbIMediaListView view
 The view that was used to generate the current sequence. More...
 
readonly attribute unsigned long viewPosition
 The current position in the view. This position is tied to the sequencePosition. More...
 
readonly attribute sbIMediaItem currentItem
 The current item in the view. More...
 
readonly attribute sbIMediaItem nextItem
 The next item in the sequence. More...
 
readonly attribute nsIArray currentSequence
 The current sequence. It contains the indexes of the songs in the current sequence in the view. More...
 
attribute unsigned long sequencePosition
 The current position in the sequence. This position is tied to the viewPosition. More...
 
const long AUTO_PICK_INDEX = -1
 Allow the sequencer to pick the most appropriate start index for a sequence. More...
 
attribute
sbIMediacoreSequenceGenerator 
customGenerator
 

Detailed Description

Definition at line 37 of file sbIMediacoreSequencer.idl.

Member Function Documentation

void sbIMediacoreSequencer::abort ( )

Abort the current item playback attempt.

Note
This method may only be called from BEFORE_TRACK_CHANGE. If you attempt to call it from another context, it will silently fail.
void sbIMediacoreSequencer::next ( [optional] in boolean  aNotFromUserAction)

Go to the next item in the sequence.

Parameters
aNotFromUserActionFalse if this call is the result of a user interface action, true if code is calling next on its own (optional, defaults to false, which may trigger further user interaction).
void sbIMediacoreSequencer::play ( )

Play the sequence.

void sbIMediacoreSequencer::playURL ( in nsIURI  aURI)

Play a single URL as a sequence.

void sbIMediacoreSequencer::playView ( in sbIMediaListView  aView,
[optional] in long long  aItemIndex,
[optional] in boolean  aNotFromUserAction 
)

Play a media list view as a sequence. Optionally provide the index of the item in the view that should play first in the sequence.

Parameters
aViewThe view you wish to play.
aItemIndexThe index of the item inside the view to play first. You may pass sbIMediacoreSequencer::AUTO_PICK_INDEX if you wish to have the sequencer pick the most appropriate start index for the sequence.
aNotFromUserActionFalse if this call is the result of a user interface action, true if code is calling playView on its own (optional, defaults to false, which may trigger further user interaction).
See Also
AUTO_PICK_INDEX
void sbIMediacoreSequencer::previous ( [optional] in boolean  aNotFromUserAction)

Go to the previous item in the sequence.

Parameters
aNotFromUserActionFalse if this call is the result of a user interface action, true if code is calling previous on its own (optional, defaults to false, which may trigger further user interaction).
void sbIMediacoreSequencer::requestHandleNextItem ( in sbIMediacore  aMediacore)

Indicate that the current core will handle the next item in the sequence when the stream ends.

void sbIMediacoreSequencer::stop ( [optional] in boolean  aNotFromUserAction)

Stop the sequence.

Parameters
aNotFromUserActionFalse if this call is the result of a user interface action, true if code is calling stop on its own (optional, defaults to false so UI stop is from user

Member Data Documentation

const long sbIMediacoreSequencer::AUTO_PICK_INDEX = -1

Allow the sequencer to pick the most appropriate start index for a sequence.

The sequencer will pick a random index for the start of the sequence if shuffle is enabled. If shuffle is disabled, the sequencer will pick the first available index: 0.

See Also
playView

Definition at line 134 of file sbIMediacoreSequencer.idl.

readonly attribute sbIMediaItem sbIMediacoreSequencer::currentItem

The current item in the view.

Note
This is the equivalent of calling sbIMediaListView::getItemByIndex using viewPosition.
This may be null if there is no currentItem.

Definition at line 82 of file sbIMediacoreSequencer.idl.

readonly attribute nsIArray sbIMediacoreSequencer::currentSequence

The current sequence. It contains the indexes of the songs in the current sequence in the view.

Note
The value of viewPosition should be at the index of sequencePosition.

Definition at line 97 of file sbIMediacoreSequencer.idl.

attribute sbIMediacoreSequenceGenerator sbIMediacoreSequencer::customGenerator

Definition at line 188 of file sbIMediacoreSequencer.idl.

attribute unsigned long sbIMediacoreSequencer::mode

Definition at line 50 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_CUSTOM = 1 << 16

Definition at line 48 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_FORWARD = 0

The mode used to generate the sequence. Note that it is possible to disable shuffle mode using the playlist.shuffle.disabled DataRemote. In this case, setting the mode to MODE_SHUFFLE will result in NS_ERROR_FAILURE.

Definition at line 44 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_REPEAT_ALL = 1 << 1

Definition at line 60 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_REPEAT_NONE = 0

The repeat mode to use. Note that it is possible to disable repeat mode using the playlist.repeat.disabled DataRemote. In this case, setting the mode to MODE_REPEAT_ONE or MODE_REPEAT_ALL will result in NS_ERROR_FAILURE.

Definition at line 58 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_REPEAT_ONE = 1

Definition at line 59 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_REVERSE = 1

Definition at line 45 of file sbIMediacoreSequencer.idl.

const unsigned long sbIMediacoreSequencer::MODE_SHUFFLE = 1 << 1

Definition at line 46 of file sbIMediacoreSequencer.idl.

readonly attribute sbIMediaItem sbIMediacoreSequencer::nextItem

The next item in the sequence.

Note
This is equivalent to getting the current sequence and asking it for sequencePosition + 1.
This may be null if there is no next item.

Definition at line 90 of file sbIMediacoreSequencer.idl.

attribute unsigned long sbIMediacoreSequencer::repeatMode

Definition at line 62 of file sbIMediacoreSequencer.idl.

attribute unsigned long sbIMediacoreSequencer::sequencePosition

The current position in the sequence. This position is tied to the viewPosition.

Exceptions
NS_ERROR_NOT_AVAILABLEwhen the sequence position is invalid.

Definition at line 104 of file sbIMediacoreSequencer.idl.

attribute sbIMediaListView sbIMediacoreSequencer::view

The view that was used to generate the current sequence.

Definition at line 67 of file sbIMediacoreSequencer.idl.

readonly attribute unsigned long sbIMediacoreSequencer::viewPosition

The current position in the view. This position is tied to the sequencePosition.

Exceptions
NS_ERROR_NOT_AVAILABLEwhen the sequence position is invalid.

Definition at line 74 of file sbIMediacoreSequencer.idl.


The documentation for this interface was generated from the following file: