Package org.hyperledger.fabric.client
Interface Proposal.Builder
- Enclosing interface:
Proposal
Builder used to create a new transaction proposal.
-
Method Summary
Modifier and TypeMethodDescriptionaddArguments
(byte[]... args) Add transactions arguments to the proposal.addArguments
(String... args) Add transactions arguments to the proposal.build()
Build the proposal from the configuration state of this builder.putAllTransient
(Map<String, byte[]> transientData) Associates all of the specified transient data keys and values with the proposal.putTransient
(String key, byte[] value) Associates the specified transient data key and value with the proposal.putTransient
(String key, String value) Associates the specified transient data key and value with the proposal.setEndorsingOrganizations
(String... mspids) Specifies the set of organizations that will attempt to endorse the proposal.
-
Method Details
-
addArguments
Add transactions arguments to the proposal. These extend any previously added arguments.- Parameters:
args
- Transaction arguments.- Returns:
- This builder.
-
addArguments
Add transactions arguments to the proposal. These extend any previously added arguments.- Parameters:
args
- Transaction arguments.- Returns:
- This builder.
-
putAllTransient
Associates all of the specified transient data keys and values with the proposal.- Parameters:
transientData
- Transient data keys and values.- Returns:
- This builder.
-
putTransient
Associates the specified transient data key and value with the proposal.- Parameters:
key
- Key with which the specified value is to be associated.value
- Value to be associated with the specified key.- Returns:
- This builder.
-
putTransient
Associates the specified transient data key and value with the proposal.- Parameters:
key
- Key with which the specified value is to be associated.value
- Value to be associated with the specified key.- Returns:
- This builder.
-
setEndorsingOrganizations
Specifies the set of organizations that will attempt to endorse the proposal. No other organizations' peers will be sent this proposal. This is usually used in conjunction withputTransient(String, byte[])
orputAllTransient(Map)
for private data scenarios.- Parameters:
mspids
- The Member Services Provider IDs of the endorsing organizations.- Returns:
- This builder.
-
build
Proposal build()Build the proposal from the configuration state of this builder. A new transaction ID will be generated on each invocation of this method.
-