(
chunk_bit_size: u8,
encryption_gens: EncryptionGens<E>,
chunked_commitment_gens: ChunkedCommitmentGens<E::G1Affine>,
encryption_key: EncryptionKey<E>,
snark_p
| 51 | |
| 52 | impl<E: Pairing> SaverProver<E> { |
| 53 | pub fn new_statement_from_params( |
| 54 | chunk_bit_size: u8, |
| 55 | encryption_gens: EncryptionGens<E>, |
| 56 | chunked_commitment_gens: ChunkedCommitmentGens<E::G1Affine>, |
| 57 | encryption_key: EncryptionKey<E>, |
| 58 | snark_proving_key: ProvingKey<E>, |
| 59 | ) -> Result<Statement<E>, ProofSystemError> { |
| 60 | SaverProtocol::validate_encryption_key(chunk_bit_size, &encryption_key)?; |
| 61 | Ok(Statement::SaverProver(Self { |
| 62 | chunk_bit_size, |
| 63 | encryption_gens: Some(encryption_gens), |
| 64 | chunked_commitment_gens: Some(chunked_commitment_gens), |
| 65 | encryption_key: Some(encryption_key), |
| 66 | snark_proving_key: Some(snark_proving_key), |
| 67 | encryption_gens_ref: None, |
| 68 | chunked_commitment_gens_ref: None, |
| 69 | encryption_key_ref: None, |
| 70 | snark_proving_key_ref: None, |
| 71 | })) |
| 72 | } |
| 73 | |
| 74 | pub fn new_statement_from_params_ref( |
| 75 | chunk_bit_size: u8, |
nothing calls this directly
no test coverage detected