interop: move into pkg/interop, replace pkg/vm/api
neo-storm has developed more wrappers for syscall APIs, so they can and should be used as a drop-in replacement for pkg/vm/api. Moving it out of vm, as it's not exactly related to the VM itself.
This commit is contained in:
parent
7cd91610df
commit
a1e3655560
38 changed files with 58 additions and 281 deletions
28
pkg/interop/iterator/iterator.go
Normal file
28
pkg/interop/iterator/iterator.go
Normal file
|
@ -0,0 +1,28 @@
|
|||
package iterator
|
||||
|
||||
// Package iterator provides function signatures that can be used inside
|
||||
// smart contracts that are written in the neo-go framework.
|
||||
|
||||
// Iterator stubs a NEO iterator object type.
|
||||
type Iterator struct{}
|
||||
|
||||
// Create creates an iterator from the given items.
|
||||
func Create(items []interface{}) Iterator {
|
||||
return Iterator{}
|
||||
}
|
||||
|
||||
// TODO: Better description for this.
|
||||
// Key returns the iterator key.
|
||||
func Key(it Iterator) interface{} {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Keys returns the iterator keys.
|
||||
func Keys(it Iterator) []interface{} {
|
||||
return nil
|
||||
}
|
||||
|
||||
// Values returns the iterator values.
|
||||
func Values(it Iterator) []interface{} {
|
||||
return nil
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue