MonitorThread

public final class MonitorThread
extends Object

java.lang.Object
   ↳ com.android.tradefed.device.server.MonitorThread


オープン接続をモニタリングします。

概要

パブリック メソッド

void addClient(ClientImpl client)

モニタリング対象のリストに新しいクライアントを追加します。

static MonitorThread createInstance()

クライアント モニター スレッドのシングルトン インスタンスを作成して返します。

void dropClient(ClientImpl client, boolean notify)

モニターからクライアントをドロップします。

void dropClients( clients, boolean notify)

指定されたクライアントのリストをモニターから削除します。

DdmJdwpExtension getDdmExtension()
static MonitorThread getInstance()

クライアント モニター スレッドのシングルトン インスタンスを取得します。

boolean getRetryOnBadHandshake()

JDWP ハンドシェイクが失敗した場合にクライアントへの接続を再試行する場合は true、失敗したクライアントをそのまま放置する場合は false を返します。

void quit()

スレッドに停止を指示します。

void registerChunkHandler(int type, ChunkHandler handler)

「handler」を「type」のハンドラとして登録します。

void run()

クライアントとデバッガからのアクティビティを監視します。

パブリック メソッド

addClient

public void addClient (ClientImpl client)

モニタリング対象のリストに新しいクライアントを追加します。また、クライアントのチャンネルとクライアントのデバッガ リスナーも選択リストに追加します。「alreadyOpen」と Client の作成の競合を回避するため、この関数は 1 つのスレッド(VMWatcherThread)からのみ呼び出す必要があります。

パラメータ
client ClientImpl

createInstance

public static MonitorThread createInstance ()

クライアント モニター スレッドのシングルトン インスタンスを作成して返します。

戻り値
MonitorThread

dropClient

public void dropClient (ClientImpl client, 
                boolean notify)

モニターからクライアントをドロップします。

これにより、実行中の clientClientImpl リストがロックされます。IDevice

dropClients

public void dropClients ( clients, 
                boolean notify)

指定されたクライアントのリストをモニターから削除します。これにより、各クライアントを実行している IDeviceClientImpl リストがロックされます。

パラメータ
clients

notify boolean

getDdmExtension

public DdmJdwpExtension getDdmExtension ()

戻り値
DdmJdwpExtension

getInstance

public static MonitorThread getInstance ()

クライアント モニター スレッドのシングルトン インスタンスを取得します。

戻り値
MonitorThread

getRetryOnBadHandshake

public boolean getRetryOnBadHandshake ()

不正な JDWP ハンドシェイクが返された場合にクライアントへの接続を再試行する場合は true、不正なものとしてマークしてそのままにする場合は false を返します。

戻り値
boolean

quit

public void quit ()

スレッドに停止を指示します。UI スレッドから呼び出されます。

registerChunkHandler

public void registerChunkHandler (int type, 
                ChunkHandler handler)

「handler」をタイプ「type」のハンドラとして登録します。

パラメータ
type int

handler ChunkHandler

ホームラン

public void run ()

クライアントとデバッガからのアクティビティを監視します。