|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.avalon.framework.logger.AbstractLogEnabled
org.apache.cocoon.components.source.impl.RepositorySource
public class RepositorySource
Source wrapper that enhances the wrapped sources with additional capabilities.
Currently this Source optionally adds inspectability through the InspectableSource interface.
Wrapped sources must implement ModifiableTraversableSource.
| Constructor Summary | |
|---|---|
RepositorySource(String prefix,
ModifiableTraversableSource delegate,
SourceDescriptor descriptor,
Logger logger)
|
|
| Method Summary | |
|---|---|
boolean |
canCancel(OutputStream out)
|
void |
cancel(OutputStream out)
|
void |
delete()
|
boolean |
exists()
|
Source |
getChild(String name)
|
Collection |
getChildren()
|
long |
getContentLength()
|
InputStream |
getInputStream()
|
long |
getLastModified()
|
String |
getMimeType()
|
String |
getName()
|
OutputStream |
getOutputStream()
|
Source |
getParent()
|
String |
getScheme()
|
SourceProperty[] |
getSourceProperties()
Get all source properties that are defined on the wrapped source. |
SourceProperty |
getSourceProperty(String uri,
String name)
Get the source property on the wrapped source. |
String |
getURI()
|
SourceValidity |
getValidity()
Return a SourceValidity object describing the validity of this Source. |
boolean |
isCollection()
|
void |
makeCollection()
|
void |
refresh()
|
void |
removeSourceProperty(String uri,
String name)
Remove the source property on the wrapped source. |
void |
setSourceProperty(SourceProperty property)
Set the source property on the wrapped source. |
| Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled |
|---|
enableLogging, getLogger, setupLogger, setupLogger, setupLogger |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RepositorySource(String prefix,
ModifiableTraversableSource delegate,
SourceDescriptor descriptor,
Logger logger)
throws SourceException
SourceException| Method Detail |
|---|
public SourceProperty[] getSourceProperties()
throws SourceException
getSourceProperties in interface InspectableSourceSourceException
public SourceProperty getSourceProperty(String uri,
String name)
throws SourceException
getSourceProperty in interface InspectableSourceSourceException
public void removeSourceProperty(String uri,
String name)
throws SourceException
removeSourceProperty in interface InspectableSourceSourceException
public void setSourceProperty(SourceProperty property)
throws SourceException
setSourceProperty in interface InspectableSourceSourceExceptionpublic boolean exists()
exists in interface Sourcepublic long getContentLength()
getContentLength in interface Source
public InputStream getInputStream()
throws IOException,
SourceNotFoundException
getInputStream in interface SourceIOException
SourceNotFoundExceptionpublic long getLastModified()
getLastModified in interface Sourcepublic String getMimeType()
getMimeType in interface Sourcepublic String getScheme()
getScheme in interface Sourcepublic String getURI()
getURI in interface Sourcepublic SourceValidity getValidity()
If the SourceDescriptor service is present, the resulting validity is an aggregated validity object containing both the validity describing the source itself _and_ one describing the validity of the SourceProperties managed by the SourceDescriptor.
getValidity in interface Sourcepublic void refresh()
refresh in interface Source
public Source getChild(String name)
throws SourceException
getChild in interface TraversableSourceSourceException
public Collection getChildren()
throws SourceException
getChildren in interface TraversableSourceSourceExceptionpublic String getName()
getName in interface TraversableSource
public Source getParent()
throws SourceException
getParent in interface TraversableSourceSourceExceptionpublic boolean isCollection()
isCollection in interface TraversableSource
public void makeCollection()
throws SourceException
makeCollection in interface ModifiableTraversableSourceSourceExceptionpublic boolean canCancel(OutputStream out)
canCancel in interface ModifiableSource
public void cancel(OutputStream out)
throws IOException
cancel in interface ModifiableSourceIOException
public void delete()
throws SourceException
delete in interface ModifiableSourceSourceException
public OutputStream getOutputStream()
throws IOException
getOutputStream in interface ModifiableSourceIOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||