mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
eth, les: Add Backend API
This commit is contained in:
parent
f82d6c8336
commit
6501c1917c
2 changed files with 9 additions and 0 deletions
|
|
@ -17,6 +17,7 @@
|
||||||
package eth
|
package eth
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"errors"
|
||||||
"context"
|
"context"
|
||||||
"math/big"
|
"math/big"
|
||||||
|
|
||||||
|
|
@ -227,3 +228,7 @@ func (b *EthAPIBackend) ServiceFilter(ctx context.Context, session *bloombits.Ma
|
||||||
go session.Multiplex(bloomRetrievalBatch, bloomRetrievalWait, b.eth.bloomRequests)
|
go session.Multiplex(bloomRetrievalBatch, bloomRetrievalWait, b.eth.bloomRequests)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (b *EthAPIBackend) TxStatusByHash(ctx context.Context, hash common.Hash) (core.TxStatus, error) {
|
||||||
|
return core.TxStatusUnknown, errors.New("Not Support")
|
||||||
|
}
|
||||||
|
|
|
||||||
|
|
@ -197,3 +197,7 @@ func (b *LesApiBackend) ServiceFilter(ctx context.Context, session *bloombits.Ma
|
||||||
go session.Multiplex(bloomRetrievalBatch, bloomRetrievalWait, b.eth.bloomRequests)
|
go session.Multiplex(bloomRetrievalBatch, bloomRetrievalWait, b.eth.bloomRequests)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (b *LesApiBackend) TxStatusByHash(ctx context.Context, hash common.Hash) (core.TxStatus, error) {
|
||||||
|
return light.GetTxStatus(ctx, b.eth.odr, hash)
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue