結果轉發器

public class ResultForwarder
extends Object implements ITestInvocationListener

java.lang.Object
com.android.tradefed.result.ResultForwarder


將呼叫結果轉送到其他偵聽器清單的ITestInvocationListener

概括

公共構造函數

ResultForwarder ( listeners) ResultForwarder ( listeners)

建立一個ResultForwarder

ResultForwarder (ITestInvocationListener... listeners)

ResultForwarder的備用變數 arg 建構子。

受保護的構造函數

ResultForwarder ()

建立具有延遲偵聽器設定的ResultForwarder

公共方法

TestSummary getSummary ()

void invocationEnded (long elapsedTime)

void invocationFailed (FailureDescription failure)

void invocationFailed (Throwable cause)

void invocationStarted (IInvocationContext context)

void testAssumptionFailure (TestDescription test, String trace)
void testAssumptionFailure (TestDescription test, FailureDescription failure)
void testEnded (TestDescription test, long endTime, testMetrics) testEnded (TestDescription test, long endTime, testMetrics)

void testEnded (TestDescription test, testMetrics) testEnded (TestDescription test, testMetrics)

void testFailed (TestDescription test, FailureDescription failure)

void testFailed (TestDescription test, String trace)

void testIgnored (TestDescription test)
void testLog (String dataName, LogDataType dataType, InputStreamSource dataStream)

void testModuleEnded ()
void testModuleStarted (IInvocationContext moduleContext)
void testRunEnded (long elapsedTime, runMetrics) testRunEnded (long elapsedTime, runMetrics)

void testRunFailed (FailureDescription failure)

void testRunFailed (String errorMessage)

void testRunStarted (String runName, int testCount, int attemptNumber)

void testRunStarted (String runName, int testCount)

void testRunStarted (String runName, int testCount, int attemptNumber, long startTime)

void testRunStopped (long elapsedTime)

void testStarted (TestDescription test, long startTime)

void testStarted (TestDescription test)

受保護的方法

getListeners ()

獲取聽眾清單。

void setListeners ( listeners) setListeners ( listeners)

建置後設定監聽器。

void setListeners (ITestInvocationListener... listeners)

建置後設定監聽器。

公共構造函數

結果轉發器

public ResultForwarder ( listeners)

建立一個ResultForwarder

參數
listeners :將結果轉送到的真正的ITestInvocationListener

結果轉發器

public ResultForwarder (ITestInvocationListener... listeners)

ResultForwarder的備用變數 arg 建構子。

參數
listeners ITestInvocationListener :將結果轉送到的真正的ITestInvocationListener

受保護的構造函數

結果轉發器

protected ResultForwarder ()

建立具有延遲偵聽器設定的ResultForwarder 。僅供子類使用。

公共方法

取得摘要

public TestSummary getSummary ()

退貨
TestSummary

呼叫結束

public void invocationEnded (long elapsedTime)

參數
elapsedTime long

呼叫失敗

public void invocationFailed (FailureDescription failure)

參數
failure FailureDescription

呼叫失敗

public void invocationFailed (Throwable cause)

參數
cause Throwable

調用開始

public void invocationStarted (IInvocationContext context)

參數
context IInvocationContext

測試假設失敗

public void testAssumptionFailure (TestDescription test, 
                String trace)

參數
test TestDescription

trace String

測試假設失敗

public void testAssumptionFailure (TestDescription test, 
                FailureDescription failure)

參數
test TestDescription

failure FailureDescription

測試結束

public void testEnded (TestDescription test, 
                long endTime, 
                 testMetrics)

參數
test TestDescription

endTime long

testMetrics

測試結束

public void testEnded (TestDescription test, 
                 testMetrics)

參數
test TestDescription

testMetrics

測試失敗

public void testFailed (TestDescription test, 
                FailureDescription failure)

參數
test TestDescription

failure FailureDescription

測試失敗

public void testFailed (TestDescription test, 
                String trace)

參數
test TestDescription

trace String

測試被忽略

public void testIgnored (TestDescription test)

參數
test TestDescription

測試日誌

public void testLog (String dataName, 
                LogDataType dataType, 
                InputStreamSource dataStream)

參數
dataName String

dataType LogDataType

dataStream InputStreamSource

測試模組結束

public void testModuleEnded ()

測試模組啟動

public void testModuleStarted (IInvocationContext moduleContext)

參數
moduleContext IInvocationContext

測試運行結束

public void testRunEnded (long elapsedTime, 
                 runMetrics)

參數
elapsedTime long

runMetrics

測試運行失敗

public void testRunFailed (FailureDescription failure)

參數
failure FailureDescription

測試運行失敗

public void testRunFailed (String errorMessage)

參數
errorMessage String

測試運行開始

public void testRunStarted (String runName, 
                int testCount, 
                int attemptNumber)

參數
runName String

testCount int

attemptNumber int

測試運行開始

public void testRunStarted (String runName, 
                int testCount)

參數
runName String

testCount int

測試運行開始

public void testRunStarted (String runName, 
                int testCount, 
                int attemptNumber, 
                long startTime)

參數
runName String

testCount int

attemptNumber int

startTime long

測試運行停止

public void testRunStopped (long elapsedTime)

參數
elapsedTime long

測試開始

public void testStarted (TestDescription test, 
                long startTime)

參數
test TestDescription

startTime long

測試開始

public void testStarted (TestDescription test)

參數
test TestDescription

受保護的方法

取得監聽器

protected  getListeners ()

獲取聽眾清單。僅供子類使用。

退貨
ITestInvocationListener的列表。

設定監聽器

protected void setListeners ( listeners)

建置後設定監聽器。僅供子類使用。

參數
listeners :將結果轉送到的真正的ITestInvocationListener

設定監聽器

protected void setListeners (ITestInvocationListener... listeners)

建置後設定監聽器。僅供子類使用。

參數
listeners ITestInvocationListener :將結果轉送到的真正的ITestInvocationListener