mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2025-05-05 03:06:16 +00:00
core: implement System.Json.* interops
This commit is contained in:
parent
d836233352
commit
6339efac11
3 changed files with 100 additions and 0 deletions
|
@ -14,6 +14,7 @@ import (
|
|||
"github.com/nspcc-dev/neo-go/pkg/core/interop/crypto"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop/enumerator"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop/iterator"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop/json"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/interop/runtime"
|
||||
"github.com/nspcc-dev/neo-go/pkg/core/native"
|
||||
"github.com/nspcc-dev/neo-go/pkg/smartcontract"
|
||||
|
@ -105,6 +106,8 @@ var systemInterops = []interop.Function{
|
|||
{Name: "System.Iterator.Key", Func: iterator.Key, Price: 400},
|
||||
{Name: "System.Iterator.Keys", Func: iterator.Keys, Price: 400},
|
||||
{Name: "System.Iterator.Values", Func: iterator.Values, Price: 400},
|
||||
{Name: "System.Json.Deserialize", Func: json.Deserialize, Price: 500000},
|
||||
{Name: "System.Json.Serialize", Func: json.Serialize, Price: 100000},
|
||||
{Name: "System.Runtime.CheckWitness", Func: runtime.CheckWitness, Price: 200, RequiredFlags: smartcontract.AllowStates},
|
||||
{Name: "System.Runtime.GetTime", Func: runtimeGetTime, Price: 1,
|
||||
AllowedTriggers: trigger.Application, RequiredFlags: smartcontract.AllowStates},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue