-
Notifications
You must be signed in to change notification settings - Fork 274
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
- Loading branch information
1 parent
a10dac8
commit f89be52
Showing
11 changed files
with
634 additions
and
186 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
27 changes: 27 additions & 0 deletions
27
modules/sdk-coin-ton/src/lib/singleNominatorWithdrawBuilder.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
import { TransactionBuilder } from './transactionBuilder'; | ||
import { BaseCoin as CoinConfig } from '@bitgo/statics'; | ||
import { Recipient, TransactionType } from '@bitgo/sdk-core'; | ||
|
||
export class SingleNominatorWithdrawBuilder extends TransactionBuilder { | ||
constructor(_coinConfig: Readonly<CoinConfig>) { | ||
super(_coinConfig); | ||
} | ||
|
||
protected get transactionType(): TransactionType { | ||
return TransactionType.SingleNominatorWithdraw; | ||
} | ||
|
||
setWithdrawAmount(amount: string): SingleNominatorWithdrawBuilder { | ||
this.transaction.withdrawAmount = amount; | ||
return this; | ||
} | ||
|
||
send(recipient: Recipient): SingleNominatorWithdrawBuilder { | ||
this.transaction.recipient = recipient; | ||
return this; | ||
} | ||
|
||
setMessage(msg: string): SingleNominatorWithdrawBuilder { | ||
throw new Error('Method not implemented.'); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { ITransactionRecipient } from '@bitgo/sdk-core'; | ||
|
||
export interface ITransactionExplanation<TFee = any, TAmount = any> { | ||
displayOrder: string[]; | ||
id: string; | ||
outputs: ITransactionRecipient[]; | ||
outputAmount: TAmount; | ||
changeOutputs: ITransactionRecipient[]; | ||
changeAmount: TAmount; | ||
fee: TFee; | ||
proxy?: string; | ||
producers?: string[]; | ||
withdrawAmount?: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.