pub struct ServerKey { /* private fields */ }Implementations§
Source§impl ServerKey
impl ServerKey
pub fn new(cks: &ClientKey) -> Self
pub fn trivial_encrypt(&self, message: bool) -> Ciphertext
pub fn not(&self, ct: &Ciphertext) -> Ciphertext
pub fn mux( &self, ct_condition: &Ciphertext, ct_then: &Ciphertext, ct_else: &Ciphertext, ) -> Ciphertext
Trait Implementations§
Source§impl<Lhs, Rhs> BinaryBooleanGates<Lhs, Rhs> for ServerKey
impl<Lhs, Rhs> BinaryBooleanGates<Lhs, Rhs> for ServerKey
fn and(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
fn nand(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
fn nor(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
fn or(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
fn xor(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
fn xnor(&self, ct_left: Lhs, ct_right: Rhs) -> Ciphertext
Source§impl<'de> Deserialize<'de> for ServerKey
impl<'de> Deserialize<'de> for ServerKey
Source§fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
fn deserialize<D>(deserializer: D) -> Result<Self, D::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for ServerKey
impl RefUnwindSafe for ServerKey
impl Send for ServerKey
impl Sync for ServerKey
impl Unpin for ServerKey
impl UnwindSafe for ServerKey
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more