BriefcaseTxns Class
Manages local changes to a BriefcaseConnection via Txns.
see BriefcaseConnection.txns.
see TxnManager for the backend counterpart.
Extends
Implements
- TxnNotifications
Methods
Name | Description | |
---|---|---|
getRedoString(): Promise<string> | Get a description of the operation that would be reinstated by calling BriefcaseTxns.reinstateTxn. | |
getUndoString(): Promise<string> | Get the description of the operation that would be reversed by calling BriefcaseTxns.reverseTxns(1) . |
|
hasPendingTxns(): Promise<boolean> | Query if the briefcase has any pending Txns waiting to be pushed. | |
isRedoPossible(): Promise<boolean> | Determine if any reinstatable (redoable) changes exist. | |
isUndoPossible(): Promise<boolean> | Determine if any reversible (undoable) changes exist. | |
reinstateTxn(): Promise<IModelStatus> | Reinstate (redo) the most recently reversed transaction. | |
restartTxnSession(): Promise<void> | Restart the current TxnManager session. | |
reverseAll(): Promise<IModelStatus> | Reverse (undo) all changes back to the beginning of the session. | |
reverseSingleTxn(): Promise<IModelStatus> | Reverse (undo) the most recent operation. | |
reverseTxns(numOperations: number): Promise<IModelStatus> | Reverse (undo) the most recent operation(s) to the briefcase in the current session. |
Inherited methods
Name | Inherited from | Description |
---|---|---|
registerImpl(): RemoveFunction | BriefcaseNotificationHandler | |
register(): RemoveFunction Static | BriefcaseNotificationHandler | Register this class as the handler for notifications on its channel. |
Properties
Name | Type | Description | |
---|---|---|---|
onAfterUndoRedo Readonly | BeEvent<(isUndo: boolean) => void> | Event raised after an undo/redo operation is performed. | |
onBeforeUndoRedo Readonly | BeEvent<(isUndo: boolean) => void> | Event raised before an undo/redo operation is performed. | |
onChangesApplied Readonly | BeEvent<() => void> | Event raised after a changeset has been applied to the briefcase. | |
onChangesPulled Readonly | BeEvent<(parentChangeset: ChangesetIndexAndId) => void> | Event raised after changes are pulled and merged into the briefcase. | |
onChangesPushed Readonly | BeEvent<(parentChangeset: ChangesetIndexAndId) => void> | Event raised after the briefcase's local changes are pushed. | |
onCommit Readonly | BeEvent<() => void> | Event raised before a commit operation is performed. | |
onCommitted Readonly | BeEvent<(hasPendingTxns: boolean, time: number) => void> | Event raised after a commit operation is performed. | |
onElementsChanged Readonly | BeEvent<(changes: Readonly<ChangedEntities>) => void> | Event raised after Txn validation or changeset application to indicate the set of changed elements. | |
onModelGeometryChanged Readonly | BeEvent<(changes: undefined) => void> | Event raised after the geometry within one or more GeometricModelStates is modified by applying a changeset or validation of a transaction. | |
onModelsChanged Readonly | BeEvent<(changes: Readonly<ChangedEntities>) => void> | Event raised after Txn validation or changeset application to indicate the set of changed models. |
Inherited properties
Name | Type | Inherited from | Description |
---|---|---|---|
channelName Accessor ReadOnly | string | BriefcaseNotificationHandler |
Defined in
Last Updated: 30 November, 2023