alvinalexander.com | career | drupal | java | mac | mysql | perl | scala | uml | unix  

What this is

This file is included in the DevDaily.com "Java Source Code Warehouse" project. The intent of this project is to help you "Learn Java by Example" TM.

Other links

The source code

/*******************************************************************************
 * Copyright (c) 2000, 2006 IBM Corporation and others.
 * All rights reserved. This program and the accompanying materials
 * 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:
 *     IBM Corporation - initial API and implementation
 *******************************************************************************/
package org.eclipse.ui;

import org.eclipse.ui.services.IServiceLocator;

/**
 * <p>
 * A service that is capable of nesting other services within itself.  This 
 * allows lower level components to query for a service provider in a 
 * hierarchical fashion, and for information to be resolved in a hierarchical
 * manner
 * </p>
 * <p>
 * This interface is not intended to be implemented or extended by clients.
 * </p>
 * 
 * @since 2.1.3
 * @deprecated This is now handled by {@link IServiceLocator} which can
 * be nested.
 * @noimplement This interface is not intended to be implemented by clients.
 */
public interface INestableKeyBindingService extends IKeyBindingService {

    /**
     * Marks the service associated with <code>nestedSite as active if
     * one exists.  If there is no service associated, then nothing changes.
     * Calling this method with <code>null forces deactivation of the
     * current service.
     * 
     * @param nestedSite The site whose service should be activated; 
     * <code>null if the current service should be deactivated.
     * @return <code>true if a service is activated (or deactivated, in
     * the case of a <code>null parameter); false if
     * nothing changed.
     */
    public boolean activateKeyBindingService(IWorkbenchSite nestedSite);

    /**
     * An accessor for the nested key binding service associated with a
     * particular site.  If the key binding service does not exist for this
     * <code>nestedSite already, then a new one should be constructed.
     * 
     * @param nestedSite The site for which the service should be found; 
     * should not be <code>null.
     * @return The associated service, if any; or a new associated service, if
     * none existed previously.
     */
    public IKeyBindingService getKeyBindingService(IWorkbenchSite nestedSite);

    /**
     * Removes a nested key binding service from this key binding service.  The
     * service to remove is determined by the <code>nestedSite with
     * which it is associated.
     * 
     * @param nestedSite The site from which to remove the nested service.
     * This site must not be <code>null.
     * @return <code>true if the service existed and could be removed; 
     * <code>false otherwise.
     */
    public boolean removeKeyBindingService(IWorkbenchSite nestedSite);

}
... this post is sponsored by my books ...

#1 New Release!

FP Best Seller

 

new blog posts

 

Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.

A percentage of advertising revenue from
pages under the /java/jwarehouse URI on this website is
paid back to open source projects.