JSR-234 1.1

javax.microedition.amms.control
Interface PriorityControl

All Superinterfaces:
javax.microedition.media.Control

public interface PriorityControl
extends javax.microedition.media.Control

PriorityControl is an interface for manipulating the priority of a Player among other Players.

Priority Settings

This interface allows prioritizing the playback of a Player by setting a priority level between 0 and 100. 100 being the highest priority, 50 the default level and zero the lowest priority. This interface can be used for automatic handling of essential sounds and experience-enhancing sounds inside the java virtual machine. 

Priority 100-51: High priority, should be used for Players that are more vital for the user interface than the default priority level Players. 
Priority 50: The default middle priority, if all Players have this priority level the functionality is identical to MMAPI 1.1.
Priority 49-1: Low priority, should be used for Players that are not as important for the user interface as the default priority level Players. 
Priority 0: The lowest priority. These Players are dropped if there is any risk that they would hinder other Players.

For Players where the priority level is not set, the default priority 50 is used.  

When a Player makes a transition from REALIZED to PREFETCHED or STARTED and there are no resources available to perform the transition then the following happens:


Method Summary
 int getPriority()
          Gets the current priority.
 void setPriority(int level)
          Sets the new priority.
 

Method Detail

getPriority

int getPriority()
Gets the current priority.

Returns:
the current priority level

setPriority

void setPriority(int level)
Sets the new priority.

Parameters:
level - new priority
Throws:
java.lang.IllegalArgumentException - if the given level < 0 or the given level > 100

JSR-234 1.1

Copyright © 2004-2007 Nokia Corporation. See the Copyright for details.