b5100c5a811771a58f35fa680e3434c7fde2372e
1 /*******************************************************************************
2 * Copyright (c) 2009 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
.lttng
.ui
.model
.trange
;
14 import java
.util
.Vector
;
16 import org
.eclipse
.linuxtools
.tmf
.ui
.viewers
.timeAnalysis
.model
.ITmfTimeAnalysisEntry
;
18 public class TimeRangeComposite
extends TimeRangeComponent
implements
19 ITmfTimeAnalysisEntry
{
21 // ========================================================================
23 // =======================================================================
25 * Type of Composites or Containers
27 * PROPERTY: Refers to a sub-composite of a RESOURCE or a PROCESS e.g the
28 * cpu which can vary over time and can have time range events associated to
29 * it, and at the same time PROPERTY is associated to a Composite parent
33 * PROCESS: A composite of time range events representing a Process
36 * RESOURCE: A composite of time range events representing a resource i.g.
37 * irq, softIrq, trap, bdev, cpu
43 public static enum CompositeType
{
44 UNKNOWN
, PROPERTY
, PROCESS
, RESOURCE
47 protected final Vector
<TimeRangeComponent
> ChildEventLeafs
= new Vector
<TimeRangeComponent
>();
48 protected final Vector
<TimeRangeComponent
> ChildEventComposites
= new Vector
<TimeRangeComponent
>();
49 protected Integer id
= 0;
50 protected String name
;
51 protected String groupName
= "";
52 protected String className
= "";
53 protected CompositeType contType
= CompositeType
.UNKNOWN
;
55 // ========================================================================
57 // =======================================================================
58 public TimeRangeComposite(Integer id
, Long stime
, Long etime
, String name
, CompositeType type
) {
59 super(stime
, etime
, null);
65 public TimeRangeComposite(Integer id
, Long stime
, Long etime
, String name
, String groupName
, String className
, CompositeType type
) {
66 this(id
, stime
, etime
, name
, type
);
68 this.groupName
= groupName
;
69 this.className
= className
;
73 // ========================================================================
75 // =======================================================================
81 * org.eclipse.linuxtools.lttng.ui.model.trange.TimeRangeComponent#getName()
84 public String
getName() {
91 public void setName(String name
) {
98 * @seeorg.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.
99 * ITmfTimeAnalysisEntry#getGroupName()
101 public String
getGroupName() {
108 public void setGroupName(String groupName
) {
109 this.groupName
= groupName
;
115 * @seeorg.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.
116 * ITmfTimeAnalysisEntry#getId()
125 public void setId(int id
) {
132 public String
getClassName() {
139 public void setClassName(String className
) {
140 this.className
= className
;
146 * @seeorg.eclipse.linuxtools.tmf.ui.viewers.timeAnalysis.model.
147 * ITmfTimeAnalysisEntry#getTraceEvents()
149 @SuppressWarnings("unchecked")
150 public Vector
<TimeRangeComponent
> getTraceEvents() {
151 return ChildEventLeafs
;
157 public Vector
<TimeRangeComponent
> getChildEventComposites() {
158 return ChildEventComposites
;
This page took 0.033767 seconds and 4 git commands to generate.