Trait prio::flp::types::fixedpoint_l2::compatible_float::CompatibleFloat
source · pub trait CompatibleFloat {
// Required methods
fn to_float(t: Field128, c: u128) -> f64;
fn to_field_integer(&self) -> <Field128 as FieldElementWithInteger>::Integer;
}
Available on crate feature
experimental
only.Expand description
Assign a Float
type to this type and describe how to represent this type as an integer of the
given field, and how to represent a field element as the assigned Float
type.
Required Methods§
sourcefn to_float(t: Field128, c: u128) -> f64
fn to_float(t: Field128, c: u128) -> f64
Represent a field element as Float
, given the number of clients c
.
sourcefn to_field_integer(&self) -> <Field128 as FieldElementWithInteger>::Integer
fn to_field_integer(&self) -> <Field128 as FieldElementWithInteger>::Integer
Represent a value of this type as an integer in the given field.
Object Safety§
This trait is not object safe.