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

bindToMapWithWildcardShouldConvertToTheRightType() — spring-boot Function Reference

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

Entity Profile

Dependency Diagram

graph TD
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505["bindToMapWithWildcardShouldConvertToTheRightType()"]
  dec6e978_683d_a8e4_7ae5_e3e729d3253e["MockConfigurationPropertySource()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| dec6e978_683d_a8e4_7ae5_e3e729d3253e
  7ed947bf_22a1_2781_a2ae_759aa1907445["add()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| 7ed947bf_22a1_2781_a2ae_759aa1907445
  76576a77_87f7_3680_8561_2923813db3c1["of()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| 76576a77_87f7_3680_8561_2923813db3c1
  d7626b8d_946e_609d_ccf0_ffbf47d8df9a["get()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| d7626b8d_946e_609d_ccf0_ffbf47d8df9a
  8e38142e_f379_3d93_cc06_7d90b1165c2d["getAddresses()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| 8e38142e_f379_3d93_cc06_7d90b1165c2d
  4fef258c_a2a4_d498_7bd8_31a7595265f6["put()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| 4fef258c_a2a4_d498_7bd8_31a7595265f6
  29543d75_44d7_1789_e9c5_ac222edd33ab["stream()"]
  97e64be1_ce1b_55e1_3ce9_bde7c9b43505 -->|calls| 29543d75_44d7_1789_e9c5_ac222edd33ab
  style 97e64be1_ce1b_55e1_3ce9_bde7c9b43505 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 617–630

	@Test
	void bindToMapWithWildcardShouldConvertToTheRightType() {
		// gh-18767
		MockConfigurationPropertySource source = new MockConfigurationPropertySource();
		source.put("foo.addresses.localhost[0]", "127.0.0.1");
		source.put("foo.addresses.localhost[1]", "127.0.0.2");
		this.sources.add(source);
		MapWithWildcardProperties result = this.binder.bind("foo", Bindable.of(MapWithWildcardProperties.class)).get();
		Map<String, ? extends List<? extends InetAddress>> addresses = result.getAddresses();
		assertThat(addresses).isNotNull();
		List<? extends InetAddress> localhost = addresses.get("localhost");
		assertThat(localhost).isNotNull();
		assertThat(localhost.stream().map(InetAddress::getHostAddress)).containsExactly("127.0.0.1", "127.0.0.2");
	}

Domain

Subdomains

Frequently Asked Questions

What does bindToMapWithWildcardShouldConvertToTheRightType() do?
bindToMapWithWildcardShouldConvertToTheRightType() is a function in the spring-boot codebase.
What does bindToMapWithWildcardShouldConvertToTheRightType() call?
bindToMapWithWildcardShouldConvertToTheRightType() calls 7 function(s): MockConfigurationPropertySource, add, get, getAddresses, of, put, stream.

Analyze Your Own Codebase

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

Try Supermodel Free