pub struct DealProposal {
    pub piece_cid: Cid,
    pub piece_size: PaddedPieceSize,
    pub verified_deal: bool,
    pub client: Address,
    pub provider: Address,
    pub label: String,
    pub start_epoch: ChainEpoch,
    pub end_epoch: ChainEpoch,
    pub storage_price_per_epoch: TokenAmount,
    pub provider_collateral: TokenAmount,
    pub client_collateral: TokenAmount,
}
Expand description

Note: Deal Collateral is only released and returned to clients and miners when the storage deal stops counting towards power. In the current iteration, it will be released when the sector containing the storage deals expires, even though some storage deals can expire earlier than the sector does. Collaterals are denominated in PerEpoch to incur a cost for self dealing or minimal deals that last for a long time. Note: ClientCollateralPerEpoch may not be needed and removed pending future confirmation. There will be a Minimum value for both client and provider deal collateral.

Fields

piece_cid: Cidpiece_size: PaddedPieceSizeverified_deal: boolclient: Addressprovider: Addresslabel: String

Arbitrary client chosen label to apply to the deal

start_epoch: ChainEpochend_epoch: ChainEpochstorage_price_per_epoch: TokenAmountprovider_collateral: TokenAmountclient_collateral: TokenAmount

Implementations

Computes weight for a deal proposal, which is a function of its size and duration.

Trait Implementations

Marshalls cbor encodable object into cbor bytes

Unmarshals cbor encoded bytes to object

Returns the content identifier of the raw block of data Default is Blake2b256 hash Read more

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

This method tests for self and other values to be equal, and is used by ==. Read more

This method tests for !=.

Serialize this value into the given Serde serializer. 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

Performs the conversion.

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

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.