public abstract class ContainerSourceContainer extends CompositeSourceContainer
Names specified in findSourceElements method can
be simple or qualified. When a name is qualified, a file will
be searched for relative to this container, and optionally
nested containers.
This class is not intended to be subclassed or instantiated by clients.
EMPTY| Constructor and Description |
|---|
ContainerSourceContainer(IContainer container,
boolean subfolders)
Constructs a source container on the given workspace container.
|
| Modifier and Type | Method and Description |
|---|---|
protected ISourceContainer[] |
createSourceContainers()
Creates the source containers in this composite container.
|
boolean |
equals(Object obj) |
Object[] |
findSourceElements(String name)
Returns a collection of source elements in this container corresponding to the
given name.
|
IContainer |
getContainer()
Returns the workspace container this source container is
rooted at.
|
String |
getName()
The name of this source container that can be used for presentation purposes.
|
int |
hashCode() |
boolean |
isComposite()
Returns whether this container is a composite container.
|
dispose, findSourceElements, getSourceContainersabort, getDirector, getSourceContainerType, init, isFindDuplicatesgetAdapterclone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitgetTypegetAdapterpublic ContainerSourceContainer(IContainer container, boolean subfolders)
container - the container to search for source insubfolders - whether nested folders should be searched
for source elementspublic IContainer getContainer()
public Object[] findSourceElements(String name) throws CoreException
ISourceContainerisFindDuplicates().
When false the returned collection should contain at most one
source element. If this is a composite container, the containers contained
by this container are also searched.
The format of the given name is implementation specific but generally conforms to the format of a file name. If a source container does not recognize the name format provided, an empty collection should be returned. A source container may or may not require names to be fully qualified (i.e. be qualified with directory names).
findSourceElements in interface ISourceContainerfindSourceElements in class CompositeSourceContainername - the name of the source element to search forCoreException - if an exception occurs while searching for source elementspublic String getName()
ISourceContainerpublic boolean isComposite()
ISourceContainerisComposite in interface ISourceContainerisComposite in class CompositeSourceContainerprotected ISourceContainer[] createSourceContainers() throws CoreException
CompositeSourceContainercreateSourceContainers in class CompositeSourceContainerCoreException - if unable to create the containersGuidelines for using Eclipse APIs. Copyright (c) IBM Corp. and others 2000, 2006. All rights reserved.