|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
org.eclipse.emf.transaction.ui.provider.TransactionalAdapterFactoryContentProvider
public class TransactionalAdapterFactoryContentProvider
Automatically wraps any potential access to model objects in read transactions.
Note that this is not necessary in the case of the
AdapterFactoryContentProvider.notifyChanged(Notification)
method because this will always be called in a transaction context.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider |
---|
org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider.ViewerRefresh |
Field Summary |
---|
Fields inherited from class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider |
---|
adapterFactory, viewer, viewerRefresh |
Constructor Summary | |
---|---|
TransactionalAdapterFactoryContentProvider(TransactionalEditingDomain domain,
org.eclipse.emf.common.notify.AdapterFactory adapterFactory)
Initializes me with the editing domain in which I create read transactions and that adapter factory that provides content providers. |
Method Summary | ||
---|---|---|
protected IPropertySource |
createPropertySource(Object object,
org.eclipse.emf.edit.provider.IItemPropertySource itemPropertySource)
Extends the inherited implementation by running in a read-only transaction. |
|
Object[] |
getChildren(Object object)
Extends the inherited implementation by running in a read-only transaction. |
|
Object[] |
getElements(Object object)
Extends the inherited implementation by running in a read-only transaction. |
|
Object |
getParent(Object object)
Extends the inherited implementation by running in a read-only transaction. |
|
IPropertySource |
getPropertySource(Object object)
Extends the inherited implementation by running in a read-only transaction. |
|
boolean |
hasChildren(Object object)
Extends the inherited implementation by running in a read-only transaction. |
|
void |
inputChanged(Viewer vwr,
Object oldInput,
Object newInput)
Extends the inherited implementation by running in a read-only transaction. |
|
protected
|
run(RunnableWithResult<? extends T> run)
Runs the specified runnable in the editing domain, with interrupt handling. |
|
protected IPropertySource |
wrap(IPropertySource propertySource)
Wraps a property source in a transactional property source. |
Methods inherited from class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider |
---|
dispose, getAdapterFactory, notifyChanged, setAdapterFactory |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TransactionalAdapterFactoryContentProvider(TransactionalEditingDomain domain, org.eclipse.emf.common.notify.AdapterFactory adapterFactory)
domain
- my editing domainadapterFactory
- the adapter factoryMethod Detail |
---|
protected <T> T run(RunnableWithResult<? extends T> run)
T
- the result type of the runnablerun
- the runnable to run
null
on interruptprotected IPropertySource createPropertySource(Object object, org.eclipse.emf.edit.provider.IItemPropertySource itemPropertySource)
createPropertySource
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public Object[] getChildren(Object object)
getChildren
in interface ITreeContentProvider
getChildren
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public Object[] getElements(Object object)
getElements
in interface IStructuredContentProvider
getElements
in interface ITreeContentProvider
getElements
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public Object getParent(Object object)
getParent
in interface ITreeContentProvider
getParent
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public IPropertySource getPropertySource(Object object)
getPropertySource
in interface IPropertySourceProvider
getPropertySource
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public boolean hasChildren(Object object)
hasChildren
in interface ITreeContentProvider
hasChildren
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
public void inputChanged(Viewer vwr, Object oldInput, Object newInput)
inputChanged
in interface IContentProvider
inputChanged
in class org.eclipse.emf.edit.ui.provider.AdapterFactoryContentProvider
protected IPropertySource wrap(IPropertySource propertySource)
propertySource
- the property source to wrap
|
Copyright 2002, 2007 IBM Corporation and others. All Rights Reserved. |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |