Package ru.curs.celesta.score.io
Class UrlResource
- java.lang.Object
-
- ru.curs.celesta.score.io.UrlResource
-
-
Constructor Summary
Constructors Constructor Description UrlResource(URL url)
UrlResource(URL url, Namespace namespace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description UrlResource
createRelative(String relativePath, Namespace namespace)
Creates a resource relative to this resource.boolean
equals(Object obj)
InputStream
getInputStream()
Returns input stream for the resource.Namespace
getNamespace()
Returns namespace of current resource.int
hashCode()
String
toString()
-
Methods inherited from interface ru.curs.celesta.score.io.Resource
contains, createRelative, createRelative, delete, getOutputStream, getRelativePath
-
-
-
-
Method Detail
-
getInputStream
public InputStream getInputStream() throws IOException
Description copied from interface:Resource
Returns input stream for the resource.- Specified by:
getInputStream
in interfaceResource
- Returns:
- Throws:
IOException
- when input stream cannot be provided.
-
createRelative
public UrlResource createRelative(String relativePath, Namespace namespace) throws MalformedURLException
Description copied from interface:Resource
Creates a resource relative to this resource.- Specified by:
createRelative
in interfaceResource
- Parameters:
relativePath
- path relative tothis
resource.namespace
- name space of the created resource.- Returns:
- Throws:
MalformedURLException
-
getNamespace
public Namespace getNamespace()
Description copied from interface:Resource
Returns namespace of current resource.- Specified by:
getNamespace
in interfaceResource
- Returns:
-
-