/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/zip/ |
D | RandomAccessFileZipDataInput.java | 43 public RandomAccessFileZipDataInput(RandomAccessFile file, long offset, long size) { in RandomAccessFileZipDataInput() argument 44 if (offset < 0) { in RandomAccessFileZipDataInput() 45 throw new IndexOutOfBoundsException("offset: " + offset); in RandomAccessFileZipDataInput() 52 this.startIndex = offset; in RandomAccessFileZipDataInput() 69 public void copyTo(long offset, long size, ZipDataOutput output) throws IOException { in copyTo() argument 71 checkBoundValid(offset, size, srcSize); in copyTo() 75 long offsetInFile = startIndex + offset; in copyTo() 92 public void copyTo(long offset, int size, ByteBuffer buffer) throws IOException { in copyTo() argument 94 checkBoundValid(offset, size, srcSize); in copyTo() 101 long offsetInFile = startIndex + offset; in copyTo() [all …]
|
D | ByteBufferZipDataInput.java | 45 public void copyTo(long offset, long size, ZipDataOutput output) throws IOException { in copyTo() argument 49 output.write(createByteBuffer(offset, (int) size)); in copyTo() 53 public void copyTo(long offset, int size, ByteBuffer buffer) throws IOException { in copyTo() argument 54 buffer.put(createByteBuffer(offset, size)); in copyTo() 58 public ByteBuffer createByteBuffer(long offset, int size) { in createByteBuffer() argument 59 checkChunkValid(offset, size); in createByteBuffer() 60 int position = (int) offset; in createByteBuffer() 71 public ZipDataInput slice(long offset, long size) { in slice() argument 72 if (offset == 0 && size == sourceSize) { in slice() 78 ByteBuffer byteBuffer = createByteBuffer(offset, (int) size); in slice() [all …]
|
D | RandomAccessFileZipDataOutput.java | 50 public void write(byte[] buffer, int offset, int length) throws IOException { in write() argument 51 if (offset < 0) { in write() 52 throw new IndexOutOfBoundsException("offset: " + offset); in write() 54 if (offset > buffer.length) { in write() 55 …throw new IndexOutOfBoundsException("offset (" + offset + ") > buffer length(" + buffer.length + "… in write() 62 file.write(buffer, offset, length); in write()
|
D | ZipDataInput.java | 42 void copyTo(long offset, long size, ZipDataOutput output) throws IOException; in copyTo() argument 52 void copyTo(long offset, int size, ByteBuffer buffer) throws IOException; in copyTo() argument 62 ByteBuffer createByteBuffer(long offset, int size) throws IOException; in createByteBuffer() argument 70 ZipDataInput slice(long offset, long size); in slice() argument
|
D | ZipUtils.java | 135 public static void setCentralDirectoryOffset(ByteBuffer eocd, long offset) { in setCentralDirectoryOffset() argument 137 setUInt32ToBuffer(eocd, eocd.position() + ZIP_CENTRAL_DIR_OFFSET_IN_EOCD, offset); in setCentralDirectoryOffset() 169 static int getUInt16FromBuffer(ByteBuffer buffer, int offset) { in getUInt16FromBuffer() argument 170 return buffer.getShort(offset) & 0xffff; in getUInt16FromBuffer() 173 static long getUInt32FromBuffer(ByteBuffer buffer, int offset) { in getUInt32FromBuffer() argument 174 return buffer.getInt(offset) & UINT32_MAX_VALUE; in getUInt32FromBuffer() 177 private static void setUInt32ToBuffer(ByteBuffer buffer, int offset, long value) { in setUInt32ToBuffer() argument 181 buffer.putInt(buffer.position() + offset, (int) value); in setUInt32ToBuffer()
|
D | MessageDigestZipDataOutput.java | 35 public void write(byte[] buffer, int offset, int length) throws IOException { in write() argument 37 messageDigest.update(buffer, offset, length); in write()
|
/developtools/profiler/host/smartperf/ide/src/hdc/common/ |
D | Serialize.ts | 71 let offset = 0; 73 offset += fileSizeValue.length; 74 mergedArray.set(atimeValue, offset) 75 offset += atimeValue.length; 76 mergedArray.set(mtimeValue, offset) 77 offset += mtimeValue.length; 78 mergedArray.set(optionsValue, offset) 79 offset += optionsValue.length; 80 mergedArray.set(pathValue, offset) 81 offset += pathValue.length; [all …]
|
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/hap/entity/ |
D | HwBlockHead.java | 46 public static byte[] getBlockHead(char type, char tag, short length, int offset) { in getBlockHead() argument 52 (byte) ((offset >> TRIPLE_BIT_SIZE) & 0xff), in getBlockHead() 53 (byte) ((offset >> DOUBLE_BIT_SIZE) & 0xff), in getBlockHead() 54 (byte) ((offset >> BIT_SIZE) & 0xff), in getBlockHead() 55 (byte) (offset & 0xff) in getBlockHead()
|
/developtools/profiler/device/plugins/ftrace_plugin/test/unittest/ |
D | ftrace_field_parser_test.cpp | 37 size_t offset = buffer_.size(); in AppendInt() local 39 if (memcpy_s(&buffer_[offset], buffer_.capacity() - offset, &value, sizeof(value))) { in AppendInt() 44 format.offset = offset; in AppendInt() 53 size_t offset = buffer_.size(); in AppendString() local 55 if (memcpy_s(&buffer_[offset], buffer_.capacity() - offset, &str[0], str.size())) { in AppendString() 60 format.offset = offset; in AppendString()
|
/developtools/profiler/device/plugins/native_hook/src/ |
D | runtime_stack_range.cpp | 113 int offset = 0; in GetAnUnlimitedLine() local 116 if (offset + length >= static_cast<int>(buf.size())) { in GetAnUnlimitedLine() 119 retLine = fgets(&buf[0] + offset, buf.size() - offset, fp); in GetAnUnlimitedLine() 123 length = static_cast<int>(strlen(&buf[0] + offset)); in GetAnUnlimitedLine() 124 if (offset + length - 1 >= 0 && buf[offset + length - 1] == '\n') { in GetAnUnlimitedLine() 127 offset += length; in GetAnUnlimitedLine()
|
/developtools/hiperf/src/ |
D | perf_file_writer.cpp | 62 attrSection_.offset = 0; in Open() 152 if (fseek(fp_, dataSection_.offset, SEEK_SET) != 0) { in ReadDataSection() 156 HLOGD("dataSection_ at offset %" PRIu64 " + %" PRIu64 "", dataSection_.offset, in ReadDataSection() 227 off_t offset = ftello(fp_); in GetFilePos() local 228 if (offset == -1) { in GetFilePos() 232 pos = static_cast<uint64_t>(offset); in GetFilePos() 286 fileAttr.ids.offset = idSectionOffset; in WriteAttrAndId() 300 attrSection_.offset = attrSectionOffset; in WriteAttrAndId() 302 dataSection_.offset = dataSectionOffset; in WriteAttrAndId() 326 header_.eventTypes.offset = 0; in WriteHeader() [all …]
|
D | perf_file_reader.cpp | 123 featureSectionOffset_ = header_.data.offset + header_.data.size; in ReadFileHeader() 151 if (fseek(fp_, header_.attrs.offset, SEEK_SET) != 0) { in ReadAttrSection() 198 if (fseek(fp_, attr.ids.offset, SEEK_SET) != 0) { in ReadIdsForAttr() 224 if (fseek(fp_, header_.data.offset, SEEK_SET) != 0) { in ReadDataSection() 229 HLOGD("dataSection_ at offset %" PRId64 " + %" PRId64 "", header_.data.offset, in ReadDataSection() 337 bool PerfFileReader::Read(char *buf, uint64_t offset, size_t len) in Read() argument 344 if (fseek(fp_, offset, SEEK_SET) != 0) { in Read() 353 HLOGM("offset %" PRIx64 " len %zu buf %x %x %x %x", offset, len, buf[0], buf[1], buf[2], in Read() 414 sectionHeader.offset, sectionHeader.size); in ReadFeatureSection() 421 if (!Read(&buf[0], sectionHeader.offset, buf.size())) { in ReadFeatureSection() [all …]
|
/developtools/global_resource_tool/src/ |
D | resource_append.cpp | 513 int32_t offset = 0; in LoadResourceItemFromMem() local 516 string nameStr = ParseString(buffer, length, offset); in LoadResourceItemFromMem() 518 string limitKeyStr = ParseString(buffer, length, offset); in LoadResourceItemFromMem() 520 string filePathStr = ParseString(buffer, length, offset); in LoadResourceItemFromMem() 522 int32_t type = ParseInt32(buffer, length, offset); in LoadResourceItemFromMem() 525 int32_t keyParamSize = ParseInt32(buffer, length, offset); in LoadResourceItemFromMem() 529 keyParam.keyType = static_cast<KeyType>(ParseInt32(buffer, length, offset)); in LoadResourceItemFromMem() 530 keyParam.value = ParseInt32(buffer, length, offset); in LoadResourceItemFromMem() 534 string data = ParseString(buffer, length, offset); in LoadResourceItemFromMem() 558 } while (offset < length); in LoadResourceItemFromMem() [all …]
|
D | file_entry.cpp | 264 string::size_type offset = 0; in GetSegments() local 265 string::size_type pos = filePath_.find_first_of(SEPARATE.front(), offset); in GetSegments() 267 segments.push_back(filePath_.substr(offset, pos - offset)); in GetSegments() 268 offset = pos + 1; in GetSegments() 269 pos = filePath_.find_first_of(SEPARATE.front(), offset); in GetSegments() 272 if (offset < filePath_.length()) { in GetSegments() 273 segments.push_back(filePath_.substr(offset)); in GetSegments() 320 bool FileEntry::CreateDirsInner(const string &path, string::size_type offset) in CreateDirsInner() argument 322 string::size_type pos = path.find_first_of(SEPARATE.front(), offset); in CreateDirsInner()
|
D | resource_table.cpp | 183 …pos += sizeof(limitKeyConfig.keyTag) + sizeof(limitKeyConfig.offset) + sizeof(limitKeyConfig.keyCo… in Prepare() 198 limitKeyConfig->second.offset = pos; in Prepare() 262 out.write(reinterpret_cast<const char *>(&iter.second.offset), sizeof(uint32_t)); in SaveLimitKeyConfigs() 311 in.read(reinterpret_cast<char *>(&limitKey.offset), INT_TO_BYTES); in ReadLimitKeys() 326 limitKeys[limitKey.offset] = keyParams; in ReadLimitKeys() 341 int32_t offset = in.tellg(); in ReadIdTables() local 359 datas[data.dataOffset] = make_pair(data.id, offset); in ReadIdTables() 388 int32_t offset = in.tellg(); in ReadDataRecordStart() local 389 offset = offset - INT_TO_BYTES - INT_TO_BYTES - INT_TO_BYTES; in ReadDataRecordStart() 409 auto idTableOffset = datas.find(offset); in ReadDataRecordStart() [all …]
|
/developtools/global_resource_tool/src/xml/ |
D | xml_key_node.cpp | 91 string::size_type offset = 0; in LoadFromFile() local 92 while (offset < inputLine.length()) { in LoadFromFile() 93 string item(inputLine.c_str() + offset); in LoadFromFile() 94 offset = offset + item.length() + sizeof(char); in LoadFromFile()
|
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/hap/sign/ |
D | SignHap.java | 96 long offset = INIT_OFFSET_LEN; in copyFiles() local 103 offset += JarFile.LOCHDR; in copyFiles() 111 offset += outEntry.getName().length(); in copyFiles() 114 if (alignment > 0 && (offset % alignment != 0)) { in copyFiles() 115 int needed = alignment - (int) (offset % alignment); in copyFiles() 117 offset += needed; in copyFiles() 126 offset += num; in copyFiles() 277 int offset = 0; in generateHapSigningBlock() local 281 offset = typeAndOffsetMap.get(optionalBlock.getType()); in generateHapSigningBlock() 282 result.putInt(offset); // offset in generateHapSigningBlock() [all …]
|
D | SignBin.java | 104 long offset = binFileLen + HwBlockHead.getBlockLen() + HwBlockHead.getBlockLen(); in writeBlockDataToFile() local 105 if (isLongOverflowInteger(offset)) { in writeBlockDataToFile() 106 … LOGGER.error("The profile block head offset is overflow interger range, offset: " + offset); in writeBlockDataToFile() 111 …BlockHead.getBlockHead(isSigned, SignatureBlockTags.DEFAULT, (short) profileDataLen, (int) offset); in writeBlockDataToFile() 113 offset += profileDataLen; in writeBlockDataToFile() 114 if (isLongOverflowInteger(offset)) { in writeBlockDataToFile() 115 … LOGGER.error("The sign block head offset is overflow integer range, offset: " + offset); in writeBlockDataToFile() 119 … SignatureBlockTypes.SIGNATURE_BLOCK, SignatureBlockTags.DEFAULT, (short) 0, (int) offset); in writeBlockDataToFile()
|
/developtools/profiler/host/smartperf/client/client_ui/entry/src/main/ets/common/ui/detail/chart/components/ |
D | ComponentBase.ets | 29 * the offset in pixels this component has on the x-axis 34 * the offset in pixels this component has on the Y-axis 59 * Returns the used offset on the x-axis for drawing the axis or legend 60 * labels. This offset is applied before and after the label. 69 * Sets the used x-axis offset for the labels on this axis. 78 * Returns the used offset on the x-axis for drawing the axis labels. This 79 * offset is applied before and after the label. 88 * Sets the used y-axis offset for the labels on this axis. For the legend, 89 * higher offset means the legend as a whole will be placed further away
|
/developtools/hapsigner/hapsigntool/hap_sign_tool_lib/src/main/java/com/ohos/hapsigntool/utils/ |
D | FileUtils.java | 308 int offset = 0; in toByteArray() local 311 while (offset < size && (read = input.read(data, offset, size - offset)) != FILE_END) { in toByteArray() 312 offset += read; in toByteArray() 315 if (offset != size) { in toByteArray() 316 … throw new IOException("Unexpected read size. current: " + offset + ", expected: " + size); in toByteArray()
|
D | HapUtils.java | 281 long offset = 0L; in computeDigests() local 290 content.copyTo(offset, chunkSize, digests); in computeDigests() 296 offset += chunkSize; in computeDigests() 349 private static void setUInt32ToByteArrayWithLittleEngian(int value, byte[] result, int offset) { in setUInt32ToByteArrayWithLittleEngian() argument 351 result[offset + i] = (byte) ((value >> (BIT_SIZE * i)) & 0xff); in setUInt32ToByteArrayWithLittleEngian() 539 private final long offset; field in HapUtils.HapSignBlockInfo 543 public HapSignBlockInfo(long offset, int version, ByteBuffer content) { in HapSignBlockInfo() argument 544 this.offset = offset; in HapSignBlockInfo() 558 return offset; in getOffset()
|
/developtools/profiler/host/smartperf/trace_streamer/src/parser/hiperf_parser/hiperf/ |
D | perf_file_reader.cpp | 150 featureSectionOffset_ = header_.data.offset + header_.data.size; in ReadFileHeader() 178 if (!SeekFromBegin(header_.attrs.offset)) { in ReadAttrSection() 224 if (!SeekFromBegin(attr.ids.offset)) { in ReadIdsForAttr() 249 if (!SeekFromBegin(header_.data.offset)) { in ReadDataSection() 253 HLOGD("dataSection_ at offset %" PRId64 " + %" PRId64 "", header_.data.offset, in ReadDataSection() 367 bool PerfFileReader::Read(char *buf, uint64_t offset, size_t len) in Read() argument 374 if (!SeekFromBegin(offset)) { in Read() 388 HLOGM("offset %" PRIx64 " len %zu buf %x %x %x %x", offset, len, buf[0], buf[1], buf[2], in Read() 449 sectionHeader.offset, sectionHeader.size); in ReadFeatureSection() 462 if (!Read(&buf[0], sectionHeader.offset, buf.size())) { in ReadFeatureSection() [all …]
|
/developtools/profiler/device/services/profiler_service/src/ |
D | trace_file_reader.cpp | 63 size_t offset = GetReadPos(stream_); in Read() local 67 …tream_, 0, "read msg length from %s (offset %zu) failed, or no more data!", path_.c_str(), offset); in Read() 72 offset = GetReadPos(stream_); in Read() 75 CHECK_TRUE(stream_, 0, "read msg bytes from %s (offset %zu) failed!", path_.c_str(), offset); in Read()
|
/developtools/profiler/host/smartperf/ide/src/hdc/ |
D | HdcDeviceManager.ts | 226 let offset = 0; 242 finalBuffer.set(new Uint8Array(resRS), offset); 243 offset += resRS.byteLength; 244 callBack((offset / hdcStream.fileSize * 100).toFixed(3)) 247 if (hdcStream.fileSize != -1 && offset >= hdcStream.fileSize) {
|
/developtools/packing_tool/adapter/ohos/ |
D | ResourcesParser.java | 188 int offset; field in ResourcesParser.ConfigIndex 284 cfg.offset = bufBuf.getInt(); in loadBaseConfig() 310 buf.position(configIndex.offset); in readBaseItem() 316 int offset = buf.getInt(); in readBaseItem() local 319 buf.position(offset); in readBaseItem() 361 cfg.offset = bufBuf.getInt(); in loadConfig() 388 buf.position(index.offset); in readAllItem() 394 int offset = buf.getInt(); in readAllItem() local 397 buf.position(offset); in readAllItem() 458 buf.position(index.offset); in readDataAllItem() [all …]
|