Logcat事件解析器
public class LogcatEventParser
extends Object
java.lang.Object | |
↳ | com.android.tradefed.util.LogcatEventParser |
概括
公共構造函數 | |
---|---|
LogcatEventParser (ITestDevice device) |
公共方法 | |
---|---|
void | close () 停止監聽 logcat。 |
void | parseEvents (String[] lines) 解析 logcat 行並將任何捕獲的事件(使用 |
void | registerEventTrigger (String tag, String msg, LogcatEventType response) 註冊給定 logcat 標記的事件和具有所需回應的訊息。 |
void | start () 開始監聽logcat並解析事件。 |
公共構造函數
Logcat事件解析器
public LogcatEventParser (ITestDevice device)
參數 | |
---|---|
device | ITestDevice |
公共方法
關閉
public void close ()
停止監聽 logcat。
解析事件
public void parseEvents (String[] lines)
解析 logcat 行並將任何捕獲的事件(使用registerEventTrigger(String, String, com.android.tradefed.util.LogcatEventType)
註冊的事件)新增至事件佇列。
參數 | |
---|---|
lines | String |
註冊事件觸發器
public void registerEventTrigger (String tag, String msg, LogcatEventType response)
註冊給定 logcat 標記的事件和具有所需回應的訊息。訊息可能不完整。
參數 | |
---|---|
tag | String |
msg | String |
response | LogcatEventType |
開始
public void start ()
開始監聽logcat並解析事件。