|
Extension SDK 10.1.2 | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object oracle.ide.net.URLFileSystemHelper oracle.ide.net.HttpURLFileSystemHelper
The HttpURLFileSystemHelper
class provides an implementation
of URLFileSystemHelper
for http URLs.
Constructor Summary | |
HttpURLFileSystemHelper()
|
Method Summary | |
boolean |
canCreate(java.net.URL url)
Tests whether the application can create the resource at the specified URL . |
boolean |
exists(java.net.URL url)
Returns true if the specified URL points to a
resource that currently exists; returns false
otherwise. |
long |
getLength(java.net.URL url)
Returns the number of bytes contained in the resource that the specified URL points to. |
java.net.URL |
getParent(java.net.URL url)
Returns the URL representing the parent directory of
the specified URL . |
protected boolean |
haveSamePort(java.net.URL url1,
java.net.URL url2)
|
long |
lastModified(java.net.URL url)
Returns the last modification time (timestamp) of the resource indicated by the specified URL in milliseconds since
00:00:00 GMT, Jan 1, 1970. |
java.io.InputStream |
openInputStream(java.net.URL url)
Opens an InputStream on the specified URL . |
Methods inherited from class oracle.ide.net.URLFileSystemHelper |
appendRelativePath, areEqual, areEqualPathElems, canonicalize, canRead, canWrite, convertSuffix, createTempFile, delete, ensureSuffix, equals, getBaseParent, getDefaultIcon, getFileName, getName, getPath, getPathNoExt, getPlatformPathName, getSuffix, getSystemIcon, hasSuffix, haveSameAuthority, haveSameHost, haveSamePath, haveSameProtocol, haveSameQuery, haveSameRef, haveSameUserInfo, isBaseURLFor, isDirectory, isDirectoryPath, isHidden, isReadOnly, isRegularFile, isValid, list, list, listRoots, ls, ls, mkdir, mkdirs, openOutputStream, renameTo, setLastModified, setReadOnly, toDisplayString, toEncodedString, toRelativeSpec, toRelativeSpec |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public HttpURLFileSystemHelper()
Method Detail |
public long getLength(java.net.URL url)
URL
points to. If the length cannot be
determined, -1
is returned.
The default implementation attempts to get the content length from
the URLConnection
associated with the URL
. If that
fails for some reason (e.g. the resource does not exist, there was
some other an I/O exception, etc.), -1
is returned.
getLength
in class URLFileSystemHelper
URLConnection
public long lastModified(java.net.URL url)
URL
in milliseconds since
00:00:00 GMT, Jan 1, 1970. If the timestamp can't be determined,
-1
is returned.
The default implementation attemps to get the last modified time
from the URLConnection
associated with the URL
. If
that fails for some reason (e.g. the resource does not exist, there
was some other I/O exception, etc.), -1
is returned.
lastModified
in class URLFileSystemHelper
URLConnection
public boolean exists(java.net.URL url)
URLFileSystemHelper
true
if the specified URL
points to a
resource that currently exists; returns false
otherwise.
The default implementation simply returns false
without doing anything.
exists
in class URLFileSystemHelper
public boolean canCreate(java.net.URL url)
URL
.
canCreate
in class URLFileSystemHelper
true
if the resource at the specified URL
exists or can be created; false
otherwise.public java.net.URL getParent(java.net.URL url)
URLFileSystemHelper
URL
representing the parent directory of
the specified URL
. If there is no parent directory,
then null
is returned.
The default implementation returns the value of invoking
URLFactory.newURL( url, ".." )
.
getParent
in class URLFileSystemHelper
public java.io.InputStream openInputStream(java.net.URL url) throws java.io.IOException
InputStream
on the specified URL
.
The default implementation attempts to open the InputStream
through the URLConnection
associated with the URL
.
If the URLConnection
implementation does not support an
InputStream
then an UnknownServiceException
(a runtime exception) will be thrown.
openInputStream
in class URLFileSystemHelper
java.io.FileNotFoundException
- if the resource at the
specified URL does not exist.
java.io.IOException
- if an I/O error occurs when trying to open
the InputStream
.
java.net.UnknownServiceException
- if the
URLConnection
backing the specified URL
does not
support an InputStream
.IOException
,
URLConnection
,
UnknownServiceException
protected boolean haveSamePort(java.net.URL url1, java.net.URL url2)
haveSamePort
in class URLFileSystemHelper
|
Extension SDK | ||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright © 1997, 2004, Oracle. All rights reserved.