-
Notifications
You must be signed in to change notification settings - Fork 518
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add support for XLS-40d + add script to auto-generate models fr…
…om rippled code (#2491) Add support for XLS-40 and adds a script to automatically generate transaction models from rippled source code. ### Context of Change XRPLF/XRPL-Standards#136 XRPLF/rippled#4636
- Loading branch information
Showing
17 changed files
with
701 additions
and
46 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -167,5 +167,6 @@ AMM | |
Clawback | ||
fixReducedOffersV1 | ||
fixNFTokenRemint | ||
# 2.0.0-b1 Amendments | ||
# 2.0.0 Amendments | ||
XChainBridge | ||
DID |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { BaseTransaction, validateBaseTransaction } from './common' | ||
|
||
// TODO: add docs | ||
|
||
/** | ||
* @category Transaction Models | ||
*/ | ||
export interface DIDDelete extends BaseTransaction { | ||
TransactionType: 'DIDDelete' | ||
} | ||
|
||
/** | ||
* Verify the form and type of a DIDDelete at runtime. | ||
* | ||
* @param tx - A DIDDelete Transaction. | ||
* @throws When the DIDDelete is malformed. | ||
*/ | ||
export function validateDIDDelete(tx: Record<string, unknown>): void { | ||
validateBaseTransaction(tx) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
import { | ||
BaseTransaction, | ||
isString, | ||
validateBaseTransaction, | ||
validateOptionalField, | ||
} from './common' | ||
|
||
// TODO: add docs | ||
|
||
/** | ||
* @category Transaction Models | ||
*/ | ||
export interface DIDSet extends BaseTransaction { | ||
TransactionType: 'DIDSet' | ||
|
||
Data?: string | ||
|
||
DIDDocument?: string | ||
|
||
URI?: string | ||
} | ||
|
||
/** | ||
* Verify the form and type of a DIDSet at runtime. | ||
* | ||
* @param tx - A DIDSet Transaction. | ||
* @throws When the DIDSet is malformed. | ||
*/ | ||
export function validateDIDSet(tx: Record<string, unknown>): void { | ||
validateBaseTransaction(tx) | ||
|
||
validateOptionalField(tx, 'Data', isString) | ||
|
||
validateOptionalField(tx, 'DIDDocument', isString) | ||
|
||
validateOptionalField(tx, 'URI', isString) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.