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

nestedMapsShouldNotBindToNull() — spring-boot Function Reference

Architecture documentation for the nestedMapsShouldNotBindToNull() function in MapBinderTests.java from the spring-boot codebase.

Entity Profile

Dependency Diagram

graph TD
  c17d0668_653a_5356_6a86_fc7171c8c197["nestedMapsShouldNotBindToNull()"]
  dec6e978_683d_a8e4_7ae5_e3e729d3253e["MockConfigurationPropertySource()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| dec6e978_683d_a8e4_7ae5_e3e729d3253e
  7ed947bf_22a1_2781_a2ae_759aa1907445["add()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| 7ed947bf_22a1_2781_a2ae_759aa1907445
  d7626b8d_946e_609d_ccf0_ffbf47d8df9a["get()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| d7626b8d_946e_609d_ccf0_ffbf47d8df9a
  d5e7c35a_d120_9dc7_997c_fba57b159746["getValue()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| d5e7c35a_d120_9dc7_997c_fba57b159746
  99c0a278_3a13_22a1_8ad2_b2cada9f329e["getFoos()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| 99c0a278_3a13_22a1_8ad2_b2cada9f329e
  4fef258c_a2a4_d498_7bd8_31a7595265f6["put()"]
  c17d0668_653a_5356_6a86_fc7171c8c197 -->|calls| 4fef258c_a2a4_d498_7bd8_31a7595265f6
  style c17d0668_653a_5356_6a86_fc7171c8c197 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

core/spring-boot/src/test/java/org/springframework/boot/context/properties/bind/MapBinderTests.java lines 496–511

	@Test
	void nestedMapsShouldNotBindToNull() {
		MockConfigurationPropertySource source = new MockConfigurationPropertySource();
		source.put("foo.value", "one");
		source.put("foo.foos.foo1.value", "two");
		source.put("foo.foos.foo2.value", "three");
		this.sources.add(source);
		BindResult<NestableFoo> foo = this.binder.bind("foo", NestableFoo.class);
		assertThat(foo.get().getValue()).isNotNull();
		NestableFoo foo1 = foo.get().getFoos().get("foo1");
		assertThat(foo1).isNotNull();
		assertThat(foo1.getValue()).isEqualTo("two");
		NestableFoo foo2 = foo.get().getFoos().get("foo2");
		assertThat(foo2).isNotNull();
		assertThat(foo2.getValue()).isEqualTo("three");
	}

Domain

Subdomains

Frequently Asked Questions

What does nestedMapsShouldNotBindToNull() do?
nestedMapsShouldNotBindToNull() is a function in the spring-boot codebase.
What does nestedMapsShouldNotBindToNull() call?
nestedMapsShouldNotBindToNull() calls 6 function(s): MockConfigurationPropertySource, add, get, getFoos, getValue, put.

Analyze Your Own Codebase

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

Try Supermodel Free