Home
last modified time | relevance | path

Searched refs:numBytes (Results 1 – 25 of 34) sorted by relevance

12

/packages/modules/IPsec/src/java/com/android/internal/net/ipsec/ike/testmode/
DDeterministicSecureRandom.java79 private byte[] generateBytes(int numBytes) { in generateBytes() argument
82 this, null /* keyBytes; unused */, mBytesToSign, numBytes); in generateBytes()
87 public byte[] generateSeed(int numBytes) { in generateSeed() argument
88 return generateBytes(numBytes); in generateSeed()
/packages/modules/StatsD/statsd/src/metrics/
DKllMetricProducer.cpp86 const size_t numBytes = aggProto.ByteSizeLong(); in writePastBucketAggregateToProto() local
87 const unique_ptr<char[]> buffer(new char[numBytes]); in writePastBucketAggregateToProto()
88 aggProto.SerializeToArray(&buffer[0], numBytes); in writePastBucketAggregateToProto()
89 protoOutput->write(FIELD_TYPE_BYTES | FIELD_ID_KLL_SKETCH, &buffer[0], numBytes); in writePastBucketAggregateToProto()
91 VLOG("\t\t sketch %d: %zu bytes", aggIndex, numBytes); in writePastBucketAggregateToProto()
/packages/modules/StatsD/framework/java/android/util/
DStatsEvent.java248 @NonNull final byte[] payload, final int numBytes) { in StatsEvent() argument
252 mNumBytes = numBytes; in StatsEvent()
478 final int numBytes = value.length; in writeByteArray() local
479 mPos += mBuffer.putInt(mPos, numBytes); in writeByteArray()
913 private boolean hasEnoughSpace(final int index, final int numBytes) { in hasEnoughSpace() argument
914 final int totalBytesNeeded = index + numBytes; in hasEnoughSpace()
1025 final int numBytes = value.length; in putByteArray() local
1026 if (hasEnoughSpace(index, numBytes)) { in putByteArray()
1027 System.arraycopy(value, 0, mBytes, index, numBytes); in putByteArray()
1028 return numBytes; in putByteArray()
/packages/apps/Camera2/src/com/android/camera/processing/imagebackend/
DTaskCompressImageToJpeg.java119 int numBytes; in run() local
235 numBytes = compressedData.limit(); in run()
283 numBytes = compressJpegFromYUV420Image( in run()
289 if (numBytes > jpgBufferSize) { in run()
302 numBytes = compressJpegFromYUV420Image( in run()
307 if (numBytes < 0) { in run()
311 compressedData.limit(numBytes); in run()
324 writeOut = new byte[numBytes]; in run()
/packages/modules/StatsD/statsd/src/config/
DConfigManager.cpp73 const int numBytes = config.ByteSize(); in UpdateConfig() local
74 vector<uint8_t> buffer(numBytes); in UpdateConfig()
75 config.SerializeToArray(buffer.data(), numBytes); in UpdateConfig()
95 update_saved_configs_locked(key, buffer, numBytes); in UpdateConfig()
100 update_saved_configs_locked(key, buffer, numBytes); in UpdateConfig()
373 const int numBytes) { in update_saved_configs_locked() argument
381 StorageManager::writeFile(file_name.c_str(), &buffer[0], numBytes); in update_saved_configs_locked()
DConfigManager.h169 const int numBytes);
/packages/modules/adb/fastdeploy/deployagent/src/com/android/fastdeploy/
DPatchUtils.java50 final int numBytes) throws IOException { in readFully() argument
52 while (numRead < numBytes) { in readFully()
53 int readNow = in.read(destination, startAt + numRead, numBytes - numRead); in readFully()
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/system/development/audio/
DWavWriter.java64 private static void writeFileHeader(DataOutputStream stream, int numBytes) throws IOException { in writeFileHeader() argument
68 stream.write(toLittleEndianBytes(HEADER_SIZE + numBytes - 8)); in writeFileHeader()
94 stream.write(toLittleEndianBytes(numBytes), 0, 4); in writeFileHeader()
DAudioDebug.java103 int numBytes = numShorts * 2; in onAudioRecorded() local
118 .setBufferSizeInBytes(numBytes) in onAudioRecorded()
131 Log.i(TAG, String.format("Wrote %d bytes to an AudioTrack", numBytes)); in onAudioRecorded()
/packages/apps/TvSettings/SettingsAPI/java/com/android/tv/settings/library/system/development/audio/
DWavWriter.java64 private static void writeFileHeader(DataOutputStream stream, int numBytes) throws IOException { in writeFileHeader() argument
68 stream.write(toLittleEndianBytes(HEADER_SIZE + numBytes - 8)); in writeFileHeader()
94 stream.write(toLittleEndianBytes(numBytes), 0, 4); in writeFileHeader()
DAudioDebug.java103 int numBytes = numShorts * 2; in onAudioRecorded() local
118 .setBufferSizeInBytes(numBytes) in onAudioRecorded()
131 Log.i(TAG, String.format("Wrote %d bytes to an AudioTrack", numBytes)); in onAudioRecorded()
/packages/modules/StatsD/statsd/src/logd/
DLogEvent.cpp108 int32_t numBytes = readNextValue<int32_t>(); in parseString() local
109 if ((uint32_t)numBytes > mRemainingLen) { in parseString()
114 string value = string((char*)mBuf, numBytes); in parseString()
115 mBuf += numBytes; in parseString()
116 mRemainingLen -= numBytes; in parseString()
135 int32_t numBytes = readNextValue<int32_t>(); in parseByteArray() local
136 if ((uint32_t)numBytes > mRemainingLen) { in parseByteArray()
141 vector<uint8_t> value(mBuf, mBuf + numBytes); in parseByteArray()
142 mBuf += numBytes; in parseByteArray()
143 mRemainingLen -= numBytes; in parseByteArray()
/packages/services/Car/tests/ConcurrentHotwordDetector/src/com/android/car/test/concurrent/hotword/
DConcurrentHotwordDetectionService.java192 int numBytes = 0; in canReadAudio() local
193 while (numBytes < buffer.length) { in canReadAudio()
195 record.read(buffer, numBytes, Math.min(1024, buffer.length - numBytes)); in canReadAudio()
200 numBytes += bytesRead; in canReadAudio()
/packages/apps/TV/tuner/sampletunertvinput/src/com/android/tv/samples/sampletunertvinput/
DSampleTunerTvInputSectionParser.java203 int numBytes = data[pos + 2] & 0xff; in parseMultipleStringStructure() local
205 if (data.length < pos + numBytes) { in parseMultipleStringStructure()
210 return new String(data, pos, numBytes, StandardCharsets.UTF_16); in parseMultipleStringStructure()
212 pos += numBytes; in parseMultipleStringStructure()
/packages/modules/StatsD/lib/libstatssocket/
Dstats_event.c229 void AStatsEvent_writeByteArray(AStatsEvent* event, const uint8_t* buf, size_t numBytes) { in AStatsEvent_writeByteArray() argument
232 numBytes = 0; in AStatsEvent_writeByteArray()
234 append_int32(event, numBytes); in AStatsEvent_writeByteArray()
235 if (numBytes > 0) { in AStatsEvent_writeByteArray()
236 append_byte_array(event, buf, numBytes); in AStatsEvent_writeByteArray()
/packages/services/BuiltInPrintService/jni/plugins/genPCLm/inc/
DPCLmGenerator.h98 int injectRLEStrip(ubyte *RLEBuffer, int numBytes, int imageWidth, int imageHeight,
104 int injectLZStrip(ubyte *LZBuffer, int numBytes, int imageWidth, int imageHeight,
/packages/services/Car/tests/EmbeddedKitchenSinkApp/src/com/google/android/car/kitchensink/backup/
DKitchenSinkBackupTransport.java511 public int sendBackupData(final int numBytes) { in sendBackupData() argument
518 mFullBackupSize += numBytes; in sendBackupData()
523 if (numBytes > mFullBackupBuffer.length) { in sendBackupData()
524 mFullBackupBuffer = new byte[numBytes]; in sendBackupData()
539 int bytesLeft = numBytes; in sendBackupData()
557 Log.d(TAG, "Stored " + numBytes + " of data"); in sendBackupData()
/packages/modules/DnsResolver/
Dres_cache.cpp318 static int _dnsPacket_checkBytes(DnsPacket* packet, int numBytes, const void* bytes) { in _dnsPacket_checkBytes() argument
321 if (p + numBytes > packet->end) return 0; in _dnsPacket_checkBytes()
323 if (memcmp(p, bytes, numBytes) != 0) return 0; in _dnsPacket_checkBytes()
325 packet->cursor = p + numBytes; in _dnsPacket_checkBytes()
456 static unsigned _dnsPacket_hashBytes(DnsPacket* packet, int numBytes, unsigned hash) { in _dnsPacket_hashBytes() argument
460 while (numBytes > 0 && p < end) { in _dnsPacket_hashBytes()
462 numBytes--; in _dnsPacket_hashBytes()
602 static int _dnsPacket_isEqualBytes(DnsPacket* pack1, DnsPacket* pack2, int numBytes) { in _dnsPacket_isEqualBytes() argument
606 if (p1 + numBytes > pack1->end || p2 + numBytes > pack2->end) return 0; in _dnsPacket_isEqualBytes()
608 if (memcmp(p1, p2, numBytes) != 0) return 0; in _dnsPacket_isEqualBytes()
[all …]
/packages/modules/adb/client/
Dusb_osx.cpp560 UInt32 numBytes = len; in usb_read() local
580 result = (*handle->interface)->ReadPipe(handle->interface, handle->bulkIn, buf, &numBytes); in usb_read()
585 result = (*handle->interface)->ReadPipe(handle->interface, handle->bulkIn, buf, &numBytes); in usb_read()
589 return numBytes; in usb_read()
/packages/modules/StatsD/tests/utils/src/android/util/
DStatsEventTestUtils.java164 final int numBytes = buf.getInt(); in getByteArrayFromByteBuffer() local
165 byte[] bytes = new byte[numBytes]; in getByteArrayFromByteBuffer()
/packages/services/BuiltInPrintService/jni/plugins/genPCLm/src/
DgenPCLm.cpp437 int PCLmGenerator::injectRLEStrip(ubyte *RLEBuffer, int numBytes, int imageWidth, int imageHeight, in injectRLEStrip() argument
489 sprintf(pOutStr, "/Length %d\n", numBytes); in injectRLEStrip()
511 write2Buff(RLEBuffer, numBytes); in injectRLEStrip()
526 int PCLmGenerator::injectLZStrip(ubyte *LZBuffer, int numBytes, int imageWidth, int imageHeight, in injectLZStrip() argument
578 sprintf(pOutStr, "/Length %d\n", numBytes); in injectLZStrip()
600 write2Buff(LZBuffer, numBytes); in injectLZStrip()
993 sint32 numBytes = imageHeight * imageWidth * numComponents; in prepImageForBacksideDuplex() local
997 for (head = imagePtr, tail = imagePtr + numBytes - 1; tail > head;) { in prepImageForBacksideDuplex()
1013 for (head = imagePtr, tail = imagePtr + numBytes; tail > head;) { in prepImageForBacksideDuplex()
/packages/modules/StatsD/lib/libstatssocket/include/
Dstats_event.h124 void AStatsEvent_writeByteArray(AStatsEvent* event, const uint8_t* buf, size_t numBytes);
/packages/modules/StatsD/statsd/src/storage/
DStorageManager.h63 static void writeFile(const char* file, const void* buffer, int numBytes);
/packages/apps/TV/tuner/src/com/android/tv/tuner/data/
DSectionParser.java2012 int numBytes = data[pos + 2] & 0xff; in extractText() local
2013 if (data.length < pos + 3 + numBytes) { in extractText()
2020 return new String(data, pos + 3, numBytes, StandardCharsets.ISO_8859_1); in extractText()
2023 return new String(data, pos + 3, numBytes, SCSU_CHARSET); in extractText()
2029 return new String(data, pos + 3, numBytes, StandardCharsets.UTF_16); in extractText()
2035 pos += 3 + numBytes; in extractText()
/packages/apps/Camera2/src/com/android/camera/one/v2/
DOneCameraImpl.java833 int numBytes = JpegUtilNative.compressJpegFromYUV420Image( in acquireJpegBytesAndClose() local
836 if (numBytes < 0) { in acquireJpegBytesAndClose()
839 buffer.limit(numBytes); in acquireJpegBytesAndClose()

12