Interface IResourceRetriever
-
- All Known Implementing Classes:
DefaultResourceRetriever
public interface IResourceRetriever
Interface for classes that can retrieve data from resources by URL.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description byte[]
getByteArrayByUrl(java.net.URL url)
Gets the byte array that are retrieved from the source URL.java.io.InputStream
getInputStreamByUrl(java.net.URL url)
Gets theInputStream
that connect with source URL for retrieving data from that connection.
-
-
-
Method Detail
-
getInputStreamByUrl
java.io.InputStream getInputStreamByUrl(java.net.URL url) throws java.io.IOException
Gets theInputStream
that connect with source URL for retrieving data from that connection.- Parameters:
url
- the source URL- Returns:
- the input stream or null if the retrieving failed
- Throws:
java.io.IOException
- if any input/output issue occurs
-
getByteArrayByUrl
byte[] getByteArrayByUrl(java.net.URL url) throws java.io.IOException
Gets the byte array that are retrieved from the source URL.- Parameters:
url
- the source URL- Returns:
- the byte array or null if the retrieving failed
- Throws:
java.io.IOException
- if any input/output issue occurs
-
-