java.lang.Iterable<PlexusIoResource>, PlexusIoResourceCollectionAbstractPlexusIoArchiveResourceCollection, AbstractPlexusIoResourceCollectionWithAttributespublic abstract class AbstractPlexusIoResourceCollection extends java.lang.Object implements PlexusIoResourceCollection
| Modifier and Type | Field | Description |
|---|---|---|
static InputStreamTransformer |
identityTransformer |
DEFAULT_ROLE_HINT, ROLE| Modifier | Constructor | Description |
|---|---|---|
protected |
AbstractPlexusIoResourceCollection() |
| Modifier and Type | Method | Description |
|---|---|---|
java.lang.String[] |
getExcludes() |
Returns a string of patterns, which excluded files
should match.
|
FileMapper[] |
getFileMappers() |
Returns the file name mappers, which are used to transform
the resource names.
|
FileSelector[] |
getFileSelectors() |
Returns a set of file selectors, which should be used
to select the included files.
|
java.lang.String[] |
getIncludes() |
Returns a string of patterns, which included files
should match.
|
java.io.InputStream |
getInputStream(PlexusIoResource resource) |
Returns an input stream for the provided resource, with stream transformers applied
|
long |
getLastModified() |
Returns the collections last modification time.
|
protected java.lang.String |
getName(java.lang.String resourceName) |
|
java.lang.String |
getName(PlexusIoResource resource) |
Returns the resources suggested name.
|
java.lang.String |
getPrefix() |
Returns the prefix, which the file sets contents shall
have.
|
protected InputStreamTransformer |
getStreamTransformer() |
|
boolean |
isCaseSensitive() |
Returns, whether the include/exclude patterns are
case sensitive.
|
boolean |
isIncludingEmptyDirectories() |
Returns, whether empty directories are being included.
|
protected boolean |
isSelected(PlexusIoResource plexusIoResource) |
|
boolean |
isUsingDefaultExcludes() |
Returns, whether the default excludes are being
applied.
|
java.util.Iterator<PlexusIoResource> |
iterator() |
|
PlexusIoResource |
resolve(PlexusIoResource resource) |
Resolves the supplide resource into a "real" resource.
|
void |
setCaseSensitive(boolean caseSensitive) |
Sets, whether the include/exclude patterns are
case sensitive.
|
void |
setExcludes(java.lang.String[] excludes) |
Sets a string of patterns, which excluded files
should match.
|
void |
setFileMappers(FileMapper[] fileMappers) |
Sets the file name mappers, which are used to transform
the resource names.
|
void |
setFileSelectors(FileSelector[] fileSelectors) |
Sets a set of file selectors, which should be used
to select the included files.
|
void |
setIncludes(java.lang.String[] includes) |
Sets a string of patterns, which included files
should match.
|
void |
setIncludingEmptyDirectories(boolean includingEmptyDirectories) |
Sets, whether empty directories are being included.
|
void |
setPrefix(java.lang.String prefix) |
Sets the prefix, which the file sets contents shall
have.
|
void |
setStreamTransformer(InputStreamTransformer streamTransformer) |
|
void |
setUsingDefaultExcludes(boolean usingDefaultExcludes) |
Sets, whether the default excludes are being
applied.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetResources, isConcurrentAccessSupported, streampublic static final InputStreamTransformer identityTransformer
protected AbstractPlexusIoResourceCollection()
public void setExcludes(java.lang.String[] excludes)
public java.lang.String[] getExcludes()
public void setFileSelectors(FileSelector[] fileSelectors)
public FileSelector[] getFileSelectors()
public void setStreamTransformer(InputStreamTransformer streamTransformer)
protected InputStreamTransformer getStreamTransformer()
public void setIncludes(java.lang.String[] includes)
public java.lang.String[] getIncludes()
public void setPrefix(java.lang.String prefix)
public java.lang.String getPrefix()
public void setCaseSensitive(boolean caseSensitive)
public boolean isCaseSensitive()
public void setUsingDefaultExcludes(boolean usingDefaultExcludes)
public boolean isUsingDefaultExcludes()
public void setIncludingEmptyDirectories(boolean includingEmptyDirectories)
public boolean isIncludingEmptyDirectories()
protected boolean isSelected(PlexusIoResource plexusIoResource) throws java.io.IOException
java.io.IOExceptionpublic FileMapper[] getFileMappers()
public void setFileMappers(FileMapper[] fileMappers)
public java.util.Iterator<PlexusIoResource> iterator()
iterator in interface java.lang.Iterable<PlexusIoResource>public java.lang.String getName(PlexusIoResource resource)
PlexusIoResourceCollectiongetName in interface PlexusIoResourceCollectionresource - A resource, which has been obtained by
calling PlexusIoResourceCollection.getResources().protected java.lang.String getName(java.lang.String resourceName)
public java.io.InputStream getInputStream(PlexusIoResource resource) throws java.io.IOException
PlexusIoResourceCollectiongetInputStream in interface PlexusIoResourceCollectionresource - The resourcesjava.io.IOException - when something goes badpublic PlexusIoResource resolve(PlexusIoResource resource) throws java.io.IOException
PlexusIoResourceCollectionresolve in interface PlexusIoResourceCollectionresource - The resourcesjava.io.IOException - when something goes badpublic long getLastModified()
throws java.io.IOException
PlexusIoResourceCollectiongetLastModified in interface PlexusIoResourceCollectionPlexusIoResource.UNKNOWN_MODIFICATION_DATE,
if the collections last modification time is unknown,
otherwise the last modification time in milliseconds.java.io.IOException - .