summaryrefslogtreecommitdiff
path: root/ace/Stats.i
blob: 8f5b6d0df22544d1d40ac6dfb366d2697d12d0c8 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
/* -*- C++ -*- */
// $Id$

ACE_INLINE
ACE_Stats_Value::ACE_Stats_Value (const u_int precision)
  : whole_ (0),
    fractional_ (0),
    precision_ (precision)
{
}

ACE_INLINE
u_int
ACE_Stats_Value::precision (void) const
{
  return precision_;
}

ACE_INLINE
void
ACE_Stats_Value::whole (const ACE_UINT32 value)
{
  whole_ = value;
}

ACE_INLINE
ACE_UINT32
ACE_Stats_Value::whole (void) const
{
  return whole_;
}

ACE_INLINE
void
ACE_Stats_Value::fractional (const ACE_UINT32 value)
{
  fractional_ = value;
}

ACE_INLINE
ACE_UINT32
ACE_Stats_Value::fractional (void) const
{
  return fractional_;
}

ACE_INLINE
void
ACE_Stats_Value::scaled_value (ACE_UINT64 &sv) const
{
  sv = whole () * fractional_field ()  +  fractional ();
}

ACE_INLINE
ACE_Stats::ACE_Stats (void) :
  cached_mean_ (0xFFFFFFFFu)
{
  reset ();
}

ACE_INLINE
ACE_UINT32
ACE_Stats::samples (void) const
{
  return number_of_samples_;
}

ACE_INLINE
ACE_INT32
ACE_Stats::min_value (void) const
{
  return min_;
}

ACE_INLINE
ACE_INT32
ACE_Stats::max_value (void) const
{
  return max_;
}