org.apache.fontbox.ttf
public class RAFDataStream extends TTFDataStream
Version: $Revision: 1.2 $
Constructor Summary | |
---|---|
RAFDataStream(String name, String mode)
Constructor.
| |
RAFDataStream(File file, String mode)
Constructor.
|
Method Summary | |
---|---|
void | close()
Close the underlying resources.
|
long | getCurrentPosition()
Get the current position in the stream. |
InputStream | getOriginalData() |
int | read()
Read an unsigned byte. |
int | read(byte[] b, int off, int len) |
long | readLong()
Read an unsigned byte. |
short | readSignedShort()
Read an signed short.
|
int | readUnsignedShort()
Read an unsigned short.
|
void | seek(long pos)
Seek into the datasource.
|
Parameters: name The raf file. mode The mode to open the RAF.
Throws: FileNotFoundException If there is a problem creating the RAF.
See Also: RandomAccessFile#RandomAccessFile( String, String )
Parameters: file The raf file. mode The mode to open the RAF.
Throws: FileNotFoundException If there is a problem creating the RAF.
See Also: RandomAccessFile#RandomAccessFile( File, String )
Throws: IOException If there is an error closing the resources.
Returns: The current position in the stream.
Throws: IOException If an error occurs while reading the stream.
Returns: An unsigned byte.
Throws: IOException If there is an error reading the data.
Parameters: b The buffer to write to. off The offset into the buffer. len The length into the buffer.
Returns: The number of bytes read.
Throws: IOException If there is an error reading from the stream.
See Also: java.io.InputStream#read( byte[], int, int )
Returns: An unsigned byte.
Throws: IOException If there is an error reading the data.
Returns: An signed short.
Throws: IOException If there is an error reading the data.
Returns: An unsigned short.
Throws: IOException If there is an error reading the data.
Parameters: pos The position to seek to.
Throws: IOException If there is an error seeking to that position.