Documentation ¶
Index ¶
- Constants
- func CheckAccessToken(auth_type, access_token string) (cakey string, errCode int64, result interface{})
- func CheckPushBlock() bool
- func GetAssetByHash(cmd map[string]interface{}) map[string]interface{}
- func GetBalanceByAddr(cmd map[string]interface{}) map[string]interface{}
- func GetBalanceByAsset(cmd map[string]interface{}) map[string]interface{}
- func GetBlockByHash(cmd map[string]interface{}) map[string]interface{}
- func GetBlockByHeight(cmd map[string]interface{}) map[string]interface{}
- func GetBlockHash(cmd map[string]interface{}) map[string]interface{}
- func GetBlockHeight(cmd map[string]interface{}) map[string]interface{}
- func GetBlockInfo(block *ledger.Block) BlockInfo
- func GetBlockTransactions(block *ledger.Block) interface{}
- func GetBlockTxsByHeight(cmd map[string]interface{}) map[string]interface{}
- func GetConnectionCount(cmd map[string]interface{}) map[string]interface{}
- func GetContract(cmd map[string]interface{}) map[string]interface{}
- func GetNoticeServerUrl(cmd map[string]interface{}) map[string]interface{}
- func GetOauthServerUrl(cmd map[string]interface{}) map[string]interface{}
- func GetStateUpdate(cmd map[string]interface{}) map[string]interface{}
- func GetTransactionByHash(cmd map[string]interface{}) map[string]interface{}
- func GetTransactionPool(cmd map[string]interface{}) map[string]interface{}
- func GetUnspendOutput(cmd map[string]interface{}) map[string]interface{}
- func GetUnspends(cmd map[string]interface{}) map[string]interface{}
- func NewOauthClient() *http.Client
- func OauthRequest(method string, cmd map[string]interface{}, url string) (map[string]interface{}, error)
- func PostRequest(cmd map[string]interface{}, url string) (map[string]interface{}, error)
- func ResponsePack(errCode int64) map[string]interface{}
- func SendRawTransaction(cmd map[string]interface{}) map[string]interface{}
- func SendRecord(cmd map[string]interface{}) map[string]interface{}
- func SendRecordTransaction(cmd map[string]interface{}) map[string]interface{}
- func SetNode(n Noder)
- func SetNoticeServerUrl(cmd map[string]interface{}) map[string]interface{}
- func SetOauthServerUrl(cmd map[string]interface{}) map[string]interface{}
- func SetPushBlockFlag(cmd map[string]interface{}) map[string]interface{}
- type ApiServer
Constants ¶
View Source
const AttributeMaxLen = 252
View Source
const TlsPort int = 443
Variables ¶
This section is empty.
Functions ¶
func CheckAccessToken ¶
func CheckPushBlock ¶
func CheckPushBlock() bool
func GetBalanceByAddr ¶
func GetBalanceByAsset ¶
func GetBlockByHash ¶
func GetBlockByHeight ¶
func GetBlockHash ¶
func GetBlockInfo ¶
func GetTotalIssued(cmd map[string]interface{}) map[string]interface{} { resp := ResponsePack(Err.SUCCESS) assetid, ok := cmd["Assetid"].(string) if !ok { resp["Error"] = Err.INVALID_PARAMS return resp } var assetHash Uint256 bys, err := HexStringToBytesReverse(assetid) if err != nil { resp["Error"] = Err.INVALID_PARAMS return resp } if err := assetHash.Deserialize(bytes.NewReader(bys)); err != nil { resp["Error"] = Err.INVALID_PARAMS return resp } amount, err := ledger.DefaultLedger.Store.GetQuantityIssued(assetHash) if err != nil { resp["Error"] = Err.INVALID_PARAMS return resp } resp["Result"] = amount.String() return resp }
func GetBlockTransactions ¶
func GetBlockTxsByHeight ¶
func GetConnectionCount ¶
Node
func GetContract ¶
func GetNoticeServerUrl ¶
func GetOauthServerUrl ¶
config
func GetStateUpdate ¶
stateupdate
func GetTransactionByHash ¶
Transaction
func GetTransactionPool ¶
func GetUnspendOutput ¶
func GetUnspends ¶
func NewOauthClient ¶
func OauthRequest ¶
func PostRequest ¶
func ResponsePack ¶
func SendRawTransaction ¶
func SendRecord ¶
func SendRecordTransaction ¶
func SetNoticeServerUrl ¶
func SetOauthServerUrl ¶
func SetPushBlockFlag ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.