Mutation API
Methods for locally mutating the token tree.
You access each of the mutation methods over:
sdtfEngine.mutation.[method]addToken
Add a new token to the token tree.
function addToken(param:{
parentPath: Array<string>,
name: string,
tokenProperties: {
$type: string;
$value: unknown;
$description?: string;
$extensions?: Record<string, unknown>;
},
}): void;renameToken
Rename a token.
function renameToken(param: { atPath: Array<string>; name: string }): void;updateTokenDescription
Update the description of a token.
updateTokenExtensions
Update the extensions of a token.
updateTokenValue
Update the value of a token.
updateTokenModeValue
Update the value of a token for a given mode.
renameTokenMode
Rename a token mode.
createTokenModeValue
Create a new token mode value.
deleteTokenModeValue
Delete a token mode value.
deleteToken
Delete a token.
moveToken
Move a token.
addCollection
Add a new collection to the token tree.
renameCollection
Rename a collection.
updateCollectionDescription
Update the description of a collection.
updateCollectionExtensions
Update the extensions of a collection.
renameCollectionMode
Rename a collection mode.
truncateCollection
Truncate a collection.
deleteCollection
Delete a collection.
deleteCollectionMode
Delete a collection mode.
moveCollection
Move a collection.
addGroup
Add a new group to the token tree.
renameGroup
Rename a group.
updateGroupDescription
Update the description of a group.
updateGroupExtensions
Update the extensions of a group.
truncateGroup
Truncate a group.
deleteGroup
Delete a group.
moveGroup
Move a group.
Last updated