HeapSegment

public final class HeapSegment
extends Object

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

การขว้าง
หาก 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