Closed jack9684 closed 2 years ago
Hello @jack9684
Thanks for trying neow3j. 🎉
You can find docs in many places! 🎉 Including our website https://neow3j.io.
But, I think it would be nice if you take a look at this specific example -- which is an example to create a single transaction with multiple invokes in it to mint
a token.
This file is located in this same repository, in the contractinvoke
directory.
Please, close the issue if this solved your problem/question. 👍
@jack9684 any news?
@gsmachado thank u ,very much . is there any demo about recive public static Map<String, String> properties(ByteString tokenId) result,in java ? and is there some mistake on DivisibleNonFungibleToken.java :
private static void addToOwnersTokens(Hash160 owner, ByteString tokenId) { new StorageMap(ctx, createTokensOfPrefix(owner)).put(tokenId, tokenId); }
private static void removeOwnersToken(Hash160 owner, ByteString tokenId) {
new StorageMap(ctx, createTokensOfPrefix(owner)).put(tokenId, tokenId);
}
at line 180,and 184. i think removeOwnersToken should me delete it from createTokensOfPrefix(owner)s StorageMap?
[...] is there some mistake on DivisibleNonFungibleToken.java :
private static void addToOwnersTokens(Hash160 owner, ByteString tokenId) { new StorageMap(ctx, createTokensOfPrefix(owner)).put(tokenId, tokenId); }
private static void removeOwnersToken(Hash160 owner, ByteString tokenId) { new StorageMap(ctx, createTokensOfPrefix(owner)).put(tokenId, tokenId); }
at line 180,and 184. i think removeOwnersToken should me delete it from createTokensOfPrefix(owner)s StorageMap?
@jack9684, yes, you are correct. It's a mistake, it should be delete
. I've just pushed a commit that fixes that.
@gsmachado thank u ,very much . is there any demo about recive public static Map<String, String> properties(ByteString tokenId) result,in java ? [...]
@jack9684 There's currently no example in this repo, but you can check out the code in the NonFungibleToken
wrapper in neow3j here.
thank u very much ~
i found there are some nonfungibletoken contracts on neo-n3-examples.
is there any demo ,how to invoke the function according to java neo3j , like invoke the mint function with parameter ,and recieve prpoerties function value from the demo NonFungibleToken.java contract?