pub trait Environment:
'static
+ Copy
+ Clone
+ Debug
+ PartialEq
+ Eq
+ Hash
+ Serialize
+ DeserializeOwned
+ Send
+ Sync {
type Affine: AffineCurve<Projective = Self::Projective, BaseField = Self::Field, ScalarField = Self::Scalar, Coordinates = (Self::Field, Self::Field)>;
type BigInteger: BigInteger;
type Field: PrimeField<BigInteger = Self::BigInteger> + SquareRootField + Copy + Zeroize;
type PairingCurve: PairingEngine<Fr = Self::Field>;
type Projective: ProjectiveCurve<Affine = Self::Affine, BaseField = Self::Field, ScalarField = Self::Scalar>;
type Scalar: PrimeField<BigInteger = Self::BigInteger> + Copy + Zeroize;
const EDWARDS_A: Self::Field;
const EDWARDS_D: Self::Field;
const MONTGOMERY_A: Self::Field;
const MONTGOMERY_B: Self::Field;
const MAX_STRING_BYTES: u32 = 255u32;
// Provided method
fn halt<S, T>(message: S) -> T
where S: Into<String> { ... }
}
Required Associated Constants§
Sourceconst MONTGOMERY_A: Self::Field
const MONTGOMERY_A: Self::Field
The coefficient A
of the Montgomery curve.
Sourceconst MONTGOMERY_B: Self::Field
const MONTGOMERY_B: Self::Field
The coefficient B
of the Montgomery curve.
Provided Associated Constants§
Sourceconst MAX_STRING_BYTES: u32 = 255u32
const MAX_STRING_BYTES: u32 = 255u32
The maximum number of bytes allowed in a string.
Required Associated Types§
type Affine: AffineCurve<Projective = Self::Projective, BaseField = Self::Field, ScalarField = Self::Scalar, Coordinates = (Self::Field, Self::Field)>
type BigInteger: BigInteger
type Field: PrimeField<BigInteger = Self::BigInteger> + SquareRootField + Copy + Zeroize
type PairingCurve: PairingEngine<Fr = Self::Field>
type Projective: ProjectiveCurve<Affine = Self::Affine, BaseField = Self::Field, ScalarField = Self::Scalar>
type Scalar: PrimeField<BigInteger = Self::BigInteger> + Copy + Zeroize
Provided Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl Environment for CanaryV0
impl Environment for CanaryV0
Source§const EDWARDS_A: <CanaryV0 as Environment>::Field = Console::EDWARDS_A
const EDWARDS_A: <CanaryV0 as Environment>::Field = Console::EDWARDS_A
The coefficient A
of the twisted Edwards curve.
Source§const EDWARDS_D: <CanaryV0 as Environment>::Field = Console::EDWARDS_D
const EDWARDS_D: <CanaryV0 as Environment>::Field = Console::EDWARDS_D
The coefficient D
of the twisted Edwards curve.
Source§const MONTGOMERY_A: <CanaryV0 as Environment>::Field = Console::MONTGOMERY_A
const MONTGOMERY_A: <CanaryV0 as Environment>::Field = Console::MONTGOMERY_A
The coefficient A
of the Montgomery curve.
Source§const MONTGOMERY_B: <CanaryV0 as Environment>::Field = Console::MONTGOMERY_B
const MONTGOMERY_B: <CanaryV0 as Environment>::Field = Console::MONTGOMERY_B
The coefficient B
of the Montgomery curve.
type Affine = <Console as Environment>::Affine
type BigInteger = <Console as Environment>::BigInteger
type Field = <Console as Environment>::Field
type PairingCurve = <Console as Environment>::PairingCurve
type Projective = <Console as Environment>::Projective
type Scalar = <Console as Environment>::Scalar
Source§impl Environment for MainnetV0
impl Environment for MainnetV0
Source§const EDWARDS_A: <MainnetV0 as Environment>::Field = Console::EDWARDS_A
const EDWARDS_A: <MainnetV0 as Environment>::Field = Console::EDWARDS_A
The coefficient A
of the twisted Edwards curve.
Source§const EDWARDS_D: <MainnetV0 as Environment>::Field = Console::EDWARDS_D
const EDWARDS_D: <MainnetV0 as Environment>::Field = Console::EDWARDS_D
The coefficient D
of the twisted Edwards curve.
Source§const MONTGOMERY_A: <MainnetV0 as Environment>::Field = Console::MONTGOMERY_A
const MONTGOMERY_A: <MainnetV0 as Environment>::Field = Console::MONTGOMERY_A
The coefficient A
of the Montgomery curve.
Source§const MONTGOMERY_B: <MainnetV0 as Environment>::Field = Console::MONTGOMERY_B
const MONTGOMERY_B: <MainnetV0 as Environment>::Field = Console::MONTGOMERY_B
The coefficient B
of the Montgomery curve.
type Affine = <Console as Environment>::Affine
type BigInteger = <Console as Environment>::BigInteger
type Field = <Console as Environment>::Field
type PairingCurve = <Console as Environment>::PairingCurve
type Projective = <Console as Environment>::Projective
type Scalar = <Console as Environment>::Scalar
Source§impl Environment for TestnetV0
impl Environment for TestnetV0
Source§const EDWARDS_A: <TestnetV0 as Environment>::Field = Console::EDWARDS_A
const EDWARDS_A: <TestnetV0 as Environment>::Field = Console::EDWARDS_A
The coefficient A
of the twisted Edwards curve.
Source§const EDWARDS_D: <TestnetV0 as Environment>::Field = Console::EDWARDS_D
const EDWARDS_D: <TestnetV0 as Environment>::Field = Console::EDWARDS_D
The coefficient D
of the twisted Edwards curve.
Source§const MONTGOMERY_A: <TestnetV0 as Environment>::Field = Console::MONTGOMERY_A
const MONTGOMERY_A: <TestnetV0 as Environment>::Field = Console::MONTGOMERY_A
The coefficient A
of the Montgomery curve.
Source§const MONTGOMERY_B: <TestnetV0 as Environment>::Field = Console::MONTGOMERY_B
const MONTGOMERY_B: <TestnetV0 as Environment>::Field = Console::MONTGOMERY_B
The coefficient B
of the Montgomery curve.