PushRegistryInternal.javaAPI DocphoneME MR2 API (J2ME)5838Wed May 02 18:00:00 BST


public final class PushRegistryInternal extends Object
Stubbed implementation for CDC without JUMP variant of stack IMPL_NOTE: some (if not all) methods might go away as a result of sources refactoring

Fields Summary
public static final int
Push option to only launch this suite when not other applications are running.
Constructors Summary
private PushRegistryInternal()
Hides the default constructor.

Methods Summary
public static voidenablePushLaunch(boolean enable)
Sets the flag which enables push launches to take place.

enable set to true to enable launching of MIDlets based on alarms and connection notification events, otherwise set to false to disable launches

public static voidinitSecurityToken( token)
Initializes the security token for this class, so it can perform actions that a normal MIDlet Suite cannot.

token security token for this class.

public static java.lang.StringlistConnections(int id, boolean available)
Return a list of registered connections for given MIDlet suite.

id identifies the specific MIDlet suite to be launched
available if true, only return the list of connections with input available
string representing an array of connection strings, where each connection is represented by the generic connection protocol, host and port number identification

        return "";
public static voidregisterConnectionInternal(com.sun.midp.midlet.MIDletSuite midletSuite, java.lang.String connection, java.lang.String midlet, java.lang.String filter, boolean bypassChecks)
Register a dynamic connection with the application management software. Once registered, the dynamic connection acts just like a connection preallocated from the descriptor file. The internal implementation includes the storage name that uniquely identifies the MIDlet. This method bypasses the class loader specific checks needed by the Installer.

midletSuite MIDlet suite for the suite registering, the suite only has to implement isRegistered, checkForPermission, and getID.
connection generic connection protocol, host and port number (optional parameters may be included separated with semi-colons (;))
midlet class name of the MIDlet to be launched, when new external data is available
filter a connection URL string indicating which senders are allowed to cause the MIDlet to be launched
bypassChecks if true, bypass the permission checks, used by the installer when redo old connections during an aborted update
IllegalArgumentException if the connection string is not valid
ConnectionNotFoundException if the runtime system does not support push delivery for the requested connection protocol
IOException if the connection is already registered or if there are insufficient resources to handle the registration request
ClassNotFoundException if the MIDlet class name can not be found in the current MIDlet suite
SecurityException if the MIDlet does not have permission to register a connection

        throw new ConnectionNotFoundException("not supported");
public static voidunregisterConnections(int id)
Unregister all the connections for a MIDlet suite.

id identifies the specific MIDlet suite