neo-modules
neo-modules copied to clipboard
RpcServer convert enumerator to array for rpcclient
When we meet enumerator type in contract, we can convert to array in rpcserver for rpclient to use.
E.g:
// NFT contract
public static enumerator tokensOf(byte[] owner)
When we meet
enumeratortype in contract, we can convert to array in rpcserver for rpclient to use.E.g:
// NFT contract public static enumerator tokensOf(byte[] owner)
Highly Agree with it. It is too difficult for front-end developers and SDK to handle the enumerator directly.
I think this is also needed on neo-cli invoke.
It is better to add the pagination index parameter, which can be changed later
@ProDog You can open an issue for neo-cli 👍
@ProDog You can open an issue for neo-cli 👍
https://github.com/neo-project/neo/issues/3010
An enumerator can contain any number of elements, and you may have problems converting it to an array.
@erikzhang Are you concerned about the size limit of an array? @doubiliu mentioned above to add paging to solve this problem.