use base2k::{FFT64, Module, Scratch}; pub trait KeySwitchScratchSpace { fn keyswitch_scratch_space(module: &Module, res_size: usize, lhs: usize, rhs: usize) -> usize; } pub trait KeySwitch { type Lhs; type Rhs; fn keyswitch(&mut self, module: &Module, lhs: &Self::Lhs, rhs: &Self::Rhs, scratch: &mut Scratch); } pub trait KeySwitchInplaceScratchSpace { fn keyswitch_inplace_scratch_space(module: &Module, res_size: usize, rhs: usize) -> usize; } pub trait KeySwitchInplace { type Rhs; fn keyswitch_inplace(&mut self, module: &Module, rhs: &Self::Rhs, scratch: &mut Scratch); }