Expand description
§BiConsumerOnce Types
Provides one-time bi-consumer interface implementations for operations accepting two input parameters without returning a result.
This module provides a unified BiConsumerOnce trait and one concrete
implementation:
BoxBiConsumerOnce<T, U>: Box-based single ownership implementation
§Why No Arc/Rc Variants?
Unlike BiConsumer and ReadonlyBiConsumer, this module does not
provide ArcBiConsumerOnce or RcBiConsumerOnce implementations. This
is a design decision based on the fundamental incompatibility between
FnOnce semantics and shared ownership. See the design documentation
for details.
§Design Philosophy
BiConsumerOnce uses FnOnce(&T, &U) semantics: for truly one-time
consumption operations. Unlike BiConsumer, BiConsumerOnce consumes
itself on first call. Suitable for initialization callbacks, cleanup
callbacks, etc.
§Author
Haixing Hu
Structs§
- BoxBi
Consumer Once - BoxBiConsumerOnce struct
- BoxConditional
BiConsumer Once - BoxConditionalBiConsumerOnce struct
Traits§
- BiConsumer
Once - BiConsumerOnce trait - Unified one-time bi-consumer interface
- FnBi
Consumer Once Ops - Extension trait providing one-time bi-consumer composition methods for closures