spring-boot-project/spring-boot-tools/spring-boot-configuration-metadata/src/main/java/org/springframework/boot/configurationmetadata/SimpleConfigurationMetadataRepository.java
/**
	 * Merge the content of the specified repository to this repository.
	 * @param repository the repository to include
	 */
Merge the content of the specified repository to this repository.
@param repository the repository to include
Merge the content of the specified repository to this repository . @param repository the repository to include
public void include(ConfigurationMetadataRepository repository) {
		for (ConfigurationMetadataGroup group : repository.getAllGroups().values()) {
			ConfigurationMetadataGroup existingGroup = this.allGroups.get(group.getId());
			if (existingGroup == null) {
				this.allGroups.put(group.getId(), group);
			}
			else {
				group.getProperties().forEach((name, value) -> putIfAbsent(existingGroup.getProperties(), name, value));
				group.getSources().forEach((name, value) -> addOrMergeSource(existingGroup.getSources(), name, value));
			}
		}
	}
public void include ( ConfigurationMetadataRepository repository ) { for ( ConfigurationMetadataGroup group : repository . getAllGroups ( ) . values ( ) ) { ConfigurationMetadataGroup existingGroup = this . allGroups . get ( group . getId ( ) ) ; if ( existingGroup == null ) { this . allGroups . put ( group . getId ( ) , group ) ; } else { group . getProperties ( ) . forEach ( ( name , value ) -> putIfAbsent ( existingGroup . getProperties ( ) , name , value ) ) ; group . getSources ( ) . forEach ( ( name , value ) -> addOrMergeSource ( existingGroup . getSources ( ) , name , value ) ) ; } } }
Merge the content of the specified repository to this repository.
Merge the content of the specified repository to this repository .
// Merge properties // Merge sources