android/guava/src/com/google/common/collect/Maps.java
static <K, V> Entry<K, V> unmodifiableEntry(final Entry<? extends K, ? extends V> entry) {
    checkNotNull(entry);
    return new AbstractMapEntry<K, V>() {
      @Override
      public K getKey() {
        return entry.getKey();
      }

      @Override
      public V getValue() {
        return entry.getValue();
      }
    };
  }
static <K, V> Entry<K, V> unmodifiableEntry(final Entry<? extends K, ? extends V> entry) {
    checkNotNull(entry);
    return new AbstractMapEntry<K, V>() {
      @Override
      public K getKey() {
        return entry.getKey();
      }

      @Override
      public V getValue() {
        return entry.getValue();
      }
    };
  }
Returns an unmodifiable view of the specified map entry. The {@link Entry#setValue} operation
throws an {@link UnsupportedOperationException}. This also has the side-effect of redefining
{@code equals} to comply with the Entry contract, to avoid a possible nefarious implementation
of equals.

@param entry the entry for which to return an unmodifiable view
@return an unmodifiable view of the entry