Interface Debugger

    • Method Detail

      • addBreakpoint

        void addBreakpoint​(Breakpoint breakpoint)
        Add the given breakpoint
        Parameters:
        breakpoint - the breakpoint
      • addBreakpoint

        void addBreakpoint​(Breakpoint breakpoint,
                           Condition... conditions)
        Add the given breakpoint
        Parameters:
        breakpoint - the breakpoint
        conditions - a number of Conditions
      • addSingleStepBreakpoint

        void addSingleStepBreakpoint​(Breakpoint breakpoint)
        Add the given breakpoint which will be used in single step mode

        The debugger will single step the first message arriving.

        Parameters:
        breakpoint - the breakpoint
      • addSingleStepBreakpoint

        void addSingleStepBreakpoint​(Breakpoint breakpoint,
                                     Condition... conditions)
        Add the given breakpoint which will be used in single step mode

        The debugger will single step the first message arriving.

        Parameters:
        breakpoint - the breakpoint
        conditions - a number of Conditions
      • removeBreakpoint

        void removeBreakpoint​(Breakpoint breakpoint)
        Removes the given breakpoint
        Parameters:
        breakpoint - the breakpoint
      • suspendAllBreakpoints

        void suspendAllBreakpoints()
        Suspends all breakpoints.
      • activateAllBreakpoints

        void activateAllBreakpoints()
        Activate all breakpoints.
      • getBreakpoints

        List<Breakpoint> getBreakpoints()
        Gets a list of all the breakpoints
        Returns:
        the breakpoints wrapped in an unmodifiable list, is never null.
      • startSingleStepExchange

        boolean startSingleStepExchange​(String exchangeId,
                                        Breakpoint breakpoint)
        Starts the single step debug mode for the given exchange
        Parameters:
        exchangeId - the exchange id
        breakpoint - the breakpoint
        Returns:
        true if the debugger will single step the given exchange, false if the debugger is already single stepping another, and thus cannot simultaneously single step another exchange
      • stopSingleStepExchange

        void stopSingleStepExchange​(String exchangeId)
        Stops the single step debug mode for the given exchange.

        Notice: The default implementation of the debugger is capable of auto stopping when the exchange is complete.

        Parameters:
        exchangeId - the exchange id
      • beforeProcess

        boolean beforeProcess​(Exchange exchange,
                              Processor processor,
                              NamedNode definition)
        Callback invoked when an Exchange is about to be processed which allows implementators to notify breakpoints.
        Parameters:
        exchange - the exchange
        processor - the Processor about to be processed
        definition - the definition of the processor
        Returns:
        true if any breakpoint was hit, false if not breakpoint was hit
      • afterProcess

        boolean afterProcess​(Exchange exchange,
                             Processor processor,
                             NamedNode definition,
                             long timeTaken)
        Callback invoked when an Exchange has been processed which allows implementators to notify breakpoints.
        Parameters:
        exchange - the exchange
        processor - the Processor which was processed
        definition - the definition of the processor
        timeTaken - time in millis it took to process the Exchange - time spend in breakpoint callbacks may affect this time
        Returns:
        true if any breakpoint was hit, false if not breakpoint was hit
      • onEvent

        boolean onEvent​(Exchange exchange,
                        CamelEvent.ExchangeEvent event)
        Callback invoked when an Exchange is being processed which allows implementators to notify breakpoints.
        Parameters:
        exchange - the exchange
        event - the event (instance of CamelEvent.ExchangeEvent
        Returns:
        true if any breakpoint was hit, false if not breakpoint was hit