org.eclipse.cdt.debug.core.sourcelookup
Interface ICSourceLocator

All Superinterfaces:
org.eclipse.debug.core.model.ISourceLocator
All Known Implementing Classes:
CSourceLocator, CSourceManager

public interface ICSourceLocator
extends org.eclipse.debug.core.model.ISourceLocator

A C/C++ extension of ISourceLocator. Provides constants and methods to manage different source modes.

Since:
Aug 19, 2002

Method Summary
 boolean contains(org.eclipse.core.resources.IResource resource)
          Returns whether this locator is able to locate the given resource.
 java.lang.Object findSourceElement(java.lang.String fileName)
          Returns an object representing the source code for a type with the specified name, or null if none could be found.
 int getLineNumber(org.eclipse.debug.core.model.IStackFrame stackFrame)
          Returns the line number of the instruction pointer in the specified stack frame that corresponds to a line in an associated source element, or -1 if line number information is unavailable.
 org.eclipse.core.resources.IProject getProject()
          Returns the project this source locator is associated with or null.
 ICSourceLocation[] getSourceLocations()
          Returns the source locations of this locator.
 boolean searchForDuplicateFiles()
          Returns whether to search for all source elements, or just the first match.
 void setSearchForDuplicateFiles(boolean search)
          Sets the value of the 'search for duplicate source files' flag.
 void setSourceLocations(ICSourceLocation[] locations)
          Sets the source locations of this locator.
 
Methods inherited from interface org.eclipse.debug.core.model.ISourceLocator
getSourceElement
 

Method Detail

getProject

org.eclipse.core.resources.IProject getProject()
Returns the project this source locator is associated with or null.

Returns:
project this source locator is associated with or null

getLineNumber

int getLineNumber(org.eclipse.debug.core.model.IStackFrame stackFrame)
Returns the line number of the instruction pointer in the specified stack frame that corresponds to a line in an associated source element, or -1 if line number information is unavailable.

Parameters:
frameInfo - the frame data
Returns:
line number of instruction pointer in this stack frame, or -1 if line number information is unavailable

getSourceLocations

ICSourceLocation[] getSourceLocations()
Returns the source locations of this locator.

Returns:
the source locations of this locator

setSourceLocations

void setSourceLocations(ICSourceLocation[] locations)
Sets the source locations of this locator.

Parameters:
location - - an array of source locations

contains

boolean contains(org.eclipse.core.resources.IResource resource)
Returns whether this locator is able to locate the given resource.

Parameters:
resource - the resource to locate
Returns:
whether this locator is able to locate the given resource

findSourceElement

java.lang.Object findSourceElement(java.lang.String fileName)
Returns an object representing the source code for a type with the specified name, or null if none could be found. The source element returned is implementation specific - for example, a resource, a local file, a zip file entry, etc.

Parameters:
name - the name of the object for which source is being searched for
Returns:
source element

searchForDuplicateFiles

boolean searchForDuplicateFiles()
Returns whether to search for all source elements, or just the first match.

Returns:
whether to search for all source elements, or just the first match

setSearchForDuplicateFiles

void setSearchForDuplicateFiles(boolean search)
Sets the value of the 'search for duplicate source files' flag.

Parameters:
search - - a value to set