diff --git a/docs/html/images/debug-ddms.png b/docs/html/images/debug-ddms.png index d92fb3c8acfde..53121db6c2537 100644 Binary files a/docs/html/images/debug-ddms.png and b/docs/html/images/debug-ddms.png differ diff --git a/docs/html/tools/debugging/ddms.jd b/docs/html/tools/debugging/ddms.jd index becbdb1fe7325..9ff71222c8200 100644 --- a/docs/html/tools/debugging/ddms.jd +++ b/docs/html/tools/debugging/ddms.jd @@ -25,6 +25,13 @@ parent.link=index.html + +

See also

+
    +
  1. Android Monitor
  2. +
  3. Android Emulator
  4. +
+ @@ -180,16 +187,16 @@ parent.link=index.html

Starting method profiling

Method profiling is a means to track certain metrics about a method, such as number of calls, - execution time, and time spent executing the method. If you want more granular control over - where profiling data is collected, use the {@link android.os.Debug#startMethodTracing()} and - {@link android.os.Debug#stopMethodTracing()} methods. For more information about generating trace logs, see + execution time, and time spent executing the method. If you want more granular control over + where profiling data is collected, use the {@link android.os.Debug#startMethodTracing()} and + {@link android.os.Debug#stopMethodTracing()} methods. For more information about generating trace logs, see Profiling and Debugging UIs.

Before you start method profiling in DDMS, be aware of the following restrictions:

@@ -246,18 +253,18 @@ TrafficStats.tagSocket(outputSocket); TrafficStats.untagSocket(outputSocket);

Alternatively, the {@link java.net.URLConnection} APIs included in the platform -automatically tag sockets internally based on the active tag (as identified by +automatically tag sockets internally based on the active tag (as identified by {@link android.net.TrafficStats#getThreadStatsTag getThreadStatsTag()}). These APIs correctly tag/untag sockets when recycled through -keep-alive pools. In the following example, -{@link android.net.TrafficStats#setThreadStatsTag setThreadStatsTag()} -sets the active tag to be {@code 0xF00D}. -There can only be one active tag per thread. -That is the value that will +keep-alive pools. In the following example, +{@link android.net.TrafficStats#setThreadStatsTag setThreadStatsTag()} +sets the active tag to be {@code 0xF00D}. +There can only be one active tag per thread. +That is the value that will be returned by {@link android.net.TrafficStats#getThreadStatsTag getThreadStatsTag()} -and thus used by the HTTP client to tag sockets. The {@code finally} statement -invokes -{@link android.net.TrafficStats#clearThreadStatsTag clearThreadStatsTag()} +and thus used by the HTTP client to tag sockets. The {@code finally} statement +invokes +{@link android.net.TrafficStats#clearThreadStatsTag clearThreadStatsTag()} to clear the tag.

TrafficStats.setThreadStatsTag(0xF00D);
@@ -297,56 +304,9 @@ displayed on devices running Android 4.0.3 or higher.

edit filter, and delete filter buttons let you manage your custom filters.

Emulating phone operations and location

-

The Emulator control tab lets you simulate a - phone's voice and data network status. This is useful when you want to test your application's - robustness in differing network environments.

+

The Emulator Control tab, shown in Figure 1, is no longer + supported. Use the + Android Emulator + for these features.

-

Changing network state, speed, and latency

-

The Telephony Status section of the Emulator - controls tab lets you change different aspects of the phone's networks status, speed and latency. - The following options are available to you and are effective immediately after you set them:

- - -

Spoofing calls or SMS text messages

-

The Telephony Actions section of the Emulator - controls tab lets you spoof calls and messages. This is useful when you want to to test your - application's robustness in responding to incoming calls and messages that are sent to the phone. - The following actions are available to you:

- - - -

Setting the location of the phone

-

If your application depends on the location of the phone, you can have DDMS send your - device or AVD a mock location. This is useful if you - want to test different aspects of your application's location specific features without - physically moving. The following geolocation data types are available to you:

- - - - For more information about providing mock location data, see - Location Strategies. -