Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minor fix in vmt.md #197

Merged
merged 1 commit into from
Oct 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions docs/examples/Standards/vmt.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ The VMT service includes the following functions:
- `TransferFrom(from, to, id, amount)`
- `BatchTransferFrom(from, to, ids, amounts)`
- `BalanceOf(account, id)`
- `BalanceOfBatch(accounts, ids)`
- `IsApproved(account, operator)`
- `Name()`
- `Symbol()`
Expand Down Expand Up @@ -81,6 +82,14 @@ Returns the balance of tokens for a given account and token ID.
pub fn balance_of(&self, account: ActorId, id: TokenId) -> U256
```

#### `BalanceOfBatch`

Returns the balances of tokens for the specified accounts and token IDs.

```rust
pub fn balance_of_batch(&self, accounts: Vec<ActorId>, id: Vec<TokenId>) -> Vec<U256>
```

#### `IsApproved`

Checks if a specific operator is approved to manage the tokens of the `account`.
Expand Down Expand Up @@ -288,6 +297,7 @@ service Vmt {
query Burners : () -> vec actor_id;
query Minters : () -> vec actor_id;
query BalanceOf : (account: actor_id, id: u256) -> u256;
query BalanceOfBatch : (accounts: vec actor_id, ids: vec u256) -> vec u256;
query Decimals : () -> u8;


Expand Down