|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface WritableResource
Extended interface for a resource that supports writing to it.
Provides an OutputStream accessor
.
OutputStream
Method Summary | |
---|---|
OutputStream |
getOutputStream()
Return an OutputStream for the underlying resource,
allowing to (over-)write its content. |
boolean |
isWritable()
Return whether the contents of this resource can be modified, e.g. |
Methods inherited from interface org.springframework.core.io.Resource |
---|
contentLength, createRelative, exists, getDescription, getFile, getFilename, getURI, getURL, isOpen, isReadable, lastModified |
Methods inherited from interface org.springframework.core.io.InputStreamSource |
---|
getInputStream |
Method Detail |
---|
boolean isWritable()
getOutputStream()
or Resource.getFile()
.
Will be true
for typical resource descriptors;
note that actual content writing may still fail when attempted.
However, a value of false
is a definitive indication
that the resource content cannot be modified.
getOutputStream()
,
Resource.isReadable()
OutputStream getOutputStream() throws IOException
OutputStream
for the underlying resource,
allowing to (over-)write its content.
IOException
- if the stream could not be openedInputStreamSource.getInputStream()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |