#ifndef SpeechRecognitionClientProxy_h
#define SpeechRecognitionClientProxy_h
#include "WebSpeechRecognizerClient.h"
#include "modules/speech/SpeechRecognitionClient.h"
#include "wtf/Compiler.h"
#include "wtf/PassOwnPtr.h"
#include "wtf/text/WTFString.h"
namespace blink {
class WebSpeechRecognizer;
class WebString;
class SpeechRecognitionClientProxy FINAL : public WebCore::SpeechRecognitionClient, public WebSpeechRecognizerClient {
public:
virtual ~SpeechRecognitionClientProxy();
static PassOwnPtr<SpeechRecognitionClientProxy> create(WebSpeechRecognizer*);
virtual void start(WebCore::SpeechRecognition*, const WebCore::SpeechGrammarList*, const String& lang, bool continuous, bool interimResults, unsigned long maxAlternatives) OVERRIDE;
virtual void stop(WebCore::SpeechRecognition*) OVERRIDE;
virtual void abort(WebCore::SpeechRecognition*) OVERRIDE;
virtual void didStartAudio(const WebSpeechRecognitionHandle&) OVERRIDE;
virtual void didStartSound(const WebSpeechRecognitionHandle&) OVERRIDE;
virtual void didEndSound(const WebSpeechRecognitionHandle&) OVERRIDE;
virtual void didEndAudio(const WebSpeechRecognitionHandle&) OVERRIDE;
virtual void didReceiveResults(const WebSpeechRecognitionHandle&, const WebVector<WebSpeechRecognitionResult>& newFinalResults, const WebVector<WebSpeechRecognitionResult>& currentInterimResults) OVERRIDE;
virtual void didReceiveNoMatch(const WebSpeechRecognitionHandle&, const WebSpeechRecognitionResult&) OVERRIDE;
virtual void didReceiveError(const WebSpeechRecognitionHandle&, const WebString& message, WebSpeechRecognizerClient::ErrorCode) OVERRIDE;
virtual void didStart(const WebSpeechRecognitionHandle&) OVERRIDE;
virtual void didEnd(const WebSpeechRecognitionHandle&) OVERRIDE;
private:
SpeechRecognitionClientProxy(WebSpeechRecognizer*);
WebSpeechRecognizer* m_recognizer;
};
};
#endif