Class DefaultTreeMasterDetailCache
- java.lang.Object
-
- org.eclipse.emfforms.spi.swt.treemasterdetail.DefaultTreeMasterDetailCache
-
- All Implemented Interfaces:
DetailViewCache
,TreeMasterDetailCache
@Deprecated public class DefaultTreeMasterDetailCache extends java.lang.Object implements TreeMasterDetailCache
Deprecated.Since 1.22, use theBasicDetailViewCache
API, instead.A default implementation of the TreeMasterDetailCache which uses the EClass as the key.- Since:
- 1.9
- Author:
- Eugen Neufeld
-
-
Field Summary
-
Fields inherited from interface org.eclipse.emf.ecp.view.spi.swt.masterdetail.DetailViewCache
DETAIL_VIEW_CACHE_SIZE, EMPTY
-
-
Constructor Summary
Constructors Constructor Description DefaultTreeMasterDetailCache()
Deprecated.Creates a cache with maximal 5 entries.DefaultTreeMasterDetailCache(int maxEntries)
Deprecated.Creates a cache with a custom number of maximal entries.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description void
cache(ECPSWTView ecpView)
Deprecated.Caches the providedECPSWTView
to allow it to be reused later.void
clear()
Deprecated.Dispose all cached views, emptying the cache.ECPSWTView
getCachedView(org.eclipse.emf.ecore.EObject selection)
Deprecated.Returns the previously cached view for the provided selection.boolean
isChached(org.eclipse.emf.ecore.EObject selection)
Deprecated.Checks whether there is already a cached view available.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.eclipse.emfforms.spi.swt.treemasterdetail.TreeMasterDetailCache
cacheView, isCached
-
-
-
-
Constructor Detail
-
DefaultTreeMasterDetailCache
public DefaultTreeMasterDetailCache()
Deprecated.Creates a cache with maximal 5 entries.
-
DefaultTreeMasterDetailCache
public DefaultTreeMasterDetailCache(int maxEntries)
Deprecated.Creates a cache with a custom number of maximal entries.- Parameters:
maxEntries
- The number of maximal entries to cache
-
-
Method Detail
-
isChached
public boolean isChached(org.eclipse.emf.ecore.EObject selection)
Deprecated.Description copied from interface:TreeMasterDetailCache
Checks whether there is already a cached view available.- Specified by:
isChached
in interfaceTreeMasterDetailCache
- Parameters:
selection
- The new selection of the tree- Returns:
- true if there is a cached view for the provided selection, false otherwise
-
getCachedView
public ECPSWTView getCachedView(org.eclipse.emf.ecore.EObject selection)
Deprecated.Description copied from interface:TreeMasterDetailCache
Returns the previously cached view for the provided selection.- Specified by:
getCachedView
in interfaceDetailViewCache
- Specified by:
getCachedView
in interfaceTreeMasterDetailCache
- Parameters:
selection
- The new selection of the tree- Returns:
- The cached view
- See Also:
DetailViewCache.isCached(EObject)
-
cache
public void cache(ECPSWTView ecpView)
Deprecated.Description copied from interface:TreeMasterDetailCache
Caches the providedECPSWTView
to allow it to be reused later.- Specified by:
cache
in interfaceTreeMasterDetailCache
- Parameters:
ecpView
- TheECPSWTView
to cache.
-
clear
public void clear()
Deprecated.Description copied from interface:DetailViewCache
Dispose all cached views, emptying the cache. The cache must still be in a state to be used (this is not a "dispose" operation).- Specified by:
clear
in interfaceDetailViewCache
-
-