public static class ManageOfferOperation.Builder
extends java.lang.Object
setOfferId(long)
.ManageOfferOperation
Constructor and Description |
---|
Builder(Asset selling,
Asset buying,
java.lang.String amount,
java.lang.String price)
Creates a new ManageOffer builder.
|
Modifier and Type | Method and Description |
---|---|
ManageOfferOperation |
build()
Builds an operation
|
ManageOfferOperation.Builder |
setOfferId(long offerId)
Sets offer ID.
|
ManageOfferOperation.Builder |
setSourceAccount(KeyPair sourceAccount)
Sets the source account for this operation.
|
public Builder(Asset selling, Asset buying, java.lang.String amount, java.lang.String price)
setOfferId(long)
.selling
- The asset being sold in this operationbuying
- The asset being bought in this operationamount
- Amount of selling being sold.price
- Price of 1 unit of selling in terms of buying.java.lang.ArithmeticException
- when amount has more than 7 decimal places.public ManageOfferOperation.Builder setOfferId(long offerId)
0
creates a new offer. Set to existing offer ID to change it.offerId
- public ManageOfferOperation.Builder setSourceAccount(KeyPair sourceAccount)
sourceAccount
- The operation's source account.public ManageOfferOperation build()