equal
deleted
inserted
replaced
|
1 // Copyright (c) 2006-2009 Nokia Corporation and/or its subsidiary(-ies). |
|
2 // All rights reserved. |
|
3 // This component and the accompanying materials are made available |
|
4 // under the terms of "Eclipse Public License v1.0" |
|
5 // which accompanies this distribution, and is available |
|
6 // at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
7 // |
|
8 // Initial Contributors: |
|
9 // Nokia Corporation - initial contribution. |
|
10 // |
|
11 // Contributors: |
|
12 // |
|
13 // Description: |
|
14 // |
|
15 |
|
16 /** |
|
17 @file |
|
18 @publishedPartner |
|
19 */ |
|
20 |
|
21 #include <mtp/mtpdatatypeconstants.h> |
|
22 #include <mtp/tmtptypeuint8.h> |
|
23 |
|
24 /** |
|
25 Default constructor. |
|
26 */ |
|
27 EXPORT_C TMTPTypeUint8::TMTPTypeUint8() : |
|
28 TMTPTypeUintBase(0, KMTPTypeUINT8Size, EMTPTypeUINT8) |
|
29 { |
|
30 |
|
31 } |
|
32 |
|
33 /** |
|
34 Conversion constructor. |
|
35 @param aData The initial data value. |
|
36 */ |
|
37 EXPORT_C TMTPTypeUint8::TMTPTypeUint8(TUint8 aData) : |
|
38 TMTPTypeUintBase(aData, KMTPTypeUINT8Size, EMTPTypeUINT8) |
|
39 { |
|
40 |
|
41 } |
|
42 |
|
43 /** |
|
44 Sets the data type to the specified value. |
|
45 */ |
|
46 EXPORT_C void TMTPTypeUint8::Set(TUint8 aValue) |
|
47 { |
|
48 iData = aValue; |
|
49 } |
|
50 |
|
51 /** |
|
52 Provides data types's value. |
|
53 @return The value of the data type |
|
54 */ |
|
55 EXPORT_C TUint8 TMTPTypeUint8::Value() const |
|
56 { |
|
57 return static_cast<TUint8>(iData); |
|
58 } |
|
59 |