public class URLDataSource extends java.lang.Object implements DataSource
| Constructor and Description |
|---|
URLDataSource(java.net.URL url)
Creates a URLDataSource from a URL object.
|
| Modifier and Type | Method and Description |
|---|---|
java.lang.String |
getContentType()
Returns the value of the URL content-type header field.
|
java.io.InputStream |
getInputStream()
Returns an InputStream obtained from the URL.
|
java.lang.String |
getName()
Returns the file name of the URL object.
|
java.io.OutputStream |
getOutputStream()
Returns an OutputStream obtained from the URL.
|
java.net.URL |
getURL()
Returns the URL of the data source.
|
public URLDataSource(java.net.URL url)
public java.lang.String getContentType()
getContentType in interface DataSourcepublic java.lang.String getName()
getName in interface DataSourcepublic java.io.InputStream getInputStream()
throws java.io.IOException
getInputStream in interface DataSourcejava.io.IOExceptionpublic java.io.OutputStream getOutputStream()
throws java.io.IOException
getOutputStream in interface DataSourcejava.io.IOExceptionpublic java.net.URL getURL()