Package org.eclipse.jdt.debug.core
Interface IJavaExceptionBreakpoint
- All Superinterfaces:
IAdaptable,IBreakpoint,IJavaBreakpoint,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
Nested ClassesModifier and TypeInterfaceDescriptionstatic enumConstants 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, REGISTEREDFields inherited from interface org.eclipse.jdt.debug.core.IJavaBreakpoint
SUSPEND_THREAD, SUSPEND_VMFields 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, ofnullif 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'sstrategyfor suspending on recurrences of the same exception instance.booleanisCaught()Returns whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).booleanReturns whether the exception associated with this breakpoint is a checked exception (compiler detected).booleanDeprecated.Exception breakpoints can have a mixed set of filters and this method is maintained strictly for API backwards compatibilitybooleanReturns whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location (not caught by a try/catch statement).voidsetCaught(boolean caught) Sets whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).voidsetExclusionFilters(String[] filters) Sets the exclusion filters that will define the scope for the associated exception.voidsetFilters(String[] filters, boolean inclusive) Deprecated.Exception breakpoints can have a mixed set of filters.voidsetInclusionFilters(String[] filters) Sets the inclusion filters that will define the scope for the associated exception.voidDefine this breakpoint'sstrategyfor suspending on recurrences of the same exception instance.voidsetUncaught(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
getAdapterMethods inherited from interface org.eclipse.debug.core.model.IBreakpoint
delete, getMarker, getModelIdentifier, isEnabled, isPersisted, isRegistered, setEnabled, setMarker, setPersisted, setRegisteredMethods 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, supportsThreadFiltersMethods 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:
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:
CoreException- if unable to access the property on this breakpoint's underlying marker- Since:
- 2.1
-
isCaught
Returns whether this breakpoint suspends execution when the associated exception is thrown in a caught location (in a try/catch statement).- Returns:
trueif this is a caught exception breakpoint- Throws:
CoreException- if unable to access the property from this breakpoint's underlying marker
-
isUncaught
Returns whether this breakpoint suspends execution when the associated exception is thrown in an uncaught location (not caught by a try/catch statement).- Returns:
trueif this is an uncaught exception breakpoint.- Throws:
CoreException- if unable to access the property from this breakpoint's underlying marker
-
setCaught
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:
CoreException- if unable to set the property on this breakpoint's underlying marker
-
setUncaught
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:
CoreException- if unable to set the property on this breakpoint's underlying marker
-
isChecked
Returns whether the exception associated with this breakpoint is a checked exception (compiler detected).- Returns:
trueif the exception associated with this breakpoint is a checked exception- Throws:
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, ofnullif 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.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:
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:
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:
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:
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:
trueif the inclusive filters have been applied- Throws:
CoreException- if unable to access the property on this breakpoint's underlying marker
-
setSuspendOnRecurrenceStrategy
void setSuspendOnRecurrenceStrategy(IJavaExceptionBreakpoint.SuspendOnRecurrenceStrategy strategy) throws CoreException Define this breakpoint'sstrategyfor suspending on recurrences of the same exception instance.- Parameters:
strategy- the new strategy- Throws:
CoreException- if accessing the breakpoint's marker failed- Since:
- 3.14
- See Also:
-
getSuspendOnRecurrenceStrategy
IJavaExceptionBreakpoint.SuspendOnRecurrenceStrategy getSuspendOnRecurrenceStrategy() throws CoreExceptionAnswer this breakpoint'sstrategyfor suspending on recurrences of the same exception instance.- Returns:
- the strategy
- Throws:
CoreException- if accessing the breakpoint's marker failed- Since:
- 3.14
- See Also:
-