bindToNonScalarCollectionWhenNonSequentialShouldThrowException() — spring-boot Function Reference
Architecture documentation for the bindToNonScalarCollectionWhenNonSequentialShouldThrowException() function in CollectionBinderTests.java from the spring-boot codebase.
Entity Profile
Dependency Diagram
graph TD 1ea80f01_ca77_daa5_0a3b_752efa98c859["bindToNonScalarCollectionWhenNonSequentialShouldThrowException()"] dec6e978_683d_a8e4_7ae5_e3e729d3253e["MockConfigurationPropertySource()"] 1ea80f01_ca77_daa5_0a3b_752efa98c859 -->|calls| dec6e978_683d_a8e4_7ae5_e3e729d3253e 725e97d2_341b_6665_84bc_9206c7185c54["put()"] 1ea80f01_ca77_daa5_0a3b_752efa98c859 -->|calls| 725e97d2_341b_6665_84bc_9206c7185c54 7437ce23_cb84_88cd_05ea_0748b72957a1["getName()"] 1ea80f01_ca77_daa5_0a3b_752efa98c859 -->|calls| 7437ce23_cb84_88cd_05ea_0748b72957a1 b36de6d8_b985_12e4_b731_db390fd85040["getValue()"] 1ea80f01_ca77_daa5_0a3b_752efa98c859 -->|calls| b36de6d8_b985_12e4_b731_db390fd85040 style 1ea80f01_ca77_daa5_0a3b_752efa98c859 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 169–188
@Test
void bindToNonScalarCollectionWhenNonSequentialShouldThrowException() {
MockConfigurationPropertySource source = new MockConfigurationPropertySource();
source.put("foo[0].value", "1");
source.put("foo[1].value", "2");
source.put("foo[4].value", "4");
this.sources.add(source);
Bindable<List<JavaBean>> target = Bindable.listOf(JavaBean.class);
assertThatExceptionOfType(BindException.class).isThrownBy(() -> this.binder.bind("foo", target))
.satisfies((ex) -> {
Throwable cause = ex.getCause();
assertThat(cause).isNotNull();
Set<ConfigurationProperty> unbound = ((UnboundConfigurationPropertiesException) cause)
.getUnboundProperties();
assertThat(unbound).singleElement().satisfies((property) -> {
assertThat(property.getName()).hasToString("foo[4].value");
assertThat(property.getValue()).isEqualTo("4");
});
});
}
Domain
Subdomains
Source
Frequently Asked Questions
What does bindToNonScalarCollectionWhenNonSequentialShouldThrowException() do?
bindToNonScalarCollectionWhenNonSequentialShouldThrowException() is a function in the spring-boot codebase.
What does bindToNonScalarCollectionWhenNonSequentialShouldThrowException() call?
bindToNonScalarCollectionWhenNonSequentialShouldThrowException() calls 4 function(s): MockConfigurationPropertySource, getName, getValue, put.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free