Interface Proposal.Builder
-
- All Superinterfaces:
Buildable,CopyableBuilder<Proposal.Builder,Proposal>,SdkBuilder<Proposal.Builder,Proposal>,SdkPojo
- Enclosing class:
- Proposal
public static interface Proposal.Builder extends SdkPojo, CopyableBuilder<Proposal.Builder,Proposal>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default Proposal.Builderactions(Consumer<ProposalActions.Builder> actions)The actions to perform on the network if the proposal isAPPROVED.Proposal.Builderactions(ProposalActions actions)The actions to perform on the network if the proposal isAPPROVED.Proposal.Builderarn(String arn)The Amazon Resource Name (ARN) of the proposal.Proposal.BuildercreationDate(Instant creationDate)The date and time that the proposal was created.Proposal.Builderdescription(String description)The description of the proposal.Proposal.BuilderexpirationDate(Instant expirationDate)The date and time that the proposal expires.Proposal.BuildernetworkId(String networkId)The unique identifier of the network for which the proposal is made.Proposal.BuildernoVoteCount(Integer noVoteCount)The current total ofNOvotes cast on the proposal by members.Proposal.BuilderoutstandingVoteCount(Integer outstandingVoteCount)The number of votes remaining to be cast on the proposal by members.Proposal.BuilderproposalId(String proposalId)The unique identifier of the proposal.Proposal.BuilderproposedByMemberId(String proposedByMemberId)The unique identifier of the member that created the proposal.Proposal.BuilderproposedByMemberName(String proposedByMemberName)The name of the member that created the proposal.Proposal.Builderstatus(String status)The status of the proposal.Proposal.Builderstatus(ProposalStatus status)The status of the proposal.Proposal.Buildertags(Map<String,String> tags)Tags assigned to the proposal.Proposal.BuilderyesVoteCount(Integer yesVoteCount)The current total ofYESvotes cast on the proposal by members.-
Methods inherited from interface software.amazon.awssdk.utils.builder.CopyableBuilder
copy
-
Methods inherited from interface software.amazon.awssdk.utils.builder.SdkBuilder
applyMutation, build
-
Methods inherited from interface software.amazon.awssdk.core.SdkPojo
equalsBySdkFields, sdkFieldNameToField, sdkFields
-
-
-
-
Method Detail
-
proposalId
Proposal.Builder proposalId(String proposalId)
The unique identifier of the proposal.
- Parameters:
proposalId- The unique identifier of the proposal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
networkId
Proposal.Builder networkId(String networkId)
The unique identifier of the network for which the proposal is made.
- Parameters:
networkId- The unique identifier of the network for which the proposal is made.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
description
Proposal.Builder description(String description)
The description of the proposal.
- Parameters:
description- The description of the proposal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
actions
Proposal.Builder actions(ProposalActions actions)
The actions to perform on the network if the proposal is
APPROVED.- Parameters:
actions- The actions to perform on the network if the proposal isAPPROVED.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
actions
default Proposal.Builder actions(Consumer<ProposalActions.Builder> actions)
The actions to perform on the network if the proposal is
This is a convenience method that creates an instance of theAPPROVED.ProposalActions.Builderavoiding the need to create one manually viaProposalActions.builder().When the
Consumercompletes,SdkBuilder.build()is called immediately and its result is passed toactions(ProposalActions).- Parameters:
actions- a consumer that will call methods onProposalActions.Builder- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
actions(ProposalActions)
-
proposedByMemberId
Proposal.Builder proposedByMemberId(String proposedByMemberId)
The unique identifier of the member that created the proposal.
- Parameters:
proposedByMemberId- The unique identifier of the member that created the proposal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
proposedByMemberName
Proposal.Builder proposedByMemberName(String proposedByMemberName)
The name of the member that created the proposal.
- Parameters:
proposedByMemberName- The name of the member that created the proposal.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
status
Proposal.Builder status(String status)
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 sufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specified proposal actions are carried out. -
REJECTED- The proposal was rejected with insufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specifiedProposalActionsaren't carried out. -
EXPIRED- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActionsaren't carried out. -
ACTION_FAILED- One or more of the specifiedProposalActionsin a proposal that was approved couldn't be completed because of an error. TheACTION_FAILEDstatus occurs even if only one ProposalAction fails and other actions are successful.
- Parameters:
status- 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 sufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specified proposal actions are carried out. -
REJECTED- The proposal was rejected with insufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specifiedProposalActionsaren't carried out. -
EXPIRED- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActionsaren't carried out. -
ACTION_FAILED- One or more of the specifiedProposalActionsin a proposal that was approved couldn't be completed because of an error. TheACTION_FAILEDstatus occurs even if only one ProposalAction fails and other actions are successful.
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
ProposalStatus,ProposalStatus
-
-
status
Proposal.Builder status(ProposalStatus status)
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 sufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specified proposal actions are carried out. -
REJECTED- The proposal was rejected with insufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specifiedProposalActionsaren't carried out. -
EXPIRED- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActionsaren't carried out. -
ACTION_FAILED- One or more of the specifiedProposalActionsin a proposal that was approved couldn't be completed because of an error. TheACTION_FAILEDstatus occurs even if only one ProposalAction fails and other actions are successful.
- Parameters:
status- 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 sufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specified proposal actions are carried out. -
REJECTED- The proposal was rejected with insufficientYESvotes among members according to theVotingPolicyspecified for theNetwork. The specifiedProposalActionsaren't carried out. -
EXPIRED- Members didn't cast the number of votes required to determine the proposal outcome before the proposal expired. The specifiedProposalActionsaren't carried out. -
ACTION_FAILED- One or more of the specifiedProposalActionsin a proposal that was approved couldn't be completed because of an error. TheACTION_FAILEDstatus occurs even if only one ProposalAction fails and other actions are successful.
-
- Returns:
- Returns a reference to this object so that method calls can be chained together.
- See Also:
ProposalStatus,ProposalStatus
-
-
creationDate
Proposal.Builder creationDate(Instant creationDate)
The date and time that the proposal was created.
- Parameters:
creationDate- The date and time that the proposal was created.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
expirationDate
Proposal.Builder expirationDate(Instant expirationDate)
The date and time that the proposal expires. This is the
CreationDateplus theProposalDurationInHoursthat is specified in theProposalThresholdPolicy. After this date and time, if members haven't cast enough votes to determine the outcome according to the voting policy, the proposal isEXPIREDandActionsaren't carried out.- Parameters:
expirationDate- The date and time that the proposal expires. This is theCreationDateplus theProposalDurationInHoursthat is specified in theProposalThresholdPolicy. After this date and time, if members haven't cast enough votes to determine the outcome according to the voting policy, the proposal isEXPIREDandActionsaren't carried out.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
yesVoteCount
Proposal.Builder yesVoteCount(Integer yesVoteCount)
The current total of
YESvotes cast on the proposal by members.- Parameters:
yesVoteCount- The current total ofYESvotes cast on the proposal by members.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
noVoteCount
Proposal.Builder noVoteCount(Integer noVoteCount)
The current total of
NOvotes cast on the proposal by members.- Parameters:
noVoteCount- The current total ofNOvotes cast on the proposal by members.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
outstandingVoteCount
Proposal.Builder outstandingVoteCount(Integer outstandingVoteCount)
The number of votes remaining to be cast on the proposal by members. In other words, the number of members minus the sum of
YESvotes andNOvotes.- Parameters:
outstandingVoteCount- The number of votes remaining to be cast on the proposal by members. In other words, the number of members minus the sum ofYESvotes andNOvotes.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
tags
Proposal.Builder tags(Map<String,String> tags)
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.
- Parameters:
tags- 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.
- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
arn
Proposal.Builder arn(String arn)
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.
- Parameters:
arn- 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.- Returns:
- Returns a reference to this object so that method calls can be chained together.
-
-