b61d7c24bf1cdd1fe9f045770136599caa683822
[deliverable/tracecompass.git] / org.eclipse.linuxtools.tmf.ui / src / org / eclipse / linuxtools / tmf / ui / views / histogram / IHistogramDataModel.java
1 /*******************************************************************************
2 * Copyright (c) 2011, 2012 Ericsson
3 *
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
8 *
9 * Contributors:
10 * Bernd Hufmann - Initial API and implementation
11 * Francois Chouinard - Moved from LTTng to TMF
12 *******************************************************************************/
13
14 package org.eclipse.linuxtools.tmf.ui.views.histogram;
15
16 import org.eclipse.linuxtools.tmf.ui.views.distribution.model.IBaseDistributionModel;
17
18 /**
19 * <b><u>IHistogramDataModel</u></b>
20 * <p>
21 */
22
23 public interface IHistogramDataModel extends IBaseDistributionModel {
24 /**
25 * Add event to the correct bucket, compacting the if needed.
26 *
27 * @param timestamp the timestamp of the event to count
28 */
29 public void countEvent(long eventCount, long timestamp);
30
31 /**
32 * Scale the model data to the width, height and bar width requested.
33 *
34 * @param width
35 * @param height
36 * @param bar width
37 * @return the result array of size [width] and where the highest value
38 * doesn't exceed [height] considering the bar width [barWidth]
39 */
40 public HistogramScaledData scaleTo(int width, int height, int barWidth);
41
42 }
This page took 0.03082 seconds and 5 git commands to generate.