Documentation ¶
Overview ¶
Copyright IBM Corp. All Rights Reserved.
SPDX-License-Identifier: Apache-2.0
Index ¶
- func AssertTokensInVault(vault *network.Vault, tx *ttx.Transaction, outputs *token.OutputStream, ...)
- func GetTMSPublicParams(tms *token.ManagementService) []byte
- type AcceptCashView
- type AcceptPreparedCashView
- type AuditView
- type Balance
- type BalanceQuery
- type BalanceView
- type BalanceViewFactory
- type BroadcastPreparedTransfer
- type BroadcastPreparedTransferView
- type BroadcastPreparedTransferViewFactory
- type CheckIfExistsInVault
- type CheckIfExistsInVaultView
- type CheckIfExistsInVaultViewFactory
- type CheckPublicParamsMatch
- type CheckPublicParamsMatchView
- type CheckPublicParamsMatchViewFactory
- type CheckTTXDB
- type CheckTTXDBView
- type CheckTTXDBViewFactory
- type CurrentHolding
- type CurrentHoldingView
- type CurrentHoldingViewFactory
- type CurrentSpending
- type CurrentSpendingView
- type CurrentSpendingViewFactory
- type FinalityWithTimeout
- type FinalityWithTimeoutView
- type FinalityWithTimeoutViewFactory
- type GetAuditorWalletIdentity
- type GetAuditorWalletIdentityView
- type GetAuditorWalletIdentityViewFactory
- type GetEnrollmentID
- type GetEnrollmentIDView
- type GetEnrollmentIDViewFactory
- type GetIssuerWalletIdentity
- type GetIssuerWalletIdentityView
- type GetIssuerWalletIdentityViewFactory
- type GetPublicParams
- type GetPublicParamsView
- type GetPublicParamsViewFactory
- type IssueCash
- type IssueCashView
- type IssueCashViewFactory
- type ListAcceptedTransactions
- type ListAcceptedTransactionsView
- type ListAcceptedTransactionsViewFactory
- type ListAuditedTransactions
- type ListAuditedTransactionsView
- type ListAuditedTransactionsViewFactory
- type ListIssuedTokens
- type ListIssuedTokensView
- type ListIssuedTokensViewFactory
- type ListUnspentTokens
- type ListUnspentTokensView
- type ListUnspentTokensViewFactory
- type ListVaultUnspentTokens
- type ListVaultUnspentTokensView
- type ListVaultUnspentTokensViewFactory
- type PrepareTransferResult
- type PrepareTransferView
- type PrepareTransferViewFactory
- type PruneInvalidUnspentTokens
- type PruneInvalidUnspentTokensView
- type PruneInvalidUnspentTokensViewFactory
- type Redeem
- type RedeemView
- type RedeemViewFactory
- type RegisterAuditorView
- type RegisterAuditorViewFactory
- type RegisterCertifier
- type RegisterCertifierView
- type RegisterCertifierViewFactory
- type RegisterIssuerWallet
- type RegisterIssuerWalletView
- type RegisterIssuerWalletViewFactory
- type RegisterOwnerWallet
- type RegisterOwnerWalletView
- type RegisterOwnerWalletViewFactory
- type SetTransactionAuditStatus
- type SetTransactionAuditStatusView
- type SetTransactionAuditStatusViewFactory
- type SetTransactionOwnerStatus
- type SetTransactionOwnerStatusView
- type SetTransactionOwnerStatusViewFactory
- type Swap
- type SwapInitiatorView
- type SwapInitiatorViewFactory
- type SwapResponderView
- type TokenSelectorUnlock
- type TokenSelectorUnlockView
- type TokenSelectorUnlockViewFactory
- type TransactionInfo
- type TransactionInfoView
- type TransactionInfoViewFactory
- type Transfer
- type TransferView
- type TransferViewFactory
- type TransferWithSelectorView
- type TransferWithSelectorViewFactory
- type WhoDeletedToken
- type WhoDeletedTokenResult
- type WhoDeletedTokenView
- type WhoDeletedTokenViewFactory
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AssertTokensInVault ¶
func AssertTokensInVault(vault *network.Vault, tx *ttx.Transaction, outputs *token.OutputStream, id view.Identity)
AssertTokensInVault checks that the tokens are or are not in the vault
func GetTMSPublicParams ¶ added in v0.2.0
func GetTMSPublicParams(tms *token.ManagementService) []byte
Types ¶
type AcceptCashView ¶
type AcceptCashView struct{}
type AcceptPreparedCashView ¶
type AcceptPreparedCashView struct {
WaitFinality bool
}
type BalanceView ¶
type BalanceView struct {
*BalanceQuery
}
type BalanceViewFactory ¶
type BalanceViewFactory struct{}
type BroadcastPreparedTransferView ¶
type BroadcastPreparedTransferView struct {
*BroadcastPreparedTransfer
}
BroadcastPreparedTransferView is a view that broadcasts a prepared transfer transaction
type BroadcastPreparedTransferViewFactory ¶
type BroadcastPreparedTransferViewFactory struct{}
type CheckIfExistsInVaultView ¶
type CheckIfExistsInVaultView struct {
*CheckIfExistsInVault
}
type CheckIfExistsInVaultViewFactory ¶
type CheckIfExistsInVaultViewFactory struct { }
type CheckPublicParamsMatch ¶
type CheckPublicParamsMatchView ¶
type CheckPublicParamsMatchView struct {
*CheckPublicParamsMatch
}
type CheckPublicParamsMatchViewFactory ¶
type CheckPublicParamsMatchViewFactory struct{}
type CheckTTXDBView ¶
type CheckTTXDBView struct {
*CheckTTXDB
}
CheckTTXDBView is a view that performs consistency checks among the transaction db (either auditor or owner), the vault, and the backed. It reports a list of mismatch that can be used for debug purposes.
type CheckTTXDBViewFactory ¶
type CheckTTXDBViewFactory struct{}
type CurrentHolding ¶
type CurrentHoldingView ¶
type CurrentHoldingView struct {
*CurrentHolding
}
CurrentHoldingView is used to retrieve the current holding of token type of the passed enrollment id
type CurrentHoldingViewFactory ¶
type CurrentHoldingViewFactory struct{}
type CurrentSpending ¶
type CurrentSpendingView ¶
type CurrentSpendingView struct {
*CurrentSpending
}
CurrentSpendingView is used to retrieve the current spending of token type of the passed enrollment id
type CurrentSpendingViewFactory ¶
type CurrentSpendingViewFactory struct{}
type FinalityWithTimeout ¶
type FinalityWithTimeoutView ¶
type FinalityWithTimeoutView struct {
*FinalityWithTimeout
}
FinalityWithTimeoutView is a view that runs the finality view with timeout. The timeout is expected to happen
type FinalityWithTimeoutViewFactory ¶
type FinalityWithTimeoutViewFactory struct{}
type GetAuditorWalletIdentity ¶ added in v0.2.0
type GetAuditorWalletIdentity struct {
ID string
}
type GetAuditorWalletIdentityView ¶ added in v0.2.0
type GetAuditorWalletIdentityView struct {
*GetAuditorWalletIdentity
}
type GetAuditorWalletIdentityViewFactory ¶ added in v0.2.0
type GetAuditorWalletIdentityViewFactory struct{}
type GetEnrollmentID ¶
type GetEnrollmentIDView ¶
type GetEnrollmentIDView struct {
*GetEnrollmentID
}
GetEnrollmentIDView is a view that returns the enrollment ID of a wallet.
type GetEnrollmentIDViewFactory ¶
type GetEnrollmentIDViewFactory struct{}
type GetIssuerWalletIdentity ¶ added in v0.2.0
type GetIssuerWalletIdentity struct {
ID string
}
type GetIssuerWalletIdentityView ¶ added in v0.2.0
type GetIssuerWalletIdentityView struct {
*GetIssuerWalletIdentity
}
type GetIssuerWalletIdentityViewFactory ¶ added in v0.2.0
type GetIssuerWalletIdentityViewFactory struct{}
type GetPublicParams ¶ added in v0.2.0
type GetPublicParamsView ¶ added in v0.2.0
type GetPublicParamsView struct {
*GetPublicParams
}
type GetPublicParamsViewFactory ¶ added in v0.2.0
type GetPublicParamsViewFactory struct{}
type IssueCash ¶
type IssueCash struct { // Anonymous set to true if the transaction is anonymous, false otherwise Anonymous bool // Auditor is the name of the auditor identity Auditor string // IssuerWallet is the issuer's wallet to use IssuerWallet string // TokenType is the type of token to issue TokenType string // Quantity represent the number of units of a certain token type stored in the token Quantity uint64 // Recipient is the identity of the recipient's FSC node Recipient view.Identity }
IssueCash contains the input information to issue a token
type IssueCashView ¶
type IssueCashView struct {
*IssueCash
}
type IssueCashViewFactory ¶
type IssueCashViewFactory struct{}
type ListAcceptedTransactions ¶
type ListAcceptedTransactions struct { SenderWallet string RecipientWallet string From *time.Time To *time.Time ActionTypes []ttxdb.ActionType Statuses []driver.TxStatus }
ListAcceptedTransactions contains the input to query the list of accepted tokens
type ListAcceptedTransactionsView ¶
type ListAcceptedTransactionsView struct {
*ListAcceptedTransactions
}
type ListAcceptedTransactionsViewFactory ¶
type ListAcceptedTransactionsViewFactory struct{}
type ListAuditedTransactions ¶
type ListAuditedTransactionsView ¶
type ListAuditedTransactionsView struct {
*ListAuditedTransactions
}
type ListAuditedTransactionsViewFactory ¶
type ListAuditedTransactionsViewFactory struct{}
type ListIssuedTokens ¶
type ListIssuedTokens struct { // Wallet whose identities own the token Wallet string // TokenType is the token type to select TokenType string }
ListIssuedTokens contains the input to query the list of issued tokens
type ListIssuedTokensView ¶
type ListIssuedTokensView struct {
*ListIssuedTokens
}
type ListIssuedTokensViewFactory ¶
type ListIssuedTokensViewFactory struct{}
type ListUnspentTokens ¶
type ListUnspentTokens struct { // Wallet whose identities own the token Wallet string // TokenType is the token type to select TokenType string }
ListUnspentTokens contains the input to query the list of unspent tokens
type ListUnspentTokensView ¶
type ListUnspentTokensView struct {
*ListUnspentTokens
}
type ListUnspentTokensViewFactory ¶
type ListUnspentTokensViewFactory struct{}
type ListVaultUnspentTokens ¶
type ListVaultUnspentTokensView ¶
type ListVaultUnspentTokensView struct {
*ListVaultUnspentTokens
}
type ListVaultUnspentTokensViewFactory ¶
type ListVaultUnspentTokensViewFactory struct{}
type PrepareTransferResult ¶
type PrepareTransferView ¶
type PrepareTransferView struct {
*Transfer
}
PrepareTransferView is a view that prepares a transfer transaction without broadcasting it
type PrepareTransferViewFactory ¶
type PrepareTransferViewFactory struct{}
type PruneInvalidUnspentTokensView ¶
type PruneInvalidUnspentTokensView struct {
*PruneInvalidUnspentTokens
}
type PruneInvalidUnspentTokensViewFactory ¶
type PruneInvalidUnspentTokensViewFactory struct{}
type Redeem ¶
type Redeem struct { // Auditor is the name of the auditor that must be contacted to approve the operation Auditor string // Wallet is the identifier of the wallet that owns the tokens to redeem Wallet string // TokenIDs contains a list of token ids to redeem. If empty, tokens are selected on the spot. TokenIDs []*token.ID // Type of tokens to redeem Type string // Amount to redeem Amount uint64 }
Redeem contains the input information for a redeem
type RedeemView ¶
type RedeemView struct {
*Redeem
}
type RedeemViewFactory ¶
type RedeemViewFactory struct{}
type RegisterAuditorView ¶
type RegisterAuditorView struct{}
type RegisterAuditorViewFactory ¶
type RegisterAuditorViewFactory struct{}
type RegisterCertifier ¶
type RegisterCertifierView ¶
type RegisterCertifierView struct {
*RegisterCertifier
}
type RegisterCertifierViewFactory ¶
type RegisterCertifierViewFactory struct{}
type RegisterIssuerWallet ¶
type RegisterIssuerWalletView ¶
type RegisterIssuerWalletView struct {
*RegisterIssuerWallet
}
RegisterIssuerWalletView is a view that register an issuer wallet
type RegisterIssuerWalletViewFactory ¶
type RegisterIssuerWalletViewFactory struct{}
type RegisterOwnerWallet ¶ added in v0.2.0
type RegisterOwnerWalletView ¶ added in v0.2.0
type RegisterOwnerWalletView struct {
*RegisterOwnerWallet
}
RegisterOwnerWalletView is a view that registers an owner wallet
type RegisterOwnerWalletViewFactory ¶ added in v0.2.0
type RegisterOwnerWalletViewFactory struct{}
type SetTransactionAuditStatusView ¶
type SetTransactionAuditStatusView struct {
*SetTransactionAuditStatus
}
SetTransactionAuditStatusView is used to set the status of a given transaction in the audit db
type SetTransactionAuditStatusViewFactory ¶
type SetTransactionAuditStatusViewFactory struct{}
type SetTransactionOwnerStatusView ¶
type SetTransactionOwnerStatusView struct {
*SetTransactionOwnerStatus
}
SetTransactionOwnerStatusView is used to set the status of a given transaction in the audit db
type SetTransactionOwnerStatusViewFactory ¶
type SetTransactionOwnerStatusViewFactory struct{}
type Swap ¶
type Swap struct { // Auditor is the identity of the auditor that must be contacted to approve the transaction Auditor string // AliceWallet is the wallet Alice will use AliceWallet string // FromAliceType is the token type Alice will transfer FromAliceType string // FromAliceAmount is the amount Alice will transfer FromAliceAmount uint64 // FromBobType is the token type Bob will transfer FromBobType string // FromBobAmount is the amount Bob will transfer FromBobAmount uint64 // Bob is the identity of the Bob's FSC node Bob view.Identity }
Swap contains the input information for a swap
type SwapInitiatorView ¶
type SwapInitiatorView struct {
*Swap
}
type SwapInitiatorViewFactory ¶
type SwapInitiatorViewFactory struct{}
type SwapResponderView ¶
type SwapResponderView struct{}
type TokenSelectorUnlock ¶
type TokenSelectorUnlock struct {
TxID string
}
type TokenSelectorUnlockView ¶
type TokenSelectorUnlockView struct {
*TokenSelectorUnlock
}
TokenSelectorUnlockView is a view that broadcasts a prepared transfer transaction
type TokenSelectorUnlockViewFactory ¶
type TokenSelectorUnlockViewFactory struct{}
type TransactionInfo ¶
type TransactionInfo struct {
TransactionID string
}
TransactionInfo contains the input information to search for transaction info
type TransactionInfoView ¶
type TransactionInfoView struct {
*TransactionInfo
}
type TransactionInfoViewFactory ¶
type TransactionInfoViewFactory struct{}
type Transfer ¶
type Transfer struct { // Auditor is the name of the auditor that must be contacted to approve the operation Auditor string // Wallet is the identifier of the wallet that owns the tokens to transfer Wallet string // TokenIDs contains a list of token ids to transfer. If empty, tokens are selected on the spot. TokenIDs []*token.ID // Type of tokens to transfer Type string // Amount to transfer Amount uint64 // Recipient is the identity of the recipient's FSC node Recipient view.Identity // Retry tells if a retry must happen in case of a failure Retry bool // FailToRelease if true, it fails after transfer to trigger the Release function on the token transaction FailToRelease bool }
Transfer contains the input information for a transfer
type TransferView ¶
type TransferView struct {
*Transfer
}
type TransferViewFactory ¶
type TransferViewFactory struct{}
type TransferWithSelectorView ¶
type TransferWithSelectorView struct {
*Transfer
}
type TransferWithSelectorViewFactory ¶
type TransferWithSelectorViewFactory struct{}
type WhoDeletedTokenResult ¶
type WhoDeletedTokenView ¶
type WhoDeletedTokenView struct {
*WhoDeletedToken
}
type WhoDeletedTokenViewFactory ¶
type WhoDeletedTokenViewFactory struct{}