|
1 /* |
|
2 * Copyright (c) 2006-2007 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: Base DLNA profile resolver class for image files. |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 #ifndef C_UPNPIMAGESOLVERBASE_H |
|
24 #define C_UPNPIMAGESOLVERBASE_H |
|
25 |
|
26 |
|
27 // system includes |
|
28 // NONE |
|
29 |
|
30 // user includes |
|
31 #include "upnpprofiler.h" |
|
32 |
|
33 // forward declarations |
|
34 // NONE |
|
35 |
|
36 // constants |
|
37 // NONE |
|
38 |
|
39 /** |
|
40 * Image file DLNA profile base resolver class. |
|
41 * |
|
42 * This class is the base class for resolving DLNA profile of image files. |
|
43 * It contains methods for querying the profiles supported by this solver |
|
44 * and for resolving a DLNA profile of a given image file. |
|
45 * |
|
46 * |
|
47 * @lib dlnaprofiler.lib |
|
48 * @since S60 v3.1 |
|
49 */ |
|
50 NONSHARABLE_CLASS( CUpnpImageSolverBase ) : public CBase, |
|
51 public MUpnpProfiler |
|
52 { |
|
53 public: |
|
54 |
|
55 static CUpnpImageSolverBase* NewL(); |
|
56 |
|
57 static CUpnpImageSolverBase* NewLC(); |
|
58 |
|
59 virtual ~CUpnpImageSolverBase(); |
|
60 |
|
61 // from base class MUpnpProfiler |
|
62 |
|
63 /** |
|
64 * From MUpnpProfiler. |
|
65 * SupportedProfilesL returns DLNA profiles that are currently supported. |
|
66 * |
|
67 * @since S60 v3.1 |
|
68 * @param aProfiles Descriptor array where supported DLNA profiles are |
|
69 * added. |
|
70 * @return TInt Error code, KErrNone if successfull. |
|
71 */ |
|
72 TInt SupportedProfilesL( CDesC16ArrayFlat* aProfiles ) const; |
|
73 |
|
74 /** |
|
75 * From MUpnpProfiler. |
|
76 * ProfileForFileL is for resolving a DLNA profile of a given file. |
|
77 * Besides of file name, also mime type of the file is passed as a |
|
78 * parameter in order to avoid re-opening of the file. |
|
79 * |
|
80 * @since S60 v3.1 |
|
81 * @param aFileName Filename of the file which is to be resolved. |
|
82 * @param aMimeType Mime type of the file which is to be resolved. |
|
83 * @param aFile Handle to opened file specified by aFilename. |
|
84 * @return DLNA profile of the file as a HBufC*, |
|
85 * NULL if could not be resolved |
|
86 */ |
|
87 HBufC* ProfileForFileL( const TDesC& aFilename, |
|
88 const TDesC8& aMimetype, |
|
89 RFile& aFile ); |
|
90 |
|
91 private: |
|
92 |
|
93 CUpnpImageSolverBase(); |
|
94 |
|
95 void ConstructL(); |
|
96 }; |
|
97 |
|
98 #endif // C_UPNPIMAGESOLVERBASE_H |