KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > eclipse > ui > internal > contexts > ContextManagerFactory


1 /*******************************************************************************
2  * Copyright (c) 2000, 2005 IBM Corporation and others.
3  * All rights reserved. This program and the accompanying materials
4  * are made available under the terms of the Eclipse Public License v1.0
5  * which accompanies this distribution, and is available at
6  * http://www.eclipse.org/legal/epl-v10.html
7  *
8  * Contributors:
9  * IBM Corporation - initial API and implementation
10  *******************************************************************************/

11
12 package org.eclipse.ui.internal.contexts;
13
14 import org.eclipse.core.commands.contexts.ContextManager;
15
16 /**
17  * This class allows clients to broker instances of <code>IContextManager</code>.
18  * <p>
19  * This class is not intended to be extended by clients.
20  * </p>
21  *
22  * @since 3.0
23  */

24 public final class ContextManagerFactory {
25
26     /**
27      * Creates a new instance of <code>ContextManagerWrapper</code>.
28      *
29      * @param contextManager
30      * The context manager that this context manager wrapper should
31      * wrap; must not be <code>null</code>.
32      * @return a new instance of <code>ContextManagerWrapper</code>. Clients
33      * should not make assumptions about the concrete implementation
34      * outside the contract of the interface. Guaranteed not to be
35      * <code>null</code>.
36      */

37     public static final ContextManagerLegacyWrapper getContextManagerWrapper(
38             final ContextManager contextManager) {
39         return new ContextManagerLegacyWrapper(contextManager);
40     }
41
42     /**
43      * This class should not be constructed.
44      */

45     private ContextManagerFactory() {
46         // Should not be called.
47
}
48 }
49
Popular Tags