Skip to content

Commit

Permalink
Fix spurious PMD warnings when building with —-profile.
Browse files Browse the repository at this point in the history
Adds a workaround for bumptech#2776.
  • Loading branch information
sjudd committed Dec 31, 2017
1 parent 04d5fea commit cc4bb16
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -235,10 +235,14 @@ public <R> LoadStatus load(
return new LoadStatus(cb, engineJob);
}

// TODO(#2776): Remove this suppression.
@SuppressWarnings("PMD.UnusedPrivateMethod")
private static void logWithTimeAndKey(String log, long startTime, Key key) {
Log.v(TAG, log + " in " + LogTime.getElapsedMillis(startTime) + "ms, key: " + key);
}

// TODO(#2776): Remove this suppression.
@SuppressWarnings("PMD.UnusedPrivateMethod")
@Nullable
private EngineResource<?> loadFromActiveResources(Key key, boolean isMemoryCacheable) {
if (!isMemoryCacheable) {
Expand All @@ -252,6 +256,8 @@ private EngineResource<?> loadFromActiveResources(Key key, boolean isMemoryCache
return active;
}

// TODO(#2776): Remove this suppression.
@SuppressWarnings("PMD.UnusedPrivateMethod")
private EngineResource<?> loadFromCache(Key key, boolean isMemoryCacheable) {
if (!isMemoryCacheable) {
return null;
Expand Down

0 comments on commit cc4bb16

Please sign in to comment.