public final class WorkspaceTransactionUtil
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledRunnable runnable)
Executes given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledRunnable runnable,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions)
Execute given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledWorkspaceRunnable runnable,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions,
org.eclipse.core.runtime.IProgressMonitor monitor)
Execute given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledWorkspaceRunnable runnable,
org.eclipse.core.runtime.IProgressMonitor monitor)
Executes given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel)
Executes given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions)
Execute given runnable in a write transaction.
|
static void |
executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions,
org.eclipse.core.runtime.IProgressMonitor monitor)
|
static java.util.Map<java.lang.String,java.lang.Object> |
getDefaultSaveNewTransactionOptions()
Returns a default set of options which can be used for executing an operation saving a new model within a write
transaction.
|
static java.util.Map<java.lang.String,java.lang.Object> |
getDefaultSaveTransactionOptions()
Returns a default set of options which can be used for executing an operation saving an existing model within a
write transaction.
|
static java.util.Map<java.lang.String,java.lang.Object> |
getDefaultTransactionOptions()
Returns a default set of options which can be used for executing an operation within a transaction.
|
static org.eclipse.core.commands.operations.IOperationHistory |
getOperationHistory(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain)
Returns the IOperationHistory for the given EditingDomain.
|
static org.eclipse.core.commands.operations.IUndoContext |
getUndoContext(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain)
Returns the IUndoContext for the given EditingDomain.
|
public static org.eclipse.core.commands.operations.IOperationHistory getOperationHistory(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain)
editingDomain - The EditingDomain for which the IOperationHistory is to be retrieved.edingDomain.public static org.eclipse.core.commands.operations.IUndoContext getUndoContext(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain)
editingDomain - The EditingDomain for which the IUndoContext is to be retrieved.edingDomain.public static java.util.Map<java.lang.String,java.lang.Object> getDefaultTransactionOptions()
public static java.util.Map<java.lang.String,java.lang.Object> getDefaultSaveNewTransactionOptions()
public static java.util.Map<java.lang.String,java.lang.Object> getDefaultSaveTransactionOptions()
public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.operationLabel - The label of the operation to be executed.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is cancelled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.operationLabel - The label of the operation to be executed.operationHistory - The operation history to store the executed operation.transactionOptions - The options to set the transaction.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is canceled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.@Deprecated
public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
java.lang.Runnable runnable,
java.lang.String operationLabel,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions,
org.eclipse.core.runtime.IProgressMonitor monitor)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
executeInWriteTransaction(TransactionalEditingDomain, Runnable, String, IOperationHistory, Map)
or
executeInWriteTransaction(TransactionalEditingDomain, ILabeledWorkspaceRunnable, IOperationHistory, Map, IProgressMonitor)
instead.editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.operationLabel - The label of the operation to be executed.operationHistory - The operation history to store the executed operation.transactionOptions - The options to set the transaction.monitor - The progress monitor to use during operation execution.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is canceled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledRunnable runnable)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is cancelled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledRunnable runnable,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.operationHistory - The operation history to store the executed operation.transactionOptions - The options to set the transaction.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is canceled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledWorkspaceRunnable runnable,
org.eclipse.core.runtime.IProgressMonitor monitor)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.monitor - The progress monitor to use during operation execution.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is cancelled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.public static void executeInWriteTransaction(org.eclipse.emf.transaction.TransactionalEditingDomain editingDomain,
ILabeledWorkspaceRunnable runnable,
org.eclipse.core.commands.operations.IOperationHistory operationHistory,
java.util.Map<java.lang.String,java.lang.Object> transactionOptions,
org.eclipse.core.runtime.IProgressMonitor monitor)
throws org.eclipse.core.runtime.OperationCanceledException,
org.eclipse.core.commands.ExecutionException
editingDomain - The editing domain receiving the transaction.runnable - The runnable to be executed.operationHistory - The operation history to store the executed operation.transactionOptions - The options to set the transaction.monitor - The progress monitor to use during operation execution.org.eclipse.core.runtime.OperationCanceledException - Thrown when the transaction is canceled by the user.org.eclipse.core.commands.ExecutionException - Thrown when the transaction could not be completed to an Exception.