Skip to content

Commit 4e002a7

Browse files
Krishang NadgaudaKrishang Nadgauda
authored andcommitted
docs gen for token bundle
1 parent d56e388 commit 4e002a7

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

docs/ITokenBundle.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55

66

7-
7+
Group together arbitrary ERC20, ERC721 and ERC1155 tokens into a single bundle. The `Token` struct is a generic type that can describe any ERC20, ERC721 or ERC1155 token. The `Bundle` struct is a data structure to track a group/bundle of multiple assets i.e. ERC20, ERC721 and ERC1155 tokens, each described as a `Token`. Expressing tokens as the `Token` type, and grouping them as a `Bundle` allows for writing generic logic to handle any ERC20, ERC721 or ERC1155 tokens.
88

99

1010

docs/TokenBundle.md

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -10,60 +10,60 @@
1010

1111
## Methods
1212

13-
### getToken
13+
### getTokenCountOfBundle
1414

1515
```solidity
16-
function getToken(uint256 _bundleId, uint256 index) external view returns (struct ITokenBundle.Token)
16+
function getTokenCountOfBundle(uint256 _bundleId) external view returns (uint256)
1717
```
1818

1919

2020

21-
21+
*Returns the total number of assets in a particular bundle.*
2222

2323
#### Parameters
2424

2525
| Name | Type | Description |
2626
|---|---|---|
2727
| _bundleId | uint256 | undefined
28-
| index | uint256 | undefined
2928

3029
#### Returns
3130

3231
| Name | Type | Description |
3332
|---|---|---|
34-
| _0 | ITokenBundle.Token | undefined
33+
| _0 | uint256 | undefined
3534

36-
### getTokenCount
35+
### getTokenOfBundle
3736

3837
```solidity
39-
function getTokenCount(uint256 _bundleId) external view returns (uint256)
38+
function getTokenOfBundle(uint256 _bundleId, uint256 index) external view returns (struct ITokenBundle.Token)
4039
```
4140

4241

4342

44-
43+
*Returns an asset contained in a particular bundle, at a particular index.*
4544

4645
#### Parameters
4746

4847
| Name | Type | Description |
4948
|---|---|---|
5049
| _bundleId | uint256 | undefined
50+
| index | uint256 | undefined
5151

5252
#### Returns
5353

5454
| Name | Type | Description |
5555
|---|---|---|
56-
| _0 | uint256 | undefined
56+
| _0 | ITokenBundle.Token | undefined
5757

58-
### getUri
58+
### getUriOfBundle
5959

6060
```solidity
61-
function getUri(uint256 _bundleId) external view returns (string)
61+
function getUriOfBundle(uint256 _bundleId) external view returns (string)
6262
```
6363

6464

6565

66-
66+
*Returns the uri of a particular bundle.*
6767

6868
#### Parameters
6969

0 commit comments

Comments
 (0)