public <R> R readWithResult(final Function<C, R> readFunction) {
        lock.readLock().lock();
        try {
            return readFunction.apply(valueReadOnly);
        } finally {
            lock.readLock().unlock();
        }
    }
executes an Action reading the collection and returning a result
main/src/main/java/cgeo/geocaching/utils/livedata/CollectionLiveData.java