|
Lines 72-79
Link Here
|
| 72 |
import org.eclipse.emf.internal.cdo.util.FSMUtil; |
72 |
import org.eclipse.emf.internal.cdo.util.FSMUtil; |
| 73 |
|
73 |
|
| 74 |
import org.eclipse.net4j.util.ImplementationError; |
74 |
import org.eclipse.net4j.util.ImplementationError; |
| 75 |
import org.eclipse.net4j.util.StringUtil; |
|
|
| 76 |
import org.eclipse.net4j.util.ReflectUtil.ExcludeFromDump; |
75 |
import org.eclipse.net4j.util.ReflectUtil.ExcludeFromDump; |
|
|
76 |
import org.eclipse.net4j.util.StringUtil; |
| 77 |
import org.eclipse.net4j.util.collection.CloseableIterator; |
77 |
import org.eclipse.net4j.util.collection.CloseableIterator; |
| 78 |
import org.eclipse.net4j.util.collection.FastList; |
78 |
import org.eclipse.net4j.util.collection.FastList; |
| 79 |
import org.eclipse.net4j.util.collection.HashBag; |
79 |
import org.eclipse.net4j.util.collection.HashBag; |
|
Lines 100-111
Link Here
|
| 100 |
import org.eclipse.emf.ecore.resource.ResourceSet; |
100 |
import org.eclipse.emf.ecore.resource.ResourceSet; |
| 101 |
import org.eclipse.emf.ecore.util.EcoreUtil; |
101 |
import org.eclipse.emf.ecore.util.EcoreUtil; |
| 102 |
import org.eclipse.emf.spi.cdo.CDOSessionProtocol; |
102 |
import org.eclipse.emf.spi.cdo.CDOSessionProtocol; |
|
|
103 |
import org.eclipse.emf.spi.cdo.CDOSessionProtocol.RefreshSessionResult; |
| 103 |
import org.eclipse.emf.spi.cdo.InternalCDOObject; |
104 |
import org.eclipse.emf.spi.cdo.InternalCDOObject; |
| 104 |
import org.eclipse.emf.spi.cdo.InternalCDOSession; |
105 |
import org.eclipse.emf.spi.cdo.InternalCDOSession; |
| 105 |
import org.eclipse.emf.spi.cdo.InternalCDOTransaction; |
106 |
import org.eclipse.emf.spi.cdo.InternalCDOTransaction; |
| 106 |
import org.eclipse.emf.spi.cdo.InternalCDOView; |
107 |
import org.eclipse.emf.spi.cdo.InternalCDOView; |
| 107 |
import org.eclipse.emf.spi.cdo.InternalCDOViewSet; |
108 |
import org.eclipse.emf.spi.cdo.InternalCDOViewSet; |
| 108 |
import org.eclipse.emf.spi.cdo.CDOSessionProtocol.RefreshSessionResult; |
|
|
| 109 |
|
109 |
|
| 110 |
import java.text.MessageFormat; |
110 |
import java.text.MessageFormat; |
| 111 |
import java.util.ArrayList; |
111 |
import java.util.ArrayList; |
|
Lines 115-122
Link Here
|
| 115 |
import java.util.HashSet; |
115 |
import java.util.HashSet; |
| 116 |
import java.util.List; |
116 |
import java.util.List; |
| 117 |
import java.util.Map; |
117 |
import java.util.Map; |
| 118 |
import java.util.Set; |
|
|
| 119 |
import java.util.Map.Entry; |
118 |
import java.util.Map.Entry; |
|
|
119 |
import java.util.Set; |
| 120 |
import java.util.concurrent.ConcurrentMap; |
120 |
import java.util.concurrent.ConcurrentMap; |
| 121 |
import java.util.concurrent.locks.ReentrantLock; |
121 |
import java.util.concurrent.locks.ReentrantLock; |
| 122 |
|
122 |
|
|
Lines 127-132
Link Here
|
| 127 |
{ |
127 |
{ |
| 128 |
private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_VIEW, CDOViewImpl.class); |
128 |
private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_VIEW, CDOViewImpl.class); |
| 129 |
|
129 |
|
|
|
130 |
private final boolean legacyModeEnabled; |
| 131 |
|
| 130 |
private int viewID; |
132 |
private int viewID; |
| 131 |
|
133 |
|
| 132 |
private InternalCDOSession session; |
134 |
private InternalCDOSession session; |
|
Lines 176-181
Link Here
|
| 176 |
public CDOViewImpl(CDOBranch branch, long timeStamp) |
178 |
public CDOViewImpl(CDOBranch branch, long timeStamp) |
| 177 |
{ |
179 |
{ |
| 178 |
branchPoint = branch.getPoint(timeStamp); |
180 |
branchPoint = branch.getPoint(timeStamp); |
|
|
181 |
legacyModeEnabled = CDOUtil.isLegacyModeDefault(); |
| 179 |
options = createOptions(); |
182 |
options = createOptions(); |
| 180 |
} |
183 |
} |
| 181 |
|
184 |
|
|
Lines 205-210
Link Here
|
| 205 |
return true; |
208 |
return true; |
| 206 |
} |
209 |
} |
| 207 |
|
210 |
|
|
|
211 |
public boolean isLegacyModeEnabled() |
| 212 |
{ |
| 213 |
return legacyModeEnabled; |
| 214 |
} |
| 215 |
|
| 208 |
public ResourceSet getResourceSet() |
216 |
public ResourceSet getResourceSet() |
| 209 |
{ |
217 |
{ |
| 210 |
return viewSet.getResourceSet(); |
218 |
return viewSet.getResourceSet(); |
|
Lines 1270-1276
Link Here
|
| 1270 |
|
1278 |
|
| 1271 |
if (old != null) |
1279 |
if (old != null) |
| 1272 |
{ |
1280 |
{ |
| 1273 |
throw new IllegalStateException(MessageFormat.format(Messages.getString("CDOViewImpl.20"), object)); //$NON-NLS-1$ |
1281 |
if (CDOUtil.isLegacyObject(object)) |
|
|
1282 |
{ |
| 1283 |
OM.LOG.warn("Legacy object has been registered multiple times: " + object); |
| 1284 |
} |
| 1285 |
else |
| 1286 |
{ |
| 1287 |
throw new IllegalStateException(MessageFormat.format(Messages.getString("CDOViewImpl.20"), object)); //$NON-NLS-1$ |
| 1288 |
} |
| 1274 |
} |
1289 |
} |
| 1275 |
} |
1290 |
} |
| 1276 |
|
1291 |
|