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

bindToCollectionWhenNestedShouldReturnPopulatedCollection() — spring-boot Function Reference

Architecture documentation for the bindToCollectionWhenNestedShouldReturnPopulatedCollection() function in CollectionBinderTests.java from the spring-boot codebase.

Entity Profile

Dependency Diagram

graph TD
  b5a77aa2_999d_c0a8_1a19_8968653f56cf["bindToCollectionWhenNestedShouldReturnPopulatedCollection()"]
  dec6e978_683d_a8e4_7ae5_e3e729d3253e["MockConfigurationPropertySource()"]
  b5a77aa2_999d_c0a8_1a19_8968653f56cf -->|calls| dec6e978_683d_a8e4_7ae5_e3e729d3253e
  725e97d2_341b_6665_84bc_9206c7185c54["put()"]
  b5a77aa2_999d_c0a8_1a19_8968653f56cf -->|calls| 725e97d2_341b_6665_84bc_9206c7185c54
  f4b76c1c_abdc_fe17_d6c1_88412a0633e7["of()"]
  b5a77aa2_999d_c0a8_1a19_8968653f56cf -->|calls| f4b76c1c_abdc_fe17_d6c1_88412a0633e7
  style b5a77aa2_999d_c0a8_1a19_8968653f56cf fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

core/spring-boot/src/test/java/org/springframework/boot/context/properties/bind/CollectionBinderTests.java lines 85–99

	@Test
	void bindToCollectionWhenNestedShouldReturnPopulatedCollection() {
		MockConfigurationPropertySource source = new MockConfigurationPropertySource();
		source.put("foo[0][0]", "1");
		source.put("foo[0][1]", "2");
		source.put("foo[1][0]", "3");
		source.put("foo[1][1]", "4");
		this.sources.add(source);
		Bindable<List<List<Integer>>> target = Bindable
			.of(ResolvableType.forClassWithGenerics(List.class, INTEGER_LIST.getType()));
		List<List<Integer>> result = this.binder.bind("foo", target).get();
		assertThat(result).hasSize(2);
		assertThat(result.get(0)).containsExactly(1, 2);
		assertThat(result.get(1)).containsExactly(3, 4);
	}

Domain

Subdomains

Frequently Asked Questions

What does bindToCollectionWhenNestedShouldReturnPopulatedCollection() do?
bindToCollectionWhenNestedShouldReturnPopulatedCollection() is a function in the spring-boot codebase.
What does bindToCollectionWhenNestedShouldReturnPopulatedCollection() call?
bindToCollectionWhenNestedShouldReturnPopulatedCollection() calls 3 function(s): MockConfigurationPropertySource, of, put.

Analyze Your Own Codebase

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

Try Supermodel Free