OLD | NEW |
---|---|
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ | 5 #ifndef CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ |
6 #define CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ | 6 #define CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ |
7 #pragma once | |
7 | 8 |
8 #include <vector> | 9 #include <vector> |
9 | 10 |
10 #include "base/basictypes.h" | 11 #include "base/basictypes.h" |
11 #include "base/string16.h" | 12 #include "base/string16.h" |
12 #include "content/common/content_export.h" | 13 #include "content/common/content_export.h" |
13 | 14 |
14 namespace content { | 15 namespace content { |
15 | 16 |
16 struct SpeechRecognitionHypothesis { | 17 struct SpeechRecognitionHypothesis { |
17 string16 utterance; | 18 string16 utterance; |
18 double confidence; | 19 double confidence; |
19 | 20 |
20 SpeechRecognitionHypothesis() : confidence(0.0) {} | 21 SpeechRecognitionHypothesis() : confidence(0.0) {} |
Satish
2012/04/27 10:04:41
move constructor definitions to .cc file
Primiano Tucci (use gerrit)
2012/04/27 15:58:44
See jam@ reply.
| |
21 | 22 |
22 SpeechRecognitionHypothesis(const string16 utterance_value, | 23 SpeechRecognitionHypothesis(const string16 utterance_value, |
23 double confidence_value) | 24 double confidence_value) |
24 : utterance(utterance_value), | 25 : utterance(utterance_value), |
25 confidence(confidence_value) { | 26 confidence(confidence_value) { |
26 } | 27 } |
27 }; | 28 }; |
28 | 29 |
29 typedef std::vector<SpeechRecognitionHypothesis> | 30 typedef std::vector<SpeechRecognitionHypothesis> |
30 SpeechRecognitionHypothesisArray; | 31 SpeechRecognitionHypothesisArray; |
31 | 32 |
32 struct CONTENT_EXPORT SpeechRecognitionResult { | 33 struct CONTENT_EXPORT SpeechRecognitionResult { |
33 SpeechRecognitionHypothesisArray hypotheses; | 34 SpeechRecognitionHypothesisArray hypotheses; |
35 bool provisional; | |
34 | 36 |
35 SpeechRecognitionResult(); | 37 SpeechRecognitionResult(); |
36 ~SpeechRecognitionResult(); | 38 ~SpeechRecognitionResult(); |
37 }; | 39 }; |
38 | 40 |
39 } // namespace content | 41 } // namespace content |
40 | 42 |
41 #endif // CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ | 43 #endif // CONTENT_PUBLIC_COMMON_SPEECH_RECOGNITION_RESULT_H_ |
OLD | NEW |