-
Notifications
You must be signed in to change notification settings - Fork 79
/
engine.go
29 lines (24 loc) · 892 Bytes
/
engine.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
package enginecontract
import (
"github.com/nspcc-dev/neo-go/pkg/interop/runtime"
)
// NotifyScriptContainer sends runtime notification with script container hash
func NotifyScriptContainer() {
tx := runtime.GetScriptContainer()
runtime.Notify("Tx", tx.Hash)
}
// NotifyCallingScriptHash sends runtime notification with calling script hash
func NotifyCallingScriptHash() {
callingScriptHash := runtime.GetCallingScriptHash()
runtime.Notify("Calling", callingScriptHash)
}
// NotifyExecutingScriptHash sends runtime notification about executing script hash
func NotifyExecutingScriptHash() {
execScriptHash := runtime.GetExecutingScriptHash()
runtime.Notify("Executing", execScriptHash)
}
// NotifyEntryScriptHash sends notification about entry script hash
func NotifyEntryScriptHash() {
entryScriptHash := runtime.GetEntryScriptHash()
runtime.Notify("Entry", entryScriptHash)
}