private static <T> void  setIfNew(Property<T> prop, T newValue)
  {
    if(!Objects.equals(prop.getValue(), newValue))
    {
      prop.setValue(newValue);
    }
  }
private static < T > void setIfNew ( Property < T > prop , T newValue ) { if ( ! Objects . equals ( prop . getValue ( ) , newValue ) ) { prop . setValue ( newValue ) ; } }
Only changes the value of the property if it is not equals to the old one.
@param <T>
@param prop
@param newValue