Documentation ¶
Index ¶
- func CheckAccountIsExist(name common.Name) (bool, error)
- func ClientCall(method string, result interface{}, args ...interface{}) error
- func DefultURL() string
- func GasPrice() (*big.Int, error)
- func GetAccountBalanceByID(accountName common.Name, assetID uint64) (*big.Int, error)
- func GetAccountByName(name common.Name) (*accountmanager.Account, error)
- func GetAssetInfoByName(assetName string) (*asset.AssetObject, error)
- func GetBlockByNumber(height uint64, fullTx bool) (map[string]interface{}, error)
- func GetCurrentBlock(fullTx bool) (map[string]interface{}, error)
- func GetDposAccount(name common.Name) (map[string]interface{}, error)
- func GetNonce(accountname common.Name) (uint64, error)
- func GetTransactionByHash(hash common.Hash) (*types.RPCTransaction, error)
- func MustRPCClient() *rpc.Client
- func SendRawTx(rawTx []byte) (common.Hash, error)
- func SetDefultURL(rpchost string)
- type Account
- func (acc *Account) ChangeProducer(to common.Name, value *big.Int, id uint64, gas uint64, producer string) []byte
- func (acc *Account) CreateAccount(to common.Name, value *big.Int, id uint64, gas uint64, pubkey common.PubKey) []byte
- func (acc *Account) PubKey() common.PubKey
- func (acc *Account) RegProducer(to common.Name, value *big.Int, id uint64, gas uint64, url string, ...) []byte
- func (acc *Account) Transfer(to common.Name, value *big.Int, id uint64, gas uint64) []byte
- func (acc *Account) UnRegProducer(to common.Name, value *big.Int, id uint64, gas uint64) []byte
- func (acc *Account) UnvoteProducer(to common.Name, value *big.Int, id uint64, gas uint64) []byte
- func (acc *Account) UnvoteVoter(to common.Name, value *big.Int, id uint64, gas uint64, voter string) []byte
- func (acc *Account) UpdateProducer(to common.Name, value *big.Int, id uint64, gas uint64, url string, ...) []byte
- func (acc *Account) VoteProducer(to common.Name, value *big.Int, id uint64, gas uint64, producer string, ...) []byte
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CheckAccountIsExist ¶
CheckAccountIsExist check Account is exist.
func ClientCall ¶
ClientCall Wrapper rpc call api.
func GetAccountBalanceByID ¶
GetAccountBalanceByID get balance by address ,assetID and number.
func GetAccountByName ¶
func GetAccountByName(name common.Name) (*accountmanager.Account, error)
func GetAssetInfoByName ¶
func GetAssetInfoByName(assetName string) (*asset.AssetObject, error)
GetAssetInfoByName get assetINfo by accountName
func GetBlockByNumber ¶
GetBlockByNumber returns the requested block.
func GetCurrentBlock ¶
GetCurrentBlock returns cureent block.
func GetTransactionByHash ¶
func GetTransactionByHash(hash common.Hash) (*types.RPCTransaction, error)
GetTransactionByHash returns the transaction for the given hash
func SetDefultURL ¶
func SetDefultURL(rpchost string)
Types ¶
type Account ¶
type Account struct {
// contains filtered or unexported fields
}
Account
func NewAccount ¶
func (*Account) ChangeProducer ¶
func (acc *Account) ChangeProducer(to common.Name, value *big.Int, id uint64, gas uint64, producer string) []byte
ChangeProducer
func (*Account) CreateAccount ¶
func (acc *Account) CreateAccount(to common.Name, value *big.Int, id uint64, gas uint64, pubkey common.PubKey) []byte
CreateAccount
func (*Account) RegProducer ¶
func (acc *Account) RegProducer(to common.Name, value *big.Int, id uint64, gas uint64, url string, state *big.Int) []byte
RegProducer
func (*Account) UnRegProducer ¶
UnRegProducer
func (*Account) UnvoteProducer ¶
func (*Account) UnvoteVoter ¶
func (acc *Account) UnvoteVoter(to common.Name, value *big.Int, id uint64, gas uint64, voter string) []byte
UnvoteVoter
Click to show internal directories.
Click to hide internal directories.