Skip to main content

LweCiphertextVectorDiscardingKeyswitchEngine

Trait LweCiphertextVectorDiscardingKeyswitchEngine 

Source
pub trait LweCiphertextVectorDiscardingKeyswitchEngine<KeyswitchKey, InputCiphertextVector, OutputCiphertextVector>: AbstractEngine
where KeyswitchKey: LweKeyswitchKeyEntity, InputCiphertextVector: LweCiphertextVectorEntity, OutputCiphertextVector: LweCiphertextVectorEntity,
{ // Required methods fn discard_keyswitch_lwe_ciphertext_vector( &mut self, output: &mut OutputCiphertextVector, input: &InputCiphertextVector, ksk: &KeyswitchKey, ) -> Result<(), LweCiphertextVectorDiscardingKeyswitchError<Self::EngineError>>; unsafe fn discard_keyswitch_lwe_ciphertext_vector_unchecked( &mut self, output: &mut OutputCiphertextVector, input: &InputCiphertextVector, ksk: &KeyswitchKey, ); }
Expand description

A trait for engines keyswitching (discarding) LWE ciphertext vectors.

§Semantics

This discarding operation fills the output LWE ciphertext vector with the element-wise keyswitch of the input LWE ciphertext vector, under the ksk lwe keyswitch key.

§Formal Definition

cf here

Required Methods§

Source

fn discard_keyswitch_lwe_ciphertext_vector( &mut self, output: &mut OutputCiphertextVector, input: &InputCiphertextVector, ksk: &KeyswitchKey, ) -> Result<(), LweCiphertextVectorDiscardingKeyswitchError<Self::EngineError>>

Keyswitch an LWE ciphertext vector.

Source

unsafe fn discard_keyswitch_lwe_ciphertext_vector_unchecked( &mut self, output: &mut OutputCiphertextVector, input: &InputCiphertextVector, ksk: &KeyswitchKey, )

Unsafely keyswitch an LWE ciphertext vector.

§Safety

For the general safety concerns regarding this operation, refer to the different variants of LweCiphertextVectorDiscardingKeyswitchError. For safety concerns specific to an engine, refer to the implementer safety section.

Dyn Compatibility§

This trait is dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§