%bte.doc super="item.bte" %> <%bte.tpl name=pageTitle%>Concatenation Streams<%/bte.tpl%> <%bte.tpl name=description%>Combine multiple streams of incoming data to create a single stream<%/bte.tpl%> <%bte.tpl name=keywords%>concat stream, concatenation stream, concatinputstream, concatreader<%/bte.tpl%> <%bte.tpl name=content%>
Concatenation Streams allow multiple input sources to be combined into a singe source stream.
// Pre-pend data to a InputStream "in" // giving a new stream. in = new ConcatInputStream( new ByteArrayInputStream( new byte[]{ 3,1,4,1,5,9 } ), in );
Combines multiple byte stream sources into a single byte stream.
[Download /w Source | Browse Source | Documentation]
// Pre-pend data to a Reader "in" // giving a new reader. in = new ConcatReader( new StringReader( "Pre-pending this data." ), in );
Combines multiple character stream sources into a single character stream.
[Download /w Source | Browse Source | Documentation]