2016-09-11 11:44:14 +00:00
|
|
|
package geth
|
2016-06-22 18:56:27 +00:00
|
|
|
|
2016-07-27 11:47:41 +00:00
|
|
|
import (
|
2016-11-05 17:12:24 +00:00
|
|
|
"github.com/ethereum/go-ethereum/common"
|
2016-08-31 18:02:06 +00:00
|
|
|
"github.com/ethereum/go-ethereum/les/status"
|
2016-07-27 11:47:41 +00:00
|
|
|
)
|
|
|
|
|
2016-06-22 18:56:27 +00:00
|
|
|
type AccountInfo struct {
|
2016-08-18 00:15:58 +00:00
|
|
|
Address string `json:"address"`
|
|
|
|
PubKey string `json:"pubkey"`
|
|
|
|
Mnemonic string `json:"mnemonic"`
|
|
|
|
Error string `json:"error"`
|
2016-06-22 18:56:27 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
type JSONError struct {
|
|
|
|
Error string `json:"error"`
|
|
|
|
}
|
2016-07-04 16:00:29 +00:00
|
|
|
|
|
|
|
type AddPeerResult struct {
|
2016-07-27 11:47:41 +00:00
|
|
|
Success bool `json:"success"`
|
|
|
|
Error string `json:"error"`
|
2016-07-04 16:00:29 +00:00
|
|
|
}
|
2016-07-12 18:10:37 +00:00
|
|
|
|
|
|
|
type AddWhisperFilterResult struct {
|
2016-07-27 11:47:41 +00:00
|
|
|
Id int `json:"id"`
|
|
|
|
Error string `json:"error"`
|
2016-07-12 18:10:37 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
type WhisperMessageEvent struct {
|
2016-07-27 11:47:41 +00:00
|
|
|
Payload string `json:"payload"`
|
|
|
|
To string `json:"to"`
|
|
|
|
From string `json:"from"`
|
|
|
|
Sent int64 `json:"sent"`
|
|
|
|
TTL int64 `json:"ttl"`
|
|
|
|
Hash string `json:"hash"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type SendTransactionEvent struct {
|
2016-10-07 14:48:36 +00:00
|
|
|
Id string `json:"id"`
|
|
|
|
Args status.SendTxArgs `json:"args"`
|
|
|
|
MessageId string `json:"message_id"`
|
2016-07-12 18:10:37 +00:00
|
|
|
}
|
|
|
|
|
2016-10-26 02:51:33 +00:00
|
|
|
type ReturnSendTransactionEvent struct {
|
|
|
|
Id string `json:"id"`
|
|
|
|
Args status.SendTxArgs `json:"args"`
|
|
|
|
MessageId string `json:"message_id"`
|
|
|
|
ErrorMessage string `json:"error_message"`
|
|
|
|
ErrorCode string `json:"error_code"`
|
|
|
|
}
|
|
|
|
|
2016-08-09 16:41:42 +00:00
|
|
|
type CompleteTransactionResult struct {
|
2016-11-05 17:12:24 +00:00
|
|
|
Id string `json:"id"`
|
2016-08-09 16:41:42 +00:00
|
|
|
Hash string `json:"hash"`
|
|
|
|
Error string `json:"error"`
|
|
|
|
}
|
|
|
|
|
2016-11-05 17:12:24 +00:00
|
|
|
type RawCompleteTransactionResult struct {
|
|
|
|
Hash common.Hash
|
|
|
|
Error error
|
|
|
|
}
|
|
|
|
|
|
|
|
type CompleteTransactionsResult struct {
|
|
|
|
Results map[string]CompleteTransactionResult `json:"results"`
|
|
|
|
}
|
|
|
|
|
|
|
|
type RawDiscardTransactionResult struct {
|
|
|
|
Error error
|
|
|
|
}
|
|
|
|
|
2016-10-30 22:35:10 +00:00
|
|
|
type DiscardTransactionResult struct {
|
|
|
|
Id string `json:"id"`
|
|
|
|
Error string `json:"error"`
|
|
|
|
}
|
|
|
|
|
2016-11-05 17:12:24 +00:00
|
|
|
type DiscardTransactionsResult struct {
|
|
|
|
Results map[string]DiscardTransactionResult `json:"results"`
|
|
|
|
}
|
|
|
|
|
2016-07-12 18:10:37 +00:00
|
|
|
type GethEvent struct {
|
2016-07-27 11:47:41 +00:00
|
|
|
Type string `json:"type"`
|
|
|
|
Event interface{} `json:"event"`
|
|
|
|
}
|
2016-10-07 14:48:36 +00:00
|
|
|
|
|
|
|
type RPCCall struct {
|
|
|
|
Id int64
|
|
|
|
Method string
|
|
|
|
Params []interface{}
|
|
|
|
}
|