code: static Entity incrementVersion(Entity nativeEntity, PropertyMetadata versionMetadata) {
      String versionPropertyName = versionMetadata.getMappedName();
      long version = nativeEntity.getLong(versionPropertyName);
      return Entity.newBuilder(nativeEntity).set(versionPropertyName, ++version).build();
    }
docs: Increments the version property of the given entity by one.
  
  @param nativeEntity
  the target entity
  @param versionMetadata
  the metadata of the version property
  @return a new entity (copy of the given), but with the incremented version.