upstream version 1.2.2
[debian/freetts] / javadoc / com / sun / speech / freetts / audio / MultiFileAudioPlayer.html
1 <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">\r
2 <!--NewPage-->\r
3 <HTML>\r
4 <HEAD>\r
5 <!-- Generated by javadoc (build 1.4.2_16) on Mon Mar 09 18:20:29 CET 2009 -->\r
6 <TITLE>\r
7 MultiFileAudioPlayer (FreeTTS 1.2)\r
8 </TITLE>\r
9 \r
10 <META NAME="keywords" CONTENT="com.sun.speech.freetts.audio.MultiFileAudioPlayer class">\r
11 \r
12 <LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../stylesheet.css" TITLE="Style">\r
13 \r
14 <SCRIPT type="text/javascript">\r
15 function windowTitle()\r
16 {\r
17     parent.document.title="MultiFileAudioPlayer (FreeTTS 1.2)";\r
18 }\r
19 </SCRIPT>\r
20 \r
21 </HEAD>\r
22 \r
23 <BODY BGCOLOR="white" onload="windowTitle();">\r
24 \r
25
26 <!-- ========= START OF TOP NAVBAR ======= -->\r
27 <A NAME="navbar_top"><!-- --></A>
28 <A HREF="#skip-navbar_top" title="Skip navigation links"></A>
29 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">\r
30 <TR>\r
31 <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">\r
32 <A NAME="navbar_top_firstrow"><!-- --></A>
33 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">\r
34   <TR ALIGN="center" VALIGN="top">\r
35   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>\r
36   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>\r
37   <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>\r
38   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>\r
39   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>\r
40   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>\r
41   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>\r
42   </TR>\r
43 </TABLE>\r
44 </TD>\r
45 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>\r
46 </EM>\r
47 </TD>\r
48 </TR>\r
49 \r
50 <TR>\r
51 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
52 &nbsp;<A HREF="../../../../../com/sun/speech/freetts/audio/MultiFile8BitAudioPlayer.html" title="class in com.sun.speech.freetts.audio"><B>PREV CLASS</B></A>&nbsp;\r
53 &nbsp;<A HREF="../../../../../com/sun/speech/freetts/audio/NullAudioPlayer.html" title="class in com.sun.speech.freetts.audio"><B>NEXT CLASS</B></A></FONT></TD>\r
54 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
55   <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A>  &nbsp;\r
56 &nbsp;<A HREF="MultiFileAudioPlayer.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;\r
57 &nbsp;<SCRIPT type="text/javascript">\r
58   <!--\r
59   if(window==top) {\r
60     document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');\r
61   }\r
62   //-->\r
63 </SCRIPT>\r
64 <NOSCRIPT>\r
65   <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>\r
66 </NOSCRIPT>
67 \r
68 </FONT></TD>\r
69 </TR>\r
70 <TR>\r
71 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
72   SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>\r
73 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
74 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>\r
75 </TR>\r
76 </TABLE>\r
77 <A NAME="skip-navbar_top"></A>
78 <!-- ========= END OF TOP NAVBAR ========= -->\r
79 \r
80 <HR>\r
81 <!-- ======== START OF CLASS DATA ======== -->\r
82 <H2>\r
83 <FONT SIZE="-1">\r
84 com.sun.speech.freetts.audio</FONT>\r
85 <BR>\r
86 Class MultiFileAudioPlayer</H2>\r
87 <PRE>\r
88 java.lang.Object\r
89   <IMG SRC="../../../../../resources/inherit.gif" ALT="extended by"><B>com.sun.speech.freetts.audio.MultiFileAudioPlayer</B>\r
90 </PRE>\r
91 <DL>\r
92 <DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></DD>\r
93 </DL>\r
94 <HR>\r
95 <DL>\r
96 <DT>public class <B>MultiFileAudioPlayer</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></DL>\r
97 \r
98 <P>\r
99 Streams audio to multiple files, one per utterance.\r
100 <P>\r
101 \r
102 <P>\r
103 <HR>\r
104 \r
105 <P>\r
106 <!-- ======== NESTED CLASS SUMMARY ======== -->\r
107 \r
108 \r
109 <!-- =========== FIELD SUMMARY =========== -->\r
110 \r
111 \r
112 <!-- ======== CONSTRUCTOR SUMMARY ======== -->\r
113 \r
114 <A NAME="constructor_summary"><!-- --></A>
115 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
116 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
117 <TD COLSPAN=2><FONT SIZE="+2">\r
118 <B>Constructor Summary</B></FONT></TD>\r
119 </TR>\r
120 <TR BGCOLOR="white" CLASS="TableRowColor">\r
121 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#MultiFileAudioPlayer()">MultiFileAudioPlayer</A></B>()</CODE>\r
122 \r
123 <BR>\r
124 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Creates a default audio player for an AudioFileFormat of type
125  WAVE.  </TD>\r
126 </TR>\r
127 <TR BGCOLOR="white" CLASS="TableRowColor">\r
128 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#MultiFileAudioPlayer(java.lang.String, javax.sound.sampled.AudioFileFormat.Type)">MultiFileAudioPlayer</A></B>(java.lang.String&nbsp;baseName,
129                      javax.sound.sampled.AudioFileFormat.Type&nbsp;type)</CODE>\r
130 \r
131 <BR>\r
132 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Constructs a MultiFileAudioPlayer</TD>\r
133 </TR>\r
134 </TABLE>\r
135 &nbsp;\r
136 <!-- ========== METHOD SUMMARY =========== -->\r
137 \r
138 <A NAME="method_summary"><!-- --></A>
139 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
140 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
141 <TD COLSPAN=2><FONT SIZE="+2">\r
142 <B>Method Summary</B></FONT></TD>\r
143 </TR>\r
144 <TR BGCOLOR="white" CLASS="TableRowColor">\r
145 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
146 <CODE>&nbsp;void</CODE></FONT></TD>\r
147 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#begin(int)">begin</A></B>(int&nbsp;size)</CODE>\r
148 \r
149 <BR>\r
150 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Starts the output of a set of data. </TD>\r
151 </TR>\r
152 <TR BGCOLOR="white" CLASS="TableRowColor">\r
153 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
154 <CODE>&nbsp;void</CODE></FONT></TD>\r
155 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#cancel()">cancel</A></B>()</CODE>\r
156 \r
157 <BR>\r
158 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cancels currently playing audio</TD>\r
159 </TR>\r
160 <TR BGCOLOR="white" CLASS="TableRowColor">\r
161 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
162 <CODE>&nbsp;void</CODE></FONT></TD>\r
163 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#close()">close</A></B>()</CODE>\r
164 \r
165 <BR>\r
166 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Closes this audio player</TD>\r
167 </TR>\r
168 <TR BGCOLOR="white" CLASS="TableRowColor">\r
169 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
170 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
171 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#drain()">drain</A></B>()</CODE>\r
172 \r
173 <BR>\r
174 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Waits for all queued audio to be played</TD>\r
175 </TR>\r
176 <TR BGCOLOR="white" CLASS="TableRowColor">\r
177 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
178 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
179 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#end()">end</A></B>()</CODE>\r
180 \r
181 <BR>\r
182 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Marks the end of a set of data. </TD>\r
183 </TR>\r
184 <TR BGCOLOR="white" CLASS="TableRowColor">\r
185 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
186 <CODE>&nbsp;javax.sound.sampled.AudioFormat</CODE></FONT></TD>\r
187 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#getAudioFormat()">getAudioFormat</A></B>()</CODE>\r
188 \r
189 <BR>\r
190 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the audio format for this player</TD>\r
191 </TR>\r
192 <TR BGCOLOR="white" CLASS="TableRowColor">\r
193 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
194 <CODE>&nbsp;long</CODE></FONT></TD>\r
195 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#getTime()">getTime</A></B>()</CODE>\r
196 \r
197 <BR>\r
198 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Gets the amount of played since the last mark</TD>\r
199 </TR>\r
200 <TR BGCOLOR="white" CLASS="TableRowColor">\r
201 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
202 <CODE>&nbsp;float</CODE></FONT></TD>\r
203 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#getVolume()">getVolume</A></B>()</CODE>\r
204 \r
205 <BR>\r
206 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the current volume.</TD>\r
207 </TR>\r
208 <TR BGCOLOR="white" CLASS="TableRowColor">\r
209 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
210 <CODE>&nbsp;void</CODE></FONT></TD>\r
211 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#pause()">pause</A></B>()</CODE>\r
212 \r
213 <BR>\r
214 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Pauses audio output</TD>\r
215 </TR>\r
216 <TR BGCOLOR="white" CLASS="TableRowColor">\r
217 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
218 <CODE>&nbsp;void</CODE></FONT></TD>\r
219 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#reset()">reset</A></B>()</CODE>\r
220 \r
221 <BR>\r
222 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Prepares for another batch of output. </TD>\r
223 </TR>\r
224 <TR BGCOLOR="white" CLASS="TableRowColor">\r
225 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
226 <CODE>&nbsp;void</CODE></FONT></TD>\r
227 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#resetTime()">resetTime</A></B>()</CODE>\r
228 \r
229 <BR>\r
230 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Resets the audio clock</TD>\r
231 </TR>\r
232 <TR BGCOLOR="white" CLASS="TableRowColor">\r
233 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
234 <CODE>&nbsp;void</CODE></FONT></TD>\r
235 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#resume()">resume</A></B>()</CODE>\r
236 \r
237 <BR>\r
238 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Resumes audio output</TD>\r
239 </TR>\r
240 <TR BGCOLOR="white" CLASS="TableRowColor">\r
241 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
242 <CODE>&nbsp;void</CODE></FONT></TD>\r
243 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#setAudioFormat(javax.sound.sampled.AudioFormat)">setAudioFormat</A></B>(javax.sound.sampled.AudioFormat&nbsp;format)</CODE>\r
244 \r
245 <BR>\r
246 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the audio format for this player</TD>\r
247 </TR>\r
248 <TR BGCOLOR="white" CLASS="TableRowColor">\r
249 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
250 <CODE>&nbsp;void</CODE></FONT></TD>\r
251 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#setVolume(float)">setVolume</A></B>(float&nbsp;volume)</CODE>\r
252 \r
253 <BR>\r
254 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Sets the current volume.</TD>\r
255 </TR>\r
256 <TR BGCOLOR="white" CLASS="TableRowColor">\r
257 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
258 <CODE>&nbsp;void</CODE></FONT></TD>\r
259 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#showMetrics()">showMetrics</A></B>()</CODE>\r
260 \r
261 <BR>\r
262 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Shows metrics for this audio player</TD>\r
263 </TR>\r
264 <TR BGCOLOR="white" CLASS="TableRowColor">\r
265 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
266 <CODE>&nbsp;void</CODE></FONT></TD>\r
267 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#startFirstSampleTimer()">startFirstSampleTimer</A></B>()</CODE>\r
268 \r
269 <BR>\r
270 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Starts the first sample timer</TD>\r
271 </TR>\r
272 <TR BGCOLOR="white" CLASS="TableRowColor">\r
273 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
274 <CODE>&nbsp;java.lang.String</CODE></FONT></TD>\r
275 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#toString()">toString</A></B>()</CODE>\r
276 \r
277 <BR>\r
278 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Returns the name of this audioplayer</TD>\r
279 </TR>\r
280 <TR BGCOLOR="white" CLASS="TableRowColor">\r
281 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
282 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
283 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#write(byte[])">write</A></B>(byte[]&nbsp;audioData)</CODE>\r
284 \r
285 <BR>\r
286 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the given bytes to the audio stream</TD>\r
287 </TR>\r
288 <TR BGCOLOR="white" CLASS="TableRowColor">\r
289 <TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">\r
290 <CODE>&nbsp;boolean</CODE></FONT></TD>\r
291 <TD><CODE><B><A HREF="../../../../../com/sun/speech/freetts/audio/MultiFileAudioPlayer.html#write(byte[], int, int)">write</A></B>(byte[]&nbsp;bytes,
292       int&nbsp;offset,
293       int&nbsp;size)</CODE>\r
294 \r
295 <BR>\r
296 &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Writes the given bytes to the audio stream</TD>\r
297 </TR>\r
298 </TABLE>\r
299 &nbsp;<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
300 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
301 <TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">\r
302 <TD><B>Methods inherited from class java.lang.Object</B></TD>\r
303 </TR>\r
304 <TR BGCOLOR="white" CLASS="TableRowColor">\r
305 <TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait</CODE></TD>\r
306 </TR>\r
307 </TABLE>\r
308 &nbsp;\r
309 <P>\r
310 \r
311 <!-- ============ FIELD DETAIL =========== -->\r
312 \r
313 \r
314 <!-- ========= CONSTRUCTOR DETAIL ======== -->\r
315 \r
316 <A NAME="constructor_detail"><!-- --></A>
317 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
318 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
319 <TD COLSPAN=1><FONT SIZE="+2">\r
320 <B>Constructor Detail</B></FONT></TD>\r
321 </TR>\r
322 </TABLE>\r
323 \r
324 <A NAME="MultiFileAudioPlayer()"><!-- --></A><H3>\r
325 MultiFileAudioPlayer</H3>\r
326 <PRE>\r
327 public <B>MultiFileAudioPlayer</B>()</PRE>\r
328 <DL>\r
329 <DD>Creates a default audio player for an AudioFileFormat of type
330  WAVE.  Reads the "com.sun.speech.freetts.AudioPlayer.baseName"
331  property for the base filename to use, and will produce files
332  of the form &lt;baseName>1.wav.  The default value for the
333  base name is "freetts".\r
334 <P>\r
335 </DL>\r
336 <HR>\r
337 \r
338 <A NAME="MultiFileAudioPlayer(java.lang.String, javax.sound.sampled.AudioFileFormat.Type)"><!-- --></A><H3>\r
339 MultiFileAudioPlayer</H3>\r
340 <PRE>\r
341 public <B>MultiFileAudioPlayer</B>(java.lang.String&nbsp;baseName,
342                             javax.sound.sampled.AudioFileFormat.Type&nbsp;type)</PRE>\r
343 <DL>\r
344 <DD>Constructs a MultiFileAudioPlayer\r
345 <P>\r
346 <DT><B>Parameters:</B><DD><CODE>baseName</CODE> - the base name of the audio file<DD><CODE>type</CODE> - the type of audio output</DL>\r
347 \r
348 <!-- ============ METHOD DETAIL ========== -->\r
349 \r
350 <A NAME="method_detail"><!-- --></A>
351 <TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">\r
352 <TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">\r
353 <TD COLSPAN=1><FONT SIZE="+2">\r
354 <B>Method Detail</B></FONT></TD>\r
355 </TR>\r
356 </TABLE>\r
357 \r
358 <A NAME="setAudioFormat(javax.sound.sampled.AudioFormat)"><!-- --></A><H3>\r
359 setAudioFormat</H3>\r
360 <PRE>\r
361 public void <B>setAudioFormat</B>(javax.sound.sampled.AudioFormat&nbsp;format)</PRE>\r
362 <DL>\r
363 <DD>Sets the audio format for this player\r
364 <P>\r
365 <DD><DL>\r
366 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#setAudioFormat(javax.sound.sampled.AudioFormat)">setAudioFormat</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
367 </DD>\r
368 <DD><DL>\r
369 <DT><B>Parameters:</B><DD><CODE>format</CODE> - the audio format
370 <DT><B>Throws:</B>
371 <DD><CODE>java.lang.UnsupportedOperationException</CODE> - if the line cannot be opened with
372      the given format</DL>\r
373 </DD>\r
374 </DL>\r
375 <HR>\r
376 \r
377 <A NAME="getAudioFormat()"><!-- --></A><H3>\r
378 getAudioFormat</H3>\r
379 <PRE>\r
380 public javax.sound.sampled.AudioFormat <B>getAudioFormat</B>()</PRE>\r
381 <DL>\r
382 <DD>Gets the audio format for this player\r
383 <P>\r
384 <DD><DL>\r
385 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#getAudioFormat()">getAudioFormat</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
386 </DD>\r
387 <DD><DL>\r
388
389 <DT><B>Returns:</B><DD>format the audio format</DL>\r
390 </DD>\r
391 </DL>\r
392 <HR>\r
393 \r
394 <A NAME="pause()"><!-- --></A><H3>\r
395 pause</H3>\r
396 <PRE>\r
397 public void <B>pause</B>()</PRE>\r
398 <DL>\r
399 <DD>Pauses audio output\r
400 <P>\r
401 <DD><DL>\r
402 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#pause()">pause</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
403 </DD>\r
404 <DD><DL>\r
405 </DL>\r
406 </DD>\r
407 </DL>\r
408 <HR>\r
409 \r
410 <A NAME="resume()"><!-- --></A><H3>\r
411 resume</H3>\r
412 <PRE>\r
413 public void <B>resume</B>()</PRE>\r
414 <DL>\r
415 <DD>Resumes audio output\r
416 <P>\r
417 <DD><DL>\r
418 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#resume()">resume</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
419 </DD>\r
420 <DD><DL>\r
421 </DL>\r
422 </DD>\r
423 </DL>\r
424 <HR>\r
425 \r
426 <A NAME="startFirstSampleTimer()"><!-- --></A><H3>\r
427 startFirstSampleTimer</H3>\r
428 <PRE>\r
429 public void <B>startFirstSampleTimer</B>()</PRE>\r
430 <DL>\r
431 <DD>Starts the first sample timer\r
432 <P>\r
433 <DD><DL>\r
434 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#startFirstSampleTimer()">startFirstSampleTimer</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
435 </DD>\r
436 <DD><DL>\r
437 </DL>\r
438 </DD>\r
439 </DL>\r
440 <HR>\r
441 \r
442 <A NAME="cancel()"><!-- --></A><H3>\r
443 cancel</H3>\r
444 <PRE>\r
445 public void <B>cancel</B>()</PRE>\r
446 <DL>\r
447 <DD>Cancels currently playing audio\r
448 <P>\r
449 <DD><DL>\r
450 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#cancel()">cancel</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
451 </DD>\r
452 <DD><DL>\r
453 </DL>\r
454 </DD>\r
455 </DL>\r
456 <HR>\r
457 \r
458 <A NAME="reset()"><!-- --></A><H3>\r
459 reset</H3>\r
460 <PRE>\r
461 public void <B>reset</B>()</PRE>\r
462 <DL>\r
463 <DD>Prepares for another batch of output. Larger groups of output
464  (such as all output associated with a single FreeTTSSpeakable)
465  should be grouped between a reset/drain pair.\r
466 <P>\r
467 <DD><DL>\r
468 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#reset()">reset</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
469 </DD>\r
470 <DD><DL>\r
471 </DL>\r
472 </DD>\r
473 </DL>\r
474 <HR>\r
475 \r
476 <A NAME="close()"><!-- --></A><H3>\r
477 close</H3>\r
478 <PRE>\r
479 public void <B>close</B>()</PRE>\r
480 <DL>\r
481 <DD>Closes this audio player\r
482 <P>\r
483 <DD><DL>\r
484 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#close()">close</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
485 </DD>\r
486 <DD><DL>\r
487 </DL>\r
488 </DD>\r
489 </DL>\r
490 <HR>\r
491 \r
492 <A NAME="getVolume()"><!-- --></A><H3>\r
493 getVolume</H3>\r
494 <PRE>\r
495 public float <B>getVolume</B>()</PRE>\r
496 <DL>\r
497 <DD>Returns the current volume.\r
498 <P>\r
499 <DD><DL>\r
500 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#getVolume()">getVolume</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
501 </DD>\r
502 <DD><DL>\r
503
504 <DT><B>Returns:</B><DD>the current volume (between 0 and 1)</DL>\r
505 </DD>\r
506 </DL>\r
507 <HR>\r
508 \r
509 <A NAME="setVolume(float)"><!-- --></A><H3>\r
510 setVolume</H3>\r
511 <PRE>\r
512 public void <B>setVolume</B>(float&nbsp;volume)</PRE>\r
513 <DL>\r
514 <DD>Sets the current volume.\r
515 <P>\r
516 <DD><DL>\r
517 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#setVolume(float)">setVolume</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
518 </DD>\r
519 <DD><DL>\r
520 <DT><B>Parameters:</B><DD><CODE>volume</CODE> - the current volume (between 0 and 1)</DL>\r
521 </DD>\r
522 </DL>\r
523 <HR>\r
524 \r
525 <A NAME="begin(int)"><!-- --></A><H3>\r
526 begin</H3>\r
527 <PRE>\r
528 public void <B>begin</B>(int&nbsp;size)</PRE>\r
529 <DL>\r
530 <DD>Starts the output of a set of data. Audio data for a single
531   utterance should be grouped between begin/end pairs.\r
532 <P>\r
533 <DD><DL>\r
534 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#begin(int)">begin</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
535 </DD>\r
536 <DD><DL>\r
537 <DT><B>Parameters:</B><DD><CODE>size</CODE> - the size of data between now and the end</DL>\r
538 </DD>\r
539 </DL>\r
540 <HR>\r
541 \r
542 <A NAME="end()"><!-- --></A><H3>\r
543 end</H3>\r
544 <PRE>\r
545 public boolean <B>end</B>()</PRE>\r
546 <DL>\r
547 <DD>Marks the end of a set of data. Audio data for a single 
548   utterance should be groupd between begin/end pairs.\r
549 <P>\r
550 <DD><DL>\r
551 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#end()">end</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
552 </DD>\r
553 <DD><DL>\r
554
555 <DT><B>Returns:</B><DD>true if the audio was output properly, false if the
556       output was cancelled or interrupted.</DL>\r
557 </DD>\r
558 </DL>\r
559 <HR>\r
560 \r
561 <A NAME="drain()"><!-- --></A><H3>\r
562 drain</H3>\r
563 <PRE>\r
564 public boolean <B>drain</B>()</PRE>\r
565 <DL>\r
566 <DD>Waits for all queued audio to be played\r
567 <P>\r
568 <DD><DL>\r
569 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#drain()">drain</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
570 </DD>\r
571 <DD><DL>\r
572
573 <DT><B>Returns:</B><DD>true if the audio played to completion, false if
574    the audio was stopped</DL>\r
575 </DD>\r
576 </DL>\r
577 <HR>\r
578 \r
579 <A NAME="getTime()"><!-- --></A><H3>\r
580 getTime</H3>\r
581 <PRE>\r
582 public long <B>getTime</B>()</PRE>\r
583 <DL>\r
584 <DD>Gets the amount of played since the last mark\r
585 <P>\r
586 <DD><DL>\r
587 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#getTime()">getTime</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
588 </DD>\r
589 <DD><DL>\r
590
591 <DT><B>Returns:</B><DD>the amount of audio in milliseconds</DL>\r
592 </DD>\r
593 </DL>\r
594 <HR>\r
595 \r
596 <A NAME="resetTime()"><!-- --></A><H3>\r
597 resetTime</H3>\r
598 <PRE>\r
599 public void <B>resetTime</B>()</PRE>\r
600 <DL>\r
601 <DD>Resets the audio clock\r
602 <P>\r
603 <DD><DL>\r
604 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#resetTime()">resetTime</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
605 </DD>\r
606 <DD><DL>\r
607 </DL>\r
608 </DD>\r
609 </DL>\r
610 <HR>\r
611 \r
612 <A NAME="write(byte[])"><!-- --></A><H3>\r
613 write</H3>\r
614 <PRE>\r
615 public boolean <B>write</B>(byte[]&nbsp;audioData)</PRE>\r
616 <DL>\r
617 <DD>Writes the given bytes to the audio stream\r
618 <P>\r
619 <DD><DL>\r
620 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#write(byte[])">write</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
621 </DD>\r
622 <DD><DL>\r
623 <DT><B>Parameters:</B><DD><CODE>audioData</CODE> - audio data to write to the device
624 <DT><B>Returns:</B><DD><code>true</code> of the write completed successfully, 
625         <code> false </code>if the write was cancelled.</DL>\r
626 </DD>\r
627 </DL>\r
628 <HR>\r
629 \r
630 <A NAME="write(byte[], int, int)"><!-- --></A><H3>\r
631 write</H3>\r
632 <PRE>\r
633 public boolean <B>write</B>(byte[]&nbsp;bytes,
634                      int&nbsp;offset,
635                      int&nbsp;size)</PRE>\r
636 <DL>\r
637 <DD>Writes the given bytes to the audio stream\r
638 <P>\r
639 <DD><DL>\r
640 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#write(byte[], int, int)">write</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
641 </DD>\r
642 <DD><DL>\r
643 <DT><B>Parameters:</B><DD><CODE>bytes</CODE> - audio data to write to the device<DD><CODE>offset</CODE> - the offset into the buffer<DD><CODE>size</CODE> - the size into the buffer
644 <DT><B>Returns:</B><DD><code>true</code> of the write completed successfully, 
645         <code> false </code>if the write was cancelled.</DL>\r
646 </DD>\r
647 </DL>\r
648 <HR>\r
649 \r
650 <A NAME="toString()"><!-- --></A><H3>\r
651 toString</H3>\r
652 <PRE>\r
653 public java.lang.String <B>toString</B>()</PRE>\r
654 <DL>\r
655 <DD>Returns the name of this audioplayer\r
656 <P>\r
657 <DD><DL>\r
658 </DL>\r
659 </DD>\r
660 <DD><DL>\r
661
662 <DT><B>Returns:</B><DD>the name of the audio player</DL>\r
663 </DD>\r
664 </DL>\r
665 <HR>\r
666 \r
667 <A NAME="showMetrics()"><!-- --></A><H3>\r
668 showMetrics</H3>\r
669 <PRE>\r
670 public void <B>showMetrics</B>()</PRE>\r
671 <DL>\r
672 <DD>Shows metrics for this audio player\r
673 <P>\r
674 <DD><DL>\r
675 <DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html#showMetrics()">showMetrics</A></CODE> in interface <CODE><A HREF="../../../../../com/sun/speech/freetts/audio/AudioPlayer.html" title="interface in com.sun.speech.freetts.audio">AudioPlayer</A></CODE></DL>\r
676 </DD>\r
677 <DD><DL>\r
678 </DL>\r
679 </DD>\r
680 </DL>\r
681 <!-- ========= END OF CLASS DATA ========= -->\r
682 <HR>\r
683 \r
684
685 <!-- ======= START OF BOTTOM NAVBAR ====== -->\r
686 <A NAME="navbar_bottom"><!-- --></A>
687 <A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
688 <TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">\r
689 <TR>\r
690 <TD COLSPAN=3 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">\r
691 <A NAME="navbar_bottom_firstrow"><!-- --></A>
692 <TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">\r
693   <TR ALIGN="center" VALIGN="top">\r
694   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A>&nbsp;</TD>\r
695   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A>&nbsp;</TD>\r
696   <TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> &nbsp;<FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT>&nbsp;</TD>\r
697   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A>&nbsp;</TD>\r
698   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A>&nbsp;</TD>\r
699   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../index-all.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A>&nbsp;</TD>\r
700   <TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1">    <A HREF="../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A>&nbsp;</TD>\r
701   </TR>\r
702 </TABLE>\r
703 </TD>\r
704 <TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>\r
705 </EM>\r
706 </TD>\r
707 </TR>\r
708 \r
709 <TR>\r
710 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
711 &nbsp;<A HREF="../../../../../com/sun/speech/freetts/audio/MultiFile8BitAudioPlayer.html" title="class in com.sun.speech.freetts.audio"><B>PREV CLASS</B></A>&nbsp;\r
712 &nbsp;<A HREF="../../../../../com/sun/speech/freetts/audio/NullAudioPlayer.html" title="class in com.sun.speech.freetts.audio"><B>NEXT CLASS</B></A></FONT></TD>\r
713 <TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">\r
714   <A HREF="../../../../../index.html" target="_top"><B>FRAMES</B></A>  &nbsp;\r
715 &nbsp;<A HREF="MultiFileAudioPlayer.html" target="_top"><B>NO FRAMES</B></A>  &nbsp;\r
716 &nbsp;<SCRIPT type="text/javascript">\r
717   <!--\r
718   if(window==top) {\r
719     document.writeln('<A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>');\r
720   }\r
721   //-->\r
722 </SCRIPT>\r
723 <NOSCRIPT>\r
724   <A HREF="../../../../../allclasses-noframe.html"><B>All Classes</B></A>\r
725 </NOSCRIPT>
726 \r
727 </FONT></TD>\r
728 </TR>\r
729 <TR>\r
730 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
731   SUMMARY:&nbsp;NESTED&nbsp;|&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_summary">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_summary">METHOD</A></FONT></TD>\r
732 <TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">\r
733 DETAIL:&nbsp;FIELD&nbsp;|&nbsp;<A HREF="#constructor_detail">CONSTR</A>&nbsp;|&nbsp;<A HREF="#method_detail">METHOD</A></FONT></TD>\r
734 </TR>\r
735 </TABLE>\r
736 <A NAME="skip-navbar_bottom"></A>
737 <!-- ======== END OF BOTTOM NAVBAR ======= -->\r
738 \r
739 <HR>\r
740 \r
741 </BODY>\r
742 </HTML>\r