1 /******************************************************************************* 2 * Copyright (c) 2009 Freescale Semiconductor and others. 3 * 4 * This program and the accompanying materials 5 * are made available under the terms of the Eclipse Public License 2.0 6 * which accompanies this distribution, and is available at 7 * https://www.eclipse.org/legal/epl-2.0/ 8 * 9 * SPDX-License-Identifier: EPL-2.0 10 * 11 * Contributors: 12 * Freescale Semiconductor - initial API and implementation � Bug 241336 13 *******************************************************************************/ 14 package org.eclipse.debug.internal.ui.viewers.model.provisional; 15 16 import org.eclipse.jface.viewers.TreePath; 17 18 /** 19 * A model proxy factory creates model proxies for elements based on 20 * specific presentation contexts. A model proxy factory is provided for 21 * a model element by registering a model proxy factory adapter for 22 * an element. 23 * <p> 24 * This interface is an alternative to the {@link IModelProxyFactory} 25 * interface. Unlike its predecessor <code>IModelProxyFactory2</code> allows 26 * the full path to the tree element to be specified when creating an 27 * <code>IModelProxy<code> instance. Using the full patch allows models to 28 * provide proper model deltas even if the root element of this proxy is at 29 * variable or unknown location in the viewer. 30 * </p> 31 * <p> 32 * Clients may implement this interface. 33 * </p> 34 * @see IModelProxyFactory 35 * @see IModelProxy 36 * @see IModelDelta 37 * 38 * @since 3.6 39 */ 40 public interface IModelProxyFactory2 { 41 /** 42 * Creates and returns a model proxy for the given element in the specified 43 * context or <code>null</code> if none. 44 * 45 * @param input viewer input context 46 * @param path to model element to create a model proxy for 47 * @param context presentation context 48 * @return model proxy or <code>null</code> 49 */ createTreeModelProxy(Object input, TreePath path, IPresentationContext context)50 IModelProxy createTreeModelProxy(Object input, TreePath path, IPresentationContext context); 51 } 52