@Component
public class MyAccountBalanceResultMapper implements JcoTableMapper<AccountBalance> {
@Override
public Result<List<AccountBalance>> map(JCoTable table) {
// Custom mapping implementation
}
}
Customization Guide
The FS-CD Adapter is designed to be customizable to accommodate project-specific requirements. This chapter describes the various customization mechanisms to customize the presentation, domain and infrastructure layer.
For the integration layer, see chapter Integration Guide.
Customization Levels
The FS-CD Adapter supports two different types of customization:
1. Configuration Properties
The simplest customization approach uses Spring Boot configuration properties to change behavior of the default implementations without writing code. The following chapters will describe the available configuration properties.
2. Bean Replacement
When property-based customization is not sufficient, individual Spring beans can be replaced to provide custom implementations.
The FS-CD Adapter’s auto-configuration respects custom bean definitions through @ConditionalOnMissingBean.
The following example replaces the default AccountBalanceResultMapper with a custom one.
There are two approaches to provide custom beans:
Approach A: Component Annotation
Approach B: Bean Factory Method
@Configuration
public class MyFscdConfiguration {
@Bean
public JcoTableMapper<AccountBalance> accountBalanceMapper() {
return new MyAccountBalanceResultMapper();
}
}
Approach A is simpler and suitable for straightforward implementations, while Approach B provides more flexibility for complex bean construction, dependency injection, and conditional bean creation based on runtime conditions.