Documentation ¶
Index ¶
- type DBCreator
- type DataManager
- func (m *DataManager) AddV3Ledger(data *database.V3Ledger) (uint64, error)
- func (m *DataManager) AddV3Payment(data *database.V3Payment) (uint64, error)
- func (m *DataManager) AddV3PaymentStmt(stmt *sql.Stmt, data *database.V3Payment) (err error)
- func (m *DataManager) AddV3Transaction(data *database.V3Transaction) (uint64, error)
- func (m *DataManager) AddV3TransactionStmt(stmt *sql.Stmt, data *database.V3Transaction) (err error)
- func (m *DataManager) Close()
- func (m *DataManager) PrepareV3Payment() (*sql.Stmt, error)
- func (m *DataManager) PrepareV3Transaction() (*sql.Stmt, error)
- func (m *DataManager) QTxBegin() error
- func (m *DataManager) QTxCommit() error
- func (m *DataManager) QTxRollback() error
- func (m *DataManager) QueryV3AccountTxs(address string, begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
- func (m *DataManager) QueryV3AllLedger(begin, end uint64, cursor, limit uint64, order string) ([]database.V3Ledger, error)
- func (m *DataManager) QueryV3AllPayments(symbol, contract string, begin, end uint64, cursor, limit uint64, order string) ([]database.V3Payment, error)
- func (m *DataManager) QueryV3AllTxs(begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
- func (m *DataManager) QueryV3BlockTxs(height int64, begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
- func (m *DataManager) QueryV3Ledger(height int64) (*database.V3Ledger, error)
- func (m *DataManager) QueryV3PaymentsByAddress(address, symbol, contract string, begin, end uint64, cursor, limit uint64, ...) ([]database.V3Payment, error)
- func (m *DataManager) QueryV3PaymentsByHash(hash, symbol, contract string, begin, end uint64, cursor, limit uint64, ...) ([]database.V3Payment, error)
- func (m *DataManager) QueryV3PaymentsByHeight(height int64, symbol, contract string, begin, end uint64, cursor, limit uint64, ...) ([]database.V3Payment, error)
- func (m *DataManager) QueryV3SingleTx(hash string) (*database.V3Transaction, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DataManager ¶
type DataManager struct {
// contains filtered or unexported fields
}
DataManager data access between app and database
func NewDataManager ¶
func NewDataManager(dbname string, dbc DBCreator) (*DataManager, error)
NewDataManager create data manager
func (*DataManager) AddV3Ledger ¶
func (m *DataManager) AddV3Ledger(data *database.V3Ledger) (uint64, error)
func (*DataManager) AddV3Payment ¶
func (m *DataManager) AddV3Payment(data *database.V3Payment) (uint64, error)
func (*DataManager) AddV3PaymentStmt ¶
func (*DataManager) AddV3Transaction ¶
func (m *DataManager) AddV3Transaction(data *database.V3Transaction) (uint64, error)
func (*DataManager) AddV3TransactionStmt ¶
func (m *DataManager) AddV3TransactionStmt(stmt *sql.Stmt, data *database.V3Transaction) (err error)
func (*DataManager) PrepareV3Payment ¶
func (m *DataManager) PrepareV3Payment() (*sql.Stmt, error)
func (*DataManager) PrepareV3Transaction ¶
func (m *DataManager) PrepareV3Transaction() (*sql.Stmt, error)
func (*DataManager) QTxBegin ¶
func (m *DataManager) QTxBegin() error
QTxBegin start database transaction of wdb
func (*DataManager) QTxCommit ¶
func (m *DataManager) QTxCommit() error
QTxCommit commit database transaction of wdb
func (*DataManager) QTxRollback ¶
func (m *DataManager) QTxRollback() error
QTxRollback rollback database transaction of wdb
func (*DataManager) QueryV3AccountTxs ¶
func (m *DataManager) QueryV3AccountTxs(address string, begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
func (*DataManager) QueryV3AllLedger ¶
func (*DataManager) QueryV3AllPayments ¶
func (*DataManager) QueryV3AllTxs ¶
func (m *DataManager) QueryV3AllTxs(begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
func (*DataManager) QueryV3BlockTxs ¶
func (m *DataManager) QueryV3BlockTxs(height int64, begin, end uint64, cursor, limit uint64, order string) ([]database.V3Transaction, error)
func (*DataManager) QueryV3Ledger ¶
func (m *DataManager) QueryV3Ledger(height int64) (*database.V3Ledger, error)
func (*DataManager) QueryV3PaymentsByAddress ¶
func (*DataManager) QueryV3PaymentsByHash ¶
func (*DataManager) QueryV3PaymentsByHeight ¶
func (*DataManager) QueryV3SingleTx ¶
func (m *DataManager) QueryV3SingleTx(hash string) (*database.V3Transaction, error)
Click to show internal directories.
Click to hide internal directories.