public abstract class ByteSource
extends java.lang.Object
Constructor and Description |
---|
ByteSource(java.lang.String fileName) |
Modifier and Type | Method and Description |
---|---|
abstract byte[] |
getAll() |
byte[] |
getBlock(int start,
int length) |
abstract byte[] |
getBlock(long start,
int length) |
abstract java.lang.String |
getDescription() |
java.lang.String |
getFileName() |
abstract java.io.InputStream |
getInputStream() |
java.io.InputStream |
getInputStream(long start) |
abstract long |
getLength()
This operation can be VERY expensive; for inputstream byte sources, the
entire stream must be drained to determine its length.
|
public final java.io.InputStream getInputStream(long start) throws java.io.IOException
java.io.IOException
public abstract java.io.InputStream getInputStream() throws java.io.IOException
java.io.IOException
public byte[] getBlock(int start, int length) throws java.io.IOException
java.io.IOException
public abstract byte[] getBlock(long start, int length) throws java.io.IOException
java.io.IOException
public abstract byte[] getAll() throws java.io.IOException
java.io.IOException
public abstract long getLength() throws java.io.IOException
java.io.IOException
- if it fails to read the byte source datapublic abstract java.lang.String getDescription()
public final java.lang.String getFileName()
Copyright © 2010 - 2023 Adobe. All Rights Reserved