Struct aws_sdk_managedblockchain::types::Proposal
source · #[non_exhaustive]pub struct Proposal {Show 14 fields
pub proposal_id: Option<String>,
pub network_id: Option<String>,
pub description: Option<String>,
pub actions: Option<ProposalActions>,
pub proposed_by_member_id: Option<String>,
pub proposed_by_member_name: Option<String>,
pub status: Option<ProposalStatus>,
pub creation_date: Option<DateTime>,
pub expiration_date: Option<DateTime>,
pub yes_vote_count: Option<i32>,
pub no_vote_count: Option<i32>,
pub outstanding_vote_count: Option<i32>,
pub tags: Option<HashMap<String, String>>,
pub arn: Option<String>,
}
Expand description
Properties of a proposal on a Managed Blockchain network.
Applies only to Hyperledger Fabric.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. }
syntax; cannot be matched against without a wildcard ..
; and struct update syntax will not work.proposal_id: Option<String>
The unique identifier of the proposal.
network_id: Option<String>
The unique identifier of the network for which the proposal is made.
description: Option<String>
The description of the proposal.
actions: Option<ProposalActions>
The actions to perform on the network if the proposal is APPROVED
.
proposed_by_member_id: Option<String>
The unique identifier of the member that created the proposal.
proposed_by_member_name: Option<String>
The name of the member that created the proposal.
status: Option<ProposalStatus>
The status of the proposal. Values are as follows:
-
IN_PROGRESS
- The proposal is active and open for member voting. -
APPROVED
- The proposal was approved with sufficientYES
votes among members according to theVotingPolicy
specified for theNetwork
. The specified proposal actions are carried out. -
REJECTED
- The proposal was rejected with insufficientYES
votes among members according to theVotingPolicy
specified for theNetwork
. The specifiedProposalActions
aren't carried out. -
EXPIRED
- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActions
aren't carried out. -
ACTION_FAILED
- One or more of the specifiedProposalActions
in a proposal that was approved couldn't be completed because of an error. TheACTION_FAILED
status occurs even if only one ProposalAction fails and other actions are successful.
creation_date: Option<DateTime>
The date and time that the proposal was created.
expiration_date: Option<DateTime>
The date and time that the proposal expires. This is the CreationDate
plus the ProposalDurationInHours
that is specified in the ProposalThresholdPolicy
. After this date and time, if members haven't cast enough votes to determine the outcome according to the voting policy, the proposal is EXPIRED
and Actions
aren't carried out.
yes_vote_count: Option<i32>
The current total of YES
votes cast on the proposal by members.
no_vote_count: Option<i32>
The current total of NO
votes cast on the proposal by members.
outstanding_vote_count: Option<i32>
The number of votes remaining to be cast on the proposal by members. In other words, the number of members minus the sum of YES
votes and NO
votes.
Tags assigned to the proposal. Each tag consists of a key and optional value.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
arn: Option<String>
The Amazon Resource Name (ARN) of the proposal. For more information about ARNs and their format, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference.
Implementations§
source§impl Proposal
impl Proposal
sourcepub fn proposal_id(&self) -> Option<&str>
pub fn proposal_id(&self) -> Option<&str>
The unique identifier of the proposal.
sourcepub fn network_id(&self) -> Option<&str>
pub fn network_id(&self) -> Option<&str>
The unique identifier of the network for which the proposal is made.
sourcepub fn description(&self) -> Option<&str>
pub fn description(&self) -> Option<&str>
The description of the proposal.
sourcepub fn actions(&self) -> Option<&ProposalActions>
pub fn actions(&self) -> Option<&ProposalActions>
The actions to perform on the network if the proposal is APPROVED
.
sourcepub fn proposed_by_member_id(&self) -> Option<&str>
pub fn proposed_by_member_id(&self) -> Option<&str>
The unique identifier of the member that created the proposal.
sourcepub fn proposed_by_member_name(&self) -> Option<&str>
pub fn proposed_by_member_name(&self) -> Option<&str>
The name of the member that created the proposal.
sourcepub fn status(&self) -> Option<&ProposalStatus>
pub fn status(&self) -> Option<&ProposalStatus>
The status of the proposal. Values are as follows:
-
IN_PROGRESS
- The proposal is active and open for member voting. -
APPROVED
- The proposal was approved with sufficientYES
votes among members according to theVotingPolicy
specified for theNetwork
. The specified proposal actions are carried out. -
REJECTED
- The proposal was rejected with insufficientYES
votes among members according to theVotingPolicy
specified for theNetwork
. The specifiedProposalActions
aren't carried out. -
EXPIRED
- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActions
aren't carried out. -
ACTION_FAILED
- One or more of the specifiedProposalActions
in a proposal that was approved couldn't be completed because of an error. TheACTION_FAILED
status occurs even if only one ProposalAction fails and other actions are successful.
sourcepub fn creation_date(&self) -> Option<&DateTime>
pub fn creation_date(&self) -> Option<&DateTime>
The date and time that the proposal was created.
sourcepub fn expiration_date(&self) -> Option<&DateTime>
pub fn expiration_date(&self) -> Option<&DateTime>
The date and time that the proposal expires. This is the CreationDate
plus the ProposalDurationInHours
that is specified in the ProposalThresholdPolicy
. After this date and time, if members haven't cast enough votes to determine the outcome according to the voting policy, the proposal is EXPIRED
and Actions
aren't carried out.
sourcepub fn yes_vote_count(&self) -> Option<i32>
pub fn yes_vote_count(&self) -> Option<i32>
The current total of YES
votes cast on the proposal by members.
sourcepub fn no_vote_count(&self) -> Option<i32>
pub fn no_vote_count(&self) -> Option<i32>
The current total of NO
votes cast on the proposal by members.
sourcepub fn outstanding_vote_count(&self) -> Option<i32>
pub fn outstanding_vote_count(&self) -> Option<i32>
The number of votes remaining to be cast on the proposal by members. In other words, the number of members minus the sum of YES
votes and NO
votes.
Tags assigned to the proposal. Each tag consists of a key and optional value.
For more information about tags, see Tagging Resources in the Amazon Managed Blockchain Ethereum Developer Guide, or Tagging Resources in the Amazon Managed Blockchain Hyperledger Fabric Developer Guide.
sourcepub fn arn(&self) -> Option<&str>
pub fn arn(&self) -> Option<&str>
The Amazon Resource Name (ARN) of the proposal. For more information about ARNs and their format, see Amazon Resource Names (ARNs) in the Amazon Web Services General Reference.
Trait Implementations§
source§impl PartialEq for Proposal
impl PartialEq for Proposal
impl StructuralPartialEq for Proposal
Auto Trait Implementations§
impl Freeze for Proposal
impl RefUnwindSafe for Proposal
impl Send for Proposal
impl Sync for Proposal
impl Unpin for Proposal
impl UnwindSafe for Proposal
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> Instrument for T
impl<T> Instrument for T
source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoEither for T
impl<T> IntoEither for T
source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moresource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more