|
1 /* |
|
2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * |
|
16 */ |
|
17 |
|
18 #include <memspy/api/memspyapimemorytrackingcycle.h> |
|
19 #include <memspy/engine/memspymemorytrackingcycledata.h> |
|
20 |
|
21 EXPORT_C TInt CMemSpyApiMemoryTrackingCycle::CycleNumber() const |
|
22 { |
|
23 return iData->iCycleNumber; |
|
24 } |
|
25 |
|
26 EXPORT_C const TTime& CMemSpyApiMemoryTrackingCycle::Time() const |
|
27 { |
|
28 return iData->iTime; |
|
29 } |
|
30 |
|
31 EXPORT_C const TDesC& CMemSpyApiMemoryTrackingCycle::Caption() const |
|
32 { |
|
33 return iData->iCaption; |
|
34 } |
|
35 |
|
36 EXPORT_C const TInt64& CMemSpyApiMemoryTrackingCycle::FreeMemory() const |
|
37 { |
|
38 return iData->iFreeMemory; |
|
39 } |
|
40 |
|
41 EXPORT_C TInt64 CMemSpyApiMemoryTrackingCycle::MemoryDelta() const |
|
42 { |
|
43 return iData->iMemoryDelta; |
|
44 } |
|
45 |
|
46 EXPORT_C TInt64 CMemSpyApiMemoryTrackingCycle::PreviousCycleDiff() const |
|
47 { |
|
48 return iData->iPreviousCycleDiff; |
|
49 } |
|
50 |
|
51 EXPORT_C TInt CMemSpyApiMemoryTrackingCycle::ChangeCount() const |
|
52 { |
|
53 return iData->iChangeCount; |
|
54 } |
|
55 |
|
56 EXPORT_C CMemSpyApiMemoryTrackingCycle::~CMemSpyApiMemoryTrackingCycle() |
|
57 { |
|
58 delete iData; |
|
59 } |
|
60 |
|
61 CMemSpyApiMemoryTrackingCycle* CMemSpyApiMemoryTrackingCycle::NewL(const TMemSpyMemoryTrackingCycleData& aData) |
|
62 { |
|
63 CMemSpyApiMemoryTrackingCycle* self = CMemSpyApiMemoryTrackingCycle::NewLC(aData); |
|
64 CleanupStack::Pop(self); |
|
65 return (self); |
|
66 } |
|
67 |
|
68 CMemSpyApiMemoryTrackingCycle* CMemSpyApiMemoryTrackingCycle::NewLC(const TMemSpyMemoryTrackingCycleData& aData) |
|
69 { |
|
70 CMemSpyApiMemoryTrackingCycle* self = new (ELeave) CMemSpyApiMemoryTrackingCycle; |
|
71 CleanupStack::PushL(self); |
|
72 self->ConstructL(aData); |
|
73 return self; |
|
74 } |
|
75 |
|
76 CMemSpyApiMemoryTrackingCycle::CMemSpyApiMemoryTrackingCycle() |
|
77 { |
|
78 } |
|
79 |
|
80 void CMemSpyApiMemoryTrackingCycle::ConstructL(const TMemSpyMemoryTrackingCycleData& aData) |
|
81 { |
|
82 iData = new (ELeave) TMemSpyMemoryTrackingCycleData(aData); |
|
83 } |