HistoryLogger

public class HistoryLogger
extends FileLogger

java.lang.Object
com.android.tradefed.log.BaseLeveledLogOutput
  com.android.tradefed.log.BaseStreamLogger<com.android.tradefed.util.SizeLimitedOutputStream>
    com.android.tradefed.log.FileLogger
      com.android.tradefed.log.HistoryLogger


TF History Logger, special log that contains only some specific events.

สรุป

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

HistoryLogger()

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

ILeveledLogOutput clone()

สร้าง FileLogger ใหม่ที่มีการตั้งค่าระดับบันทึกเดียวกันกับออบเจ็กต์ปัจจุบัน

void init()

เริ่มต้นบันทึกโดยสร้างทรัพยากร I/O ที่จำเป็น

void logEvent(Log.LogLevel logLevel, ILogRegistry.EventType event, Map<String, String> args)

เรียกใช้เมธอดนี้เพื่อบันทึกเหตุการณ์จากประเภทที่มีข้อมูลที่เกี่ยวข้องในแผนที่

void printAndPromptLog(Log.LogLevel logLevel, String tag, String message)
void printLog(Log.LogLevel logLevel, String tag, String message)

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

HistoryLogger

public HistoryLogger ()

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

โคลน

public ILeveledLogOutput clone ()

สร้าง FileLogger ใหม่ที่มีการตั้งค่าระดับบันทึกเดียวกันกับออบเจ็กต์ปัจจุบัน

ไม่คัดลอกเนื้อหาไฟล์บันทึกพื้นฐาน (เช่น ระบบจะเขียนข้อมูลบันทึกของโคลนลงในไฟล์ใหม่ )

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

init

public void init ()

เริ่มต้นบันทึกโดยสร้างทรัพยากร I/O ที่จำเป็น

ส่ง
IOException

logEvent

public void logEvent (Log.LogLevel logLevel, 
                ILogRegistry.EventType event, 
                Map<String, String> args)

เรียกใช้เมธอดนี้เพื่อบันทึกเหตุการณ์จากประเภทที่มีข้อมูลที่เกี่ยวข้องในแผนที่

พารามิเตอร์
logLevel Log.LogLevel

event ILogRegistry.EventType: EventType ของเหตุการณ์ที่จะบันทึก

args Map: แผนที่ของอาร์กิวเมนต์ที่จะเพิ่มลงในรายการบันทึกเพื่อดูรายละเอียดเพิ่มเติมเกี่ยวกับ เหตุการณ์

printAndPromptLog

public void printAndPromptLog (Log.LogLevel logLevel, 
                String tag, 
                String message)

พารามิเตอร์
logLevel Log.LogLevel

tag String

message String

printLog

public void printLog (Log.LogLevel logLevel, 
                String tag, 
                String message)

พารามิเตอร์
logLevel Log.LogLevel

tag String

message String