go-ethereum/swarm/api/testapi.go
zelig 5714724bab swap integration test
* add bzz.syncEnabled (hive.syncEnabled -> testapi/SyncEnabled | bzznosync param)) triggers nil sync State request to peer
* syncEnabled false then historical items are not delivered
* add swap initial scenarios, no funds, no retrieval; chequebook autodeployment; available funds -> retrieval
* remove -ipcexp option from swarm script
* tweaks to swarm/cmd files
* add Balance to chequebook api
* set chequebook balance from blockchain
* fix chequebook tests after balance check
* log balance when chequebook created
* fix state setting in ethereum backend
* add balanceAt to backend
2016-03-22 17:53:43 +07:00

28 lines
460 B
Go

package api
import (
// "fmt"
"github.com/ethereum/go-ethereum/swarm/network"
)
type Control struct {
api *Api
hive *network.Hive
}
func NewControl(api *Api, hive *network.Hive) *Control {
return &Control{api, hive}
}
func (self *Control) BlockNetworkRead(on bool) {
self.hive.BlockNetworkRead(on)
}
func (self *Control) SyncEnabled(on bool) {
self.hive.SyncEnabled(on)
}
func (self *Control) SwapEnabled(on bool) {
self.hive.SwapEnabled(on)
}