Mutation API
Methods for locally mutating the token tree.
You access each of the mutation methods over:
sdtfEngine.mutation.[method]addToken
addTokenAdd 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
renameTokenRename a token.
function renameToken(param: { atPath: Array<string>; name: string }): void;updateTokenDescription
updateTokenDescriptionUpdate the description of a token.
updateTokenExtensions
updateTokenExtensionsUpdate the extensions of a token.
updateTokenValue
updateTokenValueUpdate the value of a token.
updateTokenModeValue
updateTokenModeValueUpdate the value of a token for a given mode.
renameTokenMode
renameTokenModeRename a token mode.
createTokenModeValue
createTokenModeValueCreate a new token mode value.
deleteTokenModeValue
deleteTokenModeValueDelete a token mode value.
deleteToken
deleteTokenDelete a token.
moveToken
moveTokenMove a token.
addCollection
addCollectionAdd a new collection to the token tree.
renameCollection
renameCollectionRename a collection.
updateCollectionDescription
updateCollectionDescriptionUpdate the description of a collection.
updateCollectionExtensions
updateCollectionExtensionsUpdate the extensions of a collection.
renameCollectionMode
renameCollectionModeRename a collection mode.
truncateCollection
truncateCollectionTruncate a collection.
deleteCollection
deleteCollectionDelete a collection.
deleteCollectionMode
deleteCollectionModeDelete a collection mode.
moveCollection
moveCollectionMove a collection.
addGroup
addGroupAdd a new group to the token tree.
renameGroup
renameGroupRename a group.
updateGroupDescription
updateGroupDescriptionUpdate the description of a group.
updateGroupExtensions
updateGroupExtensionsUpdate the extensions of a group.
truncateGroup
truncateGroupTruncate a group.
deleteGroup
deleteGroupDelete a group.
moveGroup
moveGroupMove a group.
Last updated
Was this helpful?