neo-go/pkg/interop/native/oracle/oracle.go
Evgeniy Stratonikov cbda20aca3 core: fix native method call flags
Replace `WriteStates` with `States`.

Follow neo-project/neo#2339.
Close #1775.
Related #1725.
2021-02-25 18:07:33 +03:00

16 lines
558 B
Go

package oracle
import (
"github.com/nspcc-dev/neo-go/pkg/interop"
"github.com/nspcc-dev/neo-go/pkg/interop/contract"
)
// Hash represents Oracle contract hash.
const Hash = "\xee\x80\x4c\x14\x29\x68\xd4\x78\x8b\x8a\xff\x51\xda\xde\xdf\xcb\x42\xe7\xc0\x8d"
// Request represents `request` method of Oracle native contract.
func Request(url string, filter []byte, cb string, userData interface{}, gasForResponse int) {
contract.Call(interop.Hash160(Hash), "request",
contract.States|contract.AllowNotify,
url, filter, cb, userData, gasForResponse)
}