Home / Function/ beansAndContainersNamed() — spring-boot Function Reference

beansAndContainersNamed() — spring-boot Function Reference

Architecture documentation for the beansAndContainersNamed() function in ConditionalOnBeanTests.java from the spring-boot codebase.

Entity Profile

Dependency Diagram

graph TD
  fc09f454_25b2_580e_d105_2c84cf413faf["beansAndContainersNamed()"]
  dd57008d_dfd2_e3c9_285b_46a4dc4373a5["parameterizedContainerWhenValueIsOfMissingBeanDoesNotMatch()"]
  dd57008d_dfd2_e3c9_285b_46a4dc4373a5 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  cff01802_4b9b_abca_fd62_1be35374514e["parameterizedContainerWhenValueIsOfExistingBeanMatches()"]
  cff01802_4b9b_abca_fd62_1be35374514e -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  87b5f48a_7f6e_0635_46da_0dabaf0d1f25["parameterizedContainerWhenValueIsOfMissingBeanRegistrationDoesNotMatch()"]
  87b5f48a_7f6e_0635_46da_0dabaf0d1f25 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  08ccc9de_8ecf_a763_e9f0_91d9fadb6c5d["parameterizedContainerWhenValueIsOfExistingBeanRegistrationMatches()"]
  08ccc9de_8ecf_a763_e9f0_91d9fadb6c5d -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  affb85d5_551e_dc23_d9ba_b21a28e5c3cf["parameterizedContainerWhenReturnTypeIsOfExistingBeanMatches()"]
  affb85d5_551e_dc23_d9ba_b21a28e5c3cf -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  e4455c87_3b83_5496_d072_379d012a108a["parameterizedContainerWhenReturnTypeIsOfExistingBeanRegistrationMatches()"]
  e4455c87_3b83_5496_d072_379d012a108a -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  438cc0eb_22b4_9e49_f20d_448b4bb43f11["parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanMatches()"]
  438cc0eb_22b4_9e49_f20d_448b4bb43f11 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  cb8ea9bc_91a1_f8c6_11c5_79c8103bd1c6["parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanRegistrationMatches()"]
  cb8ea9bc_91a1_f8c6_11c5_79c8103bd1c6 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  08183736_3cc6_f67d_e05e_1df9b3c39226["genericWhenTypeArgumentMatches()"]
  08183736_3cc6_f67d_e05e_1df9b3c39226 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  5e063d6c_5b4d_5384_bae4_3956d8ed45c7["genericWhenTypeArgumentWithValueMatches()"]
  5e063d6c_5b4d_5384_bae4_3956d8ed45c7 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  74cf6e54_d85e_2140_a414_6ef74aa3cb2a["genericWithValueWhenSubclassTypeArgumentMatches()"]
  74cf6e54_d85e_2140_a414_6ef74aa3cb2a -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  3bf9fa33_6afe_4293_ac27_d71b83eec60e["parameterizedContainerGenericWhenTypeArgumentNotMatches()"]
  3bf9fa33_6afe_4293_ac27_d71b83eec60e -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  4223c306_2d21_3be4_f283_9e01d5c5cea5["parameterizedContainerGenericWhenTypeArgumentMatches()"]
  4223c306_2d21_3be4_f283_9e01d5c5cea5 -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  db055046_00a4_80b8_0b35_a55ce5a2977e["parameterizedContainerGenericWhenSubclassTypeArgumentMatches()"]
  db055046_00a4_80b8_0b35_a55ce5a2977e -->|calls| fc09f454_25b2_580e_d105_2c84cf413faf
  style fc09f454_25b2_580e_d105_2c84cf413faf fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

core/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/condition/ConditionalOnBeanTests.java lines 371–377

	private Consumer<ConfigurableApplicationContext> beansAndContainersNamed(Class<?> type, String... names) {
		return (context) -> {
			String[] beans = context.getBeanNamesForType(type);
			String[] containers = context.getBeanNamesForType(TestParameterizedContainer.class);
			assertThat(StringUtils.concatenateStringArrays(beans, containers)).containsOnly(names);
		};
	}

Domain

Subdomains

Called By

  • genericWhenTypeArgumentMatches()
  • genericWhenTypeArgumentWithValueMatches()
  • genericWithValueWhenSubclassTypeArgumentMatches()
  • parameterizedContainerGenericWhenSubclassTypeArgumentMatches()
  • parameterizedContainerGenericWhenTypeArgumentMatches()
  • parameterizedContainerGenericWhenTypeArgumentNotMatches()
  • parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanMatches()
  • parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanRegistrationMatches()
  • parameterizedContainerWhenReturnTypeIsOfExistingBeanMatches()
  • parameterizedContainerWhenReturnTypeIsOfExistingBeanRegistrationMatches()
  • parameterizedContainerWhenValueIsOfExistingBeanMatches()
  • parameterizedContainerWhenValueIsOfExistingBeanRegistrationMatches()
  • parameterizedContainerWhenValueIsOfMissingBeanDoesNotMatch()
  • parameterizedContainerWhenValueIsOfMissingBeanRegistrationDoesNotMatch()

Frequently Asked Questions

What does beansAndContainersNamed() do?
beansAndContainersNamed() is a function in the spring-boot codebase.
What calls beansAndContainersNamed()?
beansAndContainersNamed() is called by 14 function(s): genericWhenTypeArgumentMatches, genericWhenTypeArgumentWithValueMatches, genericWithValueWhenSubclassTypeArgumentMatches, parameterizedContainerGenericWhenSubclassTypeArgumentMatches, parameterizedContainerGenericWhenTypeArgumentMatches, parameterizedContainerGenericWhenTypeArgumentNotMatches, parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanMatches, parameterizedContainerWhenReturnRegistrationTypeIsOfExistingBeanRegistrationMatches, and 6 more.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free