Khai thác ngoại lệ

public class HarnessException
extends Object implements IHarnessException

java.lang.Object
com.android.tradefed.error.HarnessException


Lớp ngoại lệ cơ sở dành cho ngoại lệ được đưa vào trong dây nịt. Lớp này giúp mang ErrorIdentifier để báo cáo chi tiết lỗi.

Bản tóm tắt

Nhà thầu xây dựng công cộng

HarnessException ( ErrorIdentifier errorId)
HarnessException (String message, ErrorIdentifier errorId)
HarnessException (Throwable cause, ErrorIdentifier errorId)
HarnessException (String message, Throwable cause, ErrorIdentifier errorId)

Phương pháp công cộng

ErrorIdentifier getErrorId ()

Trả về ErrorIdentifier liên quan đến ngoại lệ.

String getOrigin ()

Trả về nguồn gốc của ngoại lệ.

String toString ()

Phương pháp được bảo vệ

final void setCallerClass (Class<?> clazz)
final void setCallerClass (String clazz)

Nhà thầu xây dựng công cộng

Khai thác ngoại lệ

public HarnessException (ErrorIdentifier errorId)

Thông số
errorId ErrorIdentifier

Khai thác ngoại lệ

public HarnessException (String message, 
                ErrorIdentifier errorId)

Thông số
message String

errorId ErrorIdentifier

Khai thác ngoại lệ

public HarnessException (Throwable cause, 
                ErrorIdentifier errorId)

Thông số
cause Throwable

errorId ErrorIdentifier

Khai thác ngoại lệ

public HarnessException (String message, 
                Throwable cause, 
                ErrorIdentifier errorId)

Thông số
message String

cause Throwable

errorId ErrorIdentifier

Phương pháp công cộng

getErrorId

public ErrorIdentifier getErrorId ()

Trả về ErrorIdentifier liên quan đến ngoại lệ. Có thể là null.

Trả lại
ErrorIdentifier

lấy nguồn gốc

public String getOrigin ()

Trả về nguồn gốc của ngoại lệ.

Trả lại
String

toString

public String toString ()

Trả lại
String

Phương pháp được bảo vệ

setCallerClass

protected final void setCallerClass (Class<?> clazz)

Thông số
clazz Class

setCallerClass

protected final void setCallerClass (String clazz)

Thông số
clazz String