1 /*******************************************************************************
2 * Copyright (c) 2009, 2010 Ericsson
4 * All rights reserved. This program and the accompanying materials are
5 * made available under the terms of the Eclipse Public License v1.0 which
6 * accompanies this distribution, and is available at
7 * http://www.eclipse.org/legal/epl-v10.html
10 * Alvaro Sanchez-Leon (alvsan09@gmail.com) - Initial API and implementation
11 *******************************************************************************/
12 package org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.test
.stub
.adaption
;
14 import java
.util
.HashMap
;
17 import org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.TimeGraphPresentationProvider
;
18 import org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.model
.ITimeEvent
;
19 import org
.eclipse
.linuxtools
.tmf
.ui
.widgets
.timegraph
.test
.stub
.model
.EventImpl
;
21 @SuppressWarnings("nls")
22 public class TsfImplProvider
extends TimeGraphPresentationProvider
{
24 // ========================================================================
26 // ========================================================================
28 public int getStateTableIndex(ITimeEvent event
) {
33 public Map
<String
, String
> getEventHoverToolTipInfo(ITimeEvent revent
) {
34 Map
<String
, String
> toolTipEventMsgs
= new HashMap
<String
, String
>();
35 if (revent
instanceof EventImpl
) {
36 toolTipEventMsgs
.put("Test Tip1", "Test Value tip1");
37 toolTipEventMsgs
.put("Test Tip2", "Test Value tip2");
40 return toolTipEventMsgs
;
44 public String
getEventName(ITimeEvent event
) {
45 String name
= "Unknown";
46 if (event
instanceof EventImpl
) {
47 EventImpl devent
= (EventImpl
) event
;
48 name
= devent
.getType().toString();