Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorVictor Roldan Betancort2009-04-30 04:45:33 -0400
committerVictor Roldan Betancort2009-04-30 04:45:33 -0400
commit8ecfa57bb81f3a69ee70d9d631aaa6de050f173d (patch)
treeb3e4e4bad98499485b78b1c11c94d7f8decdafbe /plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal
parent782ea4888abf12cbac6be73f1865b29e8aed04c3 (diff)
downloadcdo-8ecfa57bb81f3a69ee70d9d631aaa6de050f173d.tar.gz
cdo-8ecfa57bb81f3a69ee70d9d631aaa6de050f173d.tar.xz
cdo-8ecfa57bb81f3a69ee70d9d631aaa6de050f173d.zip
[272190] [UI] Externalize Strings (CDO)
https://bugs.eclipse.org/bugs/show_bug.cgi?id=272190
Diffstat (limited to 'plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal')
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java32
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOMetaWrapper.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectImpl.java31
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectWrapper.java8
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStateMachine.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStore.java48
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOURIHandler.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAbstractFeatureRuleAnalyzer.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAnalyzerFeatureInfo.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/NOOPFetchRuleManager.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/bundle/Activator.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionConfigurationImpl.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionFactory.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/FailOverStrategyInjector.java17
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOClientProtocol.java3
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOTimeRequest.java8
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ChangeSubscriptionRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitNotificationIndication.java10
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionPhase2Request.java15
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionRequest.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/GetRemoteSessionsRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadChunkRequest.java10
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadLibrariesRequest.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadPackagesRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByTimeRequest.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByVersionRequest.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionRequest.java12
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LockObjectsRequest.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ObjectLockedRequest.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/OpenSessionRequest.java19
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryCancelRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ResourceIDRequest.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetAuditRequest.java12
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetPassiveUpdateRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SyncRevisionsRequest.java9
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnlockObjectsRequest.java8
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnsubscribeRemoteSessionsRequest.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/VerifyRevisionRequest.java8
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/query/CDOQueryImpl.java6
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/revision/CDOElementProxyImpl.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionConfigurationImpl.java3
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionFactory.java14
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java25
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/remote/CDORemoteSessionImpl.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOSingleTransactionStrategyImpl.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOTransactionImpl.java37
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXACommitContextImpl.java4
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXATransactionImpl.java20
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CompletePackageClosure.java9
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/FSMUtil.java9
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/PackageClosure.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOAuditImpl.java2
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewImpl.java65
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewProviderRegistryImpl.java18
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewSetImpl.java13
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/PluginContainerViewProvider.java2
57 files changed, 306 insertions, 261 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
index e8f00e51e3..2ca0033187 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOLegacyWrapper.java
@@ -73,10 +73,10 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
private static final ContextTracer TRACER = new ContextTracer(OM.DEBUG_OBJECT, CDOLegacyWrapper.class);
- private static final Method eSetDirectResourceMethod = ReflectUtil.getMethod(EObjectImpl.class, "eSetDirectResource",
+ private static final Method eSetDirectResourceMethod = ReflectUtil.getMethod(EObjectImpl.class, "eSetDirectResource", //$NON-NLS-1$
Resource.Internal.class);
- private static final Method eBasicSetContainerMethod = ReflectUtil.getMethod(EObjectImpl.class, "eBasicSetContainer",
+ private static final Method eBasicSetContainerMethod = ReflectUtil.getMethod(EObjectImpl.class, "eBasicSetContainer", //$NON-NLS-1$
InternalEObject.class, int.class);
private CDOState state;
@@ -115,7 +115,7 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting state {0} for {1}", state, this);
+ TRACER.format("Setting state {0} for {1}", state, this); //$NON-NLS-1$
}
CDOState tmp = this.state;
@@ -132,7 +132,7 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting revision: {0}", revision);
+ TRACER.format("Setting revision: {0}", revision); //$NON-NLS-1$
}
this.revision = (InternalCDORevision)revision;
@@ -244,14 +244,14 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
@Override
public String toString()
{
- return "CDOLegacyWrapper[" + id + "]";
+ return "CDOLegacyWrapper[" + id + "]"; //$NON-NLS-1$ //$NON-NLS-2$
}
private void instanceToRevision()
{
if (TRACER.isEnabled())
{
- TRACER.format("Transfering instance to revision: {0} --> {1}", instance, revision);
+ TRACER.format("Transfering instance to revision: {0} --> {1}", instance, revision); //$NON-NLS-1$
}
// Handle containment
@@ -329,7 +329,7 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
if (TRACER.isEnabled())
{
- TRACER.format("Transfering revision to instance: {0} --> {1}", revision, instance);
+ TRACER.format("Transfering revision to instance: {0} --> {1}", revision, instance); //$NON-NLS-1$
}
boolean deliver = instance.eDeliver();
@@ -485,10 +485,10 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
// UNIQUE_EFLAG = 1 << 9;
// *******************************************
- String flagName = GenUtil.getFeatureUpperName(featureName) + "_EFLAG";
+ String flagName = GenUtil.getFeatureUpperName(featureName) + "_EFLAG"; //$NON-NLS-1$
int flagsMask = getEFlagMask(instanceClass, flagName);
- field = ReflectUtil.getField(instanceClass, "eFlags");
+ field = ReflectUtil.getField(instanceClass, "eFlags"); //$NON-NLS-1$
int flags = (Integer)ReflectUtil.getValue(field, instance);
boolean on = (Boolean)value;
if (on)
@@ -507,7 +507,7 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
if (field == null)
{
- throw new ImplementationError("Field not found: " + fieldName);
+ throw new ImplementationError("Field not found: " + fieldName); //$NON-NLS-1$
}
ReflectUtil.setValue(field, instance, value);
@@ -655,10 +655,10 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
if (!instance.eIsProxy())
{
- URI uri = URI.createURI(CDOProtocolConstants.PROTOCOL_NAME + ":proxy#" + id);
+ URI uri = URI.createURI(CDOProtocolConstants.PROTOCOL_NAME + ":proxy#" + id); //$NON-NLS-1$
if (TRACER.isEnabled())
{
- TRACER.format("Setting proxyURI {0} for {1}", uri, instance);
+ TRACER.format("Setting proxyURI {0} for {1}", uri, instance); //$NON-NLS-1$
}
instance.eSetProxyURI(uri);
@@ -670,7 +670,7 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
{
if (TRACER.isEnabled())
{
- TRACER.format("Unsetting proxyURI for {0}", instance);
+ TRACER.format("Unsetting proxyURI for {0}", instance); //$NON-NLS-1$
}
instance.eSetProxyURI(null);
@@ -726,11 +726,11 @@ public final class CDOLegacyWrapper extends CDOObjectWrapper
*/
private static final class LegacyProxyInvocationHandler implements InvocationHandler, LegacyProxy
{
- private static final Method getIDMethod = ReflectUtil.getMethod(LegacyProxy.class, "getID");
+ private static final Method getIDMethod = ReflectUtil.getMethod(LegacyProxy.class, "getID"); //$NON-NLS-1$
- private static final Method eIsProxyMethod = ReflectUtil.getMethod(EObject.class, "eIsProxy");
+ private static final Method eIsProxyMethod = ReflectUtil.getMethod(EObject.class, "eIsProxy"); //$NON-NLS-1$
- private static final Method eProxyURIMethod = ReflectUtil.getMethod(InternalEObject.class, "eProxyURI");
+ private static final Method eProxyURIMethod = ReflectUtil.getMethod(InternalEObject.class, "eProxyURI"); //$NON-NLS-1$
private CDOLegacyWrapper wrapper;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOMetaWrapper.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOMetaWrapper.java
index fdda3570b9..e91ce718d1 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOMetaWrapper.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOMetaWrapper.java
@@ -120,9 +120,9 @@ public class CDOMetaWrapper extends CDOObjectWrapper
{
if (cdoID() == null)
{
- return instance.eClass().getName() + "?";
+ return instance.eClass().getName() + "?"; //$NON-NLS-1$
}
- return instance.eClass().getName() + "@" + cdoID();
+ return instance.eClass().getName() + "@" + cdoID(); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectImpl.java
index ee5a9612f7..9678af3194 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectImpl.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.cdo.common.id.CDOID;
import org.eclipse.emf.cdo.common.revision.CDORevision;
import org.eclipse.emf.cdo.eresource.CDOResource;
import org.eclipse.emf.cdo.eresource.impl.CDOResourceImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.revision.InternalCDORevision;
import org.eclipse.emf.cdo.util.CDOUtil;
import org.eclipse.emf.cdo.view.CDOView;
@@ -193,7 +194,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting ID: {0}", id);
+ TRACER.format("Setting ID: {0}", id); //$NON-NLS-1$
}
this.id = id;
@@ -205,7 +206,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting state {0} for {1}", state, this);
+ TRACER.format("Setting state {0} for {1}", state, this); //$NON-NLS-1$
}
try
@@ -229,7 +230,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting revision: {0}", revision);
+ TRACER.format("Setting revision: {0}", revision); //$NON-NLS-1$
}
this.revision = (InternalCDORevision)revision;
@@ -303,7 +304,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Populating revision for {0}", this);
+ TRACER.format("Populating revision for {0}", this); //$NON-NLS-1$
}
InternalCDOView view = cdoView();
@@ -364,7 +365,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Populating feature {0}", feature);
+ TRACER.format("Populating feature {0}", feature); //$NON-NLS-1$
}
Object setting = cdoBasicSettings() != null ? cdoSettings()[i] : null;
@@ -398,7 +399,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Depopulating revision for {0}", this);
+ TRACER.format("Depopulating revision for {0}", this); //$NON-NLS-1$
}
InternalCDOView view = cdoView();
@@ -437,7 +438,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Depopulating feature {0}", eFeature);
+ TRACER.format("Depopulating feature {0}", eFeature); //$NON-NLS-1$
}
EStructuralFeature.Internal internalFeature = (EStructuralFeature.Internal)eFeature;
@@ -591,7 +592,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
// Answer from Christian Damus
// Java ensures that string constants are interned, so this is actually
// more efficient than .equals() and it's correct
- if (eType.getInstanceClassName() == "java.util.Map$Entry")
+ if (eType.getInstanceClassName() == "java.util.Map$Entry") //$NON-NLS-1$
{
class EStoreEcoreEMap extends EcoreEMap<Object, Object> implements InternalCDOLoadable
{
@@ -736,7 +737,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
}
else
{
- throw new IllegalArgumentException("Resource needs to be an instanceof CDOResourceImpl");
+ throw new IllegalArgumentException(Messages.getString("CDOObjectImpl.8")); //$NON-NLS-1$
}
}
@@ -997,7 +998,7 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting container: {0}, featureID={1}", newEContainer, newContainerFeatureID);
+ TRACER.format("Setting container: {0}, featureID={1}", newEContainer, newContainerFeatureID); //$NON-NLS-1$
}
if (FSMUtil.isTransient(this))
@@ -1024,10 +1025,10 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
{
if (id == null)
{
- return eClass().getName() + "?";
+ return eClass().getName() + "?"; //$NON-NLS-1$
}
- return eClass().getName() + "@" + id;
+ return eClass().getName() + "@" + id; //$NON-NLS-1$
}
private CDOStore cdoStore()
@@ -1465,18 +1466,18 @@ public class CDOObjectImpl extends EStoreEObjectImpl implements InternalCDOObjec
protected String delegateToString()
{
StringBuffer stringBuffer = new StringBuffer();
- stringBuffer.append("[");
+ stringBuffer.append("["); //$NON-NLS-1$
for (int i = 0, size = size(); i < size;)
{
Object value = delegateGet(i);
stringBuffer.append(String.valueOf(value));
if (++i < size)
{
- stringBuffer.append(", ");
+ stringBuffer.append(", "); //$NON-NLS-1$
}
}
- stringBuffer.append("]");
+ stringBuffer.append("]"); //$NON-NLS-1$
return stringBuffer.toString();
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectWrapper.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectWrapper.java
index de667d2525..04388dc5fb 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectWrapper.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOObjectWrapper.java
@@ -94,12 +94,12 @@ public abstract class CDOObjectWrapper implements InternalCDOObject
{
if (id == null)
{
- throw new IllegalArgumentException("id == null");
+ throw new IllegalArgumentException("id == null"); //$NON-NLS-1$
}
if (TRACER.isEnabled())
{
- TRACER.format("Setting ID: {0} for {1}", id, instance);
+ TRACER.format("Setting ID: {0} for {1}", id, instance); //$NON-NLS-1$
}
this.id = id;
@@ -109,7 +109,7 @@ public abstract class CDOObjectWrapper implements InternalCDOObject
{
if (TRACER.isEnabled())
{
- TRACER.format("Setting view: {0} for {1}", view, instance);
+ TRACER.format("Setting view: {0} for {1}", view, instance); //$NON-NLS-1$
}
this.view = (InternalCDOView)view;
@@ -139,7 +139,7 @@ public abstract class CDOObjectWrapper implements InternalCDOObject
public EStructuralFeature cdoInternalDynamicFeature(int dynamicFeatureID)
{
// TODO Implement method CDOWrapperImpl.cdoInternalDynamicFeature()
- throw new UnsupportedOperationException("Not yet implemented");
+ throw new UnsupportedOperationException("Not yet implemented"); //$NON-NLS-1$
}
/**
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStateMachine.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStateMachine.java
index 9e2a8ed1b0..1b7272155c 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStateMachine.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStateMachine.java
@@ -205,7 +205,7 @@ public final class CDOStateMachine extends FiniteStateMachine<CDOState, CDOEvent
{
if (TRACER.isEnabled())
{
- TRACER.format("PREPARE: {0} --> {1}", object, transactionAndMapOfContents.getElement1());
+ TRACER.format("PREPARE: {0} --> {1}", object, transactionAndMapOfContents.getElement1()); //$NON-NLS-1$
}
process(object, CDOEvent.PREPARE, transactionAndMapOfContents);
@@ -218,7 +218,7 @@ public final class CDOStateMachine extends FiniteStateMachine<CDOState, CDOEvent
{
if (TRACER.isEnabled())
{
- TRACER.format("ATTACH: {0}", object);
+ TRACER.format("ATTACH: {0}", object); //$NON-NLS-1$
}
process(object, CDOEvent.ATTACH, null);
@@ -522,7 +522,7 @@ public final class CDOStateMachine extends FiniteStateMachine<CDOState, CDOEvent
CDOState state = object.cdoState();
if (lastTracedObject != object || lastTracedState != state || lastTracedEvent != event)
{
- TRACER.format("{0}: {1}", event, object.getClass().getName());
+ TRACER.format("{0}: {1}", event, object.getClass().getName()); //$NON-NLS-1$
lastTracedObject = object;
lastTracedState = state;
lastTracedEvent = event;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStore.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStore.java
index 682f25d712..91c1d3d3d5 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStore.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOStore.java
@@ -101,7 +101,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("setContainer({0}, {1}, {2}, {3})", cdoObject, newResource, newEContainer, newContainerFeatureID);
+ TRACER.format("setContainer({0}, {1}, {2}, {3})", cdoObject, newResource, newEContainer, newContainerFeatureID); //$NON-NLS-1$
}
Object newContainerID = newEContainer == null ? CDOID.NULL : cdoObject.cdoView().convertObjectToID(newEContainer,
@@ -120,7 +120,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("getContainer({0})", cdoObject);
+ TRACER.format("getContainer({0})", cdoObject); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -132,7 +132,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("getContainingFeatureID({0})", cdoObject);
+ TRACER.format("getContainingFeatureID({0})", cdoObject); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -147,7 +147,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("getResource({0})", cdoObject);
+ TRACER.format("getResource({0})", cdoObject); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -157,7 +157,7 @@ public final class CDOStore implements EStore
@Deprecated
public EStructuralFeature getContainingFeature(InternalEObject eObject)
{
- throw new UnsupportedOperationException("Use getContainingFeatureID() instead");
+ throw new UnsupportedOperationException("Use getContainingFeatureID() instead"); //$NON-NLS-1$
}
public Object get(InternalEObject eObject, EStructuralFeature feature, int index)
@@ -165,7 +165,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("get({0}, {1}, {2})", cdoObject, feature, index);
+ TRACER.format("get({0}, {1}, {2})", cdoObject, feature, index); //$NON-NLS-1$
}
view.getFeatureAnalyzer().preTraverseFeature(cdoObject, feature, index);
@@ -190,7 +190,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("size({0}, {1})", cdoObject, feature);
+ TRACER.format("size({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -202,7 +202,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("isEmpty({0}, {1})", cdoObject, feature);
+ TRACER.format("isEmpty({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -214,7 +214,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("contains({0}, {1}, {2})", cdoObject, feature, value);
+ TRACER.format("contains({0}, {1}, {2})", cdoObject, feature, value); //$NON-NLS-1$
}
if (feature instanceof EReference)
@@ -231,7 +231,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("indexOf({0}, {1}, {2})", cdoObject, feature, value);
+ TRACER.format("indexOf({0}, {1}, {2})", cdoObject, feature, value); //$NON-NLS-1$
}
if (feature instanceof EReference)
@@ -248,7 +248,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("lastIndexOf({0}, {1}, {2})", cdoObject, feature, value);
+ TRACER.format("lastIndexOf({0}, {1}, {2})", cdoObject, feature, value); //$NON-NLS-1$
}
if (feature instanceof EReference)
@@ -265,7 +265,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("hashCode({0}, {1})", cdoObject, feature);
+ TRACER.format("hashCode({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -277,7 +277,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("toArray({0}, {1})", cdoObject, feature);
+ TRACER.format("toArray({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
InternalCDORevision revision = getRevisionForReading(cdoObject);
@@ -319,7 +319,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("set({0}, {1}, {2}, {3})", cdoObject, feature, index, value);
+ TRACER.format("set({0}, {1}, {2}, {3})", cdoObject, feature, index, value); //$NON-NLS-1$
}
value = convertToCDO(getView(), feature, value);
@@ -383,7 +383,7 @@ public final class CDOStore implements EStore
// Object object = view.convertIDToObject(entry.getObject());
// value = FeatureMapUtil.createEntry(feature, object);
throw new UnsupportedOperationException(
- "Feature maps currently not supported. See https://bugs.eclipse.org/249436");
+ "Feature maps currently not supported. See https://bugs.eclipse.org/249436"); //$NON-NLS-1$
}
else
{
@@ -422,7 +422,7 @@ public final class CDOStore implements EStore
// String uri = EcoreUtil.getURI(entry.getEStructuralFeature()).toString();
// value = CDORevisionUtil.createFeatureMapEntry(uri, entry.getValue());
throw new UnsupportedOperationException(
- "Feature maps currently not supported. See https://bugs.eclipse.org/249436");
+ "Feature maps currently not supported. See https://bugs.eclipse.org/249436"); //$NON-NLS-1$
}
else
{
@@ -442,7 +442,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("unset({0}, {1})", cdoObject, feature);
+ TRACER.format("unset({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
CDOFeatureDelta delta = new CDOUnsetFeatureDeltaImpl(feature);
@@ -457,7 +457,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("add({0}, {1}, {2}, {3})", cdoObject, feature, index, value);
+ TRACER.format("add({0}, {1}, {2}, {3})", cdoObject, feature, index, value); //$NON-NLS-1$
}
value = convertToCDO(cdoObject.cdoView(), feature, value);
@@ -472,7 +472,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("remove({0}, {1}, {2})", cdoObject, feature, index);
+ TRACER.format("remove({0}, {1}, {2})", cdoObject, feature, index); //$NON-NLS-1$
}
CDOFeatureDelta delta = new CDORemoveFeatureDeltaImpl(feature, index);
@@ -489,7 +489,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("clear({0}, {1})", cdoObject, feature);
+ TRACER.format("clear({0}, {1})", cdoObject, feature); //$NON-NLS-1$
}
CDOFeatureDelta delta = new CDOClearFeatureDeltaImpl(feature);
@@ -503,7 +503,7 @@ public final class CDOStore implements EStore
InternalCDOObject cdoObject = getCDOObject(eObject);
if (TRACER.isEnabled())
{
- TRACER.format("move({0}, {1}, {2}, {3})", cdoObject, feature, target, source);
+ TRACER.format("move({0}, {1}, {2}, {3})", cdoObject, feature, target, source); //$NON-NLS-1$
}
CDOFeatureDelta delta = new CDOMoveFeatureDeltaImpl(feature, target, source);
@@ -516,13 +516,13 @@ public final class CDOStore implements EStore
public EObject create(EClass eClass)
{
- throw new UnsupportedOperationException("Use the generated factory to create objects");
+ throw new UnsupportedOperationException("Use the generated factory to create objects"); //$NON-NLS-1$
}
@Override
public String toString()
{
- return MessageFormat.format("CDOStore[{0}]", view);
+ return MessageFormat.format("CDOStore[{0}]", view); //$NON-NLS-1$
}
private InternalCDOObject getCDOObject(Object object)
@@ -598,7 +598,7 @@ public final class CDOStore implements EStore
InternalCDORevision revision = cdoObject.cdoRevision();
if (revision == null)
{
- throw new IllegalStateException("revision == null");
+ throw new IllegalStateException("revision == null"); //$NON-NLS-1$
}
return revision;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOURIHandler.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOURIHandler.java
index debb677ffb..ef8cb8884a 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOURIHandler.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/CDOURIHandler.java
@@ -39,7 +39,7 @@ import java.util.Set;
*/
public class CDOURIHandler implements URIHandler
{
- private static final String CDO_URI_SCHEME = "cdo";
+ private static final String CDO_URI_SCHEME = "cdo"; //$NON-NLS-1$
private InternalCDOView view;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAbstractFeatureRuleAnalyzer.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAbstractFeatureRuleAnalyzer.java
index 310ceec434..c173ac87d2 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAbstractFeatureRuleAnalyzer.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAbstractFeatureRuleAnalyzer.java
@@ -65,7 +65,7 @@ public abstract class CDOAbstractFeatureRuleAnalyzer implements CDOFeatureAnalyz
{
if (TRACER.isEnabled())
{
- TRACER.format("preTraverseFeature : {0}.{1}", cdoObject.eClass(), feature.getName());
+ TRACER.format("preTraverseFeature : {0}.{1}", cdoObject.eClass(), feature.getName()); //$NON-NLS-1$
}
loadCollectionPolicy = cdoObject.cdoView().getSession().options().getCollectionLoadingPolicy();
@@ -84,7 +84,7 @@ public abstract class CDOAbstractFeatureRuleAnalyzer implements CDOFeatureAnalyz
{
if (TRACER.isEnabled())
{
- TRACER.format("postTraverseFeature : {0}.{1}", cdoObject.eClass(), feature.getName());
+ TRACER.format("postTraverseFeature : {0}.{1}", cdoObject.eClass(), feature.getName()); //$NON-NLS-1$
}
try
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAnalyzerFeatureInfo.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAnalyzerFeatureInfo.java
index d42e5e30a5..7ebd1eea34 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAnalyzerFeatureInfo.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/CDOAnalyzerFeatureInfo.java
@@ -89,7 +89,7 @@ public class CDOAnalyzerFeatureInfo
{
if (TRACER.isEnabled())
{
- TRACER.format("Adding rule : {0}.{1}", eClass.getName(), feature.getName());
+ TRACER.format("Adding rule : {0}.{1}", eClass.getName(), feature.getName()); //$NON-NLS-1$
}
CDOFetchRule fetchRule = fetchRules.get(eClass);
@@ -106,7 +106,7 @@ public class CDOAnalyzerFeatureInfo
{
if (TRACER.isEnabled())
{
- TRACER.format("Removing rule : {0}.{1}", eClass.getName(), feature.getName());
+ TRACER.format("Removing rule : {0}.{1}", eClass.getName(), feature.getName()); //$NON-NLS-1$
}
CDOFetchRule fetchRule = fetchRules.get(eClass);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/NOOPFetchRuleManager.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/NOOPFetchRuleManager.java
index 2bedf202b8..edf7e2a9f4 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/NOOPFetchRuleManager.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/analyzer/NOOPFetchRuleManager.java
@@ -46,6 +46,6 @@ public class NOOPFetchRuleManager implements CDOFetchRuleManager
@Override
public String toString()
{
- return "NOOP";
+ return "NOOP"; //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/bundle/Activator.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/bundle/Activator.java
index 52ea29e181..24d1e8a2c9 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/bundle/Activator.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/bundle/Activator.java
@@ -61,7 +61,7 @@ public final class Activator extends EMFPlugin
OSGiActivator.traceStart(context);
if (OM.BUNDLE == null)
{
- throw new IllegalStateException("bundle == null");
+ throw new IllegalStateException("bundle == null"); //$NON-NLS-1$
}
try
@@ -89,7 +89,7 @@ public final class Activator extends EMFPlugin
OSGiActivator.traceStop(context);
if (OM.BUNDLE == null)
{
- throw new IllegalStateException("bundle == null");
+ throw new IllegalStateException("bundle == null"); //$NON-NLS-1$
}
try
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionConfigurationImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionConfigurationImpl.java
index 829a4baf9e..698c6309dc 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionConfigurationImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionConfigurationImpl.java
@@ -68,7 +68,7 @@ public class CDONet4jSessionConfigurationImpl extends CDOSessionConfigurationImp
if (isActivateOnOpen())
{
CheckUtil.checkState(connector != null ^ failOverStrategy != null,
- "Specify exactly one of connector or failOverStrategy");
+ "Specify exactly one of connector or failOverStrategy"); //$NON-NLS-1$
}
CDONet4jSessionImpl session = new CDONet4jSessionImpl();
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionFactory.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionFactory.java
index eb58a21aa4..5a00217d1c 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionFactory.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/CDONet4jSessionFactory.java
@@ -26,7 +26,7 @@ import org.eclipse.emf.spi.cdo.InternalCDOSession;
public class CDONet4jSessionFactory extends CDOSessionFactory
{
- public static final String TYPE = "cdo";
+ public static final String TYPE = "cdo"; //$NON-NLS-1$
public CDONet4jSessionFactory()
{
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/FailOverStrategyInjector.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/FailOverStrategyInjector.java
index d647246a3b..4f87b4a266 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/FailOverStrategyInjector.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/FailOverStrategyInjector.java
@@ -10,6 +10,8 @@
**************************************************************************/
package org.eclipse.emf.internal.cdo.net4j;
+import org.eclipse.emf.cdo.messages.Messages;
+
import org.eclipse.net4j.connector.IConnector;
import org.eclipse.net4j.signal.failover.NOOPFailOverStrategy;
import org.eclipse.net4j.util.StringUtil;
@@ -18,12 +20,16 @@ import org.eclipse.net4j.util.container.IManagedContainer;
import org.eclipse.spi.net4j.ConnectorFactory;
+import java.text.MessageFormat;
+
/**
* @author Eike Stepper
*/
public class FailOverStrategyInjector implements IElementProcessor
{
- private static final String SCHEME_SEPARATOR = "://";
+ private static final String INVALID_URI_MESSAGE = Messages.getString("InvalidURIException.0"); //$NON-NLS-1$
+
+ private static final String SCHEME_SEPARATOR = "://"; //$NON-NLS-1$
public FailOverStrategyInjector()
{
@@ -46,19 +52,22 @@ public class FailOverStrategyInjector implements IElementProcessor
int pos = description.indexOf(SCHEME_SEPARATOR);
if (pos == -1)
{
- throw new IllegalArgumentException("Invalid URI: " + description);
+ throw new IllegalArgumentException(MessageFormat.format(INVALID_URI_MESSAGE, description,
+ Messages.getString("FailOverStrategyInjector.0"))); //$NON-NLS-1$
}
String factoryType = description.substring(0, pos);
if (StringUtil.isEmpty(factoryType))
{
- throw new IllegalArgumentException("Invalid URI: " + description);
+ throw new IllegalArgumentException(MessageFormat.format(INVALID_URI_MESSAGE, description,
+ Messages.getString("FailOverStrategyInjector.1"))); //$NON-NLS-1$
}
String connectorDescription = description.substring(pos + SCHEME_SEPARATOR.length());
if (StringUtil.isEmpty(connectorDescription))
{
- throw new IllegalArgumentException("Invalid URI: " + description);
+ throw new IllegalArgumentException(MessageFormat.format(INVALID_URI_MESSAGE, description,
+ Messages.getString("FailOverStrategyInjector.2"))); //$NON-NLS-1$
}
pos = connectorDescription.indexOf('?');
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOClientProtocol.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOClientProtocol.java
index c08f8bb5a2..5dab60355d 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOClientProtocol.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOClientProtocol.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.cdo.common.model.CDOPackageUnit;
import org.eclipse.emf.cdo.common.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.common.util.TransportException;
import org.eclipse.emf.cdo.internal.common.protocol.CDOProtocolImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.session.CDOSession;
import org.eclipse.emf.cdo.session.remote.CDORemoteSession;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageUnit;
@@ -270,7 +271,7 @@ public class CDOClientProtocol extends CDOProtocolImpl implements CDOSessionProt
super.doBeforeActivate();
if (!(getInfraStructure() instanceof CDOSession))
{
- throw new IllegalStateException("No session");
+ throw new IllegalStateException(Messages.getString("CDOClientProtocol.0")); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOTimeRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOTimeRequest.java
index 45b0528921..6622eb78b5 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOTimeRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CDOTimeRequest.java
@@ -46,7 +46,7 @@ public abstract class CDOTimeRequest<RESULT> extends CDOClientRequest<RESULT>
repositoryTimeResult.setRequested(System.currentTimeMillis());
if (TRACER.isEnabled())
{
- TRACER.format("Requested: {0,date} {0,time}", repositoryTimeResult.getRequested());
+ TRACER.format("Requested: {0,date} {0,time}", repositoryTimeResult.getRequested()); //$NON-NLS-1$
}
}
@@ -56,19 +56,19 @@ public abstract class CDOTimeRequest<RESULT> extends CDOClientRequest<RESULT>
repositoryTimeResult.setConfirmed(System.currentTimeMillis());
if (TRACER.isEnabled())
{
- TRACER.format("Confirmed: {0,date} {0,time}", repositoryTimeResult.getConfirmed());
+ TRACER.format("Confirmed: {0,date} {0,time}", repositoryTimeResult.getConfirmed()); //$NON-NLS-1$
}
repositoryTimeResult.setIndicated(in.readLong());
if (TRACER.isEnabled())
{
- TRACER.format("Read indicated: {0,date} {0,time}", repositoryTimeResult.getIndicated());
+ TRACER.format("Read indicated: {0,date} {0,time}", repositoryTimeResult.getIndicated()); //$NON-NLS-1$
}
repositoryTimeResult.setResponded(in.readLong());
if (TRACER.isEnabled())
{
- TRACER.format("Read responded: {0,date} {0,time}", repositoryTimeResult.getResponded());
+ TRACER.format("Read responded: {0,date} {0,time}", repositoryTimeResult.getResponded()); //$NON-NLS-1$
}
return null;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ChangeSubscriptionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ChangeSubscriptionRequest.java
index 1c6e60c08a..969c31b8ba 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ChangeSubscriptionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ChangeSubscriptionRequest.java
@@ -58,7 +58,7 @@ public class ChangeSubscriptionRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.trace("View " + viewID + " subscribing to " + cdoIDs.size());
+ TRACER.trace("View " + viewID + " subscribing to " + cdoIDs.size()); //$NON-NLS-1$ //$NON-NLS-2$
}
out.writeInt(viewID);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitNotificationIndication.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitNotificationIndication.java
index a47030a1e3..02e39744e0 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitNotificationIndication.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitNotificationIndication.java
@@ -51,7 +51,7 @@ public class CommitNotificationIndication extends CDOClientIndication
long timeStamp = in.readLong();
if (TRACER.isEnabled())
{
- TRACER.format("Read timeStamp: {0,date} {0,time}", timeStamp);
+ TRACER.format("Read timeStamp: {0,date} {0,time}", timeStamp); //$NON-NLS-1$
}
CDOPackageUnit[] packageUnits = in.readCDOPackageUnits(null);
@@ -64,7 +64,7 @@ public class CommitNotificationIndication extends CDOClientIndication
int size = in.readInt();
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} dirty IDs", size);
+ TRACER.format("Reading {0} dirty IDs", size); //$NON-NLS-1$
}
InternalCDOSession session = getSession();
@@ -74,7 +74,7 @@ public class CommitNotificationIndication extends CDOClientIndication
CDOIDAndVersion dirtyOID = in.readCDOIDAndVersion();
if (TRACER.isEnabled())
{
- TRACER.format("Read dirty ID: {0}", dirtyOID);
+ TRACER.format("Read dirty ID: {0}", dirtyOID); //$NON-NLS-1$
}
dirtyOIDs.add(dirtyOID);
@@ -83,7 +83,7 @@ public class CommitNotificationIndication extends CDOClientIndication
size = in.readInt();
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} Deltas", size);
+ TRACER.format("Reading {0} Deltas", size); //$NON-NLS-1$
}
List<CDORevisionDelta> deltas = new ArrayList<CDORevisionDelta>();
@@ -96,7 +96,7 @@ public class CommitNotificationIndication extends CDOClientIndication
size = in.readInt();
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} Detach Objects", size);
+ TRACER.format("Reading {0} Detach Objects", size); //$NON-NLS-1$
}
List<CDOID> detachedObjects = new ArrayList<CDOID>();
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionPhase2Request.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionPhase2Request.java
index a79313e2c2..786d389df8 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionPhase2Request.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionPhase2Request.java
@@ -16,6 +16,7 @@ import org.eclipse.emf.cdo.common.io.CDODataInput;
import org.eclipse.emf.cdo.common.io.CDODataOutput;
import org.eclipse.emf.cdo.common.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.internal.common.id.CDOIDExternalTempImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.util.CDOURIUtil;
import org.eclipse.emf.internal.cdo.bundle.OM;
@@ -29,6 +30,7 @@ import org.eclipse.emf.spi.cdo.CDOSessionProtocol.CommitTransactionResult;
import org.eclipse.emf.spi.cdo.InternalCDOXATransaction.InternalCDOXACommitContext;
import java.io.IOException;
+import java.text.MessageFormat;
import java.util.Map;
import java.util.Map.Entry;
@@ -80,7 +82,7 @@ public class CommitTransactionPhase2Request extends CommitTransactionRequest
out.writeInt(size);
if (PROTOCOL.isEnabled())
{
- PROTOCOL.format("Number of ids requested: {0}", size);
+ PROTOCOL.format("Number of ids requested: {0}", size); //$NON-NLS-1$
}
for (Entry<CDOIDExternalTempImpl, InternalCDOTransaction> entry : requestedIDs.entrySet())
@@ -92,20 +94,23 @@ public class CommitTransactionPhase2Request extends CommitTransactionRequest
InternalCDOXACommitContext commitContext = context.getTransactionManager().getCommitContext(entry.getValue());
if (commitContext == null)
{
- throw new IllegalStateException("Missing informations. " + entry.getValue() + " isn't involved in the commit.");
+ throw new IllegalStateException(MessageFormat.format(
+ Messages.getString("CommitTransactionPhase2Request.1"), entry //$NON-NLS-1$
+ .getValue()));
}
CDOID newID = commitContext.getResult().getIDMappings().get(oldCDOID);
if (newID == null)
{
- throw new IllegalStateException("Missing informations. " + oldCDOID.toURIFragment()
- + " isn't mapped in the commit.");
+ throw new IllegalStateException(MessageFormat.format(
+ Messages.getString("CommitTransactionPhase2Request.2"), oldCDOID //$NON-NLS-1$
+ .toURIFragment()));
}
CDOID newIDExternal = CDOURIUtil.convertExternalCDOID(oldURIExternal, newID);
if (PROTOCOL.isEnabled())
{
- PROTOCOL.format("ID mapping: {0} --> {1}", tempID.toURIFragment(), newIDExternal.toURIFragment());
+ PROTOCOL.format("ID mapping: {0} --> {1}", tempID.toURIFragment(), newIDExternal.toURIFragment()); //$NON-NLS-1$
}
out.writeCDOID(tempID);
out.writeCDOID(newIDExternal);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionRequest.java
index 876fa6e56b..78c90c378e 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/CommitTransactionRequest.java
@@ -192,7 +192,7 @@ public class CommitTransactionRequest extends RequestWithMonitoring<CommitTransa
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} new package units", newPackageUnits.size());
+ TRACER.format("Writing {0} new package units", newPackageUnits.size()); //$NON-NLS-1$
}
for (CDOPackageUnit newPackageUnit : newPackageUnits)
@@ -202,7 +202,7 @@ public class CommitTransactionRequest extends RequestWithMonitoring<CommitTransa
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} new objects", newResources.size() + newObjects.size());
+ TRACER.format("Writing {0} new objects", newResources.size() + newObjects.size()); //$NON-NLS-1$
}
writeRevisions(out, newResources);
@@ -210,7 +210,7 @@ public class CommitTransactionRequest extends RequestWithMonitoring<CommitTransa
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} dirty objects", revisionDeltas.size());
+ TRACER.format("Writing {0} dirty objects", revisionDeltas.size()); //$NON-NLS-1$
}
for (CDORevisionDelta revisionDelta : revisionDeltas)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/GetRemoteSessionsRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/GetRemoteSessionsRequest.java
index 7656b44c91..c3753dfe28 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/GetRemoteSessionsRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/GetRemoteSessionsRequest.java
@@ -48,7 +48,7 @@ public class GetRemoteSessionsRequest extends CDOClientRequest<List<CDORemoteSes
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing subscribe: {0}", subscribe);
+ TRACER.format("Writing subscribe: {0}", subscribe); //$NON-NLS-1$
}
out.writeBoolean(subscribe);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadChunkRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadChunkRequest.java
index 50b30dfb5d..4e293822b9 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadChunkRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadChunkRequest.java
@@ -64,7 +64,7 @@ public class LoadChunkRequest extends CDOClientRequest<Object>
CDOID id = revision.getID();
if (TRACER.isEnabled())
{
- TRACER.format("Writing revision ID: {0}", id);
+ TRACER.format("Writing revision ID: {0}", id); //$NON-NLS-1$
}
out.writeCDOID(id);
@@ -76,26 +76,26 @@ public class LoadChunkRequest extends CDOClientRequest<Object>
if (TRACER.isEnabled())
{
- TRACER.format("Writing revision version: {0}", version);
+ TRACER.format("Writing revision version: {0}", version); //$NON-NLS-1$
}
out.writeInt(version);
if (TRACER.isEnabled())
{
- TRACER.format("Writing feature: {0}", feature);
+ TRACER.format("Writing feature: {0}", feature); //$NON-NLS-1$
}
out.writeCDOClassifierRef(feature.getEContainingClass());
out.writeInt(feature.getFeatureID());
if (TRACER.isEnabled())
{
- TRACER.format("Writing fromIndex: {0}", fromIndex);
+ TRACER.format("Writing fromIndex: {0}", fromIndex); //$NON-NLS-1$
}
int diffIndex = accessIndex - fetchIndex;
out.writeInt(fromIndex - diffIndex);
if (TRACER.isEnabled())
{
- TRACER.format("Writing toIndex: {0}", toIndex);
+ TRACER.format("Writing toIndex: {0}", toIndex); //$NON-NLS-1$
}
out.writeInt(toIndex - diffIndex);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadLibrariesRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadLibrariesRequest.java
index 162bbec6a8..4db958e6d9 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadLibrariesRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadLibrariesRequest.java
@@ -48,7 +48,7 @@ public class LoadLibrariesRequest extends RequestWithConfirmation<Integer>
int size = libraryNames.size();
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} library names", size);
+ TRACER.format("Writing {0} library names", size); //$NON-NLS-1$
}
out.writeInt(size);
@@ -56,7 +56,7 @@ public class LoadLibrariesRequest extends RequestWithConfirmation<Integer>
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing library name: {0}", libraryName);
+ TRACER.format("Writing library name: {0}", libraryName); //$NON-NLS-1$
}
out.writeString(libraryName);
@@ -73,7 +73,7 @@ public class LoadLibrariesRequest extends RequestWithConfirmation<Integer>
int size = in.readInt();
if (TRACER.isEnabled())
{
- TRACER.format("Reading library {0}: {1} bytes", libraryName, size);
+ TRACER.format("Reading library {0}: {1} bytes", libraryName, size); //$NON-NLS-1$
}
File file = new File(cacheFolder, libraryName);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadPackagesRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadPackagesRequest.java
index e3eee6a65b..710eb488f8 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadPackagesRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadPackagesRequest.java
@@ -46,7 +46,7 @@ public class LoadPackagesRequest extends CDOClientRequest<EPackage[]>
String packageUnitID = packageUnit.getID();
if (TRACER.isEnabled())
{
- TRACER.format("Writing packageUnitID: {0}", packageUnitID);
+ TRACER.format("Writing packageUnitID: {0}", packageUnitID); //$NON-NLS-1$
}
out.writeCDOPackageURI(packageUnitID);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByTimeRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByTimeRequest.java
index ccfcacf6ba..92c49d391e 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByTimeRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByTimeRequest.java
@@ -43,7 +43,7 @@ public class LoadRevisionByTimeRequest extends LoadRevisionRequest
super.requesting(out);
if (TRACER.isEnabled())
{
- TRACER.format("Writing timeStamp: {0}", timeStamp);
+ TRACER.format("Writing timeStamp: {0}", timeStamp); //$NON-NLS-1$
}
out.writeLong(timeStamp);
@@ -52,7 +52,7 @@ public class LoadRevisionByTimeRequest extends LoadRevisionRequest
@Override
public String toString()
{
- return MessageFormat.format("{0}(ids={1}, referenceChunk={2}, timeStamp={3})", getClass().getSimpleName(),
+ return MessageFormat.format("{0}(ids={1}, referenceChunk={2}, timeStamp={3})", getClass().getSimpleName(), //$NON-NLS-1$
getIds(), getReferenceChunk(), timeStamp);
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByVersionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByVersionRequest.java
index 16dfcbc779..ddea39b4c8 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByVersionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionByVersionRequest.java
@@ -43,7 +43,7 @@ public class LoadRevisionByVersionRequest extends LoadRevisionRequest
super.requesting(out);
if (TRACER.isEnabled())
{
- TRACER.format("Writing version: {0}", version);
+ TRACER.format("Writing version: {0}", version); //$NON-NLS-1$
}
out.writeInt(version);
@@ -52,7 +52,7 @@ public class LoadRevisionByVersionRequest extends LoadRevisionRequest
@Override
public String toString()
{
- return MessageFormat.format("{0}(ids={1}, referenceChunk={2}, version={3})", getClass().getSimpleName(), getIds(),
+ return MessageFormat.format("{0}(ids={1}, referenceChunk={2}, version={3})", getClass().getSimpleName(), getIds(), //$NON-NLS-1$
getReferenceChunk(), version);
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionRequest.java
index 69638a96df..853dde03a2 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LoadRevisionRequest.java
@@ -57,13 +57,13 @@ public class LoadRevisionRequest extends CDOClientRequest<List<InternalCDORevisi
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing referenceChunk: {0}", referenceChunk);
+ TRACER.format("Writing referenceChunk: {0}", referenceChunk); //$NON-NLS-1$
}
out.writeInt(referenceChunk);
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} IDs", ids.size());
+ TRACER.format("Writing {0} IDs", ids.size()); //$NON-NLS-1$
}
out.writeInt(ids.size());
@@ -71,7 +71,7 @@ public class LoadRevisionRequest extends CDOClientRequest<List<InternalCDORevisi
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing ID: {0}", id);
+ TRACER.format("Writing ID: {0}", id); //$NON-NLS-1$
}
out.writeCDOID(id);
@@ -108,7 +108,7 @@ public class LoadRevisionRequest extends CDOClientRequest<List<InternalCDORevisi
ArrayList<InternalCDORevision> revisions = new ArrayList<InternalCDORevision>(idSize);
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} revisions", idSize);
+ TRACER.format("Reading {0} revisions", idSize); //$NON-NLS-1$
}
for (int i = 0; i < idSize; i++)
@@ -122,7 +122,7 @@ public class LoadRevisionRequest extends CDOClientRequest<List<InternalCDORevisi
{
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} additional revisions", additionalSize);
+ TRACER.format("Reading {0} additional revisions", additionalSize); //$NON-NLS-1$
}
CDORevisionManagerImpl revisionManager = (CDORevisionManagerImpl)getSession().getRevisionManager();
@@ -152,6 +152,6 @@ public class LoadRevisionRequest extends CDOClientRequest<List<InternalCDORevisi
@Override
public String toString()
{
- return MessageFormat.format("{0}(ids={1}, referenceChunk={2})", getClass().getSimpleName(), ids, referenceChunk);
+ return MessageFormat.format("{0}(ids={1}, referenceChunk={2})", getClass().getSimpleName(), ids, referenceChunk); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LockObjectsRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LockObjectsRequest.java
index 93dab154e6..2002179965 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LockObjectsRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/LockObjectsRequest.java
@@ -58,8 +58,8 @@ public class LockObjectsRequest extends CDOClientRequest<Object>
if (TRACER.isEnabled())
{
- TRACER.format("Locking of type {0} requested for view {1} with timeout {2}",
- lockType == RWLockManager.LockType.READ ? "read" : "write", view.getViewID(), timeout);
+ TRACER.format("Locking of type {0} requested for view {1} with timeout {2}", //$NON-NLS-1$
+ lockType == RWLockManager.LockType.READ ? "read" : "write", view.getViewID(), timeout); //$NON-NLS-1$ //$NON-NLS-2$
}
out.writeInt(objects.size());
@@ -67,7 +67,7 @@ public class LockObjectsRequest extends CDOClientRequest<Object>
{
if (TRACER.isEnabled())
{
- TRACER.format("Locking requested for objects {0}", object.cdoID());
+ TRACER.format("Locking requested for objects {0}", object.cdoID()); //$NON-NLS-1$
}
out.writeCDOID(object.cdoID());
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ObjectLockedRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ObjectLockedRequest.java
index e49ef644dd..3863b357c9 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ObjectLockedRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ObjectLockedRequest.java
@@ -53,8 +53,8 @@ public class ObjectLockedRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.format("Requesting if object {0} has of lock for object {1}", object.cdoID(),
- lockType == RWLockManager.LockType.READ ? "read" : "write");
+ TRACER.format("Requesting if object {0} has of lock for object {1}", object.cdoID(), //$NON-NLS-1$
+ lockType == RWLockManager.LockType.READ ? "read" : "write"); //$NON-NLS-1$ //$NON-NLS-2$
}
out.writeInt(view.getViewID());
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/OpenSessionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/OpenSessionRequest.java
index 3ca4a4814e..5a5b610b1b 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/OpenSessionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/OpenSessionRequest.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.cdo.common.io.CDODataInput;
import org.eclipse.emf.cdo.common.io.CDODataOutput;
import org.eclipse.emf.cdo.common.model.CDOPackageUnit;
import org.eclipse.emf.cdo.common.protocol.CDOProtocolConstants;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageUnit;
import org.eclipse.emf.cdo.util.ServerException;
@@ -55,14 +56,14 @@ public class OpenSessionRequest extends CDOTimeRequest<OpenSessionResult>
super.requesting(out);
if (TRACER.isEnabled())
{
- TRACER.format("Writing repositoryName: {0}", repositoryName);
+ TRACER.format("Writing repositoryName: {0}", repositoryName); //$NON-NLS-1$
}
out.writeString(repositoryName);
if (TRACER.isEnabled())
{
- TRACER.format("Writing passiveUpdateEnabled: {0}", passiveUpdateEnabled);
+ TRACER.format("Writing passiveUpdateEnabled: {0}", passiveUpdateEnabled); //$NON-NLS-1$
}
out.writeBoolean(passiveUpdateEnabled);
@@ -74,43 +75,43 @@ public class OpenSessionRequest extends CDOTimeRequest<OpenSessionResult>
int sessionID = in.readInt();
if (sessionID == CDOProtocolConstants.ERROR_REPOSITORY_NOT_FOUND)
{
- String msg = MessageFormat.format("Repository {0} not found", repositoryName);
+ String msg = MessageFormat.format(Messages.getString("OpenSessionRequest.0"), repositoryName); //$NON-NLS-1$
throw new ServerException(msg);
}
if (sessionID == CDOProtocolConstants.ERROR_NO_SESSION)
{
- String msg = MessageFormat.format("Failed to open session for repository {0}", repositoryName);
+ String msg = MessageFormat.format(Messages.getString("OpenSessionRequest.3"), repositoryName); //$NON-NLS-1$
throw new ServerException(msg);
}
if (TRACER.isEnabled())
{
- TRACER.format("Read sessionID: {0}", sessionID);
+ TRACER.format("Read sessionID: {0}", sessionID); //$NON-NLS-1$
}
String repositoryUUID = in.readString();
if (TRACER.isEnabled())
{
- TRACER.format("Read repositoryUUID: {0}", repositoryUUID);
+ TRACER.format("Read repositoryUUID: {0}", repositoryUUID); //$NON-NLS-1$
}
long repositoryCreationTime = in.readLong();
if (TRACER.isEnabled())
{
- TRACER.format("Read repositoryCreationTime: {0,date} {0,time}", repositoryCreationTime);
+ TRACER.format("Read repositoryCreationTime: {0,date} {0,time}", repositoryCreationTime); //$NON-NLS-1$
}
boolean repositorySupportingAudits = in.readBoolean();
if (TRACER.isEnabled())
{
- TRACER.format("Read repositorySupportingAudits: {0}", repositorySupportingAudits);
+ TRACER.format("Read repositorySupportingAudits: {0}", repositorySupportingAudits); //$NON-NLS-1$
}
CDOIDLibraryDescriptor libraryDescriptor = CDOIDUtil.readLibraryDescriptor(in);
if (TRACER.isEnabled())
{
- TRACER.format("Read libraryDescriptor: {0}", libraryDescriptor);
+ TRACER.format("Read libraryDescriptor: {0}", libraryDescriptor); //$NON-NLS-1$
}
result = new OpenSessionResult(sessionID, repositoryUUID, repositoryCreationTime, repositorySupportingAudits,
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryCancelRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryCancelRequest.java
index aa77ff354f..b3bf7caf5c 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryCancelRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryCancelRequest.java
@@ -41,7 +41,7 @@ public class QueryCancelRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.trace("Cancel query " + queryID);
+ TRACER.trace("Cancel query " + queryID); //$NON-NLS-1$
}
out.writeInt(queryID);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryRequest.java
index d9752e46d1..a62e821899 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/QueryRequest.java
@@ -75,7 +75,7 @@ public class QueryRequest extends CDOClientRequest<List<Object>>
if (TRACER.isEnabled())
{
- TRACER.format("Query executed [{0} elements received]", numberOfObjectsReceived);
+ TRACER.format("Query executed [{0} elements received]", numberOfObjectsReceived); //$NON-NLS-1$
}
}
catch (RuntimeException ex)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ResourceIDRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ResourceIDRequest.java
index 42d5ae513f..1937f58974 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ResourceIDRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/ResourceIDRequest.java
@@ -44,13 +44,13 @@ public class ResourceIDRequest extends CDOClientRequest<CDOID>
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing viewID: {0}", viewID);
+ TRACER.format("Writing viewID: {0}", viewID); //$NON-NLS-1$
}
out.writeInt(viewID);
if (TRACER.isEnabled())
{
- TRACER.format("Writing path: {0}", path);
+ TRACER.format("Writing path: {0}", path); //$NON-NLS-1$
}
out.writeString(path);
@@ -62,7 +62,7 @@ public class ResourceIDRequest extends CDOClientRequest<CDOID>
CDOID id = in.readCDOID();
if (TRACER.isEnabled())
{
- TRACER.format("Read ID: {0}", id);
+ TRACER.format("Read ID: {0}", id); //$NON-NLS-1$
}
return id;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetAuditRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetAuditRequest.java
index 9095430692..178c22ef74 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetAuditRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetAuditRequest.java
@@ -49,13 +49,13 @@ public class SetAuditRequest extends CDOClientRequest<boolean[]>
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing viewID: {0}", viewID);
+ TRACER.format("Writing viewID: {0}", viewID); //$NON-NLS-1$
}
out.writeInt(viewID);
if (TRACER.isEnabled())
{
- TRACER.format("Writing timeStamp: {0,date} {0,time}", timeStamp);
+ TRACER.format("Writing timeStamp: {0,date} {0,time}", timeStamp); //$NON-NLS-1$
}
out.writeLong(timeStamp);
@@ -63,7 +63,7 @@ public class SetAuditRequest extends CDOClientRequest<boolean[]>
int size = invalidObjects.size();
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} IDs", size);
+ TRACER.format("Writing {0} IDs", size); //$NON-NLS-1$
}
out.writeInt(size);
@@ -71,7 +71,7 @@ public class SetAuditRequest extends CDOClientRequest<boolean[]>
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing ID: {0}", object.cdoID());
+ TRACER.format("Writing ID: {0}", object.cdoID()); //$NON-NLS-1$
}
out.writeCDOID(object.cdoID());
@@ -84,7 +84,7 @@ public class SetAuditRequest extends CDOClientRequest<boolean[]>
int size = in.readInt();
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} existanceFlags", size);
+ TRACER.format("Reading {0} existanceFlags", size); //$NON-NLS-1$
}
boolean[] existanceFlags = new boolean[size];
@@ -94,7 +94,7 @@ public class SetAuditRequest extends CDOClientRequest<boolean[]>
existanceFlags[i] = existanceFlag;
if (TRACER.isEnabled())
{
- TRACER.format("Read existanceFlag: {0}", existanceFlag);
+ TRACER.format("Read existanceFlag: {0}", existanceFlag); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetPassiveUpdateRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetPassiveUpdateRequest.java
index 16dc05575a..18545f7ff0 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetPassiveUpdateRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SetPassiveUpdateRequest.java
@@ -45,7 +45,7 @@ public class SetPassiveUpdateRequest extends SyncRevisionsRequest
{
if (TRACER.isEnabled())
{
- TRACER.trace("Turning " + (passiveUpdateEnabled ? "on" : "off") + " passive update");
+ TRACER.trace("Turning " + (passiveUpdateEnabled ? "on" : "off") + " passive update"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
super.requesting(out);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SyncRevisionsRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SyncRevisionsRequest.java
index 80277cc685..ef75bc11c9 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SyncRevisionsRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/SyncRevisionsRequest.java
@@ -19,6 +19,7 @@ import org.eclipse.emf.cdo.common.io.CDODataOutput;
import org.eclipse.emf.cdo.common.model.CDOPackageUnit;
import org.eclipse.emf.cdo.common.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.common.revision.CDORevision;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.revision.InternalCDORevision;
import org.eclipse.emf.cdo.transaction.CDOTimeStampContext;
@@ -29,6 +30,7 @@ import org.eclipse.emf.internal.cdo.transaction.CDOTimeStampContextImpl;
import org.eclipse.net4j.util.om.trace.ContextTracer;
import java.io.IOException;
+import java.text.MessageFormat;
import java.util.Collection;
import java.util.Collections;
import java.util.Map;
@@ -65,7 +67,7 @@ public class SyncRevisionsRequest extends CDOClientRequest<Collection<CDOTimeSta
{
if (TRACER.isEnabled())
{
- TRACER.trace("Synchronization " + idAndVersions.size() + " objects");
+ TRACER.trace("Synchronization " + idAndVersions.size() + " objects"); //$NON-NLS-1$ //$NON-NLS-2$
}
out.writeInt(referenceChunk);
@@ -92,7 +94,8 @@ public class SyncRevisionsRequest extends CDOClientRequest<Collection<CDOTimeSta
CDOIDAndVersion idAndVersion = idAndVersions.get(revision.getID());
if (idAndVersion == null)
{
- throw new IllegalStateException("Didn't expect to receive object with id '" + revision.getID() + "'");
+ throw new IllegalStateException(MessageFormat.format(
+ Messages.getString("SyncRevisionsRequest.2"), revision.getID())); //$NON-NLS-1$
}
Set<CDOIDAndVersion> dirtyObjects = getMap(mapofContext, revised).getDirtyObjects();
@@ -102,7 +105,7 @@ public class SyncRevisionsRequest extends CDOClientRequest<Collection<CDOTimeSta
if (TRACER.isEnabled())
{
- TRACER.trace("Synchronization received " + size + " dirty objects");
+ TRACER.trace("Synchronization received " + size + " dirty objects"); //$NON-NLS-1$ //$NON-NLS-2$
}
size = in.readInt();
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnlockObjectsRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnlockObjectsRequest.java
index 5fc6e4ecd1..abe74b88bd 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnlockObjectsRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnlockObjectsRequest.java
@@ -55,7 +55,7 @@ public class UnlockObjectsRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.format("Unlocking all objects for view {0}", view.getViewID());
+ TRACER.format("Unlocking all objects for view {0}", view.getViewID()); //$NON-NLS-1$
}
out.writeInt(CDOProtocolConstants.RELEASE_ALL_LOCKS);
@@ -64,8 +64,8 @@ public class UnlockObjectsRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.format("Unlocking of type {0} requested for view {1}", lockType == RWLockManager.LockType.READ ? "read"
- : "write", view.getViewID());
+ TRACER.format("Unlocking of type {0} requested for view {1}", lockType == RWLockManager.LockType.READ ? "read" //$NON-NLS-1$ //$NON-NLS-2$
+ : "write", view.getViewID()); //$NON-NLS-1$
}
out.writeInt(objects.size());
@@ -73,7 +73,7 @@ public class UnlockObjectsRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.format("Unlocking requested for objects {0}", object.cdoID());
+ TRACER.format("Unlocking requested for objects {0}", object.cdoID()); //$NON-NLS-1$
}
out.writeCDOID(object.cdoID());
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnsubscribeRemoteSessionsRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnsubscribeRemoteSessionsRequest.java
index 17722b2ec2..cdb38e098f 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnsubscribeRemoteSessionsRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/UnsubscribeRemoteSessionsRequest.java
@@ -38,7 +38,7 @@ public class UnsubscribeRemoteSessionsRequest extends CDOClientRequest<Boolean>
{
if (TRACER.isEnabled())
{
- TRACER.trace("Unsubscribing");
+ TRACER.trace("Unsubscribing"); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/VerifyRevisionRequest.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/VerifyRevisionRequest.java
index 71f9471490..93c1bfb49a 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/VerifyRevisionRequest.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/net4j/protocol/VerifyRevisionRequest.java
@@ -52,7 +52,7 @@ public class VerifyRevisionRequest extends CDOClientRequest<List<InternalCDORevi
{
if (TRACER.isEnabled())
{
- TRACER.format("Writing {0} IDs and versions", revisions.size());
+ TRACER.format("Writing {0} IDs and versions", revisions.size()); //$NON-NLS-1$
}
out.writeInt(revisions.size());
@@ -62,7 +62,7 @@ public class VerifyRevisionRequest extends CDOClientRequest<List<InternalCDORevi
int version = revision.getVersion();
if (TRACER.isEnabled())
{
- TRACER.format("Writing ID and version: {0}v{1}", id, version);
+ TRACER.format("Writing ID and version: {0}v{1}", id, version); //$NON-NLS-1$
}
out.writeCDOID(id);
@@ -76,7 +76,7 @@ public class VerifyRevisionRequest extends CDOClientRequest<List<InternalCDORevi
ArrayList<InternalCDORevision> result = new ArrayList<InternalCDORevision>();
if (TRACER.isEnabled())
{
- TRACER.format("Reading {0} timeStamps", revisions.size());
+ TRACER.format("Reading {0} timeStamps", revisions.size()); //$NON-NLS-1$
}
for (InternalCDORevision revision : revisions)
@@ -84,7 +84,7 @@ public class VerifyRevisionRequest extends CDOClientRequest<List<InternalCDORevi
long revised = in.readLong();
if (TRACER.isEnabled())
{
- TRACER.format("Reading timeStamp: {0}", revised);
+ TRACER.format("Reading timeStamp: {0}", revised); //$NON-NLS-1$
}
if (revised != CDORevision.UNSPECIFIED_DATE)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/query/CDOQueryImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/query/CDOQueryImpl.java
index afbbbe1cf0..9616aa2ce5 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/query/CDOQueryImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/query/CDOQueryImpl.java
@@ -14,6 +14,7 @@ package org.eclipse.emf.internal.cdo.query;
import org.eclipse.emf.cdo.common.id.CDOID;
import org.eclipse.emf.cdo.common.util.BlockingCloseableIterator;
import org.eclipse.emf.cdo.internal.common.CDOQueryInfoImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.view.CDOQuery;
import org.eclipse.emf.internal.cdo.util.FSMUtil;
@@ -32,6 +33,7 @@ import java.util.Map.Entry;
*/
public class CDOQueryImpl extends CDOQueryInfoImpl implements CDOQuery
{
+ private static final String OBJECT_NOT_PERSISTED_MESSAGE = Messages.getString("CDOQueryImpl.0"); //$NON-NLS-1$
private InternalCDOView view;
public CDOQueryImpl(InternalCDOView view, String queryLanguage, String queryString)
@@ -138,12 +140,12 @@ public class CDOQueryImpl extends CDOQueryInfoImpl implements CDOQuery
InternalCDOObject internalCDOObject = FSMUtil.adapt(object, view);
if (internalCDOObject.cdoID() == null)
{
- throw new UnsupportedOperationException("Object not persisted");
+ throw new UnsupportedOperationException(OBJECT_NOT_PERSISTED_MESSAGE);
}
if (internalCDOObject.cdoID().isTemporary())
{
- throw new UnsupportedOperationException("Object not persisted");
+ throw new UnsupportedOperationException(OBJECT_NOT_PERSISTED_MESSAGE);
}
return internalCDOObject.cdoID();
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/revision/CDOElementProxyImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/revision/CDOElementProxyImpl.java
index 3f61de4900..622a9de61d 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/revision/CDOElementProxyImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/revision/CDOElementProxyImpl.java
@@ -51,6 +51,6 @@ public final class CDOElementProxyImpl implements CDOElementProxy
@Override
public String toString()
{
- return MessageFormat.format("CDOElementProxy[{0}]", index);
+ return MessageFormat.format("CDOElementProxy[{0}]", index); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionConfigurationImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionConfigurationImpl.java
index e932e31c9c..ee9676451a 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionConfigurationImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionConfigurationImpl.java
@@ -12,6 +12,7 @@ package org.eclipse.emf.internal.cdo.session;
import org.eclipse.emf.cdo.common.model.CDOPackageRegistry;
import org.eclipse.emf.cdo.common.revision.cache.CDORevisionCache;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.session.CDOSession;
import org.eclipse.emf.cdo.session.CDOSessionConfiguration;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageRegistry;
@@ -134,7 +135,7 @@ public abstract class CDOSessionConfigurationImpl implements CDOSessionConfigura
{
if (isSessionOpen())
{
- throw new IllegalStateException("Session is already open");
+ throw new IllegalStateException(Messages.getString("CDOSessionConfigurationImpl.0")); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionFactory.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionFactory.java
index 990ac35e1b..ef9c87cef0 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionFactory.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionFactory.java
@@ -10,6 +10,7 @@
*/
package org.eclipse.emf.internal.cdo.session;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.session.CDOSession;
import org.eclipse.net4j.util.StringUtil;
@@ -19,6 +20,7 @@ import org.eclipse.emf.spi.cdo.InternalCDOSession;
import java.net.URI;
import java.net.URISyntaxException;
+import java.text.MessageFormat;
import java.util.HashMap;
import java.util.Map;
import java.util.StringTokenizer;
@@ -28,7 +30,7 @@ import java.util.StringTokenizer;
*/
public abstract class CDOSessionFactory extends Factory
{
- public static final String PRODUCT_GROUP = "org.eclipse.emf.cdo.sessions";
+ public static final String PRODUCT_GROUP = "org.eclipse.emf.cdo.sessions"; //$NON-NLS-1$
private static final String TRUE = Boolean.TRUE.toString();
@@ -45,11 +47,11 @@ public abstract class CDOSessionFactory extends Factory
String query = uri.getQuery();
if (StringUtil.isEmpty(query))
{
- throw new IllegalArgumentException("Query is empty: " + description);
+ throw new IllegalArgumentException(MessageFormat.format(Messages.getString("CDOSessionFactory.1"), description)); //$NON-NLS-1$
}
Map<String, String> result = new HashMap<String, String>();
- StringTokenizer tokenizer = new StringTokenizer(query, "&");
+ StringTokenizer tokenizer = new StringTokenizer(query, "&"); //$NON-NLS-1$
while (tokenizer.hasMoreTokens())
{
String parameter = tokenizer.nextToken();
@@ -59,7 +61,7 @@ public abstract class CDOSessionFactory extends Factory
if (pos == -1)
{
String key = parameter.trim();
- result.put(key, "");
+ result.put(key, ""); //$NON-NLS-1$
}
else
{
@@ -70,8 +72,8 @@ public abstract class CDOSessionFactory extends Factory
}
}
- String repositoryName = result.get("repositoryName");
- boolean automaticPackageRegistry = TRUE.equals(result.get("automaticPackageRegistry"));
+ String repositoryName = result.get("repositoryName"); //$NON-NLS-1$
+ boolean automaticPackageRegistry = TRUE.equals(result.get("automaticPackageRegistry")); //$NON-NLS-1$
return createSession(repositoryName, automaticPackageRegistry);
}
catch (URISyntaxException ex)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
index 120e91510e..176dacb19c 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
@@ -32,6 +32,7 @@ import org.eclipse.emf.cdo.common.revision.delta.CDORevisionDelta;
import org.eclipse.emf.cdo.common.util.CDOException;
import org.eclipse.emf.cdo.eresource.EresourcePackage;
import org.eclipse.emf.cdo.internal.common.model.CDOPackageRegistryImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.session.CDOCollectionLoadingPolicy;
import org.eclipse.emf.cdo.session.CDOSession;
import org.eclipse.emf.cdo.session.CDOSessionInvalidationEvent;
@@ -222,7 +223,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
{
if (!options().isGeneratedPackageEmulationEnabled())
{
- throw new CDOException("Generated packages locally not available: " + packageUnit);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOSessionImpl.0"), packageUnit)); //$NON-NLS-1$
}
}
@@ -532,7 +533,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
@Override
public String toString()
{
- return MessageFormat.format("CDOSession[{0}, {1}]", repository().getName(), sessionID);
+ return MessageFormat.format("CDOSession[{0}, {1}]", repository().getName(), sessionID); //$NON-NLS-1$
}
/**
@@ -596,8 +597,8 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
protected void doBeforeActivate() throws Exception
{
super.doBeforeActivate();
- checkState(getSessionProtocol(), "sessionProtocol");
- checkState(repository().getName(), "repository().getName()");
+ checkState(getSessionProtocol(), "sessionProtocol"); //$NON-NLS-1$
+ checkState(repository().getName(), "repository().getName()"); //$NON-NLS-1$
}
@Override
@@ -678,7 +679,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
String factoryName = libraryDescriptor.getFactoryName();
if (TRACER.isEnabled())
{
- TRACER.format("Using CDOID factory: {0}", factoryName);
+ TRACER.format("Using CDOID factory: {0}", factoryName); //$NON-NLS-1$
}
File cacheFolder = getCacheFolder();
@@ -705,10 +706,10 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
File lib = new File(cacheFolder, neededLibrary);
if (TRACER.isEnabled())
{
- TRACER.format("Using CDOID library: {0}", lib.getAbsolutePath());
+ TRACER.format("Using CDOID library: {0}", lib.getAbsolutePath()); //$NON-NLS-1$
}
- urls[i++] = new URL("file:///" + lib.getAbsolutePath());
+ urls[i++] = new URL("file:///" + lib.getAbsolutePath()); //$NON-NLS-1$
}
classLoader = new URLClassLoader(urls, classLoader);
@@ -719,7 +720,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
private File getCacheFolder()
{
String stateLocation = OM.BUNDLE.getStateLocation();
- File repos = new File(stateLocation, "repos");
+ File repos = new File(stateLocation, "repos"); //$NON-NLS-1$
return new File(repos, repository().getUUID());
}
@@ -728,7 +729,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
Set<String> set = new HashSet<String>();
for (String fileName : fileNames)
{
- if (fileName.endsWith(".jar"))
+ if (fileName.endsWith(".jar")) //$NON-NLS-1$
{
set.add(fileName);
}
@@ -759,7 +760,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
version = delta.getOriginVersion();
}
}
-
+
uniqueObjects.put(cdoId, CDOIDUtil.createIDAndVersion(cdoId, version));
}
}
@@ -911,7 +912,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
@Override
public String toString()
{
- return "DefaultRevisionFactory";
+ return "DefaultRevisionFactory"; //$NON-NLS-1$
}
};
}
@@ -1156,7 +1157,7 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
@Override
public String toString()
{
- return "CDOSessionInvalidationEvent: " + dirtyOIDs;
+ return "CDOSessionInvalidationEvent: " + dirtyOIDs; //$NON-NLS-1$
}
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/remote/CDORemoteSessionImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/remote/CDORemoteSessionImpl.java
index 4c7d71c41b..5ae1a5f204 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/remote/CDORemoteSessionImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/remote/CDORemoteSessionImpl.java
@@ -98,6 +98,6 @@ public class CDORemoteSessionImpl implements CDORemoteSession
@Override
public String toString()
{
- return MessageFormat.format("{0} ({1}", userID, sessionID);
+ return MessageFormat.format("{0} ({1}", userID, sessionID); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOSingleTransactionStrategyImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOSingleTransactionStrategyImpl.java
index b0a4a81e46..e6a957feaa 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOSingleTransactionStrategyImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOSingleTransactionStrategyImpl.java
@@ -46,7 +46,7 @@ public class CDOSingleTransactionStrategyImpl implements CDOTransactionStrategy
InternalCDOCommitContext commitContext = transaction.createCommitContext();
if (TRACER.isEnabled())
{
- TRACER.format("CDOCommitContext.preCommit");
+ TRACER.format("CDOCommitContext.preCommit"); //$NON-NLS-1$
}
commitContext.preCommit();
@@ -66,7 +66,7 @@ public class CDOSingleTransactionStrategyImpl implements CDOTransactionStrategy
if (TRACER.isEnabled())
{
- TRACER.format("CDOCommitContext.postCommit");
+ TRACER.format("CDOCommitContext.postCommit"); //$NON-NLS-1$
}
commitContext.postCommit(result);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOTransactionImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOTransactionImpl.java
index 0a6ba100f6..901728748d 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOTransactionImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOTransactionImpl.java
@@ -33,6 +33,7 @@ import org.eclipse.emf.cdo.eresource.CDOResourceNode;
import org.eclipse.emf.cdo.eresource.EresourceFactory;
import org.eclipse.emf.cdo.eresource.impl.CDOResourceImpl;
import org.eclipse.emf.cdo.eresource.impl.CDOResourceNodeImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageUnit;
import org.eclipse.emf.cdo.spi.common.revision.InternalCDORevisionDelta;
import org.eclipse.emf.cdo.transaction.CDOConflictResolver;
@@ -388,7 +389,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
}
else
{
- throw new CDOException("Not a ResourceFolder: " + node);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOTransactionImpl.0"), node)); //$NON-NLS-1$
}
}
@@ -495,7 +496,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
CDOID id = super.getRootOrTopLevelResourceNodeID(name);
if (getLastSavepoint().getAllDetachedObjects().containsKey(id) || getDirtyObjects().containsKey(id))
{
- throw new CDOException("Root resource node " + name + " doesn't exist");
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOTransactionImpl.1"), name)); //$NON-NLS-1$
}
return id;
@@ -559,7 +560,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
checkActive();
if (hasConflict())
{
- throw new TransactionException("This transaction has conflicts");
+ throw new TransactionException(Messages.getString("CDOTransactionImpl.2")); //$NON-NLS-1$
}
if (progressMonitor == null)
@@ -823,24 +824,24 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
{
if (savepoint == null)
{
- throw new IllegalArgumentException("Save point is null");
+ throw new IllegalArgumentException(Messages.getString("CDOTransactionImpl.3")); //$NON-NLS-1$
}
if (savepoint.getUserTransaction() != this)
{
- throw new IllegalArgumentException("Save point to rollback doesn't belong to this transaction: " + savepoint);
+ throw new IllegalArgumentException(MessageFormat.format(Messages.getString("CDOTransactionImpl.4"), savepoint)); //$NON-NLS-1$
}
if (TRACER.isEnabled())
{
- TRACER.trace("handleRollback()");
+ TRACER.trace("handleRollback()"); //$NON-NLS-1$
}
try
{
if (!savepoint.isValid())
{
- throw new IllegalArgumentException("Savepoint isn't valid : " + savepoint);
+ throw new IllegalArgumentException(MessageFormat.format(Messages.getString("CDOTransactionImpl.6"), savepoint)); //$NON-NLS-1$
}
// Use the state lock since rollback mechanism is playing with EObject and CDORevisions. We do not want to
@@ -931,14 +932,14 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
@Override
public String toString()
{
- return MessageFormat.format("CDOTransaction({0})", getViewID());
+ return MessageFormat.format("CDOTransaction({0})", getViewID()); //$NON-NLS-1$
}
public void registerNew(InternalCDOObject object)
{
if (TRACER.isEnabled())
{
- TRACER.format("Registering new object {0}", object);
+ TRACER.format("Registering new object {0}", object); //$NON-NLS-1$
}
registerNewPackage(object.eClass().getEPackage());
@@ -1015,7 +1016,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
{
if (TRACER.isEnabled())
{
- TRACER.format("Registering dirty object {0}", object);
+ TRACER.format("Registering dirty object {0}", object); //$NON-NLS-1$
}
if (featureDelta != null)
@@ -1035,7 +1036,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
Object old = map.put(object.cdoID(), object);
if (old != null)
{
- throw new ImplementationError("Duplicate ID: " + object);
+ throw new ImplementationError(MessageFormat.format(Messages.getString("CDOTransactionImpl.10"), object)); //$NON-NLS-1$
}
if (!dirty)
@@ -1101,7 +1102,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
CDOPackageUnit packageUnit = packageRegistry.getPackageUnit(usedPackage);
if (packageUnit == null)
{
- throw new CDOException("No package unit for " + usedPackage);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOTransactionImpl.11"), usedPackage)); //$NON-NLS-1$
}
if (packageUnit.getState() == CDOPackageUnit.State.NEW)
@@ -1249,7 +1250,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
{
if (TRACER.isEnabled())
{
- TRACER.trace("commit()");
+ TRACER.trace("commit()"); //$NON-NLS-1$
}
for (CDOTransactionHandler handler : getHandlers())
@@ -1393,7 +1394,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
@Override
public String toString()
{
- return MessageFormat.format("CDOTransactionStartedEvent[source={0}]", getSource());
+ return MessageFormat.format("CDOTransactionStartedEvent[source={0}]", getSource()); //$NON-NLS-1$
}
}
@@ -1427,7 +1428,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
@Override
public String toString()
{
- return MessageFormat.format("CDOTransactionFinishedEvent[source={0}, type={1}, idMappings={2}]", getSource(),
+ return MessageFormat.format("CDOTransactionFinishedEvent[source={0}, type={1}, idMappings={2}]", getSource(), //$NON-NLS-1$
getType(), idMappings == null ? 0 : idMappings.size());
}
}
@@ -1462,7 +1463,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
@Override
public String toString()
{
- return MessageFormat.format("CDOTransactionConflictEvent[source={0}, conflictingObject={1}, firstConflict={2}]",
+ return MessageFormat.format("CDOTransactionConflictEvent[source={0}, conflictingObject={1}, firstConflict={2}]", //$NON-NLS-1$
getSource(), getConflictingObject(), isFirstConflict());
}
}
@@ -1497,7 +1498,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
@Override
public String toString()
{
- return MessageFormat.format("CDOViewResourcesEvent[source={0}, {1}={2}]", getSource(), resourcePath, kind);
+ return MessageFormat.format("CDOViewResourcesEvent[source={0}, {1}={2}]", getSource(), resourcePath, kind); //$NON-NLS-1$
}
}
@@ -1601,7 +1602,7 @@ public class CDOTransactionImpl extends CDOViewImpl implements InternalCDOTransa
{
if (resolver.getTransaction() != null)
{
- throw new IllegalArgumentException("New conflict resolver is already associated with a transaction");
+ throw new IllegalArgumentException(Messages.getString("CDOTransactionImpl.17")); //$NON-NLS-1$
}
resolver.setTransaction(CDOTransactionImpl.this);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXACommitContextImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXACommitContextImpl.java
index 636fc9b1ad..b3d08602d8 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXACommitContextImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXACommitContextImpl.java
@@ -17,6 +17,7 @@ import org.eclipse.emf.cdo.common.revision.CDOReferenceAdjuster;
import org.eclipse.emf.cdo.common.revision.delta.CDORevisionDelta;
import org.eclipse.emf.cdo.eresource.CDOResource;
import org.eclipse.emf.cdo.internal.common.id.CDOIDExternalTempImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.util.CDOUtil;
import org.eclipse.emf.internal.cdo.transaction.CDOXATransactionImpl.CDOXAState;
@@ -32,6 +33,7 @@ import org.eclipse.emf.spi.cdo.InternalCDOXATransaction.InternalCDOXACommitConte
import org.eclipse.core.runtime.IProgressMonitor;
+import java.text.MessageFormat;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@@ -158,7 +160,7 @@ public class CDOXACommitContextImpl implements InternalCDOXACommitContext
}
else
{
- throw new ImplementationError("Object should be an EObject " + idOrObject);
+ throw new ImplementationError(MessageFormat.format(Messages.getString("CDOXACommitContextImpl.0"), idOrObject)); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXATransactionImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXATransactionImpl.java
index a289e23416..e27c4189ca 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXATransactionImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/transaction/CDOXATransactionImpl.java
@@ -12,6 +12,7 @@
package org.eclipse.emf.internal.cdo.transaction;
import org.eclipse.emf.cdo.common.id.CDOID;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.transaction.CDOSavepoint;
import org.eclipse.emf.cdo.transaction.CDOTransaction;
import org.eclipse.emf.cdo.transaction.CDOXATransaction;
@@ -39,6 +40,7 @@ import org.eclipse.core.runtime.IProgressMonitor;
import org.eclipse.core.runtime.NullProgressMonitor;
import org.eclipse.core.runtime.SubProgressMonitor;
+import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.Collection;
import java.util.HashMap;
@@ -131,7 +133,7 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
CDOXATransaction transSet = CDOUtil.getXATransaction(viewSet);
if (transSet != null)
{
- throw new IllegalArgumentException("XATransaction is already attached to this viewSet");
+ throw new IllegalArgumentException(Messages.getString("CDOXATransactionImpl.0")); //$NON-NLS-1$
}
viewSet.eAdapters().add(internalAdapter);
@@ -147,7 +149,7 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
CDOXATransaction transSet = CDOUtil.getXATransaction(viewSet);
if (transSet != this)
{
- throw new IllegalArgumentException("ViewSet isn't attached to this XATransaction");
+ throw new IllegalArgumentException(Messages.getString("CDOXATransactionImpl.1")); //$NON-NLS-1$
}
for (InternalCDOTransaction transaction : getTransactions(viewSet))
@@ -187,7 +189,7 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
private void send(Collection<CDOXACommitContextImpl> xaContexts, final IProgressMonitor progressMonitor)
throws InterruptedException, ExecutionException
{
- progressMonitor.beginTask("", xaContexts.size());
+ progressMonitor.beginTask("", xaContexts.size()); //$NON-NLS-1$
try
{
@@ -252,8 +254,8 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
public void commit(IProgressMonitor progressMonitor) throws TransactionException
{
- CheckUtil.checkArg(progressMonitor, "progressMonitor");
- progressMonitor.beginTask("Committing XA transaction", 3);
+ CheckUtil.checkArg(progressMonitor, "progressMonitor"); //$NON-NLS-1$
+ progressMonitor.beginTask(Messages.getString("CDOXATransactionImpl.4"), 3); //$NON-NLS-1$
int phase = 0;
for (InternalCDOTransaction transaction : transactions)
@@ -318,17 +320,17 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
{
if (savepoint == null)
{
- throw new IllegalArgumentException("Save point is null");
+ throw new IllegalArgumentException(Messages.getString("CDOXATransactionImpl.5")); //$NON-NLS-1$
}
if (savepoint.getUserTransaction() != this)
{
- throw new IllegalArgumentException("Save point to rollback doesn't belong to this transaction: " + savepoint);
+ throw new IllegalArgumentException(MessageFormat.format(Messages.getString("CDOXATransactionImpl.6"), savepoint)); //$NON-NLS-1$
}
if (!savepoint.isValid())
{
- throw new IllegalArgumentException("Savepoint isn't valid : " + savepoint);
+ throw new IllegalArgumentException(Messages.getString("CDOXATransactionImpl.7") + savepoint); //$NON-NLS-1$
}
CDOXASavepointImpl savepointSet = (CDOXASavepointImpl)savepoint;
@@ -406,7 +408,7 @@ public class CDOXATransactionImpl implements InternalCDOXATransaction
{
if (!allRequestEnabled)
{
- throw new IllegalStateException("Commit from CDOTransaction is not allowed.");
+ throw new IllegalStateException(Messages.getString("CDOXATransactionImpl.8")); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CompletePackageClosure.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CompletePackageClosure.java
index 01bc3fbeb7..07123f48cd 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CompletePackageClosure.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/CompletePackageClosure.java
@@ -11,6 +11,8 @@
*/
package org.eclipse.emf.internal.cdo.util;
+import org.eclipse.emf.cdo.messages.Messages;
+
import org.eclipse.emf.internal.cdo.bundle.OM;
import org.eclipse.net4j.util.om.trace.ContextTracer;
@@ -26,6 +28,7 @@ import org.eclipse.emf.ecore.EStructuralFeature;
import org.eclipse.emf.ecore.ETypeParameter;
import org.eclipse.emf.ecore.EcorePackage;
+import java.text.MessageFormat;
import java.util.HashSet;
import java.util.List;
import java.util.Set;
@@ -76,13 +79,13 @@ public class CompletePackageClosure extends PackageClosure
{
if (TRACER.isEnabled())
{
- TRACER.trace("Found package " + p.getNsURI());
+ TRACER.trace("Found package " + p.getNsURI()); //$NON-NLS-1$
}
}
}
else
{
- OM.LOG.warn("Package == null for " + eClass.getName());
+ OM.LOG.warn(MessageFormat.format(Messages.getString("CompletePackageClosure.0"), eClass.getName())); //$NON-NLS-1$
}
}
}
@@ -126,7 +129,7 @@ public class CompletePackageClosure extends PackageClosure
{
if (TRACER.isEnabled())
{
- TRACER.trace("Found class " + eClass.getName());
+ TRACER.trace("Found class " + eClass.getName()); //$NON-NLS-1$
}
handleEStructuralFeatures(eClass.getEStructuralFeatures(), visited);
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/FSMUtil.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/FSMUtil.java
index d4515e90bd..cea170ccb0 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/FSMUtil.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/FSMUtil.java
@@ -15,6 +15,7 @@ import org.eclipse.emf.cdo.CDOObject;
import org.eclipse.emf.cdo.CDOState;
import org.eclipse.emf.cdo.common.id.CDOID;
import org.eclipse.emf.cdo.common.revision.CDORevision;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageRegistry;
import org.eclipse.emf.cdo.util.InvalidObjectException;
import org.eclipse.emf.cdo.util.ObjectNotFoundException;
@@ -96,7 +97,7 @@ public final class FSMUtil
{
if (view.isClosed())
{
- throw new IllegalStateException("View closed");
+ throw new IllegalStateException(Messages.getString("FSMUtil.0")); //$NON-NLS-1$
}
if (object instanceof InternalCDOObject)
@@ -106,7 +107,7 @@ public final class FSMUtil
if (object == null)
{
- throw new IllegalArgumentException("object == null");
+ throw new IllegalArgumentException(Messages.getString("FSMUtil.1")); //$NON-NLS-1$
}
if (isMeta(object))
@@ -126,7 +127,7 @@ public final class FSMUtil
{
if (view == null)
{
- throw new IllegalArgumentException("view == null");
+ throw new IllegalArgumentException(Messages.getString("FSMUtil.2")); //$NON-NLS-1$
}
if (object.eIsProxy())
@@ -153,7 +154,7 @@ public final class FSMUtil
public static InternalCDOObject adaptLegacy(InternalEObject object)
{
// TODO LEGACY
- throw new UnsupportedOperationException("Legacy models not supported");
+ throw new UnsupportedOperationException(Messages.getString("FSMUtil.3")); //$NON-NLS-1$
// EList<InternalEObject.EReadListener> readListeners = object.eReadListeners();
// CDOLegacyWrapper wrapper = getLegacyWrapper(readListeners);
// if (wrapper == null)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/PackageClosure.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/PackageClosure.java
index 2ad5eb566f..a5acf0dbe2 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/PackageClosure.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/util/PackageClosure.java
@@ -59,7 +59,7 @@ public abstract class PackageClosure implements IPackageClosure
{
if (TRACER.isEnabled())
{
- TRACER.trace("Package closure for " + ePackage.getNsURI());
+ TRACER.trace("Package closure for " + ePackage.getNsURI()); //$NON-NLS-1$
}
collectContents(ePackage, visited);
for (EPackage subPackage : ePackage.getESubpackages())
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOAuditImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOAuditImpl.java
index d7429993c6..397ed699a4 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOAuditImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOAuditImpl.java
@@ -95,6 +95,6 @@ public class CDOAuditImpl extends CDOViewImpl implements CDOAudit
@Override
public String toString()
{
- return MessageFormat.format("CDOAudit({0})", getViewID());
+ return MessageFormat.format("CDOAudit({0})", getViewID()); //$NON-NLS-1$
}
}
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewImpl.java
index 6a5a40a1c5..20a65bfbb7 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewImpl.java
@@ -30,6 +30,7 @@ import org.eclipse.emf.cdo.eresource.CDOResourceFolder;
import org.eclipse.emf.cdo.eresource.CDOResourceNode;
import org.eclipse.emf.cdo.eresource.EresourcePackage;
import org.eclipse.emf.cdo.eresource.impl.CDOResourceImpl;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.spi.common.model.InternalCDOPackageRegistry;
import org.eclipse.emf.cdo.spi.common.revision.InternalCDORevision;
import org.eclipse.emf.cdo.transaction.CDOCommitContext;
@@ -351,7 +352,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
return (InternalCDOTransaction)this;
}
- throw new ReadOnlyException("CDO view is read-only: " + this);
+ throw new ReadOnlyException(MessageFormat.format(Messages.getString("CDOViewImpl.0"), this)); //$NON-NLS-1$
}
public boolean hasResource(String path)
@@ -406,7 +407,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (StringUtil.isEmpty(path))
{
- throw new IllegalArgumentException("path");
+ throw new IllegalArgumentException(Messages.getString("CDOViewImpl.1")); //$NON-NLS-1$
}
CDOID folderID = null;
@@ -434,7 +435,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
folderID = getResourceNodeID(folderID, name);
if (folderID == null)
{
- throw new CDOException("Can not find " + name);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.2"), name)); //$NON-NLS-1$
}
return folderID;
@@ -473,14 +474,14 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
if (name == null)
{
- throw new IllegalArgumentException("name");
+ throw new IllegalArgumentException(Messages.getString("CDOViewImpl.3")); //$NON-NLS-1$
}
InternalCDORevision folderRevision = getLocalRevision(folderID);
EClass resourceFolderClass = EresourcePackage.eINSTANCE.getCDOResourceFolder();
if (folderRevision.getEClass() != resourceFolderClass)
{
- throw new CDOException("Expected folder for id = " + folderID);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.4"), folderID)); //$NON-NLS-1$
}
EReference nodesFeature = EresourcePackage.eINSTANCE.getCDOResourceFolder_Nodes();
@@ -499,7 +500,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
}
}
- throw new CDOException("Node " + name + " not found");
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.5"), name)); //$NON-NLS-1$
}
/**
@@ -514,18 +515,18 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (name == null)
{
- throw new CDOException("No root ResourceNode");
+ throw new CDOException(Messages.getString("CDOViewImpl.6")); //$NON-NLS-1$
}
else
{
- throw new CDOException("No top level ResourceNode with the name " + name);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.7"), name)); //$NON-NLS-1$
}
}
if (ids.size() > 1)
{
// TODO is this still needed since the is resourceQuery.setMaxResults(1) ??
- throw new ImplementationError("Duplicate top-level ResourceNodes");
+ throw new ImplementationError(Messages.getString("CDOViewImpl.8")); //$NON-NLS-1$
}
return ids.get(0);
@@ -550,7 +551,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
if (revision == null)
{
- throw new CDOException("Cannot find revision with ID " + id);
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.9"), id)); //$NON-NLS-1$
}
return revision;
@@ -651,7 +652,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (CDOIDUtil.isNull(resourceID))
{
- throw new IllegalArgumentException("resourceID: " + resourceID);
+ throw new IllegalArgumentException("resourceID: " + resourceID); //$NON-NLS-1$
}
return (CDOResourceImpl)getObject(resourceID);
@@ -741,7 +742,8 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (view.getSession() != session)
{
- throw new IllegalArgumentException("Object is contaiuned in a different session: " + objectFromDifferentView);
+ throw new IllegalArgumentException(MessageFormat.format(
+ Messages.getString("CDOViewImpl.11"), objectFromDifferentView)); //$NON-NLS-1$
}
CDOID id = object.cdoID();
@@ -787,7 +789,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (TRACER.isEnabled())
{
- TRACER.trace("Creating meta object for " + id);
+ TRACER.trace("Creating meta object for " + id); //$NON-NLS-1$
}
InternalCDOPackageRegistry packageRegistry = session.getPackageRegistry();
@@ -802,7 +804,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (TRACER.isEnabled())
{
- TRACER.trace("Creating object for " + id);
+ TRACER.trace("Creating object for " + id); //$NON-NLS-1$
}
InternalCDORevision revision = getRevision(id, true);
@@ -855,7 +857,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
return path + CDOURIUtil.SEGMENT_SEPARATOR + name;
}
- throw new ImplementationError("Not a ResourceFolder: " + object);
+ throw new ImplementationError(MessageFormat.format(Messages.getString("CDOViewImpl.14"), object)); //$NON-NLS-1$
}
/**
@@ -881,7 +883,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
CDOID id = (CDOID)shouldBeCDOID;
if (TRACER.isEnabled() && id != idOrObject)
{
- TRACER.format("Converted object to CDOID: {0} --> {1}", idOrObject, id);
+ TRACER.format("Converted object to CDOID: {0} --> {1}", idOrObject, id); //$NON-NLS-1$
}
return id;
@@ -907,7 +909,8 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
throw new DanglingReferenceException(eObject);
}
- throw new IllegalStateException("Unable to provideCDOID: " + idOrObject.getClass().getName());
+ throw new IllegalStateException(MessageFormat.format(
+ Messages.getString("CDOViewImpl.16"), idOrObject.getClass().getName())); //$NON-NLS-1$
}
public Object convertObjectToID(Object potentialObject)
@@ -983,7 +986,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
InternalCDOObject result = getObject(id, true);
if (result == null)
{
- throw new ImplementationError("ID not registered: " + id);
+ throw new ImplementationError(MessageFormat.format(Messages.getString("CDOViewImpl.17"), id)); //$NON-NLS-1$
}
return result.cdoInternalInstance();
@@ -999,7 +1002,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (!resource.isExisting())
{
- throw new ReadOnlyException("CDO view is read-only: " + this);
+ throw new ReadOnlyException(MessageFormat.format(Messages.getString("CDOViewImpl.18"), this)); //$NON-NLS-1$
}
// ResourceSet.getResource(uri, true) was called!!
@@ -1031,7 +1034,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (TRACER.isEnabled())
{
- TRACER.format("Registering {0}", object);
+ TRACER.format("Registering {0}", object); //$NON-NLS-1$
}
InternalCDOObject old;
@@ -1042,7 +1045,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
if (old != null)
{
- throw new IllegalStateException("Duplicate ID: " + object);
+ throw new IllegalStateException(MessageFormat.format(Messages.getString("CDOViewImpl.20"), object)); //$NON-NLS-1$
}
}
@@ -1050,7 +1053,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
{
if (TRACER.isEnabled())
{
- TRACER.format("Deregistering {0}", object);
+ TRACER.format("Deregistering {0}", object); //$NON-NLS-1$
}
removeObject(object.cdoID());
@@ -1068,7 +1071,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
if (TRACER.isEnabled())
{
- TRACER.format("Remapping {0} --> {1}", oldID, newID);
+ TRACER.format("Remapping {0} --> {1}", oldID, newID); //$NON-NLS-1$
}
}
@@ -1388,7 +1391,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
@Override
public String toString()
{
- return MessageFormat.format("CDOView({0})", viewID);
+ return MessageFormat.format("CDOView({0})", viewID); //$NON-NLS-1$
}
public boolean isAdapterForType(Object type)
@@ -1416,8 +1419,8 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
protected void doBeforeActivate() throws Exception
{
super.doBeforeActivate();
- checkState(session, "session");
- checkState(viewID > 0, "viewID");
+ checkState(session, "session"); //$NON-NLS-1$
+ checkState(viewID > 0, "viewID"); //$NON-NLS-1$
}
/**
@@ -1463,7 +1466,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
return CDOProtocolConstants.VIEW_AUDIT;
default:
- throw new IllegalStateException("Invalid view type: " + viewType);
+ throw new IllegalStateException(MessageFormat.format(Messages.getString("CDOViewImpl.26"), viewType)); //$NON-NLS-1$
}
}
@@ -1715,7 +1718,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
InternalCDOObject internalCDOObject = FSMUtil.adapt(eObject, CDOViewImpl.this);
if (internalCDOObject.cdoView() != CDOViewImpl.this)
{
- throw new CDOException("Object " + internalCDOObject + " doesn`t belong to this view.");
+ throw new CDOException(MessageFormat.format(Messages.getString("CDOViewImpl.27"), internalCDOObject)); //$NON-NLS-1$
}
subscribe(internalCDOObject.cdoID(), internalCDOObject, adjust);
@@ -1878,7 +1881,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
@Override
public String toString()
{
- return "CDOViewInvalidationEvent: " + dirtyObjects;
+ return "CDOViewInvalidationEvent: " + dirtyObjects; //$NON-NLS-1$
}
}
@@ -2031,7 +2034,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
return ReferenceType.WEAK;
}
- throw new IllegalStateException("referenceType");
+ throw new IllegalStateException(Messages.getString("CDOViewImpl.29")); //$NON-NLS-1$
}
public boolean setCacheReferenceType(ReferenceType referenceType)
@@ -2072,7 +2075,7 @@ public class CDOViewImpl extends Lifecycle implements InternalCDOView
break;
default:
- throw new IllegalArgumentException("referenceType");
+ throw new IllegalArgumentException(Messages.getString("CDOViewImpl.29")); //$NON-NLS-1$
}
if (objects == null)
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewProviderRegistryImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewProviderRegistryImpl.java
index e533b31933..4ffe7b3e32 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewProviderRegistryImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewProviderRegistryImpl.java
@@ -11,6 +11,7 @@
*/
package org.eclipse.emf.internal.cdo.view;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.util.CDOURIUtil;
import org.eclipse.emf.cdo.util.CDOUtil;
import org.eclipse.emf.cdo.view.AbstractCDOViewProvider;
@@ -34,6 +35,7 @@ import org.eclipse.core.runtime.IConfigurationElement;
import org.eclipse.core.runtime.IExtensionRegistry;
import org.eclipse.core.runtime.Platform;
+import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Comparator;
@@ -51,7 +53,7 @@ public class CDOViewProviderRegistryImpl extends Container<CDOViewProvider> impl
{
public static final CDOViewProviderRegistryImpl INSTANCE = new CDOViewProviderRegistryImpl();
- private static final String EXT_POINT = "viewProviders";
+ private static final String EXT_POINT = "viewProviders"; //$NON-NLS-1$
private List<CDOViewProvider> viewProviders = new ArrayList<CDOViewProvider>();
@@ -249,17 +251,19 @@ public class CDOViewProviderRegistryImpl extends Container<CDOViewProvider> impl
public CDOViewProviderDescriptor(IConfigurationElement element)
{
- super(element.getAttribute("regex"), Integer.parseInt(element.getAttribute("priority")));
+ super(element.getAttribute("regex"), Integer.parseInt(element.getAttribute("priority"))); //$NON-NLS-1$ //$NON-NLS-2$
this.element = element;
- if (StringUtil.isEmpty(element.getAttribute("class")))
+ if (StringUtil.isEmpty(element.getAttribute("class"))) //$NON-NLS-1$
{
- throw new IllegalArgumentException("class not defined for extension " + element);
+ throw new IllegalArgumentException(MessageFormat.format(
+ Messages.getString("CDOViewProviderRegistryImpl.4"), element)); //$NON-NLS-1$
}
- if (StringUtil.isEmpty(element.getAttribute("regex")))
+ if (StringUtil.isEmpty(element.getAttribute("regex"))) //$NON-NLS-1$
{
- throw new IllegalArgumentException("regex not defined for extension " + element);
+ throw new IllegalArgumentException(MessageFormat.format(
+ Messages.getString("CDOViewProviderRegistryImpl.6"), element)); //$NON-NLS-1$
}
}
@@ -272,7 +276,7 @@ public class CDOViewProviderRegistryImpl extends Container<CDOViewProvider> impl
{
try
{
- return (CDOViewProvider)element.createExecutableExtension("class");
+ return (CDOViewProvider)element.createExecutableExtension("class"); //$NON-NLS-1$
}
catch (CoreException ex)
{
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewSetImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewSetImpl.java
index 5395adc862..abea7941f3 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewSetImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOViewSetImpl.java
@@ -14,6 +14,7 @@ package org.eclipse.emf.internal.cdo.view;
import org.eclipse.emf.cdo.common.protocol.CDOProtocolConstants;
import org.eclipse.emf.cdo.eresource.CDOResource;
import org.eclipse.emf.cdo.eresource.CDOResourceFactory;
+import org.eclipse.emf.cdo.messages.Messages;
import org.eclipse.emf.cdo.view.CDOView;
import org.eclipse.emf.common.notify.Notification;
@@ -27,6 +28,7 @@ import org.eclipse.emf.ecore.resource.Resource.Factory.Registry;
import org.eclipse.emf.spi.cdo.InternalCDOView;
import org.eclipse.emf.spi.cdo.InternalCDOViewSet;
+import java.text.MessageFormat;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.HashSet;
@@ -91,7 +93,8 @@ public class CDOViewSetImpl extends NotifierImpl implements InternalCDOViewSet
{
if (repositoryUUID != null)
{
- throw new IllegalArgumentException("Cannot find associated CDOView for repository " + repositoryUUID);
+ throw new IllegalArgumentException(MessageFormat.format(
+ Messages.getString("CDOViewSetImpl.0"), repositoryUUID)); //$NON-NLS-1$
}
if (mapOfViews.size() == 1)
@@ -104,7 +107,7 @@ public class CDOViewSetImpl extends NotifierImpl implements InternalCDOViewSet
return null;
}
- throw new IllegalStateException("Don't know which CDOView to take since no authority has been specified");
+ throw new IllegalStateException(Messages.getString("CDOViewSetImpl.1")); //$NON-NLS-1$
}
}
@@ -127,7 +130,7 @@ public class CDOViewSetImpl extends NotifierImpl implements InternalCDOViewSet
CDOView lookupView = mapOfViews.get(repositoryUUID);
if (lookupView != null)
{
- throw new RuntimeException("Only one view per repository can be open for the same resource set");
+ throw new RuntimeException(Messages.getString("CDOViewSetImpl.2")); //$NON-NLS-1$
}
views.add(view);
@@ -181,12 +184,12 @@ public class CDOViewSetImpl extends NotifierImpl implements InternalCDOViewSet
{
if (!isAdapterForType(newTarget))
{
- throw new IllegalArgumentException("Unsupported target: " + newTarget);
+ throw new IllegalArgumentException(MessageFormat.format(Messages.getString("CDOViewSetImpl.3"), newTarget)); //$NON-NLS-1$
}
if (resourceSet != null)
{
- throw new IllegalStateException("Cannot associate more than 1 resource set with this view set");
+ throw new IllegalStateException(Messages.getString("CDOViewSetImpl.4")); //$NON-NLS-1$
}
resourceSet = (ResourceSet)newTarget;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/PluginContainerViewProvider.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/PluginContainerViewProvider.java
index 51d62e8db7..832a9ee7d8 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/PluginContainerViewProvider.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/PluginContainerViewProvider.java
@@ -32,7 +32,7 @@ import org.eclipse.emf.ecore.resource.ResourceSet;
*/
public class PluginContainerViewProvider extends ManagedContainerViewProvider implements CDOViewProvider
{
- private final static String REGEX = "cdo:.*";
+ private final static String REGEX = "cdo:.*"; //$NON-NLS-1$
private final static int PRIORITY = 400;

Back to the top