|
1 /* |
|
2 * Copyright (c) 2002 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 the License "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 * Declaration of class CCodRecog. |
|
16 * |
|
17 * |
|
18 */ |
|
19 |
|
20 |
|
21 #ifndef COD_RECOG_H |
|
22 #define COD_RECOG_H |
|
23 |
|
24 // INCLUDES |
|
25 |
|
26 #include <apmrec.h> |
|
27 |
|
28 // CLASS DECLARATION |
|
29 |
|
30 /** |
|
31 * COD Recognizer. |
|
32 */ |
|
33 class CCodRecog : public CApaDataRecognizerType |
|
34 { |
|
35 public: // construction |
|
36 |
|
37 /** |
|
38 * Constructor. |
|
39 */ |
|
40 CCodRecog(); |
|
41 |
|
42 public: // from CApaDataRecognizerType |
|
43 |
|
44 /** |
|
45 * Return preferred buffer size. |
|
46 * @return Preferred buffer size. |
|
47 */ |
|
48 TUint PreferredBufSize(); |
|
49 |
|
50 /** |
|
51 * Return supported data type. |
|
52 * @param aIndex Index of data type. |
|
53 * @return Supported data type. |
|
54 */ |
|
55 TDataType SupportedDataTypeL( TInt aIndex ) const; |
|
56 |
|
57 public: // new methods |
|
58 |
|
59 /** |
|
60 * Factory function. |
|
61 * @return Recognizer. |
|
62 */ |
|
63 static CApaDataRecognizerType* CreateRecognizerL(); |
|
64 |
|
65 private: // from CApaDataRecognizerType |
|
66 |
|
67 /** |
|
68 * Recognize content. Leaves only on general failures (OOM etc), but |
|
69 * does not leave on any recognition failures. |
|
70 * @param aName File name. |
|
71 * @param aBuffer Content buffer. |
|
72 */ |
|
73 void DoRecognizeL( const TDesC& aName, const TDesC8& aBuffer ); |
|
74 |
|
75 }; |
|
76 |
|
77 #endif /* def COD_RECOG_H */ |