diff options
author | Xavier Ducrohet <xav@android.com> | 2010-07-20 17:25:36 -0700 |
---|---|---|
committer | Xavier Ducrohet <xav@android.com> | 2010-07-26 10:55:08 -0700 |
commit | 9db3286c710abeb2c9478c2f95657d945a55d176 (patch) | |
tree | d3e5b901646d1c2ee6bd3990bb8da99c05eb78d3 /eventanalyzer | |
parent | f56173887a9f6430425c93203a8c260a73b1480a (diff) | |
download | sdk-9db3286c710abeb2c9478c2f95657d945a55d176.zip sdk-9db3286c710abeb2c9478c2f95657d945a55d176.tar.gz sdk-9db3286c710abeb2c9478c2f95657d945a55d176.tar.bz2 |
Update the ddmlib api for push/pull/install
The API now throws SyncException instead of returning SyncResult.
The IDevice API to install/uninstall now returns a single
InstallException that encapsulate all the other ddmlib
exception.
Also, the recently added exceptions now don't extend IOException
anymore.
Change-Id: Ib334c4157a6add1882233dfaaa032aea1910eede
Diffstat (limited to 'eventanalyzer')
-rw-r--r-- | eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java b/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java index 11444ec..691bf0c 100644 --- a/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java +++ b/eventanalyzer/src/com/android/eventanalyzer/EventAnalyzer.java @@ -16,9 +16,11 @@ package com.android.eventanalyzer; +import com.android.ddmlib.AdbCommandRejectedException; import com.android.ddmlib.AndroidDebugBridge; import com.android.ddmlib.IDevice; import com.android.ddmlib.Log; +import com.android.ddmlib.TimeoutException; import com.android.ddmlib.Log.ILogOutput; import com.android.ddmlib.Log.LogLevel; import com.android.ddmlib.log.EventContainer; @@ -159,7 +161,7 @@ public class EventAnalyzer implements ILogListener { // analyze the data gathered by the parser methods analyzeData(); - } catch (IOException e) { + } catch (Exception e) { e.printStackTrace(); } } @@ -227,7 +229,8 @@ public class EventAnalyzer implements ILogListener { } } - private void parseLogFromDevice() throws IOException { + private void parseLogFromDevice() throws IOException, TimeoutException, + AdbCommandRejectedException { // init the lib AndroidDebugBridge.init(false /* debugger support */); @@ -300,7 +303,8 @@ public class EventAnalyzer implements ILogListener { } } - private void grabLogFrom(IDevice device) throws IOException { + private void grabLogFrom(IDevice device) throws IOException, TimeoutException, + AdbCommandRejectedException { mParser = new EventLogParser(); if (mParser.init(device) == false) { printAndExit("Failed to get event-log-tags from " + device.getSerialNumber(), |