public final class CDOUtil extends Object
Modifier and Type | Field and Description |
---|---|
static String |
CDO_ANNOTATION_URI |
static String |
DOCUMENTATION_KEY |
Modifier and Type | Method and Description |
---|---|
static void |
cleanStaleReference(org.eclipse.emf.ecore.EObject eObject,
org.eclipse.emf.ecore.EStructuralFeature eFeature) |
static void |
cleanStaleReference(org.eclipse.emf.ecore.EObject eObject,
org.eclipse.emf.ecore.EStructuralFeature eFeature,
int index) |
static void |
configureView(CDOView view) |
static CDOCollectionLoadingPolicy |
createCollectionLoadingPolicy(int initialChunkSize,
int resolveChunkSize) |
static CDOFeatureAnalyzer |
createModelBasedFeatureAnalyzer() |
static CDORevisionPrefetchingPolicy |
createRevisionPrefetchingPolicy(int chunkSize) |
static CDOFetchRuleManager |
createThreadLocalFetchRuleManager() |
static CDOFeatureAnalyzer |
createUIFeatureAnalyzer() |
static CDOFeatureAnalyzer |
createUIFeatureAnalyzer(long maxTimeBetweenOperation) |
static CDOXATransaction |
createXATransaction(org.eclipse.emf.common.notify.Notifier... notifiers) |
static <T extends org.eclipse.emf.ecore.EObject> |
filterReadables(Collection<T> collection) |
static String |
getAnnotation(ModelElement modelElement,
String sourceURI,
String key) |
static CDOObject |
getCDOObject(org.eclipse.emf.ecore.EObject object) |
static CDOObject |
getCDOObject(org.eclipse.emf.ecore.EObject object,
boolean adaptLegacy) |
static String |
getDocumentation(ModelElement modelElement) |
static org.eclipse.emf.ecore.EObject |
getEObject(org.eclipse.emf.ecore.EObject object) |
static Map<String,org.eclipse.emf.ecore.EObject> |
getIntrinsicIDToEObjectMap(CDOResource resource)
Returns the map used to cache the EObject that is identified by the
value
of its ID feature. |
static CDOBranchPointRange |
getLifetime(CDOObject object) |
static org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.resource.Resource> |
getResources(org.eclipse.emf.ecore.resource.ResourceSet resourceSet) |
static CDORevision |
getRevisionByVersion(CDOObject object,
CDOBranch branch,
int version) |
static CDORevision |
getRevisionByVersion(CDOObject object,
int version) |
static CDOSession |
getSession(Object object) |
static CDOView |
getView(org.eclipse.emf.common.notify.Notifier notifier) |
static CDOView |
getView(org.eclipse.emf.ecore.resource.ResourceSet resourceSet,
org.eclipse.emf.common.util.URI uri) |
static CDOViewSet |
getViewSet(org.eclipse.emf.common.notify.Notifier notifier) |
static CDOXATransaction |
getXATransaction(CDOViewSet viewSet) |
static boolean |
isCDOObject(org.eclipse.emf.ecore.EObject object) |
static boolean |
isInvalidationRunnerActive()
Deprecated.
As of 4.0 use CDOView.isInvalidationRunnerActive()
|
static boolean |
isLegacyModeDefault()
Deprecated.
As of 4.2 the legacy mode is always enabled.
|
static boolean |
isLegacyObject(org.eclipse.emf.ecore.EObject object) |
static boolean |
isSessionDirty(CDOSession session)
|
static boolean |
isStaleObject(Object object) |
static boolean |
isWritableObject(org.eclipse.emf.ecore.EObject eObject)
Queries whether an object is writable (is permitted to be modified in the
current view context).
|
static void |
load(org.eclipse.emf.ecore.EObject eObject,
CDOView view) |
static boolean |
prepareDynamicEPackage(org.eclipse.emf.ecore.EPackage startPackage) |
static boolean |
registerResourceFactory(org.eclipse.emf.ecore.resource.Resource.Factory.Registry registry) |
static Annotation |
setAnnotation(ModelElement modelElement,
String sourceURI,
String key,
String value) |
static void |
setCredentialsProvider(org.eclipse.emf.common.util.URI uri,
IPasswordCredentialsProvider provider) |
static Annotation |
setDocumentation(ModelElement modelElement,
String value) |
static void |
setIntrinsicIDToEObjectMap(CDOResource resource,
Map<String,org.eclipse.emf.ecore.EObject> intrinsicIDToEObjectMap)
Sets the map used to cache the EObject identified by the value of its ID feature.
|
static void |
setLegacyModeDefault(boolean on)
Deprecated.
As of 4.2 the legacy mode is always enabled.
|
static CDOObject |
wrapExternalObject(org.eclipse.emf.ecore.EObject object,
CDOView view) |
public static final String CDO_ANNOTATION_URI
public static final String DOCUMENTATION_KEY
public static boolean registerResourceFactory(org.eclipse.emf.ecore.resource.Resource.Factory.Registry registry)
public static Map<String,org.eclipse.emf.ecore.EObject> getIntrinsicIDToEObjectMap(CDOResource resource)
value
of its ID feature.setIntrinsicIDToEObjectMap(org.eclipse.emf.cdo.eresource.CDOResource, java.util.Map<java.lang.String, org.eclipse.emf.ecore.EObject>)
public static void setIntrinsicIDToEObjectMap(CDOResource resource, Map<String,org.eclipse.emf.ecore.EObject> intrinsicIDToEObjectMap)
null
.
The map will be lazily loaded by the getEObjectByID
method.
It is up to the client to clear the cache when it becomes invalid,
e.g., when the ID of a previously mapped EObject is changed.intrinsicIDToEObjectMap
- the new map or null
.getIntrinsicIDToEObjectMap(org.eclipse.emf.cdo.eresource.CDOResource)
public static CDOSession getSession(Object object)
public static void configureView(CDOView view)
public static boolean prepareDynamicEPackage(org.eclipse.emf.ecore.EPackage startPackage)
public static CDOCollectionLoadingPolicy createCollectionLoadingPolicy(int initialChunkSize, int resolveChunkSize)
public static CDORevisionPrefetchingPolicy createRevisionPrefetchingPolicy(int chunkSize)
public static CDOFetchRuleManager createThreadLocalFetchRuleManager()
public static CDOFeatureAnalyzer createModelBasedFeatureAnalyzer()
public static CDOFeatureAnalyzer createUIFeatureAnalyzer()
public static CDOFeatureAnalyzer createUIFeatureAnalyzer(long maxTimeBetweenOperation)
public static CDOXATransaction createXATransaction(org.eclipse.emf.common.notify.Notifier... notifiers)
public static CDOXATransaction getXATransaction(CDOViewSet viewSet)
public static CDOViewSet getViewSet(org.eclipse.emf.common.notify.Notifier notifier)
public static CDOView getView(org.eclipse.emf.common.notify.Notifier notifier)
public static CDOView getView(org.eclipse.emf.ecore.resource.ResourceSet resourceSet, org.eclipse.emf.common.util.URI uri)
public static boolean isStaleObject(Object object)
public static void cleanStaleReference(org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.ecore.EStructuralFeature eFeature)
public static void cleanStaleReference(org.eclipse.emf.ecore.EObject eObject, org.eclipse.emf.ecore.EStructuralFeature eFeature, int index)
public static void load(org.eclipse.emf.ecore.EObject eObject, CDOView view)
public static CDOObject wrapExternalObject(org.eclipse.emf.ecore.EObject object, CDOView view)
public static org.eclipse.emf.ecore.EObject getEObject(org.eclipse.emf.ecore.EObject object)
public static CDOObject getCDOObject(org.eclipse.emf.ecore.EObject object)
public static CDOObject getCDOObject(org.eclipse.emf.ecore.EObject object, boolean adaptLegacy)
public static boolean isCDOObject(org.eclipse.emf.ecore.EObject object)
public static <T extends org.eclipse.emf.ecore.EObject> org.eclipse.emf.common.util.EList<T> filterReadables(Collection<T> collection)
public static CDOBranchPointRange getLifetime(CDOObject object)
public static CDORevision getRevisionByVersion(CDOObject object, int version)
public static CDORevision getRevisionByVersion(CDOObject object, CDOBranch branch, int version)
public static org.eclipse.emf.common.util.EList<org.eclipse.emf.ecore.resource.Resource> getResources(org.eclipse.emf.ecore.resource.ResourceSet resourceSet)
public static boolean isSessionDirty(CDOSession session)
CDOTransaction
@Deprecated public static boolean isInvalidationRunnerActive()
public static boolean isWritableObject(org.eclipse.emf.ecore.EObject eObject)
eObject
- an objectfalse
if the eObject
is managed by CDO and does not
have write permission;
true
, otherwisepublic static boolean isLegacyObject(org.eclipse.emf.ecore.EObject object)
@Deprecated public static boolean isLegacyModeDefault()
@Deprecated public static void setLegacyModeDefault(boolean on)
public static void setCredentialsProvider(org.eclipse.emf.common.util.URI uri, IPasswordCredentialsProvider provider)
public static String getAnnotation(ModelElement modelElement, String sourceURI, String key)
public static Annotation setAnnotation(ModelElement modelElement, String sourceURI, String key, String value)
public static String getDocumentation(ModelElement modelElement)
public static Annotation setDocumentation(ModelElement modelElement, String value)
Copyright (c) 2011-2014 Eike Stepper (Berlin, Germany) and others.