/*******************************************************************************
- * Copyright (c) 2009, 2010 Ericsson
+ * Copyright (c) 2009 Ericsson
*
* All rights reserved. This program and the accompanying materials are
* made available under the terms of the Eclipse Public License v1.0 which
package org.eclipse.linuxtools.tmf.ui.views;
import org.eclipse.linuxtools.tmf.component.ITmfComponent;
-import org.eclipse.linuxtools.tmf.signal.TmfSignal;
import org.eclipse.linuxtools.tmf.signal.TmfSignalManager;
import org.eclipse.swt.widgets.Composite;
import org.eclipse.ui.part.ViewPart;
/**
- * <b><u>TmfView</u></b>
+ * <b><u>TmfViewer</u></b>
* <p>
* TODO: Implement me. Please.
*/
public abstract class TmfView extends ViewPart implements ITmfComponent {
- private final String fName;
-
- // ------------------------------------------------------------------------
- // Constructor
- // ------------------------------------------------------------------------
-
- public TmfView(String viewName) {
- super();
- fName = viewName;
- TmfSignalManager.register(this);
+ /**
+ * Constructor
+ */
+ public TmfView() {
+ TmfSignalManager.addListener(this);
}
+ /**
+ * Destructor
+ */
@Override
public void dispose() {
- TmfSignalManager.deregister(this);
- super.dispose();
- }
-
- // ------------------------------------------------------------------------
- // ITmfComponent
- // ------------------------------------------------------------------------
-
- public String getName() {
- return fName;
- }
-
- public void broadcast(TmfSignal signal) {
- TmfSignalManager.dispatchSignal(signal);
+ TmfSignalManager.removeListener(this);
}
- // ------------------------------------------------------------------------
- // ViewPart
- // ------------------------------------------------------------------------
-
+ /* (non-Javadoc)
+ * @see org.eclipse.ui.part.WorkbenchPart#createPartControl(org.eclipse.swt.widgets.Composite)
+ */
@Override
public void createPartControl(Composite parent) {
// TODO Auto-generated method stub
}
+ /* (non-Javadoc)
+ * @see org.eclipse.ui.part.WorkbenchPart#setFocus()
+ */
@Override
public void setFocus() {
// TODO Auto-generated method stub
}
-}
\ No newline at end of file
+}