1e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath/*
2e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * Copyright (C) 2011 The Android Open Source Project
3e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath *
4e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * Licensed under the Apache License, Version 2.0 (the "License"); you may not
5e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * use this file except in compliance with the License. You may obtain a copy of
6e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * the License at
7e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath *
8e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * http://www.apache.org/licenses/LICENSE-2.0
9e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath *
10e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * Unless required by applicable law or agreed to in writing, software
11e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
12e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
13e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * License for the specific language governing permissions and limitations under
14e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * the License.
15e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath */
16e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamathpackage android.speech.tts;
17e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath
18e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath/**
19e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * Defines additional methods the synthesis callback must implement that
20e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath * are private to the TTS service implementation.
21e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath */
22e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamathabstract class AbstractSynthesisCallback implements SynthesisCallback {
23e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath    /**
24e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     * Checks whether the synthesis request completed successfully.
25e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     */
26e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath    abstract boolean isDone();
27e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath
28e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath    /**
29e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     * Aborts the speech request.
30e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     *
31e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     * Can be called from multiple threads.
32e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath     */
33e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath    abstract void stop();
34e22b69a7de0349b99d3107349d1d3aa72d62c841Narayan Kamath}
35