Is your feature request related to a problem? Please describe.
There are 15+ duplicate implementations of _generate_samples_single_bootstrap across different bootstrap modules, leading to code duplication and maintenance challenges.
Describe the solution you'd like
Implement a unified approach using either:
- Template Method Pattern: Create an abstract base method with customizable hooks
- Strategy Pattern: Use composition to inject specific bootstrap generation strategies
The solution should:
- Extract common bootstrap generation logic into the base class
- Allow subclasses to customize specific steps without duplicating the entire method
- Maintain backward compatibility with existing API
Describe alternatives you've considered
- Mixin classes for shared functionality
- Function composition with decorators
- Utility module with shared functions
Additional context
Benefits of consolidation:
- DRY (Don't Repeat Yourself) principle compliance
- Easier maintenance and bug fixes
- Consistent behavior across all bootstrap types
- Reduced testing burden
Part of codebase quality improvement initiative identified in refactoring analysis.
Is your feature request related to a problem? Please describe.
There are 15+ duplicate implementations of
_generate_samples_single_bootstrapacross different bootstrap modules, leading to code duplication and maintenance challenges.Describe the solution you'd like
Implement a unified approach using either:
The solution should:
Describe alternatives you've considered
Additional context
Benefits of consolidation:
Part of codebase quality improvement initiative identified in refactoring analysis.