pub struct PublicBuilder { /* private fields */ }
Expand description

A builder for the Public type.

Implementations

Creates a new PublicBuilder

Details

Builds the Public type using the provided parameters. Parameters associated with other algorithms then the provided public algorithm will be ignored.

Adds the public algorithm for the Public structure to the builder.

Adds the attributes of the Public structure to the builder

Adds the name hash algorithm for the Public strucutre to the builder.

Adds the auth policy for the Public strucutre to the builder

Adds the RSA parameters for the Public structure to the builder.

Details

This is required if the public algorithm is set to Rsa.

Adds the RSA unique identifier for the Public structure to the builder.

Details

This is required if the public algorithm is set to Rsa.

The unique identifier is the public key.

Adds the keyed hash parameters for the Public structure to the builder.

Details

This is required if the public algorithm is set to KeyedHash.

Adds the keyed hash unique identifier for the Public structure to the builder.

Details

This is required if the public algorithm is set to KeyedHash.

Adds the ECC parameters for the Public structure to the builder.

Details

This is required if the public algorithm is set to Ecc.

Adds the ECC unique identifier for the Public structure to the builder.

Details

This is required if the public algorithm is set to Ecc.

The unique identifier is a ecc point.

Adds the symmetric cipher parameters for the Public structure to the builder.

Details

This is required if the public algorithm is set to SymCipher.

Adds the symmetric cipher unique identifier for the Public structure to the builder.

Details

This is required if the public algorithm is set to SymCipher.

Builds the Public structure.

Errors

Will return error if the public algorithm, object attributes or name hashing algorithm have not been set or if the parameters and unique identifier does not match the selected public algorithm.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Drops the content pointed by this pointer and frees it. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.