Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 


Eclipse Platform
Release 3.5

org.eclipse.debug.core.sourcelookup.containers
Class CompositeSourceContainer


java.lang.Object
  extended by 

org.eclipse.core.runtime.PlatformObject
      extended by 

org.eclipse.debug.core.sourcelookup.containers.AbstractSourceContainer
          extended by 
org.eclipse.debug.core.sourcelookup.containers.CompositeSourceContainer
All Implemented Interfaces:
IAdaptable, ISourceContainer
Direct Known Subclasses:
ContainerSourceContainer, DefaultSourceContainer, DirectorySourceContainer, WorkingSetSourceContainer, WorkspaceSourceContainer

public abstract class CompositeSourceContainer
extends AbstractSourceContainer

A source container of source containers.

Clients implementing composite source containers should subclass this class.

Since:
3.0

Field Summary
 
Fields inherited from class org.eclipse.debug.core.sourcelookup.containers. AbstractSourceContainer
EMPTY
 
Constructor Summary
CompositeSourceContainer ()
           
 
Method Summary
protected abstract   ISourceContainer[] createSourceContainers ()
          Creates the source containers in this composite container.
 void dispose ()
          Disposes this source container.
  Object[] findSourceElements ( String name)
          Returns a collection of source elements in this container corresponding to the given name.
protected   Object[] findSourceElements ( String name, ISourceContainer[] containers)
          Returns a collection of source elements in the given containers corresponding to the given name.
  ISourceContainer[] getSourceContainers ()
          Returns the source containers this container is composed of.
 boolean isComposite ()
          Returns whether this container is a composite container.
 
Methods inherited from class org.eclipse.debug.core.sourcelookup.containers. AbstractSourceContainer
abort, getDirector, getSourceContainerType, init, isFindDuplicates, warn
 
Methods inherited from class org.eclipse.core.runtime. PlatformObject
getAdapter
 
Methods inherited from class java.lang. Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.debug.core.sourcelookup. ISourceContainer
getName, getType
 
Methods inherited from interface org.eclipse.core.runtime. IAdaptable
getAdapter
 

Constructor Detail

CompositeSourceContainer

public CompositeSourceContainer()
Method Detail

isComposite

public boolean isComposite()
Description copied from interface: ISourceContainer
Returns whether this container is a composite container. A composite container is composed of other source containers. For example, a workspace source container may be composed of project source containers.

Specified by:
isComposite in interface ISourceContainer
Overrides:
isComposite in class AbstractSourceContainer
Returns:
whether this container is a composite container

findSourceElements

public 
Object[] findSourceElements(
String name)
                            throws 
CoreException
Description copied from interface: ISourceContainer
Returns a collection of source elements in this container corresponding to the given name. Returns an empty collection if no source elements are found. This source container's source lookup director specifies if duplicate source elements should be searched for, via isFindDuplicates(). 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).

Parameters:
name - the name of the source element to search for
Returns:
a collection of source elements corresponding to the given name
Throws:
CoreException - if an exception occurs while searching for source elements

findSourceElements

protected 
Object[] findSourceElements(
String name,
                                      
ISourceContainer[] containers)
                               throws 
CoreException
Returns a collection of source elements in the given containers corresponding to the given name. Returns an empty collection if no source elements are found. This source container's source lookup director specifies if duplicate source elements should be searched for, via isFindDuplicates(). 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).

Parameters:
name - the name of the source element to search for
containers - the containers to search
Returns:
a collection of source elements corresponding to the given name
Throws:
CoreException - if an exception occurs while searching for source elements

createSourceContainers

protected abstract 
ISourceContainer[] createSourceContainers()
                                                      throws 
CoreException
Creates the source containers in this composite container. Subclasses should override this methods.

Throws:
CoreException - if unable to create the containers

getSourceContainers

public 
ISourceContainer[] getSourceContainers()
                                       throws 
CoreException
Description copied from interface: ISourceContainer
Returns the source containers this container is composed of. An empty collection is returned if this container is not a composite container. For example, a workspace source container may be composed of project source containers.

Specified by:
getSourceContainers in interface ISourceContainer
Overrides:
getSourceContainers in class AbstractSourceContainer
Returns:
the source containers this container is composed of, possibly an empty collection
Throws:
CoreException - if unable to retrieve source containers

dispose

public void dispose()
Description copied from interface: ISourceContainer
Disposes this source container. This method is called when the source director associated with this source container is disposed.

Specified by:
dispose in interface ISourceContainer
Overrides:
dispose in class AbstractSourceContainer

Eclipse Platform
Release 3.5

Guidelines for using Eclipse APIs.

Copyright (c) Eclipse contributors and others 2000, 2008. All rights reserved.


 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire