pub trait CleartextVectorConversionEngine<Input, Output>: AbstractEnginewhere
Input: CleartextVectorEntity,
Output: CleartextVectorEntity,{
fn convert_cleartext_vector(
&mut self,
input: &Input
) -> Result<Output, CleartextVectorConversionError<Self::EngineError>>;
unsafe fn convert_cleartext_vector_unchecked(
&mut self,
input: &Input
) -> Output;
}
Expand description
A trait for engines converting (discard) cleartext vectors.
Semantics
This pure operation generates a cleartext vector containing the
conversion of the input
cleartext vector to a type with a different representation (for
instance from cpu to gpu memory).
Formal Definition
Required Methods
sourcefn convert_cleartext_vector(
&mut self,
input: &Input
) -> Result<Output, CleartextVectorConversionError<Self::EngineError>>
fn convert_cleartext_vector(
&mut self,
input: &Input
) -> Result<Output, CleartextVectorConversionError<Self::EngineError>>
Converts a cleartext vector.
sourceunsafe fn convert_cleartext_vector_unchecked(&mut self, input: &Input) -> Output
unsafe fn convert_cleartext_vector_unchecked(&mut self, input: &Input) -> Output
Unsafely converts a cleartext.
Safety
For the general safety concerns regarding this operation, refer to the different variants
of CleartextVectorConversionError
. For safety concerns specific to an engine, refer to
the implementer safety section.