Package org.apache.tools.ant.util
Class OutputStreamFunneler
java.lang.Object
org.apache.tools.ant.util.OutputStreamFunneler
Manages a set of 
OutputStreams to
 write to a single underlying stream, which is
 closed only when the last "funnel"
 has been closed.- 
Field SummaryFields
- 
Constructor SummaryConstructorsConstructorDescriptionCreate a newOutputStreamFunnelerfor the specifiedOutputStream.OutputStreamFunneler(OutputStream out, long timeoutMillis) Create a newOutputStreamFunnelerfor the specifiedOutputStream, with the specified timeout value.
- 
Method SummaryModifier and TypeMethodDescriptionGet a "funnel"OutputStreaminstance to write to thisOutputStreamFunneler's underlyingOutputStream.voidsetTimeout(long timeoutMillis) Set the timeout for thisOutputStreamFunneler.
- 
Field Details- 
DEFAULT_TIMEOUT_MILLISpublic static final long DEFAULT_TIMEOUT_MILLISDefault timeout.- See Also:
 
 
- 
- 
Constructor Details- 
OutputStreamFunnelerCreate a newOutputStreamFunnelerfor the specifiedOutputStream.- Parameters:
- out-- OutputStream.
 
- 
OutputStreamFunnelerCreate a newOutputStreamFunnelerfor the specifiedOutputStream, with the specified timeout value.- Parameters:
- out-- OutputStream.
- timeoutMillis-- long.
- See Also:
 
 
- 
- 
Method Details- 
setTimeoutpublic void setTimeout(long timeoutMillis) Set the timeout for thisOutputStreamFunneler. This is the maximum time that may elapse between the closure of the last "funnel" and the next call togetOutputStream()without closing the underlying stream.- Parameters:
- timeoutMillis-- longtimeout value.
 
- 
getFunnelInstanceGet a "funnel"OutputStreaminstance to write to thisOutputStreamFunneler's underlyingOutputStream.- Returns:
- OutputStream.
- Throws:
- IOException- if unable to create the funnel.
 
 
-