/external/okhttp/okio/okio/src/test/java/okio/ |
D | BufferTest.java | 64 buffer.writeUtf8(repeat('a', Segment.SIZE * 4)); in completeSegmentByteCountOnBufferWithFullSegments() 65 assertEquals(Segment.SIZE * 4, buffer.completeSegmentByteCount()); in completeSegmentByteCountOnBufferWithFullSegments() 70 buffer.writeUtf8(repeat('a', Segment.SIZE * 4 - 10)); in completeSegmentByteCountOnBufferWithIncompleteTailSegment() 71 assertEquals(Segment.SIZE * 3, buffer.completeSegmentByteCount()); in completeSegmentByteCountOnBufferWithIncompleteTailSegment() 141 int size = (Segment.SIZE / 2) - 1; in moveBytesBetweenBuffersShareSegment() 147 int size = (Segment.SIZE / 2) + 1; in moveBytesBetweenBuffersReassignSegment() 153 int size = 3 * Segment.SIZE + 1; in moveBytesBetweenBuffersMultipleSegments() 155 assertEquals(asList(Segment.SIZE, Segment.SIZE, Segment.SIZE, 1, in moveBytesBetweenBuffersMultipleSegments() 156 Segment.SIZE, Segment.SIZE, Segment.SIZE, 1), segmentSizes); in moveBytesBetweenBuffersMultipleSegments() 175 int writeSize = Segment.SIZE / 2 + 1; in writeSplitSourceBufferLeft() [all …]
|
D | RealBufferedSourceTest.java | 36 source.writeUtf8(repeat('b', Segment.SIZE)); in inputStreamTracksSegments() 41 assertEquals(Segment.SIZE + 2, source.size()); in inputStreamTracksSegments() 45 assertEquals(Segment.SIZE - 1, in.available()); in inputStreamTracksSegments() 49 byte[] data = new byte[Segment.SIZE * 2]; in inputStreamTracksSegments() 50 assertEquals(Segment.SIZE - 1, in.read(data, 0, data.length)); in inputStreamTracksSegments() 51 assertEquals(repeat('b', Segment.SIZE - 1), new String(data, 0, Segment.SIZE - 1, UTF_8)); in inputStreamTracksSegments() 119 source.writeUtf8(repeat('a', Segment.SIZE)); in requireReadsOneSegmentAtATime() 120 source.writeUtf8(repeat('b', Segment.SIZE)); in requireReadsOneSegmentAtATime() 125 assertEquals(Segment.SIZE, source.size()); in requireReadsOneSegmentAtATime() 126 assertEquals(Segment.SIZE, bufferedSource.buffer().size()); in requireReadsOneSegmentAtATime() [all …]
|
D | BufferedSourceTest.java | 148 sink.writeUtf8(repeat('a', Segment.SIZE - 1)); in readShortSplitAcrossMultipleSegments() 150 source.skip(Segment.SIZE - 1); in readShortSplitAcrossMultipleSegments() 176 sink.writeUtf8(repeat('a', Segment.SIZE - 3)); in readIntSplitAcrossMultipleSegments() 180 source.skip(Segment.SIZE - 3); in readIntSplitAcrossMultipleSegments() 208 sink.writeUtf8(repeat('a', Segment.SIZE - 7)); in readLongSplitAcrossMultipleSegments() 213 source.skip(Segment.SIZE - 7); in readLongSplitAcrossMultipleSegments() 277 data.writeUtf8("Hello").writeUtf8(repeat('e', Segment.SIZE)); in readFullyByteArray() 282 byte[] sink = new byte[Segment.SIZE + 5]; in readFullyByteArray() 350 String string = "abcd" + repeat('e', Segment.SIZE); in readByteArray() 362 sink.writeUtf8("abcd").writeUtf8(repeat('e', Segment.SIZE)); in readByteString() [all …]
|
D | RealBufferedSinkTest.java | 46 bufferedSink.writeUtf8(repeat('a', Segment.SIZE - 1)); in bufferedSinkEmitsTailWhenItIsComplete() 49 assertEquals(Segment.SIZE, sink.size()); in bufferedSinkEmitsTailWhenItIsComplete() 56 bufferedSink.writeUtf8(repeat('a', Segment.SIZE * 4 - 1)); in bufferedSinkEmitMultipleSegments() 57 assertEquals(Segment.SIZE * 3, sink.size()); in bufferedSinkEmitMultipleSegments() 58 assertEquals(Segment.SIZE - 1, bufferedSink.buffer().size()); in bufferedSinkEmitMultipleSegments() 97 bufferedSink.writeUtf8(repeat('a', Segment.SIZE * 3)); in completeSegmentsEmitted() 98 assertEquals(Segment.SIZE * 3, sink.size()); in completeSegmentsEmitted() 104 bufferedSink.writeUtf8(repeat('a', Segment.SIZE * 3 - 1)); in incompleteSegmentsNotEmitted() 105 assertEquals(Segment.SIZE * 2, sink.size()); in incompleteSegmentsNotEmitted() 226 Buffer write1 = new Buffer().writeUtf8(TestUtil.repeat('a', Segment.SIZE)); in writeAllWritesOneSegmentAtATime() [all …]
|
/external/okio/okio/src/commonTest/kotlin/okio/ |
D | CommonBufferTest.kt | 114 val size = Segment.SIZE / 2 - 1 in moveBytesBetweenBuffersShareSegment() 120 val size = Segment.SIZE / 2 + 1 in moveBytesBetweenBuffersReassignSegment() 126 val size = 3 * Segment.SIZE + 1 in moveBytesBetweenBuffersMultipleSegments() 130 Segment.SIZE, Segment.SIZE, Segment.SIZE, 1, in moveBytesBetweenBuffersMultipleSegments() 131 Segment.SIZE, Segment.SIZE, Segment.SIZE, 1 in moveBytesBetweenBuffersMultipleSegments() 153 val writeSize = Segment.SIZE / 2 + 1 in writeSplitSourceBufferLeft() 156 sink.writeUtf8('b'.repeat(Segment.SIZE - 10)) in writeSplitSourceBufferLeft() 159 source.writeUtf8('a'.repeat(Segment.SIZE * 2)) in writeSplitSourceBufferLeft() 162 assertEquals(listOf(Segment.SIZE - 10, writeSize), segmentSizes(sink)) in writeSplitSourceBufferLeft() 163 assertEquals(listOf(Segment.SIZE - writeSize, Segment.SIZE), segmentSizes(source)) in writeSplitSourceBufferLeft() [all …]
|
D | AbstractBufferedSourceTest.kt | 78 sink.writeUtf8("a".repeat(Segment.SIZE - 1)) in readShortSplitAcrossMultipleSegments() 81 source.skip((Segment.SIZE - 1).toLong()) in readShortSplitAcrossMultipleSegments() 143 sink.writeUtf8("a".repeat(Segment.SIZE - 3)) in readIntSplitAcrossMultipleSegments() 146 source.skip((Segment.SIZE - 3).toLong()) in readIntSplitAcrossMultipleSegments() 224 sink.writeUtf8("a".repeat(Segment.SIZE - 7)) in readLongSplitAcrossMultipleSegments() 238 source.skip((Segment.SIZE - 7).toLong()) in readLongSplitAcrossMultipleSegments() 321 data.writeUtf8("Hello").writeUtf8("e".repeat(Segment.SIZE)) in readFullyByteArray() 327 val sink = ByteArray(Segment.SIZE + 5) in readFullyByteArray() 407 val string = "abcd" + "e".repeat(Segment.SIZE) in readByteArray() 431 sink.writeUtf8("abcd").writeUtf8("e".repeat(Segment.SIZE)) in readByteString() [all …]
|
D | CommonRealBufferedSourceTest.kt | 79 source.writeUtf8("a".repeat(Segment.SIZE)) in requireReadsOneSegmentAtATime() 80 source.writeUtf8("b".repeat(Segment.SIZE)) in requireReadsOneSegmentAtATime() 85 assertEquals(Segment.SIZE.toLong(), source.size) in requireReadsOneSegmentAtATime() 86 assertEquals(Segment.SIZE.toLong(), bufferedSource.buffer.size) in requireReadsOneSegmentAtATime() 91 source.writeUtf8("a".repeat(Segment.SIZE)) in skipReadsOneSegmentAtATime() 92 source.writeUtf8("b".repeat(Segment.SIZE)) in skipReadsOneSegmentAtATime() 95 assertEquals(Segment.SIZE.toLong(), source.size) in skipReadsOneSegmentAtATime() 96 assertEquals(Segment.SIZE.toLong() - 2L, bufferedSource.buffer.size) in skipReadsOneSegmentAtATime() 139 val write1 = Buffer().writeUtf8("a".repeat(Segment.SIZE)) in readAllReadsOneSegmentAtATime() 140 val write2 = Buffer().writeUtf8("b".repeat(Segment.SIZE)) in readAllReadsOneSegmentAtATime() [all …]
|
D | CommonRealBufferedSinkTest.kt | 32 bufferedSink.writeUtf8("a".repeat(Segment.SIZE - 1)) in bufferedSinkEmitsTailWhenItIsComplete() 35 assertEquals(Segment.SIZE.toLong(), sink.size) in bufferedSinkEmitsTailWhenItIsComplete() 42 bufferedSink.writeUtf8("a".repeat(Segment.SIZE * 4 - 1)) in bufferedSinkEmitMultipleSegments() 43 assertEquals(Segment.SIZE.toLong() * 3L, sink.size) in bufferedSinkEmitMultipleSegments() 44 assertEquals(Segment.SIZE.toLong() - 1L, bufferedSink.buffer.size) in bufferedSinkEmitMultipleSegments() 83 bufferedSink.writeUtf8("a".repeat(Segment.SIZE * 3)) in completeSegmentsEmitted() 84 assertEquals(Segment.SIZE.toLong() * 3L, sink.size) in completeSegmentsEmitted() 90 bufferedSink.writeUtf8("a".repeat(Segment.SIZE * 3 - 1)) in incompleteSegmentsNotEmitted() 91 assertEquals(Segment.SIZE.toLong() * 2L, sink.size) in incompleteSegmentsNotEmitted() 184 val write1 = Buffer().writeUtf8("a".repeat(Segment.SIZE)) in writeAllWritesOneSegmentAtATime() [all …]
|
/external/okhttp/okio/okio/src/main/java/okio/ |
D | Segment.java | 33 final class Segment { class 52 Segment next; 55 Segment prev; 57 Segment() { in Segment() method in Segment 63 Segment(Segment shareFrom) { in Segment() method in Segment 68 Segment(byte[] data, int pos, int limit) { in Segment() method in Segment 80 public Segment pop() { in pop() 81 Segment result = next != this ? next : null; in pop() 93 public Segment push(Segment segment) { in push() 109 public Segment split(int byteCount) { in split() [all …]
|
D | SegmentPool.java | 28 static Segment next; 36 static Segment take() { in take() 39 Segment result = next; in take() 42 byteCount -= Segment.SIZE; in take() 46 return new Segment(); // Pool is empty. Don't zero-fill while holding a lock. in take() 49 static void recycle(Segment segment) { in recycle() 53 if (byteCount + Segment.SIZE > MAX_SIZE) return; // Pool is full. in recycle() 54 byteCount += Segment.SIZE; in recycle()
|
D | Buffer.java | 52 Segment head; 148 Segment s = head; 174 Segment s = head; 181 Segment copy = new Segment(s); 206 Segment s = head; 216 Segment toRecycle = s; 241 Segment tail = writableSegment(1); 242 int maxToCopy = (int) Math.min(byteCount, Segment.SIZE - tail.limit); 264 Segment tail = head.prev; 265 if (tail.limit < Segment.SIZE && tail.owner) { [all …]
|
/external/okhttp/repackaged/okio/okio/src/main/java/com/android/okhttp/okio/ |
D | Segment.java | 34 final class Segment { class 53 Segment next; 56 Segment prev; 58 Segment() { in Segment() method in Segment 64 Segment(Segment shareFrom) { in Segment() method in Segment 69 Segment(byte[] data, int pos, int limit) { in Segment() method in Segment 81 public Segment pop() { in pop() 82 Segment result = next != this ? next : null; in pop() 94 public Segment push(Segment segment) { in push() 110 public Segment split(int byteCount) { in split() [all …]
|
D | SegmentPool.java | 29 static Segment next; 37 static Segment take() { in take() 40 Segment result = next; in take() 43 byteCount -= Segment.SIZE; in take() 47 return new Segment(); // Pool is empty. Don't zero-fill while holding a lock. in take() 50 static void recycle(Segment segment) { in recycle() 54 if (byteCount + Segment.SIZE > MAX_SIZE) return; // Pool is full. in recycle() 55 byteCount += Segment.SIZE; in recycle()
|
D | Buffer.java | 54 Segment head; 150 Segment s = head; 176 Segment s = head; 183 Segment copy = new Segment(s); 208 Segment s = head; 218 Segment toRecycle = s; 243 Segment tail = writableSegment(1); 244 int maxToCopy = (int) Math.min(byteCount, Segment.SIZE - tail.limit); 266 Segment tail = head.prev; 267 if (tail.limit < Segment.SIZE && tail.owner) { [all …]
|
/external/exoplayer/tree/testutils/src/main/java/com/google/android/exoplayer2/testutil/ |
D | FakeDataSet.java | 80 public static final class Segment { class in FakeDataSet.FakeData 92 private Segment(byte[] data, @Nullable Segment previousSegment) { in Segment() method in FakeDataSet.FakeData.Segment 96 private Segment(int length, @Nullable Segment previousSegment) { in Segment() method in FakeDataSet.FakeData.Segment 100 private Segment(IOException exception, @Nullable Segment previousSegment) { in Segment() method in FakeDataSet.FakeData.Segment 104 private Segment(Runnable action, @Nullable Segment previousSegment) { in Segment() method in FakeDataSet.FakeData.Segment 108 private Segment( in Segment() method in FakeDataSet.FakeData.Segment 113 @Nullable Segment previousSegment) { in Segment() 136 private final ArrayList<Segment> segments; 166 segments.add(new Segment(data, getLastSegment())); in appendReadData() 176 segments.add(new Segment(length, getLastSegment())); in appendReadData() [all …]
|
/external/rust/cxx/syntax/ |
D | symbol.rs | 33 pub fn from_idents<'a>(it: impl Iterator<Item = &'a dyn Segment>) -> Self { in from_idents() 49 pub trait Segment { trait 53 impl Segment for str { 59 impl Segment for usize { 65 impl Segment for Ident { 71 impl Segment for Symbol { 77 impl Segment for Namespace { 85 impl Segment for Pair { 92 impl Segment for ForeignName { 100 impl<T> Segment for &'_ T impl [all …]
|
/external/okio/okio/src/commonMain/kotlin/okio/ |
D | Segment.kt | 35 internal class Segment { class 56 @JvmField var next: Segment? = null 59 @JvmField var prev: Segment? = null 80 fun sharedCopy(): Segment { in sharedCopy() 82 return Segment(data, pos, limit, true, false) in sharedCopy() 86 fun unsharedCopy() = Segment(data.copyOf(), pos, limit, false, true) in unsharedCopy() 92 fun pop(): Segment? { in unsharedCopy() 104 fun push(segment: Segment): Segment { in push() 120 fun split(byteCount: Int): Segment { in split() 122 val prefix: Segment in split() [all …]
|
/external/okio/okio/src/jvmMain/kotlin/okio/ |
D | SegmentPool.kt | 48 private val LOCK = Segment(ByteArray(0), pos = 0, limit = 0, shared = false, owner = false) 65 private val hashBuckets: Array<AtomicReference<Segment?>> = Array(HASH_BUCKET_COUNT) { in <lambda>() 66 AtomicReference<Segment?>() // null value implies an empty bucket in <lambda>() 76 actual fun take(): Segment { in take() 83 return Segment() in take() 88 return Segment() in take() 101 actual fun recycle(segment: Segment) { in recycle() 114 segment.limit = firstLimit + Segment.SIZE in recycle() 122 private fun firstRef(): AtomicReference<Segment?> { in firstRef()
|
/external/libvpx/libwebm/mkvparser/ |
D | mkvparser.h | 67 class Segment; variable 305 static long Create(Segment*, const Info&, long long element_start, 310 Segment* const m_pSegment; 373 Track(Segment*, long long element_start, long long element_size); 508 VideoTrack(Segment*, long long element_start, long long element_size); 512 static long Parse(Segment*, const Info&, long long element_start, 550 AudioTrack(Segment*, long long element_start, long long element_size); 553 static long Parse(Segment*, const Info&, long long element_start, 571 Segment* const m_pSegment; 577 Tracks(Segment*, long long start, long long size, long long element_start, [all …]
|
/external/libaom/libaom/third_party/libwebm/mkvparser/ |
D | mkvparser.h | 67 class Segment; variable 305 static long Create(Segment*, const Info&, long long element_start, 310 Segment* const m_pSegment; 373 Track(Segment*, long long element_start, long long element_size); 508 VideoTrack(Segment*, long long element_start, long long element_size); 512 static long Parse(Segment*, const Info&, long long element_start, 550 AudioTrack(Segment*, long long element_start, long long element_size); 553 static long Parse(Segment*, const Info&, long long element_start, 571 Segment* const m_pSegment; 577 Tracks(Segment*, long long start, long long size, long long element_start, [all …]
|
/external/libwebm/mkvparser/ |
D | mkvparser.h | 67 class Segment; variable 305 static long Create(Segment*, const Info&, long long element_start, 310 Segment* const m_pSegment; 373 Track(Segment*, long long element_start, long long element_size); 508 VideoTrack(Segment*, long long element_start, long long element_size); 512 static long Parse(Segment*, const Info&, long long element_start, 550 AudioTrack(Segment*, long long element_start, long long element_size); 553 static long Parse(Segment*, const Info&, long long element_start, 571 Segment* const m_pSegment; 577 Tracks(Segment*, long long start, long long size, long long element_start, [all …]
|
/external/libvpx/libvpx/third_party/libwebm/mkvparser/ |
D | mkvparser.h | 67 class Segment; variable 305 static long Create(Segment*, const Info&, long long element_start, 310 Segment* const m_pSegment; 373 Track(Segment*, long long element_start, long long element_size); 508 VideoTrack(Segment*, long long element_start, long long element_size); 512 static long Parse(Segment*, const Info&, long long element_start, 550 AudioTrack(Segment*, long long element_start, long long element_size); 553 static long Parse(Segment*, const Info&, long long element_start, 571 Segment* const m_pSegment; 577 Tracks(Segment*, long long start, long long size, long long element_start, [all …]
|
/external/androidplot/Examples/DemoApp/src/com/androidplot/demos/ |
D | SimplePieChartActivity.java | 26 import com.androidplot.pie.Segment; 40 private Segment s1; 41 private Segment s2; 42 private Segment s3; 43 private Segment s4; 77 s1 = new Segment("s1", 10); in onCreate() 78 s2 = new Segment("s2", 1); in onCreate() 79 s3 = new Segment("s3", 10); in onCreate() 80 s4 = new Segment("s4", 10); in onCreate()
|
/external/llvm/tools/dsymutil/ |
D | MachOUtils.cpp | 128 MachO::segment_command_64 Segment; in iterateOnSegments() local 130 Segment = adaptFrom32bits(Obj.getSegmentLoadCommand(LCI)); in iterateOnSegments() 132 Segment = Obj.getSegment64LoadCommand(LCI); in iterateOnSegments() 136 Handler(Segment); in iterateOnSegments() 227 const object::MachOObjectFile::LoadCommandInfo &LCI, SegmentTy Segment, in transferSegmentAndSections() argument 231 if (StringRef("__DWARF") == Segment.segname) in transferSegmentAndSections() 234 Segment.fileoff = Segment.filesize = 0; in transferSegmentAndSections() 236 if (StringRef("__LINKEDIT") == Segment.segname) { in transferSegmentAndSections() 237 Segment.fileoff = LinkeditOffset; in transferSegmentAndSections() 238 Segment.filesize = LinkeditSize; in transferSegmentAndSections() [all …]
|
/external/llvm-project/llvm/tools/dsymutil/ |
D | MachOUtils.cpp | 142 MachO::segment_command_64 Segment; in iterateOnSegments() local 144 Segment = adaptFrom32bits(Obj.getSegmentLoadCommand(LCI)); in iterateOnSegments() 146 Segment = Obj.getSegment64LoadCommand(LCI); in iterateOnSegments() 150 Handler(Segment); in iterateOnSegments() 249 const object::MachOObjectFile::LoadCommandInfo &LCI, SegmentTy Segment, in transferSegmentAndSections() argument 253 if (StringRef("__DWARF") == Segment.segname) in transferSegmentAndSections() 256 Segment.fileoff = Segment.filesize = 0; in transferSegmentAndSections() 258 if (StringRef("__LINKEDIT") == Segment.segname) { in transferSegmentAndSections() 259 Segment.fileoff = LinkeditOffset; in transferSegmentAndSections() 260 Segment.filesize = LinkeditSize; in transferSegmentAndSections() [all …]
|