Methods Summary |
---|
protected void | checkUrl(com.sun.midp.io.BluetoothUrl url)Ensures URL parameters have valid value. Makes nothing actually
for all the required checks will be done durin ntspp transport
creation.
|
protected javax.microedition.io.Connection | clientConnection(com.sun.midp.security.SecurityToken token, int mode)Creates ClientSession connection over the rfcomm transport layer
checkForPermission(token, Permissions.OBEX_CLIENT);
StreamConnection sock = (StreamConnection)
new com.sun.midp.io.j2me.btspp.Protocol().
openPrim(getBtsppToken(token), name, mode, false);
return new ClientSessionImpl(new BTGOEPConnection(sock));
|
private static com.sun.midp.security.SecurityToken | getBtsppToken(com.sun.midp.security.SecurityToken token)Retrieves privileged token if there is no defined one.
return (token == null) ? internalSecurityToken : token;
|
public javax.microedition.io.Connection | openPrim(java.lang.Object token, java.lang.String name, int mode, boolean timeouts)Cheks permissions and opens requested connection.
Returns either ClientSession or SessionNotifier for OBEX connections,
depending whether client or server URL was specified. Actually all
essential logic is implemented in the superclass, this one only saves
resource name to reuse it for opening btspp transport.
this.name = name;
return super.openPrim(token, name, mode, timeouts);
|
protected javax.microedition.io.Connection | serverConnection(com.sun.midp.security.SecurityToken token, int mode)Creates server connection over the rfcomm transport layer
checkForPermission(token, Permissions.OBEX_SERVER);
StreamConnectionNotifier sock = (StreamConnectionNotifier)
new com.sun.midp.io.j2me.btspp.Protocol().
openPrim(getBtsppToken(token), name, mode, false);
return new SessionNotifierImpl(new BTGOEPNotifier(sock));
|