aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/tools/android/java/com/google/devtools
diff options
context:
space:
mode:
authorGravatar Googler <noreply@google.com>2017-01-12 20:58:35 +0000
committerGravatar Marcel Hlopko <hlopko@google.com>2017-01-13 10:57:51 +0000
commitb2e6607cd9e4e168872c87c66edbef1bc2bf943a (patch)
treeb5c3865d1e297903e6e12eb59f919912bd91d5f6 /src/tools/android/java/com/google/devtools
parent6e0efe16d4bf40a3472d20769fc9f5b8fcadfe07 (diff)
Cleanup unthrown exceptions.
-- PiperOrigin-RevId: 144360540 MOS_MIGRATED_REVID=144360540
Diffstat (limited to 'src/tools/android/java/com/google/devtools')
-rw-r--r--src/tools/android/java/com/google/devtools/build/android/AndroidDataWriter.java2
-rw-r--r--src/tools/android/java/com/google/devtools/build/android/AndroidDataWritingVisitor.java6
-rw-r--r--src/tools/android/java/com/google/devtools/build/android/DataResource.java7
-rw-r--r--src/tools/android/java/com/google/devtools/build/android/DataValueFile.java6
4 files changed, 7 insertions, 14 deletions
diff --git a/src/tools/android/java/com/google/devtools/build/android/AndroidDataWriter.java b/src/tools/android/java/com/google/devtools/build/android/AndroidDataWriter.java
index 36374e4369..f035758cfc 100644
--- a/src/tools/android/java/com/google/devtools/build/android/AndroidDataWriter.java
+++ b/src/tools/android/java/com/google/devtools/build/android/AndroidDataWriter.java
@@ -215,7 +215,7 @@ public class AndroidDataWriter implements AndroidDataWritingVisitor {
@Override
public void copyResource(final Path source, final String relativeDestinationPath)
- throws IOException, MergingException {
+ throws MergingException {
final Path destinationPath = resourceDirectory.resolve(relativeDestinationPath);
if (!source.getParent().getFileName().toString().startsWith(SdkConstants.FD_RES_RAW)
&& source.getFileName().toString().endsWith(SdkConstants.DOT_PNG)) {
diff --git a/src/tools/android/java/com/google/devtools/build/android/AndroidDataWritingVisitor.java b/src/tools/android/java/com/google/devtools/build/android/AndroidDataWritingVisitor.java
index 8d1f547dcf..4dfe1a4935 100644
--- a/src/tools/android/java/com/google/devtools/build/android/AndroidDataWritingVisitor.java
+++ b/src/tools/android/java/com/google/devtools/build/android/AndroidDataWritingVisitor.java
@@ -45,11 +45,9 @@ public interface AndroidDataWritingVisitor extends Flushable {
*
* @param source The source file to copy.
* @param relativeDestinationPath The relative destination path to write the resource to.
- * @throws IOException if there are errors during copying.
- * @throws MergingException for errors during png crunching.
+ * @throws MergingException for errors during copying.
*/
- void copyResource(Path source, String relativeDestinationPath)
- throws IOException, MergingException;
+ void copyResource(Path source, String relativeDestinationPath) throws MergingException;
/**
* Adds the namespaces associated with a {@link FullyQualifiedName}.
diff --git a/src/tools/android/java/com/google/devtools/build/android/DataResource.java b/src/tools/android/java/com/google/devtools/build/android/DataResource.java
index b177b9e49b..9ed3658d41 100644
--- a/src/tools/android/java/com/google/devtools/build/android/DataResource.java
+++ b/src/tools/android/java/com/google/devtools/build/android/DataResource.java
@@ -14,17 +14,14 @@
package com.google.devtools.build.android;
import com.android.ide.common.res2.MergingException;
-import java.io.IOException;
/**
* Represents an Android Resource parsed from an xml or binary file.
*/
public interface DataResource extends DataValue {
- /**
- * Write as a resource using the supplied {@link AndroidDataWritingVisitor}.
- */
+ /** Write as a resource using the supplied {@link AndroidDataWritingVisitor}. */
void writeResource(FullyQualifiedName key, AndroidDataWritingVisitor mergedDataWriter)
- throws IOException, MergingException;
+ throws MergingException;
/**
* Combines these resource together and returns a single resource.
diff --git a/src/tools/android/java/com/google/devtools/build/android/DataValueFile.java b/src/tools/android/java/com/google/devtools/build/android/DataValueFile.java
index b24d1278af..e6ed99addd 100644
--- a/src/tools/android/java/com/google/devtools/build/android/DataValueFile.java
+++ b/src/tools/android/java/com/google/devtools/build/android/DataValueFile.java
@@ -43,9 +43,7 @@ public class DataValueFile implements DataResource, DataAsset {
return new DataValueFile(source);
}
- /**
- * Creates a {@link DataValueFile} from a {@link SerializeFormat.DataValue}.
- */
+ /** Creates a {@link DataValueFile} from a {@link SerializeFormat#DataValue}. */
public static DataValueFile from(Path source) {
return of(source);
}
@@ -82,7 +80,7 @@ public class DataValueFile implements DataResource, DataAsset {
@Override
public void writeResource(FullyQualifiedName key, AndroidDataWritingVisitor mergedDataWriter)
- throws IOException, MergingException {
+ throws MergingException {
mergedDataWriter.copyResource(source.getPath(), key.toPathString(source.getPath()));
}