|
|
@ -9,7 +9,7 @@ import ( |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
const ( |
|
|
|
const ( |
|
|
|
MinerVersion = "1.0.0" |
|
|
|
MinerApiVersion = "1.0" |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
var ( |
|
|
|
var ( |
|
|
@ -69,6 +69,10 @@ func (self *minerApi) Name() string { |
|
|
|
return MinerApiName |
|
|
|
return MinerApiName |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
func (self *minerApi) ApiVersion() string { |
|
|
|
|
|
|
|
return MinerApiVersion |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
func (self *minerApi) StartMiner(req *shared.Request) (interface{}, error) { |
|
|
|
func (self *minerApi) StartMiner(req *shared.Request) (interface{}, error) { |
|
|
|
args := new(StartMinerArgs) |
|
|
|
args := new(StartMinerArgs) |
|
|
|
if err := self.codec.Decode(req.Params, &args); err != nil { |
|
|
|
if err := self.codec.Decode(req.Params, &args); err != nil { |
|
|
|