|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface Resource
An abstraction for an available resource in some (potentially) hierarchical repository. In many cases a resource is just a file on disk, but it could be stored other ways (for example, in a ZIP file, or on a remote server). This interface allows an application to use such resources without regard to their particular storage mechanism.
Resources are safe for use from multiple threads.
| Method Summary | |
|---|---|
Iterator<Resource> |
childResources()
|
String |
getName()
Gets the name of this resource within it's parent directory. |
ResourceTree |
getResourceTree()
Gets the ResourceTree that contains this resource. |
URL |
getUrl()
|
boolean |
isDirectory()
Indicates whether this resource is a directory, perhaps with child resources. |
| Method Detail |
|---|
String getName()
ResourceTree may be
(but need not be) empty.
null.URL getUrl()
boolean isDirectory()
true if this resource is a directory.Iterator<Resource> childResources()
ResourceTree getResourceTree()
ResourceTree that contains this resource.
null.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||