HeapSegment

public final class HeapSegment
extends Object implements Comparable<HeapSegment>

java.lang.Object
   ↳ com.android.tradefed.device.server.HeapSegment


อธิบายประเภทและตำแหน่งของออบเจ็กต์ในกลุ่มของฮีป

สรุป

คลาสที่ซ้อนกัน

class HeapSegment.HeapSegmentElement

อธิบายออบเจ็กต์/ภูมิภาคที่เข้ารหัสในข้อมูล HPSG 

ทุ่ง

protected int mAllocationUnitCount

protected int mAllocationUnitSize

protected int mHeapId

protected int mOffset

protected long mStartAddress

protected ByteBuffer mUsageData

เครื่องมือสร้างสาธารณะ

HeapSegment(ByteBuffer hpsgData)

สร้าง HeapSegment ใหม่โดยอิงตามเนื้อหาดิบของก้อนข้อมูล HPSG

เมธอดสาธารณะ

boolean append(HeapSegment other)

ผนวกเนื้อหาของ other กับกลุ่มนี้หากอธิบายกลุ่ม ที่อยู่ต่อจากกลุ่มนี้ทันที

boolean canAppend(HeapSegment other)

ดูว่า other มาหลังกลุ่มนี้ทันทีหรือไม่

int compareTo(HeapSegment other)
boolean equals(Object o)
long getEndAddress()
int getLength()
HeapSegment.HeapSegmentElement getNextElement(HeapSegment.HeapSegmentElement reuse)
long getStartAddress()
int hashCode()
boolean isValid()

ดูว่ากลุ่มนี้ยังมีข้อมูลอยู่หรือไม่ และไม่ได้ต่อท้ายกลุ่มอื่น

void rewindElements()
String toString()

ทุ่ง

mAllocationUnitCount

protected int mAllocationUnitCount

mAllocationUnitSize

protected int mAllocationUnitSize

mHeapId

protected int mHeapId

mOffset

protected int mOffset

mStartAddress

protected long mStartAddress

mUsageData

protected ByteBuffer mUsageData

เครื่องมือสร้างสาธารณะ

HeapSegment

public HeapSegment (ByteBuffer hpsgData)

สร้าง HeapSegment ใหม่โดยอิงตามเนื้อหาดิบของก้อนข้อมูล HPSG

พารามิเตอร์
hpsgData ByteBuffer: ข้อมูลดิบจากก้อนข้อมูล HPSG

ส่ง
BufferUnderflowException หาก hpsgData มีขนาดเล็กเกินกว่าจะเก็บข้อมูลส่วนหัวของ Chunk HPSG

เมธอดสาธารณะ

ต่อท้าย

public boolean append (HeapSegment other)

ผนวกเนื้อหาของ other กับกลุ่มนี้หากอธิบายกลุ่ม ที่อยู่ต่อจากกลุ่มนี้ทันที

พารามิเตอร์
other HeapSegment: กลุ่มที่จะต่อท้ายกลุ่มนี้ หากเป็นไปได้ หากต่อท้าย other จะไม่ถูกต้องเมื่อเมธอดนี้แสดงผล

การคืนสินค้า
boolean จริง หากต่อท้าย other ในกลุ่มนี้สำเร็จ

canAppend

public boolean canAppend (HeapSegment other)

ดูว่า other มาหลังกลุ่มนี้ทันทีหรือไม่

พารามิเตอร์
other HeapSegment: HeapSegment ที่จะตรวจสอบ

การคืนสินค้า
boolean จริงหาก other มาทันทีหลังจากกลุ่มนี้

compareTo

public int compareTo (HeapSegment other)

พารามิเตอร์
other HeapSegment

การคืนสินค้า
int

เท่ากับ

public boolean equals (Object o)

พารามิเตอร์
o Object

การคืนสินค้า
boolean

getEndAddress

public long getEndAddress ()

การคืนสินค้า
long

getLength

public int getLength ()

การคืนสินค้า
int

getNextElement

public HeapSegment.HeapSegmentElement getNextElement (HeapSegment.HeapSegmentElement reuse)

พารามิเตอร์
reuse HeapSegment.HeapSegmentElement

การคืนสินค้า
HeapSegment.HeapSegmentElement

getStartAddress

public long getStartAddress ()

การคืนสินค้า
long

hashCode

public int hashCode ()

การคืนสินค้า
int

isValid

public boolean isValid ()

ดูว่ากลุ่มนี้ยังมีข้อมูลอยู่หรือไม่ และไม่ได้ต่อท้ายกลุ่มอื่น

การคืนสินค้า
boolean จริง หากไม่ได้ต่อกลุ่มนี้กับกลุ่มอื่น

rewindElements

public void rewindElements ()

toString

public String toString ()

การคืนสินค้า
String