1 /******************************************************************************* 2 * Copyright (c) 2006 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 package org.eclipse.debug.internal.ui.viewers.provisional; 12 13 /** 14 * An adapter used to create column presentations. 15 * 16 * @see IColumnPresentation 17 * @since 3.2 18 */ 19 public interface IColumnPresentationFactoryAdapter { 20 21 /** 22 * Constructs and returns the column presentation for the given presentation 23 * context (view) and input element, or <code>null</code> of none. 24 * 25 * @param context presentation context 26 * @param element the input element 27 * @return column presentation or <code>null</code> 28 */ 29 public IColumnPresentation createColumnPresentation(IPresentationContext context, Object element); 30 31 /** 32 * Returns the type of column presentation to be used for the given context and object 33 * or <code>null</code> if none. Allows a previous column presentation to be re-used if 34 * it has not changed type. 35 * 36 * @param context presentation context 37 * @param element input element 38 * @return column presentation id or <code>null</code> 39 */ 40 public String getColumnPresentationId(IPresentationContext context, Object element); 41 } 42