From 8926c84ca9c668046344cc88744ee3ad9ff4df3e Mon Sep 17 00:00:00 2001 From: Hannes Janetzek Date: Sun, 9 Mar 2014 16:43:56 +0100 Subject: [PATCH] docs: MatchingCacheKey --- vtm/src/org/oscim/theme/MatchingCacheKey.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/vtm/src/org/oscim/theme/MatchingCacheKey.java b/vtm/src/org/oscim/theme/MatchingCacheKey.java index 05dfdfd5..d9fadbb4 100644 --- a/vtm/src/org/oscim/theme/MatchingCacheKey.java +++ b/vtm/src/org/oscim/theme/MatchingCacheKey.java @@ -31,10 +31,11 @@ class MatchingCacheKey { mHash = key.mHash; } - // set temporary values for comparison + /** set temporary values for comparison */ boolean set(TagSet tags, MatchingCacheKey compare) { int numTags = tags.numTags; + /* Test if tags are equal to previous query */ if (compare != null && numTags == compare.mTags.length) { int i = 0; for (; i < numTags; i++) { @@ -48,7 +49,9 @@ class MatchingCacheKey { return true; } - // need to clone tags as they belong to TileDataSource + /* Clone tags as they belong to TileDataSource. + * Also needed for comparison if previous tags + * were equal. */ mTags = new Tag[numTags]; int result = 7;