ripple-binary-codec 2.1.0 → 4.0.1-mpt-beta

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -18,7 +18,7 @@
18
18
  "PathSet": 18,
19
19
  "Vector256": 19,
20
20
  "UInt96": 20,
21
- "UInt192": 21,
21
+ "Hash192": 21,
22
22
  "UInt384": 22,
23
23
  "UInt512": 23,
24
24
  "Issue": 24,
@@ -53,6 +53,8 @@
53
53
  "AMM": 121,
54
54
  "DID": 73,
55
55
  "Oracle": 128,
56
+ "MPTokenIssuance": 126,
57
+ "MPToken": 127,
56
58
  "Any": -3,
57
59
  "Child": -2,
58
60
  "Nickname": 110,
@@ -260,6 +262,16 @@
260
262
  "type": "UInt8"
261
263
  }
262
264
  ],
265
+ [
266
+ "AssetScale",
267
+ {
268
+ "nth": 20,
269
+ "isVLEncoded": false,
270
+ "isSerialized": true,
271
+ "isSigningField": true,
272
+ "type": "UInt8"
273
+ }
274
+ ],
263
275
  [
264
276
  "LedgerEntryType",
265
277
  {
@@ -370,6 +382,16 @@
370
382
  "type": "UInt16"
371
383
  }
372
384
  ],
385
+ [
386
+ "LedgerFixType",
387
+ {
388
+ "nth": 21,
389
+ "isVLEncoded": false,
390
+ "isSerialized": true,
391
+ "isSigningField": true,
392
+ "type": "UInt16"
393
+ }
394
+ ],
373
395
  [
374
396
  "NetworkID",
375
397
  {
@@ -1070,6 +1092,46 @@
1070
1092
  "type": "UInt64"
1071
1093
  }
1072
1094
  ],
1095
+ [
1096
+ "MaximumAmount",
1097
+ {
1098
+ "nth": 24,
1099
+ "isVLEncoded": false,
1100
+ "isSerialized": true,
1101
+ "isSigningField": true,
1102
+ "type": "UInt64"
1103
+ }
1104
+ ],
1105
+ [
1106
+ "OutstandingAmount",
1107
+ {
1108
+ "nth": 25,
1109
+ "isVLEncoded": false,
1110
+ "isSerialized": true,
1111
+ "isSigningField": true,
1112
+ "type": "UInt64"
1113
+ }
1114
+ ],
1115
+ [
1116
+ "LockedAmount",
1117
+ {
1118
+ "nth": 26,
1119
+ "isVLEncoded": false,
1120
+ "isSerialized": true,
1121
+ "isSigningField": true,
1122
+ "type": "UInt64"
1123
+ }
1124
+ ],
1125
+ [
1126
+ "MPTAmount",
1127
+ {
1128
+ "nth": 27,
1129
+ "isVLEncoded": false,
1130
+ "isSerialized": true,
1131
+ "isSigningField": true,
1132
+ "type": "UInt64"
1133
+ }
1134
+ ],
1073
1135
  [
1074
1136
  "EmailHash",
1075
1137
  {
@@ -1120,6 +1182,16 @@
1120
1182
  "type": "Hash160"
1121
1183
  }
1122
1184
  ],
1185
+ [
1186
+ "MPTokenIssuanceID",
1187
+ {
1188
+ "nth": 1,
1189
+ "isVLEncoded": false,
1190
+ "isSerialized": true,
1191
+ "isSigningField": true,
1192
+ "type": "Hash192"
1193
+ }
1194
+ ],
1123
1195
  [
1124
1196
  "LedgerHash",
1125
1197
  {
@@ -1980,6 +2052,16 @@
1980
2052
  "type": "Blob"
1981
2053
  }
1982
2054
  ],
2055
+ [
2056
+ "MPTokenMetadata",
2057
+ {
2058
+ "nth": 30,
2059
+ "isVLEncoded": true,
2060
+ "isSerialized": true,
2061
+ "isSigningField": true,
2062
+ "type": "Blob"
2063
+ }
2064
+ ],
1983
2065
  [
1984
2066
  "Account",
1985
2067
  {
@@ -2070,6 +2152,16 @@
2070
2152
  "type": "AccountID"
2071
2153
  }
2072
2154
  ],
2155
+ [
2156
+ "MPTokenHolder",
2157
+ {
2158
+ "nth": 11,
2159
+ "isVLEncoded": true,
2160
+ "isSerialized": true,
2161
+ "isSigningField": true,
2162
+ "type": "AccountID"
2163
+ }
2164
+ ],
2073
2165
  [
2074
2166
  "HookAccount",
2075
2167
  {
@@ -2797,16 +2889,17 @@
2797
2889
  "temUNKNOWN": -264,
2798
2890
  "temSEQ_AND_TICKET": -263,
2799
2891
  "temBAD_NFTOKEN_TRANSFER_FEE": -262,
2800
- "temBAD_AMM_TOKENS": -261,
2801
- "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -260,
2802
- "temXCHAIN_BAD_PROOF": -259,
2803
- "temXCHAIN_BRIDGE_BAD_ISSUES": -258,
2804
- "temXCHAIN_BRIDGE_NONDOOR_OWNER": -257,
2805
- "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -256,
2806
- "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -255,
2807
- "temEMPTY_DID": -254,
2808
- "temARRAY_EMPTY": -253,
2809
- "temARRAY_TOO_LARGE": -252,
2892
+ "temBAD_MPTOKEN_TRANSFER_FEE": -261,
2893
+ "temBAD_AMM_TOKENS": -260,
2894
+ "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -259,
2895
+ "temXCHAIN_BAD_PROOF": -258,
2896
+ "temXCHAIN_BRIDGE_BAD_ISSUES": -257,
2897
+ "temXCHAIN_BRIDGE_NONDOOR_OWNER": -256,
2898
+ "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -255,
2899
+ "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -254,
2900
+ "temEMPTY_DID": -253,
2901
+ "temARRAY_EMPTY": -252,
2902
+ "temARRAY_TOO_LARGE": -251,
2810
2903
  "tefFAILURE": -199,
2811
2904
  "tefALREADY": -198,
2812
2905
  "tefBAD_ADD_AUTH": -197,
@@ -2828,6 +2921,7 @@
2828
2921
  "tefTOO_BIG": -181,
2829
2922
  "tefNO_TICKET": -180,
2830
2923
  "tefNFTOKEN_IS_NOT_TRANSFERABLE": -179,
2924
+ "tefINVALID_LEDGER_FIX_TYPE": -178,
2831
2925
  "terRETRY": -99,
2832
2926
  "terFUNDS_SPENT": -98,
2833
2927
  "terINSUF_FEE_B": -97,
@@ -2918,7 +3012,11 @@
2918
3012
  "tecINVALID_UPDATE_TIME": 188,
2919
3013
  "tecTOKEN_PAIR_NOT_FOUND": 189,
2920
3014
  "tecARRAY_EMPTY": 190,
2921
- "tecARRAY_TOO_LARGE": 191
3015
+ "tecARRAY_TOO_LARGE": 191,
3016
+ "tecMPTOKEN_EXISTS": 192,
3017
+ "tecMPT_MAX_AMOUNT_EXCEEDED": 193,
3018
+ "tecMPT_LOCKED": 194,
3019
+ "tecMPT_NOT_SUPPORTED": 195
2922
3020
  },
2923
3021
  "TRANSACTION_TYPES": {
2924
3022
  "Invalid": -1,
@@ -2969,6 +3067,11 @@
2969
3067
  "DIDDelete": 50,
2970
3068
  "OracleSet": 51,
2971
3069
  "OracleDelete": 52,
3070
+ "LedgerStateFix": 53,
3071
+ "MPTokenIssuanceCreate": 54,
3072
+ "MPTokenIssuanceDestroy": 55,
3073
+ "MPTokenAuthorize": 56,
3074
+ "MPTokenIssuanceSet": 57,
2972
3075
  "EnableAmendment": 100,
2973
3076
  "SetFee": 101,
2974
3077
  "UNLModify": 102
@@ -18,7 +18,7 @@
18
18
  "PathSet": 18,
19
19
  "Vector256": 19,
20
20
  "UInt96": 20,
21
- "UInt192": 21,
21
+ "Hash192": 21,
22
22
  "UInt384": 22,
23
23
  "UInt512": 23,
24
24
  "Issue": 24,
@@ -53,6 +53,8 @@
53
53
  "AMM": 121,
54
54
  "DID": 73,
55
55
  "Oracle": 128,
56
+ "MPTokenIssuance": 126,
57
+ "MPToken": 127,
56
58
  "Any": -3,
57
59
  "Child": -2,
58
60
  "Nickname": 110,
@@ -260,6 +262,16 @@
260
262
  "type": "UInt8"
261
263
  }
262
264
  ],
265
+ [
266
+ "AssetScale",
267
+ {
268
+ "nth": 20,
269
+ "isVLEncoded": false,
270
+ "isSerialized": true,
271
+ "isSigningField": true,
272
+ "type": "UInt8"
273
+ }
274
+ ],
263
275
  [
264
276
  "LedgerEntryType",
265
277
  {
@@ -370,6 +382,16 @@
370
382
  "type": "UInt16"
371
383
  }
372
384
  ],
385
+ [
386
+ "LedgerFixType",
387
+ {
388
+ "nth": 21,
389
+ "isVLEncoded": false,
390
+ "isSerialized": true,
391
+ "isSigningField": true,
392
+ "type": "UInt16"
393
+ }
394
+ ],
373
395
  [
374
396
  "NetworkID",
375
397
  {
@@ -1070,6 +1092,46 @@
1070
1092
  "type": "UInt64"
1071
1093
  }
1072
1094
  ],
1095
+ [
1096
+ "MaximumAmount",
1097
+ {
1098
+ "nth": 24,
1099
+ "isVLEncoded": false,
1100
+ "isSerialized": true,
1101
+ "isSigningField": true,
1102
+ "type": "UInt64"
1103
+ }
1104
+ ],
1105
+ [
1106
+ "OutstandingAmount",
1107
+ {
1108
+ "nth": 25,
1109
+ "isVLEncoded": false,
1110
+ "isSerialized": true,
1111
+ "isSigningField": true,
1112
+ "type": "UInt64"
1113
+ }
1114
+ ],
1115
+ [
1116
+ "LockedAmount",
1117
+ {
1118
+ "nth": 26,
1119
+ "isVLEncoded": false,
1120
+ "isSerialized": true,
1121
+ "isSigningField": true,
1122
+ "type": "UInt64"
1123
+ }
1124
+ ],
1125
+ [
1126
+ "MPTAmount",
1127
+ {
1128
+ "nth": 27,
1129
+ "isVLEncoded": false,
1130
+ "isSerialized": true,
1131
+ "isSigningField": true,
1132
+ "type": "UInt64"
1133
+ }
1134
+ ],
1073
1135
  [
1074
1136
  "EmailHash",
1075
1137
  {
@@ -1120,6 +1182,16 @@
1120
1182
  "type": "Hash160"
1121
1183
  }
1122
1184
  ],
1185
+ [
1186
+ "MPTokenIssuanceID",
1187
+ {
1188
+ "nth": 1,
1189
+ "isVLEncoded": false,
1190
+ "isSerialized": true,
1191
+ "isSigningField": true,
1192
+ "type": "Hash192"
1193
+ }
1194
+ ],
1123
1195
  [
1124
1196
  "LedgerHash",
1125
1197
  {
@@ -1980,6 +2052,16 @@
1980
2052
  "type": "Blob"
1981
2053
  }
1982
2054
  ],
2055
+ [
2056
+ "MPTokenMetadata",
2057
+ {
2058
+ "nth": 30,
2059
+ "isVLEncoded": true,
2060
+ "isSerialized": true,
2061
+ "isSigningField": true,
2062
+ "type": "Blob"
2063
+ }
2064
+ ],
1983
2065
  [
1984
2066
  "Account",
1985
2067
  {
@@ -2070,6 +2152,16 @@
2070
2152
  "type": "AccountID"
2071
2153
  }
2072
2154
  ],
2155
+ [
2156
+ "MPTokenHolder",
2157
+ {
2158
+ "nth": 11,
2159
+ "isVLEncoded": true,
2160
+ "isSerialized": true,
2161
+ "isSigningField": true,
2162
+ "type": "AccountID"
2163
+ }
2164
+ ],
2073
2165
  [
2074
2166
  "HookAccount",
2075
2167
  {
@@ -2798,16 +2890,17 @@
2798
2890
  "temUNKNOWN": -264,
2799
2891
  "temSEQ_AND_TICKET": -263,
2800
2892
  "temBAD_NFTOKEN_TRANSFER_FEE": -262,
2801
- "temBAD_AMM_TOKENS": -261,
2802
- "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -260,
2803
- "temXCHAIN_BAD_PROOF": -259,
2804
- "temXCHAIN_BRIDGE_BAD_ISSUES": -258,
2805
- "temXCHAIN_BRIDGE_NONDOOR_OWNER": -257,
2806
- "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -256,
2807
- "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -255,
2808
- "temEMPTY_DID": -254,
2809
- "temARRAY_EMPTY": -253,
2810
- "temARRAY_TOO_LARGE": -252,
2893
+ "temBAD_MPTOKEN_TRANSFER_FEE": -261,
2894
+ "temBAD_AMM_TOKENS": -260,
2895
+ "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -259,
2896
+ "temXCHAIN_BAD_PROOF": -258,
2897
+ "temXCHAIN_BRIDGE_BAD_ISSUES": -257,
2898
+ "temXCHAIN_BRIDGE_NONDOOR_OWNER": -256,
2899
+ "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -255,
2900
+ "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -254,
2901
+ "temEMPTY_DID": -253,
2902
+ "temARRAY_EMPTY": -252,
2903
+ "temARRAY_TOO_LARGE": -251,
2811
2904
 
2812
2905
  "tefFAILURE": -199,
2813
2906
  "tefALREADY": -198,
@@ -2830,6 +2923,7 @@
2830
2923
  "tefTOO_BIG": -181,
2831
2924
  "tefNO_TICKET": -180,
2832
2925
  "tefNFTOKEN_IS_NOT_TRANSFERABLE": -179,
2926
+ "tefINVALID_LEDGER_FIX_TYPE": -178,
2833
2927
 
2834
2928
  "terRETRY": -99,
2835
2929
  "terFUNDS_SPENT": -98,
@@ -2923,7 +3017,11 @@
2923
3017
  "tecINVALID_UPDATE_TIME": 188,
2924
3018
  "tecTOKEN_PAIR_NOT_FOUND": 189,
2925
3019
  "tecARRAY_EMPTY": 190,
2926
- "tecARRAY_TOO_LARGE": 191
3020
+ "tecARRAY_TOO_LARGE": 191,
3021
+ "tecMPTOKEN_EXISTS": 192,
3022
+ "tecMPT_MAX_AMOUNT_EXCEEDED": 193,
3023
+ "tecMPT_LOCKED": 194,
3024
+ "tecMPT_NOT_SUPPORTED": 195
2927
3025
  },
2928
3026
  "TRANSACTION_TYPES": {
2929
3027
  "Invalid": -1,
@@ -2974,6 +3072,11 @@
2974
3072
  "DIDDelete": 50,
2975
3073
  "OracleSet": 51,
2976
3074
  "OracleDelete": 52,
3075
+ "LedgerStateFix": 53,
3076
+ "MPTokenIssuanceCreate": 54,
3077
+ "MPTokenIssuanceDestroy": 55,
3078
+ "MPTokenAuthorize": 56,
3079
+ "MPTokenIssuanceSet": 57,
2977
3080
  "EnableAmendment": 100,
2978
3081
  "SetFee": 101,
2979
3082
  "UNLModify": 102
@@ -18,7 +18,7 @@
18
18
  "PathSet": 18,
19
19
  "Vector256": 19,
20
20
  "UInt96": 20,
21
- "UInt192": 21,
21
+ "Hash192": 21,
22
22
  "UInt384": 22,
23
23
  "UInt512": 23,
24
24
  "Issue": 24,
@@ -53,6 +53,8 @@
53
53
  "AMM": 121,
54
54
  "DID": 73,
55
55
  "Oracle": 128,
56
+ "MPTokenIssuance": 126,
57
+ "MPToken": 127,
56
58
  "Any": -3,
57
59
  "Child": -2,
58
60
  "Nickname": 110,
@@ -260,6 +262,16 @@
260
262
  "type": "UInt8"
261
263
  }
262
264
  ],
265
+ [
266
+ "AssetScale",
267
+ {
268
+ "nth": 20,
269
+ "isVLEncoded": false,
270
+ "isSerialized": true,
271
+ "isSigningField": true,
272
+ "type": "UInt8"
273
+ }
274
+ ],
263
275
  [
264
276
  "LedgerEntryType",
265
277
  {
@@ -370,6 +382,16 @@
370
382
  "type": "UInt16"
371
383
  }
372
384
  ],
385
+ [
386
+ "LedgerFixType",
387
+ {
388
+ "nth": 21,
389
+ "isVLEncoded": false,
390
+ "isSerialized": true,
391
+ "isSigningField": true,
392
+ "type": "UInt16"
393
+ }
394
+ ],
373
395
  [
374
396
  "NetworkID",
375
397
  {
@@ -1070,6 +1092,46 @@
1070
1092
  "type": "UInt64"
1071
1093
  }
1072
1094
  ],
1095
+ [
1096
+ "MaximumAmount",
1097
+ {
1098
+ "nth": 24,
1099
+ "isVLEncoded": false,
1100
+ "isSerialized": true,
1101
+ "isSigningField": true,
1102
+ "type": "UInt64"
1103
+ }
1104
+ ],
1105
+ [
1106
+ "OutstandingAmount",
1107
+ {
1108
+ "nth": 25,
1109
+ "isVLEncoded": false,
1110
+ "isSerialized": true,
1111
+ "isSigningField": true,
1112
+ "type": "UInt64"
1113
+ }
1114
+ ],
1115
+ [
1116
+ "LockedAmount",
1117
+ {
1118
+ "nth": 26,
1119
+ "isVLEncoded": false,
1120
+ "isSerialized": true,
1121
+ "isSigningField": true,
1122
+ "type": "UInt64"
1123
+ }
1124
+ ],
1125
+ [
1126
+ "MPTAmount",
1127
+ {
1128
+ "nth": 27,
1129
+ "isVLEncoded": false,
1130
+ "isSerialized": true,
1131
+ "isSigningField": true,
1132
+ "type": "UInt64"
1133
+ }
1134
+ ],
1073
1135
  [
1074
1136
  "EmailHash",
1075
1137
  {
@@ -1120,6 +1182,16 @@
1120
1182
  "type": "Hash160"
1121
1183
  }
1122
1184
  ],
1185
+ [
1186
+ "MPTokenIssuanceID",
1187
+ {
1188
+ "nth": 1,
1189
+ "isVLEncoded": false,
1190
+ "isSerialized": true,
1191
+ "isSigningField": true,
1192
+ "type": "Hash192"
1193
+ }
1194
+ ],
1123
1195
  [
1124
1196
  "LedgerHash",
1125
1197
  {
@@ -1980,6 +2052,16 @@
1980
2052
  "type": "Blob"
1981
2053
  }
1982
2054
  ],
2055
+ [
2056
+ "MPTokenMetadata",
2057
+ {
2058
+ "nth": 30,
2059
+ "isVLEncoded": true,
2060
+ "isSerialized": true,
2061
+ "isSigningField": true,
2062
+ "type": "Blob"
2063
+ }
2064
+ ],
1983
2065
  [
1984
2066
  "Account",
1985
2067
  {
@@ -2070,6 +2152,16 @@
2070
2152
  "type": "AccountID"
2071
2153
  }
2072
2154
  ],
2155
+ [
2156
+ "MPTokenHolder",
2157
+ {
2158
+ "nth": 11,
2159
+ "isVLEncoded": true,
2160
+ "isSerialized": true,
2161
+ "isSigningField": true,
2162
+ "type": "AccountID"
2163
+ }
2164
+ ],
2073
2165
  [
2074
2166
  "HookAccount",
2075
2167
  {
@@ -2797,16 +2889,17 @@
2797
2889
  "temUNKNOWN": -264,
2798
2890
  "temSEQ_AND_TICKET": -263,
2799
2891
  "temBAD_NFTOKEN_TRANSFER_FEE": -262,
2800
- "temBAD_AMM_TOKENS": -261,
2801
- "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -260,
2802
- "temXCHAIN_BAD_PROOF": -259,
2803
- "temXCHAIN_BRIDGE_BAD_ISSUES": -258,
2804
- "temXCHAIN_BRIDGE_NONDOOR_OWNER": -257,
2805
- "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -256,
2806
- "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -255,
2807
- "temEMPTY_DID": -254,
2808
- "temARRAY_EMPTY": -253,
2809
- "temARRAY_TOO_LARGE": -252,
2892
+ "temBAD_MPTOKEN_TRANSFER_FEE": -261,
2893
+ "temBAD_AMM_TOKENS": -260,
2894
+ "temXCHAIN_EQUAL_DOOR_ACCOUNTS": -259,
2895
+ "temXCHAIN_BAD_PROOF": -258,
2896
+ "temXCHAIN_BRIDGE_BAD_ISSUES": -257,
2897
+ "temXCHAIN_BRIDGE_NONDOOR_OWNER": -256,
2898
+ "temXCHAIN_BRIDGE_BAD_MIN_ACCOUNT_CREATE_AMOUNT": -255,
2899
+ "temXCHAIN_BRIDGE_BAD_REWARD_AMOUNT": -254,
2900
+ "temEMPTY_DID": -253,
2901
+ "temARRAY_EMPTY": -252,
2902
+ "temARRAY_TOO_LARGE": -251,
2810
2903
  "tefFAILURE": -199,
2811
2904
  "tefALREADY": -198,
2812
2905
  "tefBAD_ADD_AUTH": -197,
@@ -2828,6 +2921,7 @@
2828
2921
  "tefTOO_BIG": -181,
2829
2922
  "tefNO_TICKET": -180,
2830
2923
  "tefNFTOKEN_IS_NOT_TRANSFERABLE": -179,
2924
+ "tefINVALID_LEDGER_FIX_TYPE": -178,
2831
2925
  "terRETRY": -99,
2832
2926
  "terFUNDS_SPENT": -98,
2833
2927
  "terINSUF_FEE_B": -97,
@@ -2918,7 +3012,11 @@
2918
3012
  "tecINVALID_UPDATE_TIME": 188,
2919
3013
  "tecTOKEN_PAIR_NOT_FOUND": 189,
2920
3014
  "tecARRAY_EMPTY": 190,
2921
- "tecARRAY_TOO_LARGE": 191
3015
+ "tecARRAY_TOO_LARGE": 191,
3016
+ "tecMPTOKEN_EXISTS": 192,
3017
+ "tecMPT_MAX_AMOUNT_EXCEEDED": 193,
3018
+ "tecMPT_LOCKED": 194,
3019
+ "tecMPT_NOT_SUPPORTED": 195
2922
3020
  },
2923
3021
  "TRANSACTION_TYPES": {
2924
3022
  "Invalid": -1,
@@ -2969,6 +3067,11 @@
2969
3067
  "DIDDelete": 50,
2970
3068
  "OracleSet": 51,
2971
3069
  "OracleDelete": 52,
3070
+ "LedgerStateFix": 53,
3071
+ "MPTokenIssuanceCreate": 54,
3072
+ "MPTokenIssuanceDestroy": 55,
3073
+ "MPTokenAuthorize": 56,
3074
+ "MPTokenIssuanceSet": 57,
2972
3075
  "EnableAmendment": 100,
2973
3076
  "SetFee": 101,
2974
3077
  "UNLModify": 102
@@ -1,13 +1,18 @@
1
1
  import { BinaryParser } from '../serdes/binary-parser';
2
2
  import { JsonObject, SerializedType } from './serialized-type';
3
- /**
4
- * Interface for JSON objects that represent amounts
5
- */
6
- interface AmountObject extends JsonObject {
3
+ interface AmountObjectIOU extends JsonObject {
7
4
  value: string;
8
5
  currency: string;
9
6
  issuer: string;
10
7
  }
8
+ interface AmountObjectMPT extends JsonObject {
9
+ value: string;
10
+ mpt_issuance_id: string;
11
+ }
12
+ /**
13
+ * Interface for JSON objects that represent amounts
14
+ */
15
+ type AmountObject = AmountObjectIOU | AmountObjectMPT;
11
16
  /**
12
17
  * Class for serializing/Deserializing Amounts
13
18
  */
@@ -15,7 +20,7 @@ declare class Amount extends SerializedType {
15
20
  static defaultAmount: Amount;
16
21
  constructor(bytes: Uint8Array);
17
22
  /**
18
- * Construct an amount from an IOU or string amount
23
+ * Construct an amount from an IOU, MPT or string amount
19
24
  *
20
25
  * @param value An Amount, object representing an IOU, or a string
21
26
  * representing an integer amount
@@ -49,6 +54,13 @@ declare class Amount extends SerializedType {
49
54
  * @returns void, but will throw if invalid amount
50
55
  */
51
56
  private static assertIouIsValid;
57
+ /**
58
+ * Validate MPT.value amount
59
+ *
60
+ * @param decimal BigNumber object representing MPT.value
61
+ * @returns void, but will throw if invalid amount
62
+ */
63
+ private static assertMptIsValid;
52
64
  /**
53
65
  * Ensure that the value after being multiplied by the exponent does not
54
66
  * contain a decimal.
@@ -63,5 +75,17 @@ declare class Amount extends SerializedType {
63
75
  * @returns true if Native (XRP)
64
76
  */
65
77
  private isNative;
78
+ /**
79
+ * Test if this amount is in units of MPT
80
+ *
81
+ * @returns true if MPT
82
+ */
83
+ private isMPT;
84
+ /**
85
+ * Test if this amount is in units of IOU
86
+ *
87
+ * @returns true if IOU
88
+ */
89
+ private isIOU;
66
90
  }
67
91
  export { Amount, AmountObject };