tmf: Bug 491714: Fix population of XmlTimeGraphView for experiments
[deliverable/tracecompass.git] / tmf / org.eclipse.tracecompass.tmf.core / src / org / eclipse / tracecompass / tmf / core / timestamp / TmfRealTimestamp.java
CommitLineData
b2c971ec
MK
1/*******************************************************************************
2 * Copyright (c) 2016 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
10package org.eclipse.tracecompass.tmf.core.timestamp;
11
12/**
13 * A timestamp with a user provided scale and value
14 *
15 * @author Matthew Khouzam
16 * @since 2.0
17 */
18public class TmfRealTimestamp extends TmfTimestamp {
19
20 // ------------------------------------------------------------------------
21 // Attributes
22 // ------------------------------------------------------------------------
23
24 /**
25 * The timestamp raw value (mantissa)
26 */
27 private final long fValue;
28
29 /**
30 * The timestamp scale (magnitude)
31 */
32 private final int fScale;
33
34 // ------------------------------------------------------------------------
35 // Constructors
36 // ------------------------------------------------------------------------
37
38 /**
39 * Full constructor
40 *
41 * @param value
42 * the timestamp value
43 * @param scale
44 * the timestamp scale
45 */
46 public TmfRealTimestamp(final long value, final int scale) {
47 fValue = value;
48 fScale = scale;
49 }
50
51 @Override
52 public long getValue() {
53 return fValue;
54 }
55
56 @Override
57 public int getScale() {
58 return fScale;
59 }
60}
This page took 0.027582 seconds and 5 git commands to generate.