def find_all_cached_entries(query)
      logger.verbose("Searching cache for tokens by keys: #{query.keys}.")
      @token_cache.find do |entry|
        query.map do |k, v|
          (entry.respond_to? k.to_sym) && (v == entry.send(k.to_sym))
        end.reduce(:&)
      end
    end
def find_all_cached_entries(query)
      logger.verbose("Searching cache for tokens by keys: #{query.keys}.")
      @token_cache.find do |entry|
        query.map do |k, v|
          (entry.respond_to? k.to_sym) && (v == entry.send(k.to_sym))
        end.reduce(:&)
      end
    end
All cache entries that match a query. This matches keys in values against
 a hash to method calls on an object.

 @param Hash query
   The fields to be matched and the values to match them to.
 @return Array<CachedTokenResponse>