Package org.eclipse.jdt.debug.core
Interface IJavaExceptionBreakpoint
- All Superinterfaces:
org.eclipse.core.runtime.IAdaptable
,org.eclipse.debug.core.model.IBreakpoint
,IJavaBreakpoint
,org.eclipse.debug.core.model.ITriggerPoint
A breakpoint that suspends execution when a corresponding exception is thrown
in a target VM. An exception breakpoint can be configured to suspend
execution when the corresponding exception is thrown in a caught or uncaught
location. As well, the location can be filtered inclusively or exclusively by
type name patterns.
- Since:
- 2.0
- Restriction:
- This interface is not intended to be implemented by clients.
- Restriction:
- This interface is not intended to be extended by clients.
-
Nested Class Summary
Modifier and TypeInterfaceDescriptionstatic enum
Constants for telling the debugger for each exception breakpoint how to handle multiple occurrences of the same exception instance, which can happen via re-throwing or multiple finally clauses in the call stack. -
Field Summary
Fields inherited from interface org.eclipse.debug.core.model.IBreakpoint
BREAKPOINT_MARKER, ENABLED, ID, LINE_BREAKPOINT_MARKER, PERSISTED, REGISTERED
Fields inherited from interface org.eclipse.jdt.debug.core.IJavaBreakpoint
SUSPEND_THREAD, SUSPEND_VM
Fields inherited from interface org.eclipse.debug.core.model.ITriggerPoint
TRIGGERPOINT
-
Method Summary
Modifier and TypeMethodDescriptionReturns the fully qualified type name of the exception that last caused this breakpoint to suspend, ofnull
if this breakpoint has not caused a thread to suspend.String[]
Returns the exclusive filters that define the scope for the associated exception.String[]
Deprecated.Use getExclusionFilters() or getInclusionFilters()String[]
Returns the inclusive filters that define the scope for the associated exception.Answer this breakpoint'sstrategy
for suspending on recurrences of the same exception instance.boolean
isCaught()
Returns whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).boolean
Returns whether the exception associated with this breakpoint is a checked exception (compiler detected).boolean
Deprecated.Exception breakpoints can have a mixed set of filters and this method is maintained strictly for API backwards compatibilityboolean
Returns whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location (not caught by a try/catch statement).void
setCaught
(boolean caught) Sets whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).void
setExclusionFilters
(String[] filters) Sets the exclusion filters that will define the scope for the associated exception.void
setFilters
(String[] filters, boolean inclusive) Deprecated.Exception breakpoints can have a mixed set of filters.void
setInclusionFilters
(String[] filters) Sets the inclusion filters that will define the scope for the associated exception.void
Define this breakpoint'sstrategy
for suspending on recurrences of the same exception instance.void
setUncaught
(boolean uncaught) Sets whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location.Methods inherited from interface org.eclipse.core.runtime.IAdaptable
getAdapter
Methods inherited from interface org.eclipse.debug.core.model.IBreakpoint
delete, getMarker, getModelIdentifier, isEnabled, isPersisted, isRegistered, setEnabled, setMarker, setPersisted, setRegistered
Methods inherited from interface org.eclipse.jdt.debug.core.IJavaBreakpoint
addBreakpointListener, addInstanceFilter, getBreakpointListeners, getHitCount, getInstanceFilters, getSuspendPolicy, getThreadFilter, getThreadFilters, getTypeName, isInstalled, removeBreakpointListener, removeInstanceFilter, removeThreadFilter, setHitCount, setSuspendPolicy, setThreadFilter, supportsInstanceFilters, supportsThreadFilters
Methods inherited from interface org.eclipse.debug.core.model.ITriggerPoint
isTriggerPoint, setTriggerPoint
-
Method Details
-
setInclusionFilters
Sets the inclusion filters that will define the scope for the associated exception. Filters are a collection of strings of type name prefixes. Default packages should be specified as the empty string.- Parameters:
filters
- the array of filters to apply- Throws:
org.eclipse.core.runtime.CoreException
- if unable to set the property on this breakpoint's underlying marker- Since:
- 2.1
-
getInclusionFilters
Returns the inclusive filters that define the scope for the associated exception. Filters are a collection of strings of type name prefixes.- Returns:
- the array of defined inclusive filters
- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property on this breakpoint's underlying marker- Since:
- 2.1
-
isCaught
boolean isCaught() throws org.eclipse.core.runtime.CoreExceptionReturns whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).- Returns:
true
if this is a caught exception breakpoint- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property from this breakpoint's underlying marker
-
isUncaught
boolean isUncaught() throws org.eclipse.core.runtime.CoreExceptionReturns whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location (not caught by a try/catch statement).- Returns:
true
if this is an uncaught exception breakpoint.- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property from this breakpoint's underlying marker
-
setCaught
void setCaught(boolean caught) throws org.eclipse.core.runtime.CoreException Sets whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).- Parameters:
caught
- whether or not this breakpoint suspends execution when the associated exception is thrown in a caught location- Throws:
org.eclipse.core.runtime.CoreException
- if unable to set the property on this breakpoint's underlying marker
-
setUncaught
void setUncaught(boolean uncaught) throws org.eclipse.core.runtime.CoreException Sets whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location.- Parameters:
uncaught
- whether or not this breakpoint suspends execution when the associated exception is thrown in an uncaught location- Throws:
org.eclipse.core.runtime.CoreException
- if unable to set the property on this breakpoint's underlying marker
-
isChecked
boolean isChecked() throws org.eclipse.core.runtime.CoreExceptionReturns whether the exception associated with this breakpoint is a checked exception (compiler detected).- Returns:
true
if the exception associated with this breakpoint is a checked exception- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property from this breakpoint's underlying marker
-
getExceptionTypeName
String getExceptionTypeName()Returns the fully qualified type name of the exception that last caused this breakpoint to suspend, ofnull
if this breakpoint has not caused a thread to suspend. Note that this name may be a sub type of the exception that this breakpoint is associated with.- Returns:
- fully qualified exception name or
null
-
setFilters
@Deprecated void setFilters(String[] filters, boolean inclusive) throws org.eclipse.core.runtime.CoreException Deprecated.Exception breakpoints can have a mixed set of filters. Use setInclusiveFilters(String[] filters) or setExclusiveFilters(String[] filters)Sets the filters that will define the scope for the associated exception. Filters are a collection of strings of type name prefixes. Default packages should be specified as the empty string.- Parameters:
filters
- the array of filters to applyinclusive
- whether or not to apply the filters as inclusive or exclusive- Throws:
org.eclipse.core.runtime.CoreException
- if unable to set the property on this breakpoint's underlying marker
-
setExclusionFilters
Sets the exclusion filters that will define the scope for the associated exception. Filters are a collection of strings of type name prefixes. Default packages should be specified as the empty string.- Parameters:
filters
- the array of filters to apply- Throws:
org.eclipse.core.runtime.CoreException
- if unable to set the property on this breakpoint's underlying marker- Since:
- 2.1
-
getFilters
Deprecated.Use getExclusionFilters() or getInclusionFilters()Returns the filters that define the scope for the associated exception. Filters are a collection of strings of type name prefixes.- Returns:
- the array of defined filters
- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property on this breakpoint's underlying marker
-
getExclusionFilters
Returns the exclusive filters that define the scope for the associated exception. Filters are a collection of strings of type name prefixes.- Returns:
- the array of defined inclusive filters
- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property on this breakpoint's underlying marker- Since:
- 2.1
-
isInclusiveFiltered
Deprecated.Exception breakpoints can have a mixed set of filters and this method is maintained strictly for API backwards compatibilityReturns whether any inclusive filters have been applied.- Returns:
true
if the inclusive filters have been applied- Throws:
org.eclipse.core.runtime.CoreException
- if unable to access the property on this breakpoint's underlying marker
-
setSuspendOnRecurrenceStrategy
void setSuspendOnRecurrenceStrategy(IJavaExceptionBreakpoint.SuspendOnRecurrenceStrategy strategy) throws org.eclipse.core.runtime.CoreException Define this breakpoint'sstrategy
for suspending on recurrences of the same exception instance.- Parameters:
strategy
- the new strategy- Throws:
org.eclipse.core.runtime.CoreException
- if accessing the breakpoint's marker failed- Since:
- 3.14
- See Also:
-
getSuspendOnRecurrenceStrategy
IJavaExceptionBreakpoint.SuspendOnRecurrenceStrategy getSuspendOnRecurrenceStrategy() throws org.eclipse.core.runtime.CoreExceptionAnswer this breakpoint'sstrategy
for suspending on recurrences of the same exception instance.- Returns:
- the strategy
- Throws:
org.eclipse.core.runtime.CoreException
- if accessing the breakpoint's marker failed- Since:
- 3.14
- See Also:
-