public Data replace ( Iterable < Property > replacement ) { if ( Iterables . isEmpty ( replacement ) ) { return this ; } Map < String , Property > map = getDataAsMap ( replacement ) ; List < Property > props = this . stream ( ) . map ( f -> map . getOrDefault ( f . getName ( ) , f ) ) . collect ( Collectors . toList ( ) ) ; return new Data ( props ) ; }
Replaces all properties with the same name as the supplied properties .