diff options
author | Christian W. Damus | 2013-11-06 22:29:16 +0000 |
---|---|---|
committer | Eike Stepper | 2013-11-12 12:56:20 +0000 |
commit | 452e6c6a3919d55c3074eb02aba46ec24081c487 (patch) | |
tree | 4dafb737595ef27e6c122931ef1d48b3e00be2a0 /plugins/org.eclipse.emf.cdo.server.ocl | |
parent | f4f414bc196a8359700c6e174f3af97f5dc79ba2 (diff) | |
download | cdo-452e6c6a3919d55c3074eb02aba46ec24081c487.tar.gz cdo-452e6c6a3919d55c3074eb02aba46ec24081c487.tar.xz cdo-452e6c6a3919d55c3074eb02aba46ec24081c487.zip |
[418454] [Admin] Client API and UI for managing repositories in a server
https://bugs.eclipse.org/bugs/show_bug.cgi?id=418454
Prompt the user to confirm deletion of a repository if any users are currently connected to it. This uses a new reusable confirmation signal API, including confirmation providers, after the fashion of the authentication signal and credentials providers.
Also added the "Manage Security" action to repositories in the CDO Administration view. This uses an alternative handler targeting an admin-repository, which opens a new session if an open session doesn't already exist that is logged in as the administrator.
Change-Id: Ib8d7e7d0237f9426158f5a9af57782b8515531cc
Also-by: Eike Stepper <stepper@esc-net.de>
Diffstat (limited to 'plugins/org.eclipse.emf.cdo.server.ocl')
-rw-r--r-- | plugins/org.eclipse.emf.cdo.server.ocl/src/org/eclipse/emf/cdo/server/ocl/CDOAdditionalOperation.java | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/plugins/org.eclipse.emf.cdo.server.ocl/src/org/eclipse/emf/cdo/server/ocl/CDOAdditionalOperation.java b/plugins/org.eclipse.emf.cdo.server.ocl/src/org/eclipse/emf/cdo/server/ocl/CDOAdditionalOperation.java index 88314786e6..64a4874e3b 100644 --- a/plugins/org.eclipse.emf.cdo.server.ocl/src/org/eclipse/emf/cdo/server/ocl/CDOAdditionalOperation.java +++ b/plugins/org.eclipse.emf.cdo.server.ocl/src/org/eclipse/emf/cdo/server/ocl/CDOAdditionalOperation.java @@ -4,7 +4,7 @@ * are made available under the terms of the Eclipse Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/epl-v10.html - * + * * Contributors: * Christian W. Damus (CEA LIST) - initial API and implementation */ @@ -29,6 +29,7 @@ import org.eclipse.ocl.ecore.TypeType; import org.eclipse.ocl.expressions.CollectionKind; import org.eclipse.ocl.utilities.TypedElement; +import java.util.ArrayList; import java.util.Collection; import java.util.Collections; import java.util.Iterator; @@ -39,7 +40,7 @@ import java.util.regex.Pattern; /** * Additional operations for use in OCL queries in the CDO context. - * + * * @author Christian W. Damus * @since 4.2 */ @@ -144,7 +145,7 @@ abstract class CDOAdditionalOperation extends AdapterImpl * The <tt>cdoAllContents</tt> operation that collects all of the proper (non-cross-resource-contained) * elements within a {@link CDOResource} or an {@link EObject}. An optional argument filters the result * to instances of a particular model class. - * + * * @author Christian W. Damus */ private static class AllProperContents extends CDOAdditionalOperation @@ -174,7 +175,7 @@ abstract class CDOAdditionalOperation extends AdapterImpl @Override protected Object evaluate(CDOEvaluationEnvironment evalEnv, Object source, Object[] arguments) { - Collection<EObject> result = new java.util.ArrayList<EObject>(); + Collection<EObject> result = new ArrayList<EObject>(); // Only resources and EObjects have contents Iterator<EObject> iter; @@ -237,9 +238,9 @@ abstract class CDOAdditionalOperation extends AdapterImpl } /** - * The <tt>cdoMatches</tt> operation queries whether a regular expression matches aany string-valued + * The <tt>cdoMatches</tt> operation queries whether a regular expression matches aany string-valued * attribute of an {@link EObject}. - * + * * @author Christian W. Damus */ private static class MatchesAnyStringAttribute extends CDOAdditionalOperation @@ -323,7 +324,6 @@ abstract class CDOAdditionalOperation extends AdapterImpl } Matcher result = matcherCache.get(regex); - if (result == null) { result = Pattern.compile(regex).matcher(""); //$NON-NLS-1$ @@ -341,7 +341,6 @@ abstract class CDOAdditionalOperation extends AdapterImpl } List<EAttribute> result = stringAttributes.get(eClass); - if (result == null) { for (EAttribute next : eClass.getEAllAttributes()) @@ -351,7 +350,7 @@ abstract class CDOAdditionalOperation extends AdapterImpl { if (result == null) { - result = new java.util.ArrayList<EAttribute>(); + result = new ArrayList<EAttribute>(); } result.add(next); } |