Home
last modified time | relevance | path

Searched refs:pdu (Results 1 – 25 of 83) sorted by relevance

1234

/packages/modules/CellBroadcastService/tests/src/com/android/cellbroadcastservice/tests/
DGsmSmsCbMessageTest.java106 final byte[] pdu = hexStringToBytes("0111130F6A0101C8329BFD06559BD429E8FE96B3C92C101D9D9" in testCreateMessageFromBinary()
121 SmsCbHeader header = new SmsCbHeader(pdu); in testCreateMessageFromBinary()
124 pdus[0] = pdu; in testCreateMessageFromBinary()
170 final byte[] pdu = hexStringToBytes("0001113001010010C0111204D2"); in testCreateTriggerMessage()
172 GsmSmsCbMessage.createGeoFencingTriggerMessage(pdu); in testCreateTriggerMessage()
183 private SmsCbMessage createFromPdu(byte[] pdu) { in createFromPdu() argument
185 SmsCbHeader header = new SmsCbHeader(pdu); in createFromPdu()
187 pdus[0] = pdu; in createFromPdu()
195 private void doTestGeographicalScopeValue(byte[] pdu, byte b, int expectedGs) { in doTestGeographicalScopeValue() argument
196 pdu[0] = b; in doTestGeographicalScopeValue()
[all …]
DGsmCellBroadcastHandlerTest.java179 final byte[] pdu = hexStringToBytes("0001113001010010C0111204D2"); in testTriggerMessage()
180 mGsmCellBroadcastHandler.onGsmCellBroadcastSms(0, pdu); in testTriggerMessage()
206 final byte[] pdu = hexStringToBytes("0001113001010010C0111204D2"); in testAirplaneModeReset()
207 mGsmCellBroadcastHandler.onGsmCellBroadcastSms(0, pdu); in testAirplaneModeReset()
/packages/apps/Bluetooth/src/com/android/bluetooth/map/
DBluetoothMapSmsPdu.java176 ByteArrayInputStream pdu = new ByteArrayInputStream(mData); in cdmaGetParameterOffset() local
181 pdu.skip(1); // Skip the message type in cdmaGetParameterOffset()
183 while (pdu.available() > 0) { in cdmaGetParameterOffset()
184 int currentId = pdu.read(); in cdmaGetParameterOffset()
185 int currentLen = pdu.read(); in cdmaGetParameterOffset()
191 pdu.skip(currentLen); in cdmaGetParameterOffset()
195 pdu.close(); in cdmaGetParameterOffset()
210 ByteArrayInputStream pdu = new ByteArrayInputStream(mData); in cdmaGetSubParameterOffset() local
215 pdu.skip(offset); in cdmaGetSubParameterOffset()
218 while (pdu.available() > 0) { in cdmaGetSubParameterOffset()
[all …]
DMmsFileProvider.java28 import com.google.android.mms.pdu.GenericPdu;
29 import com.google.android.mms.pdu.PduComposer;
30 import com.google.android.mms.pdu.PduPersister;
116 GenericPdu pdu = null; in writeDataToPipe() local
122 pdu = pduPersister.load(uri); in writeDataToPipe()
123 byte[] bytes = (new PduComposer(getContext(), pdu)).make(); in writeDataToPipe()
DBluetoothMapbMessageSms.java109 for (SmsPdu pdu : mSmsBodyPdus) { in encode()
112 encodeBinary(pdu.getData(), pdu.getScAddress()).getBytes("UTF-8")); in encode()
/packages/modules/CellBroadcastService/src/com/android/cellbroadcastservice/
DSmsCbHeader.java132 public SmsCbHeader(byte[] pdu) throws IllegalArgumentException { in SmsCbHeader() argument
133 if (pdu == null || pdu.length < PDU_HEADER_LENGTH) { in SmsCbHeader()
137 if (pdu.length <= PDU_LENGTH_GSM) { in SmsCbHeader()
142 mGeographicalScope = (pdu[0] & 0xc0) >>> 6; in SmsCbHeader()
143 mSerialNumber = ((pdu[0] & 0xff) << 8) | (pdu[1] & 0xff); in SmsCbHeader()
144 mMessageIdentifier = ((pdu[2] & 0xff) << 8) | (pdu[3] & 0xff); in SmsCbHeader()
145 if (isEtwsMessage() && pdu.length <= PDU_LENGTH_ETWS) { in SmsCbHeader()
150 boolean emergencyUserAlert = (pdu[4] & 0x1) != 0; in SmsCbHeader()
151 boolean activatePopup = (pdu[5] & 0x80) != 0; in SmsCbHeader()
152 int warningType = (pdu[4] & 0xfe) >>> 1; in SmsCbHeader()
[all …]
DGsmSmsCbMessage.java119 byte[] pdu = pdus[0]; in createSmsCbMessage()
120 Pair<String, String> cbData = parseUmtsBody(header, pdu); in createSmsCbMessage()
125 int nrPages = pdu[SmsCbHeader.PDU_HEADER_LENGTH]; in createSmsCbMessage()
133 if (pdu.length > wacDataOffset) { in createSmsCbMessage()
135 Pair<Integer, List<Geometry>> wac = parseWarningAreaCoordinates(pdu, in createSmsCbMessage()
154 for (byte[] pdu : pdus) { in createSmsCbMessage()
155 Pair<String, String> p = parseGsmBody(header, pdu); in createSmsCbMessage()
186 public static GeoFencingTriggerMessage createGeoFencingTriggerMessage(byte[] pdu) { in createGeoFencingTriggerMessage() argument
192 BitStreamReader bitReader = new BitStreamReader(pdu, whamOffset); in createGeoFencingTriggerMessage()
224 byte[] pdu, int wacOffset) { in parseWarningAreaCoordinates() argument
[all …]
DGsmAlphabet.java636 public static String gsm7BitPackedToString(byte[] pdu, int offset, in gsm7BitPackedToString() argument
638 return gsm7BitPackedToString(pdu, offset, lengthSeptets, 0, 0, 0); in gsm7BitPackedToString()
657 public static String gsm7BitPackedToString(byte[] pdu, int offset, in gsm7BitPackedToString() argument
691 gsmVal = (0x7f & (pdu[offset + byteOffset] >> shift)); in gsm7BitPackedToString()
698 gsmVal |= 0x7f & (pdu[offset + byteOffset + 1] << (8 - shift)); in gsm7BitPackedToString()
DGsmCellBroadcastHandler.java288 byte[] pdu = (byte[]) message.obj; in handleSmsMessage()
289 SmsCbHeader header = createSmsCbHeader(pdu); in handleSmsMessage()
295 GsmSmsCbMessage.createGeoFencingTriggerMessage(pdu); in handleSmsMessage()
300 SmsCbMessage cbMessage = handleGsmBroadcastSms(header, pdu, slotIndex); in handleSmsMessage()
416 for (byte[] pdu : pdus) { in handleGsmBroadcastSms()
417 if (pdu == null) { in handleGsmBroadcastSms()
/packages/services/Mms/src/com/android/mms/service/
DSendRequest.java40 import com.google.android.mms.pdu.EncodedStringValue;
41 import com.google.android.mms.pdu.GenericPdu;
42 import com.google.android.mms.pdu.PduComposer;
43 import com.google.android.mms.pdu.PduHeaders;
44 import com.google.android.mms.pdu.PduParser;
45 import com.google.android.mms.pdu.PduPersister;
46 import com.google.android.mms.pdu.SendConf;
47 import com.google.android.mms.pdu.SendReq;
181 GenericPdu pdu = (new PduParser(mPduData, supportContentDisposition)).parse(); in persistIfRequired() local
182 if (pdu == null) { in persistIfRequired()
[all …]
DMmsService.java19 import static com.google.android.mms.pdu.PduHeaders.MESSAGE_TYPE;
20 import static com.google.android.mms.pdu.PduHeaders.MESSAGE_TYPE_SEND_REQ;
53 import com.google.android.mms.pdu.DeliveryInd;
54 import com.google.android.mms.pdu.GenericPdu;
55 import com.google.android.mms.pdu.NotificationInd;
56 import com.google.android.mms.pdu.PduParser;
57 import com.google.android.mms.pdu.PduPersister;
58 import com.google.android.mms.pdu.ReadOrigInd;
59 import com.google.android.mms.pdu.RetrieveConf;
60 import com.google.android.mms.pdu.SendReq;
[all …]
DDownloadRequest.java42 import com.google.android.mms.pdu.GenericPdu;
43 import com.google.android.mms.pdu.PduHeaders;
44 import com.google.android.mms.pdu.PduParser;
45 import com.google.android.mms.pdu.PduPersister;
46 import com.google.android.mms.pdu.RetrieveConf;
118 final GenericPdu pdu = (new PduParser(response, supportMmsContentDisposition)).parse(); in persistIfRequired() local
119 if (pdu == null || !(pdu instanceof RetrieveConf)) { in persistIfRequired()
123 final RetrieveConf retrieveConf = (RetrieveConf) pdu; in persistIfRequired()
145 pdu, in persistIfRequired()
DMmsHttpClient.java119 public byte[] execute(String urlString, byte[] pdu, String method, boolean isProxySet, in execute() argument
124 + ", PDU size=" + (pdu != null ? pdu.length : 0)); in execute()
179 if (pdu == null || pdu.length < 1) { in execute()
195 connection.setFixedLengthStreamingMode(pdu.length); in execute()
199 out.write(pdu); in execute()
/packages/apps/CellBroadcastReceiver/tests/testapp/src/com/android/cellbroadcastreceiver/tests/
DGsmSmsCbMessage.java118 byte[] pdu = pdus[0]; in createSmsCbMessage()
119 Pair<String, String> cbData = parseUmtsBody(header, pdu); in createSmsCbMessage()
124 int nrPages = pdu[SmsCbHeader.PDU_HEADER_LENGTH]; in createSmsCbMessage()
132 if (pdu.length > wacDataOffset) { in createSmsCbMessage()
134 Pair<Integer, List<Geometry>> wac = parseWarningAreaCoordinates(pdu, in createSmsCbMessage()
153 for (byte[] pdu : pdus) { in createSmsCbMessage()
154 Pair<String, String> p = parseGsmBody(header, pdu); in createSmsCbMessage()
179 byte[] pdu, int wacOffset) { in parseWarningAreaCoordinates() argument
181 int wacDataLength = ((pdu[wacOffset + 1] & 0xff) << 8) | (pdu[wacOffset] & 0xff); in parseWarningAreaCoordinates()
184 if (offset + wacDataLength > pdu.length) { in parseWarningAreaCoordinates()
[all …]
DSendTestMessages.java391 private static SmsCbMessage createFromPdu(Context context, byte[] pdu, int serialNumber, in createFromPdu() argument
394 pdus[0] = pdu; in createFromPdu()
401 for (byte[] pdu : pdus) { in createFromPdus()
402 if (pdu.length <= 88) { in createFromPdus()
405 pdu[0] = (byte) ((serialNumber >>> 8) & 0xff); in createFromPdus()
406 pdu[1] = (byte) (serialNumber & 0xff); in createFromPdus()
409 pdu[2] = (byte) ((category >>> 8) & 0xff); in createFromPdus()
410 pdu[3] = (byte) (category & 0xff); in createFromPdus()
415 pdu[3] = (byte) ((serialNumber >>> 8) & 0xff); in createFromPdus()
416 pdu[4] = (byte) (serialNumber & 0xff); in createFromPdus()
[all …]
/packages/apps/Messaging/src/com/android/messaging/sms/
DMmsSender.java32 import com.android.messaging.mmslib.pdu.AcknowledgeInd;
33 import com.android.messaging.mmslib.pdu.EncodedStringValue;
34 import com.android.messaging.mmslib.pdu.GenericPdu;
35 import com.android.messaging.mmslib.pdu.NotifyRespInd;
36 import com.android.messaging.mmslib.pdu.PduComposer;
37 import com.android.messaging.mmslib.pdu.PduHeaders;
38 import com.android.messaging.mmslib.pdu.PduParser;
39 import com.android.messaging.mmslib.pdu.RetrieveConf;
40 import com.android.messaging.mmslib.pdu.SendConf;
41 import com.android.messaging.mmslib.pdu.SendReq;
[all …]
DMmsUtils.java54 import com.android.messaging.mmslib.pdu.CharacterSets;
55 import com.android.messaging.mmslib.pdu.EncodedStringValue;
56 import com.android.messaging.mmslib.pdu.GenericPdu;
57 import com.android.messaging.mmslib.pdu.NotificationInd;
58 import com.android.messaging.mmslib.pdu.PduBody;
59 import com.android.messaging.mmslib.pdu.PduComposer;
60 import com.android.messaging.mmslib.pdu.PduHeaders;
61 import com.android.messaging.mmslib.pdu.PduParser;
62 import com.android.messaging.mmslib.pdu.PduPart;
63 import com.android.messaging.mmslib.pdu.PduPersister;
[all …]
/packages/apps/Messaging/src/android/support/v7/mms/
DMmsRequest.java28 import androidx.appcompat.mms.pdu.GenericPdu;
29 import androidx.appcompat.mms.pdu.PduHeaders;
30 import androidx.appcompat.mms.pdu.PduParser;
31 import androidx.appcompat.mms.pdu.SendConf;
226 final GenericPdu pdu = new PduParser( in isWrongApnResponse() local
234 if (pdu != null && pdu instanceof SendConf) { in isWrongApnResponse()
235 final SendConf sendConf = (SendConf) pdu; in isWrongApnResponse()
DMmsHttpClient.java112 public byte[] execute(String urlString, byte[] pdu, String method, boolean isProxySet, in execute() argument
117 + ", PDU size=" + (pdu != null ? pdu.length : 0)); in execute()
153 if (pdu == null || pdu.length < 1) { in execute()
171 connection.setFixedLengthStreamingMode(pdu.length); in execute()
175 out.write(pdu); in execute()
DDownloadRequest.java80 final byte[] pdu) { in writePduToContentUri() argument
81 if (contentUri == null || pdu == null) { in writePduToContentUri()
91 outStream.write(pdu); in writePduToContentUri()
/packages/apps/Messaging/src/com/android/messaging/util/
DDebugUtils.java265 final byte[] pdu = message.getPdu();
266 dos.writeInt(pdu.length);
267 dos.write(pdu, 0, pdu.length);
303 final byte[] pdu = new byte[length];
304 dis.read(pdu, 0, length);
307 ? SmsMessage.createFromPdu(pdu, format)
308 : SmsMessage.createFromPdu(pdu);
/packages/apps/Messaging/src/com/android/messaging/mmslib/util/
DPduCacheEntry.java20 import com.android.messaging.mmslib.pdu.GenericPdu;
27 public PduCacheEntry(GenericPdu pdu, int msgBox, long threadId) { in PduCacheEntry() argument
28 mPdu = pdu; in PduCacheEntry()
/packages/apps/Messaging/src/com/android/messaging/mmslib/pdu/
DPduPersister.java18 package com.android.messaging.mmslib.pdu;
563 GenericPdu pdu = null; in load() local
620 pdu = createPdu(msgType, headers, body); in load()
623 if (pdu != null) { in load()
626 cacheEntry = new PduCacheEntry(pdu, msgBox, threadId); in load()
633 return pdu; in load()
1304 public Uri persist(final GenericPdu pdu, final Uri uri, final int subId, in persist() argument
1342 final PduHeaders header = pdu.getPduHeaders(); in persist()
1403 final int msgType = pdu.getMessageType(); in persist()
1449 if (pdu instanceof MultimediaMessagePdu) { in persist()
[all …]
DPduComposer.java18 package com.android.messaging.mmslib.pdu;
137 public PduComposer(final Context context, final GenericPdu pdu) { in PduComposer() argument
138 mPdu = pdu; in PduComposer()
140 mPduHeader = pdu.getPduHeaders(); in PduComposer()
/packages/apps/Bluetooth/src/com/android/bluetooth/util/
DGsmAlphabet.java142 public static String gsm7BitPackedToString(byte[] pdu, int offset, int lengthSeptets, in gsm7BitPackedToString() argument
177 gsmVal = (0x7f & (pdu[offset + byteOffset] >> shift)); in gsm7BitPackedToString()
184 gsmVal |= 0x7f & (pdu[offset + byteOffset + 1] << (8 - shift)); in gsm7BitPackedToString()

1234