1 /*******************************************************************************
2 * Copyright (c) 2000, 2003 IBM Corporation and others.
3 * All rights reserved. This program and the accompanying materials
4 * are made available under the terms of the Common Public License v1.0
5 * which accompanies this distribution, and is available at
6 * http://www.eclipse.org/legal/cpl-v10.html
9 * IBM Corporation - initial API and implementation
10 *******************************************************************************/
11 package net.sourceforge.phpdt.internal.debug.core.logview;
13 import org.eclipse.jface.viewers.IStructuredContentProvider;
14 import org.eclipse.jface.viewers.ITreeContentProvider;
15 import org.eclipse.jface.viewers.Viewer;
17 public class LogViewContentProvider
18 implements ITreeContentProvider, IStructuredContentProvider {
19 private LogView logView;
21 public LogViewContentProvider(LogView logView) {
22 this.logView = logView;
24 public void dispose() {
26 public Object[] getChildren(Object element) {
27 return ((LogEntry) element).getChildren(element);
29 public Object[] getElements(Object element) {
30 return logView.getLogs();
32 public Object getParent(Object element) {
33 return ((LogEntry) element).getParent(element);
35 public boolean hasChildren(Object element) {
36 return ((LogEntry) element).hasChildren();
38 public void inputChanged(Viewer viewer, Object oldInput, Object newInput) {
40 public boolean isDeleted(Object element) {