//! Contains compaction strategies
pub(crate)modcompactor;pub(crate)modleveled;usecrate::levels::LevelManifest;usecrate::Result;/// Represents the input for a compaction operation
#[derive(Debug, Eq, PartialEq, Clone)]pub(crate)structCompactionInput{pubtables_to_merge:Vec<u64>,
pubtarget_level:u8,
pubsource_level:u8, // Added to track the source level
}/// Represents the possible compaction decisions
#[derive(Debug, Eq, PartialEq)]pubenumCompactionChoice{
Merge(CompactionInput),
Skip,// Added to explicitly handle cases where compaction isn't needed
}/// Defines the strategy interface for compaction
pubtraitCompactionStrategy: Send + Sync {/// Determines which levels should be compacted
fnpick_levels(&self, manifest:&LevelManifest)->Result<CompactionChoice>;}