Interface Location
-
- All Known Implementing Classes:
FileLocation,URLLocation
interface LocationThe location interface.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidclose()Close the location.java.io.FilegetFile()java.io.InputStreamgetInputStream()java.lang.StringgetSpecification()voidopen()Open the location.intread(byte[] buffer)intread(java.nio.ByteBuffer buffer)
-
-
-
Method Detail
-
getFile
java.io.File getFile() throws java.io.IOException- Returns:
File- Throws:
java.io.IOException- in case of an error
-
open
void open() throws java.io.IOException
Open the location.- Throws:
java.io.IOException- in case of an error
-
close
void close()
Close the location.
-
read
int read(java.nio.ByteBuffer buffer) throws java.io.IOException
- Parameters:
buffer- The buffer- Returns:
- number of read bytes
- Throws:
java.io.IOException- in case of an error
-
read
int read(byte[] buffer) throws java.io.IOException
- Parameters:
buffer- the buffer- Returns:
- number of read bytes
- Throws:
java.io.IOException- in case of an error
-
getInputStream
java.io.InputStream getInputStream() throws java.io.IOException- Returns:
- the resulting input stream.
- Throws:
java.io.IOException- in case of an error
-
getSpecification
java.lang.String getSpecification()
- Returns:
- spec
-
-