equal
deleted
inserted
replaced
|
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 |
|
19 |
|
20 template <typename T> TMimeTypeMapping<T>::TMimeTypeMapping(TPtrC aExt) |
|
21 { |
|
22 iExt.Set( aExt.Ptr(), aExt.Length() ); |
|
23 } |
|
24 |
|
25 template <typename T> TMimeTypeMapping<T>::TMimeTypeMapping(TPtrC aExt, TPtrC aMimeType, const T& aHandler) : |
|
26 iHandler( aHandler ) |
|
27 { |
|
28 iExt.Set( aExt.Ptr(), aExt.Length() ); |
|
29 iMimeType.Set( aMimeType.Ptr(), aMimeType.Length() ); |
|
30 } |
|
31 |
|
32 template <typename T> TInt TMimeTypeMapping<T>::CompareFunction( |
|
33 const TMimeTypeMapping<T>& aKey, |
|
34 const TMimeTypeMapping<T>& aItem) |
|
35 { |
|
36 return aKey.iExt.CompareF( aItem.iExt ); |
|
37 } |