private static final boolean D = Constants.DEBUG;
private static final boolean V = Constants.VERBOSE;
+ private static final byte OPP_FORMAT_VCARD21 = 0x01;
+ private static final byte OPP_FORMAT_VCARD30 = 0x02;
+ private static final byte OPP_FORMAT_VCAL10 = 0x03;
+ private static final byte OPP_FORMAT_ANY_TYPE_OF_OBJ = (byte) 0xFF;
+
+ private static final byte[] SUPPORTED_OPP_FORMAT = {
+ OPP_FORMAT_VCARD21, OPP_FORMAT_VCARD30, OPP_FORMAT_VCAL10, OPP_FORMAT_ANY_TYPE_OF_OBJ};
+
private boolean userAccepted = false;
private class BluetoothShareContentObserver extends ContentObserver {
return;
}
sdpManager.createOppOpsRecord("OBEX Object Push", mServerSocket.getRfcommChannel(),
- mServerSocket.getL2capPsm(), 0x0102, SdpManager.OPP_FORMAT_ALL);
+ mServerSocket.getL2capPsm(), 0x0102, SUPPORTED_OPP_FORMAT);
}
@Override
public static final byte PBAP_REPO_SPEED_DAIL = 0x01<<2;
public static final byte PBAP_REPO_FAVORITES = 0x01<<3;
- // TODO: When changing OPP to use this new API.
- // Move the defines to the profile
- /* Object Push formats */
- public static final byte OPP_FORMAT_VCARD21 = 0x01;
- public static final byte OPP_FORMAT_VCARD30 = 0x02;
- public static final byte OPP_FORMAT_VCAL10 = 0x03;
- public static final byte OPP_FORMAT_ICAL20 = 0x04;
- public static final byte OPP_FORMAT_VNOTE = 0x05;
- public static final byte OPP_FORMAT_VMESSAGE = 0x06;
- public static final byte OPP_FORMAT_ANY_TYPE_OF_OBJ = (byte)0xFF;
-
- public static final byte[] OPP_FORMAT_ALL= {
- OPP_FORMAT_VCARD21,
- OPP_FORMAT_VCARD30,
- OPP_FORMAT_VCAL10,
- OPP_FORMAT_ICAL20,
- OPP_FORMAT_VNOTE,
- OPP_FORMAT_VMESSAGE,
- OPP_FORMAT_ANY_TYPE_OF_OBJ};
-
/* Variables to keep track of ongoing and queued search requests.
* mTrackerLock must be held, when using/changing sSdpSearchTracker
* and mSearchInProgress. */