Stream

Overview

Stream is a class in Aspose.3D FOSS for Java. Inherits from: java.io.Closeable.

Created by lexchou on 12/14/2016.

This class provides 16 methods for working with Stream objects in Java programs. Available methods include: close, copyTo, flush, getInputStream, getLength, getOutputStream, read, readByte, seek, setLength, wrap, write, and 1 additional methods. All public members are accessible to any Java application after installing the Aspose.3D FOSS for Java package. Properties: SEEK_CURRENT, SEEK_END, SEEK_SET, inputStream, length, outputStream.

Properties

NameTypeAccessDescription
lengthlongReadGets the length.
inputStreamjava.io.InputStreamReadGets the input stream.
outputStreamjava.io.OutputStreamReadGets the output stream.
SEEK_SETintReadGets the seek set.
SEEK_CURRENTintReadGets the seek current.
SEEK_ENDintReadGets the seek end.

Methods

SignatureDescription
readByte()intCalls readByte on this Stream instance.
read(buf: byte[])intCalls read(buf) on this Stream instance.
read(buf: byte[], start: int, len: int)intCalls read(buf, start, len) on this Stream instance.
write(buf: byte[])Calls write(buf) on this Stream instance.
write(buf: byte[], start: int, len: int)Calls write(buf, start, len) on this Stream instance.
writeByte(b: int)Calls writeByte(b) on this Stream instance.
seek(offset: long, seek: int)longCalls seek(offset, seek) on this Stream instance.
copyTo(output: Stream)Calls copyTo(output) on this Stream instance.
close()Calls close on this Stream instance.
flush()Flushes any buffered data to the underlying stream
getLength()longReturns the length.
setLength(len: long)Sets the length value.
getInputStream()java.io.InputStreamReturns the input stream.
getOutputStream()java.io.OutputStreamReturns the output stream.
wrap(stream: OutputStream)StreamWrap an OutputStream as Stream, the stream must be closed to flush data to output stream.
wrap(stream: InputStream)StreamWrap an InputStream as Stream.

See Also

 English